Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prefer PDF again (fixes #42) #44

Merged
merged 1 commit into from
Jul 30, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions ppd/ppd-generator.c
Original file line number Diff line number Diff line change
@@ -722,6 +722,14 @@ ppdCreatePPDFromIPP2(char *buffer, // I - Filename buffer
formatfound = 1;
is_pdf = 1;
}
else if (cupsArrayFind(pdl_list, "application/pdf"))
{
// PDF printer
cupsFilePuts(fp, "*cupsFilter2: \"application/vnd.cups-pdf application/pdf 0 -\"\n");
manual_copies = 0;
formatfound = 1;
is_pdf = 1;
}
#ifdef CUPS_RASTER_HAVE_APPLERASTER
else if (cupsArrayFind(pdl_list, "image/urf") &&
(ippFindAttribute(supported, "urf-supported", IPP_TAG_KEYWORD) != NULL))
@@ -843,14 +851,6 @@ ppdCreatePPDFromIPP2(char *buffer, // I - Filename buffer
}
}
#endif
else if (cupsArrayFind(pdl_list, "application/pdf"))
{
// PDF printer
cupsFilePuts(fp, "*cupsFilter2: \"application/vnd.cups-pdf application/pdf 0 -\"\n");
manual_copies = 0;
formatfound = 1;
is_pdf = 1;
}
else if (cupsArrayFind(pdl_list, "image/pwg-raster") &&
ippFindAttribute(supported, "pwg-raster-document-type-supported", IPP_TAG_KEYWORD) != NULL &&
(attr = ippFindAttribute(supported, "pwg-raster-document-resolution-supported", IPP_TAG_RESOLUTION)) != NULL)