OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Re: [docbook-apps] Framemaker to DocBook conversion

On 10/25/06, Camille Bégnis <camille@neodoc.biz> wrote:
> I've been crawling archives and websites, found 2 threads dating back
> from 1999 and 2005, but nothing definitive. FM hacking looks not quite
> appealing.

Many of the earlier attempts using XSLT1 (which were probably what you
found with Google) failed because of the pain of grouping in XSLT1.

> Looking at the XML output from FM, it looks quite decent, the
> hierarchical structure could even be reconstructed with a bit of XSL
> neurons burning I believe.

What version of FrameMaker do you have? Recent versions have more XML
support, but I haven't played with any since 5.5.

> So did someone found a reliable FM -> DocBook conversion method?

For some subset of documents in a very strictly applied template, yes,
I have. Will there every be a reasonable
All-Frame-Documents->Reasonable-DocBook? Never.

How rigorously do your input documents follow a template? How much
format tweaking not using styles? Do you have a good understanding of
how all of the Paragraph Styles will map to DocBook elements or are
many of them purely visual?

Here's my suggestion on how to approach it:
* Get your Frame into full-fidelity XML (prolly very flat)
** We eventually wrote a MIF->XML parser (not that hard for someone
with experience), but there may be better options for recent versions
of Frame or consider the Perl modules that build a MIF tree (which is
easy to serialize as XML)
* Do simple A->B mapping of Frame's \\xNN chars and <Char>s
** Consider generating this stylesheet, as you'll have to add a ton
* Write a lot of XSLT2 stylesheets, each of which attacks something
needing greater depth (sidebars, examples, lists [especially lists,
this is what will make or break you]) with XSLT2 grouping
* Figure out how to handle index terms (this is hard, I still don't
know if we've solved it the right way)
* Do simple A->B mapping of elements into DocBook at the end
** Considering generating this document, as above

For someone experienced with the input documents, XSLT2, and document
transformation, I bet you could have something working in 80 hours.

For reference, I have 41 helper stylesheets, one stylesheet chainer
(to run the 41), two XSLT2 libraries, and one generated stylesheet
(style mapping), with a total of 4000 lines in the project.


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]