Kaydet (Commit) f9c77344 authored tarafından Tomaž Vajngerl's avatar Tomaž Vajngerl

Make tab label padding dependent on font height.

Change-Id: I7de52945bdf3062174b49e12e2f05075632c7e4a
üst 1a2b2d2c
...@@ -36,7 +36,6 @@ ...@@ -36,7 +36,6 @@
#include <limits> #include <limits>
#define TABBAR_PADDING 24
#define TABBAR_DRAG_SCROLLOFF 5 #define TABBAR_DRAG_SCROLLOFF 5
#define TABBAR_MINSIZE 5 #define TABBAR_MINSIZE 5
...@@ -607,7 +606,10 @@ bool TabBar::ImplCalcWidth() ...@@ -607,7 +606,10 @@ bool TabBar::ImplCalcWidth()
{ {
pItem->mbShort = false; pItem->mbShort = false;
} }
nNewWidth += TABBAR_PADDING;
// Padding is dependent on font height - bigger font = bigger padding
long nFontWidth = aFont.GetHeight();
nNewWidth += nFontWidth * 2;
if ( pItem->mnWidth != nNewWidth ) if ( pItem->mnWidth != nNewWidth )
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment