From: Artur Frysiak Date: Mon, 30 Sep 2002 16:12:04 +0000 (+0000) Subject: generate XML output (needed by GNOME 2.1) X-Git-Tag: DEVEL X-Git-Url: http://git.pld-linux.org/?a=commitdiff_plain;h=527bd58d3d60be53d72253a68f6e9bca359b876c;p=packages%2Fgtk-doc.git generate XML output (needed by GNOME 2.1) Changed files: gtk-doc-xml.patch -> 1.1 --- diff --git a/gtk-doc-xml.patch b/gtk-doc-xml.patch new file mode 100644 index 0000000..05c2b30 --- /dev/null +++ b/gtk-doc-xml.patch @@ -0,0 +1,3426 @@ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/ChangeLog gtk-doc/ChangeLog +--- gtk-doc-0.9/ChangeLog Fri Feb 1 23:23:35 2002 ++++ gtk-doc/ChangeLog Tue Sep 17 07:10:54 2002 +@@ -1,3 +1,184 @@ ++Tue Sep 17 01:07:51 2002 Jonathan Blandford ++ ++ * gtk-doc.xsl: output the chunks in UTF-8 so other tools can use ++ them. ++ ++2002-09-03 James Henstridge ++ ++ * gtk-doc.xsl: turn on rendering of variablelists as tables, and ++ set CSS rules to style .variablelist instead of .informaltable. ++ ++ * gtk-doc.dsl.in (variablelist): override the variablelist handler ++ instead of the tgroups. ++ ++ * gtkdoc-mkdb.in (OutputStruct): use a for listing ++ the field descriptions. ++ (OutputEnum): same here. ++ (OutputParamDescriptions): and here. ++ ++2002-08-12 James Henstridge ++ ++ * gtk-doc.xsl: include devhelp.xsl, and call generate.devhelp when ++ processing the docbook/xml input. ++ ++ * devhelp.xsl: new file, implements .devhelp file output. ++ ++2002-08-18 Havoc Pennington ++ ++ * autogen.sh: hardcode aclocal-1.4/automake-1.4 so that users with ++ both automake 1.6 and 1.4 installed get the right automake. Means ++ compilation from CVS will now require the latest automake 1.4 ++ release, or manually creating symlinks called "automake-1.4" and ++ "aclocal-1.4" ++ ++2002-08-08 James Henstridge ++ ++ * gtk-doc.xsl: add a gtkdoc.bookname param, and include it in the ++ index.sgml output (if not empty). ++ ++ * gtkdoc-mkhtml.in: only perform the sed operation if we are using ++ Jade, and pass the module name as a parameter when using xsltproc. ++ ++2002-08-04 Matthias Clasen ++ ++ * gtkdoc-scangobj.in: Don't try to list signals on types which ++ don't support signals, e.g. boxed types. ++ ++2002-06-14 jacob berkman ++ ++ * gtkdoc-mkdb.in: do the version check before help, so --version ++ doesn't output --help (should fix recent build bustage) ++ ++2002-06-12 Matthias Clasen ++ ++ * gtkdoc-mkdb.in: Make header-grabbing work without an explicit ++ --main-sgml-file argument. ++ ++ * gtkdoc-mkdb.in: Emit the object hierarchy as a rather ++ than a , since the Docbook XSL stylesheets don't ++ handle s inside . ++ ++ * gtkdoc-mkdb.in: Decide wether to generate standalone documents ++ for XIncluding or entities based on the presence of the XInclude ++ namespace declaration on the document element. ++ ++2002-06-09 James Henstridge ++ ++ * gtkdoc-mkdb.in: try to grab the header off the top of the main ++ sgml file. ++ ++2002-05-31 James Henstridge ++ ++ * gtkdoc-mkdb.in (OutputSGML): put XIncludes in the $book_bottom ++ variable. ++ (OutputBook): add the XInclude namespace declaration to the book ++ element. ++ ++ * gtkdoc-mkhtml.in (declaration): if the document looks like XML, ++ process it with xsltproc. ++ ++ * configure.in: check for xsltproc. ++ ++ * gtk-doc.xsl: start of XSLT template for converting docbook/xml ++ to HTML. ++ ++2002-06-03 Matthias Clasen ++ ++ * gtkdoc-mkdb.in (ConvertSGMLChars): Don't use Posix character ++ classes. Perl < 5.6 doesn't have them; and the API doc autobuilder ++ on widget.gnome.org has an old Perl. ++ ++2002-05-29 Matthias Clasen ++ ++ Fixes for #77193: ++ ++ * gtkdoc-mkdb.in (OutputSGML): Call GetSignals, GetArgs and ++ GetHierarchy for each symbol here and accumulate. ++ (OutputSGMLFile): Get signal, argument and hierarchy information ++ from the caller. ++ (GetSignals, GetArgs, GetHierarchy): Don't wrap the return value ++ in a refsect1, so that the results of multiple calls can be accumulated. ++ ++2002-05-28 Matthias Clasen ++ ++ * gtkdoc-mkdb.in (ConvertSGMLChars): Make this work correctly ++ for empty elements and XML comments in doc comments. ++ ++2002-05-27 Matthias Clasen ++ ++ * gtkdoc-mkdb.in (ReadTemplateFile, OutputSGMLFile): ++ Use only the basename of the template file in the key for the ++ symbol table, in order to decouple the file extensions of the ++ template files and the generated entities (we want to generate ++ .xml entities from .sgml template files when emitting XML). ++ ++2002-05-25 Matthias Clasen ++ ++ * gtkdoc-mkdb.in (ConvertSGMLChars): New function which tries to ++ be a bit more clever when escaping SGML syntax characters. ++ (ScanSourceFile): Use ConvertSGMLChars instead of CreateValidSGML. ++ This reduces the work needed to make gtk-doc emit XML (where <, & ++ and friends must always be escaped). ++ ++2002-05-18 Matthias Clasen ++ ++ * gtkdoc-mkhtml.in: Detect whether we're processing SGML or XML. ++ ++ * gtkdoc-mkdb.in: New option --output-format to switch between ++ SGML and XML output. ++ ++ * Makefile.am (EXTRA_DIST): Add xml.dcl ++ ++ * xml.dcl: The XML declaration. ++ ++2002-05-06 jacob berkman ++ ++ * gtkdoc-scangobj.in: add an include for the GTK_CHECK_VERSION ++ macro ++ ++2002-05-05 Matthias Clasen ++ ++ * gtkdoc-scangobj.in: Output style properties. (#80659) ++ ++ * gtkdoc-mkdb.in (GetArgs): Return separate sections for ++ properties, child properties and style properties. (#80659) ++ ++2002-05-03 Matthias Clasen ++ ++ * gtkdoc-scangobj.in: Fix for segfault in scangobj-generated C ++ program on Solaris. (#80606, Jacob Berkman) ++ ++2002-05-01 Matthias Clasen ++ ++ * tools/docpercentages.pl: Add the script which Owen uses for the ++ d.g.o online API docs. Its easier to keep in sync here. ++ ++ * gtkdoc-mkdb.in (OutputMissingDocumentation): Fix ++ $MODULE-undocumented.txt for d.g.o online API docs. ++ ++ * gtkdoc-mkdb.in (GetArgs): Use blurbs for property documentation. ++ ++ * gtkdoc-scangobj.in: Output child properties. Output nicks and ++ blurbs for properties. ++ ++2002-04-28 Matthias Clasen ++ ++ * gtkdoc-mkdb.in (ScanSourceFile): Don't scan for return value ++ descriptions unnecessarily. (#65997) ++ ++2002-03-11 Matthias Clasen ++ ++ * gtkdoc-scangobj.in, gtkdoc-mkdb.in: Create docs for signals on interfaces. ++ ++2002-02-01 Damon Chaplin ++ ++ * configure.in: check for openjade or jade. Patch from Stefan Kost ++ . ++ ++ * gtkdoc-mkhtml.in: use @JADE@ so the correct version of jade is used. ++ ++ * autogen.sh: commented out autoheader since we don't have a config.h. ++ + 2002-01-18 Damon Chaplin + + * Released 0.9. +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/MAINTAINERS gtk-doc/MAINTAINERS +--- gtk-doc-0.9/MAINTAINERS Thu Jan 1 01:00:00 1970 ++++ gtk-doc/MAINTAINERS Sun May 20 02:25:42 2001 +@@ -0,0 +1,2 @@ ++Email: damon@ximian.com ++Email: otaylor@redhat.com +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/Makefile.am gtk-doc/Makefile.am +--- gtk-doc-0.9/Makefile.am Fri Feb 1 23:14:42 2002 ++++ gtk-doc/Makefile.am Wed Aug 28 10:13:28 2002 +@@ -14,11 +14,17 @@ + gtkdocdata_DATA = \ + gtkdoc-common.pl \ + gtk-doc.dsl \ +- gtk-doc.dcl ++ gtk-doc.dcl \ ++ gtk-doc.xsl \ ++ devhelp.xsl \ ++ xml.dcl + + EXTRA_DIST= \ + gtk-doc.spec.in \ +- gtk-doc.dcl ++ gtk-doc.dcl \ ++ gtk-doc.xsl \ ++ devhelp.xsl \ ++ xml.dcl + + dist-hook: + mkdir $(distdir)/doc +@@ -34,3 +40,4 @@ + cp -pr $(srcdir)/tools/* $(distdir)/tools + rm -rf $(distdir)/tools/CVS + cp gtk-doc.spec $(distdir) ++ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/acconfig.h gtk-doc/acconfig.h +--- gtk-doc-0.9/acconfig.h Thu Jan 1 01:00:00 1970 ++++ gtk-doc/acconfig.h Tue Nov 24 07:00:34 1998 +@@ -0,0 +1,25 @@ ++/* acconfig.h ++ This file is in the public domain. ++ ++ Descriptive text for the C preprocessor macros that ++ the distributed Autoconf macros can define. ++ No software package will use all of them; autoheader copies the ones ++ your configure.in uses into your configuration header file templates. ++ ++ The entries are in sort -df order: alphabetical, case insensitive, ++ ignoring punctuation (such as underscores). Although this order ++ can split up related entries, it makes it easier to check whether ++ a given entry is in the file. ++ ++ Leave the following blank line there!! Autoheader needs it. */ ++ ++ ++/* Other stuff */ ++/* #undef PACKAGE */ ++/* #undef VERSION */ ++ ++ ++/* Leave that blank line there!! Autoheader needs it. ++ If you're adding to this file, keep in mind: ++ The entries are in sort -df order: alphabetical, case insensitive, ++ ignoring punctuation (such as underscores). */ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/configure.in gtk-doc/configure.in +--- gtk-doc-0.9/configure.in Thu Jan 24 00:41:38 2002 ++++ gtk-doc/configure.in Thu Jun 13 19:22:25 2002 +@@ -7,14 +7,37 @@ + AC_ISC_POSIX + AC_PROG_CC + +- ++dnl ++dnl Check for Perl. ++dnl + AC_PATH_PROG(PERL, perl) + if test -z "$PERL"; then + AC_MSG_ERROR([perl not found]) + fi + + ++dnl ++dnl Check for jade or openjade. ++dnl ++AC_PATH_PROG(JADE, openjade) ++if test -z "$JADE"; then ++ AC_PATH_PROG(JADE, jade) ++ if test -z "$JADE"; then ++ AC_MSG_ERROR([openjade/jade not found]) ++ fi ++fi ++ ++dnl ++dnl Check for xsltproc ++dnl ++AC_PATH_PROG(XSLTPROC, xsltproc) ++if test -z "$XSLTPROC"; then ++ AC_MSG_ERROR([xsltproc not found]) ++fi ++ ++dnl + dnl Set PACKAGE_DATA_DIR so we can find the script containing common routines. ++dnl + if test "x${datadir}" = 'x${prefix}/share'; then + if test "x${prefix}" = "xNONE"; then + PACKAGE_DATA_DIR="${ac_default_prefix}/share/${PACKAGE}" +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/devhelp.xsl gtk-doc/devhelp.xsl +--- gtk-doc-0.9/devhelp.xsl Thu Jan 1 01:00:00 1970 ++++ gtk-doc/devhelp.xsl Wed Aug 28 10:13:28 2002 +@@ -0,0 +1,131 @@ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ book ++ ++ ++ .devhelp ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ , ++ ++ ++ ++ ++ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtk-doc.cat gtk-doc/gtk-doc.cat +--- gtk-doc-0.9/gtk-doc.cat Thu Jan 1 01:00:00 1970 ++++ gtk-doc/gtk-doc.cat Tue Nov 24 07:00:34 1998 +@@ -0,0 +1,4 @@ ++ -- ...................................................................... -- ++ -- Modified GTK+ DocBook driver file .................................................. -- ++ ++PUBLIC "-//Gnome//DTD DocBook V3.0 extension//EN" "gtk-doc.dtd" +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtk-doc.dcl gtk-doc/gtk-doc.dcl +--- gtk-doc-0.9/gtk-doc.dcl Wed Nov 21 22:05:17 2001 ++++ gtk-doc/gtk-doc.dcl Thu Jun 13 19:22:25 2002 +@@ -1,8 +1,7 @@ + +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtk-doc.dsl.in gtk-doc/gtk-doc.dsl.in +--- gtk-doc-0.9/gtk-doc.dsl.in Mon Feb 5 22:50:56 2001 ++++ gtk-doc/gtk-doc.dsl.in Mon Sep 9 03:46:56 2002 +@@ -76,19 +76,14 @@ + (list "WIDTH" ($table-width$)) + (list "CELLPADDING" "6")))) + +-;; This overrides the tgroup definition (copied from 1.20, dbtable.dsl). +-;; It changes the table background color, cell spacing and cell padding. +-(element tgroup +- (let* ((wrapper (parent (current-node))) +- (frameattr (attribute-string (normalize "frame") wrapper)) +- (pgwide (attribute-string (normalize "pgwide") wrapper)) +- (footnotes (select-elements (descendants (current-node)) +- (normalize "footnote"))) +- (border (if (equal? frameattr (normalize "none")) +- '(("BORDER" "0")) +- '(("BORDER" "1")))) +- (roleattr (attribute-string (normalize "role") wrapper)) + ++;; This overrides the variablelist definition (copied from 1.76, ++;; dblists.dsl). It changes the table background color, cell spacing ++;; and cell padding. ++;; ++;; I have also removed the code to handle the non-table case. ++(element variablelist ++ (let* ((roleattr (attribute-string (normalize "role") (current-node))) + ;; FIXME: I thought that I should use normalize ("params") etc. here, + ;; but that doesn't work. Anyone know why? + (bgcolor (cond ((equal? roleattr "params") +@@ -98,28 +93,77 @@ + ((equal? roleattr "enum") + '(("BGCOLOR" "#F0F0D0"))) + (else +- '(("BGCOLOR" "#FFFFFF"))))) ++ '())))) ++ ++ (make sequence ++ (if %spacing-paras% ++ (make element gi: "P" (empty-sosofo)) ++ (empty-sosofo)) ++ (para-check) ++ ++ (make element gi: "TABLE" ++ attributes: (append ++ '(("CLASS" "VARIABLELIST") ++ ("BORDER" "0") ++ ("CELLSPACING" "0") ++ ("CELLPADDING" "4") ++ ("WIDTH" "100%")) ++ bgcolor) ++ (if %html40% ++ (make element gi: "TBODY" ++ (with-mode variablelist-table ++ (process-children))) ++ (with-mode variablelist-table ++ (process-children)))) ++ (para-check 'restart)))) ++ ++(mode variablelist-table ++ (element (variablelist title) ++ (make element gi: "TR" ++ attributes: '(("CLASS" "TITLE")) ++ (make element gi: "TH" ++ attributes: '(("ALIGN" "LEFT") ++ ("VALIGN" "TOP") ++ ("COLSPAN" "2")) ++ (process-children)))) ++ ++ (element varlistentry ++ (let* ((terms (select-elements (children (current-node)) ++ (normalize "term"))) ++ (listitem (select-elements (children (current-node)) ++ (normalize "listitem")))) ++ ++ (make element gi: "TR" ++ (make element gi: "TD" ++ attributes: '(("ALIGN" "RIGHT") ++ ("VALIGN" "TOP") ++ ("WIDTH" "20%")) ++ (make empty-element gi: "A" ++ attributes: (list ++ (list "NAME" (element-id)))) ++ (process-node-list terms)) ++ (make element gi: "TD" ++ attributes: '(("ALIGN" "LEFT") ++ ("VALIGN" "TOP") ++ ("WIDTH" "80%")) ++ (process-node-list listitem))))) ++ ++ (element (varlistentry term) ++ (make sequence ++ (if %css-decoration% ++ (make element gi: "SPAN" ++ attributes: '(("STYLE" "white-space: nowrap")) ++ (process-children-trim)) ++ (make element gi: "NOBR" ++ (process-children-trim))) ++ (if (not (last-sibling?)) ++ (literal ", ") ++ (literal "")))) ++ ++ (element (varlistentry listitem) ++ (process-children)) ++) + +- (width (if (equal? pgwide "1") +- (list (list "WIDTH" ($table-width$))) +- '())) +- (head (select-elements (children (current-node)) (normalize "thead"))) +- (body (select-elements (children (current-node)) (normalize "tbody"))) +- (feet (select-elements (children (current-node)) (normalize "tfoot")))) +- (make element gi: "TABLE" +- attributes: (append +- border +- width +- bgcolor +- '(("CELLSPACING" "0")) +- '(("CELLPADDING" "4")) +- (if %cals-table-class% +- (list (list "CLASS" %cals-table-class%)) +- '())) +- (process-node-list head) +- (process-node-list body) +- (process-node-list feet) +- (make-table-endnotes)))) + + ;; This overrides the refsect2 definition (copied from 1.20, dbrfntry.dsl). + ;; It puts a horizontal rule before each function/struct/... description, +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtk-doc.dtd gtk-doc/gtk-doc.dtd +--- gtk-doc-0.9/gtk-doc.dtd Thu Jan 1 01:00:00 1970 ++++ gtk-doc/gtk-doc.dtd Tue Nov 24 07:00:33 1998 +@@ -0,0 +1,10 @@ ++ ++ ++ ++ ++ ++ ++ ++ ++%orig-docbook; +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtk-doc.xsl gtk-doc/gtk-doc.xsl +--- gtk-doc-0.9/gtk-doc.xsl Thu Jan 1 01:00:00 1970 ++++ gtk-doc/gtk-doc.xsl Tue Sep 17 07:10:54 2002 +@@ -0,0 +1,332 @@ ++ ++ ++ ++ ++ ++ ++ ++ ++ 1 ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ <ANCHOR id=" ++ ++ " href=" ++ ++ ++ / ++ ++ ++ "> ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++
++
++ ++
++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++
++

