GNU bug report logs - #8376
23.3; font-lock-face doesn't get yanked

Previous Next

Package: emacs;

Reported by: Uday S Reddy <U.S.Reddy <at> cs.bham.ac.uk>

Date: Tue, 29 Mar 2011 17:28:01 UTC

Severity: minor

Found in version 23.3

Done: Chong Yidong <cyd <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #14 received at 8376 <at> debbugs.gnu.org (full text, mbox):

From: Chong Yidong <cyd <at> gnu.org>
To: Uday S Reddy <u.s.reddy <at> cs.bham.ac.uk>
Cc: Glenn Morris <rgm <at> gnu.org>, 8376 <at> debbugs.gnu.org
Subject: Re: bug#8376: 23.3; font-lock-face doesn't get yanked
Date: Sat, 18 Aug 2012 13:36:08 +0800
Uday S Reddy <u.s.reddy <at> cs.bham.ac.uk> writes:

> My context was in writing email messages in mail-mode/message-mode,
> both of which use font-lock to fontify the headers and the cited text.
>
> VM has functions that put "attachment buttons" into the mail-mode
> buffers, which are have data stored in text properties.  I wanted to
> put a face on them to make them look like "buttons".  It works fine
> normally but it is not preserved under killing and yanking.

The reason font-lock-face is removed in buffers in which font-lock is
active is that font-lock-face is typically applied by programs, so it
would be wrong for a user-level operation like yanking to apply it.

This is a rule of thumb; there is no right or wrong answer.  If you
prefer to preserve font-lock-face, I've added to trunk a new option
`yank-handled-properties' which can be customized to get the behavior
you want.




This bug report was last modified 12 years and 280 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.