On Sat, Oct 18, 2003 at 06:53:18PM +0200, Per Olofsson wrote:
> I really don't know what the right thing to do is. Some people argue that
> it is wrong to hard-code a specific character set such as UTF-8 as there
> might be some other that is preferable in the future. Still, this is the
> approach that many takes, like GTK and M$ for example, and Ion of course.
> The Xmb functions do incur a certain overhead because of the uncertainity
> of which character set is used

The problem with general mb stuff is the lack of a libc standard function 
to go back one character in a string (M$ and Watcom libraries seem to have
an mbsdec function) and with general character sets I'm afraid this could
make the title-shortening algorithm too slow in case of long titles. (A
more complicated algorithm might be a possibility but I still don't like
scanning through the whole string all the time.) An alternative would be
to just use wchar_t internally, but I kind of prefer a nice encoding like
utf-8.

-- 
Tuomo

Reply via email to