- RTF Overview
- What the different modules do
RTF is a format that can express complex formatted documents in ASCII. This document expects that you have some familiarity with it, and are familiar with the terms 'text field', 'control word', and 'group' as they apply to RTF.
Sean Burke has very usefully written:
An online introduction to RTF
The RTF Pocket Guide
RTF::Parser is the foundation class. It's essentially a wrapper for <RTF::Tokenizer> that executes events that you define as it comes across different parts of the RTF document - it has handlers for when groups open, when they close, when we come across a control word, and so on.
RTF::Control sub-classes RTF::Parser. It defines a number of events for which you can write handlers that are specifically geared towards people who want to write converters - where RTF::Parser things in terms of control words and groups, RTF::Control thinks in terms of paragraphs, and formatting properties for text.
RTF::TEXT::Converter and RTF::HTML::Converter sub-class RTF::Control, and are essentially documents that specify how to react to RTF::Control's events to spit RTF out as text and HTML respectively. You can also use them to inline RTF conversion to text or HTML in your documents.
Copyright 2004 Pete Sergeant.
This documentation is free documentation; you can redistribute it and/or modify it under the same terms as Perl itself.
This work was carried out under a grant generously provided by The Perl Foundation - give them money!