all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Teemu Likonen <tlikonen@iki.fi>
Cc: 8196@debbugs.gnu.org
Subject: bug#8196: 23.1; Feature request with code: "C-x TAB" to understand tab-stop-list
Date: Fri, 12 Jul 2013 14:18:27 -0700 (PDT)	[thread overview]
Message-ID: <9e30b1da-e346-420f-9d60-698925e50a59@default> (raw)
In-Reply-To: <87k3kv4k9f.fsf@mithlond.arda>

> http://lists.gnu.org/archive/html/help-gnu-emacs/2011-03/msg00243.html

OK, so you take as the reference column the indentation of the leftmost
line.  Without some such specification what you described earlier was
incomplete.

> Here's a concrete use-case....

My point is that this does not belong in `indent-rigidly'.  Create a new
command for it.  That's all.  `indent-rigidly' is a very old function
that is used not only interactively but in Lisp code.  There's no telling
how much existing code out there might use the fact that ARG = nil
indents one column.

> The feature supersedes indent-rigidly.

I don't think so.  And I hope not.  It is a different function.
Superseding means nothing useful is lost.  In this case what is lost
is the default behavior (ARG = nil) that you are replacing.  Depending
on the context and the user, that lost behavior is at least as useful
as its replacement.

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.

A mix would also be possible, but less desirable IMO: modify
`indent-rigidly' to provide the new behavior only interactively, never
when used in code.  That has the disadvantage of not letting code take
advantage of the indentation-to-tab-stop behavior.  I think it best to
provide a separate command.

A separate command also lets any user who prefers the current default
behavior interactively to bind `indent-rigidly', instead of your command,
to `C-x TAB'.  You find it handy to indent to a tab stop by default
(ARG = nil), and then repeat (e.g., C-x z z z z).  Someone else might
find it handier to indent one column instead of one tab stop by default,
and then repeat to indent the region incrementally.

FWIW, I would no doubt do that (but that has nothing to do with why I
replied to this thread), since I never use tab stops and I do indent
regions rigidly and incrementally.

Just one opinion.  Two separate commands provide more options for users,
including Lisp coders.  I do not object to your appropriating `C-x TAB'
for the new command.  But please do not touch the existing command.

I would also suggest polling the users wrt the key binding.  It's not
obvious a priori that more people will want to indent via tab stops.





  reply	other threads:[~2013-07-12 21:18 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 [this message]
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

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=9e30b1da-e346-420f-9d60-698925e50a59@default \
    --to=drew.adams@oracle.com \
    --cc=8196@debbugs.gnu.org \
    --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.