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
2022-07-29Cleanup: Move RNA path functions into own C++ fileJulian Eisel
Adds `rna_path.cc` and `RNA_path.h`. `rna_access.c` is a quite big file, which makes it rather hard and inconvenient to navigate. RNA path functions form a nicely coherent unit that can stand well on it's own, so it makes sense to split them off to mitigate the problem. Moreover, I was looking into refactoring the quite convoluted/overloaded `rna_path_parse()`, and found that some C++ features may help greatly with that. So having that code compile in C++ would be helpful to attempt that. Differential Revision: https://developer.blender.org/D15540 Reviewed by: Brecht Van Lommel, Campbell Barton, Bastien Montagne
2022-07-29Cleanup: Use const context argument for UIList callbacksHans Goudey
2022-07-21Cleanup: formatCampbell Barton
2022-07-21Cleanup: add ISMOUSE_MOTION macroCampbell Barton
Replace verbose ELEM(..) usage, now each kind of mouse event has it's own macro.
2022-07-21WM: replace ISMOUSE with ISMOUSE_BUTTONCampbell Barton
The ISMOUSE macro was used in situations only button events needed to be checked. The only functional difference would be MOUSEMOVE events were previously accepted for these checks.
2022-07-21Cleanup: spelling in comments, typos in tool-tipsCampbell Barton
2022-07-20UI: Remove redundant view reference in view itemsJulian Eisel
The new view item base class already holds a reference to the view, no need to have one in the derived class as well.
2022-07-20Fix missing registration of grid view items in the viewJulian Eisel
2022-07-19UI Code Quality: Move eyedropper files to own folderJulian Eisel
Part of T98518
2022-07-19Cleanup: Improve API and documentation of interface_view.ccJulian Eisel
File documentation was outdated and could use general improvement. Function names didn't really reflect the level they are operating on.
2022-07-19UI Code Quality: Move view related files to own folderJulian Eisel
Part of T98518.
2022-07-19UI: Port view item features to base class, merge view item button typesJulian Eisel
No user visible changes expected. Merges the tree row and grid tile button types, which were mostly doing the same things. The idea is that there is a button type for highlighting, as well as supporting general view item features (e.g. renaming, drag/drop, etc.). So instead there is a view item button type now. Also ports view item features like renaming, custom context menus, drag controllers and drop controllers to `ui::AbstractViewItem` (the new base class for all view items). This should be quite an improvement because: - Merges code that was duplicated over view items. - Mentioned features (renaming, drag & drop, ...) are much easier to implement in new view types now. Most of it comes "for free". - Further features will immediately become availalbe to all views (e.g. selection). - Simplifies APIs, there don't have to be functions for individual view item types anymore. - View item classes are split and thus less overwhelming visually. - View item buttons now share all code (drawing, handling, etc.) - We're soon running out of available button types, this commit merges two into one. I was hoping I could do this in multiple smaller commits, but things were quite intertwined so that would've taken quite some effort.
2022-07-19UI: Add AbstractViewItem base classJulian Eisel
No user visible changes expected. Similar to rBc355be6faeac, but for view items now instead of the view. Not much of the item code is ported to use it yet, it's actually a bit tricky for the most part. But just introducing the base class already allows me to start unifying the view item buttons (`uiButTreeRow` and `uiButGridTile`). This would be a nice improvement.
2022-07-14Fix `on_drag_start` handler not getting ID when dragging from OutlinerJulian Eisel
We would first invoke the dragging, and then set the drag data (like the ID or the dragged modifier), so the `wmDropBox.on_drag_start()` handler wouldn't be able to access this. This broke dragging some IDs from the Outliner, noticed in D15333. It's now possible to first create/request drag data, extend it, and then invoke the actual dragging. The normal function to start dragging returns `void` now instead of `wmDrag *`, so the drag data can't easily be modified after starting anymore.
2022-07-14Correct error with IME from d6fef73ef110eb43756b7b87c2cba80abae3b39fCampbell Barton
2022-07-14UI: translate tooltips coming from menu descriptionsDamien Picard
Many menus get their labels exported to the .po file, but then are not actually translated in the UI. Before: {F13283752} After: {F13283750} Reviewed By: mont29 Differential Revision: https://developer.blender.org/D15417
2022-07-14Cleanup: update & correct comments for event handlingCampbell Barton
- Remove references to `ISTEXTINPUT` as any keyboard event with it's utf8_buf set can be handled as text input. - Update references to the key repeat flag.
2022-07-14WM: Remove ASCII members from wmEvent & GHOST_TEventKeyDataCampbell Barton
The `ascii` member was only kept for historic reason as some platforms didn't support utf8 when it was first introduced. Remove the `ascii` struct members since many checks used this as a fall-back for utf8_buf not being set which isn't needed. There are a few cases where it's convenient to access the ASCII value of an event (or nil) so a function has been added to do that. *Details* - WM_event_utf8_to_ascii() has been added for the few cases an events ASCII value needs to be accessed, this just avoids having to do multi-byte character checks in-line. - RNA Event.ascii remains, using utf8_buf[0] for single byte characters. - GHOST_TEventKeyData.ascii has been removed. - To avoid regressions non-ASCII Latin1 characters from GHOST are converted into multi-byte UTF8, when building X11 without XInput & X_HAVE_UTF8_STRING it seems like could still occur.
2022-07-12UV: Box and lasso selection for partially intersecting edgesSiddhartha Jejurkar
In UV edge mode, box and lasso selections allow edge selections only when the entire edge is contained within the selection area. This doesn't consider any edges that partially overlap with the selection area. This is now fixed by adding a second pass, similar to how these operators work for edit-mesh selections. Now if both operators are unable to find any edges contained within the selection area, then they will perform a second pass which checks for edges that partially intersect with the selection area. Now edge selection in the UV editor matches edit-mesh edge-selection when drawing wire-frame. Resolves T99443. Ref D15362
2022-07-11Cleanup: Remove unused operator name storage in UI listsJulian Eisel
2022-07-07LibOverride: Make fully editable when creating an experimental user setting.Bastien Montagne
This is temporary to investigate which behavior should be kept when creating an override hierarchy if there are no cherry-picked data defined: make all overrides user-editable, or not. This removes the 'make override - fully editable' menu entries.
2022-07-07UI: Superimposed pin icon for workspace scene pinning in the scene switcherJulian Eisel
Followup to the previous commit, to display a pin icon in the scene switcher. This is a good indicator to have and such workspace-wide functionality should be available in the topbar, close to what it belongs to (scene switching). Downside is that it makes this already crowded region even more crowded. But thanks to the use of superimposed icons, it's not too noisy visually. Differential Revision: https://developer.blender.org/D11890 Reviewed by: Campbell Barton
2022-07-07Cleanup: Improve variable nameHans Goudey
The new name makes more sense in non-node-related contexts.
2022-07-04Cleanup: Correct UI view commentsJulian Eisel
2022-07-04Cleanup: correct function signature for UI_block_add_view for grid_viewCampbell Barton
2022-07-03UI: Move rename buffer management to new view base classJulian Eisel
Renaming is a nice example of a feature that shouldn't need a specific implementation for a specific view type (e.g. grid or tree view). So it's something that can be supported in the general view code. Individual views can use it "for free" then. This ports the view level part of the renaming code, the view item level part of it can be ported once we have a common base class for the view items.
2022-07-03UI: Add AbstractView base class for views, unify reconstruction in thereJulian Eisel
No user visible changes expected. There's plenty of duplicated code in the grid and the tree view, and I expect this to become more. This starts the process of unifying these parts, which should also make it easier to add new views. Complexity in the view classes is reduced, and some type shenanigans for C compatibility and general view management can be removed, since there is now a common base type. For the start this ports some of the view reconstruction, where the view and its items are compared to the version of itself in the previous redraw, so that state (highlighted, active, renaming, collapsed, ...) can be preserved. Notifier listening is also ported.
2022-06-30Cleanup: spelling in commentsCampbell Barton
2022-06-27UI: Scrollbar Behavior ChangesHarley Acheson
Changes to scrollbars so that they are always visible, but thin and dim, and widen and become more visible as your mouse approaches. See D6505 for details and examples. Differential Revision: https://developer.blender.org/D6505 Reviewed by Campbell Barton
2022-06-26Cleanup: Clang tidyHans Goudey
2022-06-22Fix T97675: slow zoom in node editor with Continue zoom methodPatrick Huang
Speed increased by 10x, making it visually similar to other editors. Differential Revision: https://developer.blender.org/D15209
2022-06-17Fix T93446: search box active result does not reset when typingPatrick Huang
Whenever the user edits the query in a search box, the active (highlighted) result resets to the first. Previously, it would remain at the last highlighted result, jumping around as the results update. This is better than the previous behavior. If a user highlights a choice either on purpose or by accidental mouse movement and continues to type, it is likely that they are not looking for the currently highlighted choice, so setting it to the top search result is more useful. Differential Revision: https://developer.blender.org/D15211
2022-06-17BLF: Fallback Font StackHarley Acheson
Allow use of multiple fonts acting together like a fallback stack, where if a glyph is not found in one it can be retrieved from another. See D12622 for much more detail Differential Revision: https://developer.blender.org/D12622 Reviewed by Brecht Van Lommel
2022-06-17Cleanup: compiler warningsBrecht Van Lommel
2022-06-17Cleanup: remove redundant string formattingCampbell Barton
2022-06-16UI: Add initial "grid view"Julian Eisel
Part of T98560. See https://wiki.blender.org/wiki/Source/Interface/Views Adds all the basic functionality needed for grid views. They display items in a grid of rows and columns, typically with a preview image and a label underneath. Think of the main region in the Asset Browser. Current features: - Active item - Notifier listening (also added this to the tree view) - Performance: Skip adding buttons that are not scrolled into view (solves performance problems for big asset libraries, for example). - Custom item size - Preview items (items that draw a preview with a label underneath) - Margins between items scale so the entire region width is filled with column, rather than leaving a big empty block at the right if there's not enough space for another column (like the File and current Asset Browser does it). - "Data-View Item" theme colors. Not shown in the UI yet. No user visible changes expected since the grid views aren't used for anything yet. This was developed as part of a rewrite of the Asset Browser UI (`asset-browser-grid-view` branch), see T95653. There's no reason to keep this part in a branch, continuing development in master makes things easier. Grid and tree views have a lot of very similar code, so I'm planning to unify them to a degree. I kept things separate for the start to first find out how much and what exactly makes sense to override.
2022-06-15UI: Implement icons for the curve sculpt tools brushesDalai Felinto
I'm using the tool icons for the brush themselves. Note: This includes a few brushes that are only defined in D15134. Those are simply the icons rendered with a world background of #282828.
2022-06-15UI: Fix sculpt curve not being able to get brush iconsDalai Felinto
This commit doesn't add the brush icons themselves, but it fix the code that allow them to be used.
2022-06-14Fix T98715: Crash drag-dropping collection from outliner to ID propertyJulian Eisel
The value of disabled buttons shouldn't be changed through dropping onto it. Check for the disabled state in the drop operator poll, so the dragging code will change the cursor to show that dropping isn't possible at the given cursor location.
2022-06-13Cleanup: Move dragging code for buttons to own fileJulian Eisel
Moves code for managing dragging data from buttons to a separate file. This way all this closely related code is in one location, making it easier to see how it all relates, and easier to find.
2022-06-10Cleanup: Clang tidyHans Goudey
2022-06-09Cleanup: use const variables & argumentsCampbell Barton
2022-06-09UI: Tooltip Edit - Copy to selected buttonAaron Carlisle
This commit changes the tool tip for the "Copy To Selected Button" operator. The exiting tool tip for this operator suggests that it will "copy property to selected objects or bones". However, it will only copies the property value to the selected objects or bones if the property already exists on the selected items. It does not copy the property. Differential Revision: https://developer.blender.org/D14528
2022-06-07IME Cleanup: Removal of BLT_lang_is_ime_supportedHarley Acheson
Removal of BLT_lang_is_ime_supported which is always returns true and is no longer needed. See D11800 for more details. Differential Revision: https://developer.blender.org/D11800 Reviewed by Campbell Barton
2022-06-07Cleanup: spelling in comments, minor formatting tweaksCampbell Barton
2022-06-07Cleanup: note that checking only the left modifiers isn't a mistakeCampbell Barton
2022-06-07VSE preview transform autokeying improvementsPhilipp Oeser
NOTE: this patch originated in T98015 which was split into multiple reports. While it could be split into multiple patches these are very much related so keeping as one for now This patch fixes the following issues: [1] autokeying transforms in preview only creates keyframes if there is an FCurve already [2] autokeying transforms in preview only creates keyframes for rotation/scale if rotating/scaling around cursor (should keyframe position as well) [3] autokeying transforms in preview does not work during animation playback For [1], a param was added to `ED_autokeyframe_property` which can tweak its default behavior of only creating keyframes on already keyed properties (which was fine because this is mostly called from buttons where this behavior is desired). Callers such as gizmos (or the VSE in our case) can use this additional param so that keyframes are also created on "not-yet-keyframed" properties. For [2], the pivot is checked and position properties also keyed if necessary (which is also consistent with the way objects are keyed in the 3DView) For [3], `animrecord_check_state` was changed to be able to work on scenes as well and the transform system in the VSE preview was made aware of the screen's `animtimer`. NOTE: there are still things to be improved for keyframing in the VSE, the most obvious is probably a `keyframe_insert` operator (with keyingsets) Fixes T98429, T98430, T98431 Maniphest Tasks: T98015, T98431, T98430, T98429 Differential Revision: https://developer.blender.org/D15047
2022-06-03Cleanup: spelling in commentsCampbell Barton
2022-06-01Cleanup: use 'e' prefix for enum typesCampbell Barton
- CustomDataType -> eCustomDataType - CustomDataMask -> eCustomDataMask - AttributeDomain -> eAttrDomain - NamedAttributeUsage -> eNamedAttrUsage
2022-05-31Attributes: Hide internal UI attributes and disallow procedural accessHans Goudey
This commit hides "UI attributes" described in T97452 from the UI lists in mesh, curve, and point cloud properties, and disallow accessing them in geometry nodes. Internal UI attributes like selection and hiding values should use the attribute system for simplicity and performance, but we don't want to expose those attributes in the attribute panel, which is meant for regular user interaction. Procedural access may be misleading or cause problems, as described in the design task above. These attributes are added by two upcoming patches: D14934, D14685 Differential Revision: https://developer.blender.org/D15069