public interface IComponent extends IWidget, IComponentCommon, IShowingStateObservable
| Modifier and Type | Method and Description |
|---|---|
IPopupMenu |
createPopupMenu()
Creates a popup menu as a child of this component
|
Position |
fromComponent(IComponentCommon component,
Position componentPosition)
Transforms a position from another components coordinate system to
this components coordinate system
|
Rectangle |
getBounds()
Gets the bounds of the component
|
boolean |
hasFocus()
Gets the input focus state of the component.
|
boolean |
isReparentable()
Gets the information if the component is reparentable
|
boolean |
isShowing()
A root component is showing if it is visible.
|
void |
setBounds(Rectangle bounds)
The the bounds of the component
|
void |
setPopupMenu(IMenuModel popupMenu)
Sets a popup menu for this component defined by a model.
|
void |
setPosition(int x,
int y)
Sets the position of the component defined by the x-coordinate and the y-coordinate
|
void |
setSize(int width,
int height)
Sets the size of the component defined by width and height
|
Position |
toComponent(Position componentPosition,
IComponentCommon component)
Transforms a position from this components coordinate system to another components
coordinate system
|
Position |
toLocal(Position screenPosition)
Transforms a position in the screen coordinate system to this components coordinate system
|
Position |
toScreen(Position localPosition)
Transforms a position in the coordinate system of this component to the screen coordinate system
|
dispose, getParent, getRoot, isDisposedaddDisposeListener, removeDisposeListenergetBackgroundColor, getForegroundColor, getPosition, getSize, isVisible, redraw, requestFocus, setBackgroundColor, setCursor, setForegroundColor, setPosition, setRedrawEnabled, setSize, setVisiblegetUiReference, isEnabled, setEnabledaddComponentListener, removeComponentListeneraddFocusListener, removeFocusListeneraddKeyListener, removeKeyListeneraddMouseListener, removeMouseListeneraddMouseMotionListener, removeMouseMotionListeneraddPopupDetectionListener, removePopupDetectionListeneraddShowingStateListener, removeShowingStateListenerboolean isReparentable()
boolean isShowing()
boolean hasFocus()
IPopupMenu createPopupMenu()
void setPopupMenu(IMenuModel popupMenu)
menuModel - The model of the popup menu or null, if no popup should be shown on popup eventsPosition toScreen(Position localPosition)
localPosition - The local position, must not be nullPosition toLocal(Position screenPosition)
screenPosition - The screen position to transform, must not ne nullvoid setSize(int width,
int height)
width - The widthheight - The heightvoid setPosition(int x,
int y)
x - The x coordinatey - The y coordinateRectangle getBounds()
void setBounds(Rectangle bounds)
bounds - The bounds to set, never nullPosition fromComponent(IComponentCommon component, Position componentPosition)
component - Component, which the position is relative to, must not be nullcomponentPosition - Position The position to transform, must not be nullPosition toComponent(Position componentPosition, IComponentCommon component)
componentPosition - The position in this coordinate systemcomponent - Component, in what coordinate system the position is transformed toSiehe auch Jowidgets Nutzerhandbuch