Syntax - mathxapp/matex GitHub Wiki

Section

<section>…</section> defines sections in your document such as chapters. section contains text and mathematical notation.

<section>
	<p>-2 = -2 × 1</p>
	<p>-2 = 2 × (-1)</p>
	<p>Divisors = {-2,-1,1,2}</p>
</section>

Paragraph

<p>…</p> defines a paragraph. It specifies self-contained content, like text, mathematical notation, etc.

<section>
	<p>-2 = -2 × 1</p>
	<p> $ \left (\begin{array}{cc}1 & 0  \\0 & 1 \\\end{array}\right) $ </p>
</section>

Mathematical notation

Mathematics that is written in LaTeX format is indicated using math delimiter $…$, telling MaTeX what part of your page represents mathematics and what is normal text.

<section>
        <p>Text</p>
	<p> $ \left (\begin{array}{cc}1 & 0  \\0 & 1 \\0 & 0 \\\end{array}\right) $ </p>
</section>

Headings

You can add title to section using the <h2>…</h2> tag.

<h2> Title </h2>
<section>
	<p> My first paragraph.</p>
</section>

You can add subtitle in section using the <h3>…</h3> tag.

<h2> Title </h2>
<section>
	<p> My first paragraph.</p>
        <h3> Subtitle </h3>
        <p> My second paragraph.</p>
</section>

Styles

You can highlight important information using these style:

  • answer
  • information
  • warning
  • error

Styles are plonked straight into the paragraph tags using class attribute. They look something like this:

<p class="answer">Answer style</p>

Answer style

<p class="information">Information style</p>

Information style

<p class="warning">Warning style</p>

Warning style

<p class="error">Error style</p>

Error style

⚠️ **GitHub.com Fallback** ⚠️