|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Panel
com.google.gwt.user.client.ui.SimplePanel
com.google.gwt.user.client.ui.PopupPanel
org.xwiki.gwt.wysiwyg.client.plugin.color.ColorPicker
public class ColorPicker
A popup panel which allows you to pick a color from a color palette by clicking on that color.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.PopupPanel |
|---|
com.google.gwt.user.client.ui.PopupPanel.PositionCallback |
| Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled |
| Field Summary |
|---|
| Fields inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
DEBUG_ID_PREFIX |
| Constructor Summary | |
|---|---|
ColorPicker(ColorPalette palette)
Creates a new color picker that uses the given color palette. |
|
| Method Summary | |
|---|---|
static java.lang.String |
convertToHex(java.lang.String color)
Converts the specified color code to hex code (as in #F0F0EE). |
java.lang.String |
getColor()
|
protected ColorPalette |
getColorPalette()
|
void |
onSelection(com.google.gwt.event.logical.shared.SelectionEvent<java.lang.String> event)
|
void |
setColor(java.lang.String color)
Sets the color that should appear as selected on the color palette. |
| Methods inherited from class com.google.gwt.user.client.ui.PopupPanel |
|---|
addAutoHidePartner, addCloseHandler, addPopupListener, center, getContainerElement, getGlassElement, getGlassStyleName, getOffsetHeight, getOffsetWidth, getPopupLeft, getPopupTop, getStyleElement, getTitle, hide, hide, isAnimationEnabled, isAutoHideEnabled, isAutoHideOnHistoryEventsEnabled, isGlassEnabled, isModal, isPreviewingAllNativeEvents, isShowing, isVisible, onEventPreview, onKeyDownPreview, onKeyPressPreview, onKeyUpPreview, onPreviewNativeEvent, onUnload, removeAutoHidePartner, removePopupListener, setAnimationEnabled, setAutoHideEnabled, setAutoHideOnHistoryEventsEnabled, setGlassEnabled, setGlassStyleName, setHeight, setModal, setPopupPosition, setPopupPositionAndShow, setPreviewingAllNativeEvents, setTitle, setVisible, setWidget, setWidth, show, showRelativeTo |
| Methods inherited from class com.google.gwt.user.client.ui.SimplePanel |
|---|
add, getWidget, iterator, remove |
| Methods inherited from class com.google.gwt.user.client.ui.Panel |
|---|
adopt, adopt, clear, disown, doAttachChildren, doDetachChildren, onLoad, orphan |
| Methods inherited from class com.google.gwt.user.client.ui.Widget |
|---|
addDomHandler, addHandler, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, removeFromParent, setLayoutData, sinkEvents |
| Methods inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setPixelSize, setSize, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, toString, unsinkEvents |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
|---|
fireEvent |
| Constructor Detail |
|---|
public ColorPicker(ColorPalette palette)
palette - the color palette to be used by this color picker| Method Detail |
|---|
public void onSelection(com.google.gwt.event.logical.shared.SelectionEvent<java.lang.String> event)
onSelection in interface com.google.gwt.event.logical.shared.SelectionHandler<java.lang.String>SelectionHandler.onSelection(SelectionEvent)protected ColorPalette getColorPalette()
public java.lang.String getColor()
public void setColor(java.lang.String color)
color - the color to be selectedpublic static java.lang.String convertToHex(java.lang.String color)
#F0F0EE). The following input formats are supported:
rgb(255,125,75)
color - a color code, in one of the supported formats
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||