]> git.lyx.org Git - features.git/commit
Fixup 3dc54d4a: fix string encoding issues with Qt4
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Thu, 20 Jun 2019 09:22:53 +0000 (11:22 +0200)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Thu, 18 Jun 2020 13:48:33 +0000 (15:48 +0200)
commit25e0b58c24551aba32b722823abaca5fa64f0491
tree64ef97fcdf6afdf38d53ac7e47745d61a214301d
parentc96e8569c70e930b998299c021c1882f50eac963
Fixup 3dc54d4a: fix string encoding issues with Qt4

The culprit here is the constructor QString(QByteArray const &): in
Qt4, it would interpret the byte array as latin1, and in Qt5 as utf8.

Therefore it is safer to use explicitly QString::fromUtf8 instead of
this constructor.

Several places where additionally simplified, in order to avoid some
extra conversions.
src/frontends/qt4/GuiLyXFiles.cpp
src/frontends/qt4/GuiWorkArea.cpp
src/support/lstrings.cpp