[clutter] docs: Warn users of ClutterGeometry
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clutter] docs: Warn users of ClutterGeometry
- Date: Sat, 11 Aug 2012 11:35:10 +0000 (UTC)
commit f5760842773f9db3b6cca436b921b97b52699171
Author: Emmanuele Bassi <ebassi gnome org>
Date: Thu Aug 9 16:56:19 2012 +0100
docs: Warn users of ClutterGeometry
The Geometry type is an *awful* representation of a integer rectangle,
as it uses unsigned integers for its size, leading to overflow issues
when unioning and intersecting. We have better rectangle types in
Cairo and Clutter, these days.
clutter/clutter-types.h | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/clutter/clutter-types.h b/clutter/clutter-types.h
index e7ede14..3020568 100644
--- a/clutter/clutter-types.h
+++ b/clutter/clutter-types.h
@@ -536,6 +536,10 @@ void clutter_actor_box_set_size (ClutterActorBox *box,
* @height: height of an actor
*
* The rectangle containing an actor's bounding box, measured in pixels.
+ *
+ * <warning>You should not use #ClutterGeometry, or operate on its fields
+ * directly; you should use #cairo_rectangle_int_t or #ClutterRect if you
+ * need a rectangle type, depending on the precision required.</warning>
*/
struct _ClutterGeometry
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]