Page MenuHome

FIX: "Selected" view mode in outliner
AbandonedPublic

Authored by Campbell Barton (campbellbarton) on Feb 4 2016, 8:46 PM.

Details

Summary

The "Selected" view mode in the ouliner currently behaves different from the other view modes.

  1. It does always show the active object, even if it is not selected - which is contrary to the real selection state as seen by bpy.context.selected_objects.
  2. It does not show invisible objects - which tells nothing about the real selection state as seen by bpy.context.visible_objects.

Steps to reproduce:

  • open attached
  • note that the red cube is selected and the blue cube is active, but not selected.

All open outliner views on the right show the correct state, except the "Selected" view. The blue cube is not selected and should not be shown here.

  • change the 3dview to some other layer than layer 1.

Again, all open outliner views on the right show the correct state, except the Selected view. The red cube is still selected, which can also be seen in the "Current Scene" and "All Scenes" ouliner views. It should also be shown in the "Selected" view.


This patch changes the "Selected" view mode in the outliner as follows:

  1. Always show all selected objects even if they are not visible.
  2. Don't show the active object if it is not selected.

T47327

Diff Detail

Event Timeline

Ralf Hölzemer (cheleb) retitled this revision from to FIX: "Selected" view mode in outliner.
Ralf Hölzemer (cheleb) updated this object.

Edited the wrong task, sorry! :)

I'm actually not sure if we really need two separate modes, 'Active' and 'Selected'. Maybe we should merge them into one ('Active/Selected')? @venomgfx, @Jonathan Williamson (carter2422), @Paweł Łyczkowski (plyczkowski), any opinion?

The reason for that change for me was the need to really only see selected objects. I use it currently on a big project at work. It is a representation whats going on inside blender and very useful for many operators that depend on selection state and also for python debugging purposes. An alternative solution maybe would be to make it more clear of whats selected in the outliner in general by changing how selection state is represented. The current method/theme does have some drawbacks im some cases - like the camera icon.


That being said, I would still say the active/selected views should stay because you can see at a glance of whats going on without scolling through a big scenetree in all other modes.

@Julian Eisel (Severin) I guess I can see a scenario where one would want a window that only displays the active object, along with Selectable/Renderable etc buttons, for quick access.

Active object was added there for a reason, anyone checked history what was the reasoning?

As showing all invisible objects -- i don't think it's a really good thing. In the viewport you usually use layers to limit amount of objects you're working on. Current logic helps keeping outliner in a usable state for complex scenes. If you change this, then all of a sudden you'll have objects appearing in the outliner which you never want to do anything with them.

Agree having active-unselected included with selected is strange. (Think this change can go directly into master).

But would keep selected behavior as-is (meaning "Visible Selected")
Tooltip can note that "Selected means visible-selected"


@Julian Eisel (Severin), Agree having 'Active' is a bit odd, The only reason I can think of it being useful is if you're dealing with complex hierarchies and you want to isolate the view to an active objects and its children.
However removing active object isnt directly related to this patch.

Campbell Barton (campbellbarton) abandoned this revision.

Committed rBf5982f2a2983783a4c26599e623143f8a30e738d

Keep layer check (and update tooltip) but remove active test.