Since 4.3
The ace:triStateCheckbox component is a checkbox that, besides the usual checked and unchecked states, can also take the indeterminate state, which can have different meanings, depending on the application. The possible values are the strings 'checked', 'indeterminate', and 'unchecked'. Any other string or a null value defaults to the 'unchecked' state.
<html ... xmlns:ace="http://www.icefaces.org/icefaces/components">
<h:body>
<h:form>
<ace:triStateCheckbox value="#{button.state}" />
</h:form>
</h:body>
</html>
TagLib Documentation
This section covers attributes involved in the typical use-cases for this component.
indeterminateBeforeChecked If true, the order of the states when this button is activated will be "unchecked-indeterminate-checked". Otherwise, the order will be "unchecked-checked-indeterminate".
label The label of the button-what the user sees that relates to that particular button. For example, "Remember Me"
style a pass through to the root element of the component.
group ID of button group component if this button is outside of the button group but wants to logically belong to the group.
styleClass a pass through to the root element of the component.
tabindex a pass through to the root element of the component, default=0.
disabled a pass through to the root element of the component.
The following attributes are supported as pass-thru attributes: alt, dir, lang, title, type, onchange, onselect, onclick, ondblclick, onkeydown, onkeypress, onkeyup, onmousedown, onmousemove, onmouseout, onmouseover, onmouseup, onblur, onfocus
As a descendant of UIInput, this component supports a value change listener.
| valueChangeListener | Method that will be notified when a new value has been set for this component |
|---|
| action | Fired when the button is clicked or pressed by any other means (default event). |
|---|
Fired when the button is clicked or pressed by any other means (default event).
The "widgetVar" attribute on the ACE components has been removed in ICEfaces 4 and in its place a new "ice.ace.instance()" client JavaScript object lookup API has been introduced. The reason for this change is to enable lazy-initialization of the ACE component JavaScript objects to improve runtime performance and reduce browser memory use.
var widget = ice.ace.instance('frm:componentId);
The ice.ace.instance function requires the full client id of the component to be specified, such as "j_idt77:componentId" instead of just "componentId". To reduce the complexity of working with complete IDs with this function it may be preferable in some cases to use
prependId="false"in the enclosing form (e.g. <h:form prependId="false">).
This component doesn't have a client-side API made specifically to be used by application developers. However, the component's internal methods and variables can be accessed in this way, including the underlying jQuery object and objects from underlying Javascript libraries (if applicable), and can be used for whatever purpose a developer might have in mind.
Default browser keyboard support for <button> elements (i.e. tabbing in and out, pressing space to activate).
The following ARIA roles are supported: checkbox.
The following markup represents the basic HTML structure of the component and the CSS classes it uses.
<!-- Root container -->
<div class="ice-tristatecheckbox [user defined classes]" style="[user defined styles]">
<span class="ui-button ui-widget">
<span class="first-child">
<button class="ui-corner-all ui-widget-content ice-tristatecheckbox-checked">
<!-- Icon -->
<span class="fa fa-check-square-o fa-lg"></span>
</button>
</span>
</span>
</div>
None.