class Panel
- Extends:
- ContainerComponent, UIComponent, ShapeContainer
Description:
Panel UI component, rectangular UI component that can be used in many different ways:
- Container for other components
- As a horizontal/vertical line or a rectangle
- Container with scroll bars that can contain objects even outside its boundaries.
- Background can be set to color, image, and gradient (like in CSS), which opens lots of opportunities, such as animating background, streaming MJPEG video by setting frames as background of the panel sequentially, and more.
- As a canvas to draw Shapes or create an interactive game using Shapes drawn on this canvas.
Panel class extends ContainerComponent and ShapeContainer, which extend UIComponent
Constructor
constructor([text])
Panel constructor. Creates an instance of Panel UI component.
Parameters:
| Name | Type | Description |
|---|---|---|
|
|
string |
Text associated with this Panel. It will be used, for example, for a tab name when this panel is added to Tabs component. |
Members
- [ readonly ] childCount
- [ readonly ] children
- [ readonly ] id
- [ readonly ] isContainer
- [ readonly ] parent
- [ readonly ] screenPosition
- [ readonly ] shapeCount
- [ readonly ] window
Methods
Inherited from ContainerComponent:
Inherited from ShapeContainer:
Inherited from UIComponent:
- addTo()
- anchor()
- background()
- border()
- bottom()
- center()
- color()
- contextMenu()
- cursor()
- destroy()
- dragAction()
- dragData()
- dragDataType()
- dropAction()
- dropDataType()
- emit()
- emitFocusKeyEvents()
- enabled()
- focusable()
- focused()
- font()
- getAncestor()
- height()
- hide()
- icon()
- index()
- isInside()
- layer()
- maxSize()
- minSize()
- move()
- onAncestorEvents()
- onComponentEvents()
- onDispose()
- onDragEvents()
- onDropEvents()
- onError()
- onFocusEvents()
- onKey()
- onMouseEvents()
- onMouseMotion()
- onMouseWheel()
- onPropertyChange()
- onShortcut()
- opacity()
- position()
- remove()
- right()
- shortcuts()
- size()
- snapshot()
- text()
- tooltip()
- update()
- verifyComponent()
- visible()
- width()
- x()
- y()
