Displays HelpSet data with navigators and a content viewer.
navDisplayed
protected boolean navDisplayed
navigators
protected Vector navigators
toolbarDisplayed
protected boolean toolbarDisplayed
addHelpNavigator
public void addHelpNavigator(JHelpNavigator navigator)
A JHelp can have a number of navigators.
One of navigators is active.
How they are presented depends on the UI, but they may be a collection
of tabs, with the active tab being at the front.
Each navigator listens to changes to the HelpModel.
A navigator can also tell the model to change--the change
is propagated to the other navigators, this component, and
the content viewer if they all use the same
HelpModel instance.
navigator
- The Navigator to explicitly add to the JHelp.
getAccessibleContext
public AccessibleContext getAccessibleContext()
Get the AccessibleContext associated with this JComponent.
- The AccessibleContext of this JComponent
getContentViewer
public JHelpContentViewer getContentViewer()
Retrieves what is the current content viewer
Read-Only property?
getCurrentNavigator
public JHelpNavigator getCurrentNavigator()
- The current navigator in the HelpUI
getHelpNavigators
public Enumeration getHelpNavigators()
- An Enumeration of HelpNavigators in the HelpUI.
getHelpSetURL
public URL getHelpSetURL()
getHistoryModel
public HelpHistoryModel getHistoryModel()
Returns The HelpHistoryModel
- The HelpHistoryModel which provides history data
getModel
public TextHelpModel getModel()
- The HelpModel that is providing the data.
getSelectedItems
public TreeItem[] getSelectedItems()
Returns a list of selected items from the current navigator
getUI
public HelpUI getUI()
Returns the HelpUI that is providing the current look and feel.
getUIClassID
public String getUIClassID()
isNavigatorDisplayed
public boolean isNavigatorDisplayed()
Determines if the Navigators are hidden/displayed in the HelpUI.
- Are the navigators displayed?
isToolbarDisplayed
public boolean isToolbarDisplayed()
Determines if the Navigators are hidden/displayed in the HelpUI.
- is the toolbar displayed?
removeHelpNavigator
public void removeHelpNavigator(JHelpNavigator navigator)
Removes a navigator.
navigator
- The Navigator to explicitly add to the JHelp.
setCurrentID
public void setCurrentID(String id)
throws BadIDException
Convenience version of the above. The implicit HelpSet is
the current HelpSet.
id
- The String to visit. Null id is valid for TextHelpModel.setCurrentID.
setCurrentID
public void setCurrentID(Map.ID id)
throws InvalidHelpSetContextException
Visits a given ID. Propagates down into the model.
id
- The ID to visit. Null id is valid for TextHelpModel.setCurrentID.
setCurrentID
public void setCurrentID(Map.ID id,
String historyName,
JHelpNavigator navigator)
throws InvalidHelpSetContextException
Visits a given ID. Propagates down into the model.
id
- The ID to visit. Null id is valid for TextHelpModel.setCurrentID.historyName
- The name for history entrynavigator
- The JHelpNavigator
setCurrentNavigator
public void setCurrentNavigator(JHelpNavigator navigator)
Sets the current navigator in the HelpUI.
navigator
- The navigator
setCurrentURL
public void setCurrentURL(URL url)
Visits a given URL. Propagates down into the model.
setCurrentURL
public void setCurrentURL(URL url,
String historyName,
JHelpNavigator navigator)
Visits a given URL. Propagates down into the model.
setHelpSetPresentation
public void setHelpSetPresentation(HelpSet.Presentation hsPres)
Set the HelpSet.Presentation.
setHelpSetSpec
public void setHelpSetSpec(String spec)
Set the URL to the HelpSet. This forces the HelpSet to be reloaded.
spec
- Where to locate the HelpSet. A null spec is valid
setModel
public void setModel(TextHelpModel newModel)
Sets the HelpModel that provides the data.
newModel
- The new Model. If newModel is null the internal model is set
to null.
setNavigatorDisplayed
public void setNavigatorDisplayed(boolean displayed)
Hidess/Displays the Navigators in the HelpUI.
setToolbarDisplayed
public void setToolbarDisplayed(boolean displayed)
Hidess/Displays the Toolbar in the HelpUI.
setUI
public void setUI(HelpUI ui)
Sets the HelpUI that will provide the current look and feel.
ui
- The HelpUI to set for this component. A null value for ui
is valid.
setupNavigators
protected void setupNavigators()
updateUI
public void updateUI()
Replaces the UI with the latest version from the default
UIFactory.