]> git.lyx.org Git - lyx.git/blobdiff - src/font.C
Remove unused font variable which caused a warning.
[lyx.git] / src / font.C
index 210d10bd60e61a0feccdbd16703736a1a6803b79..ef93daa5f91e623baba57cf6d243ff588e5ba143 100644 (file)
@@ -224,9 +224,11 @@ void lyxfont::rectText(string const & str, LyXFont const & font,
 void lyxfont::buttonText(string const & str, LyXFont const & font,
                int & width, int & ascent, int & descent)
 {
-       width = lyxfont::width(str, font) + 8;
-       ascent = lyxfont::maxAscent(font) + 3;
-       descent = lyxfont::maxDescent(font) + 3;
+       static int const d = 3;
+       
+       width = lyxfont::width(str, font) + d * 2 + 2;
+       ascent = lyxfont::maxAscent(font) + d;
+       descent = lyxfont::maxDescent(font) + d;
 }