Hi On Sun, 30 Nov 2025 at 11:57, Ihor Radchenko <[email protected]> wrote:
> Pedro Andres Aranda Gutierrez <[email protected]> writes: > > > . (("el" > > :fonts (("rm" :font "Noto Serif" > > :props "Scale=MatchLowercase")) > > :provide "onchar=ids fonts") > > ... > > \babelprovide[onchar=ids fonts]{greek} > > > > As you see, each language has a part linked to the language that is > passed > > to \babelprovide (which is optional, but crucial), while the other part > is > > passed to \babelfont (and this part is not). > > I've read a section of the babel manual of the \babelprovide command, and > it looks to me that it is not really related to fonts. It is rather > fine-tuning language punctuation and detection. E.g. one can do > alternative hyphenation rules and so on. > You are right in that it controls language detection, punctuation, etc. So we have two 'groups of settings' for babel that you map to a language (from #+LANGUAGES). I find it more convincing to go this way, because it is more 'grow as you go'. To tell you the truth, I will never use this myself, because I have more than enough with fontspec and \usepackge[language]babel (or polyglossia). So, you want it the other way round, it's back to the drawing board, rewrite the babel support code and the parts relating to this in org-manual.org > > If we went for a flat config, we would need another variable for the > > provides and that would make housekeeping more difficult. > > Touching one variable is less prone to forgetting details than having to > > touch two (IMvHO). > > IMHO, it is worth it in this case. Simply because babelprovide is not > really about fonts, maybe except onchar in particular, but that's rather > an exception. What about adding org-latex-babel-language-config variable > for babelprovide and potentially other options? > What other options do you see? If I read you correctly, this variable would be a list of plists, linking (<lang from #+LANGUAGES> :provide <string or list of strings>) > If it weren't for that, I could live with a flatter version à la > > > > #+begin_src emacs-lisp > > ((org-mode > > . ((org-latex-compiler . "lualatex") > > (org-latex-multi-lang . "babel") > > (org-latex-babel-font-config > > . (("el" :variant "rm" :font "Noto Serif" :props > > "Scale=MatchLowercase") > > (nil :variant "rm" :font "CMU Serif") > > (nil :variant "tt" :font "Noto Sans Mono" :props > > "Scale=MatchLowercase")))))) > > #+end_src > > > > which might be more appealing to you, if I understand you correctly... > > Yup, it is more appealing to me. Moreover, it has a potential to merge > all font-related settings into a single customization. After all, what > are chances that you would need different fonts for the same language > for babel vs. polyglossia? Contributions to conferences vs. book chapters, for example. Has happened to me. > And even if you do have to do such thing, we > can always have an extra property as in `org-latex-packages-alist' to > limit which compilers a given font should apply to. > I can't follow you here... And that should be easier to configure/customise for the end user? This idea (in by mind) seems increasingly attractive as it has a > potential to simplify the configuration. -- > Ihor Radchenko // yantar92, > Org mode maintainer, > Learn more about Org mode at <https://orgmode.org/>. > Support Org development at <https://liberapay.com/org-mode>, > or support my work at <https://liberapay.com/yantar92> > Best, /PA -- Fragen sind nicht da, um beantwortet zu werden, Fragen sind da um gestellt zu werden Georg Kreisler "Sagen's Paradeiser" (ORF: Als Radiohören gefährlich war) => write BE! Year 1 of the New Koprocracy
