mirror of https://codeberg.org/cage/tinmop/
- improved formatting of text in window that shows the parent of a message.
This commit is contained in:
parent
5d69437bc4
commit
c16e88ad99
|
@ -3497,13 +3497,21 @@ gemini client certificates!)."
|
||||||
(new-window-width (truncate (* (windows:win-width *main-window*) 2/3)))
|
(new-window-width (truncate (* (windows:win-width *main-window*) 2/3)))
|
||||||
(status-id (actual-author-message-id selected-row))
|
(status-id (actual-author-message-id selected-row))
|
||||||
(parent-row (db:get-parent-status-row status-id))
|
(parent-row (db:get-parent-status-row status-id))
|
||||||
(words (split-words (db:row-message-rendered-text parent-row)))
|
(lines (split-lines (db:row-message-rendered-text parent-row)))
|
||||||
(lines (flush-left-mono-text words new-window-width))
|
|
||||||
(bg (swconf:win-bg swconf:+key-help-dialog+))
|
(bg (swconf:win-bg swconf:+key-help-dialog+))
|
||||||
(fg (swconf:win-fg swconf:+key-help-dialog+)))
|
(fg (swconf:win-fg swconf:+key-help-dialog+)))
|
||||||
(windows:make-blocking-message-dialog *main-window*
|
(let ((actual-lines '()))
|
||||||
nil
|
(loop for line in lines do
|
||||||
(_ "Parent message")
|
(if (< (length line)
|
||||||
lines
|
new-window-width)
|
||||||
bg
|
(push line actual-lines)
|
||||||
fg)))
|
(let* ((words (split-words line))
|
||||||
|
(formatted-lines (flush-left-mono-text words new-window-width)))
|
||||||
|
(loop for formatted-line in formatted-lines do
|
||||||
|
(push formatted-line actual-lines)))))
|
||||||
|
(windows:make-blocking-message-dialog *main-window*
|
||||||
|
nil
|
||||||
|
(_ "Parent message")
|
||||||
|
(nreverse actual-lines)
|
||||||
|
bg
|
||||||
|
fg))))
|
||||||
|
|
Loading…
Reference in New Issue