Skip to content

Commit 49f4459

Browse files
committed
A few more notes on Stacks & Content-Aware Groups
1 parent d26638a commit 49f4459

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

reference/core/automatic-cleanups.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,7 @@ To make writing your plugin simpler, XD performs a number of automated cleanups
1414

1515
* **Repeat Grid cell syncing** - Most changes you make inside a Repeat Grid cell are automatically mirrored to all its other cells, except for certain properties
1616
such as text and images which XD permits to vary between grid cells.
17+
18+
* **Content-Aware Group & Stack layout updates** -- The background layer (if any) of a Content-Aware Group will update automatically after a plugin changes the
19+
size or position of its contents. Similarly, changing a node inside a Group with Stack layout will automatically slide its adjacent siblings to preserve a
20+
constant margin around the node. These changes do not occur until after the plugin command finishes.

reference/scenegraph.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -866,6 +866,10 @@ Groups and other containers cannot be created directly using scenenode construct
866866
scenegraph (you can't add subtrees all at once) nor can you add an empty Group and then add children to it (can't add nodes outside
867867
the scope of the current _edit context_). Instead, to create Groups and other nested structures, use [commands](commands.md).
868868

869+
Plain Groups (as well as some other node types, like SymbolInstances) can have dynamic layout features enabled such as padding and
870+
stack layouts. These are sometimes referred to as Content-Aware Groups or Stack containers, but ultimately these appear in the API as
871+
plain Group nodes. They do not carry the same edit-context restrictions as Masked Groups or other special node types.
872+
869873
In a Mask Group, the mask shape is included in the group's `children` list, at the top of the z order. It is not visible - only its
870874
path outline is used, for clipping the group.
871875

0 commit comments

Comments
 (0)