mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-22 06:05:38 +00:00
Improved font rendering for BusyComponent and GuiInfoPopup
This commit is contained in:
parent
8a42b01165
commit
40f258f0f4
|
@ -43,7 +43,7 @@ void BusyComponent::onSizeChanged()
|
||||||
mGrid.setColWidthPerc(2, middleSpacerWidth / mSize.x);
|
mGrid.setColWidthPerc(2, middleSpacerWidth / mSize.x);
|
||||||
mGrid.setColWidthPerc(3, textWidth / mSize.x);
|
mGrid.setColWidthPerc(3, textWidth / mSize.x);
|
||||||
|
|
||||||
mGrid.setRowHeightPerc(1, textHeight / std::round(mSize.y));
|
mGrid.setRowHeightPerc(1, mText->getFont()->getLetterHeight() / mSize.y);
|
||||||
|
|
||||||
mBackground.setCornerSize({16.0f * Renderer::getScreenResolutionModifier(),
|
mBackground.setCornerSize({16.0f * Renderer::getScreenResolutionModifier(),
|
||||||
16.0f * Renderer::getScreenResolutionModifier()});
|
16.0f * Renderer::getScreenResolutionModifier()});
|
||||||
|
|
|
@ -61,9 +61,10 @@ GuiInfoPopup::GuiInfoPopup(std::string message, int duration)
|
||||||
// We only initialize the actual time when we first start to render.
|
// We only initialize the actual time when we first start to render.
|
||||||
mStartTime = 0;
|
mStartTime = 0;
|
||||||
|
|
||||||
mGrid = new ComponentGrid(glm::ivec2 {1, 1});
|
mGrid = new ComponentGrid(glm::ivec2 {1, 3});
|
||||||
|
mGrid->setEntry(s, glm::ivec2 {0, 1}, false, true);
|
||||||
|
mGrid->setRowHeightPerc(1, s->getSize().y / mSize.y);
|
||||||
mGrid->setSize(mSize);
|
mGrid->setSize(mSize);
|
||||||
mGrid->setEntry(s, glm::ivec2 {0, 0}, false, true);
|
|
||||||
addChild(mGrid);
|
addChild(mGrid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue