[cups.general] Problems printing PDF files through cups.

Gerald Britton gerald.britton at gmail.com
Thu Sep 27 13:59:37 PDT 2007


As you surmised, my ultimate goal for this pdf is to print it
landscape and scaled to fill the page (landscape orientation) as best
as possible.  If I understand you correctly, there is currently no
good way to do that via cups.

Is that right?

On 9/27/07, Kurt Pfeifle <k1pfeifle at gmx.net> wrote:
> OK, so I now looked up the first two posts of your exchange after I
> could not attend any more to this topic, and found your link to the
> example PDF.
>
> I ran the filter manually like this (on *my* system, which uses the
> original CUPS-style pdftops):
>
>     /usr/lib/cups/filter/pdftops \
>                                  "1" \
>                                  "" \
>                                  "1" \
>                                  "fitplot=true PageSize=Letter" \
>                                  e002379200.pdf \
>                                | tee pdftopsfiltered-fitplotted-lettersized.ps
>
> I'll mail you the result in private mail. It looks perfect to me.
>
> I noticed that you wanted to apply "landscape" to your options. In
> gneral, this is not a good idea for PDF printing. It will just rotate
> the image by 90 degree, but it will not rotate the medium. Normally,
> "fitplot" does alread take care of fitting the image as good as you
> can get it. Adding "landscape" to the options will just destroy your
> likely intention of what you want to see on the printout.
>
>
> Kurt Pfeifle wrote:
> > Gerald Britton wrote:
> >> OK -- I'll need a bit of help.  I tried:
> >>
> >> $CUPS_SERVERROOT='/etc/cups/' /usr/lib/cups/filter/pdftops.new my.pdf
> >
> >
> > Unless the '$' above is coming from your prompt, this is the wrong way
> > to set the environment variable on the commandline....
> >
> > And the command itself - you should call it like adviced by this output
> > (occurs when running the filter without any arguments):
> >
> >   kurt at lx50:~> /usr/lib/cups/filter/pdftops
> >   Usage: pdftops job user title copies options [filename]
> >
> > This translates to (for example):
> >
> >   /usr/lib/cups/filter/pdftops "1" "dummy" "dummy" "1" "dummy" my.pdf
> >   /usr/lib/cups/filter/pdftops "1" "" "" "1" "" my.pdf
> >
> > And with some environment variables set (no '$' please!):
> >
> >   CUPS_SERVERROOT=/etc/cups/ \
> >   PPD=/etc/cups/ppd/yourprintername.ppd \
> >         /usr/lib/cups/filter/pdftops "911" "gerald" "testing pdf printing" "1" "dummy" /path/to.pdf \
> >       | /usr/lib/cups/filter/pstops  "911" "gerald" "testing pdf printing" "1" "dummy" \
> >       | tee /tmp/filtered_output-to_be_sent_to-helge.ps
> >
> > However, since you want to see results for "fitplot" and some specific
> > media size (I don't remember which), you'll want to set these options
> > on the commandline in ${5} (and you likely don't need CUPS_SERVERROOT
> > set in your use case -- but PPD for sure!):
> >
> >   PPD=/etc/cups/ppd/yourprintername.ppd \
> >         /usr/lib/cups/filter/pdftops "1" "gerald" "pdftest" "1" "fitplot=true PageSize=Letter" my.pdf \
> >       | /usr/lib/cups/filter/pstops  "1" "gerald" "pdftest" "1" "fitplot=true PageSize=Letter" \
> >       | tee /tmp/filtered_output-to_be_sent_to-helge.ps
> >
> > For a first quick look, you can also pipe it into a PostScript viewer:
> >
> >   PPD=/etc/cups/ppd/yourprintername.ppd \
> >         /usr/lib/cups/filter/pdftops "1" "dummy" "dummy" "1" "fitplot=true PageSize=Letter" my.pdf \
> >       | /usr/lib/cups/filter/pstops  "1" "dummy" "dummy" "1" "fitplot=true PageSize=Letter" \
> >       | gv -
> >
> >
> >
> > BTW, here is the list of *all* env params proviced cupsd for all running
> > filters and backends to see and pick up if they need to:
> >
> > CUPS_CACHEDIR
> > CUPS_DATADIR
> > CUPS_DOCROOT
> > CUPS_FONTPATH
> > CUPS_REQUESTROOT
> > CUPS_SERVERBIN
> > CUPS_SERVERROOT
> > CUPS_STATEDIR
> > LD_LIBRARY_PATH
> > LD_PRELOAD
> > PATH
> > SERVER_ADMIN
> > SOFTWARE
> > TMPDIR
> > USER
> > CUPS_SERVER
> > CUPS_ENCRYPTION
> > IPP_PORT
> > CHARSET
> > LANG
> > PPD
> > RIP_MAX_CACHE
> > CONTENT_TYPE
> > DEVICE_URI
> > PRINTER
> > FINAL_CONTENT_TYPE
> >
> >
>
>
>
> --
> Kurt Pfeifle
> System & Network Printing Consultant ---- Linux/Unix/Windows/Samba/CUPS
> Infotec Deutschland GmbH  .....................  Hedelfinger Strasse 58
> A RICOH Company  ...........................  D-70327 Stuttgart/Germany
> _______________________________________________
> cups mailing list
> cups at easysw.com
> http://lists.easysw.com/mailman/listinfo/cups
>





More information about the cups mailing list