http://qs1969.pair.com?node_id=970750


in reply to Make a Markup Method in Perl?

I know that you could check to see if the tag is around the text easily. It's Regular Expressions of course.

That's the hard way to do it. The easy way to do it is to write a parser to transform text into a data structure, then walk the data structure to transform it into another data structure from which it's easy to emit the right text.


Improve your skills with Modern Perl: the free book.

Replies are listed 'Best First'.
Re^2: Make a Markup Method in Perl?
by stevieb (Canon) on May 16, 2012 at 06:53 UTC

    this :)

Re^2: Make a Markup Method in Perl?
by perl.j (Pilgrim) on May 16, 2012 at 09:52 UTC
    OK. But how can I change the layout of the text?
    --perl.j

      You're going to have to learn the details of RTF or the API of a module which produces RTF.

      OK. But how can I change the layout of the text?

      Flip your monitor? Seems to work :)