diff options
| author | Stefan Monnier | 2014-04-15 09:21:18 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2014-04-15 09:21:18 -0400 |
| commit | 20fa59a004fff136c8fe8d4cd160c12d208c5cde (patch) | |
| tree | ca419d8f8bfd86149ee28c3b1aad2d961bc33695 /doc/lispref | |
| parent | f596f897c6681236092a47cabf51d07abff2286b (diff) | |
| download | emacs-20fa59a004fff136c8fe8d4cd160c12d208c5cde.tar.gz emacs-20fa59a004fff136c8fe8d4cd160c12d208c5cde.zip | |
* src/buffer.c (Foverlays_at): Add argument `sorted'.
* doc/lispref/display.texi (Overlay Properties): Reword the doc of `priority'.
(Finding Overlays): Document new arg of `overlays-at'.
* lisp/obsolete/lucid.el (extent-at):
* lisp/htmlfontify.el (hfy-overlay-props-at): Use the new `sorted' arg of
overlays-at.
(hfy-fontify-buffer): Remove unused var `orig-ovls'.
* lisp/ps-def.el (ps-generate-postscript-with-faces1): Use the new `sorted'
arg of overlays-at. Use `invisible-p'.
Diffstat (limited to 'doc/lispref')
| -rw-r--r-- | doc/lispref/display.texi | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/doc/lispref/display.texi b/doc/lispref/display.texi index 0246d1a44de..acbef6b9495 100644 --- a/doc/lispref/display.texi +++ b/doc/lispref/display.texi | |||
| @@ -1475,8 +1475,10 @@ the buffer's undo list. | |||
| 1475 | 1475 | ||
| 1476 | Since more than one overlay can specify a property value for the | 1476 | Since more than one overlay can specify a property value for the |
| 1477 | same character, Emacs lets you specify a priority value of each | 1477 | same character, Emacs lets you specify a priority value of each |
| 1478 | overlay. You should not make assumptions about which overlay will | 1478 | overlay. In case two overlays have the same priority value, and one |
| 1479 | prevail when there is a conflict and they have the same priority. | 1479 | is nested in the other, then the inner one will have priority over the |
| 1480 | outer one. If neither is nested in the other then you should not make | ||
| 1481 | assumptions about which overlay will prevail. | ||
| 1480 | 1482 | ||
| 1481 | These functions read and set the properties of an overlay: | 1483 | These functions read and set the properties of an overlay: |
| 1482 | 1484 | ||
| @@ -1507,9 +1509,9 @@ of them: | |||
| 1507 | @table @code | 1509 | @table @code |
| 1508 | @item priority | 1510 | @item priority |
| 1509 | @kindex priority @r{(overlay property)} | 1511 | @kindex priority @r{(overlay property)} |
| 1510 | This property's value (which should be a non-negative integer) | 1512 | This property's value determines the priority of the overlay. No priority, or |
| 1511 | determines the priority of the overlay. No priority, or @code{nil}, | 1513 | @code{nil}, means zero. A non-nil and non-integer value has |
| 1512 | means zero. | 1514 | undefined behavior. |
| 1513 | 1515 | ||
| 1514 | The priority matters when two or more overlays cover the same | 1516 | The priority matters when two or more overlays cover the same |
| 1515 | character and both specify the same property; the one whose | 1517 | character and both specify the same property; the one whose |
| @@ -1706,11 +1708,12 @@ Properties}. | |||
| 1706 | @node Finding Overlays | 1708 | @node Finding Overlays |
| 1707 | @subsection Searching for Overlays | 1709 | @subsection Searching for Overlays |
| 1708 | 1710 | ||
| 1709 | @defun overlays-at pos | 1711 | @defun overlays-at pos &optional sorted |
| 1710 | This function returns a list of all the overlays that cover the | 1712 | This function returns a list of all the overlays that cover the character at |
| 1711 | character at position @var{pos} in the current buffer. The list is in | 1713 | position @var{pos} in the current buffer. If @var{sorted} is non-nil, the list |
| 1712 | no particular order. An overlay contains position @var{pos} if it | 1714 | is in decreasing order of priority, otherwise it is in no particular order. |
| 1713 | begins at or before @var{pos}, and ends after @var{pos}. | 1715 | An overlay contains position @var{pos} if it begins at or before @var{pos}, and |
| 1716 | ends after @var{pos}. | ||
| 1714 | 1717 | ||
| 1715 | To illustrate usage, here is a Lisp function that returns a list of the | 1718 | To illustrate usage, here is a Lisp function that returns a list of the |
| 1716 | overlays that specify property @var{prop} for the character at point: | 1719 | overlays that specify property @var{prop} for the character at point: |