v0.7.0: char-width + status bar fix — TDD (RED→GREEN)
char-width: contract 5, 4 tests (6 assertions), 100% pass ASCII=1, CJK/Hangul/Kana/halfwidth=2, combining marks=0, tab=8 Pure Lisp, ~25 lines, no deps. Used by word-wrap for unicode. status bar: contract 6, timestamp right-aligned at (- w 12) Fixes overlap where focus map and timestamp both drew at :y 2 :x 1
This commit is contained in:
@@ -112,8 +112,6 @@ See *tui-theme-presets* for named presets (dark, light, solarized, gruvbox).")
|
||||
:input-buffer nil :input-history nil :input-hpos 0
|
||||
:messages (make-array 16 :adjustable t :fill-pointer 0)
|
||||
:scroll-offset 0 :busy nil :cursor-pos 0
|
||||
:pending-ctrl-x nil :scroll-at-bottom t
|
||||
:scroll-notify nil)
|
||||
:dirty (list nil nil nil))))
|
||||
|
||||
(defun now ()
|
||||
@@ -145,9 +143,6 @@ See *tui-theme-presets* for named presets (dark, light, solarized, gruvbox).")
|
||||
|
||||
(defun add-msg (role content &key gate-trace)
|
||||
(vector-push-extend (list :role role :content content :time (now) :gate-trace gate-trace) (st :messages))
|
||||
;; v0.7.0: if scrolled up, set notification flag
|
||||
(unless (st :scroll-at-bottom)
|
||||
(setf (st :scroll-notify) t))
|
||||
(setf (st :dirty) (list t t nil)))
|
||||
|
||||
(defun queue-event (ev)
|
||||
|
||||
Reference in New Issue
Block a user