summaryrefslogtreecommitdiffstats
path: root/ganv/item.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2014-04-26 16:49:15 +0000
committerDavid Robillard <d@drobilla.net>2014-04-26 16:49:15 +0000
commit65b14544b89afc3a7d3a7de57e6ef15ca8165bd0 (patch)
treeaff9e8f19197c83df67ff723ea154b7573880cdb /ganv/item.h
parentfb3498abb00ed3cf5c5938fcb1bffef163674274 (diff)
downloadganv-65b14544b89afc3a7d3a7de57e6ef15ca8165bd0.tar.gz
ganv-65b14544b89afc3a7d3a7de57e6ef15ca8165bd0.tar.bz2
ganv-65b14544b89afc3a7d3a7de57e6ef15ca8165bd0.zip
Clean up Ganv API.
git-svn-id: http://svn.drobilla.net/lad/trunk/ganv@5367 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'ganv/item.h')
-rw-r--r--ganv/item.h30
1 files changed, 10 insertions, 20 deletions
diff --git a/ganv/item.h b/ganv/item.h
index 83b5f3c..3e57662 100644
--- a/ganv/item.h
+++ b/ganv/item.h
@@ -28,7 +28,10 @@
G_BEGIN_DECLS
+struct _GanvCanvas;
+
typedef struct _GanvItem GanvItem;
+typedef struct _GanvItemImpl GanvItemImpl;
typedef struct _GanvItemClass GanvItemClass;
/* Object flags for items */
@@ -49,25 +52,8 @@ enum {
#define GANV_ITEM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), GANV_TYPE_ITEM, GanvItemClass))
struct _GanvItem {
- GtkObject object;
-
- /* Parent canvas for this item */
- struct _GanvCanvas* canvas;
-
- /* Parent for this item */
- GanvItem* parent;
-
- /* Layer (z order), higher values are on top */
- guint layer;
-
- /* Position in parent-relative coordinates. */
- double x, y;
-
- /* Bounding box for this item (in world coordinates) */
- double x1, y1, x2, y2;
-
- /* True if parent manages this item (don't call add/remove) */
- gboolean managed;
+ GtkObject object;
+ GanvItemImpl* impl;
};
struct _GanvItemClass {
@@ -136,7 +122,7 @@ struct _GanvItemClass {
gboolean (*event)(GanvItem* item, GdkEvent* event);
/* Reserved for future expansion */
- gpointer spare_vmethods [4];
+ gpointer spare_vmethods[4];
};
GType ganv_item_get_type(void) G_GNUC_CONST;
@@ -152,6 +138,10 @@ void ganv_item_set(GanvItem* item, const gchar* first_arg_name, ...);
void ganv_item_set_valist(GanvItem* item,
const gchar* first_arg_name, va_list args);
+struct _GanvCanvas* ganv_item_get_canvas(GanvItem* item);
+
+GanvItem* ganv_item_get_parent(GanvItem* item);
+
void ganv_item_raise(GanvItem* item);
void ganv_item_lower(GanvItem* item);