Re: Verse block and separations

2022-10-19 Thread Juan Manuel Macías
Max Nikulin writes: > I still prefer to avoid replacement of latex newlines back to empty > string. Though I am really happy with the following code, I expected a > more concise snippet. Unit tests may found bugs in it. > > (let ((contents "\n\n 0 \n\n\na b\nc d e \n\n\nf g \n h i\n\n")) >

Re: Verse block and separations (was: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX)

2022-10-19 Thread Max Nikulin
On 16/10/2022 23:33, Juan Manuel Macías wrote: (replace-regexp-in-string "^[ \t]+" (lambda (m) (format "\\hspace*{%dem}" (length m))) (replace-regexp-in-string "\\(\n\\)+\\([ \t]*\\)+" "\n" (replace-r

Re: Verse block and separations

2022-10-18 Thread Juan Manuel Macías
Ihor Radchenko writes: >> In my init I have redefined the verse block like this, so that there is >> a white line between stanzas, not \vspace (I have also added some things >> for the verse package, so that the numbering of verses is not broken). >> So your example would produce a white line unde

Re: Verse block and separations (was: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX)

2022-10-17 Thread Max Nikulin
On 16/10/2022 23:33, Juan Manuel Macías wrote: Max Nikulin writes: I am surprised that \vspace is added instead of empty line between stanzas. First of all, I'm afraid that in my previous post I mixed up two different issues: the verse block bug and my personal opinions about the new added co

Re: Verse block and separations (was: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX)

2022-10-17 Thread Ihor Radchenko
Juan Manuel Macías writes: > Yes, you're right: that \vspace is the normal behavior of the block when > exporting to LaTeX, and it is certainly not quite correct. In LaTeX, > both the out-of-the-box verse environment and the one provided by the > 'verse' package (which, typographically speaking,

Verse block and separations (was: [bug] `org-latex-line-break-safe' breaks the export of verse blocks to LaTeX)

2022-10-16 Thread Juan Manuel Macías
Max Nikulin writes: > 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\