mirror of https://github.com/stella-emu/stella.git
Fixed popup widget text limits
This commit is contained in:
parent
7834665f39
commit
37af09e3dc
|
@ -260,8 +260,9 @@ void PopUpWidget::drawWidget(bool hilite)
|
||||||
|
|
||||||
// Draw the selected entry, if any
|
// Draw the selected entry, if any
|
||||||
const string& name = myMenu->getSelectedName();
|
const string& name = myMenu->getSelectedName();
|
||||||
TextAlign align = (_font.getStringWidth(name) > w - 6) ?
|
w -= dropDownWidth(_font);
|
||||||
|
TextAlign align = (_font.getStringWidth(name) > w) ?
|
||||||
TextAlign::Right : TextAlign::Left;
|
TextAlign::Right : TextAlign::Left;
|
||||||
s.drawString(_font, name, x + _textOfs, _y + myTextY, w - 6,
|
s.drawString(_font, name, x + _textOfs, _y + myTextY, w,
|
||||||
!(isEnabled() && onTop) ? kColor : _changed ? kDbgChangedTextColor : kTextColor, align);
|
!(isEnabled() && onTop) ? kColor : _changed ? kDbgChangedTextColor : kTextColor, align);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue