Skip to content

Commit

Permalink
Updated configuration options documentaiton and added SVG and MathEve…
Browse files Browse the repository at this point in the history
…nts documentation
  • Loading branch information
dpvc committed Feb 20, 2012
1 parent 4332291 commit 39b78b1
Show file tree
Hide file tree
Showing 47 changed files with 1,981 additions and 449 deletions.
9 changes: 5 additions & 4 deletions docs/html/_sources/options/AsciiMath.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@ The AsciiMath input processor

The options below control the operation of the AsciiMath input
processor that is run when you include ``"input/AsciiMath"`` in the
`jax` array of your configuration or use a combined configuration file
that includes AsciiMath input. They are listed with their default
values. To set any of these options, include a ``AsciiMath`` section
in your :meth:`MathJax.Hub.Config()` call. For example
`jax` array of your configuration or load a combined configuration
file that includes the AsciiMath input jax. They are listed with
their default values. To set any of these options, include a
``AsciiMath`` section in your :meth:`MathJax.Hub.Config()` call. For
example

.. code-block:: javascript

Expand Down
93 changes: 75 additions & 18 deletions docs/html/_sources/options/HTML-CSS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@ The HTML-CSS output processor

The options below control the operation of the HTML-CSS output
processor that is run when you include ``"output/HTML-CSS"`` in the
`jax` array of your configuration. They are listed with their default
values. To set any of these options, include a ``"HTML-CSS"`` section
in your :meth:`MathJax.Hub.Config()` call. Note that, because of the
dash, you need to enclose the name in quotes. For example
`jax` array of your configuration or load a combined configuration
file that includes the HTML-CSS output jax. They are listed with
their default values. To set any of these options, include a
``"HTML-CSS"`` section in your :meth:`MathJax.Hub.Config()` call.
Note that, because of the dash, you need to enclose the name in
quotes. For example

.. code-block:: javascript

Expand All @@ -25,7 +27,7 @@ would set the ``preferredFont`` option to the :term:`STIX` fonts.

