mirror of https://github.com/stella-emu/stella.git
some more minor dialog refinements
This commit is contained in:
parent
795c84de9d
commit
5121a73210
|
@ -60,7 +60,6 @@ HelpDialog::HelpDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
new ButtonWidget(this, font, xpos, ypos, buttonWidth, buttonHeight,
|
new ButtonWidget(this, font, xpos, ypos, buttonWidth, buttonHeight,
|
||||||
"Close", GuiObject::kCloseCmd);
|
"Close", GuiObject::kCloseCmd);
|
||||||
wid.push_back(b);
|
wid.push_back(b);
|
||||||
addOKWidget(b); addCancelWidget(b);
|
|
||||||
|
|
||||||
xpos = 5; ypos = 5;
|
xpos = 5; ypos = 5;
|
||||||
myTitle = new StaticTextWidget(this, font, xpos, ypos, _w - 10, fontHeight,
|
myTitle = new StaticTextWidget(this, font, xpos, ypos, _w - 10, fontHeight,
|
||||||
|
|
|
@ -57,7 +57,6 @@ LoggerDialog::LoggerDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
ypos += myLogInfo->getHeight() + 8;
|
ypos += myLogInfo->getHeight() + 8;
|
||||||
|
|
||||||
// Level of logging (how much info to print)
|
// Level of logging (how much info to print)
|
||||||
xpos += 20;
|
|
||||||
VariantList items;
|
VariantList items;
|
||||||
VarList::push_back(items, "None", "0");
|
VarList::push_back(items, "None", "0");
|
||||||
VarList::push_back(items, "Basic", "1");
|
VarList::push_back(items, "Basic", "1");
|
||||||
|
@ -69,8 +68,8 @@ LoggerDialog::LoggerDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
wid.push_back(myLogLevel);
|
wid.push_back(myLogLevel);
|
||||||
|
|
||||||
// Should log output also be shown on the console?
|
// Should log output also be shown on the console?
|
||||||
xpos += myLogLevel->getWidth() + 30;
|
xpos += myLogLevel->getWidth() + 32;
|
||||||
myLogToConsole = new CheckboxWidget(this, font, xpos, ypos, "Print to console");
|
myLogToConsole = new CheckboxWidget(this, font, xpos, ypos + 1, "Print to console");
|
||||||
wid.push_back(myLogToConsole);
|
wid.push_back(myLogToConsole);
|
||||||
|
|
||||||
// Add Save, OK and Cancel buttons
|
// Add Save, OK and Cancel buttons
|
||||||
|
|
|
@ -43,7 +43,8 @@ UIDialog::UIDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
fontHeight = font.getFontHeight(),
|
fontHeight = font.getFontHeight(),
|
||||||
buttonWidth = font.getStringWidth("Defaults") + 20,
|
buttonWidth = font.getStringWidth("Defaults") + 20,
|
||||||
buttonHeight = font.getLineHeight() + 4;
|
buttonHeight = font.getLineHeight() + 4;
|
||||||
const int vBorder = 5;
|
const int VBORDER = 5;
|
||||||
|
const int HBORDER = 10;
|
||||||
int xpos, ypos, tabID;
|
int xpos, ypos, tabID;
|
||||||
int lwidth, pwidth = font.getStringWidth("Standard");
|
int lwidth, pwidth = font.getStringWidth("Standard");
|
||||||
WidgetArray wid;
|
WidgetArray wid;
|
||||||
|
@ -56,7 +57,7 @@ UIDialog::UIDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
_h = 11 * (lineHeight + 4) + 10;
|
_h = 11 * (lineHeight + 4) + 10;
|
||||||
|
|
||||||
// The tab widget
|
// The tab widget
|
||||||
xpos = ypos = vBorder;
|
xpos = ypos = VBORDER;
|
||||||
myTab = new TabWidget(this, font, xpos, ypos, _w - 2*xpos, _h - buttonHeight - 20);
|
myTab = new TabWidget(this, font, xpos, ypos, _w - 2*xpos, _h - buttonHeight - 20);
|
||||||
addTabWidget(myTab);
|
addTabWidget(myTab);
|
||||||
|
|
||||||
|
@ -127,7 +128,7 @@ UIDialog::UIDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
ypos += lineHeight + 4;
|
ypos += lineHeight + 4;
|
||||||
|
|
||||||
// Add message concerning usage
|
// Add message concerning usage
|
||||||
xpos = vBorder; ypos += 1*(lineHeight + 4);
|
xpos = VBORDER; ypos += 1*(lineHeight + 4);
|
||||||
lwidth = ifont.getStringWidth("(*) Changes require application restart");
|
lwidth = ifont.getStringWidth("(*) Changes require application restart");
|
||||||
new StaticTextWidget(myTab, ifont, xpos, ypos, std::min(lwidth, _w-20), fontHeight,
|
new StaticTextWidget(myTab, ifont, xpos, ypos, std::min(lwidth, _w-20), fontHeight,
|
||||||
"(*) Changes require application restart",
|
"(*) Changes require application restart",
|
||||||
|
@ -142,7 +143,7 @@ UIDialog::UIDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
tabID = myTab->addTab(" Misc. ");
|
tabID = myTab->addTab(" Misc. ");
|
||||||
lwidth = font.getStringWidth("Interface Palette (*) ");
|
lwidth = font.getStringWidth("Interface Palette (*) ");
|
||||||
pwidth = font.getStringWidth("Standard");
|
pwidth = font.getStringWidth("Standard");
|
||||||
xpos = ypos = vBorder;
|
xpos = ypos = VBORDER;
|
||||||
|
|
||||||
// UI Palette
|
// UI Palette
|
||||||
ypos += 1;
|
ypos += 1;
|
||||||
|
@ -189,7 +190,7 @@ UIDialog::UIDialog(OSystem& osystem, DialogContainer& parent,
|
||||||
ypos += lineHeight + 4;
|
ypos += lineHeight + 4;
|
||||||
|
|
||||||
// Add message concerning usage
|
// Add message concerning usage
|
||||||
xpos = vBorder; ypos += 1*(lineHeight + 4);
|
xpos = VBORDER; ypos += 1*(lineHeight + 4);
|
||||||
lwidth = ifont.getStringWidth("(*) Requires application restart");
|
lwidth = ifont.getStringWidth("(*) Requires application restart");
|
||||||
new StaticTextWidget(myTab, ifont, xpos, ypos, std::min(lwidth, _w-20), fontHeight,
|
new StaticTextWidget(myTab, ifont, xpos, ypos, std::min(lwidth, _w-20), fontHeight,
|
||||||
"(*) Requires application restart",
|
"(*) Requires application restart",
|
||||||
|
|
Loading…
Reference in New Issue