Index: cups/api-filter.shtml =================================================================== --- cups/api-filter.shtml (revision 7961) +++ cups/api-filter.shtml (working copy) @@ -131,6 +131,10 @@
CUPS_DATADIR
The directory where (read-only) CUPS data files can be found.
+
CUPS_FILETYPE
+
The type of file being printed: "job-sheet" for a banner page and + "document" for a regular print file.
+
CUPS_SERVERROOT
The root directory of the server.
Index: man/filter.man =================================================================== --- man/filter.man (revision 7961) +++ man/filter.man (working copy) @@ -12,7 +12,7 @@ .\" which should have been included with this file. If this file is .\" file is missing or damaged, see the license at "http://www.cups.org/". .\" -.TH filter 7 "Common UNIX Printing System" "14 May 2008" "Apple Inc." +.TH filter 7 "Common UNIX Printing System" "18 September 2008" "Apple Inc." .SH NAME filter \- cups file conversion filter interface .SH SYNOPSIS @@ -148,11 +148,22 @@ application/postscript). .TP 5 +CUPS_CACHEDIR +.br +The directory for semi-persistent cache files can be found. + +.TP 5 CUPS_DATADIR .br The directory where data files can be found. .TP 5 +CUPS_FILETYPE +.br +The type of file being printed: "job-sheet" for a banner page and "document" +for a regular print file. + +.TP 5 CUPS_SERVERROOT .br The root directory of the server. Index: CHANGES.txt =================================================================== --- CHANGES.txt (revision 7961) +++ CHANGES.txt (working copy) @@ -1,9 +1,12 @@ -CHANGES.txt - 2008-09-10 +CHANGES.txt - 2008-09-18 ------------------------ CHANGES IN CUPS V1.4b1 - Documentation updates (STR #2567) + - Added CUPS_JOBTYPE environment variable for job filters so + they know whether they are printing a banner or document + file (STR #2799) - Added support for printer filtering by the cupsfilter command (STR #2562) - Added a SSLOptions directive to allow Windows clients to Index: scheduler/job.c =================================================================== --- scheduler/job.c (revision 7961) +++ scheduler/job.c (working copy) @@ -2484,7 +2484,7 @@ title[IPP_MAX_NAME], /* Job title string */ copies[255], /* # copies string */ - *envp[MAX_ENV + 16], + *envp[MAX_ENV + 17], /* Environment variables */ charset[255], /* CHARSET env variable */ class_name[255],/* CLASS env variable */ @@ -3141,6 +3141,8 @@ envp[envc ++] = content_type; envp[envc ++] = device_uri; envp[envc ++] = printer_name; + envp[envc ++] = banner_page ? "CUPS_FILETYPE=job-sheet" : + "CUPS_FILETYPE=document"; if (!printer->remote && !printer->raw) {