Commit 4cb4711b authored by Emmet O'Neill's avatar Emmet O'Neill
Browse files

Freehand Tool: Shift-Vertical Drag can now be used to resize too.

Holding SHIFT while dragging vertically can now also be used to resize the
brush, just like horizontal dragging.
parent 396b4501
......@@ -347,7 +347,9 @@ void KisToolFreehand::continueAlternateAction(KoPointerEvent *event, AlternateAc
const qreal effectiveMaxBrushSize = qMin(maxBrushSize, effectiveMaxDragSize / scaleX);
const qreal scaleCoeff = effectiveMaxBrushSize / effectiveMaxDragSize;
const qreal sizeDiff = scaleCoeff * offset.x() ;
const bool useOffsetX = qAbs(offset.x()) > qAbs(offset.y());
const qreal largerOffset = useOffsetX ? offset.x() : -offset.y();
const qreal sizeDiff = scaleCoeff * largerOffset;
if (qAbs(sizeDiff) > 0.01) {
KisPaintOpSettingsSP settings = currentPaintOpPreset()->settings();
......@@ -409,7 +411,6 @@ void KisToolFreehand::slotDoResizeBrush(qreal newSize)
settings->setPaintOpSize(newSize);
requestUpdateOutline(m_initialGestureDocPoint, 0);
}
QPointF KisToolFreehand::adjustPosition(const QPointF& point, const QPointF& strokeBegin)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment