Age | Commit message (Collapse) | Author |
|
|
|
shouldn't have collapsed them
|
|
This reverts commit 37fd2628058f296153a21ad359fbcbc74e9141e5.
|
|
|
|
D1337 by @lichtwerk
|
|
Term pointer is overloaded already.
|
|
|
|
menu.
When active, all editing operators for markers will not fire up.
|
|
markers present
The function to get a list of markers was not clearing the list before it exited
early, and with no way to tell that the method failed, callers could make the
mistake of trusting that the list was now valid (i.e. either full of marker
frames or empty, vs being invalid)
|
|
|
|
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.
|
|
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
|
|
- avoid 2x glScalef per marker
- skip markers outside the view
- merge drawing into a single loop
|
|
|
|
|
|
Operators that trigger UI events (but nothing else)
were using 'CANCELLED' making it impossible to tell if an invoke
function failed, or opened a menu.
|
|
assumes translations are in meters.
Turned out there were several issues in handling of scale parameter by numinput.
Fixed that by factorizing more some code in common with 'usual' numbuttons eval code
(new `bUnit_getScaleUnit()` helper will return valid scaled value, depending on
given system and type).
Now, numinput behaves as expected - using default unit amended by scale in case no unit is given
(i.e. entering '20' with a scale of 0.01 will give you 20cm, and '20cm' as well!).
|
|
ops.
Also stumbled uppon 'move marker' code, was needing a bunch of fixes, cleanup and simplification,
and added a candy feature - now you will enter numinput values in seconds when editor is
in 'time' mode, instead of frames!
|
|
|
|
|
|
|
|
|
|
|
|
|
|
View2D had some inconsistencies making it error prone in some cases.
- Inconstant checking for NULL x/y args.
Disallow NULL args for x/y destination pointers, instead add:
- UI_view2d_region_to_view_x/y
- UI_view2d_view_to_region_x/y
- '_no_clip' suffix wasn't always used for non-clipping conversion,
switch it around and use a '_clip' suffix for all funcs that clip.
- UI_view2d_text_cache_add now clips before adding cache.
- '_clip' funcs return a bool to quickly check if its in the view.
- add conversion for rectangles, since this is a common task:
- UI_view2d_view_to_region_rcti
- UI_view2d_region_to_view_rctf
|
|
|
|
|
|
also increase precision of rctf print functions
|
|
Summary:
This completly changes the way modal numinput is handled. Now, edited expression is a string, which then gets unit- and py-evaluated to get a float value.
We gain many power and flexibility, but lose a few "shortcuts" like '-' to negate, or '/' to inverse (if they are really needed, we still can add them with modifiers, like e.g. ctrl-/ or so).
Features:
- units (cm, ", deg, etc.).
- basic operations from python/BKE_unit (+, *, **, etc.), and math constants and functions (pi, sin, etc.).
- you can navigate in edited value (left/right key, ctrl to move by block) and insert/delete chars, e.g. to fix a typo without having to rewrite everything.
- you can go to next/previous value with (ctrl-)TAB key.
- As before, hitting backspace after having deleted all leading chars will first reset the edited value to init state, and on second press, the whole "modal numinput" editing will be cancelled, going back to usual transform with mouse.
Notes:
- Did not touch to how values are shown in header when modal numinput is not enabled (would do that in another commit), so this is still quite inconsistent.
- Added back radian support in BKE_unit.
- Added arcminute/arcsecond to BKE_unit.
(those unit changes affect all angle UI controls, btw, so you can now enter radians or longitude/latitude values when in degrees units).
Related to T37600.
Reviewers: brecht, campbellbarton, carter2422
Reviewed By: brecht, campbellbarton, carter2422
Thanks everybody!
Differential Revision: http://developer.blender.org/D61
|
|
The keymap here used WM_keymap_verify_item(), which only allows for a
single hotkey to be bound to an operator. In most cases, this really
isn't justified.
|
|
|
|
rename change/is_change/is_changed/modified -> changed
also use bools over int/short/char and once accidental float.
|
|
|
|
OPERATOR_CANCELLED.
|
|
guaranted. Also heavily simplified it (previous code was supposed to have optimizations, but ended just looping twice over the markers' list...).
Many thanks to Brecht and Sergey for noting the quirk and reviews! :)
|
|
doesn't appear to work.
Init min/max values were just switched...
|
|
I'd disabled this for 2.68 since it caused bug [#36109].
This fix now only enabled text activation for popups. (so the toolbar textboxes are skipped)
|
|
sizeof() use in BLI_array.h
|
|
|
|
BLI_testextensie_glob every time in the file selector with a blank string.
|
|
|
|
same frame
also add macros for looping on listbases as if they were circular lists which is handy for cycling over items.
|
|
|
|
|
|
|
|
|
|
|
|
Simply clamp label position from bottom.
|
|
|
|
The operator names all show up in the Search button. As such is nicer if they
can all have the main words capitalized.
e.g. "Snap strips" should be "Snap Strips"
"Copy to clipboard" should be "Copy to Clipboard"
This was done with a mix of bash tools, regex, and manual work because I'm too rushed into regex :)
+ fix bge stereo eye separation tooltip
|