diff --git a/org/channel-tui-main.org b/org/channel-tui-main.org index 7fe5b71..3da375f 100644 --- a/org/channel-tui-main.org +++ b/org/channel-tui-main.org @@ -581,9 +581,9 @@ supplied (e.g. \"/\"), pre-fill the select filter with it." (send-daemon (list :type :event :payload val)) (add-msg :system (format nil "Sent: ~a" (getf opt :title))) (setf (st :dirty) (list t t nil))))))) - (sel (cl-tty.select:make-select :options (all-commands) :on-select on-select))) + (sel (cl-tty.dialog:make-select :options (all-commands) :on-select on-select))) (when initial-filter - (setf (cl-tty.select:select-filter sel) initial-filter)) + (setf (cl-tty.dialog:select-filter sel) initial-filter)) (let ((dlg (make-instance 'cl-tty.dialog:dialog :title "Commands" :content sel))) (push dlg (st :dialog-stack))))) @@ -987,26 +987,26 @@ Returns T on success, nil on failure. Does NOT wait or retry." (setf (st :dirty) (list t t nil))) ((member ch '(:up :down)) (if (eql ch :up) - (cl-tty.select:select-prev sel) - (cl-tty.select:select-next sel))) + (cl-tty.dialog:select-prev sel) + (cl-tty.dialog:select-next sel))) ((member ch '(:enter)) - (let* ((filtered (cl-tty.select:select-filtered-options sel)) - (idx (cl-tty.select:select-selected-index sel)) + (let* ((filtered (cl-tty.dialog:select-filtered-options sel)) + (idx (cl-tty.dialog:select-selected-index sel)) (item (when (< idx (length filtered)) (third (nth idx filtered))))) (when item - (let ((cb (cl-tty.select:select-on-select sel))) + (let ((cb (cl-tty.dialog:select-on-select sel))) (when cb (funcall cb item)))))) ((let ((chr (if (characterp ch) ch (code-char ch)))) (and chr (graphic-char-p chr)) - (setf (cl-tty.select:select-filter sel) + (setf (cl-tty.dialog:select-filter sel) (concatenate 'string - (or (cl-tty.select:select-filter sel) "") + (or (cl-tty.dialog:select-filter sel) "") (string chr))))) ((member ch '(:backspace)) - (let ((f (cl-tty.select:select-filter sel))) + (let ((f (cl-tty.dialog:select-filter sel))) (when (> (length f) 0) - (setf (cl-tty.select:select-filter sel) + (setf (cl-tty.dialog:select-filter sel) (subseq f 0 (1- f)))))))) (on-key ch)))))))) ;; Keyboard reader via cl-tty.input:read-event (handles CSI, SS3, UTF-8, resize) @@ -1033,10 +1033,10 @@ Returns T on success, nil on failure. Does NOT wait or retry." (let* ((chat-w (- w (if (sidebar-visible-p w) (or (st :sidebar-width) 42) 0))) (dlg (car ds)) (sel (cl-tty.dialog:dialog-content dlg)) - (filtered (cl-tty.select:select-filtered-options sel)) - (sel-idx (cl-tty.select:select-selected-index sel)) + (filtered (cl-tty.dialog:select-filtered-options sel)) + (sel-idx (cl-tty.dialog:select-selected-index sel)) (cnt (length filtered)) - (filter (cl-tty.select:select-filter sel)) + (filter (cl-tty.dialog:select-filter sel)) (mh (min 15 (+ 1 cnt))) (panel-top (passepartout.channel-tui:input-panel-top chat-w h)) (top (max 0 (- panel-top mh))) diff --git a/org/channel-tui-view.org b/org/channel-tui-view.org index 58a12bd..33bf2b3 100644 --- a/org/channel-tui-view.org +++ b/org/channel-tui-view.org @@ -217,10 +217,10 @@ and current sidebar mode (:auto/:visible/:hidden)." (dotimes (r panel-rows) (cl-tty.backend:draw-text fb hpad (+ panel-top r) "│" (theme-color :input-prompt) nil)) ;; Render text-input widget (word-wrap + cursor) - (let ((ln (make-layout-node))) - (setf (layout-node-x ln) (+ hpad 2) - (layout-node-y ln) (1+ panel-top) - (layout-node-width ln) prompt-w) + (let ((ln (cl-tty.layout:make-layout-node))) + (setf (cl-tty.layout:layout-node-x ln) (+ hpad 2) + (cl-tty.layout:layout-node-y ln) (1+ panel-top) + (cl-tty.layout:layout-node-width ln) prompt-w) (setf (cl-tty.input:text-input-layout-node input) ln) (cl-tty.box:render input fb)) ;; Hint bar at h-2 @@ -266,7 +266,7 @@ and current sidebar mode (:auto/:visible/:hidden)." (dot-color (if (st :connected) :dot-connected :dot-disconnected))) (append ;; Gate Trace - '("GATE TRACE" . :accent) + (list (cons "GATE TRACE" :accent)) (if last-gt (mapcan (lambda (g) (let* ((name (getf g :gate)) @@ -283,23 +283,23 @@ and current sidebar mode (:auto/:visible/:hidden)." (cons (format nil " ~a" reason) :dim)) (list (cons (format nil " ~a ~a" glyph name) color))))) last-gt) - '((cons " (none)" :dim))) + (list (cons " (none)" :dim))) ;; Rules - '("" nil) - '("RULES" . :accent) + (list (cons "" nil)) + (list (cons "RULES" :accent)) (list (cons (format nil " ~d active" (or (st :rule-count) 0)) :agent-fg)) (list (cons (format nil " ~d blocked" blocked) - (if (> blocked 0) :error :dim))) + (if (> blocked 0) :error :dim))) ;; Cost - '("" nil) - '("COST" . :accent) + (list (cons "" nil)) + (list (cons "COST" :accent)) (list (cons (format nil " $~,2f" (or (st :session-cost) 0.0)) :status-fg)) ;; Files - '("" nil) - '("FILES" . :accent) - '(" (not yet)" . :dim) + (list (cons "" nil)) + (list (cons "FILES" :accent)) + (list (cons " (not yet)" :dim)) ;; spacer - '("" nil) + (list (cons "" nil)) ;; Version footer — rendered at h-2, not in the loop (list (cons (format nil "~a ~a" dot ver-label) dot-color))))) diff --git a/passepartout b/passepartout index 23ec788..d14deac 100755 --- a/passepartout +++ b/passepartout @@ -395,13 +395,14 @@ case "$COMMAND" in stty -icanon -echo -ixon 2>/dev/null || true # Ensure COLORTERM is set for modern backend detection export COLORTERM="${COLORTERM:-truecolor}" - sbcl --noinform \ + sbcl --noinform --disable-debugger \ --load "$HOME/quicklisp/setup.lisp" \ --eval '(push (truename "'"$PASSEPARTOUT_DATA_DIR"'/") asdf:*central-registry*)' \ --eval '(setf *debugger-hook* nil uiop:*compile-file-failure-behaviour* :warn)' \ --eval '(ql:quickload :passepartout/tui)' \ --eval '(in-package :passepartout)' \ - --eval '(passepartout.channel-tui:tui-main)' + --eval '(passepartout.channel-tui:tui-main)' \ + --eval '(uiop:quit 0)' rc=$? stty icanon echo ixon 2>/dev/null exit $rc