Class AbstractSettings
java.lang.Object
org.eclipse.nebula.widgets.collapsiblebuttons.AbstractSettings
- All Implemented Interfaces:
ISettings
- Direct Known Subclasses:
DefaultSettings
public class AbstractSettings extends java.lang.Object implements ISettings
-
Constructor Summary
Constructors Constructor Description AbstractSettings()
-
Method Summary
Modifier and Type Method Description boolean
allowButtonResizing()
Whether buttons can be resized via the resize bar.boolean
drawBorder()
Whether to draw a 1 pixel border on the left, right and top side of the ButtonComposite.int
getButtonHeight()
Returns the height of a button.IButtonPainter
getButtonPainter()
Returns the IButtonPainter to use to paint buttons.org.eclipse.swt.graphics.Color
getButtonTextColor()
Returns the Color used for the text on the buttons.org.eclipse.swt.graphics.Font
getButtonTextFont(org.eclipse.swt.graphics.Font currentFont)
Returns the Font to use when drawing text on the buttons.int
getButtonTextImageSpacing()
Returns the spacing between the image and the text on a button.int
getLeftButtonTextSpacing()
Returns the spacing between the left side border and the text on a button.org.eclipse.swt.graphics.Image
getOutlook2005ArrowImage()
Returns the image for the Outlook 2005 styled arrow.int
getOutlook2005ResizeBarSize()
Returns the pixel height of the Outlook 2005 resize bar.int
getOutlook2005ResizeDotNumber()
Returns the number of dots shown on the resize bar for the Outlook 2005 styled resize bar.org.eclipse.swt.graphics.Image
getOutlook2007ArrowImage()
Returns the image for the Outlook 2007 styled arrow.int
getOutlook2007ResizeBarSize()
Returns the pixel height of the Outlook 2007 resize bar.int
getOutlook2007ResizeDotNumber()
Returns the number of dots shown on the resize bar for the Outlook 2007 styled resize bar.int
getToolBarLeftSpacer()
Returns the number of pixels left of an item on the toolbar that the selection area should cover.int
getToolBarRightSpacer()
Returns the number of pixels right of an item on the toolbar that the selection area should cover.int
getToolBarSpacing()
Returns the number of pixels between each item on the toolbar.boolean
showToolBar()
Whether to show the toolbar at the bottom or not.
-
Constructor Details
-
AbstractSettings
public AbstractSettings()
-
-
Method Details
-
allowButtonResizing
public boolean allowButtonResizing()Description copied from interface:ISettings
Whether buttons can be resized via the resize bar.- Specified by:
allowButtonResizing
in interfaceISettings
- Returns:
- true if to allow button resizing. Default is true.
-
drawBorder
public boolean drawBorder()Description copied from interface:ISettings
Whether to draw a 1 pixel border on the left, right and top side of the ButtonComposite.- Specified by:
drawBorder
in interfaceISettings
- Returns:
- true if draw border. Default is false.
-
getButtonHeight
public int getButtonHeight()Description copied from interface:ISettings
Returns the height of a button.- Specified by:
getButtonHeight
in interfaceISettings
- Returns:
- Button height. Default is 31.
-
getOutlook2005ArrowImage
public org.eclipse.swt.graphics.Image getOutlook2005ArrowImage()Description copied from interface:ISettings
Returns the image for the Outlook 2005 styled arrow.- Specified by:
getOutlook2005ArrowImage
in interfaceISettings
- Returns:
- Image
-
getOutlook2007ArrowImage
public org.eclipse.swt.graphics.Image getOutlook2007ArrowImage()Description copied from interface:ISettings
Returns the image for the Outlook 2007 styled arrow.- Specified by:
getOutlook2007ArrowImage
in interfaceISettings
- Returns:
- Image
-
getOutlook2005ResizeBarSize
public int getOutlook2005ResizeBarSize()Description copied from interface:ISettings
Returns the pixel height of the Outlook 2005 resize bar.- Specified by:
getOutlook2005ResizeBarSize
in interfaceISettings
- Returns:
- Height in pixels. Default is 7.
-
getOutlook2007ResizeBarSize
public int getOutlook2007ResizeBarSize()Description copied from interface:ISettings
Returns the pixel height of the Outlook 2007 resize bar.- Specified by:
getOutlook2007ResizeBarSize
in interfaceISettings
- Returns:
- Height in pixels. Default is 9.
-
showToolBar
public boolean showToolBar()Description copied from interface:ISettings
Whether to show the toolbar at the bottom or not.- Specified by:
showToolBar
in interfaceISettings
- Returns:
- true if to show toolbar. Default is true.
-
getOutlook2005ResizeDotNumber
public int getOutlook2005ResizeDotNumber()Description copied from interface:ISettings
Returns the number of dots shown on the resize bar for the Outlook 2005 styled resize bar.- Specified by:
getOutlook2005ResizeDotNumber
in interfaceISettings
- Returns:
- Number of dots to show. Default is 9.
-
getOutlook2007ResizeDotNumber
public int getOutlook2007ResizeDotNumber()Description copied from interface:ISettings
Returns the number of dots shown on the resize bar for the Outlook 2007 styled resize bar.- Specified by:
getOutlook2007ResizeDotNumber
in interfaceISettings
- Returns:
- Number of dots to show. Default is 5.
-
getButtonPainter
Description copied from interface:ISettings
Returns the IButtonPainter to use to paint buttons.- Specified by:
getButtonPainter
in interfaceISettings
- Returns:
- IButtonPainter. Default is DefaultButtonPainter.
-
getButtonTextFont
public org.eclipse.swt.graphics.Font getButtonTextFont(org.eclipse.swt.graphics.Font currentFont)Description copied from interface:ISettings
Returns the Font to use when drawing text on the buttons. Font will be disposed after use.- Specified by:
getButtonTextFont
in interfaceISettings
- Parameters:
currentFont
- The current font that it is recommended to modify and return- Returns:
- Font to use. Default is a bold font.
-
getButtonTextColor
public org.eclipse.swt.graphics.Color getButtonTextColor()Description copied from interface:ISettings
Returns the Color used for the text on the buttons.- Specified by:
getButtonTextColor
in interfaceISettings
- Returns:
- Color. Default is R32 G77 B137.
-
getToolBarLeftSpacer
public int getToolBarLeftSpacer()Description copied from interface:ISettings
Returns the number of pixels left of an item on the toolbar that the selection area should cover.- Specified by:
getToolBarLeftSpacer
in interfaceISettings
- Returns:
- Pixel number.
-
getToolBarRightSpacer
public int getToolBarRightSpacer()Description copied from interface:ISettings
Returns the number of pixels right of an item on the toolbar that the selection area should cover.- Specified by:
getToolBarRightSpacer
in interfaceISettings
- Returns:
- Pixel number.
-
getToolBarSpacing
public int getToolBarSpacing()Description copied from interface:ISettings
Returns the number of pixels between each item on the toolbar.- Specified by:
getToolBarSpacing
in interfaceISettings
- Returns:
- Pixel spacing. Default is 8.
-
getButtonTextImageSpacing
public int getButtonTextImageSpacing()Description copied from interface:ISettings
Returns the spacing between the image and the text on a button.- Specified by:
getButtonTextImageSpacing
in interfaceISettings
- Returns:
- pixels spacing. Default is 5.
-
getLeftButtonTextSpacing
public int getLeftButtonTextSpacing()Description copied from interface:ISettings
Returns the spacing between the left side border and the text on a button.- Specified by:
getLeftButtonTextSpacing
in interfaceISettings
- Returns:
- pixels spacing. Default is 4.
-