summaryrefslogtreecommitdiffstats
path: root/src/sp-guide.cpp
diff options
context:
space:
mode:
authorGeoff Lankow <geoff@darktrojan.net>2015-07-07 09:22:31 +0000
committerGeoff Lankow <geoff@darktrojan.net>2015-07-07 09:22:31 +0000
commit43f80e25517651b82754e3b05303dacff0c03a10 (patch)
treeb6be78397c84152c8eee77a6129a5f91cff6df1a /src/sp-guide.cpp
parentFix compilation failure in make check (diff)
downloadinkscape-43f80e25517651b82754e3b05303dacff0c03a10.tar.gz
inkscape-43f80e25517651b82754e3b05303dacff0c03a10.zip
Read inkscape:color attribute on guides
(bzr r14228.1.1)
Diffstat (limited to 'src/sp-guide.cpp')
-rw-r--r--src/sp-guide.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/sp-guide.cpp b/src/sp-guide.cpp
index 4e1c5913d..83e723e5c 100644
--- a/src/sp-guide.cpp
+++ b/src/sp-guide.cpp
@@ -26,6 +26,7 @@
#include "display/sp-canvas.h"
#include "display/guideline.h"
#include "svg/svg.h"
+#include "svg/svg-color.h"
#include "svg/stringstream.h"
#include "attributes.h"
#include "sp-guide.h"
@@ -70,6 +71,7 @@ void SPGuide::build(SPDocument *document, Inkscape::XML::Node *repr)
{
SPObject::build(document, repr);
+ this->readAttr( "inkscape:color" );
this->readAttr( "inkscape:label" );
this->readAttr( "orientation" );
this->readAttr( "position" );
@@ -95,6 +97,9 @@ void SPGuide::release()
void SPGuide::set(unsigned int key, const gchar *value) {
switch (key) {
+ case SP_ATTR_INKSCAPE_COLOR:
+ this->setColor(sp_svg_read_color(value, 0x0000ff00) | 0x7f);
+ break;
case SP_ATTR_INKSCAPE_LABEL:
if (this->label) g_free(this->label);