This was rather trivial to add to emacs:
(defun lock ()
"Make a section of text read-only, and add an overlay so
(let ((start (region-beginning))
(overlay-put (make-overlay start (+ 1 end)) 'face
'(:background "light slate gray"))
(put-text-property start end 'read-only t)))
(defun unlock ()
"Unlock a region of text, and remove its overlay"
(let ((inhibit-read-only t)
(remove-overlays start (+ 1 end))
(remove-text-properties start end '(read-only))))
Just bind lock and unlock to some keys, and there you go - makes a region of text uneditable, and adds an overlay to it.