Replace hardcoded C:\Windows path by auto-search; see issue #572
This commit is contained in:
@@ -107,7 +107,8 @@ FixRatio=true
|
||||
DPI=600
|
||||
|
||||
[Color Management]
|
||||
ICCDirectory=C:\\WINDOWS\\System32\\spool\\drivers\\color
|
||||
# Auto-determined by RT on first start
|
||||
# ICCDirectory=
|
||||
MonitorProfile=
|
||||
Intent=1
|
||||
|
||||
|
@@ -138,7 +138,11 @@ void Options::setDefaults () {
|
||||
rtSettings.darkFramesPath = "";
|
||||
rtSettings.flatFieldsPath = "";
|
||||
#ifdef WIN32
|
||||
rtSettings.iccDirectory = "C:/WINDOWS/System32/spool/drivers/color";
|
||||
const gchar* sysRoot = g_getenv("SystemRoot"); // Returns e.g. "c:\Windows"
|
||||
if (sysRoot!=NULL)
|
||||
rtSettings.iccDirectory = Glib::ustring(sysRoot) + Glib::ustring("\\System32\\spool\\drivers\\color");
|
||||
else
|
||||
rtSettings.iccDirectory = "C:\\WINDOWS\\System32\\spool\\drivers\\color";
|
||||
#else
|
||||
rtSettings.iccDirectory = "/usr/share/color/icc";
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user