FirstBootPrompt: adjust window size to font size
At 12pt, we try to fit a 640x480 display. But at larger font sizes we have to allow some more space. Fixes #16066.
This commit is contained in:
parent
96f1875f90
commit
0e55a366be
@ -68,7 +68,7 @@ static const char* kLanguageKeymapMappings[] = {
|
||||
|
||||
// Cyrillic keymaps are not usable alone, as latin alphabet is required to
|
||||
// use Terminal. So we stay in US international until the user has a chance
|
||||
// to set up KeymapSwitcher. TODO enable KeymapSwitcher automatically.
|
||||
// to set up KeymapSwitcher.
|
||||
"Belarusian", "US-International",
|
||||
"Russian", "US-International",
|
||||
"Ukrainian", "US-International",
|
||||
@ -202,7 +202,7 @@ BootPromptWindow::BootPromptWindow()
|
||||
fLanguagesListView, B_WILL_DRAW, false, true);
|
||||
|
||||
// Carefully designed to not exceed the 640x480 resolution with a 12pt font.
|
||||
float width = 640 - (labelWidth + 96);
|
||||
float width = 640 * be_plain_font->Size() / 12 - (labelWidth + 64);
|
||||
float height = be_plain_font->Size() * 23;
|
||||
fInfoTextView->SetExplicitMinSize(BSize(width, height));
|
||||
fInfoTextView->SetExplicitMaxSize(BSize(width, B_SIZE_UNSET));
|
||||
|
Loading…
Reference in New Issue
Block a user