Using MathFlow with Arbortext Styler

The information on this page applies to:
MathFlow 1.x-2.x for Arbortext Arbortext Editor 5.1 or later with Styler

Arbortext Styler is a stylesheet editor allowing you to customize the look of your XML files in Arbortext Editor, as well as their output (such as PDF or HTML). For Styler stylesheet users, some customization is required to have MathML equations display in Arbortext Editor. With Arbortext Styler you may also change the look and placement of your MathML equations.

MathFlow replaces the MathML in your XML files with images in Arbortext's Editor View to give authors a natural view of the math. To make the Editor View as clean as possible, there are two requirements. First, Abortext Editor must know the MathML <math> element is represented by an image. Secondly, Arbortext Editor must know to hide all of the descendant MathML elements. You can use the Arbortext Styler to specify these requirements.

First make sure you can see all of the MathML elements in Styler. Go to the Options menu and check "List All Elements" if it's not already checked.

If you have altered the doctype configuration file (your doctype file with the .dcf extension) as specified in the MathFlow documentation, Styler will recognize the MathML element should be displayed as a graphic. If you have not altered the configuration file:

  1. Highlight the m:math element in the list of elements.
  2. From the Style drop-down menu, choose Graphic.
  3. In the Graphic Details dialog boxes, set the following roles for the attributes:
AttributeRole
altimgFile name
baselineVertical adjust amount
heightScale to fit height
widthScale to fit width

Next, hide all of the other MathML elements. Select the element(s) in the Styler element list and choose "Hidden" from the Style drop-down menu. Arbortext Editor 5.2 users can change the style of several elements at once by holding down the shift or control keys while making the selection. Arbortext Editor 5.1 users must change the style of each element individually.

You can use Styler to alter the font size and placement of your equations. For example (using the axdocbook_math doctype to demonstrate):

  • You'd like your display equations to appear in 20 pt font while leaving the inline equations in the same font size as the surrounding text.
    1. In Styler's list of elements, right-click "m:math" and select "New Context".
    2. Click the "New parent" button.
    3. Select "equation" from the drop-down menu in the main window.
    4. Click OK.
    5. In the list of elements, highlight the new context "m:math in equation".
    6. In the Font tab of the properties to edit, choose "20" from the Size drop-down menu.
    7. Go to the Preview menu in Styler and select Arbortext Editor.
    8. In Arbortext Editor you'll need to reload the MathML images before you see the changes. To do this, select View>Reload MathML Images (MathFlow 1.5 and previous) or MathFlow>Reload MathML Images (MathFlow 1.6 and later).
  • You'd like to center your display equations.
    1. Select "equation" in Styler's list of elements.
    2. In the Indent tab of the properties to edit, choose "Centered" from the Alignment drop-down menu.
    3. Go to the Preview menu in Styler and select Arbortext Editor to see the changes.


""

We hope this has been helpful. As always, please let us know if you have questions about this, or if you have additional techniques that work. We'd love to hear from you.