From 559760e7950d5711d7aacd420aa8d5e77a49bf41 Mon Sep 17 00:00:00 2001 From: nidhijainpnp <12njain06@gmail.com> Date: Mon, 24 Aug 2020 22:06:49 +0530 Subject: [PATCH] ppdgenerator.c: add fax support (cherry picked from commit 722bf020afbec2041ade4923c2c5564176027884) --- cupsfilters/ppdgenerator.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/cupsfilters/ppdgenerator.c b/cupsfilters/ppdgenerator.c index 7a9c11437..80b6ac6b1 100644 --- a/cupsfilters/ppdgenerator.c +++ b/cupsfilters/ppdgenerator.c @@ -1863,6 +1863,25 @@ ppdCreateFromIPP2(char *buffer, /* I - Filename buffer */ cupsFilePrintf(fp, "*cupsJobPassword: \"%s\"\n", pattern); } + /* + * Fax specific options + */ + + if ((attr = ippFindAttribute(response, "ipp-features-supported", + IPP_TAG_KEYWORD))!= NULL && ippContainsString(attr, "faxout")){ + + cupsFilePuts(fp, "*cupsIPPFaxOut: True\n"); + human_readable = lookup_option("Phone", opt_strings_catalog, + printer_opt_strings_catalog); + + cupsFilePrintf(fp, "*OpenUI Phone/Phone Number: PickOne\n" + "*OrderDependency: 10 AnySetup *Phone\n" + "*DefaultPhone: None\n" "*Phone None: %s\n" "CloseUI: *Phone\n",(human_readable ? human_readable : "")); + cupsFilePrintf(fp,"*CustomPhone True: %s\n" "*ParamCustomPhone Text: 1 string 0 64\n",""); + + + } + /* * PDLs and common resolutions ... */ -- 2.47.3