[gimp] app: re-frame the layer on each text change



commit 99b3af1cd29e3c53e0d3daed814fe4089056eb97
Author: Michael Natterer <mitch gimp org>
Date:   Fri Feb 19 12:40:46 2010 +0100

    app: re-frame the layer on each text change
    
    because just about any text change can also change the text layer size.

 app/tools/gimptexttool.c |   10 +++-------
 1 files changed, 3 insertions(+), 7 deletions(-)
---
diff --git a/app/tools/gimptexttool.c b/app/tools/gimptexttool.c
index 0ec1e9e..44e894f 100644
--- a/app/tools/gimptexttool.c
+++ b/app/tools/gimptexttool.c
@@ -1341,14 +1341,10 @@ gimp_text_tool_text_notify (GimpText     *text,
       g_value_unset (&value);
     }
 
-  /* we need to redraw the rectangle if it is visible and the shape of
-   * the layer has changed, because of an undo for example.
+  /* we need to redraw the rectangle in any case because whatever changes
+   * to the text can change its size
    */
-  if (strcmp (pspec->name, "box-width") == 0  ||
-      strcmp (pspec->name, "box-height") == 0)
-    {
-      gimp_text_tool_frame_item (text_tool);
-    }
+  gimp_text_tool_frame_item (text_tool);
 
   /* if the text has changed, (probably because of an undo), we put
    * the new text into the text buffer



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