@Deprecated public abstract class AbstractColorPicker extends AbstractLegacyComponent implements Window.CloseListener, ColorSelector
| Modifier and Type | Class and Description |
|---|---|
static interface |
AbstractColorPicker.Coordinates2Color
Deprecated.
|
static class |
AbstractColorPicker.PopupStyle
Deprecated.
|
Component.ErrorEvent, Component.Event, Component.Focusable, Component.ListenerClientConnector.AttachEvent, ClientConnector.AttachListener, ClientConnector.ConnectorErrorEvent, ClientConnector.DetachEvent, ClientConnector.DetachListenerSizeable.Unit| Modifier and Type | Field and Description |
|---|---|
protected Color |
color
Deprecated.
The color.
|
protected boolean |
historyVisible
Deprecated.
|
protected boolean |
hsvVisible
Deprecated.
|
protected String |
popupCaption
Deprecated.
|
protected AbstractColorPicker.PopupStyle |
popupStyle
Deprecated.
|
protected boolean |
rgbVisible
Deprecated.
|
protected static String |
STYLENAME_AREA
Deprecated.
|
protected static String |
STYLENAME_BUTTON
Deprecated.
|
protected static String |
STYLENAME_DEFAULT
Deprecated.
|
protected boolean |
swatchesVisible
Deprecated.
|
protected boolean |
textfieldVisible
Deprecated.
|
DESIGN_ATTR_PLAIN_TEXTSIZE_UNDEFINED, UNITS_CM, UNITS_EM, UNITS_EX, UNITS_INCH, UNITS_MM, UNITS_PERCENTAGE, UNITS_PICAS, UNITS_PIXELS, UNITS_POINTS| Constructor and Description |
|---|
AbstractColorPicker()
Deprecated.
Instantiates a new color picker.
|
AbstractColorPicker(String popupCaption)
Deprecated.
Instantiates a new color picker.
|
AbstractColorPicker(String popupCaption,
Color initialColor)
Deprecated.
Instantiates a new color picker.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addColorChangeListener(ColorChangeListener listener)
Deprecated.
Adds a
ColorChangeListener to the component. |
protected void |
colorChanged(ColorChangeEvent event)
Deprecated.
Fired when a color change event occurs.
|
void |
fireColorChanged()
Deprecated.
Notifies the listeners that the selected color has changed.
|
Color |
getColor()
Deprecated.
Gets the color.
|
protected Collection<String> |
getCustomAttributes()
Deprecated.
|
boolean |
getHistoryVisibility()
Deprecated.
Gets the visibility of the Color History.
|
boolean |
getHSVVisibility()
Deprecated.
Gets the visibility of the HSV Tab.
|
AbstractColorPicker.PopupStyle |
getPopupStyle()
Deprecated.
Gets the style for the popup window.
|
boolean |
getRGBVisibility()
Deprecated.
Gets the visibility of the RGB Tab.
|
protected ColorPickerState |
getState()
Deprecated.
|
protected ColorPickerState |
getState(boolean markAsDirty)
Deprecated.
|
boolean |
getSwatchesVisibility()
Deprecated.
Gets the visibility of the Swatches Tab.
|
boolean |
getTextfieldVisibility()
Deprecated.
Gets the visibility of CSS color code text field.
|
void |
hidePopup()
Deprecated.
Hides a popup-window for color selection.
|
boolean |
isDefaultCaptionEnabled()
Deprecated.
Returns true if the component shows the default caption (css-code for the
currently selected color, e.g.
|
boolean |
isHtmlContentAllowed()
Deprecated.
as of , use
AbstractComponent.isCaptionAsHtml() instead |
void |
readDesign(org.jsoup.nodes.Element design,
DesignContext designContext)
Deprecated.
|
void |
removeColorChangeListener(ColorChangeListener listener)
Deprecated.
Removes a
ColorChangeListener from the component. |
void |
setColor(Color color)
Deprecated.
Sets the color.
|
void |
setDefaultCaptionEnabled(boolean enabled)
Deprecated.
Set true if the component should show a default caption (css-code for the
currently selected color, e.g.
|
protected abstract void |
setDefaultStyles()
Deprecated.
Sets the default styles of the component.
|
void |
setHistoryVisibility(boolean visible)
Deprecated.
Sets the visibility of the Color History.
|
void |
setHSVVisibility(boolean visible)
Deprecated.
Set the visibility of the HSV Tab.
|
void |
setHtmlContentAllowed(boolean htmlContentAllowed)
Deprecated.
as of , use
AbstractComponent.setCaptionAsHtml(boolean) instead |
void |
setPopupStyle(AbstractColorPicker.PopupStyle style)
Deprecated.
The style for the popup window.
|
void |
setPosition(int x,
int y)
Deprecated.
Sets the position of the popup window.
|
void |
setRGBVisibility(boolean visible)
Deprecated.
Set the visibility of the RGB Tab.
|
void |
setSwatchesVisibility(boolean visible)
Deprecated.
Set the visibility of the Swatches Tab.
|
void |
setTextfieldVisibility(boolean visible)
Deprecated.
Sets the visibility of the CSS color code text field.
|
void |
showPopup()
Deprecated.
Shows a popup-window for color selection.
|
protected void |
showPopup(boolean open)
Deprecated.
Shows or hides popup-window depending on the given parameter.
|
void |
windowClose(Window.CloseEvent e)
Deprecated.
|
void |
writeDesign(org.jsoup.nodes.Element design,
DesignContext designContext)
Deprecated.
|
beforeClientResponse, getExplicitImmediateValue, isImmediate, isReadOnly, setImmediate, setReadOnlyaddContextClickListener, addListener, addShortcutListener, addStyleName, attach, detach, findAncestor, fireComponentErrorEvent, fireComponentEvent, focus, getActionManager, getCaption, getComponentError, getData, getDebugId, getDescription, getErrorMessage, getHeight, getHeightUnits, getIcon, getId, getLocale, getParent, getPrimaryStyleName, getStyleName, getWidth, getWidthUnits, isCaptionAsHtml, isConnectorEnabled, isEnabled, isOrHasAncestor, isRequiredIndicatorVisible, isResponsive, isVisible, removeContextClickListener, removeListener, removeShortcutListener, removeStyleName, setCaption, setCaptionAsHtml, setComponentError, setData, setDebugId, setDescription, setDescription, setEnabled, setHeight, setHeight, setHeightUndefined, setIcon, setId, setLocale, setParent, setPrimaryStyleName, setRequiredIndicatorVisible, setResponsive, setSizeFull, setSizeUndefined, setStyleName, setVisible, setWidth, setWidth, setWidthUndefinedaddAttachListener, addDetachListener, addExtension, addListener, addListener, addListener, addMethodInvocationToQueue, createState, encodeState, equals, fireEvent, getAllChildrenIterable, getConnectorId, getErrorHandler, getExtensions, getListeners, getResource, getRpcManager, getRpcProxy, getSession, getStateType, getUI, handleConnectorRequest, hashCode, hasListeners, isAttached, isThis, markAsDirty, markAsDirtyRecursive, registerRpc, registerRpc, removeAttachListener, removeDetachListener, removeExtension, removeListener, removeListener, removeListener, removeListener, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandler, setResource, updateDiffstateclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitaddStyleNames, getUI, removeStyleNames, setStyleNameaddAttachListener, addDetachListener, encodeState, getErrorHandler, getExtensions, getRpcManager, getStateType, handleConnectorRequest, isAttached, markAsDirty, markAsDirtyRecursive, removeAttachListener, removeDetachListener, removeExtension, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandlerprotected static final String STYLENAME_DEFAULT
protected static final String STYLENAME_BUTTON
protected static final String STYLENAME_AREA
protected AbstractColorPicker.PopupStyle popupStyle
protected Color color
protected String popupCaption
protected boolean rgbVisible
protected boolean hsvVisible
protected boolean swatchesVisible
protected boolean historyVisible
protected boolean textfieldVisible
public AbstractColorPicker()
public AbstractColorPicker(String popupCaption)
popupCaption - the caption of the popup windowpublic void setColor(Color color)
ColorSelectorsetColor in interface ColorSelectorcolor - the new colorpublic Color getColor()
ColorSelectorgetColor in interface ColorSelectorpublic void setDefaultCaptionEnabled(boolean enabled)
enabled - public boolean isDefaultCaptionEnabled()
public void setPosition(int x,
int y)
x - the x-coordinatey - the y-coordinatepublic void addColorChangeListener(ColorChangeListener listener)
HasColorChangeListenerColorChangeListener to the component.addColorChangeListener in interface HasColorChangeListenerpublic void removeColorChangeListener(ColorChangeListener listener)
HasColorChangeListenerColorChangeListener from the component.removeColorChangeListener in interface HasColorChangeListenerpublic void windowClose(Window.CloseEvent e)
windowClose in interface Window.CloseListenerprotected void colorChanged(ColorChangeEvent event)
event - The color change eventpublic void fireColorChanged()
public void setPopupStyle(AbstractColorPicker.PopupStyle style)
style - The stylepublic AbstractColorPicker.PopupStyle getPopupStyle()
public void setRGBVisibility(boolean visible)
visible - The visibilitypublic boolean getRGBVisibility()
public void setHSVVisibility(boolean visible)
visible - The visibilitypublic boolean getHSVVisibility()
public void setSwatchesVisibility(boolean visible)
visible - The visibilitypublic boolean getSwatchesVisibility()
public void setHistoryVisibility(boolean visible)
visible - The visibilitypublic boolean getHistoryVisibility()
public void setTextfieldVisibility(boolean visible)
visible - The visibilitypublic boolean getTextfieldVisibility()
protected ColorPickerState getState()
getState in class AbstractLegacyComponentprotected ColorPickerState getState(boolean markAsDirty)
getState in class AbstractLegacyComponentprotected abstract void setDefaultStyles()
public void showPopup()
public void hidePopup()
protected void showPopup(boolean open)
open - @Deprecated public void setHtmlContentAllowed(boolean htmlContentAllowed)
AbstractComponent.setCaptionAsHtml(boolean) insteadhtmlContentAllowed - true if caption is rendered as HTML,
false otherwise@Deprecated public boolean isHtmlContentAllowed()
AbstractComponent.isCaptionAsHtml() insteadtrue if the caption text is to be rendered as HTML,
false otherwisepublic void readDesign(org.jsoup.nodes.Element design,
DesignContext designContext)
readDesign in interface ComponentreadDesign in class AbstractLegacyComponentpublic void writeDesign(org.jsoup.nodes.Element design,
DesignContext designContext)
writeDesign in interface ComponentwriteDesign in class AbstractLegacyComponentprotected Collection<String> getCustomAttributes()
getCustomAttributes in class AbstractComponentCopyright © 2019 Vaadin Ltd. All rights reserved.