Patch: tool order
Sander Koning
sanderkoning at kde.nl
Sat Sep 9 08:18:47 CEST 2006
Hi,
Thanks to Bart and Thomas for pointing out the way the tools are ordered, I
could do some fiddling on the train yesterday night to prevent me from getting
bored ;)
The attached patch should serve to restore the order of the tools on the Krita
toolbar to what they were in 1.5, with the new tools in 1.6 added at the end of
their respective tool sections. Almost every row of 2 tool buttons now contains
similar tools again, making it easier to find one's way.
To make the transform tool section look better, I've done a slight change there:
the transform tool is moved down so that the transform and perspective transform
are on one row.
Are there objections to applying?
Cheers,
--
Sander Koning (askie) | sanderkoning - at - kde -.- nl
KDE Nederland | http://www.kde.nl/
KOffice & Krita | http://koffice.org/ & http://koffice.org/krita/
----------------------------------------------------------------------------
-------------- next part --------------
Index: tool_filter/kis_tool_filter.h
===================================================================
--- tool_filter/kis_tool_filter.h (revision 582360)
+++ tool_filter/kis_tool_filter.h (working copy)
@@ -44,6 +44,7 @@
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_FREEHAND; }
+ virtual Q_UINT32 priority() { return 1; }
virtual QWidget* createOptionWidget(QWidget* parent);
public slots:
Index: tool_perspectivetransform/kis_tool_perspectivetransform.h
===================================================================
--- tool_perspectivetransform/kis_tool_perspectivetransform.h (revision 582360)
+++ tool_perspectivetransform/kis_tool_perspectivetransform.h (working copy)
@@ -57,7 +57,7 @@
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_TRANSFORM; }
- virtual Q_UINT32 priority() { return 0; }
+ virtual Q_UINT32 priority() { return 4; }
virtual void paint(KisCanvasPainter& gc);
virtual void paint(KisCanvasPainter& gc, const QRect& rc);
virtual void buttonPress(KisButtonPressEvent *e);
Index: tool_curves/kis_tool_moutline.h
===================================================================
--- tool_curves/kis_tool_moutline.h (revision 582360)
+++ tool_curves/kis_tool_moutline.h (working copy)
@@ -77,6 +77,7 @@
virtual void update (KisCanvasSubject*);
virtual void setup (KActionCollection*);
virtual enumToolType toolType() { return TOOL_SELECT; }
+ virtual Q_UINT32 priority() { return 9; }
virtual void keyPress(QKeyEvent*);
virtual void buttonPress(KisButtonPressEvent*);
Index: tool_curves/kis_tool_bezier_paint.h
===================================================================
--- tool_curves/kis_tool_bezier_paint.h (revision 582360)
+++ tool_curves/kis_tool_bezier_paint.h (working copy)
@@ -36,7 +36,8 @@
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_SHAPE; }
-
+ virtual Q_UINT32 priority() { return 7; }
+
protected:
virtual KisCurve::iterator paintPoint(KisPainter& painter, KisCurve::iterator point);
Index: tool_curves/kis_tool_bezier_select.h
===================================================================
--- tool_curves/kis_tool_bezier_select.h (revision 582360)
+++ tool_curves/kis_tool_bezier_select.h (working copy)
@@ -36,6 +36,7 @@
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_SELECT; }
+ virtual Q_UINT32 priority() { return 10; }
protected:
Index: defaulttools/kis_tool_duplicate.h
===================================================================
--- defaulttools/kis_tool_duplicate.h (revision 582360)
+++ defaulttools/kis_tool_duplicate.h (working copy)
@@ -41,6 +41,7 @@
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_FREEHAND; }
+ virtual Q_UINT32 priority() { return 0; }
virtual void buttonPress(KisButtonPressEvent *e);
virtual void move(KisMoveEvent *e);
Index: defaulttools/kis_tool_zoom.h
===================================================================
--- defaulttools/kis_tool_zoom.h (revision 582360)
+++ defaulttools/kis_tool_zoom.h (working copy)
@@ -44,7 +44,7 @@
public:
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_VIEW; }
- virtual Q_UINT32 priority() { return 3; }
+ virtual Q_UINT32 priority() { return 2; }
virtual void buttonPress(KisButtonPressEvent *e);
virtual void move(KisMoveEvent *e);
Index: defaulttools/kis_tool_fill.h
===================================================================
--- defaulttools/kis_tool_fill.h (revision 582360)
+++ defaulttools/kis_tool_fill.h (working copy)
@@ -44,7 +44,8 @@
virtual ~KisToolFill();
virtual void setup(KActionCollection *collection);
- virtual enumToolType toolType() { return TOOL_FILL; }
+ virtual enumToolType toolType() { return TOOL_FILL; }
+ virtual Q_UINT32 priority() { return 0; }
virtual void update(KisCanvasSubject *subject);
Index: defaulttools/kis_tool_gradient.h
===================================================================
--- defaulttools/kis_tool_gradient.h (revision 582360)
+++ defaulttools/kis_tool_gradient.h (working copy)
@@ -54,7 +54,8 @@
virtual ~KisToolGradient();
virtual void setup(KActionCollection *collection);
- virtual enumToolType toolType() { return TOOL_FILL; }
+ virtual enumToolType toolType() { return TOOL_FILL; }
+ virtual Q_UINT32 priority() { return 1; }
virtual void update(KisCanvasSubject *subject);
Index: defaulttools/kis_tool_pan.h
===================================================================
--- defaulttools/kis_tool_pan.h (revision 582360)
+++ defaulttools/kis_tool_pan.h (working copy)
@@ -40,7 +40,8 @@
virtual void update(KisCanvasSubject *subject);
virtual void setup(KActionCollection *collection);
- virtual enumToolType toolType() { return TOOL_VIEW; }
+ virtual enumToolType toolType() { return TOOL_VIEW; }
+ virtual Q_UINT32 priority() { return 1; }
virtual void buttonPress(KisButtonPressEvent *e);
virtual void move(KisMoveEvent *e);
Index: defaulttools/kis_tool_text.h
===================================================================
--- defaulttools/kis_tool_text.h (revision 582360)
+++ defaulttools/kis_tool_text.h (working copy)
@@ -42,6 +42,7 @@
virtual void update(KisCanvasSubject *subject);
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_FILL; }
+ virtual Q_UINT32 priority() { return 2; }
virtual void buttonRelease(KisButtonReleaseEvent *e);
virtual QWidget* createOptionWidget(QWidget* parent);
Index: tool_star/kis_tool_star.h
===================================================================
--- tool_star/kis_tool_star.h (revision 582360)
+++ tool_star/kis_tool_star.h (working copy)
@@ -53,6 +53,7 @@
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_SHAPE; }
+ virtual Q_UINT32 priority() { return 6; }
virtual void buttonPress(KisButtonPressEvent *event);
virtual void move(KisMoveEvent *event);
virtual void buttonRelease(KisButtonReleaseEvent *event);
Index: tool_transform/kis_tool_transform.h
===================================================================
--- tool_transform/kis_tool_transform.h (revision 582360)
+++ tool_transform/kis_tool_transform.h (working copy)
@@ -52,7 +52,7 @@
virtual void setup(KActionCollection *collection);
virtual enumToolType toolType() { return TOOL_TRANSFORM; }
- virtual Q_UINT32 priority() { return 0; }
+ virtual Q_UINT32 priority() { return 3; }
virtual void paint(KisCanvasPainter& gc);
virtual void paint(KisCanvasPainter& gc, const QRect& rc);
virtual void buttonPress(KisButtonPressEvent *e);
Index: tool_perspectivegrid/kis_tool_perspectivegrid.h
===================================================================
--- tool_perspectivegrid/kis_tool_perspectivegrid.h (revision 582360)
+++ tool_perspectivegrid/kis_tool_perspectivegrid.h (working copy)
@@ -49,7 +49,7 @@
//
virtual void setup(KActionCollection *collection);
- virtual Q_UINT32 priority() { return 5; }
+ virtual Q_UINT32 priority() { return 3; }
virtual enumToolType toolType() { return TOOL_VIEW; }
virtual void buttonPress(KisButtonPressEvent *event);
virtual void move(KisMoveEvent *event);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://mail.kde.org/pipermail/kimageshop/attachments/20060909/26c6b77b/attachment.pgp
More information about the kimageshop
mailing list