summaryrefslogtreecommitdiff
path: root/iup/srclua5/il_pplot.c
diff options
context:
space:
mode:
authorPixel <pixel@nobis-crew.org>2009-11-04 11:56:41 -0800
committerPixel <pixel@nobis-crew.org>2009-11-04 11:59:33 -0800
commitd577d991b97ae2b5ee1af23641bcffc3f83af5b2 (patch)
tree590639d50205d1bcfaff2a7d2dc6ebf3f373c7ed /iup/srclua5/il_pplot.c
Initial import. Contains the im, cd and iup librairies, and a "working" Makefile for them under linux.
Diffstat (limited to 'iup/srclua5/il_pplot.c')
-rwxr-xr-xiup/srclua5/il_pplot.c151
1 files changed, 151 insertions, 0 deletions
diff --git a/iup/srclua5/il_pplot.c b/iup/srclua5/il_pplot.c
new file mode 100755
index 0000000..8929d33
--- /dev/null
+++ b/iup/srclua5/il_pplot.c
@@ -0,0 +1,151 @@
+/******************************************************************************
+ * Automatically generated file (iuplua5). Please don't change anything. *
+ *****************************************************************************/
+
+#include <stdlib.h>
+
+#include <lua.h>
+#include <lauxlib.h>
+
+#include "iup.h"
+#include "iuplua.h"
+#include "iup_pplot.h"
+#include "il.h"
+
+
+static int pplot_edit_cb(Ihandle *self, int p0, int p1, float p2, float p3, float p4, float p5)
+{
+ lua_State *L = iuplua_call_start(self, "edit_cb");
+ lua_pushnumber(L, p0);
+ lua_pushnumber(L, p1);
+ lua_pushnumber(L, p2);
+ lua_pushnumber(L, p3);
+ lua_pushnumber(L, p4);
+ lua_pushnumber(L, p5);
+ return iuplua_call(L, 6);
+}
+
+static int pplot_deleteend_cb(Ihandle *self)
+{
+ lua_State *L = iuplua_call_start(self, "deleteend_cb");
+ return iuplua_call(L, 0);
+}
+
+static int pplot_selectbegin_cb(Ihandle *self)
+{
+ lua_State *L = iuplua_call_start(self, "selectbegin_cb");
+ return iuplua_call(L, 0);
+}
+
+static int pplot_postdraw_cb(Ihandle *self, int p0)
+{
+ lua_State *L = iuplua_call_start(self, "postdraw_cb");
+ lua_pushnumber(L, p0);
+ return iuplua_call(L, 1);
+}
+
+static int pplot_delete_cb(Ihandle *self, int p0, int p1, float p2, float p3)
+{
+ lua_State *L = iuplua_call_start(self, "delete_cb");
+ lua_pushnumber(L, p0);
+ lua_pushnumber(L, p1);
+ lua_pushnumber(L, p2);
+ lua_pushnumber(L, p3);
+ return iuplua_call(L, 4);
+}
+
+static int pplot_predraw_cb(Ihandle *self, int p0)
+{
+ lua_State *L = iuplua_call_start(self, "predraw_cb");
+ lua_pushnumber(L, p0);
+ return iuplua_call(L, 1);
+}
+
+static int pplot_selectend_cb(Ihandle *self)
+{
+ lua_State *L = iuplua_call_start(self, "selectend_cb");
+ return iuplua_call(L, 0);
+}
+
+static int pplot_select_cb(Ihandle *self, int p0, int p1, float p2, float p3, int p4)
+{
+ lua_State *L = iuplua_call_start(self, "select_cb");
+ lua_pushnumber(L, p0);
+ lua_pushnumber(L, p1);
+ lua_pushnumber(L, p2);
+ lua_pushnumber(L, p3);
+ lua_pushnumber(L, p4);
+ return iuplua_call(L, 5);
+}
+
+static int pplot_deletebegin_cb(Ihandle *self)
+{
+ lua_State *L = iuplua_call_start(self, "deletebegin_cb");
+ return iuplua_call(L, 0);
+}
+
+static int pplot_editbegin_cb(Ihandle *self)
+{
+ lua_State *L = iuplua_call_start(self, "editbegin_cb");
+ return iuplua_call(L, 0);
+}
+
+static int pplot_editend_cb(Ihandle *self)
+{
+ lua_State *L = iuplua_call_start(self, "editend_cb");
+ return iuplua_call(L, 0);
+}
+
+static int PPlot(lua_State *L)
+{
+ Ihandle *ih = IupPPlot();
+ iuplua_plugstate(L, ih);
+ iuplua_pushihandle_raw(L, ih);
+ return 1;
+}
+
+void iuplua_pplotfuncs_open(lua_State *L);
+
+int iuppplotlua_open(lua_State * L)
+{
+ iuplua_register(L, PPlot, "PPlot");
+
+ iuplua_register_cb(L, "EDIT_CB", (lua_CFunction)pplot_edit_cb, "pplot");
+ iuplua_register_cb(L, "DELETEEND_CB", (lua_CFunction)pplot_deleteend_cb, NULL);
+ iuplua_register_cb(L, "SELECTBEGIN_CB", (lua_CFunction)pplot_selectbegin_cb, NULL);
+ iuplua_register_cb(L, "POSTDRAW_CB", (lua_CFunction)pplot_postdraw_cb, NULL);
+ iuplua_register_cb(L, "DELETE_CB", (lua_CFunction)pplot_delete_cb, NULL);
+ iuplua_register_cb(L, "PREDRAW_CB", (lua_CFunction)pplot_predraw_cb, NULL);
+ iuplua_register_cb(L, "SELECTEND_CB", (lua_CFunction)pplot_selectend_cb, NULL);
+ iuplua_register_cb(L, "SELECT_CB", (lua_CFunction)pplot_select_cb, NULL);
+ iuplua_register_cb(L, "DELETEBEGIN_CB", (lua_CFunction)pplot_deletebegin_cb, NULL);
+ iuplua_register_cb(L, "EDITBEGIN_CB", (lua_CFunction)pplot_editbegin_cb, NULL);
+ iuplua_register_cb(L, "EDITEND_CB", (lua_CFunction)pplot_editend_cb, NULL);
+
+ iuplua_pplotfuncs_open(L);
+
+#ifdef IUPLUA_USELOH
+#ifdef TEC_BIGENDIAN
+#ifdef TEC_64
+#include "loh/pplot_be64.loh"
+#else
+#include "loh/pplot_be32.loh"
+#endif
+#else
+#ifdef TEC_64
+#ifdef WIN64
+#include "loh/pplot_le64w.loh"
+#else
+#include "loh/pplot_le64.loh"
+#endif
+#else
+#include "loh/pplot.loh"
+#endif
+#endif
+#else
+ iuplua_dofile(L, "pplot.lua");
+#endif
+
+ return 0;
+}
+