summaryrefslogtreecommitdiffstats
path: root/src/xml
diff options
context:
space:
mode:
authorTomasz Boczkowski <penginsbacon@gmail.com>2015-05-02 09:43:24 +0000
committerTomasz Boczkowski <penginsbacon@gmail.com>2015-05-02 09:43:24 +0000
commit4ae263b8d394775ff631efaacc835346af1ffdae (patch)
tree8c54527cb2698ade852a3286e84692fc29b74ad8 /src/xml
parentmerged gtk3 compile fix (diff)
parentsp-text: Whitespace cleanup (diff)
downloadinkscape-4ae263b8d394775ff631efaacc835346af1ffdae.tar.gz
inkscape-4ae263b8d394775ff631efaacc835346af1ffdae.zip
merge with trunk
(bzr r14059.1.12)
Diffstat (limited to 'src/xml')
-rw-r--r--src/xml/repr-util.cpp5
-rw-r--r--src/xml/repr.h2
2 files changed, 7 insertions, 0 deletions
diff --git a/src/xml/repr-util.cpp b/src/xml/repr-util.cpp
index 7c5d2d6fc..4cbe930a1 100644
--- a/src/xml/repr-util.cpp
+++ b/src/xml/repr-util.cpp
@@ -310,6 +310,11 @@ int sp_repr_compare_position(Inkscape::XML::Node const *first, Inkscape::XML::No
pjrm */
}
+bool sp_repr_compare_position_bool(Inkscape::XML::Node const *first, Inkscape::XML::Node const *second){
+ return sp_repr_compare_position(first, second)<0;
+}
+
+
/**
* Find an element node using an unique attribute.
*
diff --git a/src/xml/repr.h b/src/xml/repr.h
index c3ba40e45..17763195a 100644
--- a/src/xml/repr.h
+++ b/src/xml/repr.h
@@ -120,7 +120,9 @@ unsigned sp_repr_set_svg_length(Inkscape::XML::Node *repr, char const *key, SVGL
unsigned sp_repr_set_point(Inkscape::XML::Node *repr, char const *key, Geom::Point const & val);
unsigned sp_repr_get_point(Inkscape::XML::Node *repr, char const *key, Geom::Point *val);
+//c++-style comparison : returns (bool)(a<b)
int sp_repr_compare_position(Inkscape::XML::Node const *first, Inkscape::XML::Node const *second);
+bool sp_repr_compare_position_bool(Inkscape::XML::Node const *first, Inkscape::XML::Node const *second);
// Searching
/**