I've been experimenting today with text properties in Emacs. If I position the cursor on a line with some text on it and then execute the following code with M-:
, the line is redisplayed in bold.
(overlay-put
(make-overlay
(line-beginning-position)
(line-end-position))
'face 'bold)
If, however, I wipe out the overlay with (remove-overlays)
and execute the following code, nothing happens (except that the word "nil" appears in the minibuffer).
(put-text-property
(line-beginning-position)
(line-end-position)
'face 'bold)
From what I've gleaned so far, I'd expect that these two snippets should produce the same visual results. Why don't they?