The scaling factor (as a percentage) of math with respect to the
surrounding text. The `HTML-CSS` output processor tries to match
the en-size of the mathematics with that of the text where it is
the ex-size of the mathematics with that of the text where it is
placed, but you may want to adjust the results using this scaling
factor. The user can also adjust this value using the contextual
menu item associated with the typeset mathematics.
Expand Down Expand Up @@ -86,6 +88,68 @@ would set the ``preferredFont`` option to the :term:`STIX` fonts.
(even if it doesn't contain the needed character), so order these
carefully.

.. describe:: mtextFontInherit: false

This setting controls whether ``<mtext>`` elements will be typeset
using the math fonts or the font of the surrounding text. When
``false``, the font for ``mathvariant="normal"`` will be used;
when ``true``, the font will be inherited from the surrounding
paragraph.

.. describe:: EqnChunk: 50
EqnChunkFactor: 1.5
EqnChunkDelay: 100

These values control how "chunky" the display of mathematical
expressions will be; that is, how often the equations will be
updated as they are processed.

``EqnChunk`` is the number of equations that will be typeset before
they appear on screen. Larger values make for less visual flicker
as the equations are drawn, but also mean longer delays before the
reader sees anything.

``EqChunkFactor`` is the factor by which the ``EqnChunk`` will
grow after each chunk is displayed.

``EqChunkDelay`` is the time (in milliseconds) to delay between
chunks (to allow the browser to respond to other user
interaction).

Set ``EqnChunk`` to 1, ``EqnChunkFactor`` to 1, and
``EqnChunkDelay`` to 10 to get the behavior from MathJax v1.1 and
below.

.. describe:: linebreaks: {}

This is an object that configures automatic linebreaking in the
HTML-CSS output. In order to be backward compatible with earlier
versions of MathJax, only explicit line breaks are performed by
default, so you must enable line breaks if you want automatic
ones. The object contains the following values:

.. describe:: automatic: false

This controls the automatic breaking of expressions: when
``false``, only ``linebreak="newline"`` is processed; when
``true``, line breaks are inserted automatically in long
expressions.

.. describe:: width: "container"

This controls how wide the lines of mathematics can be.

Use an explicit width like ``"30em"`` for a fixed width.
Use ``"container"`` to compute the size from the containing
element.
Use ``"nn% container"`` for a portion of the container.
Use ``"nn%"`` for a portion of the window size.

The container-based widths may be slower, and may not produce
the expected results if the layout width changes due to the
removal of previews or inclusion of mathematics during
typesetting.

.. describe:: styles: {}

This is a list of CSS declarations for styling the HTML-CSS
Expand All @@ -96,18 +160,10 @@ would set the ``preferredFont`` option to the :term:`STIX` fonts.

.. describe:: showMathMenu: true

This controls whether the MathJax contextual menu will be
available on the mathematics in the page. If true, then
right-clicking (on the PC) or control-clicking (on the Mac) will
produce a MathJax menu that allows you to get the source of the
mathematics in various formats, change the size of the mathematics
relative to the surrounding text, get information about
MathJax, and configure other MathJax settings.

Set this to ``false`` to disable the menu. When ``true``, the
``MathMenu`` configuration block determines the operation of the
menu. See :ref:`the MathMenu options <configure-MathMenu>` for
more details.
This value has been moved to the core configuration block, since
it applies to all output jax, but it will still be honored (for
now) if it is set here. See the :ref:`Core configuration options
<configure-hub>` for more details.

.. describe:: tooltip: { ... }

Expand All @@ -128,7 +184,8 @@ would set the ``preferredFont`` option to the :term:`STIX` fonts.
The delay (in milliseconds) before the tooltop is cleared
after the mouse moves out of the ``maction`` element.

.. describe:: offsetX: 10 and offsetY: 5
.. describe:: offsetX: 10
offsetY: 5

These are the offset from the mouse position (in pixels)
where the tooltip will be placed.
32 changes: 24 additions & 8 deletions docs/html/_sources/options/MMLorHTML.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@ The MMLorHTML configuration options

The options below control the operation of the MMLorHTML configuration
file that is run when you include ``"MMLorHTML.js"`` in the `config`
array of your configuration. They are listed with their default
values. To set any of these options, include a ``MMLorHTML`` section
in your :meth:`MathJax.Hub.Config()` call. For example
array of your configuration, or when you use one of the combined
configuration files that ends with ``_HTMLorMML``. They are listed
with their default values. To set any of these options, include a
``MMLorHTML`` section in your :meth:`MathJax.Hub.Config()` call. For
example

.. code-block:: javascript

Expand All @@ -28,15 +30,29 @@ Note that if you use the ``MMLorHTML.js`` configuration file, you should
**not** specify an output processor in the `jax` array of your
configuration; `MMLorHTML` will fill that in for you.

.. describe:: prefer: { MSIE: "MML", Firefox: "MML", Opera: "HTML", other: "HTML" }
.. describe:: prefer: {
MSIE: "MML",
Firefox: "HTML",
Safari: "HTML",
Chrome: "HTML",
Opera: "HTML",
other: "HTML"
}

This lets you set the preferred renderer on a browser-by-browser
basis. You set the browser to either ``"MML"`` or ``"HTML"``
depending on whether you want to use the `NativeMML` or `HTML-CSS`
output processor. Note that although Opera does process some MathML
natively, its support is not sufficient to handle the more
complicated output generated by MathJax, so its setting is
``"HTML"`` by default.
output processor. Note that although Opera and Safari do process some MathML
natively, their support is not sufficient to handle the more
complicated output generated by MathJax, so their settings are
``"HTML"`` by default. Although Firefox does support a large
subset of MathJax, it does not implement all the features needed by
MathJax, and so it is also set to ``"HTML"`` by default (this is
new in v2.0).

Note that users can still use the MathJax contextual menu to select
a different renderer after the default one has been chosen by
``MMLorHTML.js``.



37 changes: 37 additions & 0 deletions docs/html/_sources/options/MathEvents.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
.. _configure-MathEvents:

************************
The MathEvents extension
************************

The options below control the operation of the MathEvents component that
allows handles mouse and menu events attached to mathematics that is
typeset by MathJax. They are listed with their
default values. To set any of these options, include a ``MathEvents``
section in your :meth:`MathJax.Hub.Config()` call. For example

.. code-block:: javascript

MathJax.Hub.Config({
MathEvents: {
hover: 400
}
});

would set the required delay for hovering over a math element to
400 milliseconds.

.. describe:: hover: 500

This value is the time (in milliseconds) that a user must hold the
mouse still over a math element before it is considered to be
hovering over the math.

.. describe:: styles: {}

This is a list of CSS declarations for styling the zoomed
mathematics. See the definitions in ``extensions/MathEvents.js``
for details of what are defined by default. See :ref:`CSS Style
Objects <css-style-objects>` for details on how to specify CSS
style in a JavaScript object.

3 changes: 2 additions & 1 deletion docs/html/_sources/options/MathML.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ The MathML input processor

The options below control the operation of the MathML input processor
that is run when you include ``"input/MathML"`` in the `jax` array of
your configuration. They are listed with their default values. To
your configuration or load a combined configuration file that includes
the MathML input jax. They are listed with their default values. To
set any of these options, include a ``MathML`` section in your
:meth:`MathJax.Hub.Config()` call. For example

Expand Down
46 changes: 27 additions & 19 deletions docs/html/_sources/options/MathMenu.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,33 +34,41 @@ would set the ``delay`` option to 600 milliseconds.

.. describe:: showRenderer: true

This controls whether the "Math Renderer" item will be displayed in
the "Settings" submenu of the mathematics contextual menu. It
allows the user to change between the `HTML-CSS` and `NativeMML`
output processors for the mathematics on the page. Set to
``false`` to prevent this menu item from showing.

.. describe:: showContext: false

This controls whether the "Contextual Menu" item will be displayed
in the "Settings" submenu of the mathematics contextual menu.
It allows the user to decide whether the MathJax menu or the
browser's default contextual menu will be shown when the context
menu click occurs over mathematics typeset by MathJax. (The main
reason to allow pass-through to the browser's menu is to gain
access to the MathPlayer contextual menu when the NativeMML output
processor is used in Internet Explorer with the `MathPlayer plugin
<http://www.dessci.com/en/products/mathplayer/>`_.) Set to
``false`` to prevent this menu item from showing.
This controls whether the "Math Renderer" item will be displayed
in the "Math Settings" submenu of the MathJax contextual menu.
It allows the user to change between the `HTML-CSS`, `NativeMML`,
and `SVG` output processors for the mathematics on the page. Set
to ``false`` to prevent this menu item from showing.

.. describe:: showFontMenu: false

This controls whether the "Font Preference" item will be displayed
in the "Settings" submenu of the mathematics contextual menu.
in the "Math Settings" submenu of the MathJax contextual menu.
This submenu lets the user select what font to use in the
mathematics produced by the `HTML-CSS` output processor. Note that
changing the selection in the font menu will cause the page to
reload. Set to ``false`` to prevent this menu item from showing.

.. describe:: showMathPlayer: true

This controls whether the "MathPlayer" item will be displayed in
the "Math Settings" submenu of the MathJax contextual menu. This
submenu lets the user select what events should be passed on to
the `MathPlayer plugin
<http://www.dessci.com/en/products/mathplayer/>`_, when it is
present. Mouse events can be passed on (so that clicks will be
processed by MathPlayer rather than MathJax), and emnu events can
be passed on (to allow the user access to the MathPlayer menu).
Set to ``false`` to prevent this menu item from showing.

.. describe:: showContext: false

This controls whether the "Contextual Menu" item will be displayed
in the "Math Settings" submenu of the MathJax contextual menu.
It allows the user to decide whether the MathJax menu or the
browser's default contextual menu will be shown when the context
menu click occurs over mathematics typeset by MathJax. Set to
``false`` to prevent this menu item from showing.

.. describe:: windowSettings: { ... }

Expand Down
19 changes: 12 additions & 7 deletions docs/html/_sources/options/MathZoom.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,23 +14,28 @@ section in your :meth:`MathJax.Hub.Config()` call. For example

MathJax.Hub.Config({
MathZoom: {
delay: 600
styles: {
"#MathJax_Zoom": {
"background-color": "#0000F0"
}
}
}
});

would set the ``delay`` option to 600 milliseconds.
would set the background color of the Zoom box to a very light blue.

Mathematics is zoomed when the user "triggers" the zoom by an action,
either clicking on the mathematics, double-clicking on it, or holding
the mouse still over it (i.e., "hovering"). Which trigger is used is
set by the user via the math contextual menu (or by the author using
the ``menuSettings`` configuration section).
the ``menuSettings`` configuration section of the `core configuration
options <configure-hub>`).

.. describe:: delay: 400
.. describe:: delay: 500

This the time (in milliseconds) that the mouse must be still over a
typeset mathematical formula before the zoomed version is displayed
(when the zoom trigger is set to `Hover`).
This value is now stored as the ``hover`` parameter in the
:ref:`MathEvents <configure-MathEvents>` configuration options, and
will have no effect if given here.

.. describe:: styles: {}

Expand Down
Loading

0 comments on commit 39b78b1

Please sign in to comment.