synfig/synfig — pull request #65 by genete (2013-09-28 11:50:59+00:00)
Title: Group switch

Switch Groups: allow to make visible only certain layers inside a Group layer.

The Group layer has four new parameters:
Z_Depth_range_enabled (bool)
Z_Depth_range_position (float)
Z_Depth_range_depth (float)
Z_Depth_range_transition (float)

The 'enabled' parameter just enables or disable the feature. It is non animatable by default.
The 'position' and the 'position'+'depth' parameters mark the start and end (inclusive) range of z depth value of the layers where they are full visible.
The 'transition' parameter is a value that expands the previous range. Layers with a z depth in the transition area are partially visible.

User can change manually those values on the Group layer and the layers are rendered accordingly.

Also, user can right click a layer selection (all them from the same Group layer but maybe they are not continuos) and the layer become full visible. That action doesn't modify the transition parameter.

Children layers that are visible (when enabled parameter is 'on') are displayed in the layer stack with bold letter.

Known issues:
Software render method complains continuously about paste canvas bounding box:
warning: layer_pastecanvas.cpp:509 bounding box shrank while rendering?

I've not found a way to update the bold letters immediately that the user changed one parameter manually. It works for the contextual action over the layers.

Action is not available to layers in exported canvases. Due to it is not possible to know what's the Group layer that is holding the canvas.

The instant update of the bold letter seems to not work on Windows.