File: latex_token.py

package info (click to toggle)
python-mistletoe 1.4.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 864 kB
  • sloc: python: 5,649; sh: 66; makefile: 40
file content (11 lines) | stat: -rw-r--r-- 202 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
import re
import mistletoe.span_token as span_token


__all__ = ['Math']


class Math(span_token.SpanToken):
    pattern = re.compile(r'(\${1,2})([^$]+?)\1')
    parse_inner = False
    parse_group = 0