On Thu, 24 Feb 2000, Aussie wrote:
>
> From: "Peter Samuel" <[EMAIL PROTECTED]>
> Date sent: Thu, 24 Feb 2000 14:25:02 +1100 (EST)
> Subject: Re: [SLUG] HP Printer codes
>
> > On Thu, 24 Feb 2000, Aussie wrote:
> >
> > >
> > > My father writes cashbook software that sends plain text direct to
> > > the printer, and although most printers use the standard codes for
> > > bold, condensed, underline etc, HP printers don't. I'm looking at
> > > getting the correct printing codes to start and stop the following:
> > >
> > > Bold
> > > Condensed (17cpi)
> > > Double Width
> > > Underline
> > > 10/12/17 cpi
> >
> > There ain't no such thing as standard when it comes to printers.
> > You're probably talking about Epson ESC/2 codes and HP's don't support
> > those.
>
> IBM codes actually.
>
> > Then you've got the issue of which HP printer you've got. Most support
> > some variant of PCL (all which are different), some support other
> > command codes only/too.
>
> HP Deskjet 670C. My apologies.
On the assumption the the 670C supports some variant of PCL (which it
seems to if my very quick look at the ghostscript 6.0 driver is
correct) then try the following (ESC is ASCII character 27, the other
characters as ASCII - ie 7B is a 7 followed by a B)
Primary Font Stroke Weight
Ultra Thin ESC(s-7B
Extra Thin ESC(s-6B
Thin ESC(s-5B
Extra Light ESC(s-4B
Light ESC(s-3B
Demi Light ESC(s-2B
Semi Light ESC(s-1B
Medium (book or text) ESC(s0B
Semi BOld ESC(s1B
Demi Bold ESC(s2B
Bold ESC(s3B
Extra Bold ESC(s4B
Black ESC(s5B
Extra Black ESC(s6B
Ultra Black ESC(s7B
Underline
Enable Fixed ESC&d0D
Enable Floating ESC&d3D
Disable ESC&d@
Primary Pitch
# Characters/inch ESC(s#H # == your number, eg 14
Set pitch mode
10.0 ESC&k0S
Compressed (16.5-16.7) ESC&k2S
Elite (12.0) ESC&k4S
Primary Style
Upright (solid) ESC(s0S
Italic ESC(s1S
Condensed ESC(s4S
Condensed Italic ESC(s5S
Compressed (extra condensed) ESC(s8S
Expanded ESC(s24S
Outline ESC(s32S
Inline ESC(s64S
Shadowed ESC(s128S
Outline Shadowed ESC(s160S
Regards
Peter
----------
Peter Samuel [EMAIL PROTECTED]
Technical Consultant or at present:
eServ. Pty Ltd [EMAIL PROTECTED]
Phone: +61 2 9206 3410 Fax: +61 2 9281 1301
"If you kill all your unhappy customers, you'll only have happy ones left"
--
SLUG - Sydney Linux Users Group Mailing List - http://www.slug.org.au
To unsubscribe send email to [EMAIL PROTECTED] with
unsubscribe in the text