1 ;;; org-entities.el --- Support for special entities in Org-mode
3 ;; Copyright (C) 2010-2014 Free Software Foundation, Inc.
5 ;; Author: Carsten Dominik <carsten at orgmode dot org>,
6 ;; Ulf Stegemann <ulf at zeitform dot de>
7 ;; Keywords: outlines, calendar, wp
8 ;; Homepage: http://orgmode.org
10 ;; This file is part of GNU Emacs.
12 ;; GNU Emacs is free software: you can redistribute it and/or modify
13 ;; it under the terms of the GNU General Public License as published by
14 ;; the Free Software Foundation, either version 3 of the License, or
15 ;; (at your option) any later version.
17 ;; GNU Emacs is distributed in the hope that it will be useful,
18 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
19 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ;; GNU General Public License for more details.
22 ;; You should have received a copy of the GNU General Public License
23 ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
24 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
30 (declare-function org-toggle-pretty-entities
"org" ())
31 (declare-function org-table-align
"org-table" ())
36 (defgroup org-entities nil
37 "Options concerning entities in Org-mode."
41 (defcustom org-entities-ascii-explanatory nil
42 "Non-nil means replace special entities in ASCII.
43 For example, this will replace \"\\nsup\" with \"[not a superset of]\"
44 in backends where the corresponding character is not available."
49 (defcustom org-entities-user nil
50 "User-defined entities used in Org-mode to produce special characters.
51 Each entry in this list is a list of strings. It associates the name
52 of the entity that can be inserted into an Org file as \\name with the
53 appropriate replacements for the different export backends. The order
54 of the fields is the following
56 name As a string, without the leading backslash
57 LaTeX replacement In ready LaTeX, no further processing will take place
58 LaTeX mathp A Boolean, either t or nil. t if this entity needs
60 HTML replacement In ready HTML, no further processing will take place.
61 Usually this will be an &...; entity.
62 ASCII replacement Plain ASCII, no extensions. Symbols that cannot be
63 represented will be left as they are, but see the.
64 variable `org-entities-ascii-explanatory'.
65 Latin1 replacement Use the special characters available in latin1.
66 utf-8 replacement Use the special characters available in utf-8.
68 If you define new entities here that require specific LaTeX
69 packages to be loaded, add these packages to `org-latex-packages-alist'."
75 (string :tag
"LaTeX ")
76 (boolean :tag
"Require LaTeX math?")
78 (string :tag
"ASCII ")
79 (string :tag
"Latin1")
80 (string :tag
"utf-8 "))))
82 (defconst org-entities
86 ("Agrave" "\\`{A}" nil
"À" "A" "À" "À")
87 ("agrave" "\\`{a}" nil
"à" "a" "à" "à")
88 ("Aacute" "\\'{A}" nil
"Á" "A" "Á" "Á")
89 ("aacute" "\\'{a}" nil
"á" "a" "á" "á")
90 ("Acirc" "\\^{A}" nil
"Â" "A" "Â" "Â")
91 ("acirc" "\\^{a}" nil
"â" "a" "â" "â")
92 ("Atilde" "\\~{A}" nil
"Ã" "A" "Ã" "Ã")
93 ("atilde" "\\~{a}" nil
"ã" "a" "ã" "ã")
94 ("Auml" "\\\"{A}" nil
"Ä" "Ae" "Ä" "Ä")
95 ("auml" "\\\"{a}" nil
"ä" "ae" "ä" "ä")
96 ("Aring" "\\AA{}" nil
"Å" "A" "Å" "Å")
97 ("AA" "\\AA{}" nil
"Å" "A" "Å" "Å")
98 ("aring" "\\aa{}" nil
"å" "a" "å" "å")
99 ("AElig" "\\AE{}" nil
"Æ" "AE" "Æ" "Æ")
100 ("aelig" "\\ae{}" nil
"æ" "ae" "æ" "æ")
101 ("Ccedil" "\\c{C}" nil
"Ç" "C" "Ç" "Ç")
102 ("ccedil" "\\c{c}" nil
"ç" "c" "ç" "ç")
103 ("Egrave" "\\`{E}" nil
"È" "E" "È" "È")
104 ("egrave" "\\`{e}" nil
"è" "e" "è" "è")
105 ("Eacute" "\\'{E}" nil
"É" "E" "É" "É")
106 ("eacute" "\\'{e}" nil
"é" "e" "é" "é")
107 ("Ecirc" "\\^{E}" nil
"Ê" "E" "Ê" "Ê")
108 ("ecirc" "\\^{e}" nil
"ê" "e" "ê" "ê")
109 ("Euml" "\\\"{E}" nil
"Ë" "E" "Ë" "Ë")
110 ("euml" "\\\"{e}" nil
"ë" "e" "ë" "ë")
111 ("Igrave" "\\`{I}" nil
"Ì" "I" "Ì" "Ì")
112 ("igrave" "\\`{i}" nil
"ì" "i" "ì" "ì")
113 ("Iacute" "\\'{I}" nil
"Í" "I" "Í" "Í")
114 ("iacute" "\\'{i}" nil
"í" "i" "í" "í")
115 ("Icirc" "\\^{I}" nil
"Î" "I" "Î" "Î")
116 ("icirc" "\\^{i}" nil
"î" "i" "î" "î")
117 ("Iuml" "\\\"{I}" nil
"Ï" "I" "Ï" "Ï")
118 ("iuml" "\\\"{i}" nil
"ï" "i" "ï" "ï")
119 ("Ntilde" "\\~{N}" nil
"Ñ" "N" "Ñ" "Ñ")
120 ("ntilde" "\\~{n}" nil
"ñ" "n" "ñ" "ñ")
121 ("Ograve" "\\`{O}" nil
"Ò" "O" "Ò" "Ò")
122 ("ograve" "\\`{o}" nil
"ò" "o" "ò" "ò")
123 ("Oacute" "\\'{O}" nil
"Ó" "O" "Ó" "Ó")
124 ("oacute" "\\'{o}" nil
"ó" "o" "ó" "ó")
125 ("Ocirc" "\\^{O}" nil
"Ô" "O" "Ô" "Ô")
126 ("ocirc" "\\^{o}" nil
"ô" "o" "ô" "ô")
127 ("Otilde" "\\~{O}" nil
"Õ" "O" "Õ" "Õ")
128 ("otilde" "\\~{o}" nil
"õ" "o" "õ" "õ")
129 ("Ouml" "\\\"{O}" nil
"Ö" "Oe" "Ö" "Ö")
130 ("ouml" "\\\"{o}" nil
"ö" "oe" "ö" "ö")
131 ("Oslash" "\\O" nil
"Ø" "O" "Ø" "Ø")
132 ("oslash" "\\o{}" nil
"ø" "o" "ø" "ø")
133 ("OElig" "\\OE{}" nil
"Œ" "OE" "OE" "Œ")
134 ("oelig" "\\oe{}" nil
"œ" "oe" "oe" "œ")
135 ("Scaron" "\\v{S}" nil
"Š" "S" "S" "Š")
136 ("scaron" "\\v{s}" nil
"š" "s" "s" "š")
137 ("szlig" "\\ss{}" nil
"ß" "ss" "ß" "ß")
138 ("Ugrave" "\\`{U}" nil
"Ù" "U" "Ù" "Ù")
139 ("ugrave" "\\`{u}" nil
"ù" "u" "ù" "ù")
140 ("Uacute" "\\'{U}" nil
"Ú" "U" "Ú" "Ú")
141 ("uacute" "\\'{u}" nil
"ú" "u" "ú" "ú")
142 ("Ucirc" "\\^{U}" nil
"Û" "U" "Û" "Û")
143 ("ucirc" "\\^{u}" nil
"û" "u" "û" "û")
144 ("Uuml" "\\\"{U}" nil
"Ü" "Ue" "Ü" "Ü")
145 ("uuml" "\\\"{u}" nil
"ü" "ue" "ü" "ü")
146 ("Yacute" "\\'{Y}" nil
"Ý" "Y" "Ý" "Ý")
147 ("yacute" "\\'{y}" nil
"ý" "y" "ý" "ý")
148 ("Yuml" "\\\"{Y}" nil
"Ÿ" "Y" "Y" "Ÿ")
149 ("yuml" "\\\"{y}" nil
"ÿ" "y" "ÿ" "ÿ")
151 "** Latin (special face)"
152 ("fnof" "\\textit{f}" nil
"ƒ" "f" "f" "ƒ")
153 ("real" "\\Re" t
"ℜ" "R" "R" "ℜ")
154 ("image" "\\Im" t
"ℑ" "I" "I" "ℑ")
155 ("weierp" "\\wp" t
"℘" "P" "P" "℘")
156 ("ell" "\\ell" t
"ℓ" "ell" "ell" "ℓ")
157 ("imath" "\\imath" t
"ı" "[dotless i]" "dotless i" "ı")
158 ("jmath" "\\jmath" t
"ȷ" "[dotless j]" "dotless j" "ȷ")
161 ("Alpha" "A" nil
"Α" "Alpha" "Alpha" "Α")
162 ("alpha" "\\alpha" t
"α" "alpha" "alpha" "α")
163 ("Beta" "B" nil
"Β" "Beta" "Beta" "Β")
164 ("beta" "\\beta" t
"β" "beta" "beta" "β")
165 ("Gamma" "\\Gamma" t
"Γ" "Gamma" "Gamma" "Γ")
166 ("gamma" "\\gamma" t
"γ" "gamma" "gamma" "γ")
167 ("Delta" "\\Delta" t
"Δ" "Delta" "Gamma" "Δ")
168 ("delta" "\\delta" t
"δ" "delta" "delta" "δ")
169 ("Epsilon" "E" nil
"Ε" "Epsilon" "Epsilon" "Ε")
170 ("epsilon" "\\epsilon" t
"ε" "epsilon" "epsilon" "ε")
171 ("varepsilon" "\\varepsilon" t
"ε" "varepsilon" "varepsilon" "ε")
172 ("Zeta" "Z" nil
"Ζ" "Zeta" "Zeta" "Ζ")
173 ("zeta" "\\zeta" t
"ζ" "zeta" "zeta" "ζ")
174 ("Eta" "H" nil
"Η" "Eta" "Eta" "Η")
175 ("eta" "\\eta" t
"η" "eta" "eta" "η")
176 ("Theta" "\\Theta" t
"Θ" "Theta" "Theta" "Θ")
177 ("theta" "\\theta" t
"θ" "theta" "theta" "θ")
178 ("thetasym" "\\vartheta" t
"ϑ" "theta" "theta" "ϑ")
179 ("vartheta" "\\vartheta" t
"ϑ" "theta" "theta" "ϑ")
180 ("Iota" "I" nil
"Ι" "Iota" "Iota" "Ι")
181 ("iota" "\\iota" t
"ι" "iota" "iota" "ι")
182 ("Kappa" "K" nil
"Κ" "Kappa" "Kappa" "Κ")
183 ("kappa" "\\kappa" t
"κ" "kappa" "kappa" "κ")
184 ("Lambda" "\\Lambda" t
"Λ" "Lambda" "Lambda" "Λ")
185 ("lambda" "\\lambda" t
"λ" "lambda" "lambda" "λ")
186 ("Mu" "M" nil
"Μ" "Mu" "Mu" "Μ")
187 ("mu" "\\mu" t
"μ" "mu" "mu" "μ")
188 ("nu" "\\nu" t
"ν" "nu" "nu" "ν")
189 ("Nu" "N" nil
"Ν" "Nu" "Nu" "Ν")
190 ("Xi" "\\Xi" t
"Ξ" "Xi" "Xi" "Ξ")
191 ("xi" "\\xi" t
"ξ" "xi" "xi" "ξ")
192 ("Omicron" "O" nil
"Ο" "Omicron" "Omicron" "Ο")
193 ("omicron" "\\textit{o}" nil
"ο" "omicron" "omicron" "ο")
194 ("Pi" "\\Pi" t
"Π" "Pi" "Pi" "Π")
195 ("pi" "\\pi" t
"π" "pi" "pi" "π")
196 ("Rho" "P" nil
"Ρ" "Rho" "Rho" "Ρ")
197 ("rho" "\\rho" t
"ρ" "rho" "rho" "ρ")
198 ("Sigma" "\\Sigma" t
"Σ" "Sigma" "Sigma" "Σ")
199 ("sigma" "\\sigma" t
"σ" "sigma" "sigma" "σ")
200 ("sigmaf" "\\varsigma" t
"ς" "sigmaf" "sigmaf" "ς")
201 ("varsigma" "\\varsigma" t
"ς" "varsigma" "varsigma" "ς")
202 ("Tau" "T" nil
"Τ" "Tau" "Tau" "Τ")
203 ("Upsilon" "\\Upsilon" t
"Υ" "Upsilon" "Upsilon" "Υ")
204 ("upsih" "\\Upsilon" t
"ϒ" "upsilon" "upsilon" "ϒ")
205 ("upsilon" "\\upsilon" t
"υ" "upsilon" "upsilon" "υ")
206 ("Phi" "\\Phi" t
"Φ" "Phi" "Phi" "Φ")
207 ("phi" "\\phi" t
"φ" "phi" "phi" "φ")
208 ("varphi" "\\varphi" t
"ϕ" "varphi" "varphi" "ɸ")
209 ("Chi" "X" nil
"Χ" "Chi" "Chi" "Χ")
210 ("chi" "\\chi" t
"χ" "chi" "chi" "χ")
211 ("acutex" "\\acute x" t
"´x" "'x" "'x" "𝑥́")
212 ("Psi" "\\Psi" t
"Ψ" "Psi" "Psi" "Ψ")
213 ("psi" "\\psi" t
"ψ" "psi" "psi" "ψ")
214 ("tau" "\\tau" t
"τ" "tau" "tau" "τ")
215 ("Omega" "\\Omega" t
"Ω" "Omega" "Omega" "Ω")
216 ("omega" "\\omega" t
"ω" "omega" "omega" "ω")
217 ("piv" "\\varpi" t
"ϖ" "omega-pi" "omega-pi" "ϖ")
218 ("varpi" "\\varpi" t
"ϖ" "omega-pi" "omega-pi" "ϖ")
219 ("partial" "\\partial" t
"∂" "[partial differential]" "[partial differential]" "∂")
222 ("alefsym" "\\aleph" t
"ℵ" "aleph" "aleph" "ℵ")
223 ("aleph" "\\aleph" t
"ℵ" "aleph" "aleph" "ℵ")
224 ("gimel" "\\gimel" t
"ℷ" "gimel" "gimel" "ℷ")
225 ("beth" "\\beth" t
"ℶ" "beth" "beth" "ב")
226 ("dalet" "\\daleth" t
"ℸ" "dalet" "dalet" "ד")
229 ("ETH" "\\DH{}" nil
"Ð" "D" "Ð" "Ð")
230 ("eth" "\\dh{}" nil
"ð" "dh" "ð" "ð")
231 ("THORN" "\\TH{}" nil
"Þ" "TH" "Þ" "Þ")
232 ("thorn" "\\th{}" nil
"þ" "th" "þ" "þ")
236 ("dots" "\\dots{}" nil
"…" "..." "..." "…")
237 ("cdots" "\\cdots{}" t
"⋯" "..." "..." "⋯")
238 ("hellip" "\\dots{}" nil
"…" "..." "..." "…")
239 ("middot" "\\textperiodcentered{}" nil
"·" "." "·" "·")
240 ("iexcl" "!`" nil
"¡" "!" "¡" "¡")
241 ("iquest" "?`" nil
"¿" "?" "¿" "¿")
244 ("shy" "\\-" nil
"­" "" "" "")
245 ("ndash" "--" nil
"–" "-" "-" "–")
246 ("mdash" "---" nil
"—" "--" "--" "—")
249 ("quot" "\\textquotedbl{}" nil
""" "\"" "\"" "\"")
250 ("acute" "\\textasciiacute{}" nil
"´" "'" "´" "´")
251 ("ldquo" "\\textquotedblleft{}" nil
"“" "\"" "\"" "“")
252 ("rdquo" "\\textquotedblright{}" nil
"”" "\"" "\"" "”")
253 ("bdquo" "\\quotedblbase{}" nil
"„" "\"" "\"" "„")
254 ("lsquo" "\\textquoteleft{}" nil
"‘" "`" "`" "‘")
255 ("rsquo" "\\textquoteright{}" nil
"’" "'" "'" "’")
256 ("sbquo" "\\quotesinglbase{}" nil
"‚" "," "," "‚")
257 ("laquo" "\\guillemotleft{}" nil
"«" "<<" "«" "«")
258 ("raquo" "\\guillemotright{}" nil
"»" ">>" "»" "»")
259 ("lsaquo" "\\guilsinglleft{}" nil
"‹" "<" "<" "‹")
260 ("rsaquo" "\\guilsinglright{}" nil
"›" ">" ">" "›")
263 "** Misc. (often used)"
264 ("circ" "\\^{}" nil
"ˆ" "^" "^" "ˆ")
265 ("vert" "\\vert{}" t
"|" "|" "|" "|")
266 ("brvbar" "\\textbrokenbar{}" nil
"¦" "|" "¦" "¦")
267 ("S" "\\S" nil
"§" "paragraph" "§" "§")
268 ("sect" "\\S" nil
"§" "paragraph" "§" "§")
269 ("amp" "\\&" nil
"&" "&" "&" "&")
270 ("lt" "\\textless{}" nil
"<" "<" "<" "<")
271 ("gt" "\\textgreater{}" nil
">" ">" ">" ">")
272 ("tilde" "\\textasciitilde{}" nil
"~" "~" "~" "~")
273 ("slash" "/" nil
"/" "/" "/" "/")
274 ("plus" "+" nil
"+" "+" "+" "+")
275 ("under" "\\_" nil
"_" "_" "_" "_")
276 ("equal" "=" nil
"=" "=" "=" "=")
277 ("asciicirc" "\\textasciicircum{}" nil
"^" "^" "^" "^")
278 ("dagger" "\\textdagger{}" nil
"†" "[dagger]" "[dagger]" "†")
279 ("dag" "\\dag{}" nil
"†" "[dagger]" "[dagger]" "†")
280 ("Dagger" "\\textdaggerdbl{}" nil
"‡" "[doubledagger]" "[doubledagger]" "‡")
281 ("ddag" "\\ddag{}" nil
"‡" "[doubledagger]" "[doubledagger]" "‡")
284 ("nbsp" "~" nil
" " " " " " " ")
285 ("ensp" "\\hspace*{.5em}" nil
" " " " " " " ")
286 ("emsp" "\\hspace*{1em}" nil
" " " " " " " ")
287 ("thinsp" "\\hspace*{.2em}" nil
" " " " " " " ")
290 ("curren" "\\textcurrency{}" nil
"¤" "curr." "¤" "¤")
291 ("cent" "\\textcent{}" nil
"¢" "cent" "¢" "¢")
292 ("pound" "\\pounds{}" nil
"£" "pound" "£" "£")
293 ("yen" "\\textyen{}" nil
"¥" "yen" "¥" "¥")
294 ("euro" "\\texteuro{}" nil
"€" "EUR" "EUR" "€")
295 ("EUR" "\\EUR{}" nil
"€" "EUR" "EUR" "€")
296 ("EURdig" "\\EURdig{}" nil
"€" "EUR" "EUR" "€")
297 ("EURhv" "\\EURhv{}" nil
"€" "EUR" "EUR" "€")
298 ("EURcr" "\\EURcr{}" nil
"€" "EUR" "EUR" "€")
299 ("EURtm" "\\EURtm{}" nil
"€" "EUR" "EUR" "€")
302 ("copy" "\\textcopyright{}" nil
"©" "(c)" "©" "©")
303 ("reg" "\\textregistered{}" nil
"®" "(r)" "®" "®")
304 ("trade" "\\texttrademark{}" nil
"™" "TM" "TM" "™")
307 ("minus" "\\minus" t
"−" "-" "-" "−")
308 ("pm" "\\textpm{}" nil
"±" "+-" "±" "±")
309 ("plusmn" "\\textpm{}" nil
"±" "+-" "±" "±")
310 ("times" "\\texttimes{}" nil
"×" "*" "×" "×")
311 ("frasl" "/" nil
"⁄" "/" "/" "⁄")
312 ("colon" "\\colon" t
":" ":" ":" ":")
313 ("div" "\\textdiv{}" nil
"÷" "/" "÷" "÷")
314 ("frac12" "\\textonehalf{}" nil
"½" "1/2" "½" "½")
315 ("frac14" "\\textonequarter{}" nil
"¼" "1/4" "¼" "¼")
316 ("frac34" "\\textthreequarters{}" nil
"¾" "3/4" "¾" "¾")
317 ("permil" "\\textperthousand{}" nil
"‰" "per thousand" "per thousand" "‰")
318 ("sup1" "\\textonesuperior{}" nil
"¹" "^1" "¹" "¹")
319 ("sup2" "\\texttwosuperior{}" nil
"²" "^2" "²" "²")
320 ("sup3" "\\textthreesuperior{}" nil
"³" "^3" "³" "³")
321 ("radic" "\\sqrt{\\,}" t
"√" "[square root]" "[square root]" "√")
322 ("sum" "\\sum" t
"∑" "[sum]" "[sum]" "∑")
323 ("prod" "\\prod" t
"∏" "[product]" "[n-ary product]" "∏")
324 ("micro" "\\textmu{}" nil
"µ" "micro" "µ" "µ")
325 ("macr" "\\textasciimacron{}" nil
"¯" "[macron]" "¯" "¯")
326 ("deg" "\\textdegree{}" nil
"°" "degree" "°" "°")
327 ("prime" "\\prime" t
"′" "'" "'" "′")
328 ("Prime" "\\prime{}\\prime" t
"″" "''" "''" "″")
329 ("infin" "\\propto" t
"∞" "[infinity]" "[infinity]" "∞")
330 ("infty" "\\infty" t
"∞" "[infinity]" "[infinity]" "∞")
331 ("prop" "\\propto" t
"∝" "[proportional to]" "[proportional to]" "∝")
332 ("propto" "\\propto" t
"∝" "[proportional to]" "[proportional to]" "∝")
333 ("not" "\\textlnot{}" nil
"¬" "[angled dash]" "¬" "¬")
334 ("neg" "\\neg{}" t
"¬" "[angled dash]" "¬" "¬")
335 ("land" "\\land" t
"∧" "[logical and]" "[logical and]" "∧")
336 ("wedge" "\\wedge" t
"∧" "[logical and]" "[logical and]" "∧")
337 ("lor" "\\lor" t
"∨" "[logical or]" "[logical or]" "∨")
338 ("vee" "\\vee" t
"∨" "[logical or]" "[logical or]" "∨")
339 ("cap" "\\cap" t
"∩" "[intersection]" "[intersection]" "∩")
340 ("cup" "\\cup" t
"∪" "[union]" "[union]" "∪")
341 ("int" "\\int" t
"∫" "[integral]" "[integral]" "∫")
342 ("therefore" "\\therefore" t
"∴" "[therefore]" "[therefore]" "∴")
343 ("there4" "\\therefore" t
"∴" "[therefore]" "[therefore]" "∴")
344 ("because" "\\because" t
"∵" "[because]" "[because]" "∵")
345 ("sim" "\\sim" t
"∼" "~" "~" "∼")
346 ("cong" "\\cong" t
"≅" "[approx. equal to]" "[approx. equal to]" "≅")
347 ("simeq" "\\simeq" t
"≅" "[approx. equal to]" "[approx. equal to]" "≅")
348 ("asymp" "\\asymp" t
"≈" "[almost equal to]" "[almost equal to]" "≈")
349 ("approx" "\\approx" t
"≈" "[almost equal to]" "[almost equal to]" "≈")
350 ("ne" "\\ne" t
"≠" "[not equal to]" "[not equal to]" "≠")
351 ("neq" "\\neq" t
"≠" "[not equal to]" "[not equal to]" "≠")
352 ("equiv" "\\equiv" t
"≡" "[identical to]" "[identical to]" "≡")
354 ("triangleq" "\\triangleq" t
"≜" "[defined to]" "[defined to]" "≜")
355 ("le" "\\le" t
"≤" "<=" "<=" "≤")
356 ("leq" "\\le" t
"≤" "<=" "<=" "≤")
357 ("ge" "\\ge" t
"≥" ">=" ">=" "≥")
358 ("geq" "\\ge" t
"≥" ">=" ">=" "≥")
359 ("lessgtr" "\\lessgtr" t
"≶" "[less than or greater than]" "[less than or greater than]" "≶")
360 ("lesseqgtr" "\\lesseqgtr" t
"⋚" "[less than or equal or greater than or equal]" "[less than or equal or greater than or equal]" "⋚")
361 ("ll" "\\ll" t
"≪" "<<" "<<" "≪")
362 ("Ll" "\lll" t
"⋘" "<<<" "<<<" "⋘")
363 ("lll" "\lll" t
"⋘" "<<<" "<<<" "⋘")
364 ("gg" "\\gg" t
"≫" ">>" ">>" "≫")
365 ("Gg" "\\ggg" t
"⋙" ">>>" ">>>" "⋙")
366 ("ggg" "\\ggg" t
"⋙" ">>>" ">>>" "⋙")
367 ("prec" "\\prec" t
"≺" "[precedes]" "[precedes]" "≺")
368 ("preceq" "\\preceq" t
"≼" "[precedes or equal]" "[precedes or equal]" "≼")
369 ("preccurlyeq" "\\preccurlyeq" t
"≼" "[precedes or equal]" "[precedes or equal]" "≼")
370 ("succ" "\\succ" t
"≻" "[succeeds]" "[succeeds]" "≻")
371 ("succeq" "\\succeq" t
"≽" "[succeeds or equal]" "[succeeds or equal]" "≽")
372 ("succcurlyeq" "\\succcurlyeq" t
"≽" "[succeeds or equal]" "[succeeds or equal]" "≽")
373 ("sub" "\\subset" t
"⊂" "[subset of]" "[subset of]" "⊂")
374 ("subset" "\\subset" t
"⊂" "[subset of]" "[subset of]" "⊂")
375 ("sup" "\\supset" t
"⊃" "[superset of]" "[superset of]" "⊃")
376 ("supset" "\\supset" t
"⊃" "[superset of]" "[superset of]" "⊃")
377 ("nsub" "\\not\\subset" t
"⊄" "[not a subset of]" "[not a subset of" "⊄")
378 ("sube" "\\subseteq" t
"⊆" "[subset of or equal to]" "[subset of or equal to]" "⊆")
379 ("nsup" "\\not\\supset" t
"⊅" "[not a superset of]" "[not a superset of]" "⊅")
380 ("supe" "\\supseteq" t
"⊇" "[superset of or equal to]" "[superset of or equal to]" "⊇")
381 ("setminus" "\\setminus" t
"∖" "\" "\" "⧵")
382 ("forall" "\\forall" t
"∀" "[for all]" "[for all]" "∀")
383 ("exist" "\\exists" t
"∃" "[there exists]" "[there exists]" "∃")
384 ("exists" "\\exists" t
"∃" "[there exists]" "[there exists]" "∃")
385 ("nexist" "\\nexists" t
"∃" "[there does not exists]" "[there does not exists]" "∄")
386 ("nexists" "\\nexists" t
"∃" "[there does not exists]" "[there does not exists]" "∄")
387 ("empty" "\\empty" t
"∅" "[empty set]" "[empty set]" "∅")
388 ("emptyset" "\\emptyset" t
"∅" "[empty set]" "[empty set]" "∅")
389 ("isin" "\\in" t
"∈" "[element of]" "[element of]" "∈")
390 ("in" "\\in" t
"∈" "[element of]" "[element of]" "∈")
391 ("notin" "\\notin" t
"∉" "[not an element of]" "[not an element of]" "∉")
392 ("ni" "\\ni" t
"∋" "[contains as member]" "[contains as member]" "∋")
393 ("nabla" "\\nabla" t
"∇" "[nabla]" "[nabla]" "∇")
394 ("ang" "\\angle" t
"∠" "[angle]" "[angle]" "∠")
395 ("angle" "\\angle" t
"∠" "[angle]" "[angle]" "∠")
396 ("perp" "\\perp" t
"⊥" "[up tack]" "[up tack]" "⊥")
397 ("sdot" "\\cdot" t
"⋅" "[dot]" "[dot]" "⋅")
398 ("cdot" "\\cdot" t
"⋅" "[dot]" "[dot]" "⋅")
399 ("lceil" "\\lceil" t
"⌈" "[left ceiling]" "[left ceiling]" "⌈")
400 ("rceil" "\\rceil" t
"⌉" "[right ceiling]" "[right ceiling]" "⌉")
401 ("lfloor" "\\lfloor" t
"⌊" "[left floor]" "[left floor]" "⌊")
402 ("rfloor" "\\rfloor" t
"⌋" "[right floor]" "[right floor]" "⌋")
403 ("lang" "\\langle" t
"⟨" "<" "<" "⟨")
404 ("rang" "\\rangle" t
"⟩" ">" ">" "⟩")
405 ("langle" "\\langle" t
"⟨" "<" "<" "⟨")
406 ("rangle" "\\rangle" t
"⟩" ">" ">" "⟩")
407 ("hbar" "\\hbar" t
"ℏ" "hbar" "hbar" "ℏ")
408 ("mho" "\\mho" t
"℧" "mho" "mho" "℧")
411 ("larr" "\\leftarrow" t
"←" "<-" "<-" "←")
412 ("leftarrow" "\\leftarrow" t
"←" "<-" "<-" "←")
413 ("gets" "\\gets" t
"←" "<-" "<-" "←")
414 ("lArr" "\\Leftarrow" t
"⇐" "<=" "<=" "⇐")
415 ("Leftarrow" "\\Leftarrow" t
"⇐" "<=" "<=" "⇐")
416 ("uarr" "\\uparrow" t
"↑" "[uparrow]" "[uparrow]" "↑")
417 ("uparrow" "\\uparrow" t
"↑" "[uparrow]" "[uparrow]" "↑")
418 ("uArr" "\\Uparrow" t
"⇑" "[dbluparrow]" "[dbluparrow]" "⇑")
419 ("Uparrow" "\\Uparrow" t
"⇑" "[dbluparrow]" "[dbluparrow]" "⇑")
420 ("rarr" "\\rightarrow" t
"→" "->" "->" "→")
421 ("to" "\\to" t
"→" "->" "->" "→")
422 ("rightarrow" "\\rightarrow" t
"→" "->" "->" "→")
423 ("rArr" "\\Rightarrow" t
"⇒" "=>" "=>" "⇒")
424 ("Rightarrow" "\\Rightarrow" t
"⇒" "=>" "=>" "⇒")
425 ("darr" "\\downarrow" t
"↓" "[downarrow]" "[downarrow]" "↓")
426 ("downarrow" "\\downarrow" t
"↓" "[downarrow]" "[downarrow]" "↓")
427 ("dArr" "\\Downarrow" t
"⇓" "[dbldownarrow]" "[dbldownarrow]" "⇓")
428 ("Downarrow" "\\Downarrow" t
"⇓" "[dbldownarrow]" "[dbldownarrow]" "⇓")
429 ("harr" "\\leftrightarrow" t
"↔" "<->" "<->" "↔")
430 ("leftrightarrow" "\\leftrightarrow" t
"↔" "<->" "<->" "↔")
431 ("hArr" "\\Leftrightarrow" t
"⇔" "<=>" "<=>" "⇔")
432 ("Leftrightarrow" "\\Leftrightarrow" t
"⇔" "<=>" "<=>" "⇔")
433 ("crarr" "\\hookleftarrow" t
"↵" "<-'" "<-'" "↵")
434 ("hookleftarrow" "\\hookleftarrow" t
"↵" "<-'" "<-'" "↵")
437 ("arccos" "\\arccos" t
"arccos" "arccos" "arccos" "arccos")
438 ("arcsin" "\\arcsin" t
"arcsin" "arcsin" "arcsin" "arcsin")
439 ("arctan" "\\arctan" t
"arctan" "arctan" "arctan" "arctan")
440 ("arg" "\\arg" t
"arg" "arg" "arg" "arg")
441 ("cos" "\\cos" t
"cos" "cos" "cos" "cos")
442 ("cosh" "\\cosh" t
"cosh" "cosh" "cosh" "cosh")
443 ("cot" "\\cot" t
"cot" "cot" "cot" "cot")
444 ("coth" "\\coth" t
"coth" "coth" "coth" "coth")
445 ("csc" "\\csc" t
"csc" "csc" "csc" "csc")
446 ("deg" "\\deg" t
"°" "deg" "deg" "deg")
447 ("det" "\\det" t
"det" "det" "det" "det")
448 ("dim" "\\dim" t
"dim" "dim" "dim" "dim")
449 ("exp" "\\exp" t
"exp" "exp" "exp" "exp")
450 ("gcd" "\\gcd" t
"gcd" "gcd" "gcd" "gcd")
451 ("hom" "\\hom" t
"hom" "hom" "hom" "hom")
452 ("inf" "\\inf" t
"inf" "inf" "inf" "inf")
453 ("ker" "\\ker" t
"ker" "ker" "ker" "ker")
454 ("lg" "\\lg" t
"lg" "lg" "lg" "lg")
455 ("lim" "\\lim" t
"lim" "lim" "lim" "lim")
456 ("liminf" "\\liminf" t
"liminf" "liminf" "liminf" "liminf")
457 ("limsup" "\\limsup" t
"limsup" "limsup" "limsup" "limsup")
458 ("ln" "\\ln" t
"ln" "ln" "ln" "ln")
459 ("log" "\\log" t
"log" "log" "log" "log")
460 ("max" "\\max" t
"max" "max" "max" "max")
461 ("min" "\\min" t
"min" "min" "min" "min")
462 ("Pr" "\\Pr" t
"Pr" "Pr" "Pr" "Pr")
463 ("sec" "\\sec" t
"sec" "sec" "sec" "sec")
464 ("sin" "\\sin" t
"sin" "sin" "sin" "sin")
465 ("sinh" "\\sinh" t
"sinh" "sinh" "sinh" "sinh")
466 ("sup" "\\sup" t
"⊃" "sup" "sup" "sup")
467 ("tan" "\\tan" t
"tan" "tan" "tan" "tan")
468 ("tanh" "\\tanh" t
"tanh" "tanh" "tanh" "tanh")
471 ("bull" "\\textbullet{}" nil
"•" "*" "*" "•")
472 ("bullet" "\\textbullet{}" nil
"•" "*" "*" "•")
473 ("star" "\\star" t
"*" "*" "*" "⋆")
474 ("lowast" "\\ast" t
"∗" "*" "*" "∗")
475 ("ast" "\\ast" t
"∗" "*" "*" "*")
476 ("odot" "\\odot" t
"o" "[circled dot]" "[circled dot]" "ʘ")
477 ("oplus" "\\oplus" t
"⊕" "[circled plus]" "[circled plus]" "⊕")
478 ("otimes" "\\otimes" t
"⊗" "[circled times]" "[circled times]" "⊗")
479 ("check" "\\checkmark" t
"✓" "[checkmark]" "[checkmark]" "✓")
480 ("checkmark" "\\checkmark" t
"✓" "[checkmark]" "[checkmark]" "✓")
482 "** Miscellaneous (seldom used)"
483 ("para" "\\P{}" nil
"¶" "[pilcrow]" "¶" "¶")
484 ("ordf" "\\textordfeminine{}" nil
"ª" "_a_" "ª" "ª")
485 ("ordm" "\\textordmasculine{}" nil
"º" "_o_" "º" "º")
486 ("cedil" "\\c{}" nil
"¸" "[cedilla]" "¸" "¸")
487 ("oline" "\\overline{~}" t
"‾" "[overline]" "¯" "‾")
488 ("uml" "\\textasciidieresis{}" nil
"¨" "[diaeresis]" "¨" "¨")
489 ("zwnj" "\\/{}" nil
"‌" "" "" "")
490 ("zwj" "" nil
"‍" "" "" "")
491 ("lrm" "" nil
"‎" "" "" "")
492 ("rlm" "" nil
"‏" "" "" "")
495 ("smile" "\\smile" t
"⌣" ":-)" ":-)" "⌣")
496 ("frown" "\\frown" t
"⌢" ":-(" ":-(" "⌢")
497 ("smiley" "\\smiley{}" nil
"☺" ":-)" ":-)" "☺")
498 ("blacksmile" "\\blacksmiley{}" nil
"☻" ":-)" ":-)" "☻")
499 ("sad" "\\frownie{}" nil
"☹" ":-(" ":-(" "☹")
502 ("clubs" "\\clubsuit" t
"♣" "[clubs]" "[clubs]" "♣")
503 ("clubsuit" "\\clubsuit" t
"♣" "[clubs]" "[clubs]" "♣")
504 ("spades" "\\spadesuit" t
"♠" "[spades]" "[spades]" "♠")
505 ("spadesuit" "\\spadesuit" t
"♠" "[spades]" "[spades]" "♠")
506 ("hearts" "\\heartsuit" t
"♥" "[hearts]" "[hearts]" "♥")
507 ("heartsuit" "\\heartsuit" t
"♥" "[hearts]" "[hearts]" "♥")
508 ("diams" "\\diamondsuit" t
"♦" "[diamonds]" "[diamonds]" "◆")
509 ("diamondsuit" "\\diamondsuit" t
"♦" "[diamonds]" "[diamonds]" "◆")
510 ("diamond" "\\diamondsuit" t
"⋄" "[diamond]" "[diamond]" "◆")
511 ("Diamond" "\\diamondsuit" t
"⋄" "[diamond]" "[diamond]" "◆")
512 ("loz" "\\lozenge" t
"◊" "[lozenge]" "[lozenge]" "⧫")
514 "Default entities used in Org-mode to produce special characters.
515 For details see `org-entities-user'.")
517 (defsubst org-entity-get
(name)
518 "Get the proper association for NAME from the entity lists.
519 This first checks the user list, then the built-in list."
520 (or (assoc name org-entities-user
)
521 (assoc name org-entities
)))
523 (defun org-entity-get-representation (name kind
)
524 "Get the correct representation of entity NAME for export type KIND.
525 Kind can be any of `latex', `html', `ascii', `latin1', or `utf8'."
526 (let* ((e (org-entity-get name
))
527 (n (cdr (assq kind
'((latex .
1) (html .
3) (ascii .
4)
528 (latin1 .
5) (utf8 .
6)))))
529 (r (and e n
(nth n e
))))
531 (not org-entities-ascii-explanatory
)
532 (memq kind
'(ascii latin1 utf8
))
533 (= (string-to-char r
) ?\
[))
537 (defsubst org-entity-latex-math-p
(name)
538 "Does entity NAME require math mode in LaTeX?"
539 (nth 2 (org-entity-get name
)))
541 ;; Helpfunctions to create a table for orgmode.org/worg/org-symbols.org
543 (defun org-entities-create-table ()
544 "Create an Org mode table with all entities."
546 (let ((pos (point)) e latex mathp html latin utf8 name ascii
)
547 (insert "|Name|LaTeX code|LaTeX|HTML code |HTML|ASCII|Latin1|UTF-8\n|-\n")
548 (mapc (lambda (e) (when (listp e
)
556 (if (equal ascii
"|") (setq ascii
"\\vert"))
557 (if (equal latin
"|") (setq latin
"\\vert"))
558 (if (equal utf8
"|") (setq utf8
"\\vert"))
559 (if (equal ascii
"=>") (setq ascii
"= >"))
560 (if (equal latin
"=>") (setq latin
"= >"))
562 "|" (format "=%s=" latex
)
563 "|" (format (if mathp
"$%s$" "$\\mbox{%s}$")
565 "|" (format "=%s=" html
) "|" html
566 "|" ascii
"|" latin
"|" utf8
572 (defvar org-pretty-entities
) ;; declare defcustom from org
573 (defun org-entities-help ()
574 "Create a Help buffer with all available entities."
576 (with-output-to-temp-buffer "*Org Entity Help*"
577 (princ "Org-mode entities\n=================\n\n")
578 (let ((ll (append '("* User-defined additions (variable org-entities-user)")
581 e latex mathp html latin utf8 name ascii
585 " Symbol Org entity LaTeX code HTML code\n"
586 " -----------------------------------------------------------\n")))
593 (setq lastwasstring t
))
594 (if lastwasstring
(princ head
))
595 (setq lastwasstring nil
)
600 (princ (format " %-8s \\%-16s %-22s %-13s\n"
601 utf8 name latex html
))))))
602 (with-current-buffer "*Org Entity Help*"
604 (when org-pretty-entities
605 (org-toggle-pretty-entities)))
606 (select-window (get-buffer-window "*Org Entity Help*")))
609 (defun replace-amp ()
610 "Postprocess HTML file to unescape the ampersand."
612 (while (re-search-forward "<td>&\\([^<;]+;\\)" nil t
)
613 (replace-match (concat "<td>&" (match-string 1)) t t
)))
615 (provide 'org-entities
)
621 ;;; org-entities.el ends here