From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id MDI2Jm2xqmXqOAAA62LTzQ:P1 (envelope-from ) for ; Fri, 19 Jan 2024 18:29:17 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id MDI2Jm2xqmXqOAAA62LTzQ (envelope-from ) for ; Fri, 19 Jan 2024 18:29:17 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="Eg/5DPk+"; 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"; dmarc=pass (policy=none) header.from=posteo.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1705685357; 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:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=MauInLipbbwqKKNVdSdVzm8raYc0pDI9fy6Qsvm4SB0=; b=KR2f4fvyNYDdsOvm/UyYIkSoCXTKnEsiCcfQJy46GkTqOgIkb+GQn1u5h8xUn+ZeCDC4xO 6Msmrhky9ee8enSsXc66uuBKiTYGgnm4n6QYnQ8Q4d17Gm4BO+LwUq4z5Tip/KYpehyERH CdfiG2lhsy00N2QHEuXaZClfBX/r1pYziXPGI4/61kRCC7Tu1/BMn5szgf4Bb6WWEP0kdk ACFMl8eJr7qqtGYPGhZ8w+80GTcCDw0B2jCkXcrrldynG8JW0uvzNY91JVg9VSfcoY1XPh T2tqbTivcjEQ5LxgqIkuvkA3/FdS9qKw3bFm6HRwvFmzTYOIEnInbOI/st2q2w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="Eg/5DPk+"; 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"; dmarc=pass (policy=none) header.from=posteo.net ARC-Seal: i=1; s=key1; d=yhetil.org; t=1705685357; a=rsa-sha256; cv=none; b=P6qCmyh6YbwQOAEKE9Smauw5Z+yZfyr1Pu6TpX+wCLc8TwqcGnIbstef97pqQvL0tAB3UW mEsqY8h4paFnK+qJY5dlqKIY+DpudTkeO9vtc1PsOdXTGi42PM7HriRMUl7d3K9O7lYkBx 8PrNZOsClZPQvWInfK6DWK3UHoDti8m176QoPr3dDJDTG6OeUE96mnuAs6drOOyiuaCbpk /YxReRzKBnfO+LUlbKtFe//yzpFXVA4XT/qyBoR5/ckmDQvIFzge8VGYuN/LwR1f9uNb4z 0B2JHDNxukRnjaMYwOkFBxK88e/lg9c44+N0wEyLrIKMnR20G0aCl8AWQfFZag== 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 870A145D7D for ; Fri, 19 Jan 2024 18:29:17 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rQsfJ-0002Lm-SB; Fri, 19 Jan 2024 12:28:25 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rQsfH-0002Kh-UX for emacs-orgmode@gnu.org; Fri, 19 Jan 2024 12:28:23 -0500 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rQsfF-0003SE-H5 for emacs-orgmode@gnu.org; Fri, 19 Jan 2024 12:28:23 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id E753E240103 for ; Fri, 19 Jan 2024 18:28:17 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1705685297; bh=oPZIl+wTVDPzrTPY/wG83lBWPBL2YDL6eqlx7Nyln/k=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=Eg/5DPk++blUl6FOxiWcCBURyxb7liCoxz8p6Bfj9uVttAZXxmFj+J6YucUzpgYLp KEHGPE5j11USmZt/Tx4GvfZGrQl86VEXuUzSYrwVIDA28lcFqFAa3O1QC/UMmvfup0 X+x2qiAe3pHS9Nlt9eqgF4dyf0XoyZih1ZuGn60GKxNed4SIk6oSrNPSrW+6387GKi utoAehMvi+2/by+qaIypCsib+Ew16J026f9FgDm2k/gYjRQywqxQoDGbVLLAmucji+ rprVZTFQxDVdgrC0G/GrJgEYg84Y4XVxYHGWe/Y0RtN+qgFvZtjFjH9dp8hUP5cATZ dhhmHGncT7fEg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4TGmmJ6ZGXz6twj; Fri, 19 Jan 2024 18:28:16 +0100 (CET) From: =?utf-8?Q?Juan_Manuel_Mac=C3=ADas?= To: Ihor Radchenko Cc: orgmode , Max Nikulin Subject: Re: [possible patch] Remove the '\\[0pt]' string from the last line of a verse block in LaTeX export In-Reply-To: <8734uuaj11.fsf@localhost> (Ihor Radchenko's message of "Thu, 18 Jan 2024 13:05:46 +0000") References: <874jfvjo2k.fsf@posteo.net> <87cyu5uv7c.fsf@localhost> <878r4tfccn.fsf@posteo.net> <87zfx9t7di.fsf@localhost> <87wmsddlw5.fsf@posteo.net> <87r0ikrt5h.fsf@localhost> <87o7dnefwo.fsf@posteo.net> <87cyu1l69f.fsf@localhost> <87il3tax9a.fsf@posteo.net> <8734uwjerg.fsf@localhost> <87o7dju9vn.fsf@posteo.net> <8734uuaj11.fsf@localhost> Date: Fri, 19 Jan 2024 17:28:14 +0000 Message-ID: <87h6j96xn5.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=maciaschain@posteo.net; helo=mout02.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, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -7.40 X-Migadu-Queue-Id: 870A145D7D X-Spam-Score: -7.40 X-Migadu-Scanner: mx11.migadu.com X-TUID: rLRTtC0gxyQu Ihor Radchenko writes: > This turned out to be a lot easier than I thought. > See the attached patch. > >>> \command >>> [unrelated text] >>> >>> If there are, we may actually want to consider pandoc's approach >>> seriously. >> >> In principle, any environment that takes an optional argument in a >> "dangerous" position. Just do a simple test. Something like this: >> >> #+begin_figure >> [lorem] ipsum >> #+end_figure >> >> will throw an error like ''LaTeX Error: Unknown float option...'' >> >> Of course, putting an empty line after #+begin... usually solves it. But >> the user may not know it. >> >> There are also a number of commands with an optional argument. For >> example \pagebreak. Something like this will give an error: >> >> lorem @@latex:\pagebreak@@ [ipsum] >> >> \item is another typical example, but in this case org adds \relax. > > With the patch, I am getting the following: > > * This is test > lorem @@latex:\pagebreak@@ [ipsum] > > #+begin_figure > [lorem] figure > #+end_figure > > | [foo] | 2 | > | [bar] | 3 | > > - [bax] > - [aur] > > exports to > > lorem \pagebreak {[}ipsum] > > \begin{figure} > {[}lorem] figure > \end{figure} > > \begin{center} > \begin{tabular}{lr} > {[}foo] & 2\\[0pt] > {[}bar] & 3\\[0pt] > \end{tabular} > \end{center} > > \begin{itemize} > \item {[}bax] > \item {[}aur] > \end{itemize} Great! Simple and effective. And more surgical than pandoc's global solution. But now a question arises... Your code clearly solves the problem that led to the declaration of org-latex-line-break-safe, without foreseeing any unwanted effects, since it is the solution that is usually recommended from LaTeX. So, if this code is included in Org, what is the future of org-latex-line-break-safe? Best regards, Juan Manuel