[gimp] app: enable cairo drawing for the rect and ellipse select tools



commit 926bbc6658d64a9e10d8f797218193aa379e96a3
Author: Michael Natterer <mitch gimp org>
Date:   Fri Sep 24 18:43:09 2010 +0200

    app: enable cairo drawing for the rect and ellipse select tools
    
    and draw the rectangle's round corners under the bounding box.

 app/tools/gimpellipseselecttool.c   |    2 ++
 app/tools/gimprectangleselecttool.c |    6 ++++--
 2 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/app/tools/gimpellipseselecttool.c b/app/tools/gimpellipseselecttool.c
index 9e7b0cc..8651b27 100644
--- a/app/tools/gimpellipseselecttool.c
+++ b/app/tools/gimpellipseselecttool.c
@@ -94,6 +94,8 @@ gimp_ellipse_select_tool_init (GimpEllipseSelectTool *ellipse_select)
 
   gimp_tool_control_set_tool_cursor (tool->control,
                                      GIMP_TOOL_CURSOR_ELLIPSE_SELECT);
+
+  GIMP_DRAW_TOOL (tool)->use_cairo = TRUE;
 }
 
 static void
diff --git a/app/tools/gimprectangleselecttool.c b/app/tools/gimprectangleselecttool.c
index 07868ff..055f241 100644
--- a/app/tools/gimprectangleselecttool.c
+++ b/app/tools/gimprectangleselecttool.c
@@ -238,6 +238,8 @@ gimp_rectangle_select_tool_init (GimpRectangleSelectTool *rect_sel_tool)
 
   priv->press_x = 0.0;
   priv->press_y = 0.0;
+
+  GIMP_DRAW_TOOL (tool)->use_cairo = TRUE;
 }
 
 static GObject *
@@ -292,8 +294,6 @@ gimp_rectangle_select_tool_draw (GimpDrawTool *draw_tool)
   rect_sel_tool = GIMP_RECTANGLE_SELECT_TOOL (draw_tool);
   priv          = GIMP_RECTANGLE_SELECT_TOOL_GET_PRIVATE (rect_sel_tool);
 
-  gimp_rectangle_tool_draw (draw_tool);
-
   if (priv->round_corners)
     {
       gint    x1, y1, x2, y2;
@@ -332,6 +332,8 @@ gimp_rectangle_select_tool_draw (GimpDrawTool *draw_tool)
                                square_size, square_size,
                                180 * 64, 90 * 64);
     }
+
+  gimp_rectangle_tool_draw (draw_tool);
 }
 
 static gboolean



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]