Hi, Wang Diancheng, thanks for great patch. Most are ok. Tell me, in librep patch you included some macros, but for what? They don't seem necessary, and have (minor) some shortcomings as described below, they may be deleted.
There's a misleading point in UTF8_LENGTH. There (Char) takes ucs (or Unicode 'codepoint' in more slack terminology) arg, unlike other 'Char's, which are a real byte. And UTF8_LENGTH converts ucs Char to length in bytes in utf-8 representation, right? We don't seem to need this macro. On the other hand, UTF8_GET can be used to check the validity, that is, it can check if the given string is really utf-8, so may be of use. (More precisely, if it returns -1, then it's not utf-8, but nothing can be said otherwise.) Anyway, because sawfish doesn't handle so many strings, we don't need inline function, so if it is to be rewritten (currently not necessary), it can be implemented as a usual function. Lastly, let me ask a question on copyright notice. You say that you borrowed codes from glib, but "This file some code come from glib:" is enough as copyright notice for GPL'd work? Thanks a lot! Teika (Teika kazura)
