emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Babel blocks get unindented when making changes outside the blocks
@ 2015-02-13 16:46 Mark Edgington
  2015-02-14 11:52 ` Nicolas Goaziou
  0 siblings, 1 reply; 2+ messages in thread
From: Mark Edgington @ 2015-02-13 16:46 UTC (permalink / raw)
  To: emacs-orgmode

Hello all,

Given the following code:
----- BEGIN CODE -----
* some headline
- blah
  - blah
    - blah
  - blah
    - blah
    #+begin_src octave
        first line

        if (num <= 2)
            stuff
        end
    #+end_src

- blah
  # some comments
  #       more comments
  1. item 1
----- END CODE -----

If I go to the end of the 'item 1' line, and do 'M-x org-meta-return',
the code in the preceding source-block gets un-indented, so that it
looks like:

    #+begin_src octave
    first line

    if (num <= 2)
    stuff
    end
    #+end_src

This behavior has been confirmed by another via IRC, and supposedly
the problem lies somewhere in org-list-struct-apply-struct.

I just wanted to report this strange behavior in the hope that someone
might have an idea on how to remedy it.

Regards,

Mark

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Babel blocks get unindented when making changes outside the blocks
  2015-02-13 16:46 Babel blocks get unindented when making changes outside the blocks Mark Edgington
@ 2015-02-14 11:52 ` Nicolas Goaziou
  0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Goaziou @ 2015-02-14 11:52 UTC (permalink / raw)
  To: Mark Edgington; +Cc: emacs-orgmode

Hello,

Mark Edgington <edgimar@gmail.com> writes:

> Given the following code:
> ----- BEGIN CODE -----
> * some headline
> - blah
>   - blah
>     - blah
>   - blah
>     - blah
>     #+begin_src octave
>         first line
>
>         if (num <= 2)
>             stuff
>         end
>     #+end_src
>
> - blah
>   # some comments
>   #       more comments
>   1. item 1
> ----- END CODE -----
>
> If I go to the end of the 'item 1' line, and do 'M-x org-meta-return',
> the code in the preceding source-block gets un-indented, so that it
> looks like:
>
>     #+begin_src octave
>     first line
>
>     if (num <= 2)
>     stuff
>     end
>     #+end_src

This should be fixed. Thank you.


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-02-14 11:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-13 16:46 Babel blocks get unindented when making changes outside the blocks Mark Edgington
2015-02-14 11:52 ` Nicolas Goaziou

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).