mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-26 22:57:00 +02:00
- fixes #1423 - convert values to int before using
This commit is contained in:
parent
fba4c2cf9e
commit
7f43150bb9
@ -1252,8 +1252,8 @@ void CTextContainer::blitLine(SDL_Surface *to, Rect destRect, std::string what)
|
||||
|
||||
if (alignment == CENTER)
|
||||
{
|
||||
where.x += (destRect.w - f->getStringWidth(what)) / 2;
|
||||
where.y += (destRect.h - f->getLineHeight()) / 2;
|
||||
where.x += (int(destRect.w) - int(f->getStringWidth(what))) / 2;
|
||||
where.y += (int(destRect.h) - int(f->getLineHeight())) / 2;
|
||||
}
|
||||
|
||||
if (alignment == BOTTOMRIGHT)
|
||||
|
Loading…
Reference in New Issue
Block a user