]> Dogcows Code - chaz/openbox/commitdiff
add the margins to the label_height so that the text doesnt cover the bevel/border
authorDana Jansens <danakj@orodu.net>
Sat, 6 Sep 2003 08:43:30 +0000 (08:43 +0000)
committerDana Jansens <danakj@orodu.net>
Sat, 6 Sep 2003 08:43:30 +0000 (08:43 +0000)
render/theme.c

index 934750dd27f98fcc2251fa35cff6ec049dda44ff..46636e2b7b8f22c92914b193a171658787233a20 100644 (file)
@@ -878,7 +878,15 @@ RrTheme* RrThemeNew(const RrInstance *inst, gchar *name)
 
     XrmDestroyDatabase(db);
 
-    theme->label_height = theme->winfont_height;
+    {
+        gint fl, ft, fr, fb;
+        gint ul, ut, ur, ub;
+
+        RrMargins(theme->a_focused_label, &fl, &ft, &fr, &fb);
+        RrMargins(theme->a_unfocused_label, &ul, &ut, &ur, &ub);
+        theme->label_height = theme->winfont_height
+            + MAX(ft + fb, ut + ub);
+    }
     theme->title_height = theme->label_height + theme->bevel * 2;
     theme->button_size = theme->label_height - 2;
     theme->grip_width = theme->title_height * 1.5;
This page took 0.030127 seconds and 4 git commands to generate.