From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id MOvsBoBb0WI7IAEAbAwnHQ (envelope-from ) for ; Fri, 15 Jul 2022 14:20:16 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id uHoCB4Bb0WJQ0AAA9RJhRA (envelope-from ) for ; Fri, 15 Jul 2022 14:20:16 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id C9BBEC3DD for ; Fri, 15 Jul 2022 14:20:15 +0200 (CEST) Received: from localhost ([::1]:38366 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oCKIo-00074x-VT for larch@yhetil.org; Fri, 15 Jul 2022 08:20:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:57334) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oCKGs-00073d-2p for emacs-orgmode@gnu.org; Fri, 15 Jul 2022 08:18:14 -0400 Received: from ciao.gmane.io ([116.202.254.214]:41180) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oCKGq-0000zd-GD for emacs-orgmode@gnu.org; Fri, 15 Jul 2022 08:18:13 -0400 Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1oCKGl-0006zH-7H for emacs-orgmode@gnu.org; Fri, 15 Jul 2022 14:18:07 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: emacs-orgmode@gnu.org From: Max Nikulin Subject: Re: [PATCH] ox-latex.el: Unify in one single list Babel and Polyglossia languages alists Date: Fri, 15 Jul 2022 19:18:00 +0700 Message-ID: References: <87sfxiw2jp.fsf@posteo.net> <87czeduxnz.fsf@localhost> <87lesvlvos.fsf@posteo.net> <87h73jlmh6.fsf@posteo.net> <871qunv9s8.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Content-Language: en-US In-Reply-To: <871qunv9s8.fsf@posteo.net> Received-SPF: pass client-ip=116.202.254.214; envelope-from=geo-emacs-orgmode@m.gmane-mx.org; helo=ciao.gmane.io X-Spam_score_int: 28 X-Spam_score: 2.8 X-Spam_bar: ++ X-Spam_report: (2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_ADSP_CUSTOM_MED=0.001, FORGED_GMAIL_RCVD=1, FORGED_MUA_MOZILLA=2.309, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249, NICE_REPLY_A=-0.001, NML_ADSP_CUSTOM_MED=0.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1657887615; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=3aBTblSGendstC7Nkbb6dAt39uFDr9dY5MUYR+UrDeY=; b=Ml1kig8f+JrLwNIy5+TuEIeH3upo2FVbS1yPHB8O49R3b9jp8g9LclOIgWkEgCylYOCgy9 OxC1EuiBarAZszHibiCOGP+81L2t3X7P0frWGHvEg6zmbEHnL9j3xcKZc2i1cO3k1QrytI 802cXZerIsIwgOFjRHhyVwaU+bLz0MAEurdpVkO2MiqTHzNN1evomAnlHtzV+VsExbhamm 3Wz45v0Z48TKWPJMr5iov8AR0CTTQvJ/WH1+GQAY8OqN5cfOmx81hRwmAGbN00s9AWwL6n GGhwTHdRwI4vv0Smku1t5f08dHPjHe3sss6xKIBViL3WpvXy8x2VCVX5HG/rVQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1657887615; a=rsa-sha256; cv=none; b=ZlSUDZJTz3mOjk9129NMSLbPY5eHHQaokXcZwnNGouURwDwseCl09/YxmoSmy2UEs0InPu MpdXbvBC/2Hz+VL1oZ36eNLaGNTodqHMAK7cbZMEAJDqmL1Yqi5sixe2yGFt9Y7enkY71i FaH9avBhsEJ7a0Bc9LxF+1lpwd29Vwq1ot7OardNnMLuUBb+1J9wNPg4yzE/7dggXe9r51 PSQV1w5O1/KenD+q9SyUvSoFK1U1HgBNDXsxMdiWXYxc21l/QEBJR5HBJ4eBLz/gF8vR5e TegwE84aIdDVrwzKthKfUFOOwqF4KrfNHWJH4CEceYAQyfOk+4pW0UCH22v5zw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: 2.75 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: C9BBEC3DD X-Spam-Score: 2.75 X-Migadu-Scanner: scn1.migadu.com X-TUID: HgpJTp+tN5qs On 15/07/2022 01:17, Juan Manuel Macías wrote: > Juan Manuel Macías writes: > >> In any case, I personally think that org-latex-language-alist, as it is >> now in this patch, is sufficient. I agree that the lists should be merged. My point is that with unnamed fields and variable number of them it would not be possible to extend this list with additional fields. So additional step with `make-obsolete-variable' would be required. > By the way, Maxim. I have been doing some tests with pdfLaTeX. I've > known for a while now that it's no longer necessary to load the inputenc > package. But it seems that it is not even necessary to load fontenc with > the encoding of each language. It looks like a promising feature. > In TeX live 2022 the compilation is correct (I think). It seems that > Babel (or russian/greek.ldf) loads the font encodings according to the > declared languages. From the log: > > (/usr/share/texmf-dist/tex/generic/babel/locale/es/babel-spanish.tex) Interesting, Spanish is not mentioned in your document. > Is this normal or is it a new Babel feature? If it is a new feature, I > can't find it anywhere in the documentation. I have tried on Ubuntu-20.04 LTS focal (Latest LTS is 22.04 jammy). Without explicit fontenc it may work, but emits a warning Package babel Warning: No Cyrillic font encoding has been loaded so far. (babel) A font encoding should be declared before babel. (babel) Default `T2A' encoding will be loaded on input line 74. Unfortunately in the case of \usepackage[russian,english]{babel} \selectlanguage{russian} is required, without it compilation fails with ! LaTeX Error: Command \cyrn unavailable in encoding OT1. With \usepackage[T2A]{fontenc} it behaves accordingly to acceptable for non-important documents graceful degradation. Text is readable, but no hyphenation applied. So I consider explicit loading of fontenc as more reliable. > If I'm not mistaken, there is now nothing like > an hypothetical 'org-latex-guess-fontenc', and org defaults to the T1 > option. If I remember correctly (because I haven't used pdfLaTeX in > ages), the fontenc option for Greek is LGR. And I imagine there will be > many more cases. That is why I am suggesting a mapping from language to font encoding. > If you or anyone wants to implement that on top of my > patch, that's fine with me. I do not see a solution "on the top of your patch". Either an additional mapping should be added or your changes should be overwritten by some extensible structure. The former is a step backward in respect to the idea of merging alists, the latter might make unhappy developers of third party packages.