Difference between revisions of "Creating IDE Help"

From Free Pascal wiki
Jump to navigationJump to search
Line 1: Line 1:
 
== Help for LCL units ==
 
== Help for LCL units ==
  
This is done via the [[LazDoc]] tool.
+
Whenever the user presses F1 for an Object Inspetcor property or on an identifier in the source editor the IDE searches the declaration and invokes the HTML viewer for the fpdoc item.
 +
The items can be edited easily via the [[LazDoc]] tool.
  
 
== Help for IDE windows ==
 
== Help for IDE windows ==

Revision as of 01:09, 30 April 2006

Help for LCL units

Whenever the user presses F1 for an Object Inspetcor property or on an identifier in the source editor the IDE searches the declaration and invokes the HTML viewer for the fpdoc item. The items can be edited easily via the LazDoc tool.

Help for IDE windows

The help for the IDE windows (i.e. 'Object Inspector' or the 'Compiler Options') are documented in this wiki. The IDE has a mapping file docs/IDEWindowHelpTree.xml, which contains the paths from the various IDE forms/controls to wiki pages. This mapping file editor is shown at any place in the IDE via Ctrl+Shift+F1. You can set the short cut in the editor options -> key mapping.

The root page of the IDE window docs is Lazarus IDE.

Help for FPC keywords

This is invoked when the cursor in the source editor is above a keyword and the user pressed F1. The IDE searches in the FPC html documentation for the ref.kwd file. This file is maintained by the FPC team and contains a list to all HTML pages. At the moment no custom help is implemented.

Help for Messages

This is invoked when the user presses F1 or uses the Help menu item of the message window.

To add a wiki help page for a message, do the following:

  • Create a wiki page under the root Build messages
  • Open ide/helpfpcmessages.pas and add a AddFPCMessageHelpItem line like:
  AddFPCMessageHelpItem('Can''t find unit',
                        'FPC_message:_Can_not_find_unit',': Can''t find unit ');

The first parameter is the title shown in errors. The second parameter is the wiki URL. And the third parameter is the regular expression to match the message.