fix: draw hint before prompt so cursor stays at input line

view-input drew prompt first (row h-3), then hint (row h-2),
leaving the cursor at end of the hint line after 'complete'.
Typed characters appeared there. Swapped order: hint first,
prompt last, so cursor ends at the > prompt.
This commit is contained in:
2026-05-14 12:51:21 -04:00
parent d5b4c8c8f0
commit 4bfb407094

View File

@@ -213,9 +213,9 @@ Returns a list of strings, one per line."
(pos (or (st :cursor-pos) 0))
(display-start (max 0 (- pos (1- w))))
(visible (subseq text display-start (min (length text) (+ display-start w)))))
(cl-tty.backend:draw-text fb 0 (- h 3) (format nil "> ~a" visible) (theme-color :input-fg) nil)
(cl-tty.backend:draw-text fb 0 (- h 2) (format nil " Ctrl+P palette | Up/Dn history | Tab complete")
(theme-color :hint) nil)))
(theme-color :hint) nil)
(cl-tty.backend:draw-text fb 0 (- h 3) (format nil "> ~a" visible) (theme-color :input-fg) nil)))
#+end_src
** Sidebar