emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Luciano Passuello <lucianop@litemind.com>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: Luciano Passuello <lucianop@litemind.com>,
	emacs-orgmode@gnu.org, Kaushal Modi <kaushal.modi@gmail.com>
Subject: Re: Insert heading above current one
Date: Fri, 29 Sep 2017 19:58:44 -0300	[thread overview]
Message-ID: <CACqKfLeiOkTPSyhS5WnvYcg0OUCDfQYYpN-kZdPjLV8TwgQcag@mail.gmail.com> (raw)
In-Reply-To: <874lrlmg9u.fsf@nicolasgoaziou.fr>

Hi, thanks for the replies!

>> To add, I also think that the earlier behavior made sense, if the point is
>> at bolp, insert before, else insert after.
>
> I think the current behaviour makes more sense, if the command is called
> with an universal argument. Indeed, what would be the point of using an
> universal argument if you get the exact same behaviour as without it?

I also think the earlier behavior made more sense. The variable
org-insert-heading-respect-content (or the universal argument)
controls how a new headline is inserted BELOW the current header
(either add immediately after the current line or down below). I don't
see how this variable should alter the behavior of adding a heading
ABOVE the current header (ie. "respecting content" or not has no
effect here, above is always above).

> Out of curiosity is there any to set this variable to something else
> than nil? There are already comfortable keybindings to set this
> temporarily (C-RET and C-u M-RET). Why would one have M-RET to behave
> exactly as C-RET? And even if there was a good reason to do so, why not
> simply re-binding M-RET in that case?

You have a good point. Looking this way, the
org-insert-heading-respect-content variable is indeed of little use.
But since the variable does exist (even though perhaps it should be
deprecated?), it should behave correctly.
And I just don't see how the behavior of adding a header above the
current line should be impacted by it.

Thanks!
Luciano.

  reply	other threads:[~2017-09-29 22:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-29 14:12 Insert heading above current one Luciano Passuello
2017-09-29 14:41 ` Kaushal Modi
2017-09-29 14:46   ` Kaushal Modi
2017-09-29 19:55     ` Nicolas Goaziou
2017-09-29 22:58       ` Luciano Passuello [this message]
2017-09-30  7:29         ` Nicolas Goaziou
2017-09-30 20:02           ` Luciano Passuello
2017-09-30 20:21             ` Nicolas Goaziou
2017-09-30 20:50               ` Luciano Passuello
2017-09-30 10:47       ` Rasmus

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

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CACqKfLeiOkTPSyhS5WnvYcg0OUCDfQYYpN-kZdPjLV8TwgQcag@mail.gmail.com \
    --to=lucianop@litemind.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=kaushal.modi@gmail.com \
    --cc=mail@nicolasgoaziou.fr \
    /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 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).