On Feb 23, 2010, at 5:50 PM, Krzysztof Kosiński wrote:

2010/2/19 Hans Meine <hans_meine@...240...>:
On Mittwoch 17 Februar 2010, Krzysztof Kosiński wrote:
5. For the hack in 4 to work, current directory must be set to the
place where Inkscape's executable resides

Does this happen before main() (i.e. is it some Windows-specific executable
property)?  Otherwise, how about simply converting all cmdline arguments to
absolute paths before performing the chdir?

No, we explicitly call SetCurrentDirectory. We can convert arguments
to absolute paths in WinMain, but I'd rather fix this properly (e.g.
not change the directory and be smarter about where we look for
resources).

Yes, yes, YES!!!

I want to be on record as what Krzysztof said here is right on target. 

Not changing directory goes hand in hand with not being dependent on the directory setting of the current moment. Among other things such issues can get very complicated as soon as multithreading is in play. Given that we are trying to clean things up to take advantage of multiple cores, this is about to become a much more important issue.

Probably the top thing to do is correct where we look for resources. From way back this was originally addressed by simplistic #defines to paste static paths together, etc. Instead we need to get relative lookups hierarchal and properly relative. This is right in line with Krzysztof's hesitance to convert paths to absolute in WinMain.