v11 suggestion: plugin online help interface

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Charles Dye

Super Moderator
Staff member
May 20, 2008
Albuquerque, NM
It would be nice if the online help features could be made plugin-aware. I propose something along these lines:

When help is requested via the HELP command or the F1 or Ctrl-F1 keys, TCC checks whether the specified word is a command, variable, or function provided by a plugin; and if so, whether that plugin exports a function named F1_help(). If the word is not provided by a plugin, or if that plugin does not offer an F1_help() function, then the help system is launched as usual. But if the plugin does provide F1_help(), TCC calls that instead and passes it a string containing the command/variable/function name, lowercased and with @ or _ prefixed as appropriate. The plugin is responsible for deciphering the name and launching a .CHM / .PDF / .TXT / .HTML, popping up a message box, or whatever else the author chooses.

It might also be useful to pass a second parameter to differentiate the HELP command from the F1 and Ctrl-F1 keystrokes. In the case of HELP, it might be appropriate to just dump text to stdout; for F1 and Ctrl-F1 probably not.