1 // -*- mode: C++; indent-tabs-mode: nil; c-basic-offset: 2; -*-
9 #include "otk/point.hh"
10 #include "otk/rect.hh"
63 // *** MotionData can be (and is) cast ButtonData!! (in actions.cc) *** //
79 int press_clientwidth;
80 int press_clientheight;
83 // *** MotionData can be (and is) cast ButtonData!! (in actions.cc) *** //
112 void python_init(char *argv0);
113 void python_destroy();
114 bool python_exec(const std::string &path);
116 MotionData *new_motion_data(int screen, Window window, Time time,
117 unsigned int state, unsigned int button,
118 MouseContext context, MouseAction action,
119 int xroot, int yroot, const otk::Point &initpos,
120 const otk::Rect &initarea);
121 ButtonData *new_button_data(int screen, Window window, Time time,
122 unsigned int state, unsigned int button,
123 MouseContext context, MouseAction action);
124 EventData *new_event_data(int screen, Window window, EventAction action,
126 KeyData *new_key_data(int screen, Window window, Time time, unsigned int state,
129 void python_callback(PyObject *func, PyObject *data);
131 bool python_get_long(const char *name, long *value);
132 bool python_get_string(const char *name, std::string *value);
133 bool python_get_stringlist(const char *name, std::vector<std::string> *value);
136 PyObject *mbind(const std::string &button, ob::MouseContext context,
137 ob::MouseAction action, PyObject *func);
139 PyObject *kbind(PyObject *keylist, ob::KeyContext context, PyObject *func);
141 PyObject *ebind(ob::EventAction action, PyObject *func);
143 void set_reset_key(const std::string &key);
147 #endif // __python_hh