Split docs into several files, for ggap

This commit is contained in:
Yevgen Muntyan 2007-09-22 20:06:43 -05:00
parent 02e6446b2d
commit daf6fa492d
14 changed files with 183 additions and 131 deletions

View File

@ -30,6 +30,7 @@ EXTRA_DIST = \
cygwin-configure \ cygwin-configure \
makewin \ makewin \
COPYING.GPL \ COPYING.GPL \
COPYING \
LICENSE \ LICENSE \
THANKS \ THANKS \
intltool-extract.in \ intltool-extract.in \
@ -53,8 +54,10 @@ SUBDIRS += tests
endif endif
if MOO_ENABLE_HELP if MOO_ENABLE_HELP
if MOO_BUILD_DOCS
SUBDIRS += doc SUBDIRS += doc
endif endif
endif
ACLOCAL_AMFLAGS = -I m4 ACLOCAL_AMFLAGS = -I m4

View File

@ -1,5 +1,14 @@
docbook_files = \
medit.docbook \
license.docbook \
editor-editing.docbook \
editor-open-save.docbook \
editor-plugins.docbook \
editor-prefs.docbook \
editor-tools.docbook
EXTRA_DIST = \ EXTRA_DIST = \
manual.docbook \ $(docbook_files) \
manual.xsl \ manual.xsl \
help.xsl \ help.xsl \
help.css help.css
@ -8,16 +17,22 @@ all: build-help manual.html
build-help: help/help.css build-help: help/help.css
stamp-help: manual.docbook help.xsl DISTCLEANFILES = LGPL.xml
# Stupid form feed characters and stupid XML and stupid xsltproc!!!
LGPL.xml: $(top_srcdir)/COPYING
$(srcdir)/txt2xml $(top_srcdir)/COPYING > LGPL.xml.tmp && \
mv LGPL.xml.tmp LGPL.xml
stamp-help: $(docbook_files) help.xsl LGPL.xml
rm -f help/*.html && \ rm -f help/*.html && \
$(mkdir_p) help && \ $(mkdir_p) help && \
xsltproc --stringparam base.dir $(builddir)/help/ $(srcdir)/help.xsl $(srcdir)/manual.docbook && \ xsltproc --xinclude --path "." --stringparam base.dir $(builddir)/help/ $(srcdir)/help.xsl $(srcdir)/medit.docbook && \
echo stamp > stamp-help echo stamp > stamp-help
help/help.css: stamp-help help.css help/help.css: stamp-help help.css
cp $(srcdir)/help.css help/ cp $(srcdir)/help.css help/
manual.html: manual.docbook manual.xsl manual.html: $(docbook_files) manual.xsl LGPL.xml
xsltproc --output manual.html $(srcdir)/manual.xsl $(srcdir)/manual.docbook xsltproc --xinclude --path "." --output manual.html $(srcdir)/manual.xsl $(srcdir)/medit.docbook
############################################################################# #############################################################################
# Standard automake stuff # Standard automake stuff
@ -35,12 +50,3 @@ mostlyclean:
rm -fr help stamp-help manual.html rm -fr help stamp-help manual.html
distclean: clean distclean: clean
rm -f Makefile Makefile.in rm -f Makefile Makefile.in
# all: chunks single
#
# clean:
# rm -fr manual/ *.html stamp-chunks
# single: manual.html
# manual.html: manual.docbook manual.xsl
# xsltproc --output manual.html manual.xsl manual.docbook

View File

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?>
<section id="sect-editing-text">
<title>Editing text</title>
<section id="dialog-replace">
<title>dialog-replace</title>
blah blah blah
</section>
<section id="dialog-find">
<title>dialog-find</title>
blah blah blah
</section>
<section id="dialog-find-in-files">
<title>dialog-find-in-files</title>
blah blah blah
</section>
<section id="dialog-find-file">
<title>dialog-find-file</title>
blah blah blah
</section>
</section>

View File

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?>
<section id="sect-opening-and-saving">
<title>Opening and Saving Files</title>
<section id="dialog-open">
<title>dialog-open</title>
blah blah blah
</section>
<section id="dialog-save">
<title>dialog-save</title>
blah blah blah
</section>
<section id="file-selector">
<title>file-selector</title>
blah blah blah
</section>
<section id="app-prefs-file-selector">
<title>app-prefs-file-selector</title>
blah blah blah
</section>
</section>

View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<section id="sect-plugins">
<title>Plugins</title>
<section id="app-prefs-plugins">
<title>app-prefs-plugins</title>
blah blah blah
</section>
</section>

10
doc/editor-prefs.docbook Normal file
View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<section id="app-prefs-dialog">
<title>Preferences</title>
<section id="app-prefs-langs-and-filters">
<title>app-prefs-langs-and-filters</title>
blah blah blah
</section>
</section>

5
doc/editor-sections.xml Normal file
View File

@ -0,0 +1,5 @@
<xi:include href="editor-open-save.docbook" xmlns:xi="http://www.w3.org/2001/XInclude"/>
<xi:include href="editor-editing.docbook" xmlns:xi="http://www.w3.org/2001/XInclude"/>
<xi:include href="editor-prefs.docbook" xmlns:xi="http://www.w3.org/2001/XInclude"/>
<xi:include href="editor-tools.docbook" xmlns:xi="http://www.w3.org/2001/XInclude"/>
<xi:include href="editor-plugins.docbook" xmlns:xi="http://www.w3.org/2001/XInclude"/>

10
doc/editor-tools.docbook Normal file
View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<section id="sect-user-defined-tools">
<title>User-defined Tools</title>
<section id="app-prefs-user-tools">
<title>app-prefs-user-tools</title>
blah blah blah
</section>
</section>

20
doc/license.docbook Normal file
View File

@ -0,0 +1,20 @@
<appendix id="license">
<title>License</title>
<para>
&app; as a whole is distributed under the terms of GNU General Public License,
version 2, but most of its code is released under the GNU Lesser General Public
License. Full text of these licenses and list of licenses and acknowledgements for
third-party software incorporated in &app; can be found in this section.
</para>
<sect1 id="gpl">
<title>GNU General Public License</title>
<programlisting><xi:include href="../COPYING.GPL" parse="text" encoding="UTF-8"
xmlns:xi="http://www.w3.org/2001/XInclude"/></programlisting>
</sect1>
<sect1 id="lgpl">
<title>GNU Lesser General Public License</title>
<xi:include href="LGPL.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
</sect1>
</appendix>

View File

@ -1,104 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY appversion "0.9.0">
<!ENTITY manrevision "0.1">
<!ENTITY date "Septermber 2007">
<!ENTITY app "medit">
<!-- <!ENTITY chap SYSTEM "chap.docbook">-->
]>
<article>
<articleinfo>
<title>&app; manual</title>
</articleinfo>
<sect1 id="sect-getting-started">
<title>Getting Started</title>
</sect1>
<sect1 id="sect-opening-and-saving">
<title>Opening and Saving Files</title>
<sect2 id="dialog-open">
<title>dialog-open</title>
blah blah blah
</sect2>
<sect2 id="dialog-save">
<title>dialog-save</title>
blah blah blah
</sect2>
<sect2 id="file-selector">
<title>file-selector</title>
blah blah blah
</sect2>
<sect2 id="app-prefs-file-selector">
<title>app-prefs-file-selector</title>
blah blah blah
</sect2>
</sect1>
<sect1 id="sect-editing-text">
<title>Editing text</title>
<sect2 id="dialog-replace">
<title>dialog-replace</title>
blah blah blah
</sect2>
<sect2 id="dialog-find">
<title>dialog-find</title>
blah blah blah
</sect2>
<sect2 id="dialog-find-in-files">
<title>dialog-find-in-files</title>
blah blah blah
</sect2>
<sect2 id="dialog-find-file">
<title>dialog-find-file</title>
blah blah blah
</sect2>
</sect1>
<sect1 id="app-prefs-dialog">
<title>Preferences</title>
<sect2 id="app-prefs-langs-and-filters">
<title>app-prefs-langs-and-filters</title>
blah blah blah
</sect2>
</sect1>
<sect1 id="sect-plugins">
<title>Plugins</title>
<sect2 id="app-prefs-plugins">
<title>app-prefs-plugins</title>
blah blah blah
</sect2>
</sect1>
<sect1 id="sect-user-defined-tools">
<title>User-defined Tools</title>
<sect2 id="app-prefs-user-tools">
<title>app-prefs-user-tools</title>
blah blah blah
</sect2>
</sect1>
<para role="generated-date">This document was generated
<?dbtimestamp format="Y-m-d H:M:S"?>.</para>
</article>

28
doc/medit.docbook Normal file
View File

@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY appversion "0.9.0">
<!ENTITY manrevision "0.1">
<!ENTITY date "Septermber 2007">
<!ENTITY app "medit">
<!ENTITY editor-sections SYSTEM "editor-sections.xml">
<!ENTITY license SYSTEM "license.docbook">
]>
<article>
<articleinfo>
<title>&app; manual</title>
</articleinfo>
<section id="sect-getting-started">
<title>Getting Started</title>
</section>
&editor-sections;
&license;
<para role="generated-date">This document was generated
<?dbtimestamp format="Y-m-d H:M:S"?>.</para>
</article>

5
doc/txt2xml Executable file
View File

@ -0,0 +1,5 @@
#!/bin/sh
echo "<programlisting>"
sed -e 's/\f//' -e 's/&/\&amp;/g' -e 's/</\&lt;/g' -e 's/>/\&gt;/g' \
-e 's/"/\&quot;/g' -e "s/'/\&\#39;/g" "$1"
echo "</programlisting>"

View File

@ -23,7 +23,7 @@ AC_DEFUN([_MOO_AC_CHECK_XSLT_DOCBOOK],[
</sect1> </sect1>
</article> </article>
EOFEOF EOFEOF
if ($XSLTPROC http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl conftest.docbook 2>/dev/null >/dev/null); then if ($XSLTPROC --nonet http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl conftest.docbook 2>/dev/null >/dev/null); then
AC_MSG_RESULT([yes]) AC_MSG_RESULT([yes])
rm -f conftest.docbook rm -f conftest.docbook
$1 $1
@ -42,6 +42,7 @@ AC_DEFUN([MOO_DOCS],[
AC_HELP_STRING(--disable-help, [Disable building html help files (default = auto).]), AC_HELP_STRING(--disable-help, [Disable building html help files (default = auto).]),
[:],[enable_help=auto]) [:],[enable_help=auto])
if test "x$MOO_ENABLE_HELP" != xyes; then
if test "x$enable_help" = xauto -o "x$enable_help" = xyes; then if test "x$enable_help" = xauto -o "x$enable_help" = xyes; then
_MOO_AC_CHECK_XSLT_DOCBOOK([_moo_xslt_working=yes],[_moo_xslt_working=no]) _MOO_AC_CHECK_XSLT_DOCBOOK([_moo_xslt_working=yes],[_moo_xslt_working=no])
if test $_moo_xslt_working = yes; then if test $_moo_xslt_working = yes; then
@ -52,8 +53,16 @@ AC_DEFUN([MOO_DOCS],[
AC_MSG_ERROR([xsltproc will not work]) AC_MSG_ERROR([xsltproc will not work])
fi fi
fi fi
fi
if test "x$enable_help" != xyes; then
MOO_BUILD_DOCS=no
elif test "x$MOO_BUILD_DOCS" = x; then
MOO_BUILD_DOCS=yes
fi
AM_CONDITIONAL(MOO_ENABLE_HELP, test "x$enable_help" = xyes) AM_CONDITIONAL(MOO_ENABLE_HELP, test "x$enable_help" = xyes)
AM_CONDITIONAL(MOO_BUILD_DOCS, test "x$MOO_BUILD_DOCS" = xyes)
if test "x$enable_help" = xyes; then if test "x$enable_help" = xyes; then
AC_DEFINE(MOO_ENABLE_HELP, [1], [enable help functionality]) AC_DEFINE(MOO_ENABLE_HELP, [1], [enable help functionality])
fi fi

View File

@ -170,7 +170,7 @@ show_license (void)
#define COPYRIGHT_SYMBOL "\302\251" #define COPYRIGHT_SYMBOL "\302\251"
static const char *copyright = COPYRIGHT_SYMBOL " 2004-2007 Yevgen Muntyan"; static const char copyright[] = COPYRIGHT_SYMBOL " 2004-2007 Yevgen Muntyan";
static gboolean static gboolean