From: Ruy Exel <ruyexel@gmail.com>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: emacs-orgmode@gnu.org
Subject: Re: Deletion immediately after insertion should leave org-mode tables unaltered but it doesn't
Date: Sat, 18 Nov 2017 23:16:20 -0200 [thread overview]
Message-ID: <CAB8Wf+_3wNkz=xXsT0BGtaHaYBep0YAKHSKP5dXx981vAmW01w@mail.gmail.com> (raw)
In-Reply-To: <874lprp38r.fsf@nicolasgoaziou.fr>
[-- Attachment #1: Type: text/plain, Size: 3528 bytes --]
Hi Nicolas,
This is indeed a good idea as it mimics the creation of a row in emacs
text-mode with "C-o".
Best wishes,
Ruy
On Sat, Nov 18, 2017 at 9:37 PM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:
> Hello,
>
> Ruy Exel <ruyexel@gmail.com> writes:
>
> > Given a simple table such as
> >
> > | Name | Age |
> > |-------+-----|
> > | John | 20 |
> > | Peter | 25 |
> > |-------+-----|
> >
> > place the cursor in the cell containing 'Age', insert two columns
> pressing
> > 'M-S-right' each time and, immediately after that, delete two columns
> with
> > "M-S-left". One would expect the table to return to its original state,
> > but is doesn't. In reality the table becomes
> >
> > | | Age |
> > |---+-----|
> > | | 20 |
> > | | 25 |
> > |---+-----|
> >
> > because the second deletion actually kills the column labeled "Name".
> >
> > Contrast this with the behaviour of inserting and deleting characters in
> > text-mode and you will see that the above behaviour is counter intuitive.
> >
> > I believe this is due to the fact that 'M-S-right' inserts a column at
> the
> > cursor, placing the cursor within the inserted column, while, after
> > deletion, the cursor is placed in the column to the LEFT of the deleted
> > column (except after deleting the leftmost column).
> >
> > A possible solution is to place the column to the RIGHT of the deleted
> > column after deletion (except after deleting the rightmost column).
>
> The deletion is triggered by pressing the <LEFT> arrow. Your suggestion
> would make the point move right. This is not optimal either.
>
> Maybe the other way is better. Since column creation is triggered by
> pressing <RIGHT> arrow, we might create it to the right of the current
> column, and point would move into it.
>
> WDYT?
>
> Regards,
>
> --
> Nicolas Goaziou
>
On Sat, Nov 18, 2017 at 9:37 PM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:
> Hello,
>
> Ruy Exel <ruyexel@gmail.com> writes:
>
> > Given a simple table such as
> >
> > | Name | Age |
> > |-------+-----|
> > | John | 20 |
> > | Peter | 25 |
> > |-------+-----|
> >
> > place the cursor in the cell containing 'Age', insert two columns
> pressing
> > 'M-S-right' each time and, immediately after that, delete two columns
> with
> > "M-S-left". One would expect the table to return to its original state,
> > but is doesn't. In reality the table becomes
> >
> > | | Age |
> > |---+-----|
> > | | 20 |
> > | | 25 |
> > |---+-----|
> >
> > because the second deletion actually kills the column labeled "Name".
> >
> > Contrast this with the behaviour of inserting and deleting characters in
> > text-mode and you will see that the above behaviour is counter intuitive.
> >
> > I believe this is due to the fact that 'M-S-right' inserts a column at
> the
> > cursor, placing the cursor within the inserted column, while, after
> > deletion, the cursor is placed in the column to the LEFT of the deleted
> > column (except after deleting the leftmost column).
> >
> > A possible solution is to place the column to the RIGHT of the deleted
> > column after deletion (except after deleting the rightmost column).
>
> The deletion is triggered by pressing the <LEFT> arrow. Your suggestion
> would make the point move right. This is not optimal either.
>
> Maybe the other way is better. Since column creation is triggered by
> pressing <RIGHT> arrow, we might create it to the right of the current
> column, and point would move into it.
>
> WDYT?
>
> Regards,
>
> --
> Nicolas Goaziou
>
[-- Attachment #2: Type: text/html, Size: 5135 bytes --]
next prev parent reply other threads:[~2017-11-19 1:17 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-18 13:38 Deletion immediately after insertion should leave org-mode tables unaltered but it doesn't Ruy Exel
2017-11-18 23:37 ` Nicolas Goaziou
2017-11-19 1:16 ` Ruy Exel [this message]
2017-11-21 22:47 ` Nicolas Goaziou
2017-11-28 20:27 ` Ruy Exel
2017-11-28 21:58 ` Nicolas Goaziou
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAB8Wf+_3wNkz=xXsT0BGtaHaYBep0YAKHSKP5dXx981vAmW01w@mail.gmail.com' \
--to=ruyexel@gmail.com \
--cc=emacs-orgmode@gnu.org \
--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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.