Forum Bugs

Error in absolute positioning

felipellrocha
Hey guys. I'm trying to use MathJax to render some math for me, but it seems that prince doesn't like the html that MathJax spits out.
I attached a screenshot of both chrome's and prince's rendering of the same part of the page. My intuition is that absolute positioning is not working 100%, but I'm not sure. What do you guys think?

<span class="MathJax" id="MathJax-Element-1-Frame" role="textbox" aria-readonly="true" style=""><nobr><span class="math" id="MathJax-Span-1" style="width: 3.516em; display: inline-block; "><span style="display: inline-block; position: relative; height: 0px; font-size: 116%; width: 3.017em; "><span style="position: absolute; clip: rect(1.802em 1000em 3.043em -0.437em); top: -2.64em; left: 0em; "><span class="mrow" id="MathJax-Span-2"><span class="mo" id="MathJax-Span-3" style="font-family: STIXMathJax_Main; ">(</span><span class="msubsup" id="MathJax-Span-4"><span style="display: inline-block; position: relative; height: 0px; width: 0.988em; "><span style="position: absolute; clip: rect(2.037em 1000em 2.813em -0.512em); top: -2.64em; left: 0em; "><span class="mi" id="MathJax-Span-5" style="font-family: STIXMathJax_Main; font-style: italic; ">x<span style="display: inline-block; overflow-x: hidden; overflow-y: hidden; height: 1px; width: 0.003em; "></span></span><span style="display: inline-block; width: 0px; height: 2.64em; "></span></span><span style="position: absolute; top: -2.005em; left: 0.536em; "><span class="mn" id="MathJax-Span-6" style="font-size: 70.7%; font-family: STIXMathJax_Main; ">1</span><span style="display: inline-block; width: 0px; height: 2.155em; "></span></span></span></span><span class="mo" id="MathJax-Span-7" style="font-family: STIXMathJax_Main; ">,</span><span class="msubsup" id="MathJax-Span-8" style="padding-left: 0.188em; "><span style="display: inline-block; position: relative; height: 0px; width: 0.991em; "><span style="position: absolute; clip: rect(2.037em 1000em 3.008em -0.509em); top: -2.64em; left: 0em; "><span class="mi" id="MathJax-Span-9" style="font-family: STIXMathJax_Main; font-style: italic; ">y</span><span style="display: inline-block; width: 0px; height: 2.64em; "></span></span><span style="position: absolute; top: -1.914em; left: 0.539em; "><span class="mn" id="MathJax-Span-10" style="font-size: 70.7%; font-family: STIXMathJax_Main; ">1</span><span style="display: inline-block; width: 0px; height: 2.155em; "></span></span></span></span><span class="mo" id="MathJax-Span-11" style="font-family: STIXMathJax_Main; ">)</span></span><span style="display: inline-block; width: 0px; height: 2.64em; "></span></span></span><span style="border-left-width: 0em; border-left-style: solid; border-left-color: initial; display: inline-block; overflow-x: hidden; overflow-y: hidden; width: 0px; height: 1.189em; vertical-align: -0.342em; "></span></span></nobr></span>
  1. Screen Shot 2014-07-08 at 12.47.57 AM.png18.1 kB
    Chrome
  2. Screen Shot 2014-07-08 at 12.48.12 AM.png20.1 kB
    Prince
mikeday
It's a width issue causing line-break, and Prince not supporting <nobr> by default. You can workaround this by adding a CSS rule:
nobr { white-space: nowrap }
felipellrocha
Worked like a charm! :) Thanks, mikeday!
mikeday
We have added this rule to the default HTML style sheet in Prince 10. Thanks for letting us know about the issue. :)