Last modified: 2014-08-08 15:41:26 UTC
Please add this definition: span.texhtml { white-space: nowrap } It is needed because PNG formulae do not wrap, so neither should they in HTML.
Fixed in r23649.
On consideration, reverted in r24692. Isn't the correct behavior for inline LaTeX to wrap normally? I'm almost certain that's the case.
1. MediaWiki need not obey LaTeX conventions to the point. LaTeX is for typesetting high-quality articles; MediaWiki is for looking up knowledge. The browser space is not as limited as the paper space is (especially in scientific periodicals). 2. TeX normally wraps inline mathematics but only inside blocks. If you insist, you can follow this convention exactly by means of the following rule: span.html span { white-space:nowrap } Please reconsider.
What do you mean by "only inside blocks"? What elements is that selector meant to select? (Did you mean span.texhtml?)
My latest comment contains two mistakes, of course. TeX wraps only *outside* of any TeX block in math mode. The rule span.texhtml span { white-space:nowrap } inhibits breaking lines within spans inside formulas, to match the TeX behaviour to the point. The rule span.texhtml { white-space:nowrap } inhibits breaking formulas anywhere.
What's an example of where this would make a difference again?
<?xml version="1.0" ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" [ <!ENTITY sample "<br />Consider the following equation: <span class='texhtml' >0 = <span >0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0</span ></span >" > ]><html xmlns="http://www.w3.org/1999/xhtml" ><head ><title >Illustration to MediaWiki Bug 10438</title ><style type="text/css" > .texhtml { background: yellow; } .nowrap .texhtml { white-space: nowrap } .outerwrap .texhtml span { white-space: nowrap } </style ></head ><body ><p >The following list shows the effect of various style declarations on how inline formulae are rendered. Play with the window width to make the equations wrap.</p ><p >default: &sample;</p ><p class="nowrap" >texvc: &sample;</p ><p class="outerwrap" >TeX: &sample;</p ></body ></html >
Of course the outermost classes are artificial to put all formula presentation modes into the same document. I am also asking for the rule span.texhtml span.composite { word-spacing: -.1ex } for typesetting things like "arc sin <var >x</var >". See <http://en.wikipedia.org/wiki/Template:Macomp>.
And Microsoft Internet Explorer needs span.texhtml { font-family: Cambria, serif } because "serif" resolves to Times New Roman which does not have combining diacritical marks (only precomposed characters).
Actually Microsoft Internet Explorer needs span.texhtml { font-family: "Cambria Math", serif } /* otherwise it cannot display ⟨ and ⟩ */ span.texhtml var, span.texhtml i { font-family: Cambria, serif } /* because Cambria Math does not have an italic version and Times New Roman does not have combining diacritical marks */
seems to be fixed