BPython - first step for better integration of Python in Blender:

- add a new space: Space Script
- add a new dna struct: Script
- add these two properly everywhere they are meant to

It's not a tiny commit, but most of it is ground work for what is still to be done.
Right now the benefits should be: freeing the Text Editor to be used in a window even while a script w/ gui in "on" and letting more than one currently running script w/ gui be accessible from each window

Some files are added, so some build systems (not autotools) will need updates
This commit is contained in:
2003-12-14 01:18:09 +00:00
parent 6653af7914
commit 49021f7ec4
36 changed files with 1656 additions and 883 deletions

View File

@@ -46,10 +46,12 @@
#include "BMF_Api.h"
#include "DNA_screen_types.h"
#include "DNA_script_types.h"
#include "DNA_space_types.h"
#include "DNA_text_types.h"
#include "BKE_global.h"
#include "BKE_library.h"
#include "BIF_gl.h"
#include "BIF_screen.h"
@@ -77,7 +79,6 @@ int g_window_redrawn;
static char Draw_doc[] =
"The Blender.Draw submodule";
static void exit_pydraw (SpaceText *st);
static uiBlock *Get_uiBlock (void);
void initDraw (void);
@@ -119,13 +120,14 @@ static Button *newbutton (void);
/* GUI interface routines */
static void exit_pydraw(SpaceText *st);
static void exec_callback(SpaceText *st, PyObject *callback, PyObject *args);
void BPY_spacetext_do_pywin_draw(SpaceText *st);
static void spacetext_do_pywin_buttons(SpaceText *st, unsigned short event);
void BPY_spacetext_do_pywin_event(SpaceText *st,
unsigned short event, short val);
int BPY_spacetext_is_pywin(SpaceText *sc);
static void exit_pydraw(SpaceScript *sc, short error);
static void exec_callback(SpaceScript *sc, PyObject *callback, PyObject *args);
/* these are declared in ../BPY_extern.h */
void BPY_spacescript_do_pywin_draw(SpaceScript *sc);
static void spacescript_do_pywin_buttons(SpaceScript *sc, unsigned short event);
void BPY_spacescript_do_pywin_event(SpaceScript *sc, unsigned short event, short val);
void BPY_free_compiled_text(Text *text);
static char Method_Exit_doc[] =
"() - Exit the windowing interface";