|
Boost : |
From: Joel de Guzman (joel_at_[hidden])
Date: 2006-08-01 10:28:19
Julio M. Merino Vidal wrote:
> Hi,
>
> I've just started adding example programs to my SoC project and I was
> wondering if there was a way to bundle their code into the
> documentation (which I'm writing with Quickbook). Of course I can
> hyperlink to the source file, but this could be useless in printed
> documentation. Also I'd copy&paste the C++ code in the qbk file, but
> that is asking for trouble (desyncronization). Hence, I think it'd be
> useful to be able to include this code in the final document straight
> from the qbk file.
>
> I tried with the [include ...] command but it did not work as I
> expected. And indenting it in the .qbk file so that it was formatted
> as source code made things worse because the inclusion had no effect
> at all. Similarly, [xinclude ...] cannot work either for obvious
> reasons (source code is not XML).
>
> So... I added a 'cinclude' tag (standing for code include) to
> quickbook which, given a file, includes it in the documentation marked
> up (and colored!) appropriately. The implementation is attached. It
> can very well be flawed as it is basically a copy&paste of other parts
> of the code, but so far seems to work.
>
> Any chance this -- or something similar -- can be integrated?
Certainly. I might need to ask for some more cinclude related
features. Are you willing to do some more coding? Please email
me.
Regards,
-- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk