GNOME Bugzilla – Bug 352654
quotation mark overlap with the next character in zh_CN.UTF-8 locale
Last modified: 2010-04-01 21:43:48 UTC
Please describe the problem: In zh_CN.UTF-8 locale, the "Quan Jiao" quotation mark(which is two characters wide) will overlap with the next character, whether it's chinese character or not. I can only show you the picture: http://static.flickr.com/77/223548966_dbdc35cfda_o.png,as a comparison, there's no such problem with zh_CN.GBK locale: http://static.flickr.com/64/223548967_66cda03c7e_o.png. and there're no such problems for rxvt-unicode(but gnome-terminal/vte is much much more prittier than rxvt-unicode, so I hope g-t will improve in this tiny problem :) either in zh_CN.UTF-8 locale: http://static.flickr.com/58/223548968_2919aff0d4_o.png, or in zh_CN.GBK locale: http://static.flickr.com/85/223548969_ca7b09a9fb_o.png. I've not tried other locale(zh_TW.UTF-8 for example) Steps to reproduce: 1. open gnome-terminal in zh_CN.UTF-8 locale 2. use any chinese input method(scim/fcitx for instance) to input "Quan Jiao" quotation mark 3. there's the poblem Actual results: quotation mark overlap with the next character Expected results: in UTF-8, I hope it will display like rxvt-unicode in UTF-8 locale Does this happen every time? yes Other information: I do not have too much knowledge about the details of coding related stuff like UCS/UTF-8/GBK, but in rxvt-unicode and UTF-8, quotation mark displayed like a "Ban Jiao"(one western character's wide) character, but in g-t, it seems the glyph(font?) itself is a "Quan Jiao"(two characters wide) character, but g-t attempts to display it like an "Ban Jiao"(one western character's wide), so it ovlap with the next character.
Could you tell us the unicode code points for these characters, and/or paste them directly here in this bug, so I can test this?
You can use the env var VTE_CJK_WIDTH=wide before running the terminal to get the desired behavior. Otherwise, what you see is exactly what Unicode recommends here: # Ambiguous characters behave like wide or narrow characters depending on the context (language tag, script identification, associated font, source of data, or explicit markup; all can provide the context). If the context cannot be established reliably, they should be treated as narrow characters by default. http://www.unicode.org/reports/tr11/#Recommendations In a terminal emulator, we can't really rely on much context. We used to render them as wide, but that screws up all kind of ASCII art, so I changed it to default to narrow and respect an env var instead. PS. Maybe we should have a g-t config for this instead. ChPe, if you think that would be useful, reopen and I'll add the VTE API.
Yes, I think having vte API instead of having to set an env var before starting g-t would be nice.
Filed bug 614617 for the vte api and bug 614618 for the g-t UI.