++ ++ ++ ++

++
++
++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++
++ ++ ++ ++
++ ++ ++ ++ ++ ++ ++ ++ ++ ++ <<<  ++ ++ nav-prev ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ nav-home ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ nav-up ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ nav-next ++ ++  >>> ++ ++ ++ ++ ++
++
++
++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++
++ ++ ++ ++ ++ ++ ++ ++ ++ ++ <<<  ++ ++ nav-prev ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ nav-home ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ nav-up ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ nav-next ++ ++  >>> ++ ++ ++ ++ ++
++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++
++
++
++ ++
+diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtkdoc-mkdb.in gtk-doc/gtkdoc-mkdb.in +--- gtk-doc-0.9/gtkdoc-mkdb.in Fri Jan 18 18:19:27 2002 ++++ gtk-doc/gtkdoc-mkdb.in Mon Sep 9 03:46:56 2002 +@@ -47,6 +47,7 @@ + my $OUTPUT_ALL_SYMBOLS; + my $MAIN_SGML_FILE; + my $SGML_MODE; ++my $OUTPUT_FORMAT; + + my %optctl = (module => \$MODULE, + 'source-dir' => \@SOURCE_DIRS, +@@ -56,14 +57,19 @@ + 'help' => \$PRINT_HELP, + 'main-sgml-file' => \$MAIN_SGML_FILE, + 'outputallsymbols' => \$OUTPUT_ALL_SYMBOLS, +- 'sgml-mode' => \$SGML_MODE); +-GetOptions(\%optctl, "module=s", "source-dir:s", "output-dir:s", "version", "outputallsymbols", "main-sgml-file:s", "help", "sgml-mode"); ++ 'sgml-mode' => \$SGML_MODE, ++ 'output-format' => \$OUTPUT_FORMAT); ++GetOptions(\%optctl, "module=s", "source-dir:s", "output-dir:s", "version", "outputallsymbols", "main-sgml-file:s", "help", "sgml-mode", "output-format:s"); + + if ($PRINT_VERSION) { + print "@VERSION@\n"; + exit 0; + } + ++if (!$MODULE) { ++ $PRINT_HELP = 1; ++} ++ + if ($PRINT_HELP) { + print "gtkdoc-mkdb version @VERSION@\n"; + print "\n--module=MODULE_NAME Name of the doc module being parsed"; +@@ -72,19 +78,56 @@ + print "\n--output-dir=DIRNAME Directory to put the generated Docbook files in"; + print "\n--tmpl-dir=DIRNAME DIRECTORY in which template files may be found"; + print "\n--main-sgml-file=FILE File containing the toplevel SGML file."; ++ print "\n--output-format=FORMAT The format to use for the generated docbook, XML or SGML."; + print "\n--sgml-mode Allow Docbook markup in inline documentation."; + print "\n--version Print the version of this program"; + print "\n--help Print this help\n"; + exit 0; + } + ++if (!$MAIN_SGML_FILE) { ++ $MAIN_SGML_FILE="${MODULE}-docs.sgml"; ++} ++ ++my ($empty_element_end, $doctype_header); ++ ++if (lc($OUTPUT_FORMAT) eq "xml") { ++ $OUTPUT_FORMAT = "xml"; ++ $empty_element_end = "/>"; ++ ++ if ($MAIN_SGML_FILE && -e $MAIN_SGML_FILE) { ++ print "scanning $MAIN_SGML_FILE"; ++ open(INPUT, "<$MAIN_SGML_FILE") || die "Can't open $MAIN_SGML_FILE"; ++ $doctype_header = ""; ++ while () { ++ if (/^\s*<(book|chapter|article)/) { ++ if (index($_, "http://www.w3.org/2001/XInclude") < 0) { ++ $doctype_header = ""; ++ } ++ last; ++ } ++ $doctype_header .= $_; ++ } ++ close(INPUT); ++ } else { ++ $doctype_header = ++"\n" . ++"\n"; ++ } ++ $doctype_header =~ s/"; ++} ++ + my $ROOT_DIR = "."; + + # All the files are written in subdirectories beneath here. + $TMPL_DIR = $TMPL_DIR ? $TMPL_DIR : "$ROOT_DIR/tmpl"; + + # This is where we put all the DocBook output. +-$SGML_OUTPUT_DIR = $SGML_OUTPUT_DIR ? $SGML_OUTPUT_DIR : "$ROOT_DIR/sgml"; ++$SGML_OUTPUT_DIR = $SGML_OUTPUT_DIR ? $SGML_OUTPUT_DIR : "$ROOT_DIR/$OUTPUT_FORMAT"; + + # This file contains the object hierarchy. + my $OBJECT_TREE_FILE = "$ROOT_DIR/$MODULE.hierarchy"; +@@ -108,7 +151,8 @@ + my @ArgNames; # The Arg name. + my @ArgTypes; # The Arg type - gint, GtkArrowType etc. + my @ArgFlags; # How the Arg can be used - readable/writable etc. +- ++my @ArgNicks; # The nickname of the Arg. ++my @ArgBlurbs; # Docstring of the Arg. + # These global hashes store declaration info keyed on a symbol name. + my %Declarations; + my %DeclarationTypes; +@@ -203,9 +247,9 @@ + print (OUTPUT < + +- +- +- ++ + EOF + +@@ -254,6 +298,15 @@ + my $details; + my $num_symbols; + my $changed = 0; ++ my $signals_synop = ""; ++ my $signals_desc = ""; ++ my $args_synop = ""; ++ my $child_args_synop = ""; ++ my $style_args_synop = ""; ++ my $args_desc = ""; ++ my $child_args_desc = ""; ++ my $style_args_desc = ""; ++ my $hierarchy = ""; + + while () { + if (m/^#/) { +@@ -286,7 +339,7 @@ + %SymbolDocs = (); + %SymbolTypes = (); + %SymbolParams = (); +- &ReadTemplateFile ("$TMPL_DIR/$file.sgml", 1); ++ &ReadTemplateFile ("$TMPL_DIR/$file", 1); + &MergeSourceDocumentation; + + } elsif (m/^(.*)<\/INCLUDE>/) { +@@ -303,7 +356,6 @@ + # print "End of section: $title\n"; + + $file =~ s/\s/_/g; +- $file .= ".sgml"; + + # GtkObjects use their class name as the ID. + my $section_id; +@@ -314,16 +366,102 @@ + } + + if ($num_symbols > 0) { +- $book_top .= "\n"; +- $book_bottom .= " &$section_id;\n"; ++ if (lc($OUTPUT_FORMAT) eq "xml") { ++ $book_bottom .= " \n"; ++ } else { ++ $book_top.="\n"; ++ $book_bottom .= " &$section_id;\n"; ++ } + + if ($section_includes eq "") { + $section_includes = $includes; + } + ++ if ($signals_synop ne '') { ++ $signals_synop = < ++Signal Prototypes ++ ++ ++${signals_synop} ++ ++EOF ++ $signals_desc = < ++Signals ++$signals_desc ++ ++EOF ++ } ++ if ($args_synop ne '') { ++ $args_synop = < ++Properties ++ ++ ++${args_synop} ++ ++EOF ++ $args_desc = < ++Properties ++ ++$args_desc ++ ++ ++EOF ++ } ++ if ($child_args_synop ne '') { ++ $args_synop .= < ++Child Properties ++ ++ ++${child_args_synop} ++ ++EOF ++ $args_desc .= < ++Child Properties ++ ++$child_args_desc ++ ++ ++EOF ++ } ++ if ($style_args_synop ne '') { ++ $args_synop .= < ++Style Properties ++ ++ ++${style_args_synop} ++ ++EOF ++ $args_desc .= < ++Style Properties ++ ++$style_args_desc ++ ++ ++EOF ++ } ++ if ($hierarchy ne "") { ++ $hierarchy = < ++Object Hierarchy ++$hierarchy ++ ++EOF ++ } ++ + my $file_changed = &OutputSGMLFile ($file, $title, $section_id, + $section_includes, +- \$synopsis, \$details); ++ \$synopsis, \$details, ++ \$signals_synop, \$signals_desc, ++ \$args_synop, \$args_desc, ++ \$hierarchy); + if ($file_changed) { + $changed = 1; + } +@@ -332,20 +470,42 @@ + $subsection = ""; + $in_section = 0; + $section_includes = ""; ++ $signals_synop = ""; ++ $signals_desc = ""; ++ $args_synop = ""; ++ $child_args_synop = ""; ++ $style_args_synop = ""; ++ $args_desc = ""; ++ $child_args_desc = ""; ++ $style_args_desc = ""; ++ $hierarchy = ""; + + } elsif (m/^(\S+)/) { + my $symbol = $1; + # print " Symbol: $symbol\n"; + +- my $declaration = $Declarations{$1}; ++ my $declaration = $Declarations{$symbol}; + if (defined ($declaration)) { + # We don't want standard macros/functions of GtkObjects, + # or private declarations. + if ($subsection ne "Standard" && $subsection ne "Private") { + my ($synop, $desc) = &OutputDeclaration ($symbol, + $declaration); ++ my ($sig_synop, $sig_desc) = &GetSignals ($symbol); ++ my ($arg_synop, $child_arg_synop, $style_arg_synop, ++ $arg_desc, $child_arg_desc, $style_arg_desc) = &GetArgs ($symbol); ++ my $hier = &GetHierarchy ($symbol); + $synopsis .= $synop; + $details .= $desc; ++ $signals_synop .= $sig_synop; ++ $signals_desc .= $sig_desc; ++ $args_synop .= $arg_synop; ++ $child_args_synop .= $child_arg_synop; ++ $style_args_synop .= $style_arg_synop; ++ $args_desc .= $arg_desc; ++ $child_args_desc .= $child_arg_desc; ++ $style_args_desc .= $style_arg_desc; ++ $hierarchy .= $hier; + } + + # Note that the declaration has been output. +@@ -430,9 +590,9 @@ + $synop .= "\n"; + + if ($args ne "") { +- $desc = "\n<anchor id=\"$id\">${symbol}()\n"; ++ $desc = "\n<anchor id=\"$id\"${empty_element_end}${symbol}()\n"; + } else { +- $desc = "\n<anchor id=\"$id\">$symbol\n"; ++ $desc = "\n<anchor id=\"$id\"${empty_element_end}$symbol\n"; + } + # Don't output the macro definition if is is a conditional macro or it + # looks like a function, i.e. starts with "g_" or "_?gnome_", or it is +@@ -473,7 +633,7 @@ + my ($symbol, $declaration) = @_; + my $id = &CreateValidSGMLID ($symbol); + my $synop = "typedef $symbol;\n"; +- my $desc = "\n<anchor id=\"$id\">$symbol\n"; ++ my $desc = "\n<anchor id=\"$id\"${empty_element_end}$symbol\n"; + if (!defined ($DeclarationConditional{$symbol})) { + $declaration = &CreateValidSGML ($declaration); + $desc .= "$declaration\n"; +@@ -518,7 +678,7 @@ + $id = &CreateValidSGMLID ($symbol); + } + my $synop = "struct $symbol;\n"; +- my $desc = "\n<anchor id=\"$id\">struct $symbol\n"; ++ my $desc = "\n<anchor id=\"$id\"${empty_element_end}struct $symbol\n"; + + # Form a pretty-printed, private-data-removed form of the declaration + +@@ -592,27 +752,23 @@ + my %field_descrs = @$params; + + $desc .= < +- +- +- +- ++ + EOF + while (@fields) { + my $field_name = shift @fields; + my $text = shift @fields; + my $field_descr = $field_descrs{$field_name}; + +- $desc .= "\n$text\n"; ++ $desc .= "\n$text\n"; + if (defined $field_descr) { +- $desc .= "".&ExpandAbbreviations($field_descr)."\n"; ++ $desc .= "".&ExpandAbbreviations($field_descr)."\n"; + } else { +- $desc .= "\n"; ++ $desc .= "\n"; + } +- $desc .= "\n"; ++ $desc .= "\n"; + } + +- $desc .= ""; ++ $desc .= "
"; + } + $desc .= "\n"; + return ($synop, $desc); +@@ -630,7 +786,7 @@ + my ($symbol, $declaration) = @_; + my $id = &CreateValidSGMLID ($symbol); + my $synop = "enum $symbol;\n"; +- my $desc = "\n<anchor id=\"$id\">enum $symbol\n"; ++ my $desc = "\n<anchor id=\"$id\"${empty_element_end}enum $symbol\n"; + $declaration = &CreateValidSGML ($declaration); + $desc .= "$declaration\n"; + +@@ -664,25 +820,21 @@ + my %member_descrs = @$params; + + $desc .= < +- +- +- +- ++ + EOF + for my $member_name (@members) { + my $member_descr = $member_descrs{$member_name}; + +- $desc .= "\n$member_name\n"; ++ $desc .= "\n$member_name\n"; + if (defined $member_descr) { +- $desc .= "".&ExpandAbbreviations($member_descr)."\n"; ++ $desc .= "".&ExpandAbbreviations($member_descr)."\n"; + } else { +- $desc .= "\n"; ++ $desc .= "\n"; + } +- $desc .= "\n"; ++ $desc .= "\n"; + } + +- $desc .= ""; ++ $desc .= ""; + } + + $desc .= "\n"; +@@ -701,7 +853,7 @@ + my ($symbol, $declaration) = @_; + my $id = &CreateValidSGMLID ($symbol); + my $synop = "union $symbol;\n"; +- my $desc = "\n<anchor id=\"$id\">union $symbol\n"; ++ my $desc = "\n<anchor id=\"$id\"${empty_element_end}union $symbol\n"; + $declaration = &CreateValidSGML ($declaration); + $desc .= "$declaration\n"; + +@@ -739,7 +891,7 @@ + $synop = "extern $symbol;\n"; + } + +- my $desc = "\n<anchor id=\"$id\">$symbol\n"; ++ my $desc = "\n<anchor id=\"$id\"${empty_element_end}$symbol\n"; + $declaration = &CreateValidSGML ($declaration); + $desc .= "$declaration\n"; + +@@ -816,7 +968,7 @@ + } + + my $synop = $ret_type_output . $symbol_output . '('; +- my $desc = "\n<anchor id=\"$id\">${symbol} ()\n"; ++ my $desc = "\n<anchor id=\"$id\"${empty_element_end}${symbol} ()\n"; + $desc .= "${ret_type_output}$symbol_desc_output("; + + my $param_num = 0; +@@ -947,37 +1099,33 @@ + $param_name = "..."; + } + $param = &ExpandAbbreviations($param); +- $params_desc .= "$param_name :\n$param\n"; ++ $params_desc .= "$param_name :\n$param\n"; + } + } + + # Signals have an implicit user_data parameter which we describe. + if ($symbol_type eq "SIGNAL") { +- $params_desc .= "user_data :\nuser data set when the signal handler was connected.\n"; ++ $params_desc .= "user_data :\nuser data set when the signal handler was connected.\n"; + } + + # Start a table if we need one. + if ($params_desc || $returns) { + $output .= < +- +- +- +- ++ + EOF + + if ($params_desc ne "") { +-# $output .= "Parameters:\n"; ++# $output .= "Parameters:\n"; + $output .= $params_desc; + } + + # Output the returns info last. + if ($returns) { +- $output .= "Returns :$returns\n"; ++ $output .= "Returns :$returns\n"; + } + + # Finish the table. +- $output .= ""; ++ $output .= ""; + } + } + return $output; +@@ -995,22 +1143,15 @@ + # of synopsis, with '<' '>' around them. + # $synopsis - reference to the DocBook for the Synopsis part. + # $details - reference to the DocBook for the Details part. ++# $signal_synop - reference to the DocBook for the Signal Synopsis part ++# $signal_desc - reference to the DocBook for the Signal Description part ++# $args_synop - reference to the DocBook for the Arg Synopsis part ++# $args_desc - reference to the DocBook for the Arg Description part ++# $hierarchy - reference to the DocBook for the Object Hierarchy part + ############################################################################# + + sub OutputSGMLFile { +- my ($file, $title, $section_id, $includes, $synopsis, $details) = @_; +- +- # Find out if this is a GtkObject or descendant. +- my $signals_synop = ""; +- my $signals_desc = ""; +- my $args_synop = ""; +- my $args_desc = ""; +- my $hierarchy = ""; +- if (&CheckIsObject ($title)) { +- ($signals_synop, $signals_desc) = &GetSignals ($title); +- ($args_synop, $args_desc) = &GetArgs ($title); +- $hierarchy = &GetHierarchy ($title); +- } ++ my ($file, $title, $section_id, $includes, $synopsis, $details, $signals_synop, $signals_desc, $args_synop, $args_desc, $hierarchy) = @_; + + # The edited title overrides the one from the sections file. + my $new_title = $SymbolDocs{"$TMPL_DIR/$file:Title"}; +@@ -1055,8 +1196,8 @@ + $include_output .= "#include <${include}>\n"; + } + +- my $old_sgml_file = "$SGML_OUTPUT_DIR/$file"; +- my $new_sgml_file = "$SGML_OUTPUT_DIR/$file.new"; ++ my $old_sgml_file = "$SGML_OUTPUT_DIR/$file.$OUTPUT_FORMAT"; ++ my $new_sgml_file = "$SGML_OUTPUT_DIR/$file.$OUTPUT_FORMAT.new"; + + open (OUTPUT, ">$new_sgml_file") + || die "Can't create $new_sgml_file"; +@@ -1068,6 +1209,10 @@ + # since it changes every day (and it is only used in the man pages): + # "" + ++ if (lc($OUTPUT_FORMAT) eq "xml") { ++ print OUTPUT $doctype_header; ++ } ++ + print OUTPUT < + +@@ -1088,9 +1233,9 @@ + $${synopsis} + + +-$hierarchy +-$args_synop +-$signals_synop ++$$hierarchy ++$$args_synop ++$$signals_synop + + + Description +@@ -1101,8 +1246,8 @@ + Details + $$details + +-$args_desc +-$signals_desc ++$$args_desc ++$$signals_desc + + $see_also + +@@ -1154,15 +1299,25 @@ + open (OUTPUT, ">$MAIN_SGML_FILE") + || die "Can't create $MAIN_SGML_FILE"; + +- print OUTPUT < ++ ++ + EOF +- +- print OUTPUT $book_top; +- +- print OUTPUT < + ++EOF ++ } ++ ++print OUTPUT < + [Insert name here] Reference Manual + +@@ -1224,6 +1379,30 @@ + return $text; + } + ++############################################################################# ++# Function : ConvertSGMLChars ++# Description : This turns chars which are used in SGML into entities, ++# e.g. '<' into '<'. Depending on $SGML_MODE, this is done ++# unconditionally or only if the character doesn't seem to be ++# part of an SGML construct (tag or entity reference) ++# Arguments : $text - the text to turn into proper SGML. ++############################################################################# ++ ++sub ConvertSGMLChars { ++ my ($text) = @_; ++ if ($SGML_MODE) { ++ $text =~ s/&(?![a-zA-Z#])/&/g; # Do this first, or the others get messed up. ++ $text =~ s/<(?![a-zA-Z\/!])/</g; ++ $text =~ s/(?/>/g; ++ } ++ else { ++ $text =~ s/&/&/g; # Do this first, or the others get messed up. ++ $text =~ s//>/g; ++ } ++ return $text; ++} ++ + + ############################################################################# + # Function : ExpandAbbreviations +@@ -1337,12 +1516,7 @@ + } + $hierarchy .= "\n"; + +- return < +-Object Hierarchy +-$hierarchy +- +-EOF ++ return $hierarchy; + } + + +@@ -1375,7 +1549,7 @@ + . (' ' x $SIGNAL_FIELD_WIDTH); + } + +- $desc .= "<anchor id=\"$id\">The "$name" signal\n"; ++ $desc .= "<anchor id=\"$id\"${empty_element_end}The "$name" signal\n"; + $desc .= ""; + + $SignalReturns[$i] =~ m/\s*(const\s*)?(\w+)\s*(\**)/; +@@ -1421,22 +1595,6 @@ + $desc .= ""; + } + } +- if ($synop ne '') { +- $synop = < +-Signal Prototypes +- +- +-${synop} +- +-EOF +- $desc = < +-Signals +-$desc +- +-EOF +- } + return ($synop, $desc); + } + +@@ -1452,6 +1610,10 @@ + my ($object) = @_; + my $synop = ""; + my $desc = ""; ++ my $child_synop = ""; ++ my $child_desc = ""; ++ my $style_synop = ""; ++ my $style_desc = ""; + + my $i; + for ($i = 0; $i <= $#ArgObjects; $i++) { +@@ -1495,45 +1657,29 @@ + if ($flags_string) { $flags_string .= " / "; } + $flags_string .= "Construct Only"; + } +- if ($flags =~ m/c/) { +- if ($flags_string) { $flags_string .= " / "; } +- $flags_string .= "Child"; +- } + ++ my $blurb = &CreateValidSGML ($ArgBlurbs[$i]); + my $pad1 = " " x (20 - length ($name)); + my $pad2 = " " x (20 - length ($type)); +- $synop .= " "$name"$pad1 $type_output$pad2 : $flags_string\n"; + +- $desc .= ""$name" ($type_output : $flags_string)\n\n"; ++ my $arg_synop = " "$name"$pad1 $type_output$pad2 : $flags_string\n"; ++ my $arg_desc = "$name" ($type_output : $flags_string)\n\n$blurb\n\n"; + +- if (defined ($SymbolDocs{$symbol})) { +- $desc .= &ExpandAbbreviations($SymbolDocs{$symbol}); +- } else { +- $desc .= "\n"; ++ if ($flags =~ m/c/) { ++ $child_synop .= $arg_synop; ++ $child_desc .= $arg_desc; ++ } ++ elsif ($flags =~ m/s/) { ++ $style_synop .= $arg_synop; ++ $style_desc .= $arg_desc; ++ } ++ else { ++ $synop .= $arg_synop; ++ $desc .= $arg_desc; + } +- +- $desc .= "\n"; + } + } +- if ($synop ne '') { +- $synop = < +-Properties +- +- +-${synop} +- +-EOF +- $desc = < +-Properties +- +-$desc +- +- +-EOF +- } +- return ($synop, $desc); ++ return ($synop, $child_synop, $style_synop, $desc, $child_desc, $style_desc); + } + + +@@ -1604,6 +1750,7 @@ + my ($in_description, $in_return); + my ($description, $return_desc, $return_start); + my $current_param; ++ my $ignore_returns; + my @params; + while () { + # Look for the start of a comment block. +@@ -1621,6 +1768,7 @@ + $description = ""; + $return_desc = ""; + $current_param = -1; ++ $ignore_returns = 0; + @params = (); + } + next; +@@ -1640,14 +1788,12 @@ + push (@params, "Returns"); + push (@params, $return_desc); + } +- # Convert special SGML characters, unless --sgml-mode is used. +- if (!$SGML_MODE) { +- $description = &CreateValidSGML ($description); +- my $k; +- for ($k = 1; $k <= $#params; $k += 2) { +- $params[$k] = &CreateValidSGML ($params[$k]); +- } +- } ++ # Convert special SGML characters ++ $description = &ConvertSGMLChars ($description); ++ my $k; ++ for ($k = 1; $k <= $#params; $k += 2) { ++ $params[$k] = &ConvertSGMLChars ($params[$k]); ++ } + + $SourceSymbolDocs{$symbol} = $description; + $SourceSymbolParams{$symbol} = [ @params ]; +@@ -1692,7 +1838,7 @@ + # Get rid of 'Description:' + s%^\s*Description:%%; + +- if (m%^\s*(returns:|return\s+value:|returns\s*)%i) { ++ if (!$ignore_returns && m%^\s*(returns:|return\s+value:|returns\s*)%i) { + # print "RETURNS: $_"; + $return_start = $1; + $return_desc = $'; +@@ -1718,6 +1864,9 @@ + if ($param_name eq "...") { + $param_name = "Varargs"; + } ++ if ("\L$param_name" eq "returns") { ++ $ignore_returns = 1; ++ } + push (@params, $param_name); + push (@params, $'); + $current_param += 2; +@@ -1758,16 +1907,12 @@ + + foreach $symbol (sort (keys (%AllSymbols))) { + if (defined ($Declarations{$symbol})) { +- my $type = $DeclarationTypes{$symbol}; +- if (($type eq 'FUNCTION') or ($type eq 'MACRO')) { +- $total++; +- if (exists ($AllDocumentedSymbols{$symbol})) { +- $n_documented++; +- } else { +- $buffer .= $symbol . "\n"; +- } +- } elsif ($type eq 'STRUCT') { +- } ++ $total++; ++ if (exists ($AllDocumentedSymbols{$symbol})) { ++ $n_documented++; ++ } else { ++ $buffer .= $symbol . "\n"; ++ } + } + } + +@@ -1778,15 +1923,15 @@ + $percent = ($n_documented / $total) * 100.0; + } + +- printf UNDOCUMENTED "%.0f%% function docs coverage.\n", $percent; +- print UNDOCUMENTED "$n_documented functions documented.\n"; ++ printf UNDOCUMENTED "%.0f%% symbol docs coverage.\n", $percent; ++ print UNDOCUMENTED "$n_documented symbols documented.\n"; + print UNDOCUMENTED ($total - $n_documented) . " not documented.\n\n\n"; + + print UNDOCUMENTED $buffer; + + close (UNDOCUMENTED); + +- printf (("%.0f%% function docs coverage ($n_documented functions documented, " . ($total - $n_documented) . " not documented)\nSee $MODULE-undocumented.txt for a list of missing docs.\nThe doc coverage percentage doesn't include intro sections.\n"), $percent); ++ printf (("%.0f%% symbol docs coverage ($n_documented symbols documented, " . ($total - $n_documented) . " not documented)\nSee $MODULE-undocumented.txt for a list of missing docs.\nThe doc coverage percentage doesn't include intro sections.\n"), $percent); + } + + +@@ -2118,9 +2263,10 @@ + sub ReadTemplateFile { + my ($docsfile, $skip_unused_params) = @_; + +-# print "Reading $docsfile\n"; +- if (! -f $docsfile) { +- print "File doesn't exist: $docsfile\n"; ++ my $template = "$docsfile.sgml"; ++# print "Reading $template\n"; ++ if (! -f $template) { ++ print "File doesn't exist: $template\n"; + return; + } + +@@ -2134,8 +2280,8 @@ + # of param name & description. + my $in_unused_params = 0; # True if we are reading in the unused params. + +- open (DOCS, $docsfile) +- || die "Can't open file $docsfile: $!"; ++ open (DOCS, "$template") ++ || die "Can't open file $template: $!"; + while () { + if (m/^/) { + my $type = $1; +@@ -2247,10 +2393,12 @@ + + my $old_tree_index = "$SGML_OUTPUT_DIR/tree_index.sgml"; + my $new_tree_index = "$SGML_OUTPUT_DIR/tree_index.new"; ++ my $tree_header = $doctype_header; ++ $tree_header =~ s/$new_tree_index") + || die "Can't create $new_tree_index"; +- print (OUTPUT "\n"); ++ print (OUTPUT "$tree_header\n"); + + while () { + if (m/\S+/) { +@@ -2264,7 +2412,7 @@ + push (@ObjectLevels, $level); + } + } +- print (OUTPUT "\n"); ++ print (OUTPUT "\n"); + + close (INPUT); + close (OUTPUT); +@@ -2279,7 +2427,8 @@ + # Function : ReadArgsFile + # Description : This reads in an existing file which contains information on + # all GTK args. It creates the arrays @ArgObjects, @ArgNames, +-# @ArgTypes and @ArgFlags containing info on the args. ++# @ArgTypes, @ArgFlags, @ArgNicks and @ArgBlurbs containing info ++# on the args. + # Arguments : $file - the file containing the arg information. + ############################################################################# + +@@ -2291,12 +2440,16 @@ + my $arg_name; + my $arg_type; + my $arg_flags; ++ my $arg_nick; ++ my $arg_blurb; + + # Reset the signal info. + @ArgObjects = (); + @ArgNames = (); + @ArgTypes = (); + @ArgFlags = (); ++ @ArgNicks = (); ++ @ArgBlurbs = (); + + if (! -f $file) { + return; +@@ -2313,6 +2466,8 @@ + $arg_name = ""; + $arg_type = ""; + $arg_flags = ""; ++ $arg_nick = ""; ++ $arg_blurb = ""; + } + } else { + if (m/^(.*)<\/NAME>/) { +@@ -2328,12 +2483,24 @@ + $arg_type = $1; + } elsif (m/^(.*)<\/FLAGS>/) { + $arg_flags = $1; ++ } elsif (m/^(.*)<\/NICK>/) { ++ $arg_nick = $1; ++ } elsif (m/^(.*)<\/BLURB>/) { ++ $arg_blurb = $1; ++ if ($arg_blurb eq "(null)") { ++ $arg_blurb = ""; ++ print <%) { + # print "Found end of arg: ${arg_object}::${arg_name}\n${arg_type} : ${arg_flags}\n"; + push (@ArgObjects, $arg_object); + push (@ArgNames, $arg_name); + push (@ArgTypes, $arg_type); + push (@ArgFlags, $arg_flags); ++ push (@ArgNicks, $arg_nick); ++ push (@ArgBlurbs, $arg_blurb); + $in_arg = 0; + } + } +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtkdoc-mkhtml.in gtk-doc/gtkdoc-mkhtml.in +--- gtk-doc-0.9/gtkdoc-mkhtml.in Wed Nov 28 03:53:24 2001 ++++ gtk-doc/gtkdoc-mkhtml.in Sat Aug 10 10:36:46 2002 +@@ -15,16 +15,32 @@ + fi + + module=$1 ++document=$2 + + prefix=@prefix@ +-gtkdocdir=@datadir@/gtk-doc/ ++gtkdocdir=@datadir@/gtk-doc ++ ++declaration=$gtkdocdir/gtk-doc.dcl ++ ++if head -1 $document | grep -q " index.sgml.tmp && mv index.sgml.tmp index.sgml ++if $is_xml; then ++ @XSLTPROC@ --xinclude --stringparam gtkdoc.bookname $module $gtkdocdir/gtk-doc.xsl $document ++else ++ @JADE@ -t sgml -w no-idref -d $gtkdocdir/gtk-doc.dsl \ ++ $gtkdocdir/gtk-doc.dcl $document ++ ++ sed s%href=\"%href=\"$module/% < index.sgml > index.sgml.tmp && mv index.sgml.tmp index.sgml ++fi + + echo "timestamp" > ../html.stamp ++ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/gtkdoc-scangobj.in gtk-doc/gtkdoc-scangobj.in +--- gtk-doc-0.9/gtkdoc-scangobj.in Fri Feb 1 23:16:16 2002 ++++ gtk-doc/gtkdoc-scangobj.in Thu Aug 8 00:13:12 2002 +@@ -68,7 +68,7 @@ + open OUTPUT, ">$MODULE-scan.c" || die "Cannot open $MODULE-scan.c: $!\n"; + + my $old_signals_filename = "$OUTPUT_DIR/$MODULE.signals"; +-my $new_signals_filename = "$OUTPUT_DIR/MODULE.signals.new"; ++my $new_signals_filename = "$OUTPUT_DIR/$MODULE.signals.new"; + my $old_hierarchy_filename = "$OUTPUT_DIR/$MODULE.hierarchy"; + my $new_hierarchy_filename = "$OUTPUT_DIR/$MODULE.hierarchy.new"; + my $old_args_filename = "$OUTPUT_DIR/$MODULE.args"; +@@ -100,6 +100,9 @@ + #include + + $includes ++#ifdef GTK_IS_WIDGET_CLASS ++#include ++#endif + GType object_types[$ntypes]; + + GType * +@@ -119,6 +122,7 @@ + * their signals and properties. + */ + for (i=0; object_types[i]; i++) ++ if (G_TYPE_IS_CLASSED (object_types[i])) + g_type_class_ref (object_types[i]); + + return object_types; +@@ -207,17 +211,22 @@ + guint *signals, n_signals; + guint sig; + +- object_class_name = g_type_name (object_type); ++ if (G_TYPE_IS_INSTANTIATABLE (object_type) || ++ G_TYPE_IS_INTERFACE (object_type)) ++ { + +- signals = g_signal_list_ids (object_type, &n_signals); +- qsort (signals, n_signals, sizeof (guint), compare_signals); ++ object_class_name = g_type_name (object_type); + +- for (sig = 0; sig < n_signals; sig++) +- { +- output_widget_signal (fp, object_type, object_class_name, +- signals[sig]); +- } +- g_free (signals); ++ signals = g_signal_list_ids (object_type, &n_signals); ++ qsort (signals, n_signals, sizeof (guint), compare_signals); ++ ++ for (sig = 0; sig < n_signals; sig++) ++ { ++ output_widget_signal (fp, object_type, object_class_name, ++ signals[sig]); ++ } ++ g_free (signals); ++ } + } + + +@@ -735,7 +744,6 @@ + fclose (fp); + } + +- + static void + output_widget_args (FILE *fp, GType object_type) + { +@@ -745,6 +753,11 @@ + gchar flags[16], *pos; + GParamSpec **properties; + guint n_properties; ++ gboolean child_prop; ++ gboolean style_prop; ++ ++ if (!G_TYPE_IS_CLASSED (object_type)) ++ return; + + class = g_type_class_peek (object_type); + if (!class) +@@ -753,31 +766,70 @@ + object_class_name = g_type_name (object_type); + + properties = g_object_class_list_properties (class, &n_properties); ++ child_prop = FALSE; ++ style_prop = FALSE; + +- for (arg = 0; arg < n_properties; arg++) +- { +- GParamSpec *spec = properties[arg]; +- +- if (spec->owner_type != object_type) +- continue; +- +- pos = flags; +- /* We use one-character flags for simplicity. */ +- if (spec->flags & G_PARAM_READABLE) +- *pos++ = 'r'; +- if (spec->flags & G_PARAM_WRITABLE) +- *pos++ = 'w'; +- if (spec->flags & G_PARAM_CONSTRUCT) +- *pos++ = 'x'; +- if (spec->flags & G_PARAM_CONSTRUCT_ONLY) +- *pos++ = 'X'; +- *pos = 0; ++ while (TRUE) { ++ for (arg = 0; arg < n_properties; arg++) ++ { ++ GParamSpec *spec = properties[arg]; ++ const gchar *nick, *blurb, *dot; ++ ++ if (spec->owner_type != object_type) ++ continue; ++ ++ pos = flags; ++ /* We use one-character flags for simplicity. */ ++ if (child_prop && !style_prop) ++ *pos++ = 'c'; ++ if (style_prop) ++ *pos++ = 's'; ++ if (spec->flags & G_PARAM_READABLE) ++ *pos++ = 'r'; ++ if (spec->flags & G_PARAM_WRITABLE) ++ *pos++ = 'w'; ++ if (spec->flags & G_PARAM_CONSTRUCT) ++ *pos++ = 'x'; ++ if (spec->flags & G_PARAM_CONSTRUCT_ONLY) ++ *pos++ = 'X'; ++ *pos = 0; ++ ++ nick = g_param_spec_get_nick (spec); ++ blurb = g_param_spec_get_blurb (spec); ++ ++ dot = ""; ++ if (blurb) { ++ int str_len = strlen (blurb); ++ if (str_len > 0 && blurb[str_len - 1] != '.') ++ dot = "."; ++ } ++ ++ fprintf (fp, "\\n%s::%s\\n%s\\n%s\\n%s\\n%s%s\\n\\n\\n", ++ object_class_name, g_param_spec_get_name (spec), g_type_name (spec->value_type), flags, nick ? nick : "(null)", blurb ? blurb : "(null)", dot); ++ } ++ ++ g_free (properties); ++ ++#ifdef GTK_IS_CONTAINER_CLASS ++ if (!child_prop && GTK_IS_CONTAINER_CLASS (class)) { ++ properties = gtk_container_class_list_child_properties (class, &n_properties); ++ child_prop = TRUE; ++ continue; ++ } ++#endif + +- fprintf (fp, "\\n%s::%s\\n%s\\n%s\\n\\n\\n", +- object_class_name, spec->name, g_type_name (spec->value_type), flags); ++#ifdef GTK_IS_WIDGET_CLASS ++#if GTK_CHECK_VERSION(2,1,0) ++ if (!style_prop && GTK_IS_WIDGET_CLASS (class)) { ++ properties = gtk_widget_class_list_style_properties (GTK_WIDGET_CLASS (class), &n_properties); ++ style_prop = TRUE; ++ continue; + } ++#endif ++#endif + +- g_free (properties); ++ break; ++ } + } + EOT + +@@ -803,9 +855,10 @@ + + system("./$MODULE-scan") == 0 or die "Scan failed\n"; + +-unlink "./$MODULE-scan.c", "./$MODULE-scan", +- ++unlink "./$MODULE-scan.c", "./$o_file", "./$MODULE-scan"; + + &UpdateFileIfChanged ($old_signals_filename, $new_signals_filename, 0); + &UpdateFileIfChanged ($old_hierarchy_filename, $new_hierarchy_filename, 0); + &UpdateFileIfChanged ($old_args_filename, $new_args_filename, 0); ++ ++ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/help/manual/C/ChangeLog gtk-doc/help/manual/C/ChangeLog +--- gtk-doc-0.9/help/manual/C/ChangeLog Thu Jan 1 01:00:00 1970 ++++ gtk-doc/help/manual/C/ChangeLog Mon Nov 27 06:27:46 2000 +@@ -0,0 +1,14 @@ ++2000-11-26 Dan Mueth ++ ++ * gtk-doc-manual.sgml: Committing changes made by ++ Chris Lyttle . (Text for Chapter 1) ++ ++2000-11-25 Dan Mueth ++ ++ * gtk-doc-manual.sgml: Put part of the outline into SGML. ++ Chris plans to put rest of outline in here and start ++ writing. ++ * fdl-appendix.sgml: The FDL in SGML. We will probably post ++ these on the web as a single document (book) so we will ++ need the FDL to be included as an appendix. ++ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/help/manual/C/fdl-appendix.sgml gtk-doc/help/manual/C/fdl-appendix.sgml +--- gtk-doc-0.9/help/manual/C/fdl-appendix.sgml Thu Jan 1 01:00:00 1970 ++++ gtk-doc/help/manual/C/fdl-appendix.sgml Sat Nov 25 23:41:56 2000 +@@ -0,0 +1,671 @@ ++ ++ ++ ++ ++ ++ Version 1.1, March 2000 ++ ++ ++ 2000Free Software Foundation, Inc. ++ ++ ++ ++
Free Software Foundation, Inc. 59 Temple Place, ++ Suite 330, Boston, MA ++ 02111-1307 USA
++ Everyone is permitted to copy and distribute verbatim copies of this ++ license document, but changing it is not allowed. ++
++
++
++ GNU Free Documentation License ++ ++ ++ 0. PREAMBLE ++ ++ The purpose of this License is to make a manual, textbook, or ++ other written document free in the sense of ++ freedom: to assure everyone the effective freedom to copy and ++ redistribute it, with or without modifying it, either ++ commercially or noncommercially. Secondarily, this License ++ preserves for the author and publisher a way to get credit for ++ their work, while not being considered responsible for ++ modifications made by others. ++ ++ ++ ++ This License is a kind of copyleft, which means ++ that derivative works of the document must themselves be free in ++ the same sense. It complements the GNU General Public License, ++ which is a copyleft license designed for free software. ++ ++ ++ ++ We have designed this License in order to use it for manuals for ++ free software, because free software needs free documentation: a ++ free program should come with manuals providing the same ++ freedoms that the software does. But this License is not limited ++ to software manuals; it can be used for any textual work, ++ regardless of subject matter or whether it is published as a ++ printed book. We recommend this License principally for works ++ whose purpose is instruction or reference. ++ ++ ++ ++ 1. APPLICABILITY AND DEFINITIONS ++ ++ This License applies to any manual or other work that contains a ++ notice placed by the copyright holder saying it can be ++ distributed under the terms of this License. The ++ Document, below, refers to any such manual or ++ work. Any member of the public is a licensee, and is addressed ++ as you. ++ ++ ++ ++ A Modified Version of the Document means any work ++ containing the Document or a portion of it, either copied ++ verbatim, or with modifications and/or translated into another ++ language. ++ ++ ++ ++ A Secondary Section is a named appendix or a ++ front-matter section of the Document that deals exclusively ++ with the relationship of the publishers or authors of the ++ Document to the Document's overall subject (or to related ++ matters) and contains nothing that could fall directly within ++ that overall subject. (For example, if the Document is in part a ++ textbook of mathematics, a Secondary Section may not explain any ++ mathematics.) The relationship could be a matter of historical ++ connection with the subject or with related matters, or of ++ legal, commercial, philosophical, ethical or political position ++ regarding them. ++ ++ ++ ++ The Invariant Sections are certain Secondary Sections whose titles ++ are designated, as being those of Invariant Sections, in the ++ notice that says that the Document is released under this ++ License. ++ ++ ++ ++ The Cover Texts are certain short passages of ++ text that are listed, as Front-Cover Texts or Back-Cover Texts, ++ in the notice that says that the Document is released under this ++ License. ++ ++ ++ ++ A Transparent copy of the Document means a machine-readable ++ copy, represented in a format whose specification is available ++ to the general public, whose contents can be viewed and edited ++ directly and straightforwardly with generic text editors or (for ++ images composed of pixels) generic paint programs or (for ++ drawings) some widely available drawing editor, and that is ++ suitable for input to text formatters or for automatic ++ translation to a variety of formats suitable for input to text ++ formatters. A copy made in an otherwise Transparent file format ++ whose markup has been designed to thwart or discourage ++ subsequent modification by readers is not Transparent. A copy ++ that is not Transparent is called ++ Opaque. ++ ++ ++ ++ Examples of suitable formats for Transparent copies include ++ plain ASCII without markup, Texinfo input format, LaTeX input ++ format, SGML or XML using a publicly available DTD, and ++ standard-conforming simple HTML designed for human ++ modification. Opaque formats include PostScript, PDF, ++ proprietary formats that can be read and edited only by ++ proprietary word processors, SGML or XML for which the DTD ++ and/or processing tools are not generally available, and the ++ machine-generated HTML produced by some word processors for ++ output purposes only. ++ ++ ++ ++ The Title Page means, for a printed book, the ++ title page itself, plus such following pages as are needed to ++ hold, legibly, the material this License requires to appear in ++ the title page. For works in formats which do not have any title ++ page as such, Title Page means the text near the ++ most prominent appearance of the work's title, preceding the ++ beginning of the body of the text. ++ ++ ++ ++ ++ 2. VERBATIM COPYING ++ ++ You may copy and distribute the Document in any medium, either ++ commercially or noncommercially, provided that this License, the ++ copyright notices, and the license notice saying this License ++ applies to the Document are reproduced in all copies, and that ++ you add no other conditions whatsoever to those of this ++ License. You may not use technical measures to obstruct or ++ control the reading or further copying of the copies you make or ++ distribute. However, you may accept compensation in exchange for ++ copies. If you distribute a large enough number of copies you ++ must also follow the conditions in section 3. ++ ++ ++ ++ You may also lend copies, under the same conditions stated ++ above, and you may publicly display copies. ++ ++ ++ ++ ++ 3. COPYING IN QUANTITY ++ ++ If you publish printed copies of the Document numbering more than 100, ++ and the Document's license notice requires Cover Texts, you must enclose ++ the copies in covers that carry, clearly and legibly, all these ++ Cover Texts: Front-Cover Texts on the front cover, and ++ Back-Cover Texts on the back cover. Both covers must also ++ clearly and legibly identify you as the publisher of these ++ copies. The front cover must present the full title with all ++ words of the title equally prominent and visible. You may add ++ other material on the covers in addition. Copying with changes ++ limited to the covers, as long as they preserve the title of the ++ Document and satisfy these ++ conditions, can be treated as verbatim copying in other ++ respects. ++ ++ ++ ++ If the required texts for either cover are too voluminous to fit ++ legibly, you should put the first ones listed (as many as fit ++ reasonably) on the actual cover, and continue the rest onto ++ adjacent pages. ++ ++ ++ ++ If you publish or distribute Opaque copies of the Document numbering more than 100, ++ you must either include a machine-readable Transparent copy along with ++ each Opaque copy, or state in or with each Opaque copy a ++ publicly-accessible computer-network location containing a ++ complete Transparent copy of the Document, free of added ++ material, which the general network-using public has access to ++ download anonymously at no charge using public-standard network ++ protocols. If you use the latter option, you must take ++ reasonably prudent steps, when you begin distribution of Opaque ++ copies in quantity, to ensure that this Transparent copy will ++ remain thus accessible at the stated location until at least one ++ year after the last time you distribute an Opaque copy (directly ++ or through your agents or retailers) of that edition to the ++ public. ++ ++ ++ ++ It is requested, but not required, that you contact the authors ++ of the Document well before ++ redistributing any large number of copies, to give them a chance ++ to provide you with an updated version of the Document. ++ ++ ++ ++ ++ 4. MODIFICATIONS ++ ++ You may copy and distribute a Modified Version of the Document under the conditions of ++ sections 2 and 3 above, provided that you release ++ the Modified Version under precisely this License, with the ++ Modified Version filling the role of the Document, thus ++ licensing distribution and modification of the Modified Version ++ to whoever possesses a copy of it. In addition, you must do ++ these things in the Modified Version: ++ ++ ++ ++ ++ ++ A ++ ++ Use in the Title ++ Page (and on the covers, if any) a title distinct ++ from that of the Document, and from those of ++ previous versions (which should, if there were any, be ++ listed in the History section of the Document). You may ++ use the same title as a previous version if the original ++ publisher of that version gives permission. ++ ++ ++ ++ ++ ++ ++ B ++ ++ List on the Title ++ Page, as authors, one or more persons or entities ++ responsible for authorship of the modifications in the ++ Modified Version, ++ together with at least five of the principal authors of ++ the Document (all of ++ its principal authors, if it has less than five). ++ ++ ++ ++ ++ ++ ++ C ++ ++ State on the Title ++ Page the name of the publisher of the Modified Version, as the ++ publisher. ++ ++ ++ ++ ++ ++ ++ D ++ ++ Preserve all the copyright notices of the Document. ++ ++ ++ ++ ++ ++ ++ E ++ ++ Add an appropriate copyright notice for your modifications ++ adjacent to the other copyright notices. ++ ++ ++ ++ ++ ++ ++ F ++ ++ Include, immediately after the copyright notices, a ++ license notice giving the public permission to use the ++ Modified Version under ++ the terms of this License, in the form shown in the ++ Addendum below. ++ ++ ++ ++ ++ ++ ++ G ++ ++ Preserve in that license notice the full lists of Invariant Sections and ++ required Cover ++ Texts given in the Document's license notice. ++ ++ ++ ++ ++ ++ ++ H ++ ++ Include an unaltered copy of this License. ++ ++ ++ ++ ++ ++ ++ I ++ ++ Preserve the section entitled History, and ++ its title, and add to it an item stating at least the ++ title, year, new authors, and publisher of the Modified Version as given on ++ the Title Page. If ++ there is no section entitled History in the ++ Document, create one ++ stating the title, year, authors, and publisher of the ++ Document as given on its Title Page, then add an item ++ describing the Modified Version as stated in the previous ++ sentence. ++ ++ ++ ++ ++ ++ ++ J ++ ++ Preserve the network location, if any, given in the Document for public access ++ to a Transparent ++ copy of the Document, and likewise the network locations ++ given in the Document for previous versions it was based ++ on. These may be placed in the History ++ section. You may omit a network location for a work that ++ was published at least four years before the Document ++ itself, or if the original publisher of the version it ++ refers to gives permission. ++ ++ ++ ++ ++ ++ ++ K ++ ++ In any section entitled Acknowledgements or ++ Dedications, preserve the section's title, ++ and preserve in the section all the substance and tone of ++ each of the contributor acknowledgements and/or ++ dedications given therein. ++ ++ ++ ++ ++ ++ ++ L ++ ++ Preserve all the Invariant ++ Sections of the Document, unaltered in their ++ text and in their titles. Section numbers or the ++ equivalent are not considered part of the section titles. ++ ++ ++ ++ ++ ++ ++ M ++ ++ Delete any section entitled ++ Endorsements. Such a section may not be ++ included in the Modified ++ Version. ++ ++ ++ ++ ++ ++ ++ N ++ ++ Do not retitle any existing section as ++ Endorsements or to conflict in title with ++ any Invariant ++ Section. ++ ++ ++ ++ ++ ++ ++ If the Modified Version ++ includes new front-matter sections or appendices that qualify as ++ Secondary Sections and ++ contain no material copied from the Document, you may at your ++ option designate some or all of these sections as invariant. To ++ do this, add their titles to the list of Invariant Sections in the ++ Modified Version's license notice. These titles must be ++ distinct from any other section titles. ++ ++ ++ ++ You may add a section entitled Endorsements, ++ provided it contains nothing but endorsements of your Modified Version by various ++ parties--for example, statements of peer review or that the text ++ has been approved by an organization as the authoritative ++ definition of a standard. ++ ++ ++ ++ You may add a passage of up to five words as a Front-Cover Text, and a passage ++ of up to 25 words as a Back-Cover Text, to the end of ++ the list of Cover Texts ++ in the Modified Version. ++ Only one passage of Front-Cover Text and one of Back-Cover Text ++ may be added by (or through arrangements made by) any one ++ entity. If the Document ++ already includes a cover text for the same cover, previously ++ added by you or by arrangement made by the same entity you are ++ acting on behalf of, you may not add another; but you may ++ replace the old one, on explicit permission from the previous ++ publisher that added the old one. ++ ++ ++ ++ The author(s) and publisher(s) of the Document do not by this License ++ give permission to use their names for publicity for or to ++ assert or imply endorsement of any Modified Version . ++ ++ ++ ++ ++ 5. COMBINING DOCUMENTS ++ ++ You may combine the Document ++ with other documents released under this License, under the ++ terms defined in section 4 ++ above for modified versions, provided that you include in the ++ combination all of the Invariant ++ Sections of all of the original documents, unmodified, ++ and list them all as Invariant Sections of your combined work in ++ its license notice. ++ ++ ++ ++ The combined work need only contain one copy of this License, ++ and multiple identical Invariant ++ Sections may be replaced with a single copy. If there are ++ multiple Invariant Sections with the same name but different ++ contents, make the title of each such section unique by adding ++ at the end of it, in parentheses, the name of the original ++ author or publisher of that section if known, or else a unique ++ number. Make the same adjustment to the section titles in the ++ list of Invariant Sections in the license notice of the combined ++ work. ++ ++ ++ ++ In the combination, you must combine any sections entitled ++ History in the various original documents, ++ forming one section entitled History; likewise ++ combine any sections entitled Acknowledgements, ++ and any sections entitled Dedications. You must ++ delete all sections entitled Endorsements. ++ ++ ++ ++ ++ 6. COLLECTIONS OF DOCUMENTS ++ ++ You may make a collection consisting of the Document and other documents ++ released under this License, and replace the individual copies ++ of this License in the various documents with a single copy that ++ is included in the collection, provided that you follow the ++ rules of this License for verbatim copying of each of the ++ documents in all other respects. ++ ++ ++ ++ You may extract a single document from such a collection, and ++ dispbibute it individually under this License, provided you ++ insert a copy of this License into the extracted document, and ++ follow this License in all other respects regarding verbatim ++ copying of that document. ++ ++ ++ ++ ++ 7. AGGREGATION WITH INDEPENDENT WORKS ++ ++ A compilation of the Document or its derivatives with ++ other separate and independent documents or works, in or on a ++ volume of a storage or distribution medium, does not as a whole ++ count as a Modified Version ++ of the Document, provided no compilation copyright is claimed ++ for the compilation. Such a compilation is called an ++ aggregate, and this License does not apply to the ++ other self-contained works thus compiled with the Document , on ++ account of their being thus compiled, if they are not themselves ++ derivative works of the Document. If the Cover Text requirement of section 3 is applicable to these ++ copies of the Document, then if the Document is less than one ++ quarter of the entire aggregate, the Document's Cover Texts may ++ be placed on covers that surround only the Document within the ++ aggregate. Otherwise they must appear on covers around the whole ++ aggregate. ++ ++ ++ ++ ++ 8. TRANSLATION ++ ++ Translation is considered a kind of modification, so you may ++ distribute translations of the Document under the terms of section 4. Replacing Invariant Sections with ++ translations requires special permission from their copyright ++ holders, but you may include translations of some or all ++ Invariant Sections in addition to the original versions of these ++ Invariant Sections. You may include a translation of this ++ License provided that you also include the original English ++ version of this License. In case of a disagreement between the ++ translation and the original English version of this License, ++ the original English version will prevail. ++ ++ ++ ++ ++ 9. TERMINATION ++ ++ You may not copy, modify, sublicense, or distribute the Document except as expressly ++ provided for under this License. Any other attempt to copy, ++ modify, sublicense or distribute the Document is void, and will ++ automatically terminate your rights under this License. However, ++ parties who have received copies, or rights, from you under this ++ License will not have their licenses terminated so long as such ++ parties remain in full compliance. ++ ++ ++ ++ ++ 10. FUTURE REVISIONS OF THIS LICENSE ++ ++ The Free Software ++ Foundation may publish new, revised versions of the GNU ++ Free Documentation License from time to time. Such new versions ++ will be similar in spirit to the present version, but may differ ++ in detail to address new problems or concerns. See http://www.gnu.org/copyleft/. ++ ++ ++ ++ Each version of the License is given a distinguishing version ++ number. If the Document ++ specifies that a particular numbered version of this License ++ or any later version applies to it, you have the ++ option of following the terms and conditions either of that ++ specified version or of any later version that has been ++ published (not as a draft) by the Free Software Foundation. If ++ the Document does not specify a version number of this License, ++ you may choose any version ever published (not as a draft) by ++ the Free Software Foundation. ++ ++ ++ ++ ++ Addendum ++ ++ To use this License in a document you have written, include a copy of ++ the License in the document and put the following copyright and ++ license notices just after the title page: ++ ++ ++
++ ++ Copyright © YEAR YOUR NAME. ++ ++ ++ Permission is granted to copy, distribute and/or modify this ++ document under the terms of the GNU Free Documentation ++ License, Version 1.1 or any later version published by the ++ Free Software Foundation; with the Invariant Sections being LIST ++ THEIR TITLES, with the Front-Cover Texts being LIST, ++ and with the Back-Cover ++ Texts being LIST. A copy of the license is included in ++ the section entitled GNU Free Documentation ++ License. ++ ++
++ ++ ++ If you have no Invariant ++ Sections, write with no Invariant Sections ++ instead of saying which ones are invariant. If you have no ++ Front-Cover Texts, write ++ no Front-Cover Texts instead of ++ Front-Cover Texts being LIST; likewise for Back-Cover Texts. ++ ++ ++ ++ If your document contains nontrivial examples of program code, ++ we recommend releasing these examples in parallel under your ++ choice of free software license, such as the GNU General Public ++ License, to permit their use in free software. ++ ++
++
++ ++ ++ ++ ++ ++ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/help/manual/C/gtk-doc-manual.sgml gtk-doc/help/manual/C/gtk-doc-manual.sgml +--- gtk-doc-0.9/help/manual/C/gtk-doc-manual.sgml Thu Jan 1 01:00:00 1970 ++++ gtk-doc/help/manual/C/gtk-doc-manual.sgml Mon Nov 27 06:27:46 2000 +@@ -0,0 +1,288 @@ ++ ++]> ++ ++ ++ ++ ++ GTK-Doc Manual ++ 0.0 ++ ++ ++ Chris ++ Lyttle ++ ++
++ chris@wilddev.net ++
++
++
++ ++ Dan ++ Mueth ++ ++
++ d-mueth@uchicago.edu ++
++
++
++
++ ++ 2000 ++ Dan Mueth and Chris Lyttle ++ ++ ++ ++ ++ ++ ++ Permission is granted to copy, distribute and/or modify this ++ document under the terms of the GNU Free Documentation ++ License, Version 1.1 or any later version published by the Free Software Foundation with no Invariant Sections, no ++ Front-Cover Texts, and no Back-Cover Texts. A copy of the license ++ is included in . ++ ++ ++ Many of the names used by companies to distinguish their products and ++ services are claimed as trademarks. Where those names appear in any ++ GNOME documentation, and those trademarks are made aware to the members ++ of the GNOME Documentation Project, the names have been printed in caps ++ or initial caps. ++ ++ ++ ++
++ ++ ++ ++ ++ Introduction ++ ++ ++ This chapter introduces GTK-Doc and gives an overview of what it is and how it is used. ++ ++ ++ ++ What is GTK-Doc? ++ ++ ++ GTK-Doc is used to document C code. It is typically used to document the public ++ API of libraries, such as the GTK+ and Gnome libraries. But it can also be ++ used to document application code. ++ ++ ++ ++ ++ ++ ++ ++ How Does GTK-Doc Work? ++ ++ ++GTK-Doc works by using documentation of functions placed inside the source files in ++specially-formatted comment blocks, or documentation added to the template files ++which GTK-Doc uses (though note that GTK-Doc will only document functions that ++are declared in header files; it won't produce output for static functions). ++Currently GTK-Doc does not support placing documentation of other types of ++declarations, such as enums, macros, and structs, inside the source code. ++ ++ ++ ++GTK-Doc consists of a number of perl scripts, each performing a different step ++in the process. ++ ++ ++ ++There are 5 main steps in the process: ++ ++ ++ ++ ++ ++ ++Gathering information about the code. ++ ++ gtkdoc-scan scans the header files of the code looking for declarations of ++ functions, macros, enums, structs, and unions. It creates a list of the ++ declarations, placing them into sections according to which header file they ++ are in. The author can rearrange the sections, and the order of the ++ declarations within them, to produce the final desired order. ++ ++ gtkdoc-scanobj can also be used to dynamically query a library about ++ any GtkObject subclasses it exports. It saves information about each ++ object's position in the class hierarchy and about any GTK Args and Signals it ++ provides. ++ ++ ++ ++ ++ ++Generating the "template" files. ++ ++ gtkdoc-mktmpl creates a number of files in the tmpl/ subdirectory, using the ++ information gathered in the first step. (Note that this can be run ++ repeatedly. It will try to ensure that no documentation is ever lost.) ++ ++ ++ ++ ++ ++Writing the documentation. ++ ++ The author fills in the template files with the documentation for each ++function, macro, union etc. ++ ++ ++ ++ ++ ++Generating the SGML and HTML. ++ ++ gtkdoc-mkdb turns the template files into SGML files in the sgml/ ++ subdirectory.(If the source code contains documentation on functions, using the special ++ comment blocks, it gets merged in here.) ++ ++ gtkdoc-mkhtml turns the SGML files into HTML files in the html/ ++ subdirectory. ++ ++ ++ ++ ++ ++Fixing up cross-references between documents. ++ ++ After installing the HTML files, gtkdoc-fixxref can be run to fix up any ++ cross-references between separate documents. For example, the GTK+ ++documentation ++ contains many cross-references to types documented in the GLib manual. ++ ++ ++ ++ ++ ++ ++ ++ ++ Getting GTK-Doc ++ ++ ++ Requirements ++ ++ ++ ++Perl v5 - the main scripts are in Perl. ++ ++ ++DocBook DTD v3.0 - This is the DocBook SGML DTD. ++ http://www.ora.com/davenport ++ ++ ++Jade v1.1 - This is a DSSSL processor for converting SGML to various formats. ++ http://www.jclark.com/jade ++ ++ ++Modular DocBook Stylesheets ++ This is the DSSSL code to convert DocBook to HTML (and a few other ++ formats). It's used together with jade. ++ I've customized the DSSSL code slightly, in gtk-doc.dsl, to colour ++ the program code listings/declarations, and to support global ++ cross-reference indices in the generated HTML. ++ http://nwalsh.com/docbook/dsssl ++ ++ ++docbook-to-man - if you want to create man pages from the DocBook. ++ I've customized the 'translation spec' slightly, to capitalise section ++ headings and add the 'GTK Library' title at the top of the pages and the ++ revision date at the bottom. ++ There is a link to this on http://www.ora.com/davenport ++ NOTE: This does not work yet. ++ ++ ++ ++ ++ Installation ++ ++ ++ ++There is no standard place where the DocBook Modular Stylesheets are installed. ++ ++ ++gtk-doc's configure script searches these 3 directories automatically: ++ ++ ++ /usr/lib/sgml/stylesheets/nwalsh-modular (used by RedHat) ++ ++ ++ /usr/lib/dsssl/stylesheets/docbook (used by Debian) ++ ++ ++ /usr/share/sgml/docbkdsl (used by SuSE) ++ ++ ++ ++If you have the stylesheets installed somewhere else, you need to configure ++gtk-doc using the option: ++ ++ --with-dsssl-dir=<PATH_TO_TOPLEVEL_STYLESHEETS_DIR> ++ ++ ++ ++ ++ ++ ++ ++ ++ When to Use GTK-Doc ++ ++ ++ (FIXME) ++ ++ ++ ++ (What things GTK-Doc should, and shouldn't, be used for.) ++ ++ ++ ++ ++ ++ ++ About GTK-Doc ++ ++ ++ (FIXME) ++ ++ ++ ++ (History, authors, web pages, license, future plans, ++ comparison with other similar systems.) ++ ++ ++ ++ ++ ++ About this Manual ++ ++ ++ (FIXME) ++ ++ ++ ++ (who it is meant for, where you can get it, license) ++ ++ ++ ++ ++ ++ ++ ++ ++&FDL; ++ ++
++ ++ +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/tools/docpercentages.pl gtk-doc/tools/docpercentages.pl +--- gtk-doc-0.9/tools/docpercentages.pl Thu Jan 1 01:00:00 1970 ++++ gtk-doc/tools/docpercentages.pl Wed May 1 02:05:08 2002 +@@ -0,0 +1,155 @@ ++#!/usr/bin/perl -w ++ ++############################################################################# ++# Function : CreateValidSGMLID ++# Description : Creates a valid SGML 'id' from the given string. ++# NOTE: SGML ids are case-insensitive, so we have a few special ++# cases to avoid clashes of ids. ++# Arguments : $id - the string to be converted into a valid SGML id. ++############################################################################# ++ ++sub CreateValidSGMLID { ++ my ($id) = $_[0]; ++ ++ # Append -CAPS to all all-caps identifiers ++ ++ # Special case, '_' would end up as '' so we use 'gettext-macro' instead. ++ if ($id eq "_") { return "gettext-macro"; } ++ ++ if ($id !~ /[a-z]/) { $id .= "-CAPS" }; ++ ++ $id =~ s/[_ ]/-/g; ++ $id =~ s/[,\.]//g; ++ $id =~ s/^-*//; ++ $id =~ s/::/-/g; ++ ++ return $id; ++} ++ ++$BASEDIR=shift @ARGV; ++ ++print < ++ ModuleDocumented ++EOT ++ ++my $row = 0; ++while (@ARGV) { ++ my $percentage; ++ my $documented; ++ my $undocumented; ++ my @undocumented_symbols; ++ ++ my $module_name = shift @ARGV; ++ my $file = shift @ARGV; ++ my $indexfile = shift @ARGV; ++ ++ open DOCUMENTED, "<$file" or die "Cannot open $file: $!\n"; ++ ++ while () { ++ if (/(\d+)% (function|symbol) docs coverage/) { ++ $percentage = $1; ++ } elsif (/(\d+) (function|symbol)s documented/) { ++ $documented = $1; ++ } elsif (/(\d+) not documented/) { ++ $undocumented = $1; ++ } elsif (/^\s*(\w+)\s*$/) { ++ push @undocumented_symbols, $1; ++ } ++ } ++ ++ close DOCUMENTED; ++ ++ my $complete = defined $percentage && defined $documented && defined $undocumented; ++ if (!$complete) { ++ die "Cannot parse documentation status file $file\n"; ++ } ++ ++ my $total = $documented + $undocumented; ++ ++ my $directory; ++ ($directory = $indexfile) =~ s@/[^/]*$@@; ++ ++ $bgcolor = ($row % 2 == 0) ? "#f7ebd3" : "#fffcf4"; ++ ++ print < ++ $module_name ++ $documented ++ /$total ++ ($percentage%) ++EOT ++ if ($undocumented != 0) { ++ print <[missing] ++EOT ++ } ++ print < ++EOT ++ ++ # ++ # Print an index of undocumented symbols for this module ++ # ++ ++ @undocumented_symbols = sort { uc($a) cmp uc($b) } @undocumented_symbols; ++ ++ my $base = "$BASEDIR/$directory"; ++ ++ open INDEX_SGML, "<$base/index.sgml" or die "Cannot open $base/index.sgml: $!\n"; ++ ++ my %index_symbols; ++ ++ while () { ++ if (//) { ++ $index_symbols{$1} = $2; ++ } ++ } ++ ++ close INDEX_SGML; ++ ++ open UNDOC_OUT, ">$base/undocumented.html" or die "Cannot open $base/undocumented.html: $!\n"; ++ print UNDOC_OUT < ++ ++Undocumented functions in $module_name ++ ++ ++ ++ ++EOT ++ my $i = 0; ++ for $symbol (@undocumented_symbols) { ++ my $id = uc(CreateValidSGMLID($symbol)); ++ ++ my $output; ++ if (exists $index_symbols{$id}) { ++ my $href; ++ ++ ($href = $index_symbols{$id}) =~ s@.*/(.*)$@$1@; ++ ++ $output = qq($symbol); ++ } else { ++ $output = qq($symbol); ++ } ++ print UNDOC_OUT " \n"; ++ if ($i % 3 == 2) { ++ print UNDOC_OUT " \n"; ++ } ++ ++ $i++; ++ } ++ ++ print UNDOC_OUT < ++
$output
++ ++ ++EOT ++ close UNDOC_OUT; ++ $row++; ++} ++ ++print < ++EOT +diff -urN --exclude missing --exclude mkinstalldirs --exclude autogen.sh --exclude install-sh --exclude gtk-doc.spec --exclude aclocal.m4 --exclude configure --exclude Makefile.in --exclude INSTALL --exclude COPYING --exclude CVS --exclude .cvsignore gtk-doc-0.9/xml.dcl gtk-doc/xml.dcl +--- gtk-doc-0.9/xml.dcl Thu Jan 1 01:00:00 1970 ++++ gtk-doc/xml.dcl Sat May 18 01:45:25 2002 +@@ -0,0 +1,179 @@ ++" ++ PIC "?>" ++ SHORTREF NONE ++ ++ NAMES ++ SGMLREF ++ ++ QUANTITY NONE ++ ++ ENTITIES ++ "amp" 38 ++ "lt" 60 ++ "gt" 62 ++ "quot" 34 ++ "apos" 39 ++ ++ FEATURES ++ MINIMIZE ++ DATATAG NO ++ OMITTAG NO ++ RANK NO ++ SHORTTAG ++ STARTTAG ++ EMPTY NO ++ UNCLOSED NO ++ NETENABL IMMEDNET ++ ENDTAG ++ EMPTY NO ++ UNCLOSED NO ++ ATTRIB ++ DEFAULT YES ++ OMITNAME NO ++ VALUE NO ++ EMPTYNRM YES ++ IMPLYDEF ++ ATTLIST NO ++ DOCTYPE NO ++ ELEMENT NO ++ ENTITY NO ++ NOTATION NO ++ LINK ++ SIMPLE NO ++ IMPLICIT NO ++ EXPLICIT NO ++ OTHER ++ CONCUR NO ++ SUBDOC NO ++ FORMAL NO ++ URN NO ++ KEEPRSRE YES ++ VALIDITY TYPE ++ ENTITIES ++ REF ANY ++ INTEGRAL YES ++ APPINFO NONE ++ SEEALSO "ISO 8879:1986//NOTATION ++ Extensible Markup Language (XML) 1.0//EN" ++>