|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface CDockable
A basic element representing some Component
. This interface
is not intended to be implemented by clients. Clients should extend the
class AbstractCDockable
.
Field Summary | |
---|---|
static String |
ACTION_KEY_CLOSE
Key for an action of getAction(String) . |
static String |
ACTION_KEY_EXTERNALIZE
Key for an action of getAction(String) . |
static String |
ACTION_KEY_MAXIMIZE
Key for an action of getAction(String) . |
static String |
ACTION_KEY_MINIMIZE
Key for an action of getAction(String) . |
static String |
ACTION_KEY_NORMALIZE
Key for an action of getAction(String) . |
Method Summary | |
---|---|
void |
addCDockablePropertyListener(CDockablePropertyListener listener)
Adds a property listener to this dockable, the listener will be informed of changes of this dockable. |
void |
addCDockableStateListener(CDockableStateListener listener)
Adds a state listener to this dockable, the listener will be informed of changes of this dockable. |
void |
addDoubleClickListener(CDoubleClickListener listener)
Adds a new listener to this dockable. |
void |
addFocusListener(CFocusListener listener)
Adds a focus listener to this dockable. |
void |
addKeyboardListener(CKeyboardListener listener)
Adds a keyboard listener to this dockable. |
CAction |
getAction(String key)
Gets an action which is not added to the title by this CDockable
put by another module. |
RequestDimension |
getAndClearResizeRequest()
Gets the preferred size of this CDockable . |
CLocation |
getBaseLocation()
Gets the location of this dockable. |
ColorMap |
getColors()
Gets a mutable map of colors. |
CControlAccess |
getControl()
Gets the control which is responsible for this dockable. |
ExtendedMode |
getExtendedMode()
Gets the size and location of this dockable. |
FontMap |
getFonts()
Gets a mutable map of fonts. |
Dimension |
getMinimizedSize()
Gets the size which is used when this dockable is minimzed and on a popup window. |
CStation<?> |
getWorkingArea()
Gets the parent of this dockable, this should be the same as set by the last call of setWorkingArea(CStation) . |
CommonDockable |
intern()
Gets the intern representation of this dockable. |
boolean |
isCloseable()
Tells whether this dockable can be closed by the user. |
boolean |
isExternalizable()
Tells whether this dockable can be externalized by the user. |
boolean |
isMaximizable()
Tells whether this dockable can be maximized by the user. |
boolean |
isMinimizable()
Tells whether this dockable can be minimized by the user. |
boolean |
isMinimizedHold()
Tells whether this dockable remains visible when minimized and without focus. |
boolean |
isResizeLockedHorizontally()
Tells whether the width of this dockable should remain the same when its parent changes the size. |
boolean |
isResizeLockedVertically()
Tells whether the height of this dockable should remain the same when its parent changes the size. |
boolean |
isSingleTabShown()
Tells whether a single tab should be shown for this dockable. |
boolean |
isStackable()
Tells whether this dockable can be combined with another dockable to create a stack. |
boolean |
isTitleShown()
Tells whether this dockable shows its title or not. |
boolean |
isVisible()
Tells whether this dockable is currently visible or not. |
void |
removeCDockablePropertyListener(CDockablePropertyListener listener)
Removes a property listener from this dockable. |
void |
removeCDockableStateListener(CDockableStateListener listener)
Removes a state listener from this dockable. |
void |
removeDoubleClickListener(CDoubleClickListener listener)
Removes a listener from this dockable. |
void |
removeFocusListener(CFocusListener listener)
Removes a focus listener from this dockable. |
void |
removeKeyboardListener(CKeyboardListener listener)
Removes a listener from this dockable. |
void |
setControl(CControlAccess control)
Sets the CControl which is responsible for this dockable. |
void |
setExtendedMode(ExtendedMode extendedMode)
Sets how and where this dockable should be shown. |
void |
setLocation(CLocation location)
Sets the location of this dockable. |
void |
setMinimizedHold(boolean hold)
Sets whether this dockable should remain visible when minimized and without focus. |
void |
setMinimizedSize(Dimension size)
Sets the size of this dockable when this dockable is minimized and on a popup window. |
void |
setVisible(boolean visible)
Shows or hides this dockable. |
void |
setWorkingArea(CStation<?> area)
Sets the parent of this dockable. |
Field Detail |
---|
static final String ACTION_KEY_MINIMIZE
getAction(String)
. The action behind this
key should call setExtendedMode(ExtendedMode)
with an argument of ExtendedMode.MINIMIZED
.
static final String ACTION_KEY_MAXIMIZE
getAction(String)
. The action behind this
key should call setExtendedMode(ExtendedMode)
with an argument of ExtendedMode.MAXIMIZED
.
static final String ACTION_KEY_NORMALIZE
getAction(String)
. The action behind this
key should call setExtendedMode(ExtendedMode)
with an argument of ExtendedMode.NORMALIZED
.
static final String ACTION_KEY_EXTERNALIZE
getAction(String)
. The action behind this
key should call setExtendedMode(ExtendedMode)
with an argument of ExtendedMode.EXTERNALIZED
.
static final String ACTION_KEY_CLOSE
getAction(String)
. The action behind this
key should call setVisible(boolean)
with the argument
false
.
Method Detail |
---|
void addCDockableStateListener(CDockableStateListener listener)
listener
- the new listenervoid addCDockablePropertyListener(CDockablePropertyListener listener)
listener
- the new listenervoid removeCDockableStateListener(CDockableStateListener listener)
listener
- the listener to removevoid removeCDockablePropertyListener(CDockablePropertyListener listener)
listener
- the listener to removevoid addFocusListener(CFocusListener listener)
listener
- the new listenervoid removeFocusListener(CFocusListener listener)
listener
- the listener to removevoid addKeyboardListener(CKeyboardListener listener)
listener
- the new listenervoid removeKeyboardListener(CKeyboardListener listener)
listener
- the listener to removevoid addDoubleClickListener(CDoubleClickListener listener)
listener
- the new listenervoid removeDoubleClickListener(CDoubleClickListener listener)
listener
- the listener to removeboolean isMinimizable()
true
if this element can be minimizedboolean isMaximizable()
true
if this element can be maximizedboolean isExternalizable()
true
if this element can be externalizedboolean isStackable()
true
if this element can be combined with
another dockable, normally true
should be the answer.boolean isCloseable()
CloseActionSource
and include this source
in the array that is returned by CommonDockable.getSources()
.
true
if this element can be closedboolean isResizeLockedVertically()
true
if the height of this dockable should remain
the same during resize events of the parent.boolean isResizeLockedHorizontally()
true
if the width of this dockable should remain
the same during resize events of the parent.RequestDimension getAndClearResizeRequest()
CDockable
. The preferred size
will be used to resize this CDockable
when
CControl.handleResizeRequests()
is called. There are no guarantees
that the request can be granted, or will be handled at all.null
is
returned.
null
void setVisible(boolean visible)
CControlAccess.show(CDockable)
or
CControlAccess.hide(CDockable)
.
visible
- the new visibility state
IllegalStateException
- if this dockable can't be made visibleisVisible()
boolean isVisible()
JFrame
is not shown, or some DockStation
not
properly added to a parent component, then a visible dockable can
be invisible for the user.CControlAccess.isVisible(CDockable)
.
true
if this dockable can be accessed by the user
through a graphical user interface.void setLocation(CLocation location)
CControlAccess.getLocationManager()
and
CLocationModeManager.setLocation(bibliothek.gui.Dockable, CLocation)
.
location
- the new location, null
is possible, but
will not move the dockable immediatelyCLocation getBaseLocation()
setLocation(CLocation)
.
null
void setExtendedMode(ExtendedMode extendedMode)
isExternalizable()
, isMaximizable()
and isMinimizable()
will just be ignored.
extendedMode
- the size and locationExtendedMode getExtendedMode()
null
if this dockable
is not part of an CControl
.void setWorkingArea(CStation<?> area)
setLocation(CLocation)
.
area
- the new parent or null
CStation<?> getWorkingArea()
setWorkingArea(CStation)
.
null
void setMinimizedSize(Dimension size)
size
- the sizeDimension getMinimizedSize()
void setMinimizedHold(boolean hold)
hold
- whether to remain visibleboolean isMinimizedHold()
true
if this remains visible, false
otherwiseboolean isTitleShown()
DockTheme
s might override this setting.
true
if the title is shown, false
otherwise.boolean isSingleTabShown()
DockTheme
s might ignore this setting.
true
if a single tab should be shown,
false
if notCommonDockable intern()
void setControl(CControlAccess control)
CControl
which is responsible for this dockable. Subclasses
must call CControlAccess.link(CDockable, CDockableAccess)
to grant
the CControl
access to the internal systems of this
CDockable
. link
can also be used to revoke access.
control
- the new control or null
CAction getAction(String key)
CDockable
put by another module.
key
- the name of the action
null
ColorMap getColors()
FontMap getFonts()
CControlAccess getControl()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |