[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [34471] trunk/blender/source/blender/ editors/interface/interface_widgets.c: Small fix for text input buttons:
Ton Roosendaal
ton at blender.org
Sun Jan 23 20:20:11 CET 2011
Revision: 34471
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=34471
Author: ton
Date: 2011-01-23 19:20:10 +0000 (Sun, 23 Jan 2011)
Log Message:
-----------
Small fix for text input buttons:
Number buttons, in text input mode, now also align internally
like text buttons.
Modified Paths:
--------------
trunk/blender/source/blender/editors/interface/interface_widgets.c
Modified: trunk/blender/source/blender/editors/interface/interface_widgets.c
===================================================================
--- trunk/blender/source/blender/editors/interface/interface_widgets.c 2011-01-23 17:25:27 UTC (rev 34470)
+++ trunk/blender/source/blender/editors/interface/interface_widgets.c 2011-01-23 19:20:10 UTC (rev 34471)
@@ -1110,7 +1110,10 @@
if(but==NULL) return;
/* clip but->drawstr to fit in available space */
- if (ELEM4(but->type, NUM, NUMABS, NUMSLI, SLI)) {
+ if (but->editstr && but->pos >= 0) {
+ ui_text_leftclip(fstyle, but, rect);
+ }
+ else if (ELEM4(but->type, NUM, NUMABS, NUMSLI, SLI)) {
ui_text_label_rightclip(fstyle, but, rect);
}
else if (ELEM(but->type, TEX, SEARCH_MENU)) {
More information about the Bf-blender-cvs
mailing list