Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

emacs some part of the text read only

(defun make-region-read-only (start end)
  (interactive "*r")
  (let ((inhibit-read-only t))
    (put-text-property start end 'read-only t)))

(defun make-region-read-write (start end)
  (interactive "*r")
  (let ((inhibit-read-only t))
    (put-text-property start end 'read-only nil)))
Source by itectec.com #
 
PREVIOUS NEXT
Tagged: #emacs #part #text #read
ADD COMMENT
Topic
Name
5+3 =