Directional quotation marks broken by inline formatting tags
Here's an text macro cleanup that highlights several issues:
Rinsed html output:
<h4 style="font-family: Times New Roman; text-align: center">“<i>Desabilitado</i>:”</h4>
Text macro cleanup output:
<h3 style="font-family: Times New Roman; text-align: center">"<i>Desabilitado:”</i>”</h3>
But it should really be:
<h3 style="font-family: Times New Roman; text-align: center">“<i>Desabilitado:</i>”</h3>
Issues:
-
Because the open quote is by itself, the macro cleans it up to a straight quote, since it doesn't know what direction it should go. The quotation mark should recognize that it's next to a word, even across inline formatting tags, and be assigned a direction accordingly.
-
This shouldn't apply after the first issue is fixed, but if the text cleanup does encounter a directional single or double quotation mark all by itself (e.g.
<p>”</p>
), with no clue as to which way it should face, it replaces it with a straight single or double quotation mark. I'd prefer that in these instances, it just sticks with whatever direction the original quotation mark was. If this is tricky to do though, let's leave it alone. -
We end up with an extra closing quotation mark. I am guessing it's because the colon is brought into the italics tag (coercing punctionation to match prior word's formatting), but it looks like the quotation mark comes along for the ride, too. Instead, it should be left where it is outside the italic tags, as it's not one of the punctuation marks that rule should apply to.