Paperwork 2.2: testing phase

Hello,

Good news everyone ! What-will-be-Paperwork-2.2 has entered testing phase.

Testing phase is about testing Paperwork but also about translating it. Testing phases usually last about a month or so.

Future Paperwork 2.2 is now in the branch ‘testing’.

If you use Linux, you can download the appimage or get it using Flatpak:

flatpak --user uninstall work.openpaper.Paperwork  # if it is already installed
flatpak --user install https://builder.openpaper.work/paperwork_testing.flatpakref

If you use Windows, you can install it thanks to the installer: testing’s installer

What’s New ?

The main changes are:

  • Use of PNG images instead of JPEG images by default (see below for details)
  • 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.

And of course new bugs to replace older ones :slight_smile:

As usual, more detailed list of changes can be found in the files */ChangeLog in the Git repository.

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 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

So What Now ?

There are still many things that need to be done before releasing Paperwork 2.2. Of course contributions are welcome.

All the changes below will go directly to the Git branch ‘testing’. I will periodically merge the changes from the branch ‘testing’ to the branch ‘develop’.

Testing and stabilization

Feel free to test it and report any bug you find on the bug tracker or using the integrated bug report system.

Translations

Translations can be done in Weblate . You can freely register on it.

There are 6 components to translate:

After 1 hour without changes, Weblate will automatically commit the translations in Git (branch testing). This commit will trigger a rebuild of Paperwork with the new translations. Then, by installing the testing version as describe above, you can check your translations in their final context before the final release.

If you need contexts or screenshots for some translations, don’t hesitate to ask me, either in the Paperwork category of this forum or by email. Beware that if you just add comments on Weblate, I am not notified.

If you want to translate Paperwork in languages that are not yet enabled in Weblate, just tell me and I’ll enable them.

Thanks in advance for any help you can provide,

Best regards,