[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
GWorkspace, utf-8 and cStringLength
From: |
Roman Belenov |
Subject: |
GWorkspace, utf-8 and cStringLength |
Date: |
Tue, 28 Sep 2004 14:40:47 +0400 |
User-agent: |
Gnus/5.1006 (Gnus v5.10.6) Emacs/21.2 (windows-nt) |
I moved to utf-8-based locale recently (LANG=ru_RU.UTF-8 on Linux) and found
that GWorkspace started to raise NSRangeEception while trying to display
filenames with Cyrillic characters (that take 2 bytes per char in
UTF-8). Quick browsing of the code showed that cStringLength is used in many
places where number of characters, not bytes, is needed. (Almost) blind
s/cStringLength/length/ fixed the problem for me, although I'm not sure that
it is 100% correct; I hope that someone more familiar with GWorkspace code
will look into the problem and fix it in official sources.
I played with GWorkspace 0.6.5; seems that code in CVS has this problem too.
--
With regards, Roman.
- GWorkspace, utf-8 and cStringLength,
Roman Belenov <=