lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Sam Roberts wrote:
> In my workings with utf-8, I've just used them as strings, and its
> worked very well for me.
> What would you want from a utf-8 library?

Well, my application is a text editor, so the main thing I need is the ability
to do string slicing, substitution, pattern matching etc on UTF-8 strings
reasonably quickly, using character offsets throughout. In fact, the one thing
I *don't* want to do is to transcode from one encoding to another, so iconv
doesn't help me.

It'd also be nice to have an interface to the Unicode character class tables
so I can determine if a particular character is whitespace, double-width, etc,
but that's not particularly crucial --- for the western text that the app is
aimed at, I can use hard-coded tables.

╭─┈David Given┈──McQ─╮ "...electrons, nuclei and other particles are good
│┈┈┈┈┈│ approximations to perfectly elastic spherical
│┈(┈│ cows." --- David M. Palmer on r.a.sf.c

Attachment: signature.asc
Description: OpenPGP digital signature