Label vs. CLabel : CLabel « SWT « Java Tutorial






Description                          Label      CLabel

Alignment (left, right, and center)  Yes        Yes

Shadow (in, out, and none)           Yes        Yes

Wrap                                 Yes        No

Text                                 Yes        Yes

Image                                Yes        Yes

Text and image                       No         Yes

Tool tip                             Yes        Yes

Background color                     Yes        Yes

Background color gradient            No         Yes

Background image                     No         Yes

Font                                 Yes        Yes

Automatically shorten text           No         Yes








17.14.CLabel
17.14.1.The CLabel ClassThe CLabel Class
17.14.2.Label vs. CLabel
17.14.3.Creating a CLabel
17.14.4.CLabel: left and shadow inCLabel: left and shadow in
17.14.5.CLabel: center and shadow outCLabel: center and shadow out
17.14.6.CLabel: right and shadow noneCLabel: right and shadow none
17.14.7.To draw a gradient background: two colorsTo draw a gradient background: two colors
17.14.8.To draw a gradient background: three colorsTo draw a gradient background: three colors
17.14.9.Set the background image of a CLabel objectSet the background image of a CLabel object