/** * Custom src for the close icon for this tab to display if it is closeable. See {@link * com.smartgwt.client.widgets.tab.Tab#getCanClose canClose} and {@link * com.smartgwt.client.widgets.tab.TabSet#getCanCloseTabs canCloseTabs}. * * @param closeIcon closeIcon Default value is null */ public void setCloseIcon(String closeIcon) { setAttribute("closeIcon", closeIcon); }
/** * If {@link com.smartgwt.client.widgets.tab.TabSet#getShowTabPicker showTabPicker} is true for this TabSet, if set this * property will determine the title of the picker menu item for this tab. If unset, {@link * com.smartgwt.client.widgets.tab.Tab#getTitle title} will be used instead * * @param pickerTitle pickerTitle Default value is null * @see com.smartgwt.client.widgets.tab.TabSet#setShowTabPicker * @see com.smartgwt.client.widgets.tab.Tab#setTitle */ public void setPickerTitle(String pickerTitle) { setAttribute("pickerTitle", pickerTitle); }
/** * If specified, overrides the {@link com.smartgwt.client.widgets.tab.TabSet#getCanEditTabTitles canEditTabTitles} setting, * for this one tab only. * * @param canEditTitle canEditTitle Default value is null * @see com.smartgwt.client.widgets.tab.TabSet#setCanEditTabTitles */ public void setCanEditTitle(Boolean canEditTitle) { setAttribute("canEditTitle", canEditTitle); }
/** * If {@link com.smartgwt.client.widgets.tab.Tab#getIcon icon} is specified, this property may be used to specify a size * for the icon. Per side sizing may be specified instead via {@link com.smartgwt.client.widgets.tab.Tab#getIconWidth * iconWidth} and {@link com.smartgwt.client.widgets.tab.Tab#getIconHeight iconHeight}. * * @param iconSize iconSize Default value is null */ public void setIconSize(Integer iconSize) { setAttribute("iconSize", iconSize); }
/** * Specifies the prompt to be displayed when the mouse hovers over the tab. * * @param prompt prompt Default value is null */ public void setPrompt(String prompt) { setAttribute("prompt", prompt); }
public void setCanClose(boolean canClose) { setAttribute("canClose", canClose); }
/** * Size of the {@link com.smartgwt.client.widgets.tab.Tab#getCloseIcon closeIcon} for this tab. If unspecified the icon * will be sized according to {@link com.smartgwt.client.widgets.tab.TabSet#getCloseTabIconSize closeTabIconSize} * * @param closeIconSize closeIconSize Default value is null */ public void setCloseIconSize(Integer closeIconSize) { setAttribute("closeIconSize", closeIconSize); }
/** * If {@link com.smartgwt.client.widgets.tab.Tab#getIcon icon} is specified, this property may be used to specify a size * for the icon * * @param iconHeight iconHeight Default value is null */ public void setIconHeight(Integer iconHeight) { setAttribute("iconHeight", iconHeight); }
/** * If {@link com.smartgwt.client.widgets.tab.Tab#getIcon icon} is specified, this property may be used to specify a size * for the icon * * @param iconWidth iconWidth Default value is null */ public void setIconWidth(Integer iconWidth) { setAttribute("iconWidth", iconWidth); }
/** * You can specify an explicit width for the tab using this property. Note that tabs automatically size to make room for * the full title, but if you want to e.g. specify a uniform width for all tabs in a TabSet, this property enables you to * do so. * * @param width width Default value is 100 */ public void setWidth(int width) { setAttribute("width", width); }
/** * Determines whether this tab should show an icon allowing the user to dismiss the tab by clicking on it directly. The URL * for this icon's image will be derived from {@link com.smartgwt.client.widgets.tab.TabSet#getCloseTabIcon closeTabIcon} * by default, but may be overridden by explicitly specifying {@link com.smartgwt.client.widgets.tab.Tab#getCloseIcon * closeIcon}. <P> If unset, this property is derived from {@link com.smartgwt.client.widgets.tab.TabSet#getCanCloseTabs * canCloseTabs} * * @param canClose canClose Default value is null * @see com.smartgwt.client.widgets.tab.TabSet#closeClick * @see <a href="http://www.smartclient.com/smartgwt/showcase/#layout_tabs_closeable" target="examples">Closeable Tabs Example</a> */ public void setCanClose(Boolean canClose) { setAttribute("canClose", canClose); }
/** * Optional ID for the tab, which can later be used to reference the tab. APIs requiring a reference to a tab will accept * the tabs ID [including {@link com.smartgwt.client.widgets.tab.TabSet#selectTab TabSet.selectTab}, {@link * com.smartgwt.client.widgets.tab.TabSet#updateTab TabSet.updateTab}, {@link * com.smartgwt.client.widgets.tab.TabSet#removeTab TabSet.removeTab}].<br> The ID will also be passed to the {@link * com.smartgwt.client.widgets.tab.TabSet#addTabSelectedHandler TabSet.tabSelected} and {@link * com.smartgwt.client.widgets.tab.TabSet#addTabDeselectedHandler TabSet.tabDeselected} handler functions, if specified. * <p> Note that if you provide an ID, it must be globally unique. * * @param ID ID Default value is null */ public void setID(String ID) { setAttribute("ID", ID); }
public void setPaneID(String paneID) { setAttribute("pane", paneID); }
/** * Context menu to show for this tab. * * @param contextMenu contextMenu Default value is null */ public void setContextMenu(Menu contextMenu) { setAttribute("contextMenu", contextMenu.getOrCreateJsObj()); }
/** * Specifies the pane associated with this tab. You can change the pane associated with a given tab after the TabSet * has been created by calling {@link com.smartgwt.client.widgets.tab.TabSet#updateTab(int, com.smartgwt.client.widgets.Canvas)} * * @param pane the tab pane */ public void setPane(Canvas pane) { setAttribute("pane", pane.getOrCreateJsObj()); }
/** * Specifies the title of the this tab. To change the title after the TabSet has been created, call {@link * com.smartgwt.client.widgets.tab.TabSet#setTabTitle TabSet.setTabTitle}. * * @param title title Default value is null */ public void setTitle(String title) { if(tabSet == null || !tabSet.isDrawn()) { setAttribute("title", title); } else { tabSet.setTabTitle(this, title); } }
/** * If specified, this tab will show an icon next to the tab title. Note that as with {@link * com.smartgwt.client.widgets.Button#getIcon icon}, the URL of a tabs icon will be updated to reflect disabled state.<br> * If desired a click handler may be assigned to the icon, which will be fired when the user clicks the tab. This method * takes a single parameter <code>tab</code>, a pointer to the tab object. * * @param icon icon Default value is null * @see <a href="http://www.smartclient.com/smartgwt/showcase/#layout_tabs_orientation" target="examples">Orientation Example</a> */ public void setIcon(String icon) { if(tabSet == null || !tabSet.isDrawn()) { setAttribute("icon", icon); } else { tabSet.setTabIcon(getID(), icon); } }
/** * If specified, this tab will initially be rendered in a disabled state. * * @param disabled disabled Default value is null */ public void setDisabled(boolean disabled) { if(tabSet == null || !tabSet.isDrawn()) { setAttribute("disabled", disabled); } else { if(disabled) { tabSet.disableTab(getID()); } else { tabSet.enableTab(getID()); } } }