Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting personal default printer #133

Closed
AHeinlein opened this issue Apr 3, 2019 · 2 comments
Closed

Setting personal default printer #133

AHeinlein opened this issue Apr 3, 2019 · 2 comments

Comments

@AHeinlein
Copy link

Until at least the version contained in Debian 8 (1.4.6), it was possible to set a remote shared printer as a personal default. This is different from a system default and requires no admin privileges, it sets the default printer in ~/.cups/lpoptions.
It seems that this does not work in Debian 9 (system-config-printer 1.5.7) anymore. The context menu item for this is grayed out - in fact everything is grayed out except for "Show printer queue". If I set the default printer manually with 'lpoptions -d', then system-config-printer reflects that change with a star.
I don't know if this has anything to do with the way the printers are shared - all printers are manually configured on a central print server, which is using the legacy cups browsing protocol to share out the printers to the clients.

@AHeinlein
Copy link
Author

Unfortunately, I got no answer. I tried to debug the problem myself.

I found this in system-config-printer.py:

userdef = userdefault.UserDefaultPrinter ().get ()

if (n != 1 or
            (userdef is None and self.default_printer == name)):
            set_default_sensitivity = False
        else:
            set_default_sensitivity = True
        self.ui_manager.get_action ("/set-default-printer").set_sensitive (
            set_default_sensitivity)

This is part of the function dests_iconview_selection_changed (self, iconview)

I guess this is intended to enable the context menu item "Set as default" when exactly one printer is selected ("n != 1"). Unfortunately, from my debugging runs, that function is called only once on startup (with n == 0, obviously) and then never again.

If I force that menu item to be enabled by setting
self.ui_manager.get_action ("/set-default-printer").set_sensitive ( True)

then that menu item works as expected.

This is no real solution, of course, but if someone could find out why that function is not called when it ought to, this bug could probably be fixed.

@zdohnal
Copy link
Member

zdohnal commented Jan 20, 2020

Hi,
it could be connected to apple/cups#5684 and apple/cups#5683

@zdohnal zdohnal closed this as completed Apr 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants