new JAccordion()
public function updateUI():Void
Description copied from Component
Resets the UI property to a value from the current look and feel.
Component
subclasses must override this method
like this:
public void updateUI() { setUI((SliderUI)UIManager.getUI(this); }
public function setUI(newUI:AccordionUI):Void
Description copied from Component
Sets the look and feel delegate for this component.
Component
subclasses generally override this method
to narrow the argument type. For example, in JSlider
:
public void setUI(SliderUI newUI) { super.setUI(newUI); }
Additionally Component
subclasses must provide a
getUI
method that returns the correct type. For example:
public SliderUI getUI() { return (SliderUI)ui; }
public function getUIClassID():String
Description copied from Component
Returns the UIDefaults
key used to
look up the name of the org.aswing.plaf.ComponentUI
class that defines the look and feel
for this component. Most applications will never need to
call this method. Subclasses of Component
that support
pluggable look and feel should override this method to
return a UIDefaults
key that maps to the
ComponentUI
subclass that defines their look and feel.
public function setLayout(layout:LayoutManager):Void
Generally you should not set layout to JAccordion.
layout | layoutManager for JAccordion |
Error | when you set a non-AccordionUI layout to JAccordion. |
public function append(com:Component, constraints:Object):Void
Adds a component to the accordion.
If constraints is a String or an Icon or an Object(object.toString() as a title),
it will be used for the tab title,
otherwise the component's name will be used as the tab title.
Shortcut of insert(-1, com, constraints)
.
com | the component to be displayed when this tab is clicked |
constraints | the object to be displayed in the tab |
append() in org.aswing.Container
public function insert(i:Number, com:Component, constraints:Object):Void
Adds a component to the accordion with spesified index. If constraints is a String or an Icon or an Object(object.toString() as a title), it will be used for the tab title, otherwise the component's name will be used as the tab title. Cover method for insertTab.
i | index the position at which to insert the component, or less than 0 value to append the component to the end |
com | the component to be added |
constraints | the object to be displayed in the tab |
insert() in org.aswing.Container
public function appendTab(com:Component, title:String, icon:Icon, tip:String):Void
Adds a component and tip represented by a title and/or icon, either of which can be null.
Shortcut of insertTab(-1, com, title, icon, tip)
com | The component to be displayed when this tab is clicked |
title | the title to be displayed in this tab |
icon | the icon to be displayed in this tab |
tip | the tooltip to be displayed for this tab, can be null means no tool tip. |
public function insertTab(i:Number, com:Component, title:String, icon:Icon, tip:String):Void
Inserts a component, at index, represented by a title and/or icon, either of which may be null.
i | the index position to insert this new tab |
com | The component to be displayed when this tab is clicked |
title | the title to be displayed in this tab |
icon | the icon to be displayed in this tab |
tip | the tooltip to be displayed for this tab, can be null means no tool tip. |
Error | when index > children count |
public function removeTabAt(i):Component
Removes the specified child component. After the component is removed, its visibility is reset to true to ensure it will be visible if added to other containers.
i | the index of component, less than 0 mean the component in the end of children list. |
the component just removed, or null there is not component at this position.
public function remove(com:Component):Component
Removes the specified child component. After the component is removed, its visibility is reset to true to ensure it will be visible if added to other containers. Cover method for removeTabAt.
remove() in org.aswing.Container
public function removeAt(index:Number):Component
Removes the specified index child component. After the component associated with index is removed, its visibility is reset to true to ensure it will be visible if added to other containers. Cover method for removeTabAt.
removeAt() in org.aswing.Container
public function removeAll():Void
Remove all child components. After the component is removed, its visibility is reset to true to ensure it will be visible if added to other containers.
removeAll() in org.aswing.Container
public function getTitleAt(i:Number):String
Returns the tab title at specified index.
i | the index |
the tab title
public function getIconAt(i:Number):Icon
Returns the tab icon at specified index.
i | the index |
the tab icon
public function getTipAt(i:Number):String
Returns the tab tool tip text at specified index.
i | the index |
the tab tool tip text
public function indexOfTitle(title:String):Number
Returns the first tab index with a given title, or -1 if no tab has this title.
title | the title for the tab |
the first tab index which matches title, or -1 if no tab has this title
public function indexOfIcon(icon:Icon):Number
Returns the first tab index with a given icon, or -1 if no tab has this icon.
the first tab index which matches icon, or -1 if no tab has this icon