summaryrefslogtreecommitdiff
path: root/src/xwidget.h
diff options
context:
space:
mode:
authorJoakim Verona <joakim@verona.se>2010-06-18 15:32:32 +0200
committerJoakim Verona <joakim@verona.se>2010-06-18 15:32:32 +0200
commitea113b66ba333a891d6653f1ab34c95b8a52b536 (patch)
tree31d7d759b2ef5b87cca1b66a752365bfdc9a4fc9 /src/xwidget.h
parent85350e06b0c0de0e774ce6e4e7713b309938f248 (diff)
downloademacs-ea113b66ba333a891d6653f1ab34c95b8a52b536.tar.gz
initial move from git to bzr
Diffstat (limited to 'src/xwidget.h')
-rw-r--r--src/xwidget.h61
1 files changed, 61 insertions, 0 deletions
diff --git a/src/xwidget.h b/src/xwidget.h
new file mode 100644
index 00000000000..acceb720108
--- /dev/null
+++ b/src/xwidget.h
@@ -0,0 +1,61 @@
+void x_draw_xwidget_glyph_string P_ ((struct glyph_string *s));
+void syms_of_xwidget ();
+
+extern Lisp_Object Qxwidget;
+/* Test for xwidget (xwidget . spec) (car must be the symbol xwidget)*/
+#define XWIDGETP(x) (CONSP (x) && EQ (XCAR (x), Qxwidget))
+
+int valid_xwidget_p (Lisp_Object object) ;
+
+#include <gtk/gtk.h>
+
+/*
+each xwidget instance 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;
+ GtkContainer* emacswindow;
+};
+
+
+struct xwidget_type
+{
+ /* A symbol uniquely identifying the xwidget type, */
+ Lisp_Object *type;
+
+ /* Check that SPEC is a valid image specification for the given
+ image type. Value is non-zero if SPEC is valid. */
+ int (* valid_p) P_ ((Lisp_Object spec));
+
+ /* Next in list of all supported image types. */
+ struct xwidget_type *next;
+};
+
+
+static INLINE 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_modify_region();
+
+void xwidget_touch(struct xwidget* xw);
+void xwidget_delete(struct xwidget* xw);
+void assert_valid_xwidget_id(int id,char *str);