[Lazarus] Extending FCL documentation

Mattias Gaertner nc-gaertnma at netcologne.de
Wed Feb 8 17:27:58 CET 2012


On Wed, 08 Feb 2012 17:03:22 +0100
Michael Schnell <mschnell at lumino.de> wrote:

> On 02/08/2012 04:59 PM, Sven Barth wrote:
> >
> > DocView is not part of Lazarus source code. Also it would first need 
> > to be converted to LCL (though according to Graeme this should be 
> > rather easy).

He does not need much LCL. He just needs to write an
IDE package that starts and communicates with DocView.
The chmhelppkg starts lhelp as external tool and communicates via
SimpleIPC.


> I understand that Graeme would be able (and willing) do make a DocView 
> Packet. Another way would be using (an advanced version of) the 
> "external Tool" interface. This already does work nice for DocView.

The external tool is not very context sensitive. For example you
can not get help for a dialog.
And it's rather crude for pascal sources. An external tool can use
macros to get current source editor filename, line and column.
On the other hand the IDE's help interface for pascal sources uses
the codetools to find the declaration and passes a complete path to the
help. For example the external tool only gets "LoadFromFile", while a
registered help gets fpc sources, rtl/objpas/classes.pp,
class TStrings, method LoadFromFile. 
There is a base class for fpdoc help formats in ideintf helpfpdoc.pas,
demonstrating how to convert this information to the fpdoc element
path. The only thing you have to do is to find the corresponding
element in DocView.


Mattias




More information about the Lazarus mailing list