From owner-freebsd-questions@FreeBSD.ORG Sat Aug 21 05:15:10 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7C331106566C for ; Sat, 21 Aug 2010 05:15:10 +0000 (UTC) (envelope-from remegius@comcast.net) Received: from qmta11.emeryville.ca.mail.comcast.net (qmta11.emeryville.ca.mail.comcast.net [76.96.27.211]) by mx1.freebsd.org (Postfix) with ESMTP id 5D99B8FC0C for ; Sat, 21 Aug 2010 05:15:10 +0000 (UTC) Received: from omta06.emeryville.ca.mail.comcast.net ([76.96.30.51]) by qmta11.emeryville.ca.mail.comcast.net with comcast id wtAZ1e00516AWCUABtFA5U; Sat, 21 Aug 2010 05:15:10 +0000 Received: from remegius.comcast.net ([67.180.204.190]) by omta06.emeryville.ca.mail.comcast.net with comcast id wtF81e00746zqiB8StF9vS; Sat, 21 Aug 2010 05:15:09 +0000 Message-ID: <4C6F60DC.6060307@comcast.net> Date: Fri, 20 Aug 2010 22:15:08 -0700 From: Rem P Roberti User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.9.2.8) Gecko/20100819 Thunderbird/3.1.2 MIME-Version: 1.0 To: Polytropon References: <4C6F2AA2.6060005@comcast.net> <20100821054843.ae15204d.freebsd@edvax.de> <4C6F560C.9080700@comcast.net> <4C6F57A4.2030409@cyberleo.net> <4C6F59B5.7090705@comcast.net> <20100821070151.9ff539f0.freebsd@edvax.de> In-Reply-To: <20100821070151.9ff539f0.freebsd@edvax.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: Printing from Thunderbird X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Aug 2010 05:15:10 -0000 On 08/20/10 22:01, Polytropon wrote: > On Fri, 20 Aug 2010 21:44:37 -0700, Rem P Roberti wrote: >> On 08/20/10 21:35, CyberLeo Kitsana wrote: >>> On 08/20/2010 11:29 PM, Rem P Roberti wrote: >>>> Ah-ha! In my case I am using the bash shell, and I believe the syntax >>>> that is needed for the .bashrc is different than what is used in your >>>> csh.cshrc. Any idea where I can find the appropriate syntax for >>>> variables stored within .bashrc? >>> export PRINTER="Photoshop7760" >>> >>> bash(1) has extensive documentation; as bash is a superset of the bourne >>> shell included in base, sh(1) is likewise useful for reference. >>> >> Well...I kind of thought that the "export" variable was the correct >> one to use, and I entered : >> >> export PRINTER="Photosmart7760" >> >> into both my .bashrc and .bash_profile, [...] > This is correct, but keep in mind that this setting will be > a per-user only setting, allthough it should be sufficient. > With > > $ echo $PRINTER > > you can always check for it. > > > >> [...] but no dice. The printer >> neither shows up in Thunderbird or Firefox > I checked in my Firefox (version 2): The printer's name is just > "PostScript/Default", and when I click "Properties", the following > print command is listed: > > lpr ${MOZ_PRINTER_NAME:+'-P'}${MOZ_PRINTER_NAME} > > In my case, this strangely works, as I don't have $MOZ_PRINTER_NAME > defined anywhere. You can try to simplify the setting to just be > > lpr > > which should then default to $PRINTER. You can also test the > intended behaviour with an example like > > lpr /etc/rc.conf > > which should then - without any trouble - output /etc/rc.conf to > the printer. > > > From my understanding: When Firefox prints, it sends the data > to lpr per pipe. Checking the printer queue right after ^P will > lead to something like this: > > % lpq > Laserjet is ready and printing > Rank Owner Job Files Total Size > 1st poly 982 (standard input) 484630 bytes > > Now as $PRINTER is defined, you don't need -P anymore for all > the lp* tools - only if you want to override the default (e. g. > as I use -PLaserjet-nodup if I intendedly want to force non-duplex > single-sided printing). > > My bad. Adding the above variable to .bashrc does indeed result in the desired effect. For some reason I thought that the printer as named was actually going to shop up in the print menu. Thunderbird and Firefox are now printing fine, and I can print any text file simply by using the lpr command. Thank you all. Cheers... Rem