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
AgeCommit message (Collapse)Author
2021-06-25Cleanup: make formatDalai Felinto
string.c still needs cleanup, but I will leave to the original author of the latest chagnes to do it since it needs some tags to skip formatting.
2021-06-25Spreadsheet: Dataset region for spreadsheet editorFabian Schempp
This patch adds a left aligned sidebar to the spreadsheet editor. This Sidebar can be used to navigate the geometry component types and attribute domains. It also provides a quick overview of domain sizes. It replaces the two dropdowns in the regions header. Next step will be to add the domain cycling shortcut using the CTRL + mouse wheel. Reviewer: Dalai Felinto (dfelinto), Julian Eisel (Severin), Hans Goudey (HooglyBoogly). Differential Revision: https://developer.blender.org/D11046
2021-06-24Cleanup: comment blocks, trailing space in commentsCampbell Barton
2021-06-24Cleanup: remove outdated/redundant commentsCampbell Barton
2021-06-23Fix T89265: Crash when tabbing through num inputsFalk David
Fix by reverting the part of ec30cf0b742f5181c4de91b474ca01d6a809c593 that assigned `but->editval` in `ui_numedit_begin_set_values`. Causing access freed memory when using tab to switch to a numeric input and then leaving the textbox by clicking outside. This was because `ui_numedit_begin_set_values` shouldn't need to set `but->editval` and overwrite the pointer. This would set a pointer that had previously been freed, causing a `NULL` check to fail later on. Ref D11679
2021-06-23Cleanup: reformat trailing comments that caused line wrappingCampbell Barton
2021-06-22Cleanup: Spelling MistakesLeon Zandman
This patch fixes many minor spelling mistakes, all in comments or console output. Mostly contractions like can't, won't, don't, its/it's, etc. Differential Revision: https://developer.blender.org/D11663 Reviewed by Harley Acheson
2021-06-19Spreadsheet Editor: Row FiltersHans Goudey
This patch adds support for filtering rows based on rules and values. Filters will work for any attribute data source, they are a property of the spreadsheet rather than of the attribute system. The properties displayed in the row filter can depend on data type of the currently visible column with that name. If the name is no longer visible, the row filter filter is grayed out, but it will remember the value until a column with its name is visible again. Note: The comments in `screen.c` combined with tagging the sidebar for redraw after the main region point to a lack of understanding or technical debt, that is a point to improve in the future. **Future Improvements** * T89272: A search menu for visible columns when adding a new filter. * T89273: Possibly a "Range" operation. Differential Revision: https://developer.blender.org/D10959
2021-06-18Fix Build WarningHarley Acheson
Removal of unused local variable. Calculation of underline thickness no longer needed with change to text output of underscore character. Introduced in aee04d496035 Differential Revision: https://developer.blender.org/D11641
2021-06-18Fix T89246: No Mnemonic Underlines in DialogsHarley Acheson
When drawing mnemonic underlines for hotkeys, use text output of underscore character instead of direct drawing a line. Otherwise these are not visible in dialog buttons. Introduced in 0fcc063fd99c Differential Revision: https://developer.blender.org/D11641 Reviewed by Campbell Barton
2021-06-17Cleanup: spellingCampbell Barton
2021-06-16Edge-scrolling for node editorLukas Tönne
Starts scrolling when dragging a node or node link and going outside the current window. Largely copied from the VIEW2D_OT_edge_pan operator. Edge panning operator customdata and supporting functions now in UI_view2d.h, so they could be used by operators in other editor libraries. The VIEW2D_OT_edge_pan operator also uses this customdata and shared functions now. Operators properties can be used to configure edge panning margins and speed for each use case, rather than using hardcoded values. The speed function for edge panning has been tweaked somewhat: * "Speed per pixel" has been replaced with a "speed ramp" distance. This is more intuitive and also creates an upper bound for the speed, which can otherwise become extreme with large cursor distance. * "Max speed" is reached at the end of the speed ramp. * Padding the region inside and outside is applied as before, but both values are operator properties now. Node transform operator also supports edge panning. This requires an offset for changes in the view2d rect, otherwise nodes are "stuck" to the original view. Transform operator had cursor wrapping categorically enabled, but this gets quite confusing with the edge scrolling mechanism. A new TransInfo option T_NO_CURSOR_WRAP has been introduced to disable this behavior. The double negative is a bit annoying, but want to avoid affecting the existing transform modes, so by default it should still set the OP_IS_MODAL_GRAB_CURSOR flag (which then sets the WM_CURSOR_WRAP_XY flag during modal execution). Reviewed By: HooglyBoogly, JacquesLucke Differential Revision: https://developer.blender.org/D11073
2021-06-15UI: Support right aligned non-shortcut hints in widgetsJulian Eisel
Widget drawing code already supported drawing right-aligned, grayed out shortcut strings. This patch generalizes things a bit so this can also be used to draw other hints in the same way. There have been a few instances in the past where this would've been useful, D11046 being the latest one. Note that besides some manual regression testing, I didn't check if this works yet, as there is no code actually using it (other than the shortcuts). Can be checked as part of further development for D11046. A possible further improvement would be providing a way to define how clipping should be done. E.g. sometimes the right-aligned text should be clipped first (because it's just a hint), in other cases it should be left untouched (like current code explicitly does it for shortcuts). Removes the `UI_BUT_HAS_SHORTCUT` flag, which isn't needed anymore.
2021-06-11Add option to link assets on drag & dropJulian Eisel
Note: Linking in this case as in link vs. append. Easily confused with linking a data-block to multiple usages (e.g. single material used by multiple objects). Adds a drop-down to the Asset Browser header to choose between Link and Append. This is probably gonna be a temporary place, T54642 shows where this could be placed eventually. Linking support is crucial for usage of the asset browser in production environments. It just wasn't enabled yet because a) the asset project currently focuses on single user, not production assets, and b) because there were many unkowns still for the workflow that have big impact on production use as well. With the recently held asset workshop I'm more confident with enabling linking, as design ideas relevant to production use were confirmed. Differential Revision: https://developer.blender.org/D11536 Reviewed by: Bastien Montagne
2021-06-09Cleanup: missing NULL check in assertCampbell Barton
2021-06-09Cleanup: redundant/unused assignmentsCampbell Barton
2021-06-08Cleanup: Silent compile warning in `interface_widgets.c`.Jeroen Bakker
2021-06-07Fix T88801: Positioning of Menu UnderlinesHarley Acheson
This patch improves the positioning of the little mnemonic underlines shown under some hotkey letters in menus, especially when using custom fonts. see D11521 for details and examples. Differential Revision: https://developer.blender.org/D11521 Reviewed by Campbell Barton
2021-06-03Fix T88762: UI using tab to enter next button could clamp the hard min/Philipp Oeser
max unneccessarily Since rB298d5eb66916 [which was needed to update buttons with custom property range functions correctly], using tab would always clamp (hardmin/hardmax) properties which were using FLT_MAX / INT_MAX as range in their property definitions. The clamping of rB298d5eb66916 was copied over from rB9b7f44ceb56c [where it was used for the softmin/softmax], and while the re-evaluation of hardmin/hardmax is needed for custom property range functions, the clamping should actually not take place. There are many properties using FLT_MAX / INT_MAX etc. and while it probably would be good to update these with ranges that make more sense -- not using FLT_MAX / INT_MAX would not have done the clamping here -- there should not be an arbitrary limit to these and they should stay as they are. Maniphest Tasks: T88762 Differential Revision: https://developer.blender.org/D11473
2021-05-31Cleanup: else-after-returnJacques Lucke
2021-05-31Fix T88666: Cryptomatte: EXR sequence does not update when scrubbing the ↵Jeroen Bakker
timeline. Cause is that initializing the cryptomatte session would reset the current frame of an image sequence. The solution is to always use the scene current frame so it resets to the correct frame. This was a todo that wasn't solved after it landed in master. Needs to be backported to 2.93.
2021-05-27Cleanup: rename BKE_main_id_{clear_newpoins => newptr_and_tag_clear}Campbell Barton
It wasn't obvious this function cleared the tag as well.
2021-05-27Cleanup: simplify logic for copying vector button as textCampbell Barton
An arbitrary size offsets was used in float_array_to_string, simplify the loop, use exact size limits. Also rename variables so it's clear which array the length apply to.
2021-05-27Fix incorrect BLI_snprintf usageCampbell Barton
Event though in practice this wasn't causing problems as the fixed size buffers are generally large enough not to truncate text. Using the result from `snprint` or `BLI_snprintf` to step over a fixed size buffer allows for buffer overruns as the returned value is the size needed to copy the entire string, not the number of bytes copied. Building strings using this convention with multiple calls: ofs += BLI_snprintf(str + ofs, str_len_max - ofs); .. caused the size argument to become negative, wrapping it to a large value when cast to the unsigned argument.
2021-05-25Cleanup: clang-formatCampbell Barton
2021-05-21Cleanup: spellingLeon Zandman
Includes fixes to misspelled function names. Ref D11280
2021-05-21Cleanup: quiet -Warray-parameter warnings from GCC11Campbell Barton
Some warnings remain that require larger changes.
2021-05-19Merge branch 'blender-v2.93-release'Jeroen Bakker
2021-05-19Fix T88167: Regression: no tooltip for syringe/picker, during picking objectPratik Borhade
Fix T88167. Caused by {rB97defd9cd79b6e3ed0e52481a7078107dbe0522b} `(BLI_rcti_isect_pt` used here to confirm if cursor position is in between active region boundary. Subtracting min region boundary from the mouse position before the check, fails the condition. `mval[2]` introduced to hold the region relative mouse position. Reviewed By: Severin Maniphest Tasks: T88167 Differential Revision: https://developer.blender.org/D11224
2021-05-17UI: add non-linear slider supportHenrik Dick
This patch introduces non linear sliders. That means, that the movement of the mouse doesn't map linearly to the value of the slider. The following changes have been made. - Free logarithmic sliders with maximum range of (`0 <= x < inf`) - Logarithmic sliders with correct value indication bar. - Free cubic sliders with maximum range of (`-inf < x < inf`) - Cubic sliders with correct value indication bar. Cubic mapping has been added as well, because it's used for brush sizes in other applications (Krita for e.g.). To make a slider have a different scale type use following line in RNA: `RNA_def_property_ui_scale_type(prop, PROP_SCALE_LOGARITHMIC);` or: `RNA_def_property_ui_scale_type(prop, PROP_SCALE_CUBIC);` Test the precision, step size and soft-min if you change the scale type of a property as it will feel very different and may need tweaking. Ref D9074
2021-05-07Cleanup: make format (clang-format)Dalai Felinto
2021-05-06Fix T88058: Hover+return doesn't accept 0 as inputFalk David
When the user hovered over a number input field, pressed Enter and then typed in '0', confirming the input would always cancel the action. This is because in this particular case `ui_textedit_begin` is called instead of `ui_numedit_begin`. This function will not set `data->startvalue` (leaving it at `0`) which will then trigger the cancel in `ui_apply_but_NUM` which checks if the input changed (by comparing the entered value with `data->startvalue`). The fix makes sure that when `ui_textedit_begin` is called on a number button, the `data->startvalue` is set correctly like in `ui_numedit_begin`. Breaking commit: rBSeb06ccc32462beaacbb114d6d0e450b6fc911047 Note: This also affects pressing tab to move to a new number field and entering '0'. The fix will also cover this case. Reviewed By: Severin, #user_interface Maniphest Tasks: T88058 Differential Revision: https://developer.blender.org/D11168
2021-05-05Merge branch 'blender-v2.93-release'Richard Antalik
2021-05-04Fix missing background of buttons after reportsJulian Eisel
Reports would change the active emboss of the Block, to make some of its buttons appear without background. But it didn't reset it so that buttons added afterwards wouldn't use the correct embossing.
2021-05-04Fix T87489: Text Data-Blocks get deleted on Recursive PurgeSebastian Parborg
Text data block were not considered special in the recursive purge function. So they would get deleted if they had no actual users. To fix this we instead make text data block use "fake user" so that addon authors can specify script files that should be removed if nothing is using it anymore. Per default, new text object have "fake user" set. So functionality wise, the user has to explicitly specify that they want the text object to be purge-able. Reviewed By: Bastien Differential Revision: http://developer.blender.org/D10983
2021-05-04Fix T87489: Text Data-Blocks get deleted on Recursive PurgeSebastian Parborg
Text data block were not considered special in the recursive purge function. So they would get deleted if they had no actual users. To fix this we instead make text data block use "fake user" so that addon authors can specify script files that should be removed if nothing is using it anymore. Per default, new text object have "fake user" set. So functionality wise, the user has to explicitly specify that they want the text object to be purge-able. Reviewed By: Bastien Differential Revision: http://developer.blender.org/D10983
2021-05-03Cleanup: spellingCampbell Barton
2021-04-30Cleanup: interface_intern.h doc-stringsCampbell Barton
Also clarify some vague comments & add doxygen section for menu-memory.
2021-04-30Cleanup: use early return in edittranslation_execCampbell Barton
2021-04-29Cleanup: Use const argument for contextHans Goudey
2021-04-28Cleanup: Fix inconcistent array lengths in function declarationsHans Goudey
In some cases functions were defined with arguments of different array lengths in headers vs. implementations. This commit fixes some of the cases I ran into, but probably not all of them.
2021-04-28Merge branch 'blender-v2.93-release'Jacques Lucke
2021-04-28Fix T87526: poor contrast in attribute searchJacques Lucke
Differential Revision: https://developer.blender.org/D11106
2021-04-27Merge branch 'blender-v2.93-release'Hans Goudey
2021-04-27Fix T87749: Fix text jitter in buttons with iconsHans Goudey
This patch fixes the remaining issues described in T87749. The jitter was caused by inconsistent rounding when using the floats icon_size and icon_padding to offset the bound for the text drawing. Using `round_fl_to_int` leads to consistent results and fixes the jitter that remained in some buttons with icons, UI lists, and breadcrumbs. Differential Revision: https://developer.blender.org/D11062
2021-04-26Merge branch 'blender-v2.93-release'Philipp Oeser
2021-04-26Fix T87771: Immediate Crash on "Edit Source" in CompositorPhilipp Oeser
Caused by {rB278011e44d43}. Framebuffer management since above commit now seems to require region bind/unbind in for the operator to be able to redraw correctly without using the same framebuffer in multiple contexts. Maniphest Tasks: T87771 Differential Revision: https://developer.blender.org/D11084
2021-04-23Merge branch 'blender-v2.93-release'Hans Goudey
2021-04-23Fix T87749 (partially): Text jitter in buttons and spreadsheet editorLeon Leno
This patch fixes jittering text when resizing regions of the UI as described in T87749. The jitter was caused by the text padding being stored as an integer which lead to inconsistent rounding. Most notably this patch fixes the jitter in the new spreadsheet editor, but not all occurrences of jitter described in T87749 (e.g. in UI lists) are addressed. Differential Revision: https://developer.blender.org/D11060
2021-04-23Cleanup: clang-formatCampbell Barton