* [FR] org-babel-examplify-region does not add a newline for the example block end
@ 2021-11-20 19:17 Kristoffer
0 siblings, 0 replies; only message in thread
From: Kristoffer @ 2021-11-20 19:17 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1647 bytes --]
Hello,
I've been testing out org-babel-examplify-region in my bookshelf file to
mark excerpts from books, but there's an issue I have encountered. If
there is a #+end_example after the currently marked region, once you run
org-babel-examplify-region, it does not create a #+end_example at the
end of the marked region properly unless the last line marked includes
the line end. An example is below:
This is text,
that is marked.
#+begin_example
This is text,
already within an example block
#+end_example
Marking this text:
This is text,
that is marked.
And running org-babel-examplify-region on the marked region results in:
#+begin_example
This is text,
that is marked.#+end_example
#+begin_example
This is text,
already within an example block
#+end_example
Which is not a valid example block. I haven't checked the code itself,
but I can assume from its behavior that it does not create a new line to
place the example block end onto. Behavior for better usability would be
to place it onto a new line if other text is present on the same line as
the marked region end. E.g.
#+begin_example
This is text,
that is marked.
#+end_example
#+begin_example
This is text,
already within an example block
#+end_example
Alternatively, it could also just make an assumption and always place it
onto a new line, but that'd hurt intuitive usability.
Regardless, I think something should be done to fix this, but I'm not
sure if I'm supposed to categorize this as a [BUG] so I've marked the
subject as a [FR] instead.
Regards,
Kristoffer
[-- Attachment #2: Type: text/html, Size: 2333 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-11-22 5:23 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-20 19:17 [FR] org-babel-examplify-region does not add a newline for the example block end Kristoffer
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).