Age | Commit message (Collapse) | Author |
|
This is still far from prefect, but yet much better than what we had so
far (more consistent with inheritent precision available in floats).
Note that this fixes some (currently commented out) units unittests, and
requires adjusting some others, will be done in next commit.
|
|
* Numbers with units (especially, angles) where not handled correctly
regarding number of significant digits (spotted by @brecht in T52222
comment, thanks).
* Zero value has no valid log, need to take that into account!
|
|
|
|
The purpose of the keymap strings is probably for un-embossed menu items
like seen in most pulldowns. I can't see a reason for also adding that
string for regularly drawn buttons within popups, we don't add it
anywhere else in the UI either. So this commit makes sure shortcut
strings are only added to buttons that are drawn like pulldown-menu
items.
|
|
While drawing nice 'rounded' values is OK also for 'low precision'
editing like dragging and such, it's quite an issue when you type in a
precise value, validate, edit again the value, and find a rounded
version of it instead of what you typed in!
So now, *only when entering textedit of num buttons*, we always get the highest
reasonable precision for floats (and use exponential notation when
values are too low or too high, to avoid tremendous amounts of zero's).
|
|
|
|
|
|
|
|
This reverts commit f5bc8ad4ce87165fc0648f1cd8c0ae1fb5f07281.
We agreed there needs to be a better solution for this, see comments in
rBf5bc8ad4ce87165.
|
|
|
|
|
|
|
|
|
|
|
|
Reported by coverity scan.
|
|
This is useful e.g. for search buttons to quickly clear the filter string. We might want to make this optional for python scripts.
|
|
This commit allows RNA properties to return additional info on their editable state which may then be displayed in tooltips. To show how it works, it also adds some info for the editable check of proxies. For generally un-editable properties or properties of a linked data-block, RNA returns default strings.
| {F362785} | {F362786} | {F362787} |
Reviewed by brecht, thanks!
Differential Revision: https://developer.blender.org/D2243
|
|
* Rename uiBut.lockstr to disabled_info
* Remove unreachable code
* Replace duplicated check with assert
* Replace overly ambitious check with assert
* Add comments
|
|
Old leftover from pre 2.5 days. Now handled through UI_BUT_DISABLED button flag.
|
|
|
|
Quiets assert
|
|
|
|
F-Curves easier
Now, when trying to insert a keyframe on a driven property (using IKEY, or with
autokeying enabled), the keyframes will get created on the Driver's F-Curve
(instead of creating a new FCurve that goes into the active action, but will never
do anything). Furthermore, the x-value of the new keyframe will be the current
result of the driver expression.
Why/Motivations:
This way, it becomes easier to create corrective drivers, as you can position all
the targets the driver depends on, then adjust the driver value until it does what
you need, and then you keyframe that value to bake it into the Driver F-Curve
(in effect, "training" the computer how to behave in that case).
Usage Notes:
* In practice, that particular workflow is still quite clunky to achieve, due to some
quirks of how the driver system and the UI widgets interact. Specifically, you'll
need to disable/mute the driver before trying to edit the setting (to prevent the
driver from immediately resetting the value - before even autokey fires!). However,
if you're using the Graph Editor to preview/monitor/manage the keying process, you'll
then want to re-enable the driver before changing the targets, so that you can see
how much of a change you'll want to be applying!
* The warning about editing driver values may need to be disabled or selectively
knocked out. I had it disabled while testing this functionality, but it's actually
harmless in its current state (if just a bit annoying).
|
|
|
|
Search buttons would overwrite existing callbacks, even when they weren't needed.
Causing missing updates for search buttons in pop-ups.
|
|
|
|
Was caused by d49985c.
|
|
Gives better context especially when operators have generic names.
|
|
Needed to support alternate search UI's, no functional changes.
|
|
wmOrtho2_region_pixelspace and wmOrtho2_region_ui were doing exact same thing since rBSa86482f81cf3.
|
|
Displaying a button would clamp the value if the button was outside the range.
This could be OK in some cases,
however it's problematic with object dimensions which would re-scale objects on showing the panel.
Add `ui_but_update_edited` when its OK to modify the value.
|
|
Useful for progress ETA to continuously update.
This adds API option not to activate new regions GL state which isn't needed in many cases.
|
|
|
|
enum-search popup menu.
|
|
Also use doxy formatting for warning/note.
|
|
have it.
|
|
Use BPY_execute_* prefix for all Python execution commands
|
|
in tooltip.
Also related to T46918.
|
|
|
|
|
|
|
|
RNA could define strings as dynamically sized,
but the interface ignored this and clamped them to UI_MAX_DRAW_STR.
Fixes T46734, also fixes possible pasting non-utf8 text into utf8 buttons.
|
|
This new code fixes a tons of issues with previous one, which basically was epic-failing
in many non-basic cases (especially mixed columns and rows with column-dominant layout).
It basically no more relies over order of buttons declaration in the uiBlock, instead it
finds and stores spatial neighbors and uses that data to compute needed stitching.
See code comments for details.
New code seems to be roughly ten times slower than old one (for complex grouped layouts),
that is, about a few microsecconds per alignment group - this remains reasonable.
Also, ui-align code becomming rather big in itself, it was separated in
own new `interface_align.c` file.
Reviewers: campbellbarton, severin
Reviewed By: campbellbarton, severin
Differential Revision: https://developer.blender.org/D1573
|
|
label when active.
Poll function of that keymap was slightly... agressive.
|
|
progress bar at all).
|
|
- remove NULL checks for args already set as ATTR_NONNULL.
- double promotion.
|
|
Popups were clamped be screen-margin,
then clipped by UI_POPUP_MENU_TOP, causing regular popups
not to have enough room & add scroll buttons.
|
|
Strings exceeding UI_MAX_DRAW_STR weren't null terminated.
|
|
The user interface was ignoring the precision step size for degrees,
making all rotation inputs drag by a 100th of a degree.
Now use a 10th of a degree instead.
|
|
|