bibliothek.gui.dock.station.stack.tab
Class TabConfiguration

java.lang.Object
  extended by bibliothek.gui.dock.station.stack.tab.TabConfiguration

public class TabConfiguration
extends Object

A set of configurations for defining the look of tabs. New configurations are created by the TabConfigurations factory.

Author:
Benjamin Sigg

Nested Class Summary
static class TabConfiguration.ActionHiding
          Tells at which moment actions on a tab should be made invisible
static class TabConfiguration.IconHiding
          Tells at which moment the icon on a tab is made invisible
 
Constructor Summary
TabConfiguration()
           
 
Method Summary
 TabConfiguration.ActionHiding getActionHiding()
          Gets if and when buttons on the tab are made invisible.
 TabConfiguration.IconHiding getIconHiding()
          Gets if and when the icon is made invisible.
 boolean isHiddenActionUsingSpace()
          Tells whether hidden actions still use up some space.
 boolean isKeepLabelBig()
          Tells whether the label should be kept big enough to show the icon even if the tab itself demands a size that is smaller.
 void setActionHiding(TabConfiguration.ActionHiding actionHiding)
          Tells if and when to make buttons on the tab invisible.
 void setHiddenActionUsingSpace(boolean hiddenActionUsingSpace)
          Tells whether hidden actions still can influence the layout by using up some space.
 void setIconHiding(TabConfiguration.IconHiding iconHiding)
          Tells if and when to make the icon invisible.
 void setKeepLabelBig(boolean keepLabelBig)
          Sets whether the label should be kept big enough to show the icon even if the tab itself demands a size that is smaller.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TabConfiguration

public TabConfiguration()
Method Detail

setActionHiding

public void setActionHiding(TabConfiguration.ActionHiding actionHiding)
Tells if and when to make buttons on the tab invisible.

Parameters:
actionHiding - hiding strategy, not null

getActionHiding

public TabConfiguration.ActionHiding getActionHiding()
Gets if and when buttons on the tab are made invisible.

Returns:
the strategy, not null

setIconHiding

public void setIconHiding(TabConfiguration.IconHiding iconHiding)
Tells if and when to make the icon invisible.

Parameters:
iconHiding - hiding strategy, not null

getIconHiding

public TabConfiguration.IconHiding getIconHiding()
Gets if and when the icon is made invisible.

Returns:
the strategy, not null

setKeepLabelBig

public void setKeepLabelBig(boolean keepLabelBig)
Sets whether the label should be kept big enough to show the icon even if the tab itself demands a size that is smaller. This option can lead to some graphical errors as the icon appears to be outside of the tab. The default value of this option is true.

Parameters:
keepLabelBig - whether to keep the label big

isKeepLabelBig

public boolean isKeepLabelBig()
Tells whether the label should be kept big enough to show the icon even if the tab itself demands a size that is smaller.

Returns:
whether to keep the label big
See Also:
setKeepLabelBig(boolean)

setHiddenActionUsingSpace

public void setHiddenActionUsingSpace(boolean hiddenActionUsingSpace)
Tells whether hidden actions still can influence the layout by using up some space. If true hidden actions are assumed to require 0 pixels but still have a border, otherwise the actions are treated as if they would not exist. The default value of this property is true.

Parameters:
hiddenActionUsingSpace - whether hidden actions have an influence on the layout or not

isHiddenActionUsingSpace

public boolean isHiddenActionUsingSpace()
Tells whether hidden actions still use up some space.

Returns:
wether hidden actions use space
See Also:
setHiddenActionUsingSpace(boolean)