diff options
author | Micksha <ms-shaman@gmx.de> | 2019-01-04 21:37:34 +0100 |
---|---|---|
committer | Micksha <ms-shaman@gmx.de> | 2019-04-13 19:53:49 +0000 |
commit | 168ad9d6c730e93d76c801da607df84355187a39 (patch) | |
tree | b771ad105e5a73733ede7559e22467f13a2880a8 /saedit/spritedrawingarea/spritedrawingarea.h | |
parent | 8c75e651f00048dda32db85b2bff34e131960864 (diff) | |
download | evol-tools-168ad9d6c730e93d76c801da607df84355187a39.tar.gz evol-tools-168ad9d6c730e93d76c801da607df84355187a39.tar.bz2 evol-tools-168ad9d6c730e93d76c801da607df84355187a39.tar.xz evol-tools-168ad9d6c730e93d76c801da607df84355187a39.zip |
update saedit to saedit2
Diffstat (limited to 'saedit/spritedrawingarea/spritedrawingarea.h')
-rw-r--r-- | saedit/spritedrawingarea/spritedrawingarea.h | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/saedit/spritedrawingarea/spritedrawingarea.h b/saedit/spritedrawingarea/spritedrawingarea.h new file mode 100644 index 0000000..ee3aa6d --- /dev/null +++ b/saedit/spritedrawingarea/spritedrawingarea.h @@ -0,0 +1,71 @@ +#ifndef __SPRITE_DRAWING_AREA_H__ +#define __SPRITE_DRAWING_AREA_H__ + +#include <gdk/gdk.h> +#include <gtk/gtk.h> +#include "sdalayer.h" + +G_BEGIN_DECLS + +#define TYPE_SPRITE_DRAWING_AREA (sprite_drawing_area_get_type ()) +#define SPRITE_DRAWING_AREA(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SPRITE_DRAWING_AREA, SpriteDrawingArea)) +#define SPRITE_DRAWING_AREA_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SPRITE_DRAWING_AREA, SpriteDrawingAreaClass)) +#define IS_SPRITE_DRAWING_AREA(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SPRITE_DRAWING_AREA)) +#define IS_SPRITE_DRAWING_AREA_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SPRITE_DRAWING_AREA)) +#define SPRITE_DRAWING_AREA_GET_CLASS(obj) ((obj), TYPE_SPRITE_DRAWING_AREA, SpriteDrawingAreaClass) + +typedef struct _SpriteDrawingArea SpriteDrawingArea; +typedef struct _SpriteDrawingAreaPrivate SpriteDrawingAreaPrivate; +typedef struct _SpriteDrawingAreaClass SpriteDrawingAreaClass; + +struct _SpriteDrawingArea { + GtkDrawingArea darea; + + SpriteDrawingAreaPrivate *priv; +}; + +struct _SpriteDrawingAreaClass { + GtkDrawingAreaClass darea_class; + + void (* draw_field) ( + GtkWidget *sdarea, + gpointer data + ); +}; + +static const gint SPRITE_DRAWING_AREA_FIELD_SIZE = 1024; + +GType +sprite_drawing_area_get_type (void); + +GtkWidget* +sprite_drawing_area_new (void); + +void +sprite_drawing_area_set_scale_factor ( + SpriteDrawingArea *sdarea, + gdouble scale_factor +); + +void +sprite_drawing_area_add_layer ( + SpriteDrawingArea *sdarea, + SDALayer *layer +); + +void +sprite_drawing_area_remove_layer ( + SpriteDrawingArea *sdarea, + SDALayer *layer +); + +void +sprite_drawing_area_set_center ( + SpriteDrawingArea *sdarea, + gint center_x, + gint center_y +); + +G_END_DECLS + +#endif |