From: Jiri Slaby <jirislaby@kernel.org>
To: Nicolas Pitre <nico@fluxnic.net>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Nicolas Pitre <npitre@baylibre.com>,
linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 03/13] vt: properly support zero-width Unicode code points
Date: Wed, 16 Apr 2025 05:45:41 +0200 [thread overview]
Message-ID: <a05950b2-8995-484f-8678-699584d30ffe@kernel.org> (raw)
In-Reply-To: <20250415192212.33949-4-nico@fluxnic.net>
On 15. 04. 25, 21:17, Nicolas Pitre wrote:
> From: Nicolas Pitre <npitre@baylibre.com>
>
> Zero-width Unicode code points are causing misalignment in vertically
> aligned content, disrupting the visual layout. Let's handle zero-width
> code points more intelligently.
>
> Double-width code points are stored in the screen grid followed by a white
> space code point to create the expected screen layout. When a double-width
> code point is followed by a zero-width code point in the console incoming
> bytestream (e.g., an emoji with a presentation selector) then we may
> replace the white space padding by that zero-width code point instead of
> dropping it. This maximize screen content information while preserving
> proper layout.
>
> If a zero-width code point is preceded by a single-width code point then
> the above trick is not possible and such zero-width code point must
> be dropped.
>
> VS16 (Variation Selector 16, U+FE0F) is special as it doubles the width
> of the preceding single-width code point. We handle that case by giving
> VS16 a width of 1 when that happens.
>
> Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Reviewed-by: Jiri Slaby <jirislaby@kernel.org>
--
js
suse labs
next prev parent reply other threads:[~2025-04-16 3:45 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-15 19:17 [PATCH v2 00/13] vt: implement proper Unicode handling Nicolas Pitre
2025-04-15 19:17 ` [PATCH v2 01/13] vt: minor cleanup to vc_translate_unicode() Nicolas Pitre
2025-04-16 3:41 ` Jiri Slaby
2025-04-15 19:17 ` [PATCH v2 02/13] vt: move unicode processing to a separate file Nicolas Pitre
2025-04-16 3:42 ` Jiri Slaby
2025-04-15 19:17 ` [PATCH v2 03/13] vt: properly support zero-width Unicode code points Nicolas Pitre
2025-04-16 3:45 ` Jiri Slaby [this message]
2025-04-15 19:17 ` [PATCH v2 04/13] vt: introduce gen_ucs_width_table.py to create ucs_width_table.h Nicolas Pitre
2025-04-16 4:14 ` Jiri Slaby
2025-04-16 4:19 ` Jiri Slaby
2025-04-16 13:21 ` Nicolas Pitre
2025-04-15 19:17 ` [PATCH v2 05/13] vt: create ucs_width_table.h with gen_ucs_width_table.py Nicolas Pitre
2025-04-16 4:20 ` Jiri Slaby
2025-04-15 19:17 ` [PATCH v2 06/13] vt: use new tables in ucs.c Nicolas Pitre
2025-04-16 4:22 ` Jiri Slaby
2025-04-17 8:30 ` kernel test robot
2025-04-15 19:17 ` [PATCH v2 07/13] vt: introduce gen_ucs_recompose_table.py to create ucs_recompose_table.h Nicolas Pitre
2025-04-16 4:29 ` Jiri Slaby
2025-04-16 13:17 ` Nicolas Pitre
2025-04-17 4:09 ` Jiri Slaby
2025-04-15 19:17 ` [PATCH v2 08/13] vt: create ucs_recompose_table.h with gen_ucs_recompose_table.py Nicolas Pitre
2025-04-16 5:05 ` Jiri Slaby
2025-04-15 19:17 ` [PATCH v2 09/13] vt: support Unicode recomposition Nicolas Pitre
2025-04-16 5:07 ` Jiri Slaby
2025-04-15 19:17 ` [PATCH v2 10/13] vt: pad double-width code points with a zero-width space Nicolas Pitre
2025-04-16 5:07 ` Jiri Slaby
2025-04-15 19:18 ` [PATCH v2 11/13] vt: remove zero-width-space handling from conv_uni_to_pc() Nicolas Pitre
2025-04-16 5:07 ` Jiri Slaby
2025-04-15 19:18 ` [PATCH v2 12/13] vt: update gen_ucs_width_table.py to make tables more space efficient Nicolas Pitre
2025-04-16 5:09 ` Jiri Slaby
2025-04-15 19:18 ` [PATCH v2 13/13] vt: refresh ucs_width_table.h and adjust code in ucs.c accordingly Nicolas Pitre
2025-04-16 5:12 ` Jiri Slaby
2025-04-16 13:09 ` Nicolas Pitre
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a05950b2-8995-484f-8678-699584d30ffe@kernel.org \
--to=jirislaby@kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=nico@fluxnic.net \
--cc=npitre@baylibre.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox