24 Commits

Author SHA1 Message Date
Harley Acheson
6691529dcc Fix #147926: Incorrect Icon used for Generic Collection
We have icons that represent specific individual collections. like
Icon_Outliner_Collection for a default (uncolored) collection, and
Icon_Collection_color_x for ones with colors. For "collections" as a
general thing though we have icon_group. Sometimes we confuse the two,
for example the list of tabs to show in Properties uses a different
icon than the actual category icon. This PR fixes the complaint by
using the correct icon for each of these purposes.

Pull Request: https://projects.blender.org/blender/blender/pulls/147942
2025-10-13 01:26:16 +02:00
Casey Bianco-Davis
d2269441bb Python: Rename bpy.data.grease_pencils_v3 to bpy.data.grease_pencils
This renames `bpy.data.grease_pencils_v3` to `bpy.data.grease_pencils`.

Part of #125058.

Pull Request: https://projects.blender.org/blender/blender/pulls/146904
2025-09-29 12:32:08 +02:00
Campbell Barton
9567ac1272 Cleanup: quiet python linter warnings 2025-04-16 11:08:40 +10:00
Bastien Montagne
df215441eb Fix (unreported): Protect Outliner UI py code util against None context.id value.
Detected by review of !135936, the code checked for a non-empty
`context.selected_ids`, but did not propect against a potential
`None` `context.id`.
2025-04-14 14:17:42 +02:00
Bastien Montagne
0eba8caaf9 Core: Add 'relocate' operation on individual linked ID.
So far it was only possible to relocate a whole library, now one can
also relocate a single linked ID (pulling in all of its dependencies).

This is essentially linking the new data, remapping local usages of the
old linked data to the new one, removing no more used IDs, and updating
liboverrides if needed.
2025-04-14 12:54:48 +02:00
Campbell Barton
be0c9174aa Cleanup: argument wrapping for Python scripts
- Wrap the closing parenthesis onto it's own line
  which makes assignments to the return value
  read better.
- Reduce right-shift with multi-line function calls.
2025-01-14 12:53:32 +11:00
Falk David
a5c4218b02 Fix: Outliner: Grease Pencil object filter
The filter for grease pencil objects wasn't showing up.
The code was still checking for the legacy type.
Now, we're checking for the right object type and
are also looking at the `bpy.data.grease_pencils_v3`
list to make the checkbox show up in the UI.
2024-07-19 18:01:47 +02:00
Campbell Barton
56388dc8fe Cleanup: reduce right-shift in startup scripts
Also un-wrap lines that fit in the column width.
2024-04-30 12:46:05 +10:00
Bastien Montagne
b56457aa5e Core: ID Management: Make 'Purge' operation always recursive by default.
Inherited from previous versions of this feature, by default the Purge
operation from the Outliner would remove all unused IDs, recursively.
The same operation invoked from the File -> Clean Up main menu would by
default only delete directly unused IDs.

Now both will by default remove all (directly or indirectly) unused data.
2024-04-12 11:25:00 +02:00
Campbell Barton
d07d6f1c10 Cleanup: un-wrap lines that fit within 120 width for Python scripts 2024-03-15 10:04:03 +11:00
Pablo Vazquez
c02fd6c6d8 Revert "Outliner: Add shortcut to Add Object and Duplicate"
This reverts commit 537d175289.

It doesn't work well with Sync Selection and other Outliner view modes.
2024-02-08 17:15:33 +01:00
Pablo Vazquez
537d175289 Outliner: Add shortcut to Add Object and Duplicate
Add shortcuts to the Outliner for consistency and convenience:
* Add Object (Shift+A)
* Duplicate (Shift+D)
* Duplicate Linked (Alt+D)

More info and images in the PR.

Pull Request: https://projects.blender.org/blender/blender/pulls/117922
2024-02-07 12:00:09 +01:00
Philipp Oeser
f815484e7d Outliner: add "Expand/Collapse All" to view context menu
This was only in the blender keymap, but seems useful to have this in a
menu as well.

Pull Request: https://projects.blender.org/blender/blender/pulls/114138
2023-11-17 00:49:04 +01:00
Philipp Oeser
4793b4592b Outliner: clarify "Show Hierarchy" context menu entry
Display OUTLINER_OT_show_hierarchy as "Show Object Hierarchy"

Pull Request: https://projects.blender.org/blender/blender/pulls/114139
2023-11-17 00:31:32 +01:00
Campbell Barton
790fea431f Cleanup: use since quotes for enum values, wrap multi-line brackets 2023-09-29 14:41:48 +10:00
Pablo Vazquez
05fc31f27f UI: Remove redundant "Context Menu" in menu titles
Context menus are a type of menu, like header menus, there is no need to mention
the type as part of the name since it is implied by context.

Pull Request: https://projects.blender.org/blender/blender/pulls/112662
2023-09-25 16:25:55 +02:00
Pablo Vazquez
da495765b4 UI: Add icon to Library Override menu entries
To create a connection with the icon that shows up in
ID templates and decorators once library is overriden.

Affects Outliner context and Object menu in 3D Viewport.
Similar to the Asset menu.
2023-09-20 15:06:54 +02:00
Campbell Barton
c51336f5e8 Cleanup: single quote enums in Python 2023-09-13 13:38:39 +10:00
Pablo Vazquez
754f2f9c80 UI: Use asset icon for "Mark Asset" in menus
Use the asset icon for the "Mark Asset" operator in menus.

Using icons is not only good for accessibility, but also to create
a connection with the Asset Browser and the icon shown in the
data-block template once marked as asset.

Pull Request: https://projects.blender.org/blender/blender/pulls/112111
2023-09-08 15:39:59 +02:00
Campbell Barton
e955c94ed3 License Headers: Set copyright to "Blender Authors", add AUTHORS
Listing the "Blender Foundation" as copyright holder implied the Blender
Foundation holds copyright to files which may include work from many
developers.

While keeping copyright on headers makes sense for isolated libraries,
Blender's own code may be refactored or moved between files in a way
that makes the per file copyright holders less meaningful.

Copyright references to the "Blender Foundation" have been replaced with
"Blender Authors", with the exception of `./extern/` since these this
contains libraries which are more isolated, any changed to license
headers there can be handled on a case-by-case basis.

Some directories in `./intern/` have also been excluded:

- `./intern/cycles/` it's own `AUTHORS` file is planned.
- `./intern/opensubdiv/`.

An "AUTHORS" file has been added, using the chromium projects authors
file as a template.

Design task: #110784

Ref !110783.
2023-08-16 00:20:26 +10:00
Campbell Barton
65f99397ec License headers: use SPDX-FileCopyrightText in all sources 2023-06-15 13:35:34 +10:00
Campbell Barton
6482f9fffe Cleanup: quiet various pylint warnings 2023-04-13 13:14:05 +10:00
Antonio Vazquez
b558fff5b8 Outliner: New Grease Pencil filter
Actually is impossible to filter the Grease Pencil object type in the Outliner because only Meshes, Cameras and Lights are supported. This patch adds the Grease Pencil filter that allows artists to select only this type of objects. This filter is very handy for storyboarding.

Pull Request #104473
2023-02-27 13:07:14 +01:00
Sergey Sharybin
03806d0b67 Re-design of submodules used in blender.git
This commit implements described in the #104573.

The goal is to fix the confusion of the submodule hashes change, which are not
ideal for any of the supported git-module configuration (they are either always
visible causing confusion, or silently staged and committed, also causing
confusion).

This commit replaces submodules with a checkout of addons and addons_contrib,
covered by the .gitignore, and locale and developer tools are moved to the
main repository.

This also changes the paths:
- /release/scripts are moved to the /scripts
- /source/tools are moved to the /tools
- /release/datafiles/locale is moved to /locale

This is done to avoid conflicts when using bisect, and also allow buildbot to
automatically "recover" wgen building older or newer branches/patches.

Running `make update` will initialize the local checkout to the changed
repository configuration.

Another aspect of the change is that the make update will support Github style
of remote organization (origin remote pointing to thy fork, upstream remote
pointing to the upstream blender/blender.git).

Pull Request #104755
2023-02-21 16:39:58 +01:00