Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2006-01-11 19:55:31 +0300
committerCampbell Barton <ideasman42@gmail.com>2006-01-11 19:55:31 +0300
commit74ed4024908dfd2ab82ad842e9289c823aea94ad (patch)
tree9ddac400d9231ee93cefb9247b504ab196d9e280 /source/blender/src/toolbox.c
parentfbc977e48ca210cd232971bc766ae8f23110de68 (diff)
Exclude labels from grouping. - Clever numbuts look nicer with rounded theme.
Diffstat (limited to 'source/blender/src/toolbox.c')
-rw-r--r--source/blender/src/toolbox.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/source/blender/src/toolbox.c b/source/blender/src/toolbox.c
index b4692ca9964..973a01d9187 100644
--- a/source/blender/src/toolbox.c
+++ b/source/blender/src/toolbox.c
@@ -1347,6 +1347,9 @@ int do_clever_numbuts(char *name, int tot, int winevent)
/* WATCH IT: TEX BUTTON EXCEPTION */
/* WARNING: ONLY A SINGLE BIT-BUTTON POSSIBLE: WE WORK AT COPIED DATA! */
+
+ BIF_ThemeColor(TH_MENU_TEXT); /* makes text readable on dark theme */
+
uiDefBut(block, LABEL, 0, name, (short)(x1+15), (short)(y2-35), (short)(sizex-60), 19, 0, 1.0, 0.0, 0, 0, "");
/*
@@ -1358,12 +1361,22 @@ int do_clever_numbuts(char *name, int tot, int winevent)
uiBlockBeginAlign(block);
varstr= &numbuts[0];
for(a=0; a<tot; a++, varstr++) {
+
if(varstr->type==TEX) {
uiDefBut(block, TEX, 0, varstr->name,(short)(x1+15),(short)(y2-55-20*a),(short)(sizex-60), 19, numbpoin[a], varstr->min, varstr->max, 0, 0, varstr->tip);
}
else {
+
+ if(varstr->type==LABEL) /* dont include the label when rounding the buttons */
+ uiBlockEndAlign(block);
+
uiDefBut(block, varstr->type, 0, varstr->name,(short)(x1+15),(short)(y2-55-20*a), (short)(sizex-60), 19, &(numbdata[a]), varstr->min, varstr->max, 100, 0, varstr->tip);
+
+ if(varstr->type==LABEL)
+ uiBlockBeginAlign(block);
}
+
+
}
uiBlockEndAlign(block);