Package uk.ac.starlink.topcat
Class BrowserHelpAction
java.lang.Object
javax.swing.AbstractAction
uk.ac.starlink.topcat.BrowserHelpAction
- All Implemented Interfaces:
ActionListener
,Serializable
,Cloneable
,EventListener
,Action
Action which invokes help by attempting to display a page from the
help document in a web browser.
- Since:
- 19 Sep 2008
- Author:
- Mark Taylor
- See Also:
-
Field Summary
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
-
Method Summary
Modifier and TypeMethodDescriptionvoid
static Action
createIdAction
(String helpId, Component parent) Returns a new action displaying help for a given help ID.static Action
createManual1Action
(Component parent) Returns a new action displaying help for the whole application as a single-page HTML documentstatic Action
createManualAction
(Component parent) Returns a new action displaying help for the whole application as a multi-page HTML documentstatic URI
getHelpUri
(String relUrl) Returns an internal URI corresponding to a relative URL (rooted at uk/ac/starlink/topcat/ in the classpath).static URL
getHelpUrl
(String relUrl) Returns an internal URL corresponding to a relative URL (rooted at uk/ac/starlink/topcat/ in the classpath).Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
-
Method Details
-
actionPerformed
-
createIdAction
Returns a new action displaying help for a given help ID.- Parameters:
helpId
- help IDparent
- parent window - may be used for positioning- Returns:
- help action
-
createManualAction
Returns a new action displaying help for the whole application as a multi-page HTML document- Parameters:
parent
- parent window - may be used for positioning- Returns:
- help action
-
createManual1Action
Returns a new action displaying help for the whole application as a single-page HTML document- Parameters:
parent
- parent window - may be used for positioning- Returns:
- help action
-
getHelpUrl
Returns an internal URL corresponding to a relative URL (rooted at uk/ac/starlink/topcat/ in the classpath).- Parameters:
relUrl
- relative path- Returns:
- URL, or null in case of problem
-
getHelpUri
Returns an internal URI corresponding to a relative URL (rooted at uk/ac/starlink/topcat/ in the classpath).- Parameters:
relUrl
- relative path- Returns:
- URI, or null in case of problem
-