GNU Info

Info Node: (gimpprint.info)printers.xml

(gimpprint.info)printers.xml


Next: Driver file Up: New Printer
Enter node , (file) or (file)node

`printers.xml'
==============

   `printers.xml' is an XML-like file (there's no formal DTD) that
contains very simple printer definitions.  A typical definition follows:

     <printer name="EPSON Stylus Color 1500" driver="escp2-1500">
     <color>
     <model value=2>
     <gamma value=0.597>
     <density value=1.0>
     <language value=escp2>
     </printer>

   There are other tags that may be present.  The only ones that are
mandatory are `<printer>', `<color>', `<model>', and `<language>'.  The
other optional parameters (gamma and density in this case) can be used
to adjust control settings.  This is probably not the right place for
them; the printer drivers themselves should contain this information.
There's probably no good reason for anything but gamma and density to
be in here.  Gamma refers to the printer's gamma factor; density is the
desired base ink density for the printer.  The Epson driver contains
the density information for each printer at each resolution internally.
An even better driver would adjust density and possibly even gamma for
paper type.  All the more reason not to have that information here.

   If you really are curious about what tags are permitted, please see
`printdefl.l'.  I deliberately want to make this obscure.

   Anyway, here's the definition of the tags that do matter:

 - `printers.xml' tag: `<printer name="LONGNAME" driver="DRIVERNAME">'
     This starts the definition of a printer.  The LONGNAME should be
     something human readable; the DRIVERNAME should consist of
     alphanumerics and hyphens, and be fairly short.  The LONGNAME is
     what will appear in the GUI listing of printers; the DRIVERNAME is
     what is actually used to key into the list of printers.  It is
     legal to have multiple printers with the same driver name.

 - `printers.xml' tag: `<color>'
 - `printers.xml' tag: `<nocolor>'
     Indicates that this printer is capable of color, or is not capable
     of color respectively

 - `printers.xml' tag: `<model value=INT>'
     This defines a model number.  This is passed into the driver,
     which may do whatever it cares to with it--index into a table,
     compute on, or whatever.  This need not be unique.

 - `printers.xml' tag: `<language value=TYPE>'
     This defines what driver module this printer uses.  TYPE should be
     `escp2', `pcl', `canon', or `ps'.

 - `printers.xml' tag: `</printer>'
     This, of course, closes off a printer definition.

   This is handled very ad-hoc.  It's ugly.  But it's reasonably easy to
extend, and it's buzzword-compliant.


automatically generated by info2www version 1.2.2.9