From owner-freebsd-questions@FreeBSD.ORG Sat Aug 2 13:39:25 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 152FB140 for ; Sat, 2 Aug 2014 13:39:25 +0000 (UTC) Received: from sam.nabble.com (sam.nabble.com [216.139.236.26]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EA0C920C5 for ; Sat, 2 Aug 2014 13:39:24 +0000 (UTC) Received: from [192.168.236.26] (helo=sam.nabble.com) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1XDZWs-0002Wn-Lx for freebsd-questions@freebsd.org; Sat, 02 Aug 2014 06:39:22 -0700 Date: Sat, 2 Aug 2014 06:39:22 -0700 (PDT) From: Beeblebrox To: freebsd-questions@freebsd.org Message-ID: <1406986762673-5934162.post@n5.nabble.com> In-Reply-To: <1406966714419-5934110.post@n5.nabble.com> References: <1405676044178-5929730.post@n5.nabble.com> <53C919E0.6070008@bananmonarki.se> <20140718183958.1864052a@rsbsd.rsb> <20140727221419.35efb9b0@morena.maps.net> <1406966714419-5934110.post@n5.nabble.com> Subject: Re: printcap configuration problem MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Aug 2014 13:39:25 -0000 @Warren: Below is what I have in printcap and the filter file. psif is straight out of the Handbook page. When printing an existing ps file with "$ /usr/bin/lpr -Php2100", the resulting hardcopy has 3-4 lines truncated from the top - I can't figure it out. Secondly, I don't see the point of piping an already ps-formated file through ghostscript, unless it's to adjust print resolution. Is gs smart enough to recognize a ps file and simply (and quickly) modify the ink amount or must it do a complete re-process of the page? hp2100:lp:rm=192.168.1.9:rp=raw:\ :if=/usr/local/libexec/filters/psif:\ :lf=/var/log/lpd-errs:af=/var/spool/lpd/acct:\ :sd=/var/spool/lpd/hp2100:\ :mx=0:sh: # psif: Print PostScript or plain text on a PostScript printer IFS="" read -r first_line first_two_chars=`expr "$first_line" : '\(..\)'` case "$first_two_chars" in %!) # %! : PostScript job, print it. echo "$first_line" && cat && exit 0 exit 2 ;; *) # otherwise, format with enscript ( echo "$first_line"; cat ) | /usr/local/bin/enscript -o - && exit 0 exit 2 ;; esac ----- FreeBSD-11-current_amd64_root-on-zfs_RadeonKMS -- View this message in context: http://freebsd.1045724.n5.nabble.com/printcap-configuration-problem-tp5929730p5934162.html Sent from the freebsd-questions mailing list archive at Nabble.com.