1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-06 14:30:50 -08:00

Improve 'put-image' documentation

* doc/lispref/display.texi (Showing Images): Mention that it returns the
created overlay.
* lisp/image.el (put-image): And here.
This commit is contained in:
Robert Pluim 2024-07-09 17:14:45 +02:00
parent c38d5cc3b2
commit 945335fec1
2 changed files with 6 additions and 2 deletions

View file

@ -7093,7 +7093,9 @@ buffer's text.
Internally, this function creates an overlay, and gives it a Internally, this function creates an overlay, and gives it a
@code{before-string} property containing text that has a @code{display} @code{before-string} property containing text that has a @code{display}
property whose value is the image. (Whew! that was a mouthful@dots{}) property whose value is the image. (Whew! that was a mouthful@dots{}).
It returns the created overlay upon success, and also sets its
@code{put-image} property to @code{t}.
@end defun @end defun
@defun remove-images start end &optional buffer @defun remove-images start end &optional buffer

View file

@ -638,7 +638,9 @@ IMAGE must be an image created with `create-image' or `defimage'.
IMAGE is displayed by putting an overlay into the current buffer with a IMAGE is displayed by putting an overlay into the current buffer with a
`before-string' STRING that has a `display' property whose value is the `before-string' STRING that has a `display' property whose value is the
image. STRING defaults to \"x\" if it's nil or omitted. image. STRING defaults to \"x\" if it's nil or omitted.
The overlay created by this function has the `put-image' property set to t. Upon success, this function returns the created overlay with its
`put-image' property set to t.
POS may be an integer or marker. POS may be an integer or marker.
AREA is where to display the image. AREA nil or omitted means AREA is where to display the image. AREA nil or omitted means
display it in the text area, a value of `left-margin' means display it in the text area, a value of `left-margin' means