Age | Commit message (Collapse) | Author |
|
Scene buttons).
Reported by sebastian_k through IRC, thanks!
|
|
|
|
|
|
|
|
Both were maked as temp, but used often.
Now pass uiFontStyle to both, rename UI_draw_string to UI_fontstyle_draw_simple,
since its a variant of UI_fontstyle_draw that skips shadow, align... etc.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Recent flag re-order broke it since bits overlap, but logic here was far too complicated & fragile,
Checked the type of each button when testing which direction to handle events as well as block direction.
Now store the block-flipped state as a flag.
|
|
Make the UI API more consistent and reduce confusion with some naming.
mainly:
- API function calls
- enum values
some internal static functions have been left for now
|
|
|
|
If user drags away from initial position, menu changes to drag style and
returning to that position won't remake the menu click-style. Allows to
use the threshold indicator to cancel the pie.
|
|
Make pie menu item placement touch the radius from the internal side of
the buttons rather than placing on the center on the cirtcle. This
allows us to get rid of the separate visual angle property, also allows
for tighter placement of pies with a smaller radius without easily
overlapping.
Also pie menu title now always appears above the threshold indicator.
|
|
This commit merges the code in the pie-menu branch.
As per decisions taken the last few days, there are no pie menus
included and there will be an official add-on including overrides of
some keys with pie menus. However, people will now be able to use the
new code in python.
Full Documentation is in http://wiki.blender.org/index.php/Dev:Ref/
Thanks:
Campbell Barton, Dalai Felinto and Ton Roosendaal for the code review
and design comments
Jonathan Williamson, Pawel Lyczkowski, Pablo Vazquez among others for
suggestions during the development.
Special Thanks to Sean Olson, for his support, suggestions, testing and
merciless bugging so that I would finish the pie menu code. Without him
we wouldn't be here. Also to the rest of the developers of the original
python add-on, Patrick Moore and Dan Eicher and finally to Matt Ebb, who
did the research and first implementation and whose code I used to get
started.
|
|
We do have odd behaviors with name and expanded enums, but in this case it did
not made any sense at all! :)
Note the error was not in RNA, but in C UILayout api itself...
|
|
|
|
This is needed for popups to chance state once activated,
currently it makes use of operators `check` callback, after values are modified,
as the file selector does already.
|
|
|
|
Missed setting the flag for operator-menus.
Now call `ui_but_add_shortcut` to match the rest of the api.
|
|
also remove redundant loop in BKE_pose_copy_data
|
|
|
|
This deduplicates/simplifies some code. Also cleanup up a bit scopes UI code!
Use new GRIP button for uiList grab-resize.
This allows us to greatly simplifies the code, and get rid of a few hacks in uiList event handling!
Note autosize mode of uiList is now trigered by any value of list_grip below a given threshold, rather than the fixed zero value...
Reviewers: brecht
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D343
|
|
|
|
|
|
Enum icon-only buttons were getting their strings set,
then truncated with blenders string shortening methods, then not drawn
because there was no room (since buttons are icon width).
Modify UI code so icon-only buttons don't get names and passing "" to a
button won't have its text set later on.
|
|
|
|
Allow menu functions to define their own direction, this way
menu_item_enum_opname_menu can keep menu flipping from 2.69.
|
|
|
|
|
|
|
|
|
|
Adds some padding to the left of the icon, adds more space around the separator
line and make it more visible, and add some spacing at the top and bottom of
the menu. Ref T37794
Reviewed By: dingto, billrey
Differential Revision: https://developer.blender.org/D223
|
|
|
|
|
|
This also was in the info header but less obvious, mistake in the layout engine.
|
|
drawn shifted to the right.
Reported by plasmasolution over IRC, thanks.
Also fixes wrong handling of "sub-titles" with icons in EnumO menus (they were just treated as text-only ones).
Dev notes: in fact, that clean up commit revealed kind of an "hidden bug that happend to work well"
(or at least, a very bad hack): with titles without icon, code used to use uiItemL with ICON_NONE.
However, as the root layout is a menu one, internal ui code would add a dummy blank icon,
and set UI_HAS_ICON flag for the label button. But in the affected menus, code afterward assigned
UI_TEXT_LEFT to but->flag, thus erasing the (internal) UI_HAS_ICON. As UI_TEXT_LEFT was moved to
but->drawflag, the internal flag was no more erased, and the fake icon was drawn, creating that
shift-to-the-right effect. Turns out we do not even have to set UI_TEXT_LEFT in these cases,
just add label buttons without icon is enough!
|
|
was often making much too big strings to show in a tip.
|
|
Summary:
More information here:
http://lists.blender.org/pipermail/bf-committers/2013-November/042113.html
Reviewers: brecht
Reviewed By: brecht
CC: mont29
Differential Revision: http://developer.blender.org/D8
|
|
|
|
commit b8b7180760b7c57f15b9930c29207febcf5fefb3
Author: Bastien Montagne <montagne29@wanadoo.fr>
Date: Thu Nov 21 16:31:16 2013 +0100
Code cleanup: replace "LISTLABEL" button type by an "UI_BUT_LIST_ITEM" button flag.
Summary:
Rationals:
I) I was never that happy to have a full button type just to set custom colors to labels inside listitems!
II) If we use (as planned) TEX buttons instead of labels to allow listitems click-rename, I'd like to be able to use listitems' theme color here as well, much easier witha flag than adding yet another button type!
Note: related to D8
Reviewers: brecht
Differential Revision: http://developer.blender.org/D25
|
|
commit 6f97e194e58aab38d351c796bf7bb6abca33f5f9
Author: Bastien Montagne <montagne29@wanadoo.fr>
Date: Wed Nov 20 21:18:20 2013 +0100
Code cleanup: Move some uiBut->flag to uiBut->drawflag, make those flags anonymous enums.
Summary:
Make some room in but->flag (I did not add another flag, we already have drawflag, which was nearly not used up till now).
Note: I’m not sure whether REDALERT (and perhaps even DISABLED?) should not go to but->drawflag as well...
Related to D8
Reviewers: brecht
Differential Revision: http://developer.blender.org/D22
|
|
Patch by Jose Molina Garcia (sentinel), with style fixes by myself.
|
|
|
|
get colored as active (need recursion in sublayouts!). Was affecting e.g. Group node inputs/outputs lists.
|
|
values of args
Refactored a bit WM api to generate operator's pystring, now it can also handle correctly macro operators. Thanks to Campbell for the review!
|
|
completly inconsistent, but again, better to do such changes (soft-breaking API) in bulk...
|
|
enums is not consistent with other properties, as there labels are never shown. Keep it for now, though, as this would break many scripts and ui file, better to do this in bulk!
Thanks to DingTo and plasmasolutions for notifying the issue.
|