VirtualSwingNode
Emits content into the container this node is composed in, as if content were written there, and declares modifier to that container for each component content places in it.
A virtual node has no component. Its children are added to the nearest ancestor that has one, in composition order among that ancestor's other children. That ancestor's layout manager receives this node's declarations ahead of each child's own. Nested groups declare in order from outermost to innermost. The group declarations and each child's own declarations form one list. For non-additive declarations, a later declaration replaces an earlier declaration of the same key. Additive declarations accumulate. Parent data in the list must use the same protocol. The container checks exactly the declarations it receives, so a declaration a later one replaces is not checked. Declarations reach no further: the children of a child are added to the child's container and never receive them.
A changed modifier reaches each component this node places in composition order, once the pass's other changes have been applied; a child added in that pass is added to the container then, with its final declaration. A declaration the container refuses fails the pass, and the components declared before it keep the new one.
A group is refused under a container that places children in named regions, including a composition root with a single-content slot. An ordinary setContent root accepts groups among its indexed children. An ExistingSwingNode directly inside a group is refused. A group cannot be used in menu content. A group that declares parent data is refused under a container with no layout manager. Each child can still declare its own parent data there.
Under a LayoutManager2 that is not a MeasurementLayoutManager, the group's folded parent data is the add constraint of each child, so VirtualSwingNode(SwingModifier.layoutConstraint(c)) { ... } gives every child the constraint c.
Parameters
parent-layout declarations only: ParentLayoutElements that are not ParentLayoutNodeElements. Any other element is refused.
the composables whose components the container receives.