From d40d8fb93db6ffa8d19efb1b7fcd9027483597d8 Mon Sep 17 00:00:00 2001 From: Luke Stagner Date: Thu, 22 May 2014 15:52:15 -0700 Subject: [PATCH 1/4] add unicode superscripts and subscripts to latex substitutions --- base/latex_symbols.jl | 45 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/base/latex_symbols.jl b/base/latex_symbols.jl index e2c586851d3e4..58d6075fc6804 100644 --- a/base/latex_symbols.jl +++ b/base/latex_symbols.jl @@ -781,6 +781,51 @@ const latex_symbols = [ "\\openbracketright" => "〛", "\\overbrace" => "︷", "\\underbrace" => "︸", + "\\^{0}" => "⁰", + "\\^{1}" => "¹", + "\\^{2}" => "²", + "\\^{3}" => "³", + "\\^{4}" => "⁴", + "\\^{5}" => "⁵", + "\\^{6}" => "⁶", + "\\^{7}" => "⁷", + "\\^{8}" => "⁸", + "\\^{9}" => "⁹", + "\\^{+}" => "⁺", + "\\^{-}" => "⁻", + "\\^{=}" => "⁼", + "\\^{(}" => "⁽", + "\\^{)}" => "⁾", + "\\^{n}" => "ⁿ", + "\\^{i}" => "ⁱ", + "\\_{0}" => "₀", + "\\_{1}" => "₁", + "\\_{2}" => "₂", + "\\_{3}" => "₃", + "\\_{4}" => "₄", + "\\_{5}" => "₅", + "\\_{6}" => "₆", + "\\_{7}" => "₇", + "\\_{8}" => "₈", + "\\_{9}" => "₉", + "\\_{+}" => "₊", + "\\_{-}" => "₋", + "\\_{=}" => "₌", + "\\_{(}" => "₍", + "\\_{)}" => "₎", + "\\_{a}" => "ₐ", + "\\_{e}" => "ₑ", + "\\_{o}" => "ₒ", + "\\_{x}" => "ₓ", + "\\_{schwa}" => "ₔ", + "\\_{h}" => "ₕ", + "\\_{k}" => "ₖ", + "\\_{l}" => "ₗ", + "\\_{m}" => "ₘ", + "\\_{n}" => "ₙ", + "\\_{p}" => "ₚ", + "\\_{s}" => "ₛ", + "\\_{t}" => "ₜ", ] From 198cd0294cfc93d3a132d368b8f41a6e9f2254c9 Mon Sep 17 00:00:00 2001 From: Luke Stagner Date: Thu, 22 May 2014 18:05:37 -0700 Subject: [PATCH 2/4] replace \\Elzxh with \\hbar to match latex usage --- base/latex_symbols.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/latex_symbols.jl b/base/latex_symbols.jl index 58d6075fc6804..b06d0ae8f0675 100644 --- a/base/latex_symbols.jl +++ b/base/latex_symbols.jl @@ -85,7 +85,7 @@ const latex_symbols = [ "\\th" => "þ", "\\DJ" => "Đ", "\\dj" => "đ", - "\\Elzxh" => "ħ", + "\\hbar" => "ħ", "\\imath" => "ı", "\\L" => "Ł", "\\l" => "ł", From f0e0339ead63d85c1beac642be4c8299ca79d05b Mon Sep 17 00:00:00 2001 From: Luke Stagner Date: Thu, 22 May 2014 18:36:43 -0700 Subject: [PATCH 3/4] moved super/subscripts and hbar to manually added section --- base/latex_symbols.jl | 93 ++++++++++++++++++++++--------------------- 1 file changed, 47 insertions(+), 46 deletions(-) diff --git a/base/latex_symbols.jl b/base/latex_symbols.jl index b06d0ae8f0675..27648d5026dca 100644 --- a/base/latex_symbols.jl +++ b/base/latex_symbols.jl @@ -47,6 +47,52 @@ const latex_symbols = [ "\\cbrt" => "\u221B", "\\female" => "♀", "\\mars" => "♂", + "\\^{0}" => "⁰", + "\\^{1}" => "¹", + "\\^{2}" => "²", + "\\^{3}" => "³", + "\\^{4}" => "⁴", + "\\^{5}" => "⁵", + "\\^{6}" => "⁶", + "\\^{7}" => "⁷", + "\\^{8}" => "⁸", + "\\^{9}" => "⁹", + "\\^{+}" => "⁺", + "\\^{-}" => "⁻", + "\\^{=}" => "⁼", + "\\^{(}" => "⁽", + "\\^{)}" => "⁾", + "\\^{n}" => "ⁿ", + "\\^{i}" => "ⁱ", + "\\_{0}" => "₀", + "\\_{1}" => "₁", + "\\_{2}" => "₂", + "\\_{3}" => "₃", + "\\_{4}" => "₄", + "\\_{5}" => "₅", + "\\_{6}" => "₆", + "\\_{7}" => "₇", + "\\_{8}" => "₈", + "\\_{9}" => "₉", + "\\_{+}" => "₊", + "\\_{-}" => "₋", + "\\_{=}" => "₌", + "\\_{(}" => "₍", + "\\_{)}" => "₎", + "\\_{a}" => "ₐ", + "\\_{e}" => "ₑ", + "\\_{o}" => "ₒ", + "\\_{x}" => "ₓ", + "\\_{schwa}" => "ₔ", + "\\_{h}" => "ₕ", + "\\_{k}" => "ₖ", + "\\_{l}" => "ₗ", + "\\_{m}" => "ₘ", + "\\_{n}" => "ₙ", + "\\_{p}" => "ₚ", + "\\_{s}" => "ₛ", + "\\_{t}" => "ₜ", + "\\hbar" => "ħ", # 732 symbols generated from unicode.xml "\\textexclamdown" => "¡", @@ -85,7 +131,7 @@ const latex_symbols = [ "\\th" => "þ", "\\DJ" => "Đ", "\\dj" => "đ", - "\\hbar" => "ħ", + "\\Elzxh" => "ħ", "\\imath" => "ı", "\\L" => "Ł", "\\l" => "ł", @@ -781,51 +827,6 @@ const latex_symbols = [ "\\openbracketright" => "〛", "\\overbrace" => "︷", "\\underbrace" => "︸", - "\\^{0}" => "⁰", - "\\^{1}" => "¹", - "\\^{2}" => "²", - "\\^{3}" => "³", - "\\^{4}" => "⁴", - "\\^{5}" => "⁵", - "\\^{6}" => "⁶", - "\\^{7}" => "⁷", - "\\^{8}" => "⁸", - "\\^{9}" => "⁹", - "\\^{+}" => "⁺", - "\\^{-}" => "⁻", - "\\^{=}" => "⁼", - "\\^{(}" => "⁽", - "\\^{)}" => "⁾", - "\\^{n}" => "ⁿ", - "\\^{i}" => "ⁱ", - "\\_{0}" => "₀", - "\\_{1}" => "₁", - "\\_{2}" => "₂", - "\\_{3}" => "₃", - "\\_{4}" => "₄", - "\\_{5}" => "₅", - "\\_{6}" => "₆", - "\\_{7}" => "₇", - "\\_{8}" => "₈", - "\\_{9}" => "₉", - "\\_{+}" => "₊", - "\\_{-}" => "₋", - "\\_{=}" => "₌", - "\\_{(}" => "₍", - "\\_{)}" => "₎", - "\\_{a}" => "ₐ", - "\\_{e}" => "ₑ", - "\\_{o}" => "ₒ", - "\\_{x}" => "ₓ", - "\\_{schwa}" => "ₔ", - "\\_{h}" => "ₕ", - "\\_{k}" => "ₖ", - "\\_{l}" => "ₗ", - "\\_{m}" => "ₘ", - "\\_{n}" => "ₙ", - "\\_{p}" => "ₚ", - "\\_{s}" => "ₛ", - "\\_{t}" => "ₜ", ] From b42723e5c89f5afd4d628c3b01f682d19168b117 Mon Sep 17 00:00:00 2001 From: Luke Stagner Date: Thu, 22 May 2014 19:51:30 -0700 Subject: [PATCH 4/4] get rid of curly braces in latex super/subscripts and add \del mapping --- base/latex_symbols.jl | 91 ++++++++++++++++++++++--------------------- 1 file changed, 46 insertions(+), 45 deletions(-) diff --git a/base/latex_symbols.jl b/base/latex_symbols.jl index 27648d5026dca..acea2d387edaa 100644 --- a/base/latex_symbols.jl +++ b/base/latex_symbols.jl @@ -47,52 +47,53 @@ const latex_symbols = [ "\\cbrt" => "\u221B", "\\female" => "♀", "\\mars" => "♂", - "\\^{0}" => "⁰", - "\\^{1}" => "¹", - "\\^{2}" => "²", - "\\^{3}" => "³", - "\\^{4}" => "⁴", - "\\^{5}" => "⁵", - "\\^{6}" => "⁶", - "\\^{7}" => "⁷", - "\\^{8}" => "⁸", - "\\^{9}" => "⁹", - "\\^{+}" => "⁺", - "\\^{-}" => "⁻", - "\\^{=}" => "⁼", - "\\^{(}" => "⁽", - "\\^{)}" => "⁾", - "\\^{n}" => "ⁿ", - "\\^{i}" => "ⁱ", - "\\_{0}" => "₀", - "\\_{1}" => "₁", - "\\_{2}" => "₂", - "\\_{3}" => "₃", - "\\_{4}" => "₄", - "\\_{5}" => "₅", - "\\_{6}" => "₆", - "\\_{7}" => "₇", - "\\_{8}" => "₈", - "\\_{9}" => "₉", - "\\_{+}" => "₊", - "\\_{-}" => "₋", - "\\_{=}" => "₌", - "\\_{(}" => "₍", - "\\_{)}" => "₎", - "\\_{a}" => "ₐ", - "\\_{e}" => "ₑ", - "\\_{o}" => "ₒ", - "\\_{x}" => "ₓ", - "\\_{schwa}" => "ₔ", - "\\_{h}" => "ₕ", - "\\_{k}" => "ₖ", - "\\_{l}" => "ₗ", - "\\_{m}" => "ₘ", - "\\_{n}" => "ₙ", - "\\_{p}" => "ₚ", - "\\_{s}" => "ₛ", - "\\_{t}" => "ₜ", + "\\^0" => "⁰", + "\\^1" => "¹", + "\\^2" => "²", + "\\^3" => "³", + "\\^4" => "⁴", + "\\^5" => "⁵", + "\\^6" => "⁶", + "\\^7" => "⁷", + "\\^8" => "⁸", + "\\^9" => "⁹", + "\\^+" => "⁺", + "\\^-" => "⁻", + "\\^=" => "⁼", + "\\^(" => "⁽", + "\\^)" => "⁾", + "\\^n" => "ⁿ", + "\\^i" => "ⁱ", + "\\_0" => "₀", + "\\_1" => "₁", + "\\_2" => "₂", + "\\_3" => "₃", + "\\_4" => "₄", + "\\_5" => "₅", + "\\_6" => "₆", + "\\_7" => "₇", + "\\_8" => "₈", + "\\_9" => "₉", + "\\_+" => "₊", + "\\_-" => "₋", + "\\_=" => "₌", + "\\_(" => "₍", + "\\_)" => "₎", + "\\_a" => "ₐ", + "\\_e" => "ₑ", + "\\_o" => "ₒ", + "\\_x" => "ₓ", + "\\_schwa" => "ₔ", + "\\_h" => "ₕ", + "\\_k" => "ₖ", + "\\_l" => "ₗ", + "\\_m" => "ₘ", + "\\_n" => "ₙ", + "\\_p" => "ₚ", + "\\_s" => "ₛ", + "\\_t" => "ₜ", "\\hbar" => "ħ", + "\\del" => "∇", # 732 symbols generated from unicode.xml "\\textexclamdown" => "¡",