OpenPrinting News - July 2022
New web pages about our work
At Canonical I got told some weeks ago that someone asked what Canonical is doing for printing with Linux. The person seems not having been aware that Canonical is paying me to lead OpenPrinting full-time.
This brought us to the idea to soon post a Ubuntu Blog article and to support such an article we need more detailed information about what OpenPrinting is doing, to link it from there and also partially re-post it in the blog.
Therefore I have decided to add three articles to our static web site (not the News and Events blog series here):
- How did this all begin?
- Our principal achievements
- What we are currently doing
The first is derived from my blog article about how I got started with OpenPrinting, the second one is about what we have achieved in all the time, and the third will be about what we are currently doing. The first two are already available (simply follow the links) and the third I will write soon after I an back from GUADEC.
The new pages are all linked from our “About Us” page.
GUADEC 2022 in Guadalajara in Mexico is approaching! Next week we will celebrate the 25th anniversary of GNOME!
It is the first time for me to attend a GUADEC and also the first time for me to visit Mexico.
In my talk (July 21, 14:20 - 15:00 local time, Bosch Auditorium) I will spread the news about our GSoC work on the “Printers” module of the GNOME Control Center and on the GTK print dialog and also introduce the GNOME Community into the New Architecture of printing and scanning (Update: slides).
You will probably often enough find me at the Canonical booth (or better gathering table, see last month’s news).
If you cannot make it to Guadalajara in Mexico but to Berlin, you can get to a satellite event, the Berlin Mini-GUADEC 2022 in the C-Base and meet Berlin’s/Europe’s GNOME community and besides local sessions, hackfests, … also have a public viewing of the complete GUADEC. And some talks of the GUADEC are even performed in Berlin and transmitted live to Mexico. This is the wonderful world of hybrid (in-person + online) conferences!
Google Summer of Code 2022
Now we are one month into the coding period of the Google Summer of Code 2022 and all our 8 contributors are doing great work!
All of them have posted a little summary of what they have done in our group chat on Telegram:
Converting Braille embosser support into a printer application
Contributor: Chandresh Soni
Mentors: Till Kamppeter, Samuel Thibault
I researched the existing implementation of Braille in cups-filters and how things operate to have a general concept of how braille embossers work and what functionality they bring. I learned about liblouis and ImageMagick, which are used to transform basic text or images to Braille. I’ve also configured a virtual BRF printer. Now I’m attempting to implement the current filter features, which is converting old shell scripts to C.
Scanning Support in PAPPL
Contributor: Deepak Khatri
Mentors: Till Kamppeter, Michael Sweet, Dheeraj Yadav, Deepak Patankar
I have already looked over PAPPL code and some implementations of it, and it is functioning well. I’ve also seen the PAPPL scanning work that Bhavna Kosta and others have done in the past. I’m currently going through the current PAPPL scanning issues. I’ll try to fix some of the issues in the approaching days as I continue working.
Adding Common Print Dialog Backends (CPDB) support to existing Print Dialogs
Contributor: Gaurav Guleria
Mentors: Till Kamppeter
Hello. I have been working on writing the GTK CPDB print dialog backend, and it’s going good. It has been a bit slow, as there is no online documentation regarding it and I have to constantly refer the GtkPrintBackendCups and GtkUnixPrintDialog files along with various others. Some of the files aren’t even commented and follow old Gtk code conventions, so it takes some time to understand them (I even talked to Emmanuele Bassi about this). Nevertheless, due to the progress I had made earlier as well as putting in some extra hours, I will be able to complete it by the end of first month of GSoC as proposed in the timeline. I plan to finish it by this week, so I can fix any bugs or continue with the qt backend.
I just have to add support for multiple backends, configure media-margins and borderless option properly, and add a few more things.
I also fixed some more issues with the cpdb-backend.
Gaurav’s GitHub repository
GNOME Control Center GUI for discovering non-driverless printers and finding suitable Printer Applications for them
Contributor: Mohit Verma
Mentors: Till Kamppeter, Michael Sweet, Pranshu Kharkwal, Divyasheel, Deepak Patankar
Hello all, I am currently working on updating the discovery of devices in cups-pk-helper.We will use PAPPL, Printer apps, and lpinfo (as long as it is accessible) in the new approach of device discovery .I had to understand the current functions of cups-pk-helper and the general architecture of G-C-C, which was using it to locate and configure printers.I will try to complete this by next week.After that, I will be working on creating a GUI for printer application set up dialog whose design is ready. I will be sharing the design on the link given below once I am done updating cups-pk-helper. One of the most challenging task for me till now was to use gnome-builder to build current branch of G-C-C. There were too many dependency errors and other weird errors while building it.I had to ask for help at several Gnome IRC channels and even creating a issue at gnome-builder gitlab’s page.Finally, I was able to build it successfully after a lot of errors and using few tricks suggested by Christian Hergert(maintainer of gnome-builder).Here’s the link for discussion on the new printer dialog.
Issue report with discussion on Mohit’s work.
Scanning Support in PAPPL with eSCL Support
Contributor: Rishabh Maheshwari
Mentors: Till Kamppeter, Michael Sweet, Dheeraj Yadav, Deepak Patankar
I have completed learning about both AirSane and PAPPL and have marked the important files and some other related files in them and I have prepared short notes for the description and usage of these files. Currently, I am trying to use the code from AirSane and use it in PAPPL in one of the scan functions to make our eSCL parser by making the required changes in it in.
Add Avahi calls for discovering and resolving driverless IPP printers and Optimize the processes
Contributor: Sachin Thakan
Mentors: Till Kamppeter, Michael Sweet, Deepak Patankar
Hi all, until now I was doing online reading and trying to understand the implementation for service discovery using avahi and bonjour. From this week I starting to work on segregating the tasks of service browse and service resolve and will try to finish the utility for at least one of them and subsequently make a push.
Make a native Printer Application from Gutenprint
Contributor: Sahil Kumar Dhiman
Mentors: Till Kamppeter, Michael Sweet, Solomon Peachy, Robert Krawitz
I have been actively working to understand the PAPPL framework. I have learnt basics of PAPPL and proceeded to knowing the libgutenprint library. I had made myself familiar with the most of the APIs. Having read and understood the workflow of hp_printer_app I have begun modifying the code for Gutenprint Printer Application. The hard task of getting the capabilities of printer using the libgutenprint library has been almost completed. I am also finishing my code after which I will be working on printer admin web interface.
All the documentation will also be updated as time progresses.
Sahil’s GitHub repository
Create new printer setup tool for the GNOME Control Center
Contributor: Shivan Mishra
Mentors: Till Kamppeter, Pranshu Kharkwal, Divyasheel, Deepak Patankar
Hello all, I have been working on modifying Divyasheel’s code for adding functionality to list IPP printing services in the main panel along with CUPS queues. I plan to finish it by this week so that I can move over to adding IPP Device Configuration System Service in the base hybrid module. Other than this, I have also been working on removing widget for setting of drivers (PPD) in the Printer Details dialog for printers advertised as IPP services over DNS-SD.
Feature requests so far:
- #1877: Improve setting of IPP options
- #1878: Allow to add new printers via Printer Applications
- #1879: Do not show setting of drivers for IPP printers
- #1911: Printers: Make adminurl available for IPP printers
CUPS Snap and snapd printing interface
CUPS Snap in the Snap Store
cups snapd interface is now fully working as documented!
The bugs we told about last month are all fixed and appropriate CUPS Snap and snapd versions are released. Also the CUPS Snap is now auto-connecting the system’s
cups-control interface. So snappers only need to follow the instructions in the mentioned documentation to use the
cups interface in their apps and users of applications plugging the
cups interface can just print.
Note that there is still no further application using the
cups interface except the first two, especially Firefox, Chromium, and LibreOffice did not switch over to it yet.
Approaching cups-filters 2.0
Continuing the restructuring to have libppd depend on libcupsfilters instead of libcupsfilters depend on libppd, as introduced in May. Continuing to restructure the code to separate the siamesian twins of the filter functions and PPD file support:
- Made the
cfFilterImageToPDF()filter functions free of PPD file support and created appropriate
ppdFilter...()wrapper filter functions in libppd for them.
- Also had a look into the
cfFilter...ToPS()filter functions but they will not get converted but completely moved over to libppd, considering not only PPD files obsolete but also the PostScript format (at least when not used in a PostScript printer driver with PPD).
- Tested handling of media size, margins, and page geometry and found some issues. Did several improvements on the
cfGenerateSizes()functions to solve the problems.
- Added support for page size variants in PPD files (
A4.Duplex, … differences in margins, sometimes even a bit in the size dimensions)
- Now we are also matching of custom page sizes and pages rotated by 90 degrees.
- Support for the Duplex (
- Support for using the sizes of the input file’s pages when not explicitly requesting a page size, no page scaling (
page-scaling=none), and no special layout features like N-up or booklet printing. This allows documents with differently sized pages to be printed.
- When working on the
cfFilterGhostscript()filter function bumped into problems with Ghostscript’s
cupsoutput device. It allows supplying the backside orientation for duplex, the need of software copies, and the CUPS Raster version only via PPD files, so added appropriate functionality for setting these parameters without PPD file to the Ghostscript device in the Ghostscript upstream repository.
- Have the
cfFilterImageToPDF()sharing the JCL/PJL support code for classic native PDF printers.
Remaining filter functions to be converted:
cfFilterUniversal(). I still need to check whether to convert also
cfFilterTextToText(). So we come close to cups-filters 2.x.
Snap Store Overview
From OpenPrinting we have already 6 Snaps in the Snap Store:
|ps-printer-app||PostScript Printer Application||2313|
|ghostscript-printer-app||Ghostscript Printer Application||1482|
|hplip-printer-app||HPLIP Printer Application||4864|
|gutenprint-printer-app||Gutenprint Printer Application||4128|
Currently released is 2.4.2.
There will be further bug fix releases in the 2.4.x series. Some bug fixes were done during the last month, see changes below.
Ubuntu Jammy Jellyfish (22.04 LTS) comes with 2.4.1. Ubuntu Kinetic Kudu (22.10 will most probably come with a later 2.4.x.
The CUPS Snap and our CUPS-driver-retro-fitting Printer Application Snaps use the current GIT master of CUPS.
Changes in CUPS v2.4.3 (TBA) ---------------------------- - Fixed the `device_uri` invalid pointer for driverless printers with `.local` hostname (Issue #419) - Use localhost when printing via printer application (Issue #353) - Now localize HTTP responses using the Content-Language value (Issue #426)
Currently released is 1.28.15.
We are continuing to restructure the code to separate the siamesian twins of the filter functions and PPD file support and after that we will finally polish and bug-fix the code for the 2.0.0 release.
See above for more details.
The re-structuring made me not doing any further bug fixes on cups-filters, so there is also nothing to backport to 1.x.
Ubuntu Jammy Jellyfish (22.04 LTS) comes with cups-filters 1.28.15. Ubuntu Kinetic Kudu (22.10 will be the first Ubuntu coming with cups-filters 2.x.
The CUPS Snap currently uses cups-filter’s GIT master (2.x). The Printer Application Snaps also use the current GIT master of cups-filters.
Currently released is 1.2.1.
In the last month only some minor bug fixes got done, also fixes for libcups3 (CUPS 3.x) compatibility, and addition of translations from Weblate.
I have started to work on adding the new PAPPL 1.2.x features (SNMP-based supply level readout, localization/human-readable strings for options/attributes) to pappl-retrofit. See above.
All the CUPS-driver-retro-fitting Printer Applications in the Snap Store (see above) use the current GIT master of PAPPL, so they contain all the latest fixes and improvements.
See also the currently open and closed issues of PAPPL.