Sha256: 78ce34ff6b775f79c282cad30baa6d4a376ae130e0d160dbe51866fa1851ed22

Contents?: true

Size: 1.57 KB

Versions: 12

Compression:

Stored size: 1.57 KB

Contents

.. _configure-mml2jax:

************************
The mml2jax Preprocessor
************************

The options below control the operation of the `mml2jax` preprocessor
that is run when you include ``"mml2jax.js"`` in the `extensions` array
of your configuration.  They are listed with their default values.  To
set any of these options, include a ``mml2jax`` section in your
:meth:`MathJax.Hub.Config()` call.  For example

.. code-block:: javascript

    MathJax.Hub.Config({
      mml2jax: {
        preview: "none"
      }
    });

would set the ``preview`` parameter to ``"none"``.

.. describe:: preview: "alttext"

    This controls whether `mml2jax` inserts ``MathJax_Preview`` spans
    to make a preview available, and what preview to use, when it
    locates mathematics on the page.  The default is ``"alttext"``,
    which means use the ``<math>`` tag's ``alttext`` attribute as the
    preview (visible until it is processed by MathJax), if the tag has
    one.  Set it to ``"none"`` to prevent the previews from being
    inserted (the math will simply disappear until it is typeset).
    Set it to an array containing the description of an HTML snippet
    in order to use the same preview for all equations on the page.

    Examples:

    .. code-block:: javascript

        preview: ["[math]"],     //  insert the text "[math]" as the preview

    .. code-block:: javascript

        preview: [["img",{src: "/images/mypic.jpg"}]],  // insert an image as the preview

    See the :ref:`description of HTML snippets <html-snippets>` for
    details on how to represent HTML code in this way.


Version data entries

12 entries across 6 versions & 2 rubygems

Version Path
mathjax-rails-1.0.3 vendor/mathjax-MathJax-da8d488/docs/source/options/mml2jax.rst
mathjax-rails-1.0.3 vendor/mathjax-MathJax-da8d488/docs/html/_sources/options/mml2jax.txt
mathjax-rails-1.0.2 vendor/mathjax-MathJax-da8d488/docs/html/_sources/options/mml2jax.txt
mathjax-rails-1.0.2 vendor/mathjax-MathJax-da8d488/docs/source/options/mml2jax.rst
mathjax_rails-0.0.1 vendor/mathjax-MathJax-da8d488/docs/source/options/mml2jax.rst
mathjax_rails-0.0.1 vendor/mathjax-MathJax-da8d488/docs/html/_sources/options/mml2jax.txt
mathjax-rails-0.0.4 vendor/mathjax-MathJax-da8d488/docs/html/_sources/options/mml2jax.txt
mathjax-rails-0.0.4 vendor/mathjax-MathJax-da8d488/docs/source/options/mml2jax.rst
mathjax-rails-0.0.3 vendor/mathjax-MathJax-da8d488/docs/source/options/mml2jax.rst
mathjax-rails-0.0.3 vendor/mathjax-MathJax-da8d488/docs/html/_sources/options/mml2jax.txt
mathjax-rails-0.0.2 vendor/mathjax-MathJax-f5cd294/docs/source/options/mml2jax.rst
mathjax-rails-0.0.2 vendor/mathjax-MathJax-f5cd294/docs/html/_sources/options/mml2jax.txt