RTF语法
一个RTF文件由未格式化文本、控制字、控制符号和组组成。为了更容易的转换,一个标准的RTF文件应该仅包含7位ASCII码字符。RTF文件没有限制文件的行的最大长度。(再议:maximun line length是指行的字符数还是指文档的行数?)
An RTF file consists of unformatted text, control words, control symbols, and groups. For ease of transport, a standard RTF file can consist of only 7-bit ASCII characters. (Converters that communicate with Microsoft Word for Windows or Microsoft Word for the Macintosh should expect 8-bit characters.) There is no set maximum line length for an RTF file.
控制字是一种特殊的RTF用来标记打印机控制符的格式化命令,也是程序用来管理文档样式的格式化信息。(再议:措辞不好。)一个控制字不能超过32个字符。一个控制字类似以下形式:
A control word is a specially formatted command that RTF uses to mark printer control codes and information that applications use to manage documents. A control word cannot be longer than 32 characters. A control word takes the following form:
/LetterSequence<Delimiter>
以下Word 97-2000关键字并不遵守以上所说的关键字不允许包含任何的大写字母的要求。所有编辑器应该仍然遵守这个规定,而Word的下一个版本也将是关键字完全使用小写字母的版本。同时,建议那些查看器将以下关键字作为例外:
- /clFitText
- /clftsWidthN
- /clNoWrap
- /clwWidthN
- /tdfrmtxtBottomN
- /tdfrmtxtLeftN
- /tdfrmtxtRightN
- /tdfrmtxtTopN
- /trftsWidthAN
- /trftsWidthBN
- /trftsWidthN
- /trwWidthAN
- /trwWidthBN
- /trwWidthN
- /sectspecifygenN