VisualComponentAddToComponent Method (Visual, Visual, String, Boolean) |
Mark this visual as a member of the component. Component must be the root of an existing component, or null.
If deep is set, then this visual and all its descendants will be added to the component. If deep is not set
but this visual is already a member of a component, then it and all its child visuals within the current component,
will be moved to the new component.
Namespace:
Demo3D.Visuals
Assembly:
Demo3D.Core (in Demo3D.Core.dll) Version: 10.0.0.6737
Syntaxpublic static void AddToComponent(
this Visual visual,
Visual component,
string componentType,
bool deep = true
)
Parameters
- visual
- Type: Demo3D.VisualsVisual
The visual to add. - component
- Type: Demo3D.VisualsVisual
The root of the component. - componentType
- Type: SystemString
The component type. - deep (Optional)
- Type: SystemBoolean
True if all descendants should be added too.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
Visual. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also