mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-01-19 07:25:39 +00:00
Fixed an issue where a GUI element size was incorrectly calculated.
This commit is contained in:
parent
392ca21adb
commit
2f3a2a6157
|
@ -99,7 +99,7 @@ void GuiMenu::openUISettings()
|
||||||
if ((*it)->getName() != "retropie") {
|
if ((*it)->getName() != "retropie") {
|
||||||
// If required, abbreviate the system name so it doesn't overlap the setting name.
|
// If required, abbreviate the system name so it doesn't overlap the setting name.
|
||||||
std::string abbreviatedString = Font::get(FONT_SIZE_MEDIUM)->
|
std::string abbreviatedString = Font::get(FONT_SIZE_MEDIUM)->
|
||||||
getTextMaxWidth((*it)->getFullName(), Renderer::getScreenWidth() * 0.25f);
|
getTextMaxWidth((*it)->getFullName(), mSize.x() * 0.47f);
|
||||||
float sizeDifference = Font::get(FONT_SIZE_MEDIUM)->sizeText((*it)->getFullName()).x() -
|
float sizeDifference = Font::get(FONT_SIZE_MEDIUM)->sizeText((*it)->getFullName()).x() -
|
||||||
Font::get(FONT_SIZE_MEDIUM)->sizeText(abbreviatedString).x();
|
Font::get(FONT_SIZE_MEDIUM)->sizeText(abbreviatedString).x();
|
||||||
if (sizeDifference > 0) {
|
if (sizeDifference > 0) {
|
||||||
|
|
Loading…
Reference in a new issue