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 KLSEIdPmM2Mz3gAAbAwnHQ (envelope-from ) for ; Wed, 28 Sep 2022 08:16:51 +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 ELeZIdPmM2MCBQAA9RJhRA (envelope-from ) for ; Wed, 28 Sep 2022 08:16:51 +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 C5E3C3DBF7 for ; Wed, 28 Sep 2022 08:16:50 +0200 (CEST) Received: from localhost ([::1]:38858 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1odQNF-0002Ac-KA for larch@yhetil.org; Wed, 28 Sep 2022 02:16:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47582) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1odQL1-00029u-FD for emacs-orgmode@gnu.org; Wed, 28 Sep 2022 02:14:31 -0400 Received: from mout01.posteo.de ([185.67.36.65]:37271) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1odQKy-00076Y-85 for emacs-orgmode@gnu.org; Wed, 28 Sep 2022 02:14:30 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 83CC0240026 for ; Wed, 28 Sep 2022 08:14:24 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1664345664; bh=bLADSJe8j2v7f2H3lcQBgueT2xNhyNYLTT6zI4bN3MM=; h=From:To:Cc:Subject:Date:From; b=U5qzr61ErhdUDozD42+kYUBp9suQGdvArmT6qxfkKagARcgUSGzinNdAjR8MsoGnV XmQIXSuSHbjC3CKARt504JnqxMC3sXJsvoBSvRLqv369yesPzC32d4O2P95rhsazNI kUdaZiqa/WI7bMxqLCy81k4qDalCgqDuYYNlSeoXK/Rd2OPdtik69+xx80SdDeOyuX Jdcb5fUAv5gaLqCosOQ8BiUNlGq75WKTtAPNyBA8NZ8iC0dumXxMINAlqLIxnjVawt 3z38R1XvlAC+bGodZktzv0D7cZWed7NUA7syp40NOnn5qswDwt4dMgzH/N8bHQjykv yBR/qBoIeXAjA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4McmRM5G31z6tmF; Wed, 28 Sep 2022 08:14:23 +0200 (CEST) From: =?utf-8?Q?Juan_Manuel_Mac=C3=ADas?= To: Hendursaga Cc: orgmode Subject: Re: Create in Org a bilingual book with facing pages References: <87h70tyyiz.fsf@posteo.net> <87zgeku66t.fsf@aol.com> Date: Wed, 28 Sep 2022 06:14:21 +0000 In-Reply-To: <87zgeku66t.fsf@aol.com> (hendursaga@aol.com's message of "Tue, 27 Sep 2022 12:34:50 -0400") Message-ID: <874jwsauv6.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=185.67.36.65; envelope-from=maciaschain@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham 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-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1664345811; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc: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:dkim-signature; bh=bLADSJe8j2v7f2H3lcQBgueT2xNhyNYLTT6zI4bN3MM=; b=X0cetuTuDKJUvKkpScm3jxEtb6mJkrcL59+hxdqx05+BP3hrIy1iXFZose+nddDUSGHh2g 75sUxnPCzqNhyYN4FgWLQFS69hnFjcHSazViPoBbxWmydueChrbVbCp7wsHAGqitOBqTi2 kydCYSw5Kar5Jy1LTuvqfWE3313KJ8s2Xfzv3diE6hp7ATdysVygdE1PxaqHhPBYguzuxr 7WlPqPaAxb56FTiyHdhLpkw3+wWelyntCLy20ddQ2FC97gqKqhcgDB5Sw5viuQTQlEb0Xh pS+M+amAcUiXmigSwHNlOMbCRrO2oXpPN8k8jzulQYZUw42xHG1KXZ1jDpDS+Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1664345811; a=rsa-sha256; cv=none; b=VxOeOCctYSPVJhJx8ZNshtPpDXvBW8HoZzLPCo0Alyj3s6J4BYXjd6YZsM3NwpBGIDsr40 pSdHiF1FNDrdzZJawBJqQu80ODx1llZgodpYvwdWIu+6P0Z2WfBDG8O8hDXh2I2gmHYX08 6JBGb+qFtMzDy0fU/hIHQ5V4S79Idi++aY849OtkQU8N6JMme8RmwN9QGYVL4PJv9xmZ3s l1c8JebchmQmxUBGyzOK9ZftjhDnOoMORw3eqPw4soxo9rx8XdhpIWbKA3GKLVCmBkI5jS +vOYbFWYkF6+qF5ov9eKj2yZNA6LMB86uFMXhPLri6U2hIBDAT6Z1de3lMAe4Q== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=U5qzr61E; dmarc=pass (policy=none) header.from=posteo.net; 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: -9.65 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=U5qzr61E; dmarc=pass (policy=none) header.from=posteo.net; 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: C5E3C3DBF7 X-Spam-Score: -9.65 X-Migadu-Scanner: scn0.migadu.com X-TUID: 3lqN9M3GyUZL Hi, thank you for your comments. Hendursaga writes: >> The bilingual critical edition (ancient Greek/Spanish) of the >> letters of Demosthenes and Aeschines has recently been published in >> Spain, a book whose production and typesetting I have taken charge >> of, using Org and Org-publish. > What is the name of this book / the publisher's page? I don't really > know Spanish, and only a little Greek, but I'm fascinated by bilingual > editions, especially with critical apparati. I've been looking for a > workflow for creating my own (possibly critical) bilingual works, but > so far, months later, I haven't really found anything satisfactory. Dem=C3=B3stenes y Esquines, Cartas atribuidas. Publisher: Dykinson. Perhaps it is not yet in the catalog, because the book is very recent. On this page you can see other critical editions (among other books) that I have produced: https://maciaschain.gitlab.io/lunotipia/muestra_trabajos.html. Certainly critical editions are some of the most fascinating kinds of books out there. My favorites are the Oxford Classical Texts, the Bud=C3=A9 Collectio= n, and Teubner. In bilingual format the Loeb Classical Texts are also excellent. All these have marked a canon. >> First of all, for this kind of work you have to take into account an >> inherent limitation of TeX: the compilation process in TeX is a >> single-threaded process. That is, in TeX you cannot compile >> different parts of a document, with different configurations (=3D >> different preambles), at the same time. > > To clarify: you mean that you would have to have two distinct > documents so that, say, the page titles, fonts, indices, etc can be > specific to that "language half" of a work? I would've thought you > could just have everything in one document. That's how I've been > (trying to) do it so far, using the reledpar package, an extension of > reledmac. Did you / have you tried using that? I've also tried various > other packages, like the parallel package. I think that the automatic synchronization of the facing pages of a bilingual editions, either in TeX or in any other software, is a utopia. Or, to be less radical and pessimistic, that is something possible in very few scenarios. The ideal scenario would be for text A and text B to have *exactly* the same number of lines and the same content per page. This rarely happens. When it comes to poetry in verse it is more common to happen. But factors such as the corpus of footnotes or the critical apparatus, which are parts of the page with a variable height, also have an influence. In the case of this book there was a significant gap between the two texts. That is to say, that in the end a manual intervention is necessary to balance the pages according to the content. In the case of TeX/LaTeX, the single-thread TeX limitation is also added. Packages like parallel (or paracol, which is newer) work fine when dealing with simple text. At more complexity they are unusable. And furthermore, in this case text A is a critical edition that needs its own configuration. Parallel or paracol simply don't work here. The case of reledpar could be the solution (since it is a version of reledmac for parallel texts), but, unfortunately, it almost never is. Reledpar works fine (more or less) when the scenario I mentioned at the beginning occurs: if text A and text B are almost identical in length page to page and paragraph to paragraph. Otherwise, manual synchronization becomes very difficult and reledpar has a very erratic behavior. Reledmac is wonderful, but I think reledpar is not a good package and my recommendation is to avoid using it if possible. As I said at the beginning, the ideal in TeX/LaTeX would be to be able to compile with true parallel threads of text with a different configuration, which is impossible. So my strategy is to create two separate documents and load them with pdfpages. The good thing is that Org helps a lot in this process, giving the feeling that I am working with true parallel threads, since all the processes involved are asynchronous. >> On the other hand, since in this book the content of the odd and >> even pages is variable, the synchronization has been done per page, >> so that the reader always obtains the same content on the odd and >> even page when facing the open book. For the Greek document I used >> the reledmac LaTeX package[...] > > I've looked at reledmac, and I agree, it is pretty sophisticated. Can > you clarify which synchronization method(s) you use? If you do use > reledpar, in section 6.2.2, it lists the different ways you can > synchronize. Otherwise, could you try to explain in terms it uses? You might also want to take a look at ekdosis, a new package for critical editions. It is not as complete as reledmac (for now), but it has some interesting features, such as the possibility of exporting to TEI. As for what you ask me about the synchronization, this one is visual. It is inevitable, from what I said before. And I think it is also necessary. No matter how sophisticated typographic software is, in the end human intervention is always necessary for things like this, which depend on content and not on form. And for things like correcting typographic rivers and such. Maybe in the not too distant future we can train an IA to do it, but at the moment TeX doesn't understand content :-). Of course, this synchronization must be done when both texts are already hypercorrected. It is enough to add some marks to the text, indicating where to generate a cut. Reledmac has the \ledpb command for it, which I have redefined like this: \makeatletter \renewcommand{\led@check@pb}{\xifinlist{\the\absline@num}{\l@prev@pb}{\clea= rpage}{}} \makeatother >> Once both PDFs are obtained and synchronized, they are loaded into >> the master Org document using the pdfpages LaTeX package. Since it >> was necessary to introduce in certain pages some commands specific >> to each page, such as page styles, index entries or labels for >> references, and to avoid having to load the pages one by one with >> pdfpages commands, I wrote a function that obtains the number of >> pages of the synchronized PDF (via mutool) and it does all that >> work. [...] > > To clarify once more: when you introduce page-specific commands, is > this in the original PDF documents that you generate, or are those, > like, trimmed and then you add on the headers etc later, or what? Page-specific commands (such as page styles, reference labels, and so on) are not in the original PDFs but are passed through the pdfpages package, using the 'pagecommand' key. For example, with PDF pages you can put something like (for page 1): \includepdf[pages=3D{1},noautoscale=3Dtrue,pagecommand=3D{\thispagestyle{em= pty}\label{foo}]{file.pdf} What my function does is get the number of pages in the PDF and do all that work, adding the commands I want on the needed page. >> And that=E2=80=99s it. The next challenge for this fall is going to be a >> trilingual edition of the New Testament (Greek, Latin, Spanish). >> [...] > > Are you aware of Kevin Klement's trilingual edition[1] of > Wittgenstein's Tractatus Logico-Philosophicus? (OK, it's technically > bilingual, but with two separate English translations along with the > original German!) He uses PHP (gross, I know!) to collate everything > into a LaTeX document to then generate the various final versions. > Besides the PHP, you might pick up a technique or two! (Or three!) Interesting. For critical editions (among other text types for Humanities), the standard for storing textual data is TEI (https://en.wikipedia.org/wiki/Text_Encoding_Initiative). The problem with TEI (at least for me) is that it consists of XML, and I hate XML :-). In this regard, I think that a lightweight markup language as powerful as Org could be a good alternative to TEI. And Org is indeed human-readable. One could even think of a possible Org backend for TEI... Best regards, Juan Manuel=20