bibliothek.extension.gui.dock.theme.eclipse
Interface EclipseThemeConnector

All Known Implementing Classes:
CommonEclipseThemeConnector, DefaultEclipseThemeConnector

public interface EclipseThemeConnector

The EclipseThemeConnector tells the EclipseTheme where to paint tabs and borders. It also tells which DockActions to show on tabs and which actions to hide.

Author:
Janni Kovacs

Nested Class Summary
static class EclipseThemeConnector.TitleBar
          Describes which kind of title, and which kind of DockableDisplayer should be used for a Dockable or a DockStation.
 
Method Summary
 void addEclipseThemeConnectorListener(EclipseThemeConnectorListener listener)
          Adds listener to this connector.
 EclipseThemeConnector.TitleBar getTitleBarKind(DockStation parent, Dockable dockable)
          Tells which kind of title and DockableDisplayer should be shown for dockable assuming everything can be chosen freely.
 void removeEclipseThemeConnectorListener(EclipseThemeConnectorListener listener)
          Removes listener from this connector.
 boolean shouldShowOnSide(DockAction action, EclipseTabStateInfo tab)
          Tells whether action should be shown on the right side of the tab of dockable.
Note that #shouldShowOnSide(DockAction, Dockable) and shouldShowOnTab(DockAction, EclipseTabStateInfo) are independent of each other.
 boolean shouldShowOnTab(DockAction action, EclipseTabStateInfo tab)
          Tells whether action should be shown on the tab of dockable.
Note that #shouldShowOnSide(DockAction, Dockable) and shouldShowOnTab(DockAction, EclipseTabStateInfo) are independent of each other.
 

Method Detail

addEclipseThemeConnectorListener

void addEclipseThemeConnectorListener(EclipseThemeConnectorListener listener)
Adds listener to this connector.

Parameters:
listener - the listener, not null

removeEclipseThemeConnectorListener

void removeEclipseThemeConnectorListener(EclipseThemeConnectorListener listener)
Removes listener from this connector.

Parameters:
listener - the listener to remove

getTitleBarKind

EclipseThemeConnector.TitleBar getTitleBarKind(DockStation parent,
                                               Dockable dockable)
Tells which kind of title and DockableDisplayer should be shown for dockable assuming everything can be chosen freely.

Parameters:
parent - the future or current parent of dockable that will show the DockableDisplayer. May be null.
dockable - the element that stands alone on a DockStation
Returns:
which kind of title and displayer should be used

shouldShowOnSide

boolean shouldShowOnSide(DockAction action,
                         EclipseTabStateInfo tab)
Tells whether action should be shown on the right side of the tab of dockable.
Note that #shouldShowOnSide(DockAction, Dockable) and shouldShowOnTab(DockAction, EclipseTabStateInfo) are independent of each other.

Parameters:
action - the action to show
tab - information about the tab that shows the Dockable
Returns:
whether action should be shown on the right side

shouldShowOnTab

boolean shouldShowOnTab(DockAction action,
                        EclipseTabStateInfo tab)
Tells whether action should be shown on the tab of dockable.
Note that #shouldShowOnSide(DockAction, Dockable) and shouldShowOnTab(DockAction, EclipseTabStateInfo) are independent of each other.

Parameters:
action - the action to show
tab - information about the tab that shows the Dockable
Returns:
whether action should be shown on the tab