We have success "editing" the fo programmatically, parsing out some
special strings our application embeds in the xml/text nodes. Not
something we're necessarily proud of, but it works perfectly well.
On 06/14/2011 09:54 AM, kalgon wrote:
You're right, I shouldn't have been talking so much about the context of what
I want to achieve, the only question that matters to me is: "is it possible
for an extension to programmatically add standard FO nodes to the main FO
tree, if yes how?". That is all I want to know and until now, nobody has
been able to answer that question. I see that FOP does have a lot of
extension points but very few documentation about their usage, and I don't
mind it this is not the correct way of doing things. I never started the
debate about that, I just wanted a simple plain answer to my question.
Regards,
Kalgon
Christopher R. Maden wrote:
On 06/14/2011 11:23 AM, kalgon wrote:
I understand but if we want to be strict, XSLT only transform from XML to
another format (often XML but also Text). In my case wiki syntax is not
XML
so we could say it shouldn't be transformed through XSLT.
Text nodes are part of XML... XSLT can handle processing the contents of
those text nodes.
However, it’s not always the best tool for doing that. I would probably
write something in your language-of-choice that takes in an XML tree and
writes it out identically, except for upgrading the free-text markup.
There are converters out there to do it... the Freebase BFG project used
one written by one of the original Wikipedia markup designers... see
<URL: https://secure.wikimedia.org/wikipedia/en/wiki/User:Magnus_Manske>.
This has gotten off-topic for FOP. If you decide to do this in XSLT,
see<URL: http://www.mulberrytech.com/xsl/xsl-list/>. Otherwise, see
the discussion fora for whatever other programming language you’re using.
~Chris
--
Chris Maden, text nerd<URL: http://crism.maden.org/>
“Before I built a wall I’d ask to know / What I was walling in or
out, / And to whom I was like to give offence.” — RF, Mending Wall
GnuPG Fingerprint: C6E4 E2A9 C9F8 71AC 9724 CAA3 19F8 6677 0077 C319
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]