[gimp/gimp-2-8] Bug 774383 - Text layer created by gimp-text-fontname doesn't...



commit 0947a37ad5f1a1135e07edea083969589c5f3a83
Author: Michael Natterer <mitch gimp org>
Date:   Tue Nov 15 13:23:00 2016 +0100

    Bug 774383 - Text layer created by gimp-text-fontname doesn't...
    
    ...respect border when resized
    
    gimp_text_layout_new(): in FIXED box mode, subtract (2 * border) when
    setting the layout width.
    
    (cherry picked from commit 1415a78fa1035eb8c3397bfd27c959c0e5d5f921)

 app/text/gimptextlayout.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/app/text/gimptextlayout.c b/app/text/gimptextlayout.c
index 5266bc8..12e775b 100644
--- a/app/text/gimptextlayout.c
+++ b/app/text/gimptextlayout.c
@@ -170,7 +170,8 @@ gimp_text_layout_new (GimpText  *text,
                               pango_units_from_double
                               (gimp_units_to_pixels (text->box_width,
                                                      text->box_unit,
-                                                     xres)));
+                                                     xres) -
+                               2 * layout->text->border));
       break;
     }
 


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