Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "7 Basic Controls"
m (→Class Label) |
(→Class Button) |
||
Line 21: | Line 21: | ||
* alignment (<code>LEFT</code>, <code>CENTER</code>, <code>RIGHT</code>) | * alignment (<code>LEFT</code>, <code>CENTER</code>, <code>RIGHT</code>) | ||
* SelectionListener | * SelectionListener | ||
+ | * Default button behavior (see [[11_Controls%2C_Composites%2C_Groups%2C_and_Shells#Class_Shell|Shell]]) | ||
===Class Text=== | ===Class Text=== |
Revision as of 08:45, 17 February 2007
RWT will have the same behavior for all basic controls as SWT does. Currently there exists an incomplete implementation that provides basic functionality.
Class Label
Currently implemented:
- get/set text
- get/set image
- Note: Just like in SWT, the label can only display a string or an image but not both at the same time. When both is set, the label displays the object that was set last. However, the behavior of the RWT label differs slightly from SWT in that that setting an image clears the text and vice versa. As a result, calling
getImage()
after setting a text usingsetText()
returnsnull
even though an image has been set previously.
- alignment (
LEFT
,CENTER
,RIGHT
) -
SEPARATOR
style, both horizontal and vertical with the same styles as supported by SWT:SHADOW_NONE
,SHADOW_IN
,SHADOW_OUT
Class Button
Currently implemented:
- the types
CHECK
,PUSH
,RADIO
- get/set text and image
- selection
- alignment (
LEFT
,CENTER
,RIGHT
) - SelectionListener
- Default button behavior (see Shell)
Class Text
Currently implemented:
- get/set text
- SINGLE, MULTI and PASSWORD styles
- READ_ONLY
Class List
Currently implemented:
- all selection-related methods
- handling of focused item
- all item operations
- control scroll behaviour similar to SWT via
H_SCROLL
andV_SCROLL
style flags: scroll never, scroll horizontal only, scroll vertical only, automatically scroll when necessary - SelectionListener
Class Combo
Currently Implemented:
- all selection-related methods
- all item operations
- SelectionListener