-use: getWidth()

git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@256 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
satbaby
2010-02-04 12:13:19 +00:00
parent f548d2e3c0
commit d974484c3e
2 changed files with 9 additions and 5 deletions

View File

@@ -93,9 +93,10 @@ void CDBoxInfoWidget::paint()
{
const int headSize = 5;
const char *head[headSize] = {"Filesystem", "Size", "Used", "Available", "Use%"};
int sizeOffset = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth("9999.99M");
int percOffset = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth("100%");
int nameOffset = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth("WWWwwwwwww");
int fontWidth = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getWidth();
int sizeOffset = fontWidth * 7;//9999.99M
int percOffset = fontWidth * 3 ;//100%
int nameOffset = fontWidth * 9;//WWWwwwwwww
int offsetw = nameOffset+ (sizeOffset+10)*3 +10+percOffset+10;
offsetw += 20;
width = offsetw + 10 + 120;