Re: [AD] grabber ._txification

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On Sun, 2004-10-24 at 21:52 +0100, Grzegorz Adam Hankiewicz wrote:
> > 
> > Hm. I see. So ._tx can as well be kept. Maybe the best is to just
> > document that internal structure.
> 
> It's all in makedoc.h really.
> 

Yes, so obviously, not just documenting, but refactoring is needed:

- ._tx should never contain platform specific commands (!html !rtf !
man ... ). Output plugins should descide themselves what they can do and
what not. This probably is the most serious flaw of ._tx. Of course this
can be explained by how it evolved.. in the beginning, it allowed a bit
more flexibility. But now it makes the code really ugly.

- Why have a TOC tree and a list of lines, which output plugins need to
synchronize? Much better would be to just have a single TOC, and each
section has a list of lines. Can also be explained by the fact that
the .txt format was the main output format at first, and the TOC was
seen as an extra hack.. but now it just complicates things (e.g.
arbitrary depth nesting).

I guess, if those two things could be fixed, makedoc.c as well as the
output plugins would get a lot shorter and simpler, and the produced
documentation would be improved as well. But this raises the old
question - how much easier is refactoring than writing a simple ._tx
parser and output plugins from scratch.

-- 
Elias Pschernig





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/