org.ka2ddo.yaac.gui.help
Class HelpAdapter

java.lang.Object
  extended by org.ka2ddo.yaac.gui.help.HelpAdapter

public class HelpAdapter
extends java.lang.Object

This class provides generalized support for hot-key "help" on functions within YAAC. Help can be invoked (in addition to the normal ways through the Help menu):

  1. by pressing the F1 or HELP keys on your keyboard when the focus is on a component tagged with a JavaHelp tag in the collected help maps (or an ancestor container of the focused component has such a tag).


Field Summary
static java.lang.String HELP_KEY
           
 
Constructor Summary
HelpAdapter()
           
 
Method Summary
static HelpAdapter getInstance()
          Get the singleton HelpAdapter object.
 void registerWindowForHelpKeys(javax.swing.RootPaneContainer window)
          Set up infrastructure for handling Help-related window hot-keys on the specified window.
static void setHelpTag(javax.swing.JComponent c, java.lang.String tag)
          Associate a JavaHelp tag with a GUI component so the F1 hot key will launch the appropriate help text.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HELP_KEY

public static final java.lang.String HELP_KEY
See Also:
Constant Field Values
Constructor Detail

HelpAdapter

public HelpAdapter()
Method Detail

getInstance

public static HelpAdapter getInstance()
Get the singleton HelpAdapter object.

Returns:
HelpAdapter

registerWindowForHelpKeys

public void registerWindowForHelpKeys(javax.swing.RootPaneContainer window)
Set up infrastructure for handling Help-related window hot-keys on the specified window.

Parameters:
window - RootPaneContainer on which to enable hot-key help

setHelpTag

public static void setHelpTag(javax.swing.JComponent c,
                              java.lang.String tag)
Associate a JavaHelp tag with a GUI component so the F1 hot key will launch the appropriate help text.

Parameters:
c - JComponent to tag
tag - String name of help tag to associate