[Digikam-devel] [Bug 103645] zoom in with rectangle tool selection
Gilles Caulier
caulier.gilles at gmail.com
Mon Mar 26 10:30:09 BST 2007
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
http://bugs.kde.org/show_bug.cgi?id=103645
------- Additional Comments From caulier.gilles gmail com 2007-03-26 11:30 -------
SVN commit 646267 by cgilles:
digikam from trunk : patch from Arnd Baecker to use a zoom multiplier adapted to the current zoom factor instead to use a constant zoom step.
CCBUGS: 103645
M +6 -6 canvas.cpp
--- trunk/extragear/graphics/digikam/utilities/imageeditor/canvas/canvas.cpp #646266:646267
@ -76,7 +76,7 @
public:
CanvasPrivate() :
- tileSize(128), minZoom(0.1), maxZoom(10.0), zoomStep(0.1)
+ tileSize(128), minZoom(0.1), maxZoom(10.0), zoomMultiplier(1.2)
{
rubber = 0;
pressedMoved = false;
@ -121,7 +121,7 @
double zoom;
const double minZoom;
const double maxZoom;
- const double zoomStep;
+ const double zoomMultiplier;
QToolButton *cornerButton;
@ -849,12 +849,12 @
bool Canvas::maxZoom()
{
- return ((d->zoom + d->zoomStep) >= d->maxZoom);
+ return ((d->zoom * d->zoomMultiplier) >= d->maxZoom);
}
bool Canvas::minZoom()
{
- return ((d->zoom - d->zoomStep) <= d->minZoom);
+ return ((d->zoom / d->zoomMultiplier) <= d->minZoom);
}
bool Canvas::exifRotated()
@ -867,7 +867,7 @
if (maxZoom())
return;
- setZoomFactor(d->zoom + d->zoomStep);
+ setZoomFactor(d->zoom * d->zoomMultiplier);
}
void Canvas::slotDecreaseZoom()
@ -875,7 +875,7 @
if (minZoom())
return;
- setZoomFactor(d->zoom - d->zoomStep);
+ setZoomFactor(d->zoom / d->zoomMultiplier);
}
void Canvas::setZoomFactor(float zoom)
More information about the Digikam-devel
mailing list