summaryrefslogtreecommitdiffstats
path: root/src/sp-object.cpp
diff options
context:
space:
mode:
authorJohan B. C. Engelen <jbc.engelen@swissonline.ch>2014-11-25 21:39:57 +0000
committerJohan B. C. Engelen <j.b.c.engelen@alumnus.utwente.nl>2014-11-25 21:39:57 +0000
commitc1e2bbe2ed5d8b7cddd69b80ee20c7d39ab20c44 (patch)
tree1746030d151c4266a3f7797866c72fc5d557c816 /src/sp-object.cpp
parentMore C++ string usage. (diff)
downloadinkscape-c1e2bbe2ed5d8b7cddd69b80ee20c7d39ab20c44.tar.gz
inkscape-c1e2bbe2ed5d8b7cddd69b80ee20c7d39ab20c44.zip
More c++ string usage.
(bzr r13763)
Diffstat (limited to 'src/sp-object.cpp')
-rw-r--r--src/sp-object.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/sp-object.cpp b/src/sp-object.cpp
index 024fce85a..4e45eb824 100644
--- a/src/sp-object.cpp
+++ b/src/sp-object.cpp
@@ -1254,6 +1254,16 @@ void SPObject::setAttribute(gchar const *key, gchar const *value, SPException *e
//XML Tree being used here.
getRepr()->setAttribute(key, value, false);
}
+void SPObject::setAttribute(char const *key, Glib::ustring const &value, SPException *ex)
+{
+ setAttribute(key, value.empty() ? NULL : value.c_str(), ex);
+}
+void SPObject::setAttribute(Glib::ustring const &key, Glib::ustring const &value, SPException *ex)
+{
+ setAttribute( key.empty() ? NULL : key.c_str(),
+ value.empty() ? NULL : value.c_str(), ex);
+}
+
void SPObject::removeAttribute(gchar const *key, SPException *ex)
{