On Mar 13, 2008, at 3:19 PM, Krzysztof KosiĆski wrote:
Hello
Can anyone review the patch provided here: https://bugs.launchpad.net/inkscape/+bug/195220 It moves the commandline option parsing from popt to GOption and shortens main.cpp a fair bit, but I'm not sure how does Inkscape open files
- does it
(1) use UTF-8 filenames or (2) filenames in the system encoding? This patch will be ok if 2 is the case, and I believe 2 is the standard practice with Glib.
That's actually a bit tricky. It should actually be using neither of those encodings. Instead it should be using the third type of encoding which is filename encoding (GTK apps have to juggle system, internal/UTF-8 *and* filesystem)
The standard with GLib has been that it uses filesystem encoding. Sometimes filesystem encoding is the same as system encoding (in which case you'll notice no difference). Other times filesystem encoding is different.
What makes it even trickier is that the filesystem encoding can be the original one used waaaaaaaay back when the filesystem was installed. For example I've seen Japanese systems that have a Linux distro installed that uses UTF-8 as the system and filesystem encodings *but* on a specific box use ISO-2022-JP for the filesystem instead since it was an older system that had been upgraded.