sbbs.el

Diff
Login

Differences From Artifact [676c904eb1]:

To Artifact [4c1b0d2eeb]:


522
523
524
525
526
527
528
529

530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
        (newline))
      (setq header-line-format (format "Responding to Thread %d" id)
            sbbs--thread-id id
            sbbs--board board)
      (switch-to-buffer (current-buffer)))))

(defun sbbs-compose-format (style)
  "Insert "

  (if (region-active-p)
      (save-excursion
        (goto-char (region-beginning))
        (insert "style")
        (goto-char (region-end))
        (insert "style"))
    (insert style style)
    (forward-char (- (length style)))))

(defun sbbs-compose-format-code ()
  "Insert code syntax markers."
  (interactive)
  (sbbs-compose-format "```\n"))

(defun sbbs-compose-format-bold ()







|
>
|
|
|
|
|
|
|
|







522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
        (newline))
      (setq header-line-format (format "Responding to Thread %d" id)
            sbbs--thread-id id
            sbbs--board board)
      (switch-to-buffer (current-buffer)))))

(defun sbbs-compose-format (style)
  "Insert string STYLE around region or point."
  (save-mark-and-excursion
    (if (region-active-p)
        (progn
          (goto-char (region-beginning))
          (insert style)
          (goto-char (region-end))
          (insert style))
      (insert style style)))
  (forward-char (length style)))

(defun sbbs-compose-format-code ()
  "Insert code syntax markers."
  (interactive)
  (sbbs-compose-format "```\n"))

(defun sbbs-compose-format-bold ()