Function: preview-gs-urgentize

preview-gs-urgentize is a byte-compiled function defined in preview.el.

Signature

(preview-gs-urgentize OV BUFF)

Documentation

Make a displayed overlay render with higher priority.

This function is used in fake conditional display properties for reordering the conversion order to prioritize on-screen images. OV is the overlay in question, and BUFF is the Ghostscript process buffer where the buffer-local queue is located.

Source Code

;; Defined in ~/.emacs.d/elpa/auctex-14.1.2/preview.el
(defun preview-gs-urgentize (ov buff)
  "Make a displayed overlay render with higher priority.
This function is used in fake conditional display properties
for reordering the conversion order to prioritize on-screen
images.  OV is the overlay in question, and BUFF is the
Ghostscript process buffer where the buffer-local queue
is located."
  ;; It does not matter that ov gets queued twice in that process: the
  ;; first version to get rendered will clear the 'queued property.
  ;; It cannot get queued more than twice since we remove the
  ;; conditional display property responsible for requeuing here.
  ;; We don't requeue if the overlay has been killed (its buffer made
  ;; nil).  Not necessary, but while we are checking...
  ;; We must return t.
  (preview-remove-urgentization ov)
  (when (and (overlay-get ov 'queued)
             (overlay-buffer ov))
    (with-current-buffer buff
      (push ov preview-gs-queue)))
  t)