[LinuxFocus-icon]
LinuxFocus article number 380
http://linuxfocus.org

Gerrit photo
by Gerrit Renker
<gerrit.renker(at)gmx.de>

About the author:
Gerrit didn't like any computers at all until he tried C and Linux.

LF tip: Using Acrobat 7 with kde and kprinter

[Illustration]

Abstract:

This is a small tip. From now on LinuxFocus will have at least one new tip every month. If you have some ideas for a new tip then send them to guido("at"sign)linuxfocus.org

_________________ _________________ _________________

 

Problem

Acrobat 7 is available and is a nice PDF viewer. Unfortunately, when printing it removes the output file before the KDE system (kprinter) has completed the print job.  

Solution

Put a script in between which creates a temporary file for the postscript output and removes it afterwards.
#!/bin/sh
# save this as /usr/local/bin/printerScript
# and make it executable with: chmod 755 /usr/local/bin/printerScript
## create temporary file
tmp="/tmp/postscript-print-$$.ps"
[ -f "$tmp" ] && exit 1
## save the file to a new name which will not be deleted by acroread.
## the first argument is the file name of the postscript file
cp  "$1"  $tmp
## start the KDE printer frontend on this file
kprinter  $tmp
## clean up afterwards
rm -f     $tmp
##
Here is a screenshot of the printer config panel in acroread:
[acroread printer config panel]


Webpages maintained by the LinuxFocus Editor team
© Gerrit Renker
"some rights reserved" see linuxfocus.org/license/
http://www.LinuxFocus.org
Translation information:
en --> -- : Gerrit Renker <gerrit.renker(at)gmx.de>

2005-06-19, generated by lfparser_pdf version 2.51