From bab4cd69913eee9aa30d61db7dc46e21655e4bde Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 28 Feb 2009 13:27:45 +0000 Subject: Python experimental UI API Can draw panels in the scripts space containing RNA and operator buttons. * Added bpyui.register() so scripts can draw buttons and panels into the scripts space type. * wrapped drawBlock, drawPanels and matchPanelsView2d * Operator buttons take a python dictionary used to set the button defaults. * BPY_getFileAndNum utility function to get the filename and line number python is currently running. --- source/blender/python/BPY_extern.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'source/blender/python/BPY_extern.h') diff --git a/source/blender/python/BPY_extern.h b/source/blender/python/BPY_extern.h index 35dba84d553..219ab2d3c41 100644 --- a/source/blender/python/BPY_extern.h +++ b/source/blender/python/BPY_extern.h @@ -95,7 +95,14 @@ extern "C" { int BPY_menu_do_python( short menutype, int event ); int BPY_menu_do_shortcut( short menutype, unsigned short key, unsigned short modifiers ); int BPY_menu_invoke( struct BPyMenu *pym, short menutype ); - void BPY_run_python_script( struct bContext *C, const char *filename ); + + /* 2.5 UI Scripts */ + void BPY_run_python_script( struct bContext *C, const char *filename ); // 2.5 working + int BPY_run_script_space_draw(struct bContext *C, struct SpaceScript * sc); // 2.5 working +// int BPY_run_script_space_listener(struct bContext *C, struct SpaceScript * sc, struct ARegion *ar, struct wmNotifier *wmn); // 2.5 working + + + int BPY_run_script(struct Script *script); void BPY_free_compiled_text( struct Text *text ); -- cgit v1.2.3