all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* abbrevs and cursor control
@ 2003-02-13 19:01 Harry Putnam
  2003-02-14  9:02 ` Kai Großjohann
  0 siblings, 1 reply; 6+ messages in thread
From: Harry Putnam @ 2003-02-13 19:01 UTC (permalink / raw)


Is there any way to control things like where the cursor lands during
and inserted abbrev?

Something like can be done with skeletons

(define-skeleton hp-mkeywords
	"Insert nifty keywords string into mail/news messages
         and closing characters to make it searchable in a blob"
	nil
	"Keywords: "_"\n" 
	(format-time-string "X-Key-Date: %b %d %Y %w\n") 
	"X-&&: ") 

I'd like to do something like that with the symplicity of an abbrev
rather than calling command or hitting command keys.

I'm thinking of stuff like one might want when writing perl or other
scripts.
An example might be some standard stuff needed for a perl style
getopts section with the cursor located as shown:

  ## ========== BEGIN Getopts section ==========
  ## Declare vars inside qw()
  use vars qw(<cursor>);
  use Getopt::Std;
  my $optstr ="";
  getopts($optstr);

Easy enough if you don't care where the curor goes.. Just wondered
if that can be controlled in an abbrev.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-02-15 10:23 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-02-13 19:01 abbrevs and cursor control Harry Putnam
2003-02-14  9:02 ` Kai Großjohann
2003-02-14 10:00   ` Harry Putnam
2003-02-14 12:49     ` Kai Großjohann
2003-02-15  3:18       ` Harry Putnam
2003-02-15 10:23         ` Kai Großjohann

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.