The SWidgets are a collection of custom SWT widgets that are designed for use in Lotus
® Expeditor applications.
The custom widget library embraces the SWT programming model and enables applications to mix and match these widgets with standard SWT widgets. SWidgets extend the capabilities for customizing the look and feel of controls provided by standard SWT widgets. SWidgets, like all standard custom widgets based on SWT, subclass the Canvas class and register all the necessary event handlers. For SWidgets that are similar to SWT controls, such as the SMenu
classes, the SWidget API is compatible with the API of the equivalent SWT control. The advantage of using SWidgets is that the look and feel of controls created using SWidgets is customizable. SWidgets are customizable because they use a paint delegate pattern that enables all the rendering for the widgets to be done by a pluggable delegate object. The paint delegate objects act like the skin of the control, and are referred to as skins. In fact, the S in front of the widget class names stands for skinnable.
The library contains the following SWidgets:
- SButton – Represents a button. It is used, for example, as the control that a user clicks to activate the launch menu. The SButton custom widget provides support for customizable rendering and some alignment options that the standard SWT button does not support.
- SMenu – Represents the launch menu and other menus in the client. The SMenu custom widget provides support for customizable rendering. It also provides functionality that the standard SWT menu does not provide, such as support for context menus. The SCoolBar supports tearing out and floating menu items or docking SMenu items in a SCoolBar in the form of a floating SToolBar.
- SToolbar and SCoolbar – Represent the main window toolbar. A SCoolbar is a container widget that contains instances of SToolbars that may be repositioned or floated. The SToolbar widget also represents the toolbar inside view parts and editor parts in the workbench. A toolbar that displays in a view or editor is commonly referred to as an action bar. The widgets provide support for a customizable rendering and functionality that the standard SWT toolbar and coolbar do not. For example, the SCoolBar supports tearing out and floating toolbars. The SToolBar and SCoolBar widgets both have corresponding Jface contribution and wrapper classes. The API for these classes is very similar to the API for the standard Jface manager and contribution classes.
- STabFolder – Represents a “grouped tab.” Grouped tabs allow for child tabs to be consolidated under a parent tab and made accessible through a pop-up menu. The STabFolder is used in the main launcher user interface and to represent tabs in many other places in the user interface.
- STable – Represents a table that structures the data that displays in views or editors. The custom table widget provides support for a customizable rendering and functionality that the standard SWT table does not provide.
- SViewForm and SViewStack – The SViewForm widget represents the area surrounding sidebar and stand–alone views within a perspective. The SViewStack widget represents the container for a collection of sidebar panels and enables you to resize and collapse the stack horizontally.
The custom widgets are provided in the com.ibm.rcp.swtex
plug-in, which has dependencies on the org.eclipse.swt
plug-in. The library also contains a set of JFaceEX action classes.
Parent topic: Customizing the user interface