Foomatic 4.0.13 =============== foomatic-db-engine ------------------ Foomatic's database engine generates PPD files from the data in Foomatic's XML database. It also contains scripts to directly generate print queues and handle jobs. Till Kamppeter Lars Uebernickel http://www.openprinting.org/ This README contains mainly info for developers. See the file USAGE if you want to know how to use Foomatic. Copying ------- This package and also the other Foomatic packages needed to run this are under the GPL. See http://www.gnu.org/. Bugs ---- If you spot a data error or any other bug, please report it on the OpenPrinting bug tracking system: http://bugs.linux-foundation.org/ Choose "OpenPrinting" as the product and "foomatic-db-engine" as the component. Intro ----- This is the stable version of Foomatic. This version is also the base of our database web interface on http://www.openprinting.org/ New features for Foomatic 4.0.x ------------------------------- Added in 4.0.0: - Support for the PDF-based printing workflow. foomatic-rip now understands both PostScript and PDF as input. PPDs are generated with two "*cupsFilter" lines now, so that CUPS knows that also PDF can get fed in. By the cost factors PDF is made the preferred input format. - foomatic-rip is rewritten in C, so that libraries can be used without needing Perl bindings. - Support for CUPS custom options. If a printer/driver combo has numerical, string, or password options, appropriate keywords are added to the PPD so that these options are also recognized as CUPS custom options (see http://www.cups.org/documentation.php/doc-1.4/spec-ppd.html for the CUPS PPD extension for custom options). - PJL/JCL options in PPD files are now generated in the standard way as defined by the PPD specs. Foomatic keywords are only used if really necessary. - Generated PPDs have now an additional "*cupsFilter:" line to tell CUPS that foomatic-rip understands PDF input (output of the "pdftopdf" CUPS filter). - Driver XML files can now have a new "" tag in the "" section, to supply a different command line prototype for PDF input. If left out, the same command line prototype is used for both PDF and PostScript input. - Margins in generated PPDs now default to safer values and not to zero if no margins are specified in the XML files. - CUPS page accounting can be suppressed on a per-driver basis now, via the tag "" and the PPD keyword "*FoomaticRIPNoPageAccounting: True". - Added new "foomatic-ppd-to-xml" utility to generate Foomatic XML files corresponding to a given PPD file. - Printer/driver relations now can be defined by the "" section in the driver XML file or by the "" section in the printer XML file. Before, only the former was possible. - Added find_printer() method, to search for printers in the database. This method is especially used by the web query API for automatic driver/PPD downloads from the OpenPrinting web site. It can also be used in a local installation with the new "foomatic-searchprinter" utility. - Added support for more detailed driver information, like license, whether it is free, whether it comes from the printer's manufacturer, support contacts, short description, by-task ratings. This gives more information to decide on downloading and installing a driver for both driver auto download and browsing the OpenPrinting web site. The information can also be used by printer setup tools using a locally installed Foomatic database. The information is available in the driver XML files (there one enters it), the PPD files, and also in the device ID strings, defined in the PPDs (so that the information goes into the output of "lpinfo -l -m" of CUPS). New features for Foomatic 3.0.x ------------------------------- Added after 3.0.2: - Support for on-the-fly PPD generation by CUPS 1.2. Now all Foomatic PPDs appear in the model lists of the CUPS web interface without needing to pre-compile the PPDs. The PPDs get actually generated if one selects them for the new print queue to be set up. Added in 3.0.2: - Some fixes to make foomatic-rip more robust against weird input via the command line or environment variables are done. This solves the problem of an attacker being able to run arbitrary commands as "lp" (or however the spooler's special user is named) on the print server (Security Advisory CAN-2004-0801). - Workaround for PostScript generation bug in all OpenOffice.org 1.1.x versions. - Let the PPD generator use the manufacturer as defined in the Foomatic database and not the one from the IEEE-1284 auto-detection ID string for the "*Manufacturer: ..." tag of the PPD files, as in the IDs the manufacturer names often do not comply with the Adobe specs (as "Hewlett-Packard", "HP" has to be used). Added in 3.0.1: - CUPS raster drivers can now be used with any spooler. This makes a lot of newer commercial or manufacturer-supplied printer drivers available for non-CUPS environments. To use a CUPS raster driver with a spooler other than CUPS, you need to install Ghostscript (preferrably ESP Ghostscript) with CUPS raster support, the appropriate CUPS raster driver. You do not need to install the complete CUPS package, the CUPS libraries are enough (libcups and libcupsimage, usually in the "libcups" package of your distribution) and to compile CUPS raster drivers you need also the header files of the CUPS library (libcups-devel, cupsys-dev, or similar package of your distro). Then you can set up a print queue with the PPD file of the CUPS driver the same way as if you had a native PostScript printer. - If a printer/driver combo has Foomatic-defined JCL options and the driver already generates a JCL header, the JCL options are merged into the header produced by the driver. - Workaround for newly introduced PostScript generation bug of OpenOffice.org 1.1.0 (OOo puts settings for whole document into "%%PageSetup" section of first page). - Added "use strict;" to the most important Perl scripts, clean-up of the scripts (Thanks to Patrick Powell from LPRng) - Improved LPRng support (Thanks to Patrick Powell from LPRng) - Printer listing options and auto-selection of recommended driver for the PPD generator foomatic-ppdfile (Thanks to Patrick Powell from LPRng). - Support for string options and additional operation modes for foomatic-addpjloptions (Thanks to Patrick Powell from LPRng). - Additional checks in the configure scripts (Thanks to Patrick Powell from LPRng). - Composite options can be nested now (normal and forced composite options can be mixed). - Several modifications to make the PPD files compatible with the PostScript drivers for Windows: 100 instead of 999 choices for the "Copies" options, no "," and "+" in the "*NickName" and "*ShortNickName" entries, optional cutting of the long names of the options and choices (translation strings in the PPDs) to 39 characters for compatibility with the Microsoft PostScript driver and the original PostScript driver for Windows of CUPS. All this is not required by the Adobe specification for PPD files. - Compatibility fixes for IRIX and the *BSD operating systems. - Script to update the "gutenprint" driver entry in the database using the src/foomatic/foomatic-printermap file of the source tarball of Gutenprint 5.0.x. - perltoxml() Perl function in DB.pm to generate XML database entries from PPD files (thanks to Tim Waugh from Red Hat). - Let foomatic-ppdfile (which can be also called under the name "foomatic-datafile", for compatibility with frontends) accept and ignore the "-t" option for backwards compatibility. Now the KDE Printing Manager works correctly again. - Fixed PPD file generation so that the files pass the "cupstestppd" of CUPS 1.1.20. Added in 3.0.0: - For all supported spoolers (CUPS, LPRng, LPD, GNUlpr, PPR, PDQ, CPS, no spooler) the same PostScript-to-printer's-native-language filter (RIP, Raster Image Processor), foomatic-rip is used. foomatic-rip detects automatically from which spooler it is called. - foomatic-rip gets the info about the printer's capabilities and the driver options and default settings always from PPD files, independent which spooler is used. It is possible to use Foomatic-generated PPD files (usually for non-PostScript printers) or manufacturer- supplied PPD files of PostScript printers. So o PPD files of PostScript printers can be used with every spooler, not only with CUPS and PPR and on all spoolers all options will be available. So PostScript printers work always "Perfectly". o With the PPD file one has one configuration file for every place where information about the printer and its options is needed: The print queue itself, PPD-aware applications (as Star Office, OpenOffice.org, GIMP, ...), and clients (Windows, Mac, Unix with arbitrary spooler). The PPD format is a standard format used by every modern operating system. - PPD building and PostScript processing is done according to the Adobe specifications DSC (Document Structuring Conventions) and PPD (PostScript Printer Description) as published on http://partners.adobe.com/public/developer/ps/index_specs.html - foomatic-rip inserts all default settings from the PPD file (so you can edit the "*Default..." lines in the PPD files to set the defaults), reads option settings from the user's command line, and from the PostScript data stream. Settings in the PostScript data stream have the highest priority to assure that what one sets in an application is used. Depending on the option type the settings are applied to the renderer's (usually Ghostscript's) command line, to the JCL header, or stuffed in at the right place of the PostScript data stream. - Support for option settings only acting on a certain page selection (example: First page on letterhead paper from tray 1, rest on plain paper from tray 2). Settings must be put into the "%%BeginPageSetup"/ "%%EndPageSetup" sections (or at least right after the "%%Page:" comments) of the appropriate pages in the PostScript input file. They can also be specified on the command line by specifying a page range before the option name (ex: "lpr -o 1,5-8:ColorMode=CMYK file.ps"). If necessary, the renderer (usually Ghostscript) is stopped and restarted in the middle of the job, when certain pages need a different command line for the renderer. The bug of Star Office/OpenOffice.org inserting the "%%BeginSetup...%%EndSetup" section after the first "%%Page:" comment is taken care of. - foomatic-rip does neither use temporary files on the disk, nor does it need to load huge documents completely into memory. All is done in data streams where not more data than necessary is buffered. To make this possible foomatic-rip forks into up to six sub-processes. - The installation is very easy, one needs only foomatic-rip (absolutely monolithic, no Perl modules needed), a PPD file, and optionally foomatic-gswrapper. No different files for different spoolers. - Custom page size support with all spoolers when the PPD file has Adobe-compliant definitions for usage of custom page sizes. - The spooler-less printing mode of foomatic-rip can be used for testing and debugging PPD files in arbitrary directories, one simply specifies them with the new "--ppd" option. - With PDQ one can print arbitrary file types now, and even set up raw printers. The PDQ driver files are generated by foomatic-rip, so the user does not need to download more files than with other spoolers. - Under PPR 1.50 and newer foomatic-rip runs as a PPR RIP, under older versions, as before, as a PPR interface. - foomatic-configure sets up printer queues based on Foomatic database entries, arbitrary third-party PPDs (as shipped with PostScript printers), or raw queues. - foomatic-configure is much faster when copying or modifying print queues now, as it does not rebuild the PPD from the Foomatic database all the time (as long as one does not force a rebuild with "-f"). - foomatic-addpjloptions works also in regular installations now, not only in "inplace" installations. - foomatic-compiledb generates only PPD and XML files now. - foomatic-datafile is renamed to foomatic-ppdfile, a compatibility link named foomatic-datafile is set. foomatic-ppdfile generates only PPDs, the options "-t" and "-f" are ignored. - foomatic-configure, foomatic-printjob, and all the other scripts have the same command lines as in Foomatic 2.0. Exceptions: In foomatic-configure "--oldppd" was dropped, "--ppd" (for setting up a queue with a third-party PPD file) added, and the meaning of "-f" (force rebuild of PPD) changed. - Option groups: Options can be put into groups and subgroups in the PPD files, so that GUIs can present them in a structured way (in tabs or in a tree structure). It is nearly completely functional, the only thing missing is translation support ("long names" for the groups, as "Adjustments and Corrections" for "Adjustment", or translations to other languages). Now the PPD generator makes trivial translations ("ThisIsAGroup" -> "This Is A Group") automatically. - Composite options: This is a new option type to make it easier for users to choose the best settings for a certain printing task, especially if the driver has very many options. The idea is to have an enumerated choice option which does not directly modify something in the driver's command line but sets several of the other options. We will have a "Printout Mode" option for all printers with the following choices: Draft Normal High Quality Very High Quality Photo For an Epson Stylus Color 680 with Gutenprint it sets the options resolution, dithering, and image type as follows: Choice Resolution Dither ImageType ------------------------------------------------------------------ Draft 180x180 dpi Very Fast LineArt Normal 360x360 dpi Adaptive Hybrid Photographs High Quality 720x720 dpi Adaptive Hybrid Photographs Very High Qual. 1440x720 dpi Adaptive Hybrid Photographs Photo 2880x720 dpi Even Tone Photographs The mentioned settings set all the color mode to "Color", there are also choices with a ".Gray" modifier (ex: "Normal.Gray" which set the color mode to "Grayscale", but the other mentioned options as the standard variants ("Normal"). The member options of the composite option all get one choice called "FromPrintoutMode"/"Controlled by 'Printout Mode'" added, which gets their default setting. If this choice is selected, the option is set by the composite option according to the table. If the user wants to modify one of the individual member options, he simply chooses a value other than "FromPrintoutMode" for this particular option. In addition the member options will be put into a group (named "Printout Mode"). and the composite option goes into the same group as "PageSize", "InputSlot", ... So the user sees the composite option on the "Front page" of the GUI and can quickly set up print jobs without getting confused. The user with more special demands goes to the tab with the member options and makes detailed choices. - Forced composite options: These are special composite options where the user cannot set the individual member options, but only the composite option (the user is forced to use the composite option). This allows options acting at two or more places, for example a "PageSize" option for a driver which is a filter translating Ghostscript bitmap output to the printer's language. One lets one member option be an option inserting PostScript code for the page size into the PostScript input data stream for Ghostscript, and another member option insert the correct bitmap size into the filter's command line. The user sees only the composite option and sets the paper size with it as usual. - String and password options: These options allow the user to supply nearly arbitrary strings (a length limit and restrictions be a list of allowed characters or a Perl regular expression can be set) to the printer driver, for example names of color calibration files, fax numbers, passwords for confidential jobs, ... Frequently needed strings can be added as enumerated choices, so a frontend can show the option as a combo-box. The enumerated choices are also used for frontends which only support options as defined by the PPD spec. - New handling of numerical options in the PPD files: "*Default