RtfPipe
RtfPipe copied to clipboard
Parser: Newline whitespace characters are not ignored.
New-line whitespace characters are supposed to be ignored from processing, unless they are added as control words. \n and \r is treated as a TextToken.
That is to say:
{
\rtf1
this is new text\par
}
Is parsed differently than:
{\rtf1 this is new text\par}
When the results should be equivalent.
For reference, RTF Spec, Pg. 145:
A carriage return (character value 13) or line feed (character value 10) is treated as a \par
control if the character is preceded by a backslash. You must include the backslash; otherwise,
RTF ignores the control word. (You may also want to insert a carriage-return/line feed pair
without backslashes at least every 255 characters for better text transmission over
communication lines.)
More information: Any text after a newline is considered a plain text until a control symbol is encountered.