Commits

Jason S committed 8abcfec

README.md edited online with Bitbucket

  • Participants
  • Parent commits fea91c6

Comments (0)

Files changed (1)

 # SVG_MathJax #
 
+This replaces MathJax inline markup in an `<svg>` element with SVG-rendered MathJax.
+
+Usage is easy:
+
+```
+<html>
+    <head>
+    <script type="text/javascript"
+      src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_SVG">
+    </script>
+    <script type="text/javascript" src="svg_mathjax.js">
+    </script>
+    <script type="text/javascript">
+        new Svg_MathJax().install();
+    </script>
+</head>
+<body>
+<svg xmlns="http://www.w3.org/2000/svg"
+     <!-- center-align at x,y point: -->
+     <text font-size="11" x="100" y="175">\( a^2 + b^2 = c^2 \)</text>
+     <!-- left-align at x,y point: -->
+     <text font-size="11" x="100" y="205">L\( a^2 + b^2 = c^2 \)</text>
+     <!-- right-align at x,y point: -->
+     <text font-size="11" x="100" y="235">R\( a^2 + b^2 = c^2 \)</text>
+  </svg>
+</body>
+</html>