Re: [Kde-accessibility] Gnome-braille.



Bill Haneman, le Thu 19 Oct 2006 10:23:40 +0100, a écrit :
> > iconv should be fine for this
> >   
> Actually, I don't think so - it doesn't include offset_to_pointer 

That's something like:
long utf8_offset_to_pointer(char *str, long offset) {
	iconv_t conv = iconv_open("wchar_t","utf-8");
	size_t sin = strlen(str), sout = offset * sizeof(wchar_t);
	wchar_t *out = malloc(sout), *_out = out;
	iconv(conv, &str, &sin, (char**)&_out, &sout);
	free(out);
	iconv_close(conv);
	return str;
}

> >> (now the hard ones...)
> >> g_unichar_break_type
> >> g_unicode_canonical_decomposition
> >>     
> >
> > libicu should be fine for this.
> >   
> I wasn't too impressed when I last used ICU but that was awhile back.  

It is at least version 36 now.

> We don't need great speed/performance here so it may work; I'll have a look.

There is libunicode too, I don't know how better (or worse) it might be.

Samuel



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