emacs-devel
[Top][All Lists]
Advanced

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

How to remove the "read-only" property...


From: Davin Pearson
Subject: How to remove the "read-only" property...
Date: Sun, 28 Aug 2022 19:27:07 +1200

I have written some code that makes the first line read-only:

(save-excursion
  (goto-char (point-min))
  (set-text-properties (point-at-bol) (point-at-eol) '(read-only t))
  )

When I try to remove all text-properties:

(condition-case err
    (save-excursion
      (set-text-properties (point-min) (point-max) nil))
  (error
   (message "dmp-error:err=%s" err)))

It barfs with the following error message:

dmp-error:err=(text-read-only)

How do I go about removing the read-only property of the text?

TIA,

Davin

reply via email to

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