|
From: | Chet Ramey |
Subject: | Re: Completion should handle combining accents equivalents |
Date: | Tue, 2 Feb 2021 11:33:51 -0500 |
User-agent: | Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.6.1 |
On 2/2/21 11:19 AM, Samuel Thibault wrote:
Chet Ramey, le mar. 02 févr. 2021 10:50:35 -0500, a ecrit:On 2/1/21 5:31 PM, Samuel Thibault wrote:This is tested with libreadline 8.0 on Debian. If I create a directory named héhé where é is e + U+0301 (combining acute accent), and then try to complete hé into it where é is the precombined form U+00E9), libreadline does not take care that é (e with combining acute accent) is equivalent to é (the precombined "e with acute accent" character), and fails to complete.Readline doesn't use strcoll right now, since it doesn't work for case- insensitive completion or case-mapping completion, and there's no strncmp equivalent.libreadline can use a unicode normal form for the completion matching.
Readline has hooks to do filename rewriting now. The bash-specific one uses iconv to convert filenames on macOS. If you want to take a shot at using that, or something similar, I'd be happy to take a look at what you came up with. Try to avoid using iconv or anything similar and external if you can, to avoid adding any dependencies to readline. -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/
[Prev in Thread] | Current Thread | [Next in Thread] |