prev next
File: Presentation/GeneralLayout/mfrac/mfracSinheritance14.xml (mml file)
Author: Robert Miner and Jeff Schaefer, Geometry Technologies
Description: This example tests that colors and scriptlevels inherit properly from <mstyle> to <mfrac>
Sample Rendering:
Created by: webeq

Your browser's rendering:

1 y + 3 y + 3 1 y + 3 1 y + 3 y + 3


Source Code:

    <math> 
      <mrow> 
        <mstyle color='#48c' scriptlevel='+0'> 
          <mfrac> 
            <mfrac> 
              <mn>1</mn> 
              <mrow> 
                <mi>y</mi> 
                <mo>+</mo> 
                <mn>3</mn> 
              </mrow> 
            </mfrac> 
            <mrow> 
              <mi>y</mi> 
              <mo>+</mo> 
              <mn>3</mn> 
            </mrow> 
          </mfrac> 
        </mstyle> 
        <mstyle color='#48c' scriptlevel='+1'> 
          <mfrac> 
            <mn>1</mn> 
            <mrow> 
              <mi>y</mi> 
              <mo>+</mo> 
              <mn>3</mn> 
            </mrow> 
          </mfrac> 
        </mstyle> 
        <mstyle color='#48c' scriptlevel='+2'> 
          <mfrac> 
            <mstyle color='#48c' scriptlevel='-3'> 
              <mfrac> 
                <mn>1</mn> 
                <mrow> 
                  <mi>y</mi> 
                  <mo>+</mo> 
                  <mn>3</mn> 
                </mrow> 
              </mfrac> 
            </mstyle> 
            <mrow> 
              <mi>y</mi> 
              <mo>+</mo> 
              <mn>3</mn> 
            </mrow> 
          </mfrac> 
        </mstyle> 
      </mrow> 
    </math>
  

Test Suite Home