Function: follow-calculate-first-window-start-from-above

follow-calculate-first-window-start-from-above is a byte-compiled function defined in follow.el.gz.

Signature

(follow-calculate-first-window-start-from-above WINDOWS GUESS WIN START)

Source Code

;; Defined in /usr/src/emacs/lisp/follow.el.gz
;; Find the starting point, start at GUESS and search downward.
;; The returned point is always a point below GUESS.

(defun follow-calculate-first-window-start-from-above
       (windows guess win start)
  (save-excursion
    (let ((done nil)
	  win-start
	  res)
      (goto-char guess)
      (while (not done)
	(if (not (= (vertical-motion 1 (car windows)) 1))
            ;; Hit bottom!  (Can we really do this?)
	    ;; We'll keep it, since it ensures termination.
	    (progn
	      (setq done t)
	      (setq res (point-max)))
	  (setq win-start (follow-calc-win-start windows (point) win))
	  (if (>= win-start start)
	      (setq done t res (point)))))
      res)))