Bug 445349 - Add a zoom magnifier glass widget over the preview canvas.
Summary: Add a zoom magnifier glass widget over the preview canvas.
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Preview-Image (other bugs)
Version First Reported In: 7.4.0
Platform: Other Linux
: NOR wishlist
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-11 17:07 UTC by rwijtvliet
Modified: 2026-01-12 10:47 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 9.0.0
Sentry Crash Report:


Attachments
mockup (176.85 KB, image/jpeg)
2021-11-11 17:07 UTC, rwijtvliet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description rwijtvliet 2021-11-11 17:07:01 UTC
Created attachment 143462 [details]
mockup

SUMMARY
Wenn judging which picture to keep out of several nearly identical ones, sharpness is a main criterium. It's cumbersome to always have to zoom in to judge the sharpness, so a small additional window at 100% zoom would be welcome. I've added a mock-up with that additional feature in the bottom right; see attachment.

I'm aware that lighttable allows for zooming in on the same area of 2 images at the same time, but that's still quite elaborate when dealing with multiple photos of the same scene.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Pop!_OS 21.04
(available in About System)
KDE Frameworks 5.80.0
Qt 5.15.2 (built against 5.15.2)
The xcb windowing system

ADDITIONAL INFORMATION
Comment 1 Maik Qualmann 2021-11-11 18:33:05 UTC
How should the 100% cutout be chosen? The area where the mouse pointer is in the image preview?

Maik
Comment 2 caulier.gilles 2021-11-11 19:20:30 UTC
Preview canvas can be already switched to 100% with a button from status bar, near zoom slider. It's not enough ?

Gilles Caulier
Comment 3 Maik Qualmann 2021-11-11 21:43:15 UTC
I agree with Gilles, a section can be selected in the 100% image preview view. The section is retained when the image is changed and the sharpness can be assessed perfectly. I don't see where the little image in the right sidebar should be an advantage.

Maik
Comment 4 caulier.gilles 2021-11-11 21:50:49 UTC
And look also the railway available on the bottom / right corner of the canvas. A bottom is available to enable the view, where you can select the 100% area visible from the image. 

GIlles Caulier
Comment 5 rwijtvliet 2021-11-12 08:57:14 UTC
Thanks for the quick response.

My reasoning is that the additional smaller 100% preview pane can be used to assess the sharpness, while the main preview pane shows the entire image to assess its composition.

Of course it's currently possible to switch between these two previews by adjusting the zoom. But you have to switch back and forth for each image, as both are important criteria, and that's a pain. 
In addition: if I have 10 images with the same overall composition, the problem is only compounded - I want to assess the quality of each image, not only as it stands on itself, but also in comparison with the other 9 images.

I can even imagine that the sharpness of an image is assessed computationally, and then shown in color coding in the bottom right pane, to be even more accessible.
Comment 6 rwijtvliet 2021-11-12 09:03:42 UTC
As to which section to show in the 100% pane - either where the mouse currently is, or by dragging the section shown in the 100% pane (and adding a 'show in 100% preview' to right-click menu on main preview. In the latter case, when selecting a different photo, the relative position (i.e. 30% from left, 20% from top) of the preview can be retained. I'm not sure what's the best way.
Comment 7 caulier.gilles 2023-05-12 15:44:19 UTC
In fact you want a magnifying glass widget over the preview canvas, following the mouse moves.

Gilles Caulier
Comment 8 caulier.gilles 2023-05-12 15:48:43 UTC
Something like that :

https://www.qt.io/blog/2009/10/07/magnifying-glass

Gilles
Comment 9 caulier.gilles 2023-05-12 15:53:52 UTC
The repository relevant of code from my previous comment is located here :

https://github.com/Tarzanello/graphics-dojo-qt5/tree/master/imgzoom

Gilles
Comment 11 caulier.gilles 2026-01-10 17:31:01 UTC
Hi Maik,

I coded a magnifier tool for the canvas managed by the classes GraphicsDImgItem/View. It start to work but not yet finalized. See my demo here :

https://imgur.com/a/7kWMmTm

Best regards

Gilles
Comment 12 caulier.gilles 2026-01-11 11:09:14 UTC
Maik,

I created a new devel branch to hos this code :

https://invent.kde.org/graphics/digikam/-/commit/35616c509b285a7be4cb7fe54c7862cae65ffed5

Gilles
Comment 13 caulier.gilles 2026-01-11 19:10:35 UTC
Git commit 42b3e44e848596567f64ad089dfc503f308195c8 by Gilles Caulier.
Committed on 11/01/2026 at 19:09.
Pushed by cgilles into branch 'master'.

Preview magnifier tool completed.
FIXED-IN: 9.0.0

M  +2    -1    NEWS

https://invent.kde.org/graphics/digikam/-/commit/42b3e44e848596567f64ad089dfc503f308195c8
Comment 14 caulier.gilles 2026-01-12 10:47:05 UTC
Git commit aafc7e9998fdb01cbe3716711420fa4f85db54f2 by Gilles Caulier.
Committed on 12/01/2026 at 10:46.
Pushed by cgilles into branch 'master'.

Preview Magnifier: add tool size settings

M  +1    -0    core/app/views/preview/itempreviewview.cpp
M  +3    -1    core/libs/settings/applicationsettings.cpp
M  +4    -1    core/libs/settings/applicationsettings.h
M  +3    -1    core/libs/settings/applicationsettings_p.h
M  +12   -2    core/libs/settings/applicationsettings_views.cpp
M  +5    -2    core/libs/widgets/graphicsview/graphicsdimgview.h
M  +12   -2    core/libs/widgets/graphicsview/graphicsdimgview_magnifier.cpp
M  +27   -4    core/utilities/setup/album/setupalbumview.cpp

https://invent.kde.org/graphics/digikam/-/commit/aafc7e9998fdb01cbe3716711420fa4f85db54f2