[cups.general] Printing escape sequence to format font size

Johannes Meixner jsmeix at suse.de
Mon Oct 9 01:47:35 PDT 2006


Hallo,

On Oct 3 11:54 Paola wrote (shortened):
> With SuSe Linux Enterprise Server 9 SP3 i have add a printer (TCP/IP)
> like LOCAL RAW DEVICE (HP LaserJet 4000 - PCL5). My program uses some
> sequences of Escape which are only printed correctly if I use:
> ( printf "\033&k2G" ; cat check.txt ) | lp -d hp4000
> How I can to set up the print queue with the automatic Settaggio of the LF?

Don't use a plain raw queue but a queue with a "System V style
interface script", see "man lpadmin", "man 7 filter", and
http://en.opensuse.org/SDB:Using_Your_Own_Filters_to_Print_with_CUPS

The following (untested) bash script should do what you want:
---------------------------------------------------------------------
#! /bin/bash
# activate the next line for debug info in /var/log/cups/error_log
#set -x
# have the input at fd0 (stdin) in any case
[ -n "$6" ] && exec <"$6"
# set up the printer before printing
echo -en "\033&k2G"
# printing
cat -
---------------------------------------------------------------------

For general information see for example
http://en.opensuse.org/SDB:CUPS_in_a_Nutshell

Kind Regards
Johannes Meixner
-- 
SUSE LINUX Products GmbH, Maxfeldstrasse 5      Mail: jsmeix at suse.de
90409 Nuernberg, Germany                    WWW: http://www.suse.de/





More information about the cups mailing list