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:
authorTon Roosendaal <ton@blender.org>2009-04-12 17:40:29 +0400
committerTon Roosendaal <ton@blender.org>2009-04-12 17:40:29 +0400
commit5cb480cef44bc4ec3d191f114622af04bba6285d (patch)
tree788654e26024cfacb0431314d716362bd317f4f1 /source/blender/editors/space_image
parent1fec143198d34dd50a55ef313f2daf55a75cd414 (diff)
2.5
Various ui fixes: - panel drawing now correctly follows scaled view - made imagewindow buttons using TH_PANEL color back (was too dark) - click on open/close panel was wrong - menu items disabling now draws correct - curve/hsv widgets didn't draw on right locations - numsliders have nicer interior slider decoration - new type TOGBUT to enforce old style toggle button (not new type 'option button' with checkmark - (temp) disabled live updating while using Curve widget, was too slow to be fun. Needs general solution :)
Diffstat (limited to 'source/blender/editors/space_image')
-rw-r--r--source/blender/editors/space_image/image_header.c8
-rw-r--r--source/blender/editors/space_image/image_panels.c10
-rw-r--r--source/blender/editors/space_image/space_image.c2
3 files changed, 10 insertions, 10 deletions
diff --git a/source/blender/editors/space_image/image_header.c b/source/blender/editors/space_image/image_header.c
index 0319b18eed4..a243d958b33 100644
--- a/source/blender/editors/space_image/image_header.c
+++ b/source/blender/editors/space_image/image_header.c
@@ -744,23 +744,23 @@ void image_header_buttons(const bContext *C, ARegion *ar)
uiBlockSetEmboss(block, UI_EMBOSSP);
xmax= GetButStringLength("View");
- uiDefMenuBut(block, image_viewmenu, NULL, "View", xco, yco-2, xmax-3, 24, "");
+ uiDefMenuBut(block, image_viewmenu, NULL, "View", xco, yco, xmax-3, 20, "");
xco+= xmax;
if(show_uvedit) {
xmax= GetButStringLength("Select");
- uiDefMenuBut(block, image_selectmenu, NULL, "Select", xco, yco-2, xmax-3, 24, "");
+ uiDefMenuBut(block, image_selectmenu, NULL, "Select", xco, yco, xmax-3, 20, "");
xco+= xmax;
}
menuname= (ibuf && (ibuf->userflags & IB_BITMAPDIRTY))? "Image*": "Image";
xmax= GetButStringLength(menuname);
- uiDefMenuBut(block, image_imagemenu, NULL, menuname, xco, yco-2, xmax-3, 24, "");
+ uiDefMenuBut(block, image_imagemenu, NULL, menuname, xco, yco, xmax-3, 20, "");
xco+= xmax;
if(show_uvedit) {
xmax= GetButStringLength("UVs");
- uiDefMenuBut(block, image_uvsmenu, NULL, "UVs", xco, yco-2, xmax-3, 24, "");
+ uiDefMenuBut(block, image_uvsmenu, NULL, "UVs", xco, yco, xmax-3, 20, "");
xco+= xmax;
}
}
diff --git a/source/blender/editors/space_image/image_panels.c b/source/blender/editors/space_image/image_panels.c
index 5d387bffcf0..62144293b41 100644
--- a/source/blender/editors/space_image/image_panels.c
+++ b/source/blender/editors/space_image/image_panels.c
@@ -1357,13 +1357,13 @@ void ED_image_uiblock_panel(const bContext *C, uiBlock *block, Image **ima_pp, I
/* fields */
uiBlockBeginAlign(block);
- but= uiDefButBitS(block, TOG, IMA_FIELDS, imagechanged, "Fields", 10, 70, 65, 20, &ima->flag, 0, 0, 0, 0, "Click to enable use of fields in Image");
+ but= uiDefButBitS(block, TOGBUT, IMA_FIELDS, imagechanged, "Fields", 10, 70, 65, 20, &ima->flag, 0, 0, 0, 0, "Click to enable use of fields in Image");
uiButSetFunc(but, image_field_test, ima, iuser);
- uiDefButBitS(block, TOG, IMA_STD_FIELD, B_NOP, "Odd", 75, 70, 45, 20, &ima->flag, 0, 0, 0, 0, "Standard Field Toggle");
+ uiDefButBitS(block, TOGBUT, IMA_STD_FIELD, B_NOP, "Odd", 75, 70, 45, 20, &ima->flag, 0, 0, 0, 0, "Standard Field Toggle");
uiBlockSetFunc(block, image_reload_cb, ima, iuser);
- uiDefButBitS(block, TOG, IMA_ANTIALI, B_NOP, "Anti", 10, 50, 45, 20, &ima->flag, 0, 0, 0, 0, "Toggles Image anti-aliasing, only works with solid colors");
- uiDefButBitS(block, TOG, IMA_DO_PREMUL, imagechanged, "Premul", 55, 50, 65, 20, &ima->flag, 0, 0, 0, 0, "Toggles premultiplying alpha");
+ uiDefButBitS(block, TOGBUT, IMA_ANTIALI, B_NOP, "Anti", 10, 50, 45, 20, &ima->flag, 0, 0, 0, 0, "Toggles Image anti-aliasing, only works with solid colors");
+ uiDefButBitS(block, TOGBUT, IMA_DO_PREMUL, imagechanged, "Premul", 55, 50, 65, 20, &ima->flag, 0, 0, 0, 0, "Toggles premultiplying alpha");
uiBlockEndAlign(block);
if( ELEM(ima->source, IMA_SRC_MOVIE, IMA_SRC_SEQUENCE)) {
@@ -1395,7 +1395,7 @@ void ED_image_uiblock_panel(const bContext *C, uiBlock *block, Image **ima_pp, I
uiBlockSetFunc(block, image_generated_change_cb, ima, iuser);
uiDefButS(block, NUM, imagechanged, "SizeX:", 120,70,100,20, &ima->gen_x, 1.0, 5000.0, 0, 0, "Image size x");
uiDefButS(block, NUM, imagechanged, "SizeY:", 220,70,90,20, &ima->gen_y, 1.0, 5000.0, 0, 0, "Image size y");
- uiDefButS(block, TOG, imagechanged, "UV Test grid",120,50,190,20, &ima->gen_type, 0.0, 1.0, 0, 0, "");
+ uiDefButS(block, TOGBUT, imagechanged, "UV Test grid",120,50,190,20, &ima->gen_type, 0.0, 1.0, 0, 0, "");
uiBlockSetFunc(block, NULL, NULL, NULL);
}
}
diff --git a/source/blender/editors/space_image/space_image.c b/source/blender/editors/space_image/space_image.c
index 77017979de7..fab9317bbd0 100644
--- a/source/blender/editors/space_image/space_image.c
+++ b/source/blender/editors/space_image/space_image.c
@@ -496,7 +496,7 @@ static void image_buttons_area_draw(const bContext *C, ARegion *ar)
float col[3];
/* clear */
- UI_GetThemeColor3fv(TH_BACK, col);
+ UI_GetThemeColor3fv(TH_PANEL, col);
glClearColor(col[0], col[1], col[2], 0.0);
glClear(GL_COLOR_BUFFER_BIT);