summaryrefslogtreecommitdiff
path: root/library/src/text
diff options
context:
space:
mode:
authorMartin Haug <mhaug@live.de>2022-12-22 01:33:09 +0100
committerMartin Haug <mhaug@live.de>2022-12-22 01:33:09 +0100
commit947522b71aa6220ce8f006bfab4700d6e3cb04f1 (patch)
tree870f032263dc8dc025ad67660b0eabbfc4b5720c /library/src/text
parentc06d45002a56dc8fcb4281eab3b9a4038bd26800 (diff)
Symbol table
Diffstat (limited to 'library/src/text')
-rw-r--r--library/src/text/symbol.rs26
1 files changed, 26 insertions, 0 deletions
diff --git a/library/src/text/symbol.rs b/library/src/text/symbol.rs
index a59461a7..4a7c8ad3 100644
--- a/library/src/text/symbol.rs
+++ b/library/src/text/symbol.rs
@@ -19,6 +19,32 @@ use crate::text::TextNode;
/// the notation directly. There, all letter sequence of length at least two are
/// automatically parsed as symbols (unless a variable of that name is defined).
///
+/// Additionally, some very common but hard to type symbols can be expressed with
+/// dedicated shortcuts. These are:
+///
+/// | Symmie | Shorthand | Result |
+/// | ----------- | --------- | ------ |
+/// | `dots:b` | `...` | … |
+/// | `dash:en` | `---` | – |
+/// | `dash:em` | `--` | — |
+/// | none yet | `-?` | A soft hyphen |
+/// | none yet | `~` | A non breaking space |
+///
+/// Within math mode, additional shorthands are available:
+///
+/// | Symmie | Shorthand | Result |
+/// | ------------------ | --------- | ------ |
+/// | `arrow:r` | `->` | `→` |
+/// | `arrow:r:double` | `=>` | `⇒` |
+/// | `arrow:l` | `<-` | `←` |
+/// | `arrow:r:bar` | <code>&VerticalLine;-></code> | `↦` |
+/// | `arrow:l:r` | `<->` | `↔` |
+/// | `arrow:l:r:double` | `<=>` | `⇔` |
+/// | `eq:not` | `!=` | `≠` |
+/// | `eq:gt` | `>=` | `≥` |
+/// | `eq:lt` | `<=` | `≤` |
+/// | `colon:eq` | `:=` | `≔` |
+///
/// ## Example
/// ```
/// // In text, with colons.