ParagraphManagerclass | output.t[620] |
Superclass Tree | Subclass Tree | Global Objects | Property Summary | Method Summary | Property Details | Method Details |
We also process the zero-spacing paragraph, <.P0>. This doesn't generate any output, but otherwise acts like a paragraph break in that it suppresses any paragraph breaks that immediately follow.
The special marker <./P0> cancels the effect of a <.P0>. This can be used if you want to ensure that a newline or paragraph break is displayed, even if a <.P0> was just displayed.
Our special processing ensures that paragraph tags interact with one another and with other display elements specially:
- A run of multiple consecutive paragraph tags is treated as a single paragraph tag. This property is particularly important because it allows code to write out a paragraph marker without having to worry about whether preceding code or following code add paragraph markers of their own; if redundant markers are found, we'll filter them out automatically.
- We can suppress paragraph markers following other specific sequences. For example, if the paragraph break is rendered as a blank line, we might want to suppress an extra blank line for a paragraph break after an explicit blank line.
- We can suppress other specific sequences following a paragraph marker. For example, if the paragraph break is rendered as a newline plus a tab, we could suppress whitespace following the paragraph break.
The paragraph manager should always be instantiated with transient instances, because this object's state is effectively part of the interpreter user interface, which doesn't participate in save and restore.
class
ParagraphManager : OutputFilter
ParagraphManager
OutputFilter
object
mainParagraphManager
menuParagraphManager
leadingMultiPat
leadingSinglePat
renderAfterInput
renderText
suppressAfter
suppressBefore
leadingMultiPat | output.t[656] |
leadingSinglePat | output.t[657] |
renderAfterInput | output.t[631] |
renderText | output.t[625] |
suppressAfter | output.t[653] |
suppressBefore | output.t[641] |
filterText (ostr, txt) OVERRIDDEN | output.t[661] |