Operating System - HP-UX
1833285 Members
3142 Online
110051 Solutions
New Discussion

Generic landscape printing command for HP-UX

 
Ira Landis
New Member

Generic landscape printing command for HP-UX

How can I format an lp command to print a file landscape (132 wide). Ultimately I would like to print more than 132 characters wide, but not required.

Any assistance would be greatly appreciated.
5 REPLIES 5
Andreas Voss
Honored Contributor

Re: Generic landscape printing command for HP-UX

Hi,

if you have configured a PCL printer (LaserJet, DeskJet) you could use the following option:
lp -olandscape

Greetings

Andrew
Rick Garland
Honored Contributor

Re: Generic landscape printing command for HP-UX

If you are wanting to print 132 characters in portrait mode, you would need to change the font. Software such as enscript will allow the ability to format to your desires.
Also check the command 'pr'. Not sure but I think it allows changing of the fonts as well.

Check the printer interface files (/etc/lp/interface) to see if the HW is set to recognize options to the lp command. lp -o. Some printers will have the ability to change the font.
Alan Riggs
Honored Contributor

Re: Generic landscape printing command for HP-UX

The above answers are correct. If the printer is defined in jetadmin, though, you will want to examine the driver in /etc/lp/interfaces/model.orig to determine the appropriate landscape flag. For most HP printers (all that I have encountered) the -o landscape option will work.
Tim Malnati
Honored Contributor

Re: Generic landscape printing command for HP-UX

Your subject line suggests that you are using a generic (dumb) print driver, This driver performs no formatting of any kind, no matter what options you throw at it. If you are using this driver, I suggest that you pipe the file through the pr command prior to piping it to lp. pr allows adjustment of PAGE_WIDTH, PAGE_LENGTH, margins, etc to suit your needs.
Rita C Workman
Honored Contributor

Re: Generic landscape printing command for HP-UX

Well a little will depend on your font setting, but to print landscape add the print option -olandscape;
if you need to compress it you can do a -oc. So your line will look something like this:
lp -dprinter_name -olandscape -oc print_file
Regards,