Class WCssDecorationStyle
You can manipulate the decoration style of a single widget using WWidget.getDecorationStyle() or you can use a WCssDecorationStyle to add a rule to the
inline style sheet using WCssStyleSheet#addRule().
-
Nested Class Summary
Nested classes/interfaces inherited from class WObject
WObject.FormData -
Constructor Summary
ConstructorsConstructorDescriptionCreates a default style.Copy constructor. -
Method Summary
Modifier and TypeMethodDescriptionReturns the background color.Returns the background image URL.Returns the background image repeat.final WBorderReturns the border style.Returns the border style.Returns the cursor style.Returns the cursor image.getFont()Returns the font.Returns the text color.Returns the text decoration options.voidsetBackgroundColor(WColor color) Sets the background color.final voidsetBackgroundImage(WLink image) Sets a background image.final voidsetBackgroundImage(WLink image, EnumSet<Orientation> repeat) Sets a background image.final voidsetBackgroundImage(WLink image, EnumSet<Orientation> repeat, Side side, Side... sides) Sets a background image.voidsetBackgroundImage(WLink image, EnumSet<Orientation> repeat, EnumSet<Side> sides) Sets a background image.final voidsetBackgroundImage(String url) Sets a background image.final voidsetBackgroundImage(String url, EnumSet<Orientation> repeat) Sets a background image.final voidsetBackgroundImage(String url, EnumSet<Orientation> repeat, Side side, Side... sides) Sets a background image.voidsetBackgroundImage(String url, EnumSet<Orientation> repeat, EnumSet<Side> sides) Sets a background image.final voidSets the border style.final voidSets the border style.voidSets the border style.voidSets the cursor style.final voidSets a custom cursor image Url.voidSets a custom cursor image Url.voidSets the text font.voidsetForegroundColor(WColor color) Sets the text color.final voidsetTextDecoration(TextDecoration option, TextDecoration... options) Sets text decoration options.voidsetTextDecoration(EnumSet<TextDecoration> options) Sets text decoration options.Methods inherited from class WObject
getId, getObjectName, remove, resendFormData, setFormData, setObjectName, tr
-
Constructor Details
-
WCssDecorationStyle
public WCssDecorationStyle()Creates a default style. -
WCssDecorationStyle
Copy constructor.
-
-
Method Details
-
setCursor
Sets the cursor style. -
getCursor
-
setCursor
-
setCursor
Sets a custom cursor image Url. -
getCursorImage
-
setBackgroundColor
Sets the background color. -
getBackgroundColor
-
setBackgroundImage
Sets a background image.The
linkmay be a URL or a resource.The image may be placed in a particular location by specifying sides by OR'ing
Sidevalues together, e.g. (Side.Right|Side.Top). -
setBackgroundImage
public final void setBackgroundImage(WLink image, EnumSet<Orientation> repeat, Side side, Side... sides) Sets a background image.Calls
setBackgroundImage(image, repeat, EnumSet.of(side, sides)) -
setBackgroundImage
Sets a background image. -
setBackgroundImage
Sets a background image.Calls
setBackgroundImage(image, repeat, EnumSet.noneOf(Side.class)) -
setBackgroundImage
Sets a background image.The image may be placed in a particular location by specifying sides by OR'ing
Sidevalues together, e.g. (Side.Right|Side.Top). -
setBackgroundImage
public final void setBackgroundImage(String url, EnumSet<Orientation> repeat, Side side, Side... sides) Sets a background image.Calls
setBackgroundImage(url, repeat, EnumSet.of(side, sides)) -
setBackgroundImage
Sets a background image. -
setBackgroundImage
Sets a background image.Calls
setBackgroundImage(url, repeat, EnumSet.noneOf(Side.class)) -
getBackgroundImage
-
getBackgroundImageRepeat
Returns the background image repeat.- See Also:
-
setForegroundColor
Sets the text color. -
getForegroundColor
-
setBorder
-
setBorder
Sets the border style. -
setBorder
Sets the border style. -
getBorder
Returns the border style.Returns the border style set using
setBorder()for the givenside.- See Also:
-
getBorder
Returns the border style.Returns
getBorder(Side.Top) -
setFont
Sets the text font. -
getFont
-
setTextDecoration
Sets text decoration options.You may logically or together any of the options of the TextDecoration enumeration.
The default is 0.
-
setTextDecoration
Sets text decoration options. -
getTextDecoration
-