Juan Manuel Macías writes:
> Subject: [PATCH] lisp/ox-latex.el: Add the `:literal' attribute to verse
> block.
Thanks!
Applied, onto main.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=2eb4fd890
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode a
Ihor Radchenko writes:
> Thanks!
>
>> * (org-latex-verse-block): now the treatment of blank lines is
>> consistent with the syntax of the LaTeX `verse' environment, and the
>> one provided by the `verse' package. If the `:literal' attribute is
>> used, all blank lines are preserved and exported as
Juan Manuel Macías writes:
> Here is the modified patch.
Thanks!
> * (org-latex-verse-block): now the treatment of blank lines is
> consistent with the syntax of the LaTeX `verse' environment, and the
> one provided by the `verse' package. If the `:literal' attribute is
> used, all blank lines
Ihor Radchenko writes:
> Juan Manuel Macías writes:
>
>> I think the best thing is to rethink the :literal attribute, as I
>> commented at the end of my other email:
>>
>> - without :literal --> verse environment with a more "canonical" syntax.
>>
>> - with :literal --> verse environment seen in
Juan Manuel Macías writes:
> I think the best thing is to rethink the :literal attribute, as I
> commented at the end of my other email:
>
> - without :literal --> verse environment with a more "canonical" syntax.
>
> - with :literal --> verse environment seen in the "old (org) style",
> preser
Ihor Radchenko writes:
> Sure, but look at the pdf. The generated pdfs are not different for some
> reason.
Ah, sorry. It was a foolish oversight of mine. The point is that a
\vspace after a line break in normal text has no effect. This does work:
lorem ipsum\\
\vspace*{10ex}\\
dolor
but it's a
Juan Manuel Macías writes:
>> The output is not different, which it should be, AFAIU. Am I missing
>> something?
>
> I have tried your examples and I think both give the expected result.
> Look at this screenshot:
>
> https://i.imgur.com/ofl8Z9f.png
Sure, but look at the pdf. The generated pdfs
Ihor Radchenko writes:
> Thanks!
> I tested the patch with
>
> #+attr_latex: :literal t
>
> #+begin_verse
>
> This is just a test.
> ASF.
>
> #+end_verse
>
>
> and then with
>
> #+attr_latex: :literal t
>
> #+begin_verse
>
> This is just a test.
>
> ASF.
>
Juan Manuel Macías writes:
> Ihor Radchenko writes:
>
>> Looks reasonable in general. Of course, we will also need to document
>> the new attribute.
>
> Here is the modified patch (with your suggestions, including the `rx' code)
> and the documentation of the new attribute.
Thanks!
I tested the
Ihor Radchenko writes:
> Looks reasonable in general. Of course, we will also need to document
> the new attribute.
Here is the modified patch (with your suggestions, including the `rx' code)
and the documentation of the new attribute.
--
Juan Manuel Macías
https://juanmanuelmacias.com
https:
Juan Manuel Macías writes:
>>> + (concat "\\("
>>> + (regexp-quote org-latex-line-break-safe)
>>> + "\n\\)"
>>> + "\\(^[ \t]*"
>>> + (regexp-quote org-latex-line-break-safe)
>>> +
Ihor Radchenko writes:
> Juan Manuel Macías writes:
>> + (vwidth (if (not lit)
>> + (if versewidth (format "\\settowidth{\\versewidth}{%s}\n"
>> versewidth) "")
>> + ""))
>
> Can just do (if (and versewidth (not lit)) (format ...) "")
>
>> + (linres
Juan Manuel Macías writes:
> How about this (pre-)patch? With the `:literal' attr., the content of the
> block is exported "as is", with all manual formatting preserved.
Looks reasonable in general.
Of course, we will also need to document the new attribute.
> I have made some modifications in
Ihor Radchenko writes:
> Juan Manuel Macías writes:
>
>> ... In any case, the fact that the verse block can also be used to
>> literally export line breaks and horizontal/vertical spaces is
>> interesting. Something occurred to me that I don't know if it's a bit
>> foolhardy: how about a LaTeX at
Juan Manuel Macías writes:
> ... In any case, the fact that the verse block can also be used to
> literally export line breaks and horizontal/vertical spaces is
> interesting. Something occurred to me that I don't know if it's a bit
> foolhardy: how about a LaTeX attribute ':literal t'? If used,
Ihor Radchenko writes:
> Well. Technically, we already warn users that the blank lines are
> preserved in the verse blocks:
>
> 12.1 Paragraphs
> ===
>
> Paragraphs are separated by at least one empty line. If you need to
> enforce a line break within a paragraph,
Juan Manuel Macías writes:
>> Do you mean that people use extra leading/trailing spaces just to get
>> extra vertical space before/after the verse block in _latex_ export?
>
> No, I don't think people use it for that purpose. I meant that if
> someone puts a space before or after the content (whi
Ihor Radchenko writes:
>>> I see nothing that would prevent merging this patch.
>>> However, I believe that removing blank lines before/after content is
>>> something we may want to do in other built-in backends as well. WDYT?
>>
>> I think you're right. My impression is that the blank lines befor
Juan Manuel Macías writes:
>> I see nothing that would prevent merging this patch.
>> However, I believe that removing blank lines before/after content is
>> something we may want to do in other built-in backends as well. WDYT?
>
> I think you're right. My impression is that the blank lines befor
Ihor Radchenko writes:
>> Rationale for this patch: the treatment of blank lines in
>> `org-latex-verse-block' is inconsistent with the syntax of the `verse'
>> environment, both the one that includes LaTeX and the one provided by
>> the `verse' package as a replacement for the former.
>> ...
>> S
Juan Manuel Macías writes:
> Rationale for this patch: the treatment of blank lines in
> `org-latex-verse-block' is inconsistent with the syntax of the `verse'
> environment, both the one that includes LaTeX and the one provided by
> the `verse' package as a replacement for the former.
> ...
> So
Rationale for this patch: the treatment of blank lines in
`org-latex-verse-block' is inconsistent with the syntax of the `verse'
environment, both the one that includes LaTeX and the one provided by
the `verse' package as a replacement for the former.
Currently, each blank line is exported to LaTe
22 matches
Mail list logo