Details
-
Suggestion
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
3.x, 4.0.0, 4.0.1, 4.1.0, 4.1.1, 4.1.2, 4.1.3, 4.1.4, 4.1.5, 4.2.0, 4.2.1, 4.2.2, 4.2.3, 4.3.0, 4.3.1, 4.3.2, 4.3.3, 4.3.4, 4.3.5, 4.4.0, 4.4.1, 4.4.2, 4.4.3, 4.5.0, 4.5.1, 4.5.2, 4.5.3, 4.6.0, 4.6.1, 4.6.2
-
None
Description
Characters can be full-width or half-width (with invisible characters being 0-width), and we need a way to know which characters are full-width or half-width.
QString/QChar should implement columnWidth() that would return 0, 1, or 2 for the number of columns a character occupies. -1 could be used for errors.
The biggest use case for this is to know how many columns a string would occupy in terminal applications. We cannot use QFontMetrics because we cannot reference the font the terminal application is using.