How To Change Padding Of Math In MathJax?
Like, when I have my piece of Math in my div, it would look like this, where I have set the padding of my div to 0: So, is there a way to change the value of the padding of the ma
Solution 1:
Found from here (and to believe I answered this question, and forgot about it):
MathJax.Hub.Config({
jax: ["input/TeX","output/HTML-CSS"],
displayIndent: "2em"
});
Solution 2:
The simplest way to customize this would be call MathJax.Hub.Config(...)
before you load the MathJax config file in your header. For example:
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
"HTML-CSS": {
styles: {
".MathJax nobr": {
padding: "0.2em 0.2em"
},
}
}
});
</script>
<script type="text/javascript" src="/path/to/MathJax.js?config=TeX-AMS_HTML" charset="utf-8"></script>
Where you change the path to your MathJax installation.
Alternatively, you can either modify an existing config file or setup your own config via the method outlined here: http://docs.mathjax.org/en/latest/configuration.html#config-files
Post a Comment for "How To Change Padding Of Math In MathJax?"