diff options
author | Daniel Salazar <zanqdo@gmail.com> | 2010-02-11 19:28:31 +0300 |
---|---|---|
committer | Daniel Salazar <zanqdo@gmail.com> | 2010-02-11 19:28:31 +0300 |
commit | 6286e415146f1325207f764b4b9f8c92996cc4a6 (patch) | |
tree | 3daecf6e71fc63400ae8978289a37b39c1f99481 /source/blender/editors | |
parent | 9ee81473f8ce2e08027a50c8b0f42c49fbc3499e (diff) |
Theme support for console background. Thx cam for help!
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/interface/resources.c | 3 | ||||
-rw-r--r-- | source/blender/editors/space_console/space_console.c | 7 |
2 files changed, 6 insertions, 4 deletions
diff --git a/source/blender/editors/interface/resources.c b/source/blender/editors/interface/resources.c index 785cb6384ac..02d8ae43d4f 100644 --- a/source/blender/editors/interface/resources.c +++ b/source/blender/editors/interface/resources.c @@ -353,6 +353,8 @@ char *UI_ThemeGetColorPtr(bTheme *btheme, int spacetype, int colorid) cp= ts->console_info; break; case TH_CONSOLE_ERROR: cp= ts->console_error; break; + case TH_BACK: + cp= ts->console_back; break; case TH_HANDLE_VERTEX: cp= ts->handle_vertex; @@ -621,6 +623,7 @@ void ui_theme_init_userdef(void) SETCOL(btheme->tconsole.console_input, 255, 255, 255, 255); SETCOL(btheme->tconsole.console_info, 0, 170, 0, 255); SETCOL(btheme->tconsole.console_error, 220, 96, 96, 255); + SETCOL(btheme->tconsole.console_back, 0, 0, 0, 255); /* space sound */ diff --git a/source/blender/editors/space_console/space_console.c b/source/blender/editors/space_console/space_console.c index ea1d6667d11..4e9427de6f4 100644 --- a/source/blender/editors/space_console/space_console.c +++ b/source/blender/editors/space_console/space_console.c @@ -162,15 +162,14 @@ static void console_main_area_draw(const bContext *C, ARegion *ar) SpaceConsole *sc= CTX_wm_space_console(C); View2D *v2d= &ar->v2d; View2DScrollers *scrollers; - //float col[3]; + float col[3]; if((sc->type==CONSOLE_TYPE_PYTHON) && (sc->scrollback.first==NULL)) WM_operator_name_call((bContext *)C, "CONSOLE_OT_banner", WM_OP_EXEC_DEFAULT, NULL); /* clear and setup matrix */ - //UI_GetThemeColor3fv(TH_BACK, col); - //glClearColor(col[0], col[1], col[2], 0.0); - glClearColor(0, 0, 0, 1.0); + UI_GetThemeColor3fv(TH_BACK, col); + glClearColor(col[0], col[1], col[2], 1.0); glClear(GL_COLOR_BUFFER_BIT); console_update_rect(C, ar); |