printcap configuration problem

Warren Block wblock at
Sun Aug 3 19:40:35 UTC 2014

On Sun, 3 Aug 2014, Beeblebrox wrote:

>> Both cases are for use with a printer that understands PostScript
>> natively.  A plain LaserJet 2100 does not,
> Mine does, it's the 2100tn model, has native ps level-II
>> Sorry, I don't understand the question.
> Well, my first question was: Why under the current filter setting does 
> lpd scrape or cut 4 lines from the top? I'm able to get the hard copy 
> the way I want it to look by increasing the top margin by 4 lines, 
> save it as a ps file, then lpr the file from command line.

lpd does not mess with the input file, although the filter might.  I 
suspect that this just means you need to supply some margin settings for 
enscript in the psif filter.  See enscript(1).

> The ghostscript comment was referring to previous discussion - sorry 
> for the confusion: If I want to print in r: 300 x 300, the only way 
> that's going to happen is by sending it through ghostscript, if I 
> understand correctly?

No, that's not necessary.  PostScript can be told what resolution to 
use.  A filter would have to append that to the start of the PS program, 
similar to the way duplex can be set.  See this thread for an example:

I have some additional filters on my list of things to add to the 
Handbook, but no idea when I can work on them.

> How could I modify psif so that "lpr -Php2100 -r300" would 
> result in 1. check if ps 2. adjust for one of available resolution 
> options (300 OR 600).

-r is already used by lpr.  Actually, I have not experimented with 
passing through options that way, and don't know if it can be done. 
I'd just define two printers, one for 300DPI and one for 600DPI.

The header code is probably going to be
<</HWResolution[600 600]>> setpagedevice
<</HWResolution[300 300]>> setpagedevice

That might be different on a printer as old as the LJ2100.  It can be 
tested in plain PS files sent directly to the printer.

More information about the freebsd-questions mailing list