From: Drew Adams <drew.adams@oracle.com>
To: Teemu Likonen <tlikonen@iki.fi>
Cc: 8196-done@debbugs.gnu.org, "Jambunathan K." <kjambunathan@gmail.com>
Subject: bug#8196: 23.1; Feature request with code: "C-x TAB" to understand tab-stop-list
Date: Tue, 8 Oct 2013 09:21:26 -0700 (PDT) [thread overview]
Message-ID: <c684b5d2-b898-467f-878e-ee80322f9863@default> (raw)
In-Reply-To: <87hacr3hg0.fsf@mithlond.arda>
> >> I just folded it into indent-rigidly.
> >
> > Dunno what that means exactly, but a priori: too bad. Should be a
> > separate command, as previously discussed and agreed.
>
> The change has effect only when called interactively and when there is
> no prefix argument. The new feature is more useful.
Yes, we know that. Please read the thread. Remember this part, for
instance?
> > > What you can propose instead is that your new command get the
> > > traditional binding for `indent-rigidly', `C-x TAB'. What we
> > > should not do is replace the current `indent-rigidly' behavior
> > > by the proposed behavior in the same command. Steal the key,
> > > perhaps, but not the command.
> >
> > That's exactly what I'm doing. My command is called
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> > "tl-indent-region" (ok, we can drop the tl- prefix) and it relies
> > on indent-rigidly to do the job.
>
> Great. Sounds good. I misunderstood that you wanted to change
> `indent-rigidly'; sorry.
>
> > My command behaves the same as indent-rigidly when called with
> > a numeric prefix argument.
>
> Yes, that I understood from the code.
Changing the key binding but not the command itself, as you said you
were doing, would be fine. There is no reason to change
`indent-rigidly' itself.
"My command" should have remained just that: a separate command.
The fact that without a prefix arg it behaves the same as
`indent-rigidly' is irrelevant, except as a (weak) argument for
someone wanting to replace `indent-rigidly'. It means nothing for
someone truly intending to add a new command and bind it by default
to `C-x TAB'.
What is important is to keep two separate functions, and not screw
`indent-rigidly'.
This portion of the thread is also relevant, as it seems to be what has
now been implemented, in spite of the discussion:
d> A mix would also be possible, but less desirable IMO: modify
d> `indent-rigidly' to provide the new behavior only interactively,
d> never when used in code. That has the disadvantage of not letting
^^^^^^^^^^^
d> code take advantage of the indentation-to-tab-stop behavior.
d> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
d> I think it best to provide a separate command.
d>
d> A separate command also lets any user who prefers the current default
d> behavior interactively to bind `indent-rigidly', instead of your
d> command, to `C-x TAB'. You find it handy to indent to a tab stop by
d> default (ARG = nil), and then repeat (e.g., C-x z z z z). Someone
d> else might find it handier to indent one column instead of one tab
d> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
d> stop by default, and then repeat to indent the region incrementally.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
The simplest approach is the best one, for these and other reasons
discussed: Provide the new command. Even make it the new default
binding for `C-x TAB'. But keep `indent-rigidly' as it has been.
Simple, sane, no downside, wise.
prev parent reply other threads:[~2013-10-08 16:21 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-07 18:19 bug#8196: 23.1; Feature request with code: "C-x TAB" to understand tab-stop-list Teemu Likonen
2013-07-12 17:19 ` Teemu Likonen
2013-07-12 19:11 ` Drew Adams
2013-07-12 19:18 ` Drew Adams
2013-07-12 20:05 ` Teemu Likonen
2013-07-12 21:18 ` Drew Adams
2013-07-12 22:53 ` Jambunathan K
2013-07-13 5:43 ` Teemu Likonen
2013-07-13 4:49 ` Teemu Likonen
2013-07-13 4:59 ` Drew Adams
2013-07-13 20:02 ` Stefan Monnier
2013-07-14 14:41 ` Teemu Likonen
2013-10-08 6:18 ` Stefan Monnier
2013-10-08 15:12 ` Drew Adams
2013-10-08 15:34 ` Teemu Likonen
2013-10-08 16:21 ` Drew Adams [this message]
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=c684b5d2-b898-467f-878e-ee80322f9863@default \
--to=drew.adams@oracle.com \
--cc=8196-done@debbugs.gnu.org \
--cc=kjambunathan@gmail.com \
--cc=tlikonen@iki.fi \
/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.