|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object bibliothek.extension.gui.dock.theme.eclipse.stack.tab.DockTitleTab
TabPainter
is the preferred way to modify the tabs
@Deprecated public class DockTitleTab
A DockTitleTab
is a wrapper around an ordinary DockTitle
to get a TabComponent
.
This DockTitleTab
will use EclipseDockTitleEvent
s
to inform its DockTitle
when a property has changed, the
method DockTitle.changed(bibliothek.gui.dock.title.DockTitleEvent)
is called for that purpose.
Field Summary | |
---|---|
static TabPainter |
FACTORY
Deprecated. A TabPainter that uses the id EclipseTheme.TAB_DOCK_TITLE
to get a DockTitleVersion from the DockTitleManager
and create a new DockTitle which is then wrapped by a
DockTitleTab . |
Constructor Summary | |
---|---|
DockTitleTab(DockStation station,
Dockable dockable,
DockTitleVersion title,
EclipseTheme theme)
Deprecated. Creates a new tab. |
Method Summary | |
---|---|
void |
addMouseInputListener(MouseInputListener listener)
Deprecated. Adds a listener to this representative, it is not defined what to do with that listener, but most subclasses would just add the listener to their component . |
void |
addMouseListener(MouseListener listener)
Deprecated. |
void |
addMouseMotionListener(MouseMotionListener listener)
Deprecated. |
void |
bind()
Deprecated. Informs this tab that it will be shown soon |
static TabPainter |
createFactory(TabPainter fallback)
Deprecated. Creates a new factory which uses fallback to create
a TabComponent when no DockTitle is available. |
protected void |
fire()
Deprecated. Fires an event to the DockTitle of this DockTitleTab . |
Component |
getComponent()
Deprecated. Gets the internal representation of this TabComponent , this
method must always return the same value. |
Dockable |
getDockable()
Deprecated. Gets the Dockable which is represented by this tab. |
EclipseTabStateInfo |
getEclipseTabStateInfo()
Deprecated. Gets information about the state of this tab. |
DockElement |
getElement()
Deprecated. Gets the element which is represented by this . |
Dimension |
getMinimumSize(TabComponent[] tabs)
Deprecated. Gets the minimum size of this tab under the assumption that this tab is displayed together with tabs . |
Insets |
getOverlap(TabComponent other)
Deprecated. Gets the number of pixels which should be covered at the sides of this component by other tabs. |
Point |
getPopupLocation(Point click,
boolean popupTrigger)
Deprecated. Tells whether a popup menu should be opened when the user clicks at click with the mouse. |
Dimension |
getPreferredSize(TabComponent[] tabs)
Deprecated. Gets the preferred size of this tab under the assumption that this tab is displayed together with tabs . |
boolean |
isFocused()
Deprecated. Whether the tab is currently focused. |
boolean |
isSelected()
Deprecated. Whether the tab is currently selected. |
boolean |
isUsedAsTitle()
Deprecated. Tells whether this DockElementRepresentative is used as title.Some modules grant more rights to titles than to non-titles, i.e. |
void |
removeMouseInputListener(MouseInputListener listener)
Deprecated. Removes a listener from this representative. |
void |
removeMouseListener(MouseListener listener)
Deprecated. |
void |
removeMouseMotionListener(MouseMotionListener listener)
Deprecated. |
void |
setConfiguration(TabConfiguration configuration)
Deprecated. Fine tunes the look and behavior of this tab. |
void |
setEnabled(boolean enabled)
Deprecated. Calling this method has no effect, as this tab shows a DockTitle which has its own
mechanism to disable itself. |
void |
setFocused(boolean focused)
Deprecated. Tells this component that its Dockable gained or lost focus. |
void |
setIcon(Icon icon)
Deprecated. Sets the icon that should be painted on this tab. |
void |
setOrientation(TabPlacement orientation)
Deprecated. Sets the placement of the tabs and as a result the orientation of this component. |
void |
setPaintIconWhenInactive(boolean paint)
Deprecated. Tells this component whether to paint an Icon if not selected. |
void |
setSelected(boolean selected)
Deprecated. Tells this component whether it has to be painted selected or not. |
void |
setTab(EclipseTab tab)
Deprecated. Informs this TabComponent by which tab is is used. |
void |
setText(String text)
Deprecated. Sets the text that should be displayed on this tab. |
void |
setTooltip(String tooltip)
Deprecated. Sets the tooltip that should be displayed on this tab. |
boolean |
shouldFocus()
Deprecated. Tells whether a click onto this component should transfer the focus either to this component or to the Dockable . |
boolean |
shouldTransfersFocus()
Deprecated. Tells whether a click onto this component should transfer the focus to the Dockable or not. |
void |
unbind()
Deprecated. Informs this tab that it is invisible and must not have any connections to other resources |
void |
update()
Deprecated. Updates the selection and focus state of the title of this tab. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final TabPainter FACTORY
TabPainter
that uses the id EclipseTheme.TAB_DOCK_TITLE
to get a DockTitleVersion
from the DockTitleManager
and create a new DockTitle
which is then wrapped by a
DockTitleTab
.
Constructor Detail |
---|
public DockTitleTab(DockStation station, Dockable dockable, DockTitleVersion title, EclipseTheme theme)
station
- the station which uses the tabbed pane, might be null
dockable
- the element for which this tab is showntitle
- the title which represents the tabtheme
- the theme which uses this tabMethod Detail |
---|
public static final TabPainter createFactory(TabPainter fallback)
fallback
to create
a TabComponent
when no DockTitle
is available.
fallback
- the backup-factory
TabPainter
public EclipseTabStateInfo getEclipseTabStateInfo()
TabComponent
getEclipseTabStateInfo
in interface TabComponent
public void setConfiguration(TabConfiguration configuration)
TabComponent
setConfiguration
in interface TabComponent
configuration
- the new configuration to use, not null
public void setOrientation(TabPlacement orientation)
TabComponent
setOrientation
in interface TabComponent
orientation
- the orientation, not null
public void setTab(EclipseTab tab)
TabComponent
TabComponent
by which tab is is used.
setTab
in interface TabComponent
tab
- the owner of this TabComponent
public void bind()
TabComponent
bind
in interface TabComponent
public void unbind()
TabComponent
unbind
in interface TabComponent
public void addMouseListener(MouseListener listener)
public void addMouseMotionListener(MouseMotionListener listener)
public Component getComponent()
TabComponent
TabComponent
, this
method must always return the same value.
getComponent
in interface TabComponent
getComponent
in interface DockElementRepresentative
null
public Dimension getMinimumSize(TabComponent[] tabs)
TabComponent
tabs
.
getMinimumSize
in interface TabComponent
tabs
- the displayed tabs, exactly one entry is this
and may contain null
entries.
public Dimension getPreferredSize(TabComponent[] tabs)
TabComponent
tabs
.
getPreferredSize
in interface TabComponent
tabs
- the displayed tabs, exactly one entry is this
and may contain null
entries.
public DockElement getElement()
DockElementRepresentative
this
.
The result of this method must not change.
getElement
in interface DockElementRepresentative
null
public Dockable getDockable()
EclipseTabStateInfo
Dockable
which is represented by this tab.
getDockable
in interface EclipseTabStateInfo
null
public boolean isUsedAsTitle()
DockElementRepresentative
DockElementRepresentative
is used as title.DockRelocator
can allow drag & drop only for titles.Dockable
should have only one element that is a title,
so if in doubt return false
.
isUsedAsTitle
in interface DockElementRepresentative
true
if this representative should be seen as titlepublic boolean shouldTransfersFocus()
DockElementRepresentative
Dockable
or not. If this
object is a Dockable
, then a result of true
might change the currently focused item
of itself. This property is ignored if DockElementRepresentative.shouldFocus()
returns false
.
shouldTransfersFocus
in interface DockElementRepresentative
public boolean shouldFocus()
DockElementRepresentative
Dockable
.
shouldFocus
in interface DockElementRepresentative
true
if clicking this component should influence focuspublic void setEnabled(boolean enabled)
DockTitle
which has its own
mechanism to disable itself.
setEnabled
in interface TabComponent
enabled
- whether this component is enabled or notpublic Point getPopupLocation(Point click, boolean popupTrigger)
DockElementRepresentative
click
with the mouse. If yes, then the top left edge
of the popup should be returned, otherwise null
should be
returned.
getPopupLocation
in interface DockElementRepresentative
click
- the location where the user clicked with the mousepopupTrigger
- whether the invocation is the systems popup trigger
or not. Many implementations of this method will return click
in case of true
, and null
in case of false
null
if no
popup-menu should be openedpublic void addMouseInputListener(MouseInputListener listener)
DockElementRepresentative
component
. It is valid to do nothing.
addMouseInputListener
in interface DockElementRepresentative
listener
- the new listenerpublic void removeMouseInputListener(MouseInputListener listener)
DockElementRepresentative
removeMouseInputListener
in interface DockElementRepresentative
listener
- the listener to removepublic Insets getOverlap(TabComponent other)
TabComponent
getOverlap
in interface TabComponent
other
- the component which may overlap this component
public void removeMouseListener(MouseListener listener)
public void removeMouseMotionListener(MouseMotionListener listener)
public void setFocused(boolean focused)
TabComponent
Dockable
gained or lost focus.
setFocused
in interface TabComponent
focused
- the state of its dockable.public boolean isFocused()
EclipseTabStateInfo
isFocused
in interface EclipseTabStateInfo
public void setPaintIconWhenInactive(boolean paint)
TabComponent
Icon
if not selected.
setPaintIconWhenInactive
in interface TabComponent
paint
- true
if an icon is always to be painted,
false
if icons should only appear on selected tabs.public void setSelected(boolean selected)
TabComponent
setSelected
in interface TabComponent
selected
- the selection state of this tabpublic boolean isSelected()
EclipseTabStateInfo
isSelected
in interface EclipseTabStateInfo
public void setIcon(Icon icon)
TabComponent
setIcon
in interface TabComponent
icon
- the icon, can be null
public void setText(String text)
TabComponent
setText
in interface TabComponent
text
- the new textpublic void setTooltip(String tooltip)
TabComponent
setTooltip
in interface TabComponent
tooltip
- the new tooltip, can be null
public void update()
protected void fire()
DockTitle
of this DockTitleTab
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |