added function for org macros
This commit is contained in:
parent
d8a4a5a274
commit
845b6cfd7a
228
funcs.el
228
funcs.el
@ -9,111 +9,111 @@
|
|||||||
;;
|
;;
|
||||||
;;; License: GPLv3
|
;;; License: GPLv3
|
||||||
|
|
||||||
(setq conlanging//matter-latin-to-runes '((", *" . "᛬")
|
(setq conlanging//matter-latin-to-runes '((", *" . "᛬")
|
||||||
("\\. *" . "᛭")
|
("\\. *" . "᛭")
|
||||||
(" +" . "᛫")
|
(" +" . "᛫")
|
||||||
("ċ" . "ᛇ")
|
("ċ" . "ᛇ")
|
||||||
("ch" . "ᛇ")
|
("ch" . "ᛇ")
|
||||||
("ae" . "ᚫ")
|
("ae" . "ᚫ")
|
||||||
("æ" . "ᚫ")
|
("æ" . "ᚫ")
|
||||||
("dh" . "ᛋ")
|
("dh" . "ᛋ")
|
||||||
("z" . "ᛋ")
|
("z" . "ᛋ")
|
||||||
("ð" . "ᛋ")
|
("ð" . "ᛋ")
|
||||||
("th" . "ᚦ")
|
("th" . "ᚦ")
|
||||||
("s" . "ᚦ")
|
("s" . "ᚦ")
|
||||||
("þ" . "ᚦ")
|
("þ" . "ᚦ")
|
||||||
("w" . "ᚹ")
|
("w" . "ᚹ")
|
||||||
("ƿ" . "ᚹ")
|
("ƿ" . "ᚹ")
|
||||||
("g" . "ᚷ")
|
("g" . "ᚷ")
|
||||||
("ᵹ" . "ᚷ")
|
("ᵹ" . "ᚷ")
|
||||||
("ea" . "ᛠ")
|
("ea" . "ᛠ")
|
||||||
("f" . "ᚠ")
|
("f" . "ᚠ")
|
||||||
("u" . "ᚢ")
|
("u" . "ᚢ")
|
||||||
("o" . "ᚩ")
|
("o" . "ᚩ")
|
||||||
("r" . "ᚱ")
|
("r" . "ᚱ")
|
||||||
("c" . "ᚳ")
|
("c" . "ᚳ")
|
||||||
("h" . "ᚻ")
|
("h" . "ᚻ")
|
||||||
("n" . "ᚾ")
|
("n" . "ᚾ")
|
||||||
("i" . "ᛁ")
|
("i" . "ᛁ")
|
||||||
("j" . "ᛄ")
|
("j" . "ᛄ")
|
||||||
("p" . "ᛈ")
|
("p" . "ᛈ")
|
||||||
("v" . "ᛝ")
|
("v" . "ᛝ")
|
||||||
("t" . "ᛏ")
|
("t" . "ᛏ")
|
||||||
("b" . "ᛒ")
|
("b" . "ᛒ")
|
||||||
("e" . "ᛖ")
|
("e" . "ᛖ")
|
||||||
("m" . "ᛗ")
|
("m" . "ᛗ")
|
||||||
("l" . "ᛚ")
|
("l" . "ᛚ")
|
||||||
("d" . "ᛞ")
|
("d" . "ᛞ")
|
||||||
("é" . "ᛟ")
|
("é" . "ᛟ")
|
||||||
("a" . "ᚪ")
|
("a" . "ᚪ")
|
||||||
("y" . "ᚣ")))
|
("y" . "ᚣ")))
|
||||||
(setq conlanging//matter-latin-to-native '((" +" . " ")
|
(setq conlanging//matter-latin-to-native '((" +" . " ")
|
||||||
("ch" . "ċ")
|
("ch" . "ċ")
|
||||||
("ae" . "æ")
|
("ae" . "æ")
|
||||||
("th" . "þ")
|
("th" . "þ")
|
||||||
("s" . "þ")
|
("s" . "þ")
|
||||||
("dh" . "ð")
|
("dh" . "ð")
|
||||||
("z" . "ð")
|
("z" . "ð")
|
||||||
("w" . "ƿ")
|
("w" . "ƿ")
|
||||||
("j" . "i")))
|
("j" . "i")))
|
||||||
(setq conlanging//matter-latin-to-latex-runes '((", *" . ":")
|
(setq conlanging//matter-latin-to-latex '((", *" . ":")
|
||||||
("\\. *" . "*")
|
("\\. *" . "*")
|
||||||
(" +" . ".")
|
(" +" . ".")
|
||||||
("ch" . "I")
|
("ch" . "I")
|
||||||
("ċ" . "I")
|
("ċ" . "I")
|
||||||
("ae" . "æ")
|
("ae" . "æ")
|
||||||
("ea" . "\\\\ea")
|
("ea" . "\\\\ea")
|
||||||
("ƿ" . "w")
|
("ƿ" . "w")
|
||||||
("dh" . "s")
|
("dh" . "s")
|
||||||
("z" . "s")
|
("z" . "s")
|
||||||
("ð" . "s")
|
("ð" . "s")
|
||||||
("th" . "þ")
|
("th" . "þ")
|
||||||
("s" . "þ")
|
("s" . "þ")
|
||||||
("v" . "\\\\ng")
|
("v" . "\\\\ng")
|
||||||
("é " . "\\\\oe")))
|
("é " . "\\\\oe")))
|
||||||
|
|
||||||
(setq conlanging//einnlanda-latin-to-latex '((", *" . "\\\\tripledot")
|
(setq conlanging//einnlanda-latin-to-latex '((", *" . "\\\\tripledot")
|
||||||
("\\. *" . "\\\\tripledot")
|
("\\. *" . "\\\\tripledot")
|
||||||
(" +" . ":")
|
(" +" . ":")
|
||||||
("hw" . "x")
|
("hw" . "x")
|
||||||
("ø" . "\\\\o")
|
("ø" . "\\\\o")
|
||||||
("ö" . "\\\\oO")
|
("ö" . "\\\\oO")
|
||||||
("ó" . "v")
|
("ó" . "v")
|
||||||
("ń" . "\\\\ndot")
|
("ń" . "\\\\ndot")
|
||||||
("v" . "b")))
|
("v" . "b")))
|
||||||
(setq conlanging//einnlanda-latin-to-runes '((", *" . "⁝")
|
(setq conlanging//einnlanda-latin-to-runes '((", *" . "⁝")
|
||||||
("\\. *" . "⁝")
|
("\\. *" . "⁝")
|
||||||
(" +" . "᛬")
|
(" +" . "᛬")
|
||||||
("hw" . "ᛪ")
|
("hw" . "ᛪ")
|
||||||
("i" . "ᛁ")
|
("i" . "ᛁ")
|
||||||
("j" . "ᛁ")
|
("j" . "ᛁ")
|
||||||
("y" . "ᛦ")
|
("y" . "ᛦ")
|
||||||
("u" . "ᚢ")
|
("u" . "ᚢ")
|
||||||
("e" . "ᛂ")
|
("e" . "ᛂ")
|
||||||
("ø" . "ᚯ")
|
("ø" . "ᚯ")
|
||||||
("o" . "ᚮ")
|
("o" . "ᚮ")
|
||||||
("ö" . "ᚰ")
|
("ö" . "ᚰ")
|
||||||
("ó" . "ᚤ")
|
("ó" . "ᚤ")
|
||||||
("æ" . "ᛅ")
|
("æ" . "ᛅ")
|
||||||
("a" . "ᛆ")
|
("a" . "ᛆ")
|
||||||
("m" . "ᛘ")
|
("m" . "ᛘ")
|
||||||
("n" . "ᚾ")
|
("n" . "ᚾ")
|
||||||
("ń" . "ᛀ")
|
("ń" . "ᛀ")
|
||||||
("p" . "ᛔ")
|
("p" . "ᛔ")
|
||||||
("b" . "ᛒ")
|
("b" . "ᛒ")
|
||||||
("t" . "ᛐ")
|
("t" . "ᛐ")
|
||||||
("d" . "ᛑ")
|
("d" . "ᛑ")
|
||||||
("k" . "ᚴ")
|
("k" . "ᚴ")
|
||||||
("g" . "ᚵ")
|
("g" . "ᚵ")
|
||||||
("f" . "ᚠ")
|
("f" . "ᚠ")
|
||||||
("v" . "ᛒ")
|
("v" . "ᛒ")
|
||||||
("þ" . "ᚦ")
|
("þ" . "ᚦ")
|
||||||
("ð" . "ᚧ")
|
("ð" . "ᚧ")
|
||||||
("s" . "ᛋ")
|
("s" . "ᛋ")
|
||||||
("h" . "ᚼ")
|
("h" . "ᚼ")
|
||||||
("w" . "ᚥ")
|
("w" . "ᚥ")
|
||||||
("r" . "ᚱ")
|
("r" . "ᚱ")
|
||||||
("l" . "ᛚ")))
|
("l" . "ᛚ")))
|
||||||
|
|
||||||
(defun conlanging//replace-string-by-char (t-string t-correspondance-table)
|
(defun conlanging//replace-string-by-char (t-string t-correspondance-table)
|
||||||
"Return a copy of t-string converted with the correspondance
|
"Return a copy of t-string converted with the correspondance
|
||||||
@ -159,30 +159,52 @@ with."
|
|||||||
; Mattér ;
|
; Mattér ;
|
||||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
(defun conlanging/matter-to-runes ()
|
(defun conlanging/matter-to-runes ()
|
||||||
"Replaces transliterated Mattér to its runic writing system"
|
"Replaces transliterated Mattér with its runic writing system"
|
||||||
(interactive)
|
(interactive)
|
||||||
(conlanging//replace-char-by-table conlanging//matter-latin-to-runes))
|
(conlanging//replace-char-by-table conlanging//matter-latin-to-runes))
|
||||||
|
|
||||||
(defun conlanging/matter-to-native-latin ()
|
(defun conlanging/matter-to-native-latin ()
|
||||||
"Replaces transliterated Mattér by its corresponding native
|
"Replaces transliterated Mattér with its corresponding native
|
||||||
latin writing system"
|
latin writing system"
|
||||||
(interactive)
|
(interactive)
|
||||||
(conlanging//replace-char-by-table conlanging//matter-latin-to-native))
|
(conlanging//replace-char-by-table conlanging//matter-latin-to-native))
|
||||||
|
|
||||||
(defun conlanging/matter-to-latex ()
|
(defun conlanging/matter-to-latex ()
|
||||||
"Replaces transliterated Mattér by its corresponding runes"
|
"Replaces transliterated Mattér with its corresponding runes"
|
||||||
(interactive)
|
(interactive)
|
||||||
(conlanging//replace-char-by-table conlanging//matter-latin-to-latex-runes))
|
(conlanging//replace-char-by-table conlanging//matter-latin-to-latex))
|
||||||
|
|
||||||
|
(defun conlanging/matter-org-export-runes (text)
|
||||||
|
"Replaces transliterated Mattér with its corresponding runes during org-mode
|
||||||
|
export"
|
||||||
|
(interactive)
|
||||||
|
(if (org-export-derived-backend-p org-export-current-backend
|
||||||
|
'latex)
|
||||||
|
(concat "\\textarm{"
|
||||||
|
(conlanging//replace-string-by-char text conlanging//matter-latin-to-latex)
|
||||||
|
"}")
|
||||||
|
(conlanging//replace-string-by-char text conlanging//matter-latin-to-runes)))
|
||||||
|
|
||||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
; Einnlanda ;
|
; Einnlanda ;
|
||||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
(defun conlanging/einnlanda-to-runes ()
|
(defun conlanging/einnlanda-to-runes ()
|
||||||
"Replaces transliterated Mattér to its runic writing system"
|
"Replaces transliterated Einnlandic with its runic writing system"
|
||||||
(interactive)
|
(interactive)
|
||||||
(conlanging//replace-char-by-table conlanging//einnlanda-latin-to-runes))
|
(conlanging//replace-char-by-table conlanging//einnlanda-latin-to-runes))
|
||||||
|
|
||||||
(defun conlanging/einnlanda-to-latex ()
|
(defun conlanging/einnlanda-to-latex ()
|
||||||
"Replaces transliterated Mattér by its corresponding runes"
|
"Replaces transliterated Einnlandic with its corresponding runes"
|
||||||
(interactive)
|
(interactive)
|
||||||
(conlanging//replace-char-by-table conlanging//einnlanda-latin-to-latex-runes))
|
(conlanging//replace-char-by-table conlanging//einnlanda-latin-to-latex))
|
||||||
|
|
||||||
|
(defun conlanging/einnlanda-org-export-runes (text)
|
||||||
|
"Replaces transliterated Einnlandic with its corresponding runes during
|
||||||
|
org-mode export"
|
||||||
|
(interactive)
|
||||||
|
(if (org-export-derived-backend-p org-export-current-backend
|
||||||
|
'latex)
|
||||||
|
(concat "\\textarm{"
|
||||||
|
(conlanging//replace-string-by-char text conlanging//einnlanda-latin-to-latex)
|
||||||
|
"}")
|
||||||
|
(conlanging//replace-string-by-char text conlanging//einnlanda-latin-to-runes)))
|
||||||
|
Reference in New Issue
Block a user