Paperwork 2.2.1

Hello,

Good news everyone, Paperwork 2.2.1 is out !

What’s new ?

  • IMPORTANT: PNG are now the default image format for scanned documents (see below for details).
  • IMPORTANT: Due to packaging difficulties, Pypi packages won’t be updated anymore. I’m assuming that nobody ever used them anyway. If you’re using them, please reach out.
  • setup.py have been replaced by pyproject.toml.
  • Added dependency: rich
  • Dropped dependency: python-levenshtein
  • GTK: document list has been optimized.
  • Rendering: optimization: use of cairo.ImageSurface.create_from_data() now that it’s available instead of the old hack used before.
  • paperwork-cli: Rich has been used to make the output of some of the commands even more kick-ass.
  • paperwork-cli export has now clearer error messages.

Known bug

On Windows, in the dialog “about”, the wrong version is displayed (0.1.xxx instead of 2.2.2.xxx). This is being investigated. It’s also likely that the notifications for new versions won’t work either.

IMPORTANT: Switch from JPEG to PNG for new pages

Starting with 2.2, Paperwork will now use PNG instead of JPEG by default.

Existing files won’t be converted (no point). But new files (scans, image imports, etc) will appear in the work directory as paper.X.png instead of paper.X.jpg. This change means that images will take much more disk space from now on.

Why ?

FeRD (Frank Dana) posted a convincing rationale on Gitlab for this change . The goal is to improve OCR quality by not losing data due to compression.

Compatibility

Paperwork 2.2 is able to use work directories created with Paperwork 2.1. No conversion are required at all.
However, beware that Paperwork 2.1 won’t be able to process correctly work directories modified by Paperwork 2.2 !

Swiching back to JPEG

  • What if you need to keep working on the same work directory with both Paperwork 2.1 and 2.2 ?
  • What if you don’t have enough disk space for PNG ?

From the command line, you can change the configuration to switch back to JPEG. This setting is shared between paperwork-gtk, paperwork-cli and paperwork-json and will persist across updates.

Linux

paperwork-cli config put model_img_format str JPEG
paperwork-cli config put model_img_overlay_format str JPEG

Flatpak

flatpak run --command=paperwork-cli work.openpaper.Paperwork config put model_img_format str JPEG
flatpak run --command=paperwork-cli work.openpaper.Paperwork config put model_img_overlay_format str JPEG

Windows

paperwork-json config put model_img_format str JPEG
paperwork-json config put model_img_overlay_format str JPEG

Changelogs

As usual, detailed ChangeLogs can be found here:

Best regards,