-
-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support user-defined pretty entities #84
Comments
No, there is currently no way to influence the available entities. |
I hope this feature can be included in a near future. Nice app in any case. |
Can you give an example entry or your |
Sure. The Emacs variable description of
At the moment, mine has the following value. (setq org-entities-user '(
("primes" "\\mathbb{P}" t "ℙ" "P" "P" "ℙ")
("naturals" "\\mathbb{N}" t "ℕ" "N" "P" "ℕ")
("integers" "\\mathbb{Z}" t "ℤ" "Z" "Z" "ℤ")
("rationals" "\\mathbb{Q}" t "ℚ" "Q" "Q" "ℚ")
("irrationals" "\\mathbb{I}" t "𝕀" "I" "I" "𝕀")
("reals" "\\mathbb{R}" t "ℝ" "R" "R" "ℝ")
("complexes" "\\mathbb{C}" t "ℂ" "C" "C" "ℂ")
("quaternions" "\\mathbb{H}" t "ℍ" "H" "H" "ℍ")
("scalars" "\\mathbb{K}" t "𝕂" "K" "K" "𝕂")
("coloneq" "\\coloneqq" t "≔" ":=" ":=" "≔")
("eqcolon" "\\eqqcolon" t "≕" "=:" "=:" "≕")
("then" "\\Rightarrow" t "⇒" "=>" "=>" "⇒")
("iff" "\\Leftrightarrow" t "⇔" "<=>" "<=>" "⇔")
("from" "\\leftarrow" t "←" "<-" "<-" "←")
("mapsto" "\\mapsto" t "&x21A6;" "->" "->" "↦")
("leadsto" "\\leadsto" t "&x21DD;" "->" "->" "⇝")
("pm" "\\mp" nil "±" "+-" "±" "±")
("mp" "\\pm" nil "∓" "-+" "-±" "∓")
("sqrt" "\\sqrt" t "√" "sqrt" "sqrt" "√")
("cbrt" "\\sqrt[3]" t "∛" "cbrt" "cbrt" "∛")
("frrt" "\\sqrt[4]" t "∜" "frrt" "frrt" "∜")
)) I believe only the first and last "columns" are of interest to Orgro. I hope it is of help. |
I've strenuously avoided adding settings to Orgro itself, and I'd prefer to keep it that way for this as well. What I'm thinking now is to support parsing and interpreting You could hide such a section from export via the Your setting would look like this at the bottom of your file:
(The single-line form I got from doing Line-by-line version
|
I understand. Your solution overwrites # Local Variables:
# eval: (dolist (org-entity-local '(
# ("cont" "\\mathcal{C}" t "𝒞" "C" "C" "𝒞")
# ("neigh" "\\mathcal{E}" t "ℰ" "E" "E" "ℰ")
# )) (add-to-list 'org-entities-user org-entity-local t))
# End: Thank you for pointing me to the solution. Cheerios. |
Ah yes, that would be a problem if you don't want to include your entire value in every document.
Now Orgro can't just parse the value; it needs to be able to run arbitrary Elisp. This is a much bigger task, and may not even be allowed on the App Store. |
Does Orgro get updates from Emacs? I could contact upstream to see if it is feasible to add a new variable, |
Orgro doesn't use any Emacs or org-mode code; I've reimplemented the relevant bits in Dart. So in principle I can just decide to support In general I would prefer to not invent new things here; in other words ideally org-mode would add |
You should definitely give support to either Just to know, what is the set of entities Orgro supports? The one from |
Yes, I generate the default list from |
v1.34.2 is out on the App Store and Google Play; it supports local var list definitions for |
Nice! I'm gonna give it a try. |
v1.34.2 is now available on F-Droid as well. |
I've just tried it and it seems to work correctly. Thanks for the implementation! |
Incidentally the "safe" predicate for I submitted a fix that should be in the next release. |
Orgro supports pretty entities. Does it allow to set new
org-entities
throughorg-entities-user
?The text was updated successfully, but these errors were encountered: