[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: skeleton.el _ versus @

From: Joe Kelsey
Subject: Re: skeleton.el _ versus @
Date: 11 Apr 2003 17:11:15 -0700

On Fri, 2003-04-11 at 16:59, Stefan Monnier wrote:
> >     According to Stefan, he put it in Emacs 21.1.
> > 
> > That isn't too long ago, so I don't think it isn't too late
> > to change this back.
> > 
> > Stefan, could you give me a brief self-contained description of the
> > two behaviors, written for someone who doesn't use skeleton?
> A simple skeleton could look like
>        ... "(" _ ")" ...
> If a region is active when executing the skeleton, it will end
> up wrapping the region in parentheses. Otherwise, it will insert
> "()" and point point in the middle.
> Skeleton also has a special @ which pushes the corresponding position
> onto a list of positions which elisp code can then use as it
> sees fit (I don't actually know of any uses, so I'll let other
> people describe what these are might be used for).

mmm-mode uses @ in skeletons to mark special positions around the
skeleton for use afterwards.  An mmm-mode skeleton looks like

... @ "front-tag" @ "other stuff" _ "other stuff" @ back tag" @

mmm-mode expects point to end up at the _.  Simply because Stefan could
not imagine what @ was used for, he discarded its behavior and ruined
all of the existing mmm-mode skeletons.

> Before my patch, the behavior was that after insertion of
> a skeleton, point would be placed at "the first occurrence of _
> or at the end of the skeleton".
> What my patch changed is that point after insertion of a skeleton
> is now placed at "the first occurrence of _ or @
> or at the end of the skeleton".
>       Stefan

reply via email to

[Prev in Thread] Current Thread [Next in Thread]