Remove .gitignore do nothing is ignored.
[synfig.git] / synfig-core / trunk / src / synfig / main.cpp
index 9133b2f..9e0a56a 100644 (file)
@@ -165,6 +165,7 @@ synfig::Main::Main(const synfig::String& basepath,ProgressCallback *cb):
 
 #ifdef ENABLE_NLS
        bindtextdomain("synfig", LOCALEDIR);
+       bind_textdomain_codeset("synfig", "UTF-8");
 #endif
 
        String prefix=basepath+"/..";
@@ -230,18 +231,20 @@ synfig::Main::Main(const synfig::String& basepath,ProgressCallback *cb):
                locations.push_back(getenv("SYNFIG_MODULE_LIST"));
        else
        {
-               locations.push_back("./"MODULE_LIST_FILENAME);  //1
-               locations.push_back("../etc/"MODULE_LIST_FILENAME);     //1
-               locations.push_back("~/.synfig/"MODULE_LIST_FILENAME); //2
+               locations.push_back("./"MODULE_LIST_FILENAME);
+               locations.push_back("../etc/"MODULE_LIST_FILENAME);
+               if(getenv("HOME"))
+                       locations.push_back(strprintf("%s/.synfig/%s", getenv("HOME"), MODULE_LIST_FILENAME));
        #ifdef SYSCONFDIR
                locations.push_back(SYSCONFDIR"/"MODULE_LIST_FILENAME);
        #endif
-               locations.push_back(prefix+"/etc/"+MODULE_LIST_FILENAME); //3
+               locations.push_back(prefix+"/etc/"+MODULE_LIST_FILENAME);
                locations.push_back("/usr/local/etc/"MODULE_LIST_FILENAME);
        #ifdef __APPLE__
                locations.push_back("/Library/Frameworks/synfig.framework/Resources/"MODULE_LIST_FILENAME);
                locations.push_back("/Library/Synfig/"MODULE_LIST_FILENAME);
-               locations.push_back("~/Library/Synfig/"MODULE_LIST_FILENAME);
+               if(getenv("HOME"))
+                       locations.push_back(strprintf("%s/Library/Synfig/%s", getenv("HOME"), MODULE_LIST_FILENAME));
        #endif
        #ifdef WIN32
                locations.push_back("C:\\Program Files\\Synfig\\etc\\"MODULE_LIST_FILENAME);
@@ -311,7 +314,7 @@ synfig::Main::~Main()
        // synfig::info("Module::subsys_stop()");
        // Module::subsys_stop();
        // synfig::info("Exiting");
-       
+
 #if defined(HAVE_SIGNAL_H) && defined(SIGPIPE)
        signal(SIGPIPE, SIG_DFL);
 #endif