Page MenuHomePhabricator

Feature: Let Math accept certain Unicode input (eg. ∫ \frac{∂f}{∂τ}dτ )
Open, NormalPublic

Description

Using utf8 characters allow a much more readable expression. Math Stackexchange does this.

This can be achieved by modifying one line in textvc:

Just add 4 new range of unicode-points to the allowed character set.

This is possible because MathJax recognize these characters. If MathJax doesn't, it just put the verbatim character to the output svg.

The proposed allowed sets of characters are :

  1. greeks \u0370-\u03FF
  2. operators \u2200-\u22FF eg. ∀ ∃ ∂ ∈ ⊂ ∫
  3. ℕ ℤ ℙ ℚ ℝ ℂ ℍ
  4. arrows \u2190-\u21FF eg → ↔ ⇀ ⇒ ↪ ↦
  5. ¬±×÷♭♮♯

Character table: link

Diff: https://github.com/physikerwelt/texvcjs/pull/1/files

- literal_id =      [a-zA-Z]
+ /* greeks, operators, letter-like symbols, arrows */
+ literal_id =      [a-zA-Z¬±×÷♭♮♯\u0370-\u03FF\u2200-\u22FF\u2100-\u214F\u2190-\u21FF]

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMay 19 2017, 12:52 PM
Golopotw renamed this task from Allow utf-8 characters in math input so user can write α→β instead of \alpha\to\beta to Make the math renderer understand utf-8 input so user can write α→β instead of \alpha\to\beta.May 19 2017, 12:53 PM
Golopotw updated the task description. (Show Details)May 29 2017, 7:23 AM
Golopotw renamed this task from Make the math renderer understand utf-8 input so user can write α→β instead of \alpha\to\beta to Feature: Accept certain Unicode input so users can write α→β instead of \alpha\to\beta.Jun 8 2017, 11:44 PM
Golopotw updated the task description. (Show Details)
Golopotw renamed this task from Feature: Accept certain Unicode input so users can write α→β instead of \alpha\to\beta to Feature: Accept certain Unicode input (eg. ∫ \frac{∂f}{∂τ}dτ ).Jun 8 2017, 11:57 PM
Golopotw renamed this task from Feature: Accept certain Unicode input (eg. ∫ \frac{∂f}{∂τ}dτ ) to Feature: Let Math accept certain Unicode input (eg. ∫ \frac{∂f}{∂τ}dτ ).Jun 9 2017, 12:00 AM
Physikerwelt added a subscriber: Physikerwelt.

I like the idea. However, I think it would be better to replace the unicode chars by the respective commands for furhter processing. That way the formulae can still be rendered using pdflatex (with \usepackage{texvc}). Some symbols are already listed here https://github.com/physikerwelt/utf8tex/blob/master/unicode2classicTex.csv What do you think?

Physikerwelt triaged this task as Normal priority.Jun 11 2017, 12:46 PM

I think both approach are good. More code is needed to replace chars, but it is manageable.

He7d3r added a subscriber: He7d3r.Jan 2 2018, 11:55 AM

I think a reasonable way to go forward is to build that into the VE

Physikerwelt removed Physikerwelt as the assignee of this task.Dec 2 2018, 5:25 PM
Pkra moved this task from Incoming to texvc on the Math board.Dec 7 2018, 10:49 AM
Pkra moved this task from texvc to New TeX macro proposals on the Math board.Dec 7 2018, 10:54 AM