Quote:
Originally Posted by Jellby
How would you know the "correct" output is :
Code:
This \textit{is} \textbf{\textit{in}deed} a strange idea!
and not:
Code:
This \textit{is \textbf{in}}\textbf{deed} a strange idea!
?
Of course, the real output, after a LaTeX run, would be indistinguishable. (Note that whether the whitespace must be italic or not may be debatable, but you should probably keep whatever was in the input file)
|
Hmmm... spaces should only remain "formatted" if both the previous and the next character is formatted exactly the same way. (This is taken care of by a formatting normalization plugin... and I failed to indicate this in my much simplified code.)
My example was therefore incorrect. But the same problem exists with this slight modification that is legal/plausible within the framework of pacify.
Code:
T h i s i s i n d e e d a s t r a n g e i d e a !
-- -- -- -- -- -I -I -I -I BI BI B- B- B- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
Quote:
Originally Posted by Jellby
I don't know what would be the "canonical" way of dealing with this, but I'd say you'll have to check proper nesting when generating LaTeX code: Whenever a feature is deactivated, check if it's the innermost feature (the last one to have been activated; if it is, close the brace, if it isn't, close the the inner features' braces, close the brace, and open the inner features again.
|
I might give this a try first actually. Thanks, Jellby.
- Ahi