texstudio
texstudio copied to clipboard
Chinese characters are showing uncorrectly in message panel. (消息窗口的中文字符显示乱码)
Environment
- TeXstudio: 4.2.2
- Qt: 6.2.3
- OS: Windows 10
- TeX distribution: texlive
Expected behavior
In the message panel which locates at the bottom-left of the whole window, the Chinese character should display correctly just as the software UI's character do.
Actual behavior
The characters which were typed in by user just became distorted in message panel.
For example, '你好'
became '浣犲ソ'
.
The following illustration is more straight-forward.
![VeryCapture_20220315170216](https://user-images.githubusercontent.com/30381410/158343264-b13e3102-e297-4192-8a98-2aaa0ee307f0.png)
How to reproduce
- Install Git and configure it on TeXStudio.
- Open a new tex file.
- From
Menu Bar
, selectFiles
>SVN/GIT
>check in
. - Enter some Chinese words like '你好' as commit comments.
- The distorted characters should show up in message panel.
(Screen recording...)
Have you tried to use git on a console/cmd ? Does that work correctly ?
I tried. It works well on Powershell/CMD/Git Bash.
By the way, I used to use git in integrated console
of VS Code, where the document editing
and the version controlling
could be done smoothly.
When I migrated to TeXstudio, I realized that using a integrated git in TXS is not easy (this comment). So I tried to configure git on TXS and use the built-in check in
command. Then the problem appeared.
Seems a decoding issue. 浣犲ソ
comes from decoding a UTF8 encoded 你好
with GB18030.
Seems a decoding issue.
浣犲ソ
comes from decoding a UTF8 encoded你好
with GB18030.
Any suggest about where to configure this encoding & decoding? Or is it a software-side problem?
txs assumes that the local code page is used for cmd output. so I am not sure if win used GB18030 and git ignores it or windows actually used utf8 and QT misses that.