Color profiles not loaded on Windows
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Inkscape |
In Progress
|
Medium
|
jazzynico |
Bug Description
Reproduced on Windows XP (32-bit) with lp:inkscape/0.92.x rev. 15214.
Not reproduced on Xubuntu 16.04, lp:inkscape/0.92.x rev. 15214 and lp:inkscape rev. 15273.
On Windows XP, the profiles linked to a document are listed in the Documents properties and F&S dialogs, but can't be used. It seems to be due to bug in src/uri.cpp (called from src/color-
The document docbase is "C:\Documents and Settings\
In ColorProfile::set:
1. "g_uri_
"C:%5CWINDOWS%
2. In "URI::from_
"file:/
and then initialized as an URI object.
3. "URI::getFullPath" is called for the docbase URI object, and itself calls "_impl->getPath()" that returns:
"/C:/Documents and Settings/
4. "URI::getFullPath" tests the path, and as it's an invalid path, clears it.
5. Another URI object is created for the profile path. "_impl->getPath()" returns:
"\WINDOWS\
Invalid again, the path is clears.
6. "cmsOpenProfile
Replacing:
gchar* fullname = g_uri_unescape_
with:
gchar* fullname = g_uri_unescape_
fixes the issue on Windows XP, with profiles linked as absolute path. But of course, it would be better to fix the issue in the URI creation.
Changed in inkscape: | |
milestone: | 0.92 → 0.93 |
Another possibility to fix the profile path (but not the docbase). More elegant, but really needs some extra testing.
--- src/color- profile. cpp 2016-06-14 12:33:17 +0000 profile. cpp 2016-11-25 17:43:52 +0000
//# 1. Get complete URI of document
gchar const *docbase = doc->getURI();
+++ src/color-
@@ -314,7 +314,7 @@
- gchar* escaped = g_uri_escape_ string( this->href, "!*'();:@=+$,/?#", TRUE); string( this->href, NULL, TRUE);
+ gchar* escaped = g_uri_escape_