Improved filling.
authorTim Vaughan <plugd@thelambdalab.xyz>
Wed, 30 Jun 2021 15:34:46 +0000 (17:34 +0200)
committerTim Vaughan <plugd@thelambdalab.xyz>
Wed, 30 Jun 2021 15:34:46 +0000 (17:34 +0200)
lurk.el

diff --git a/lurk.el b/lurk.el
index c5ba515..697c937 100644 (file)
--- a/lurk.el
+++ b/lurk.el
@@ -333,14 +333,15 @@ portion of the source component of the message, as LURK doesn't use this.")
       (goto-char lurk-prompt-marker)
       (let ((inhibit-read-only t)
             (old-pos (marker-position lurk-prompt-marker))
       (goto-char lurk-prompt-marker)
       (let ((inhibit-read-only t)
             (old-pos (marker-position lurk-prompt-marker))
-            (adaptive-fill-regexp (rx (= 6 anychar))))
+            (adaptive-fill-regexp (rx (= 6 anychar)))
+            (fill-column 80))
         (insert-before-markers
          (propertize (concat (format-time-string "%H:%M") " ")
                      'face 'lurk-text
                      'read-only t)
          (propertize (concat (apply #'concat strings) "\n")
                      'read-only t))
         (insert-before-markers
          (propertize (concat (format-time-string "%H:%M") " ")
                      'face 'lurk-text
                      'read-only t)
          (propertize (concat (apply #'concat strings) "\n")
                      'read-only t))
-        (fill-region old-pos lurk-prompt-marker)))))
+        (fill-region old-pos lurk-prompt-marker nil t)))))
 
 (defun lurk-render-prompt ()
   (with-current-buffer "*lurk*"
 
 (defun lurk-render-prompt ()
   (with-current-buffer "*lurk*"
@@ -447,6 +448,7 @@ portion of the source component of the message, as LURK doesn't use this.")
 (defun lurk-eval-msg-string (string)
   ;; (lurk-display-string string)
   (let* ((msg (lurk-string->msg string)))
 (defun lurk-eval-msg-string (string)
   ;; (lurk-display-string string)
   (let* ((msg (lurk-string->msg string)))
+    ;; (message (pp msg))
     (pcase (lurk-msg-cmd msg)
       ("PING"
        (lurk-send-msg
     (pcase (lurk-msg-cmd msg)
       ("PING"
        (lurk-send-msg