Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: filename completion with umlauts (again)



On Jan 8, 12:35am, Andy Spiegl wrote:
}
} Uhm, too bad.  I am wondering whether case insensitivity in the
} matcher could be achieved with a different trick?

As I understand it, the problem isn't case insensitivity.  The problem
is (a) representing each set of characters in a managable syntax and
(b) efficiently constructing a mapping between the two sets.

This is a tractable problem for single byte characters because there
is a single fixed ordering and no more than 256 values in each set; for
multibyte characters, not only is the number of values much larger,
but also the user-expected collating order is not always the same as
the numeric order of the underlying encoding.

(And now I fully expect someone to point out that I've got that entirely
wrong and the trouble really is something else.)

} But no, I guess case insensitivity is a lot more complex, right?

If all you want is bidirectional case insensitivity, you might be
able to construct a completer based on _approximate that inserts a
(#i) into the value of PREFIX in the way _approximate does for (#a).
Then add that completer to your completers zstyle.

This is considerably less powerful than what matcher-list does.



Messages sorted by: Reverse Date, Date, Thread, Author