mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
fix: qt5
This commit is contained in:
parent
5809eeb2bf
commit
2e30ebc825
1 changed files with 2 additions and 1 deletions
|
@ -516,7 +516,8 @@ int TextLayoutElement::getXFromIndex(size_t index)
|
|||
int x = 0;
|
||||
for (size_t i = 0; i < index; i++)
|
||||
{
|
||||
x += metrics.horizontalAdvance(this->getText()[i]);
|
||||
x += metrics.horizontalAdvance(
|
||||
this->getText()[static_cast<QString::size_type>(i)]);
|
||||
}
|
||||
return x + this->getRect().left();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue