Oracle Fusion Middleware Tag Reference for Oracle ADF Faces 11g Release 1 (11.1.1.5.0) E12419-07 |
UIComponent class: oracle.adf.view.rich.component.rich.layout.RichToolbar
Component type: oracle.adf.RichToolbar
Unsupported agents: pda
A toolbar is designed to be used inside of an <af:toolbox>
and usually contains commandToolbarButtons or groups of commandToolbarButtons. You may use a toolbar outside of a toolbox though doing so will cause the toolbar to lose some of the geometry management functionality that the toolbox and toolbar provide. For example, the flex attribute will have no feasible meaning if the toolbar is not inside a toolbox. Toolbars are not rendered on printable pages.
Typically you would put a commandToolbarButton or group component in a toolbar. You may alternatively put a facetRef, iterator, or switcher in a toolbar if these wrappers provide components that would normally belong in the toolbar.
If you group the children of a toolbar, separators will be drawn between the children of a group.
If you have an <af:toolbox>
with multiple toolbars or menuBars displayed on a single row, you can specify how they are stretched in relationship to each other by specifying their flex
attributes. You can control stretching within a toolbar by using its stretchId
property. If you want a toolbar to align certain items to the left, and other items to the right, you can put an <af:spacer>
in between them. You would then specify the toolbar's stretchId to that spacer. A toolbar that specifies a stretchId should also have a flex value assigned, to indicate to the toolbox that it requires special handling.
<af:toolbox> <af:toolbar flex="1" stretchid="stretch1"> <af:group> <af:commandToolbarButton text="Forward" icon="/images/fwdarrow_gray.gif" disabled="true"></af:commandToolbarButton> <af:commandToolbarButton icon="/images/uplevel.gif" /> </af:group> <af:commandToolbarButton id="search" text="Search" icon="/images/search.gif" /> <af:commandToolbarButton text="Folders" icon="/images/folders.gif" /> <af:spacer id="stretch1" clientComponent="true"/> <af:commandToolbarButton text="Reports" /> <af:commandToolbarButton id="toggleRefresh" text="Refresh:OFF" /> </af:toolbar> </af:toolbox>
Note that if a toolbar child component is going to be updated through partial page rendering, you need to update the toolbar as well. You do this by adding the child components id to the toolbar's partialTriggers attribute. This way the toolbar can appropriately manage its children in respect to sizing and placement in overflow. Also note that many input components also update themselves through partial page rendering. If you include an input component (or quickQuery) on a toolbar, you should include that child's id in the toolbar's partialTriggers attribute so that the toolbar also updates when the input component is replaced. Because this partialTrigger will cause overflow to close during the toolbar ppr, toolbar child components that update themselves via ppr outside of a submit (like InputComboboxLOV) will work better when not in overflow.
<af:toolbar> <af:group> <af:commandToolbarButton id="search" text="Search" icon="/images/search.gif"/> <af:commandToolbarButton text="Folders" icon="/images/folders.gif"/> </af:group> <af:group> <af:commandToolbarButton text="Reports"/> <af:commandToolbarButton id="toggleRefresh" text="Refresh:OFF"/> </af:group> </af:toolbar>
Type | Phases | Description |
---|---|---|
org.apache.myfaces.trinidad.event.AttributeChangeEvent | Invoke Application, Apply Request Values |
Event delivered to describe an attribute change. Attribute change events are not delivered for any programmatic change to a property. They are only delivered when a renderer changes a property without the application's specific request. An example of an attribute change events might include the width of a column that supported client-side resizing. |
Name | Type | Supports EL? | Description |
---|---|---|---|
attributeChangeListener | javax.el.MethodExpression | Only EL | a method reference to an attribute change listener. Attribute change events are not delivered for any programmatic change to a property. They are only delivered when a renderer changes a property without the application's specific request. An example of an attribute change events might include the width of a column that supported client-side resizing. |
binding | oracle.adf.view.rich.component.rich.layout.RichToolbar | Only EL | an EL reference that will store the component instance on a bean. This can be used to give programmatic access to a component from a backing bean, or to move creation of the component to a backing bean. |
clientComponent | boolean | Yes | Default Value: false whether a client-side component will be generated. A component may be generated whether or not this flag is set, but if client Javascript requires the component object, this must be set to true to guarantee the component's presence. Client component objects that are generated today by default may not be present in the future; setting this flag is the only way to guarantee a component's presence, and clients cannot rely on implicit behavior. However, there is a performance cost to setting this flag, so clients should avoid turning on client components unless absolutely necessary. |
customizationId | String | Yes | This attribute is deprecated. The 'id' attribute should be used when applying persistent customizations. This attribute will be removed in the next release. |
flex | int | Yes | Default Value: 0 a non-negative integer that indicates the flexibility of this component in its container. If the container supports it (the toolbox component), flex is used to determine how space is distributed among its children. Components with larger flex values will be made larger than components with lower flex values. This is done so at the ratio determined by the flex of each of the two components. The actual value is only relevant if there are other flexible components (components with flex values larger than zero) within the same container. Components that specify a stretchId should specify a flex value as well. |
id | String | No | the identifier for the component. The identifier must follow a subset of the syntax allowed in HTML:
|
inlineStyle | String | Yes | the CSS styles to use for this component. This is intended for basic style changes. The inlineStyle is a set of CSS styles that are applied to the root DOM element of the component. If the inlineStyle's CSS properties do not affect the DOM element you want affected, then you will have to create a skin and use the skinning keys which are meant to target particular DOM elements, like ::label or ::icon-style. |
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. Identifiers are relative to the source component (this component), and must account for NamingContainers. If your component is already inside of a naming container, you can use a single colon to start the search from the root of the page, or multiple colons to move up through the NamingContainers - "::" will pop out of the component's naming container (or itself if the component is a naming container) and begin the search from there, ":::" will pop out of two naming containers (including itself if the component is a naming container) and begin the search from there, etc. |
rendered | boolean | Yes | Default Value: true whether the component is rendered. When set to false, no output will be delivered for this component (the component will not in any way be rendered, and cannot be made visible on the client). If you want to change a component's rendered attribute from false to true using PPR, set the partialTrigger attribute of its parent component so the parent refreshes and in turn will render this component. |
shortDesc | String | Yes | the short description of the component. This text is commonly used by user agents to display tooltip help text, in which case the behavior for the tooltip is controlled by the user agent, e.g. Firefox 2 truncates long tooltips. For form components, the shortDesc is displayed in a note window. For components that support the helpTopicId attribute it is recommended that helpTopicId is used as it is more flexible and is more accessibility-compliant. |
stretchId | String | Yes | the id of a child component that will be given all of the available space left in the toolbar if the contents of the toolbar do not use all of the space that the toolbar has available. A toolbar that specifies a stretchId should specify a flex value as well. |
styleClass | String | Yes | a CSS style class to use for this component. The style class can be defined in your jspx page or in a skinning CSS file, for example, or you can use one of our public style classes, like 'AFInstructionText'. |
unsecure | java.util.Set | Yes | A whitespace separated list of attributes whose values ordinarily can be set only on the server, but need to be settable on the client. Currently, this is supported only for the "disabled" attribute. |
visible | boolean | Yes | Default Value: true the visibility of the component. If it is "false", the component will be hidden on the client. Unlike "rendered", this does not affect the lifecycle on the server - the component may have its bindings executed, etc. - and the visibility of the component can be toggled on and off on the client, or toggled with PPR. When "rendered" is false, the component will not in any way be rendered, and cannot be made visible on the client. In most cases, use the "rendered" property instead of the "visible" property. Not supported on the following renderkits: org.apache.myfaces.trinidad.core |