mathjax / MathJax-node

MathJax for Node
Apache License 2.0
615 stars 97 forks source link

Make sure padding and margin can accept 0 to mean 0px. #244 #245

Closed dpvc closed 8 years ago

dpvc commented 8 years ago

Make sure padding and margin can accept 0 to mean 0px. Resolves issue #244

pkra commented 8 years ago

I can't really comment on what it does but the code looks good to me.

pkra commented 8 years ago

@dpvc I still see the issue (though it's not as bad as before). Example: http://codepen.io/pkra/pen/YWqRLB.

I'm using MathJax's develop branch and this branch.

dpvc commented 8 years ago

I still see the issue (though it's not as bad as before).

That turns out to be independent of this PR, so I'd recommend merging this for now. The problem you are having is very dependent on the font size and zoom level (for me), and is probably due to rounding issues. The labels are in a separate column that has spacing added to (theoretically) make it match the table row sizes, but the imprecise knowledge of the em and ex size affect this, as does the fact that the table is made of pieces with different heights than the labels, so the cumulative around-off error is different. Also, the error is additive, so it gets more and more several as you go down the table.

I'm not sure how to fix it, but any solution will have to be in the CommonHTML code, not mathjax-node. I'll see what I can come up with.

pkra commented 8 years ago

I'm not sure how to fix it, but any solution will have to be in the CommonHTML code, not mathjax-node. I'll see what I can come up with.

Will you open an issue upstream?

dpvc commented 8 years ago

Done. mathjax/MathJax#1532