MathML Expression in Grid

asked 2012-01-25 02:53:40 +0800

agsiegel gravatar image agsiegel
6 1

I would like to be able to render a MathML expression inside the cell of a grid. Take this link for example.


It uses the stylesheet

<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="pmathml.xsl"?>

to render the mathml expression created by the following.

<math xmlns="http://www.w3.org/1998/Math/MathML">
<cn> 0 </cn> <cn> 1 </cn> <cn> 0 </cn>
<cn> 0 </cn> <cn> 0 </cn> <cn> 1 </cn>
<cn> 1 </cn> <cn> 0 </cn> <cn> 0 </cn>

Any thought?


delete flag offensive retag edit

1 Reply

Sort by ยป oldest newest

answered 2012-01-25 03:29:52 +0800

agsiegel gravatar image agsiegel
6 1

Well looks like firefox has mathml support build in. So all I needed to do was something like

Listcell c = new Listcell();
c.appendChild(new Html(
"<math xmlns=\"&mathml;\">"
+ "<mrow>"
+ "<mi>a</mi>"
+ "<msup>"
+ "<mi>x</mi>"
+ "<mn>2</mn>"
+ "</msup>"
+ "<mo>+</mo>"
+ "<mi>b</mi>"
+ "<mi>x</mi>"
+ "<mo>+</mo>"
+ "<mi>c</mi>"
+ "<mo>=</mo>"
+ "<mn>0</mn>"
+ "</mrow>"
+ "</math>"));

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools




Asked: 2012-01-25 02:53:40 +0800

Seen: 118 times

Last updated: Jan 25 '12

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More