Uwe Brauer writes:
>> "Stephen" == Stephen J Turnbull
<stephen(a)xemacs.org> writes:
> I'm unclear on how useful it would be to most users
Maybe the example was not very good, but what about toggling between
2
different fonts?
No, I understood the example fine.
But maybe this is a question of taste.
Exactly, it's a matter of taste. If you find this kind of thing
convenient in *your* workflow, you should be able to get XEmacs to do
it, conveniently. Since it defines a new command and *you* bind it to
a keystroke, it's nobody else's business. And since there are similar
features (the message-mode function on C-a, GNU Emacs's new C-l
functionality), evidently somebody likes this style of UI. Making it
easier to define is perhaps a service to those users.
But it's not to my taste, so I wonder. For example, for your my-home
command, would
(defun my-home ()
(interactive)
(cond ((bolp) (beginning-of-buffer))
((looking-back "\\s-*" (point-at-bol)) (beginning-of-line))
(t (back-to-indentation))))
be better, about the same, or worse than the version you posted? (The
difference is that instead of counting repetitions, this version
checks whether you're already at one of the target places, and if so,
moves to the target earlier in the buffer.)
> extended functionality to actually define a command)
> `defun-command-sequence'.
You mean
(defun defun-command-sequence
I mean maybe it would be good it
(defun-command-sequence my-home
"Move to margin, to bol, or to bob depending on number of repetitions."
back-to-indentation
beginning-of-line
beginning-of-buffer)
(define-key global-map [home] #'my-home)
does the desired thing.
Steve
_______________________________________________
XEmacs-Beta mailing list
XEmacs-Beta(a)xemacs.org
http://lists.xemacs.org/mailman/listinfo/xemacs-beta