Qalculate / libqalculate

Qalculate! library and CLI
https://qalculate.github.io/
GNU General Public License v2.0
1.81k stars 146 forks source link

[Feature request] input Unicode characters by tab completion #685

Open howaboutuser opened 2 months ago

howaboutuser commented 2 months ago

Example

θ: \theta (tab)
x²: x\^2 (tab)
H₂O: H\_2 (tab) O

I think Greek alphabet, superscript and subscript should be enough for most people. But I also want ∠(angle), °(degree) and ∥(parallel) personally.

This feature may cause following problem:

> 1=sinθ #θ already in use

  error: You need at least 1 argument in function heaviside().
  1 = sin(heaviside() × radians)

  1 − sin(θ()) = 0

> 1=sin²x #invalid syntax

  warning: Misplaced operator(s) "^" ignored
  1 = sin((2 × x) radians)

  x = πn + π / 4 ≈ 3.141592654n + 0.7853981634

Reference https://docs.julialang.org/en/v1/manual/unicode-input/#Unicode-Input