> But, I would like to integrate the generated Latex files within an
> already existing Latex project (more precise: in the appendix of a
> book). In particular I want the Sphinx-generated documentation pages
> to have the header, footer and section heading styles of the parent
> document. I guess I could somehow transfer the relevant parts by
> manually removing unneeded stuff and adjusting various options in the
> tex files generated by Sphinx. However, probably this is going to be a
> very tedious fiddling taking too much of my time (thinking of
> conflicting packages and options I have to detect and fix). Ideally
> Sphinx would just output some package and command declarations I can
> include in the preamble of the existing LaTeX document and the actual
> content which can be included anywhere in the document area.

Hi, I was doing the same half year ago in my thesis. What I did was to
cut the sphinx-generated LaTeX source file in pieces, and then include
them at appropriate places; a part of the sphinx-generated preamble
was to be included in the global preamble.

I had to replace a few things with regexps, such as hyper-references
to sphinx bibliography by \cite{...} (Sphinx references were generated
from a .bib files, and those .bib files were then included directly in
the resulting doc).

You can browse the code at 
http://bazaar.launchpad.net/~eudoxos/+junk/thesis/files
; you will be particularly interested in build.py (which cuts the
sphinx doc in chunks, does the substitutions and saves them) and
thesis.tex, which is the master document. The sphinx preamble is
included at line 12, and the sections from sphinx start from 190.

The final pdf is available from 
http://beta.arcig.cz/~eudoxos/smilauer2010-phd-thesis.pdf
, the sphinx sections are chapters 5, 6, 7 (pg. 69-148) and appendices
C, D (161-240). The HTML sphinx doc is (the version online is updated,
so does not correspond exactly) at http://www.yade-dem.org/sphinx/
(chapter 2 of the thesis was originally written in LaTeX, then
converted to sphinx, so is part of the HTML docs now).

HTH, Vaclav

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-...@googlegroups.com.
To unsubscribe from this group, send email to 
sphinx-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en.

Reply via email to