Closed
Bug 312583
Opened 20 years ago
Closed 20 years ago
I can't change the printer spooler
Categories
(Core :: Printing: Output, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: jcea, Unassigned)
References
Details
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b5) Gecko/20051015 Firefox/1.4.1
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b5) Gecko/20051015 Firefox/1.4.1
In Firefox/Thunderbird 1.0.*, when I printed a web/email, I could change the
default "lpr" command to the more apropiate (for me) "kprinter".
In current pre1.5 builds, I can't change the spooler program. I can print fine
from firefox/thunderbird, but I have no control over the spooling process, queue
control, filtering, etc. FF/TB seem to print directly to CUPS via LPR or
similar. I can't change that.
Manipulating the "prefs.js" with a text editor, changing "lpr" to "kprinter"
seems to have no effect.
Reproducible: Always
Steps to Reproduce:
1. Try to print a webpage/email
2. On the printer panel, choose "properties".
3. I can change paper size, margins, etc., but I can't change the command used
internally to print. FF/TB seems to use CUPS directly.
Actual Results:
I have no control over spooler process, queue management, printing cancelation,
filtering, etc.
Expected Results:
I would like to be able to choose the spooling command (for example,
"kprinter"), like in the 1.0.* releases.
Comment 1•20 years ago
|
||
Jesus, in the print dialog, the printers labelled with "CUPS" do not have print
commands that can be edited. Mozilla spools the print job without calling an
external program.
However, the list of printers should include at least one whose name starts with
"PostScript", e.g. "PostScript/default". These printers have print commands you
can edit, just as they always did.
What is the name of the printer you're trying to use (as displayed by mozilla)?
What other printers are available to be selected?
Assignee: nobody → printing
Component: General → Printing
Product: Firefox → Core
QA Contact: general
Version: 1.5 Branch → 1.8 Branch
Kenneth, you are right. I see three printer (I have two real printers):
"CUPS/general", "CUPS/Phaser860" and "Postscript/default".
I can't change the spooling command in any of the three, in Firefox.
Nevertheless, in Thunderbird I can edit the Postscript one just fine.
Perhaps my unsucessfull hand editing of prefs.js had damaged the configuration.
Could you possibly guide me?.
How can I add additional printers?. And delete them?. Do I need to hand-edit the
pref.js?
The relevant prefs.js about Postscript/default:
>>>>>
user_pref("print.printer_PostScript/default.print_bgcolor", false);
user_pref("print.printer_PostScript/default.print_bgimages", false);
user_pref("print.printer_PostScript/default.print_colorspace", "default");
user_pref("print.printer_PostScript/default.print_command", "kprinter");
user_pref("print.printer_PostScript/default.print_downloadfonts", true);
user_pref("print.printer_PostScript/default.print_edge_bottom", 4);
user_pref("print.printer_PostScript/default.print_edge_left", 4);
user_pref("print.printer_PostScript/default.print_edge_right", 4);
user_pref("print.printer_PostScript/default.print_edge_top", 4);
user_pref("print.printer_PostScript/default.print_evenpages", true);
user_pref("print.printer_PostScript/default.print_footercenter", "");
user_pref("print.printer_PostScript/default.print_footerleft", "&PT");
user_pref("print.printer_PostScript/default.print_footerright", "&D");
user_pref("print.printer_PostScript/default.print_headercenter", "");
user_pref("print.printer_PostScript/default.print_headerleft", "&T");
user_pref("print.printer_PostScript/default.print_headerright", "&U");
user_pref("print.printer_PostScript/default.print_in_color", true);
user_pref("print.printer_PostScript/default.print_margin_bottom", "0.5");
user_pref("print.printer_PostScript/default.print_margin_left", "0.5");
user_pref("print.printer_PostScript/default.print_margin_right", "0.5");
user_pref("print.printer_PostScript/default.print_margin_top", "0.5");
user_pref("print.printer_PostScript/default.print_oddpages", true);
user_pref("print.printer_PostScript/default.print_orientation", 0);
user_pref("print.printer_PostScript/default.print_pagedelay", 500);
user_pref("print.printer_PostScript/default.print_pagedelay", 500);
user_pref("print.printer_PostScript/default.print_paper_data", 0);
user_pref("print.printer_PostScript/default.print_paper_height", "297.00");
user_pref("print.printer_PostScript/default.print_paper_name", "A4");
user_pref("print.printer_PostScript/default.print_paper_size", 666);
user_pref("print.printer_PostScript/default.print_paper_size_type", 1);
user_pref("print.printer_PostScript/default.print_paper_size_unit", 1);
user_pref("print.printer_PostScript/default.print_paper_width", "210.00");
user_pref("print.printer_PostScript/default.print_plex_name", "default");
user_pref("print.printer_PostScript/default.print_printer", "PostScript/default");
user_pref("print.printer_PostScript/default.print_resolution_name", "default");
user_pref("print.printer_PostScript/default.print_reversed", false);
user_pref("print.printer_PostScript/default.print_scaling", " 1.00");
user_pref("print.printer_PostScript/default.print_shrink_to_fit", true);
user_pref("print.printer_PostScript/default.print_to_file", false);
user_pref("print.printer_PostScript/default.print_to_filename",
"/home/jcea/mozilla.ps");
<<<<<
Seeing the prefs.js I see definitions about "Postscript/general" and
"PostScript/Phaser860", my printers in the 1.0.* products. But they are not
available in the printer dialogue.
Thanks for yout time and attention.
Comment 3•20 years ago
|
||
Confirming. I'm seeing this too with my daily-use firefox profile, though it
doesn't appear with a clean profile.
1) Open the print dialog.
2) Select "PostScript/default"
3) Click the "properties" button.
Expected: Properties dialog includes a widget for the spooler command.
Actual: Properties dialog doesn't include the spooler command.
The properties dialog uses a series of prefs starting with
"print.tmp.printerfeatures.<printername>" to control which widgets it displays.
I added some dump() calls to
toolkit/components/printing/content/printjoboptions.js, and it looks like the
dialog is getting the wrong printer name. When I selected "PostScript/default"
as a printer, it was looking up prefs using the name "CUPS/i4200". CUPS/i4200
wasn't in the actual list of available printers at the time of the test, though
I do have a set of preferences for it.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Updated•20 years ago
|
Flags: blocking1.8rc1? → blocking1.8rc1-
Comment 4•20 years ago
|
||
In the print dialog, whenever the user selects a printer, a javascript function called setPrinterDefaultsForSelectedPrinter() is called to load settings for that printer (seamonkey and ff/tb have separate copies of the javascript and xul for the print dialog, but the relevant sections seem to be the same). This js function performs three steps:
1) Set the print settings printer name from the dialog printer selector widget.
2) Load settings for the print settings printer name from the device context spec.
3) Load settings for the print settings printer name from preferences. During this last step, print settings printer name is being changed back to whatever was saved in prefs as the last printer used. This is the root cause of the bug.
Later, when the user clicks on the properties dialog, the settings for the print settings printer--ie, the last-used printer--are displayed. If the last-used printer is one that doesn't use a print command, then the print command widget won't be displayed in the printer properties dialog.
In the print dialog, when the user clicks "print" to execute the print job, the onAccept() function reloads the printer name and other settings from the dialog. So the wrong printer name in print settings doesn't have an effect on the actual print job.
The function that performs step 3 is nsPrintOptions::InitPrintSettingsFromPrefs() in gfx/src/nsPrintOptionsImpl.cpp. At <http://lxr.mozilla.org/seamonkey/source/gfx/src/nsPrintOptionsImpl.cpp#1103> it calls ReadPrefs() with a blank printer name and flags of kInitSaveAll. This causes ReadPrefs() to read the pref "print.printer_name" and save that in print settings as the printer name.
Version: 1.8 Branch → Trunk
Comment 5•20 years ago
|
||
Bug 324072 was also opened about this issue, and I think bug 323781 is about the same thing. I've attached a patch to bug 324072 which fixes this bug.
Comment 6•20 years ago
|
||
This should be fixed by the checkin for bug 324072.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Well the same problem is on both branches (1.8 and 1.8.0) so it would be good to get it in there but that will depend on drivers.
Since the patch is already done, I don't know if soliciting blocking 1.8.0.2 and 1.8.1 is the right procedure. Let's try...
Flags: blocking1.8.1?
Flags: blocking1.8.0.2?
Comment 10•20 years ago
|
||
best to ask for blocking on the bug that has the patch though...
Comment 11•20 years ago
|
||
No patch, nothing to approve (e.g. flag the right bug)
Flags: blocking1.8.0.2? → blocking1.8.0.2-
Comment 12•19 years ago
|
||
*** Bug 334419 has been marked as a duplicate of this bug. ***
Updated•19 years ago
|
Flags: blocking1.8.1?
You need to log in
before you can comment on or make changes to this bug.
Description
•