From: Oliver Scholz <alkibiades@gmx.de>
Subject: Re: skeletons/abbrevs
Date: Sat, 26 Apr 2003 11:34:33 +0200 [thread overview]
Message-ID: <878ytxhaae.fsf@ID-87814.user.dfncis.de> (raw)
In-Reply-To: mailman.5197.1051285138.21513.help-gnu-emacs@gnu.org
Oliver Lohmann <nagash2270@yahoo.de> writes:
> Hello,
>
> i've got a problem with making useful
> skeletons/abbrevs:
>
> i.e. i define the following function/skeleton-construct:
> ;;===
> (defun myFor(s1 s2 s3)
> (interactive "sSet Var: \nsSet BreakCondition: \nsSet Incr: ")
> (skeleton-insert'(nil
> >"for(" s1 ";" s2 ";" s3 ")" "{" \n
> > _ \n
> > "}" \n
> )))
> ;;===
Use `define-skeleton' instead:
(define-skeleton my-for
"Insert the skeleton for a for-loop."
>"for("
(skeleton-read "Set Var: ") ";"
(skeleton-read "Set BreakCondition: ") ";"
(skeleton-read "Set Incr: ") ")" "{" \n
> _ \n
> "}" \n)
(define-abbrev c-mode-abbrev-table "ffor" "" 'my-for)
Oliver
--
6 Floréal an 211 de la Révolution
Liberté, Egalité, Fraternité!
next parent reply other threads:[~2003-04-26 9:34 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.5197.1051285138.21513.help-gnu-emacs@gnu.org>
2003-04-26 9:34 ` Oliver Scholz [this message]
2003-04-25 15:38 skeletons/abbrevs Oliver Lohmann
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=878ytxhaae.fsf@ID-87814.user.dfncis.de \
--to=alkibiades@gmx.de \
/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.