Search Results

Found 1 results for "943f293b027047de77f2b4fb75d8d7a3" across all boards searching md5.

Anonymous /g/105652614#105706173
6/26/2025, 2:56:04 AM
>>105696372
>is there a way to see what percentage of the way you're into an entire info mode manual? Not just the current section

(defun Info-percent ()
"Return what percentage of the way you're into the current info manual.

Examples:

;; Return a plist with current-line, total-lines, and percent.
ELISP> (with-current-buffer \"*info*\" (Info-percent))
(current-line 113 total-lines 2569 percent 4.398598676527832)
"
(interactive)
(without-restriction
(let* ((current-line (line-number-at-pos))
(total-lines (line-number-at-pos (point-max)))
(percent (* (/ (float current-line) total-lines) 100.0))
(result `(current-line ,current-line
total-lines ,total-lines
percent ,percent)))
(message "%s" result)
result)))


Examples:
ELISP> (with-current-buffer "*info*" (Info-percent))
(current-line 77 total-lines 2569 percent 2.997275204359673)

ELISP> (plist-get (with-current-buffer "*info*" (Info-percent)) 'percent)
2.997275204359673