The call on the primitive (scanCharactersFrom:to:in:rightX:) will be interrupted according to an array of stop conditions passed to the scanner at which time the code to handle the stop condition is run and the call on the primitive continued until a stop condition returns true (which means the line has terminated). leftInRun is the # of characters left to scan in the current run; when 0, it is time to call setStopConditions.
The central display routine. The call on the primitive
(scanCharactersFrom:to:in:rightX:) will be interrupted according to an
array of stop conditions passed to the scanner at which time the code to
handle the stop condition is run and the call on the primitive continued
until a stop condition returns true (which means the line has
terminated).
See the note in CharacterScanner>>characterNotInFont.
All fonts have an illegal character to be used when a character is not
within the font's legal range. When characters out of ranged are
encountered in scanning text, then this special character indicates the
appropriate behavior. The character is usually treated as a unary
message understood by a subclass of CharacterScanner.
This condition will sometimes be reached 'legally' during display, when,
for instance the space that caused the line to wrap actually extends over
the right boundary. This character is allowed to display, even though it
is technically outside or straddling the clipping ectangle since it is in
the normal case not visible and is in any case appropriately clipped by
the scanner.
The end of a run in the display case either means that there is actually
a change in the style (run code) to be associated with the string or the
end of this line has been reached.
Each space is a stop condition when the alignment is right justified.
Padding must be added to the base width of the space according to
which space in the line this space is and according to the amount of
space that remained at the end of the line when it was composed.