Sublime Forum

[BUG] Chinese characters and English characters are not vertically aligned

#1

If you put Chinese characters and English characters in the same line, then it’s very obvious the two kinds of the characters are not vertcailly aligned.

I am using Linux. All the fonts have the problem, although different fonts have different serious degree, but even choosing a font with the slightest disalignments doesn’t help, because the disalignment is still very easy to see.

You can test it with the following text:

Test測試與英文alignment對齊with Chinese

Hope this issue will get fixed. Thanks!

2 Likes

#2

This is the only reason why I don’t use Sublime these days, because I am programming in C with Chinese identifiers and comments.

Sublime has really good user experience in every aspect, but unfortunately, disalignment between Chinese characters and English characters just makes very terrible readablity, so I had to switch to another editor but I wish I will switch back to Sublime in future.

Would the author please fix the bug?

0 Likes

#3

I found that I “actually” have this problem on my Windows 7 PC too.

But because I always enable gdi in font_options in ST’s settings and using MacType, the final rendered result looks quite good to me.

If I turn both gdi and MacType off, I would get a badly aligned sentence.

0 Likes

#4

Thank you for the reply.

So the issue does not only exist on Linux, it seems OS-independent.

I think it’s an actual bug, it should have worked well no matter whether the gdi and MacType are turned on. It’s not reasonable to require the user to turn on them for just displaying text correctly.

0 Likes

#5

on my Windows 7, with the default font and directwrite it looks fine:

0 Likes

#6

Thanks for the reply.

It doesn’t look perfect to my Chinese eyes, I can just say it’s just not serious from your screenshot. All the English characters are a little higher than the Chinese characters. Typically, it would look better if the bottomside of the g character is a little lower than the bottomsides of any Chinese characters(Please take a look at jfcherng’s first screenshot), but your screenshot shows that’s not the case.

Even if it looks fine in this font, it doesn’t mean it will also look fine in other fonts. If you switch to some random font, you would probably see disalignment in a different degree. So the essential issue is that the Sublime doesn’t align the baseline of the characters between Chinese and English, picking some font which “works” is just palliative.

0 Likes

#7

WIll this bug be fixed? I am looking forward to hearing from the author.

0 Likes

#8

May be related with Weird fonts in new update 3.1 Build 3170.

0 Likes

#9

The best place to file bugs with core functionality, such as text rendering is https://github.com/SublimeTextIssues/Core/issues. That sort of a system makes it easier to search, discuss and group issues and solutions.

0 Likes

#10

To both of you: Thank you for the information. I’ll file a bug there.

0 Likes