change unicode for better font support and fix some cases (#4139)

Co-authored-by: Felanbird <41973452+Felanbird@users.noreply.github.com>
Co-authored-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
Salman Abuhaimed
2022-11-12 11:30:44 +03:00
committed by GitHub
parent c714f15ce9
commit 070151fbc8
3 changed files with 6 additions and 7 deletions
@@ -14,8 +14,7 @@
namespace {
const QChar RTL_MARK(0x200F);
const QChar RTL_EMBED(0x202B);
} // namespace
namespace chatterino {
@@ -295,8 +294,7 @@ void TextLayoutElement::paint(QPainter &painter)
QString text = this->getText();
if (text.isRightToLeft() || this->reversedNeutral)
{
text.prepend(RTL_MARK);
text.append(RTL_MARK);
text.prepend(RTL_EMBED);
}
painter.setPen(this->color_);