From: Max Nikulin <manikulin@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX
Date: Sun, 16 Oct 2022 22:04:48 +0700 [thread overview]
Message-ID: <tih6ii$lvr$1@ciao.gmane.io> (raw)
In-Reply-To: <875ygk6a8z.fsf@posteo.net>
On 16/10/2022 04:35, Juan Manuel Macías wrote:
>
> To begin with, it is a particular solution
> applied in a general way. This can have unexpected consequences, as has
> happened in verse blocks.
In my opinion Org has to apply a general solution merely because a table
may be result of evaluation of an org-babel code block. I may be wrong,
but I suspect that some users do not care what is the intermediate
format when they need a PDF file.
> And finally, I think that applying a general solution to this problem is
> something that should be done(IMHO) in LaTeX and not in Org,
Org has a bit more information concerning context of square brackets.
They may be just text of a table cell or contents of an export snippet.
In a LaTeX file they are just square brackets and there is no way to
distinguish them.
I believe, it is a design flaw in LaTeX that the \\ command does not
have a counterpart with no optional * and [] arguments. For humans \\ is
enough, but it is fragile when LaTeX is used as an intermediate export
format. A part of the problem is that all 3rd party packages should be
adapted for the robust \\ sibling. Likely it may be solved by additional
pass in the exporter code but it will significantly increase its
complexity. I have no idea what is appropriate place to discuss such
issue with LaTeX developers.
The following is irrelevant to the recent changes. I have tried
---- >8 ----
text
#+begin_verse
a b
c d
e f
g h
#+end_verse
---- 8< ----
With the fix Ihor committed today I have got
---- >8 ----
text
\begin{verse}
\vspace*{1em}
a b\\\empty
c d\\\empty
\vspace*{1em}
e f\\\empty
g h\\\empty
\end{verse}
---- 8< ----
My expectation was
---- >8 ----
\begin{verse}
a b\\\empty
c d
e f\\\empty
g h
\end{verse}
---- 8< ----
I am surprised that \vspace is added instead of empty line between
stanzas. Is there a reason to override LaTeX defaults? If such reason
exists would not it better to add
\parskip=1em plus 0.5em minus 0.25em\relax
before first verse line? Is hard coded rigid vertical space acceptable
when high quality output is desired? \vspace before first line looks
like a bug. Frankly speaking, nested calls of `replace-regexp-in-string'
makes the code hard to read.
P.S. I have not found exact citation, but I noticed a mention: Lamport
expected that verse environment would get negative feedback from poets.
next prev parent reply other threads:[~2022-10-16 15:18 UTC|newest]
Thread overview: 53+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-15 21:35 [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX Juan Manuel Macías
2022-10-16 3:24 ` Ihor Radchenko
2022-10-16 12:08 ` Juan Manuel Macías
2022-10-16 15:04 ` Max Nikulin [this message]
2022-10-16 16:33 ` Verse block and separations (was: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX) Juan Manuel Macías
2022-10-17 8:54 ` Ihor Radchenko
2022-10-18 9:39 ` Verse block and separations Juan Manuel Macías
2022-10-17 14:48 ` Verse block and separations (was: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX) Max Nikulin
2022-10-19 11:08 ` Max Nikulin
2022-10-19 11:24 ` Verse block and separations Juan Manuel Macías
2022-10-16 17:14 ` Line breaks and brackets in LaTeX export (was: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX) Juan Manuel Macías
2022-10-17 9:04 ` Ihor Radchenko
2022-10-17 11:30 ` Line breaks and brackets in LaTeX export Juan Manuel Macías
2022-10-17 11:47 ` Ihor Radchenko
2022-10-17 12:27 ` Juan Manuel Macías
2022-10-17 15:01 ` Juan Manuel Macías
2022-10-17 16:46 ` Max Nikulin
2022-10-17 18:04 ` Juan Manuel Macías
2022-10-18 4:41 ` Ihor Radchenko
2022-10-18 14:23 ` Juan Manuel Macías
2022-10-19 3:57 ` Ihor Radchenko
2022-10-19 5:11 ` Max Nikulin
2022-10-19 11:16 ` Juan Manuel Macías
2022-10-19 12:30 ` Juan Manuel Macías
2022-10-19 17:07 ` Max Nikulin
2022-10-20 16:55 ` Juan Manuel Macías
2022-10-21 3:34 ` Ihor Radchenko
2022-10-21 16:38 ` Max Nikulin
2022-10-21 19:32 ` Juan Manuel Macías
[not found] ` <ac290c60-3b54-5521-eb16-82e6611dc6e2@gmail.com>
2022-10-20 17:07 ` Juan Manuel Macías
2022-10-29 2:36 ` Ihor Radchenko
2022-11-13 17:01 ` Max Nikulin
2022-10-18 4:39 ` Ihor Radchenko
2022-10-19 17:12 ` Max Nikulin
2022-10-20 5:07 ` Ihor Radchenko
2022-10-20 17:15 ` Max Nikulin
2022-10-21 3:41 ` Ihor Radchenko
2022-10-21 16:32 ` Max Nikulin
2022-10-22 5:15 ` Ihor Radchenko
2022-10-22 12:26 ` Juan Manuel Macías
2022-10-22 15:55 ` Max Nikulin
2022-11-01 1:51 ` Ihor Radchenko
2022-11-01 16:07 ` Max Nikulin
2022-11-02 6:44 ` Ihor Radchenko
2022-11-02 6:46 ` Ihor Radchenko
2022-11-02 15:27 ` Max Nikulin
2022-11-03 6:15 ` Ihor Radchenko
2022-11-03 15:00 ` Juan Manuel Macías
2022-11-03 15:33 ` Max Nikulin
2022-11-03 15:48 ` Juan Manuel Macías
2022-11-04 4:23 ` Ihor Radchenko
2022-11-04 5:40 ` Max Nikulin
2022-11-05 5:30 ` Ihor Radchenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='tih6ii$lvr$1@ciao.gmane.io' \
--to=manikulin@gmail.com \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.