From mboxrd@z Thu Jan 1 00:00:00 1970 From: swedebugia@riseup.net Subject: Idea: guile-cups-notifier (Was: Re: Improving GUI printing in GuixSD: (python-)system-config-printer, worth adding?) Date: Wed, 16 Jan 2019 07:31:07 -0800 Message-ID: <064825f0d9ccdb2218ac83812ff2ce9e@riseup.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([209.51.188.92]:36699) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gjnAK-0007I3-Ck for guix-devel@gnu.org; Wed, 16 Jan 2019 10:31:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gjnAD-0001Q8-BV for guix-devel@gnu.org; Wed, 16 Jan 2019 10:31:38 -0500 In-Reply-To: List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel Cc: Guix-devel On 2019-01-16 14:43, swedebugia@riseup.net wrote: > Hi > > Today I investigated a bit about this program. > > system-config-printer is a Red hat offspin that is essentially a quick > python hack to be able to say "we have a desktop gui for printer > configuration". > > Is it a useful program you think? Having used it on arch and debian I > found it somewhat buggy, ugly, unintuitive. > > It does not seem to interact with the system bus in order to send > printer errors to the notification area. (I could be wrong about this) > > One thing it does is give you easy access to the queue and to view print > related errors. Although cups errors are usually quite bad if you ask me > and I found I cannot really rely on it for restarting jobs etc. > > CUPS seems to me like in the same category as TeX, it is old, scolded, > overly complicated, error prone and we use and rely on it ONLY because > we lack a well working GNU replacement. > > -- > > system-config-printer depends on pycups and perhaps some polkit > pk-helper. > > Unfortunately I found no build documentation in the repository and it > has not seen a release for a year. > https://github.com/zdohnal/system-config-printer So if system-config-printer is an ugly python hack based on pycups, can we do better in guile? (pycups is 95,9% written in C) https://github.com/molefrog/cupsidity Is an alternative to pycups written in C++ and contains only the basics of the CUPS API. Keeping it simple we could make sure to ONLY add what Guix does not provide: print queue management. The idea is to make guile-cups bindings and a guile-cups-notifier that interacts with CUPS via guile-ffi and does only a few things (and do them well!): * has a daemon running that reads the queue from cups * prints messages to the user via dbus E.g. if the user sends something to the printer it pops up a message "Printing: "document name" - click to cancel." (cancelling a document is a nice feature and needed if the printer is far away) E.g. if an error occurs during printing it pops up a message displaying the error. E.g. "Printing of "document name" failed: No paper found" If printing succeed it prints: "Printing of "document name" finished." Thoughts? -- Cheers Swedebugia