unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Text Properties And Buffer Modification
@ 2018-12-04 23:39 T.V Raman
  2018-12-05  6:33 ` Eli Zaretskii
  0 siblings, 1 reply; 23+ messages in thread
From: T.V Raman @ 2018-12-04 23:39 UTC (permalink / raw)
  To: emacs-devel


At present, modifying text properties (adding, removing or changing
properties) markes the buffer as  modified.
Since property changes are mostly cosmetic, is there a good reason why
this is so?

Given the present state of buffer-modified status with respect to
text-properties, one  has to be fairly careful e.g.
naively writing 
(with-silent-modifications (put-text-property ...))
will work *most of the time* except when you say something like:
(with-silent-modifications 
  (put-text-property beg end 'face 'bold other-buffer))

you actually need to write this:

(with-silent-modifications 
  (with-current-buffer other-buffer 
    (put-text-property beg end 'face 'bold other-buffer)))

-- 
Id: kg:/m/0285kf1 



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

end of thread, other threads:[~2018-12-08 11:22 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-12-04 23:39 Text Properties And Buffer Modification T.V Raman
2018-12-05  6:33 ` Eli Zaretskii
2018-12-05  7:15   ` Joost Kremers
2018-12-05  8:30     ` Eli Zaretskii
2018-12-05 15:32       ` Stefan Monnier
2018-12-05 17:35         ` T.V Raman
2018-12-05 18:42         ` Eli Zaretskii
2018-12-05 19:04           ` martin rudalics
2018-12-05 19:09             ` Eli Zaretskii
2018-12-06  9:07               ` martin rudalics
2018-12-06  9:19                 ` Eli Zaretskii
2018-12-06 10:10                   ` martin rudalics
2018-12-06 10:28                     ` Eli Zaretskii
2018-12-06 18:46                       ` martin rudalics
2018-12-06 19:16                         ` Eli Zaretskii
2018-12-08  9:42                           ` martin rudalics
2018-12-08 11:22                             ` Eli Zaretskii
2018-12-05 20:54           ` Stefan Monnier
2018-12-06  6:04             ` Eli Zaretskii
2018-12-05  9:16   ` martin rudalics
2018-12-05 10:54     ` Eli Zaretskii
2018-12-05 19:04       ` martin rudalics
2018-12-05 19:08         ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).