Re: gtk-doc: getting doc from *.c files



Bjorn Andersson wrote:
> 
> I am trying to use gtk-doc in my own project. I don't, however, yet
> understand how to get the function documentation from the *.c files
> into the final docbook document.
> 
> For example, if I have the files test.c and test.h, this is what
> I did to test gtk-doc:
> 
> # this generate mymod-decl.txt mymod-decl-list.txt
> gtkdoc-scan --module=mymod ./test.h
> cp mymod-decl-list.txt mymod-sections.txt
> # this generates ./tmpl/test.sgml
> gtkdoc-mktmpl --module=mymod
> # this generates ./sgml/test.sgml ./sgml/mymod-doc.{top,bottom}
> gtkdoc-mkdb --module=mymod
> 
> At what stage does my commented test.c file come into play, so
> that I get the documentation into the docbook file? What am I
> missing?

gtkdoc-mkdb scans the source files (optionally), adding the
documentation to the DocBook output. You pass it a --source-dir
argument to tell it the toplevel source directory, e.g.

  gtkdoc-mkdb --module=mymod --source-dir=.


Hope that helps.

Damon




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]