Virtual Keyboard: 'Ab'use the console font to get a font small enough to be usable on 320*240 virtual keyboards for display_area (GUI and BigGUI take up far too much space).

svn-id: r41300
This commit is contained in:
John Willis 2009-06-06 20:05:21 +00:00
parent 0989bb0b90
commit d89fbd5b75

View file

@ -117,8 +117,12 @@ void VirtualKeyboardGUI::setupDisplayArea(Rect& r, OverlayColor forecolor) {
if (!fontIsSuitable(_dispFont, r)) {
_dispFont = FontMan.getFontByUsage(Graphics::FontManager::kGUIFont);
if (!fontIsSuitable(_dispFont, r)) {
_displayEnabled = false;
return;
/* FIXME: We 'ab'use the kConsoleFont to get a font that fits in a small display_area on 320*240 keyboard images */
_dispFont = FontMan.getFontByUsage(Graphics::FontManager::kConsoleFont);
if (!fontIsSuitable(_dispFont, r)) {
_displayEnabled = false;
return;
}
}
}
_dispX = _kbdBound.left + r.left;