[go: up one dir, main page]

TeXZilla.toImage

This page contains a <canvas>. A mathematical equation is inserted at the center using the following code:

  var image =
    TeXZilla.toImage("\\vec{F} = G \\frac{m_1 m_2}{r^2} \\mathbf{u}");
  image. {
    context.drawImage(image,
                      (canvas.width - image.width) / 2,
                      (canvas.height - image.height) / 2);