printcap configuration problem

Polytropon freebsd at edvax.de
Fri Jul 18 23:19:51 UTC 2014


On Fri, 18 Jul 2014 09:55:48 -0600 (MDT), Warren Block wrote:
> In practice, it may be somewhat involved.  Unless you change models of 
> printers frequently, it is probably easier to just manually set up the 
> filter to do what is desired.

An existing printer configuration can be used to create
a new one, or a variation (for example the same printer
with and without duplex, or the use of tray 2, 3 or 4
instead of the default -> different printers to the
system, so it's easy to select features according to
the printer name). This can be done with individual
printer filters (for PS + adding features like paper
format definition, duplex or tray selection; PS to
PCL; PS to Splix or whatever you need) stored as
individual files. The use of $PRINTER makes it easy
to switch the default printer - /etc/printcap doesn't
need to be modified and "rebuilt" (cap_mkdb).

For example, I have those:

	/opt/libexec/ps2pcl-dup.sh
	/opt/libexec/ps2pcl-nodup.sh
	/opt/libexec/ps2splix.sh

They correspond to "Laserjet" (default per $PRINTER),
"Laserjet-nodup", and "Samsung". The really fantastic
thing is that you can name the printers as you wish,
representing brand, model, features, or even location.
:-)



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...


More information about the freebsd-questions mailing list