diff options
author | Willian Padovani Germano <wpgermano@gmail.com> | 2006-12-30 21:28:49 +0300 |
---|---|---|
committer | Willian Padovani Germano <wpgermano@gmail.com> | 2006-12-30 21:28:49 +0300 |
commit | 91b2bc5c2344220aa395d5e7d6e2fd5c777b6218 (patch) | |
tree | 8c593d3d29da0b391e3f123dff9743a7266e7847 /source/blender/python/api2_2x/windowTheme.c | |
parent | 822a88959bb2961ec1b5391b1fd01ebbece7b1df (diff) |
Python API:
-Added missing access to Node win theme (thanks Mickaƫl Le-bihan for pointing) and also options group and group_active.
-Added Node space to Window.Types dict.
-Tiny update to the save theme script version numbers (keeping 2.42 for now to avoid popups, but should change to 2.43 right before release).
BTW: Happy New Year everyone :).
Diffstat (limited to 'source/blender/python/api2_2x/windowTheme.c')
-rw-r--r-- | source/blender/python/api2_2x/windowTheme.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/source/blender/python/api2_2x/windowTheme.c b/source/blender/python/api2_2x/windowTheme.c index 985af8b3c11..dfcf26ed5cb 100644 --- a/source/blender/python/api2_2x/windowTheme.c +++ b/source/blender/python/api2_2x/windowTheme.c @@ -47,7 +47,7 @@ #define EXPP_THEME_DRAWTYPE_MIN 1 #define EXPP_THEME_DRAWTYPE_MAX 4 -#define EXPP_THEME_NUMBEROFTHEMES 15 +#define EXPP_THEME_NUMBEROFTHEMES 16 static const EXPP_map_pair themes_map[] = { {"ui", -1}, {"buts", SPACE_BUTS}, @@ -64,6 +64,7 @@ static const EXPP_map_pair themes_map[] = { {"text", SPACE_TEXT}, {"oops", SPACE_OOPS}, {"time", SPACE_TIME}, + {"node", SPACE_NODE}, {NULL, 0} }; @@ -159,9 +160,11 @@ static PyObject *ThemeSpace_getAttr( BPy_ThemeSpace * self, char *name ) ELSEIF_TSP_RGBA( hilite ) ELSEIF_TSP_RGBA( grid ) ELSEIF_TSP_RGBA( wire ) - ELSEIF_TSP_RGBA( lamp ) ELSEIF_TSP_RGBA( select ) + ELSEIF_TSP_RGBA( lamp ) ELSEIF_TSP_RGBA( active ) + ELSEIF_TSP_RGBA( group ) + ELSEIF_TSP_RGBA( group_active ) ELSEIF_TSP_RGBA( transform ) ELSEIF_TSP_RGBA( vertex ) ELSEIF_TSP_RGBA( vertex_select ) @@ -195,17 +198,19 @@ static PyObject *ThemeSpace_getAttr( BPy_ThemeSpace * self, char *name ) else if( !strcmp( name, "facedot_size" ) ) attrib = Py_BuildValue( "i", tsp->facedot_size ); else if( !strcmp( name, "__members__" ) ) - attrib = Py_BuildValue("[sssssssssssssssssssssssssssssssssssssssssss]", "theme", + attrib = Py_BuildValue("[ssssssssssssssssssssssssssssssssssssssssssssss]", "theme", "back", "text", "text_hi", "header", "panel", "shade1", "shade2", "hilite", - "grid", "wire", "lamp", "select", "active", + "grid", "wire", "select", "lamp", "active", + "group", "group_active", "transform", "vertex", "vertex_select", "edge", "edge_select", "edge_seam", "edge_facesel", "face", "face_select", "face_dot", "normal", "bone_solid", "bone_pose", "strip", "strip_select", "syntaxl", "syntaxn", "syntaxb", "syntaxv", "syntaxc", - "movie", "image", "scene", "audio", "effect", "plugin", "transition", "meta", + "movie", "image", "scene", "audio", "effect", "plugin", + "transition", "meta", "vertex_size", "facedot_size" ); if( attrib != Py_None ) @@ -233,9 +238,11 @@ static int ThemeSpace_setAttr( BPy_ThemeSpace * self, char *name, ELSEIF_TSP_RGBA( hilite ) ELSEIF_TSP_RGBA( grid ) ELSEIF_TSP_RGBA( wire ) - ELSEIF_TSP_RGBA( lamp ) ELSEIF_TSP_RGBA( select ) + ELSEIF_TSP_RGBA( lamp ) ELSEIF_TSP_RGBA( active ) + ELSEIF_TSP_RGBA( group ) + ELSEIF_TSP_RGBA( group_active ) ELSEIF_TSP_RGBA( transform ) ELSEIF_TSP_RGBA( vertex ) ELSEIF_TSP_RGBA( vertex_select ) @@ -741,6 +748,9 @@ static PyObject *Theme_get( BPy_Theme * self, PyObject * args ) case SPACE_TIME: tsp = &btheme->ttime; break; + case SPACE_NODE: + tsp = &btheme->tnode; + break; } if( tui ) { |