Bug 104031 - Selected item should stay centered in thumbnail bar
Summary: Selected item should stay centered in thumbnail bar
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Showfoto-Thumbs (show other bugs)
Version: unspecified
Platform: Debian testing Linux
: NOR wishlist
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-04-16 19:42 UTC by Tom Albers
Modified: 2022-02-05 04:57 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 7.6.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Albers 2005-04-16 19:42:30 UTC
Version:            (using KDE KDE 3.4.0)
Installed from:    Debian testing/unstable Packages

It would be nice if the active thumnail in the thumnail bar would stay centered.

Now it happens that you only see part of the selected thumnail when you have a lot of thumnails and going through them with pagedown.
Comment 1 Tom Albers 2005-08-22 21:22:35 UTC
SVN commit 452180 by toma:

Keep the thumbnail completely visible and the next one as well. I heard from the bugreporter that he is extremely happy and will buy a pizza for me.
BUG: 104031


 M  +5 -1      thumbbar.cpp  


--- trunk/extragear/graphics/digikam/libs/thumbbar/thumbbar.cpp #452179:452180
@@ -178,7 +178,11 @@
     d->currItem = item;
     if (d->currItem)
     {
-        ensureVisible(0,item->m_pos);
+        // We want the complete thumb visible and the next one.
+        // find the middle of the image and give a margin of 1,5 image
+        // When changed, watch regression for bug 104031
+        ensureVisible(0, (int)(item->m_pos+d->margin+d->tileSize*.5),
+                      0, (int)(d->tileSize*1.5+3*d->margin));
         item->repaint();
         emit signalURLSelected(item->url());
     }