Sign in Join
Wiki copytemporary

FPDoc Editor: what changed

Revision 1 to 2. Removed lines have a minus sign; added lines have a plus sign.

OldNewLine
11## Introduction
22
33FPDoc is the Free Pascal documentation tool which is specifically designed to create help files for individual units of Pascal source code. For more information about FPDoc see here: [Free Pascal documentation tool manual](http://www.freepascal.org/docs-html/fpdoc/fpdoc.html).
44
5-<figure>
6-<img src="FPDocEditorDescription.png" title="FPDocEditorDescription.png" />
7-<figcaption>FPDocEditorDescription.png</figcaption>
8-</figure>
5+![](/wiki-images/6/6c/FPDocEditorDescription.png)
96
107Lazarus provides inline FPDoc help viewer in hints and two help file editors either of which you can use to create or update source code documentation in FPDoc format. If you want to see it correctly formatted, you have to install Package TurboPowerIProDsgn.lpk! The simpler editor, integrated into the Lazarus IDE is called **FPDoc Editor**, and is described on this page. There is also a more complete and complex editor called [[Lazarus Documentation Editor|LazDE]].
118
129**LazDE** is a bigger brother to **FPDoc Editor** and is the Lazarus Documentation Editor. It is a standalone application (not an integral part of the IDE). It is located at (\$LazDir)/doceditor/lazde.lpi. Once you have compiled the lazde project (using Lazarus) LazDE then runs outside the IDE. You can add it into menu Tools as external tool.
1310
1411## Using the FPDoc Editor
1512
1613To use the FPDoc Editor you simply:
1714
18151. Open the FPDoc Editor. You will find it under the View menu.
19162. In the Lazarus source code editor move the cursor to some code element. You will notice that the FPDoc Editor's Caption changes to show the selected source element together with the filename of the documentation file. Within FPDoc Editor you can select an appropriate page where you can edit a specific documentation tag. Of course it is also possible to use FPDoc Editor only to view documentation files, without changing them.
20173. Click on the Create Help button. If you have not yet set up search paths for FPDoc the IDE will ask you where the FPDoc files it generates should be stored. For each of your projects you would normally provide a 'docs' subdirectory.
21184. Write a short description.
22195. Click on the Save button to the left or go to the next item (the editor automatically saves a description when you move away from it).
2320
2421## Editing FPDoc entries for the LCL sources and Lazarus sources
2522
2623There are in folder (\$LazDir)\docs\xml, You can add this folder to FPDoc paths at Tools / Options / Environment / FPDoc Editor
2724
2825## Editing FPDoc entries for the FPC sources, RTL and FCL
2926
3027The FPDoc entries for the FPC sources can be downloaded from svn:
3128
3229``` bash
3330cd /home/username/yourchoice/
3431svn co http://svn.freepascal.org/svn/fpcdocs/trunk fpcdocs
3532```
3633
3734Add the path */home/username/yourchoice/fpcdocs* to Tools / Options / Environment / FPDoc Editor
3835
3936A good item to test FPDoc on is *TComponent.Name*.
4037
4138## Future plans
4239
4340The todo list currently contains the following items, in no particular order:
4441
4542- Write a help editor for topics.
4643- Create nicer HTML output for the hint windows.
4744- Support Operators
4845- Jump to next/previous undocumented identifier
4946
5047### Already done
5148
5249- Extend the link editor to show packages and identifiers
5350- Add documentation tags "example" to FPDoc Editor
5451- Add documentation tags "topic" to FPDoc Editor
5552- Make FPDoc Editor create new elements in documentation
5653- Make FPDoc Editor create new documentation files
5754- Adding a small toolbar makes it possible to use the available markup tags
5855- Make FPDoc Editor work on keydown in source code editor
5956- Add FPDoc Editor to IDE settings (showing and position in IDE)
6057- Make it work for fpc sources (rtl files already exist)
6158- Add settings to environment menu
6259- Make it work on project files also
6360- Propose to expand documentation tags with: "todo" and "notes" (no need for that, as there are alternatives)
6461- Reduce overhead even further
6562- All source elements are interpreted by FPDoc Editor using codetools
6663- Find inherited entries. For example TControl.Align of TButton.Align
6764- Optimization: inherited Entries are parsed on idle
6865- Optimization: xml files are cached, and only parsed once or if they changed on disk
6966- Add a HTML viewer. This is available by installing the turbopoweriprodsgn package
7067- Checks for invalid xml tags and auto repairs them
7168
7269---
7370*From the Free Pascal wiki, page "FPDoc Editor", as it stood on 2023-01-30 after a change by Kai Burghardt, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).*

Back to history