Gix the alignment in GuiText

This commit is contained in:
Maschell 2020-08-13 14:12:26 +02:00
parent 64e2756b92
commit d89093de78

View File

@ -639,6 +639,11 @@ void GuiText::draw(CVideo *pVideo) {
float x_pos = getCenterX() * internalRenderingScale;
float y_pos = getCenterY() * internalRenderingScale;
if (alignment & ALIGN_TOP) {
y_pos -= getLineHeight() * getScale() * internalRenderingScale;
} else if (alignment & ALIGN_BOTTOM) {
y_pos += getLineHeight() * getScale() * internalRenderingScale;
}
if (maxWidth > 0 && maxWidth <= textWidth) {
if (wrapMode == DOTTED) { // text dotted