Oracle ADF Faces - af:chooseColor
Summary

Tag name: < af:chooseColor >

UIComponent class: oracle.adf.view.faces.component.core.input.CoreChooseColor

Component type: oracle.adf.CoreChooseColor

The chooseColor control creates a palette for picking colors. A chooseColor can display two sets of colors:

  • A set of standard colors, as specified by the colorData attribute.
  • A set of custom colors which extend the set of colors available in the standard palette. Custom colors are specified by the customColorData attribute.

Both the colorData and customColorData attributes accept both List and array objects, each of which contain one java.awt.Color instance for each color to display.

In order to simplify the use of standard palettes, ADF Faces makes certain palettes available via the uix.colorPalette EL implicit object. The "#{adfFacesContext.colorPalette}" implicit object provides access to four standard color palettes:

  • "default49" : 49 colors, including one transparent entry.
  • "opaque49" : 49 colors, without a transparent entry.
  • "default80" : 80 colors, including one transparent entry.
  • "web216" : the 216 "web-safe" colors.

Example:

<!-- A chooseColor which uses the standard "default49" palette -->
<af:chooseColor id="cc0"
                colorData="#{adfFacesContext.colorPalette.default49}"/>

<!-- A chooseColor which defines custom colors using inline data -->
<af:chooseColor id="cc1" colorData="#{adfFacesContext.colorPalette.default49}"
                         customColorData="#{myBean.listOfColors}">

<!-- A chooseColor that is associated with a selectInputColor -->
<af:selectInputColor id="sic1" chooseId="cc2"/>
<af:chooseColor id="cc2" width="18"
                colorData="#{adfFacesContext.colorPalette.web216}"/>
            

Attributes
Ungrouped attributes
Name Type Supports EL? Description
attributeChangeListener javax.faces.el.MethodBinding Only EL a method reference to an attribute change listener
colorData java.util.List Yes the list of colors for the component
customColorData java.util.List Yes the list of custom colors for the component
partialTriggers String[ ] Yes the IDs of the components that should trigger a partial update. This component will listen on the trigger components. If one of the trigger components receives an event that will cause it to update in some way, this component will request to be updated too.
width int Yes the width of the standard palette in cells
Core attributes
Name Type Supports EL? Description
binding oracle.adf.view.faces.component. core.input.CoreChooseColor Only EL a binding reference to store the component instance
id String No the identifier for the component. This must be a valid XML ID, and therefore may not contain whitespace or start with a number. Also, JSF requires that IDs must not contain any colons (":").
inlineStyle String Yes the inline CSS style for this element
rendered boolean Yes whether the bean is rendered. When set to false, no output will be delivered for this bean.
shortDesc String Yes the short description of the bean. This text is commonly used by user agents to display tooltip help text.
styleClass String Yes the CSS style class of the bean.
Javascript attributes
Name Type Supports EL? Description
onclick String Yes an onclick Javascript handler.
ondblclick String Yes an ondblclick Javascript handler.
onkeydown String Yes an onkeydown Javascript handler.
onkeypress String Yes an onkeypress Javascript handler.
onkeyup String Yes an onkeyup Javascript handler.
onmousedown String Yes an onmousedown Javascript handler.
onmousemove String Yes an onmousemove Javascript handler.
onmouseout String Yes an onmouseout Javascript handler.
onmouseover String Yes an onmouseover Javascript handler.
onmouseup String Ye s an onmouseup Javascript handler.
Copyright © 2003-2006, Oracle Corporation. All Rights Reserved.

E-mail this page
Printer View Printer View
Oracle Is The Information Company About Oracle | Oracle RSS Feeds | Careers | Contact Us | Site Maps | Legal Notices | Terms of Use | Privacy