summaryrefslogtreecommitdiff
path: root/src/xwidget.h
diff options
context:
space:
mode:
authorJoakim Verona <joakim@verona.se>2011-06-22 02:03:38 +0200
committerJoakim Verona <joakim@verona.se>2011-06-22 02:03:38 +0200
commit479d2bf9a9887d6b3d59ba077cb0ad564b180e07 (patch)
tree4a7a38d313eb611830fa12f2d31f83e8e5627b5b /src/xwidget.h
parenta7513ade3bc0fe79430d5541d88c9dcda0932bec (diff)
downloademacs-479d2bf9a9887d6b3d59ba077cb0ad564b180e07.tar.gz
trying to revert the composition code and mowe to mvc. now compiles but far from functional. dont bother trying yet.
Diffstat (limited to 'src/xwidget.h')
-rw-r--r--src/xwidget.h47
1 files changed, 30 insertions, 17 deletions
diff --git a/src/xwidget.h b/src/xwidget.h
index 3852103d78d..c66568eaac0 100644
--- a/src/xwidget.h
+++ b/src/xwidget.h
@@ -9,28 +9,42 @@ int valid_xwidget_p (Lisp_Object object) ;
#include <gtk/gtk.h>
+
/*
-each xwidget instance is described by this struct.
+each xwidget instance/model is described by this struct.
*/
struct xwidget{
int id;
int type;
- int hidden;
- GtkWidget* widget;
- GtkContainer* widgetwindow;
-
char* title;
- int initialized;
+
+
int height;
int width;
- int x; int y;
- Lisp_Object message_hook;
- int redisplayed;
+ int initialized;
+};
+
+
+//struct for each xwidget view
+struct xwidget_view{
+ struct xwidget* model;
+
+ int hidden;//if the "live" instance isnt drawn
+ int redisplayed; //if touched by redisplay
+ int initialized;
+
+ GtkWidget* widget;
+ GtkContainer* widgetwindow;
GtkContainer* emacswindow;
+ int x; int y;
int clipx; int clipy;
+ struct window *w;
};
+
+
+
struct xwidget_type
{
/* A symbol uniquely identifying the xwidget type, */
@@ -44,19 +58,18 @@ struct xwidget_type
struct xwidget_type *next;
};
-
-static INLINE struct xwidget_type *lookup_xwidget_type (Lisp_Object symbol);
-
-
+static struct xwidget_type *lookup_xwidget_type (Lisp_Object symbol);
struct xwidget* xwidget_from_id(int id);
extern int xwidget_owns_kbd;
-void xwidget_start_redisplay();
-void xwidget_end_redisplay(struct glyph_matrix* matrix);
+void xwidget_start_redisplay();
+void xwidget_end_redisplay(struct glyph_matrix* matrix);
void xwidget_modify_region();
-void xwidget_touch(struct xwidget* xw);
-void xwidget_delete(struct xwidget* xw);
+void xwidget_touch (struct xwidget_view *xw);
+
void assert_valid_xwidget_id(int id,char *str);
+
+int lookup_xwidget (Lisp_Object spec);