diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2016-03-14 16:47:47 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2016-03-14 16:47:47 +0000 |
| commit | fee7ec667cc353e1efda6a1a92f1f4715836fa4f (patch) | |
| tree | 63fe115530cd3f8511b29cf2e250fcf23dc8fe08 /src/color-profile.cpp | |
| parent | update credits (diff) | |
| parent | "Relative to" option for node alignment. (diff) | |
| download | inkscape-fee7ec667cc353e1efda6a1a92f1f4715836fa4f.tar.gz inkscape-fee7ec667cc353e1efda6a1a92f1f4715836fa4f.zip | |
update to trunk
(bzr r13682.1.32)
Diffstat (limited to 'src/color-profile.cpp')
| -rw-r--r-- | src/color-profile.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/color-profile.cpp b/src/color-profile.cpp index 690a72654..bcefe994a 100644 --- a/src/color-profile.cpp +++ b/src/color-profile.cpp @@ -271,6 +271,7 @@ void ColorProfile::build(SPDocument *document, Inkscape::XML::Node *repr) { SPObject::build(document, repr); this->readAttr( "xlink:href" ); + this->readAttr( "id" ); this->readAttr( "local" ); this->readAttr( "name" ); this->readAttr( "rendering-intent" ); @@ -488,18 +489,17 @@ static int getLcmsIntent( guint svgIntent ) static SPObject* bruteFind( SPDocument* document, gchar const* name ) { SPObject* result = 0; - const GSList * current = document->getResourceList("iccprofile"); - while ( current && !result ) { - if ( IS_COLORPROFILE(current->data) ) { - ColorProfile* prof = COLORPROFILE(current->data); + std::set<SPObject *> current = document->getResourceList("iccprofile"); + for (std::set<SPObject *>::const_iterator it = current.begin(); (!result) && (it != current.end()); ++it) { + if ( IS_COLORPROFILE(*it) ) { + ColorProfile* prof = COLORPROFILE(*it); if ( prof ) { if ( prof->name && (strcmp(prof->name, name) == 0) ) { - result = SP_OBJECT(current->data); + result = SP_OBJECT(*it); break; } } } - current = g_slist_next(current); } return result; |
