[fpc-pascal] fpdoc and linked elements
Graeme Geldenhuys
graeme at geldenhuys.co.uk
Tue Dec 4 16:33:01 CET 2012
Hi Michael (or anybody else that could help),
I'm using fpdoc from FPC 2.7.1 (pulled yesterday from the repository).
I have a xml description file with the following elements.
----------[ fpg_button.xml ]-----------------
<element name="TfpgButton.ImageName" link="TfpgBaseButton.ImageName"/>
<element name="TfpgButton.ImageSpacing"
link="fpg_button.TfpgBaseButton.ImageSpacing"/>
---------------[ end ]---------------
What is the correct format for the link attribute?
The first one (for ImageName property) which doesn't list the unit name
in the link attribute, is never found by fpdoc. So the generated
documentation ends up being blank. The second one where I explicitly
mention the unit name, fpdoc does find the linked element, and correct
documentation is generated.
So I gather I am always supposed to use the syntax:
<unitname>.<class>.<property>
What is strange, and I still can't find the issue in fpdoc, is that
sometimes both syntax works. eg: yesterday I generated documentation and
all linked docs worked. Today it doesn't.
I've also stepped through the TFPDocEngine.FindDocNode() implementation,
and when it gets to the iteration of the "uses lists", it only
iterations 3 units, but fpg_button.pas there are 6 units listed in the
interface section's uses clause.
Also in the FindLinkedNode(), where it calls
FindDocNode(CurModule,ANode.Link);
for ANode = TfpgButton.ImageName, the CurModule is pointing to the unit
fpg_colorwheel.pas??? No wonder it never finds the
TfpgBaseButton.ImageName element. Something seems seriously wrong in
fpdoc somewhere.
Regards,
- Graeme -
More information about the fpc-pascal
mailing list