diff options
author | Jonathon Jongsma <jjongsma@gnome.org> | 2010-12-30 17:27:18 -0600 |
---|---|---|
committer | Jonathon Jongsma <jjongsma@gnome.org> | 2010-12-30 17:28:52 -0600 |
commit | cc99d6a9d32a28861292b56217339c0f6df9362e (patch) | |
tree | e3011059bfc4211d8fb60343c33030873fd50358 | |
parent | 61ffb52e696d8885abb17e505f1ec98bffbd2c11 (diff) |
Wrap cairo_region_xor_*
-rw-r--r-- | cairomm/region.cc | 12 | ||||
-rw-r--r-- | cairomm/region.h | 4 |
2 files changed, 16 insertions, 0 deletions
diff --git a/cairomm/region.cc b/cairomm/region.cc index 1233f2c..55b6154 100644 --- a/cairomm/region.cc +++ b/cairomm/region.cc @@ -182,6 +182,18 @@ void Region::do_union(const RectangleInt& rectangle) check_status_and_throw_exception (status); } +void Region::do_xor(const RefPtr<Region>& other) +{ + ErrorStatus status = cairo_region_xor(m_cobject, (other ? other->cobj() : 0)); + check_status_and_throw_exception (status); +} + +void Region::do_xor(const RectangleInt& rectangle) +{ + ErrorStatus status = cairo_region_xor_rectangle(m_cobject, &rectangle); + check_status_and_throw_exception (status); +} + } //namespace Cairo diff --git a/cairomm/region.h b/cairomm/region.h index 67b891b..37d7b21 100644 --- a/cairomm/region.h +++ b/cairomm/region.h @@ -92,6 +92,10 @@ public: void do_union(const RectangleInt& rectangle); + void do_xor(const RefPtr<Region>& other); + + void do_xor(const RectangleInt& rectangle); + typedef cairo_region_t cobject; |