mirror of
https://codeberg.org/cage/tinmop/
synced 2025-03-11 11:10:43 +01:00
- fixed line wrapping of announcements window.
This commit is contained in:
parent
ceaeeb8ec6
commit
c1d4024185
@ -1895,14 +1895,21 @@
|
||||
"Shows a window with all announcements"
|
||||
(when-let* ((all-announcements (api-client:get-announcements))
|
||||
(all-texts (mapcar (lambda (a)
|
||||
(html-utils:html->text a
|
||||
:quote-prefix (swconf:message-window-quote-prefix)
|
||||
:list-item-prefix (swconf:message-window-bullet-prefix)))
|
||||
(text-utils:justify-monospaced-text (html-utils:html->text a
|
||||
:quote-prefix
|
||||
(swconf:message-window-quote-prefix)
|
||||
:list-item-prefix
|
||||
(swconf:message-window-bullet-prefix))
|
||||
(truncate (* 3/4
|
||||
(windows:win-width specials:*main-window*)))))
|
||||
(mapcar #'tooter:content all-announcements)))
|
||||
(lines (reduce #'append
|
||||
(mapcar #'text-utils:split-lines all-texts)))
|
||||
(window-content (text-utils:join-with-strings* (swconf:config-announcements-separator)
|
||||
lines)))
|
||||
(lines (mapcar (lambda (a)
|
||||
(append a
|
||||
(list ""
|
||||
(swconf:config-announcements-separator)
|
||||
"")))
|
||||
all-texts))
|
||||
(window-content (flatten lines)))
|
||||
(api-client:dismiss-all-announcements all-announcements)
|
||||
(line-oriented-window:make-blocking-list-dialog-window specials:*main-window*
|
||||
window-content
|
||||
|
Loading…
x
Reference in New Issue
Block a user