From mboxrd@z Thu Jan 1 00:00:00 1970 From: Emmanuel Charpentier Subject: Re: Possible bug in org-mode (MELPA version as of 1018-11-25) : #+language: is not (fully) honored. Date: Wed, 5 Dec 2018 17:37:21 +0100 Message-ID: References: <7ecc5c8e82316b99d6a55b77a29f1a8d1e77ca5b.camel@gmail.com> <87sgzmk3fn.fsf@gmail.com> <87pnuqtggf.fsf@nicolasgoaziou.fr> <070afa36c50daaec4016356bbb36d2167f358616.camel@gmail.com> <87pnuqrsw4.fsf@nicolasgoaziou.fr> <875zwhs3dr.fsf@nicolasgoaziou.fr> <87tvk0q8op.fsf@nicolasgoaziou.fr> <87h8fzr93h.fsf@nicolasgoaziou.fr> <0b203d5f5c53407d7d19dbb4a1351fd22909615b.camel@gmail.com> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000aa02e2057c48ffd1" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:55290) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gUaBB-0005va-OA for emacs-orgmode@gnu.org; Wed, 05 Dec 2018 11:37:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gUaB9-0007Ht-Qt for emacs-orgmode@gnu.org; Wed, 05 Dec 2018 11:37:41 -0500 Received: from mail-ot1-x330.google.com ([2607:f8b0:4864:20::330]:42262) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gUaB5-00071D-Sr for emacs-orgmode@gnu.org; Wed, 05 Dec 2018 11:37:37 -0500 Received: by mail-ot1-x330.google.com with SMTP id v23so19174306otk.9 for ; Wed, 05 Dec 2018 08:37:33 -0800 (PST) In-Reply-To: <0b203d5f5c53407d7d19dbb4a1351fd22909615b.camel@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Nicolas Goaziou Cc: emacs-orgmode@gnu.org --000000000000aa02e2057c48ffd1 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Rights transferred to FSF (scanned signed copy of the form set to assign@fsf.org). HTH, -- Emmanuel Charpentier Le dim. 2 d=C3=A9c. 2018 =C3=A0 21:26, a = =C3=A9crit : > Dear all, > > Please find enclosed a proposed patch (against master) to document the > need for babel/polyglossia in order to honor #+language in LaTeX > export. > > This is purely a documentation patch. A better solution would be to > detect the use of a non-default #+language: and act accordingly. > Nicolas notes (rightly) that babel (and polyglossia, BTW) are too > "invasive" to be default, and is shy of auto-loading the necessary > package(s) "automagically. > > I do not (yet) know how ti reconcile these imperative, hence the > present interim atch (which should disappear if/when a better solution > is created). > > HTH, > > -- > Emmanuel Charpentier > > > Le jeudi 29 novembre 2018 =C3=A0 20:12 +0100, Nicolas Goaziou a =C3=A9cri= t : > > Emmanuel Charpentier writes: > > > > > This is *not* *documented* (not even in the `org-latex-packages- > > > alist''s > > > docstring). > > > > I know. I fixed `org-latex-packages-alist''s docstring two days ago. > > > > > Also agreed, with the reservation that "invasive" didn't mean the > > > same > > > thing in the 1980s (when the core size of computers was measured in > > > kilobytes) and in the 2010s (the current core measurement unit is > > > the > > > /giga/byte...). > > > > Not invasive by its sheer size, but by the number of alterations it > > generates in the LaTeX default behaviour, and the incompatibilities > > it > > may introduce. For example there used to be issues between frenchb > > and > > KOMA-Script. > > > > > Again, I think that the end user should *not* have to worry with > > > this only > > > when exporting to LaTeX (or beamer or PDF). > > > > Ideally, that would be nice. > > > > > If this can be handled silently when exporting to ODT, HTML or > > > plain > > > text, it should be handled silently when exporting to LaTeX. > > > > I disagree. Packages should not be loaded /silently/. > > > > > I do not know how to handle this. My *hunch* is that the Latex > > > Export > > > function generating the preamble should check for language > > > > It does already, in `org-latex-guess-babel-language'. > > > > > and if not default, add the relevant package(s) to the preamble. > > > > Don't. Anything that is in the header should be declared. > > > > We could try and see if Babel causes trouble by adding it to default > > packages in "next" branch. I'd rather do that than inserting it > > magically. > --000000000000aa02e2057c48ffd1 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Rights transferred to FSF (scanned signed copy of the form= set to assign@fsf.org).

HTH,

--
Emmanuel Charpentier

Le=C2=A0dim. 2 d=C3= =A9c. 2018 =C3=A0=C2=A021:26, <emanuel.charpentier@gmail.com> a =C3=A9crit=C2=A0:
=
Dear all,

Please find enclosed a proposed patch (against master) to document the
need for babel/polyglossia in order to honor #+language in LaTeX
export.

This is purely a documentation patch. A better solution would be to
detect the use of a non-default #+language: and act accordingly.
Nicolas notes (rightly) that babel (and polyglossia, BTW) are too
"invasive" to be default, and is shy of auto-loading the necessar= y
package(s) "automagically.

I do not (yet) know how ti reconcile these imperative, hence the
present interim atch (which should disappear if/when a better solution
is created).

HTH,

--
Emmanuel Charpentier


Le jeudi 29 novembre 2018 =C3=A0 20:12 +0100, Nicolas Goaziou a =C3=A9crit = :
> Emmanuel Charpentier <emanuel.charpentier@gmail.com> writes:
>
> > This is *not* *documented* (not even in the `org-latex-packages-<= br> > > alist''s
> > docstring).
>
> I know. I fixed `org-latex-packages-alist''s docstring two day= s ago.
>
> > Also agreed, with the reservation that "invasive" didn&= #39;t mean the
> > same
> > thing in the 1980s (when the core size of computers was measured = in
> > kilobytes) and in the 2010s (the current core measurement unit is=
> > the
> > /giga/byte...).
>
> Not invasive by its sheer size, but by the number of alterations it > generates in the LaTeX default behaviour, and the incompatibilities > it
> may introduce. For example there used to be issues between frenchb
> and
> KOMA-Script.
>
> > Again, I think that the end user should *not* have to worry with<= br> > > this only
> > when exporting to LaTeX (or beamer or PDF).
>
> Ideally, that would be nice.
>
> > If this can be handled silently when exporting to ODT, HTML or > > plain
> > text, it should be handled silently when exporting to LaTeX.
>
> I disagree. Packages should not be loaded /silently/.
>
> > I do not know how to handle this. My *hunch* is that the Latex > > Export
> > function generating the preamble should check for language
>
> It does already, in `org-latex-guess-babel-language'.
>
> > and if not default, add the relevant package(s) to the preamble.<= br> >
> Don't. Anything that is in the header should be declared.
>
> We could try and see if Babel causes trouble by adding it to default > packages in "next" branch. I'd rather do that than inser= ting it
> magically.
--000000000000aa02e2057c48ffd1--