Overview
Comment: | Use Shift-JIS font for text if installed |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | master | trunk |
Files: | files | file ages | folders |
SHA3-256: |
5ffdf5dd20d7a3255e1b218f14abbfe8 |
User & Date: | zge on 2020-06-05 21:38:45 |
Other Links: | branch diff | manifest | tags |
Context
2020-06-06
| ||
16:06 | Only generate "other" board when link matches regexp Fixes [ed8a04be6b] check-in: ae851a4d20 user: zge tags: master, trunk | |
2020-06-05
| ||
21:38 | Use Shift-JIS font for text if installed check-in: 5ffdf5dd20 user: zge tags: master, trunk | |
20:45 | Fixed non-ASCII encoding issues check-in: 17bd3b2661 user: zge tags: master, trunk | |
Changes
Modified sbbs.el from [cec4081882] to [47b32ff1b0].
63 63 "Face for spoiler text in threads.") 64 64 65 65 (defface sbbs--code-face 66 66 '((((background light)) :background "gray89" :extend t) 67 67 (((background dark)) :background "gray11" :extend t)) 68 68 "Face for code blocks in threads.") 69 69 70 +(defface sbbs--variable-pitch 71 + (if (x-list-fonts "Mona-") 72 + '((nil :font "Mona" 73 + :inherit variable-pitch)) 74 + '((nil :inherit variable-pitch))) 75 + "Face for code blocks in threads.") 76 + 70 77 ;; VARIABLES 71 78 72 79 (defvar-local sbbs--board nil 73 80 "Buffer local reference to current board. 74 81 75 82 See `sbbs-make-board'.") 76 83 ................................................................................ 259 266 (sbbs-view-open id range))) 260 267 ;; other thread 261 268 ((/= id sbbs--thread-id) 262 269 (let ((sbbs--board board)) 263 270 (sbbs-view-open id range))) 264 271 ;; this thread 265 272 (range (sbbs--limit-to-range range)))))) 266 - (insert-button (propertize text 'face 'variable-pitch) 273 + (insert-button (propertize text 'face 'sbbs--variable-pitch) 267 274 'action func 'sbbs-ref range))))) 268 275 269 276 (defun sbbs--insert-sxml-par (sxml) 270 277 "Insert paragraph contents SXML at point." 271 278 (dolist (it sxml) 272 279 (cond ((stringp it) 273 - (insert (propertize it 'face 'variable-pitch))) 280 + (insert (propertize it 'face 'sbbs--variable-pitch))) 274 281 ((eq (car it) 'br) 275 282 (newline)) 276 283 ((eq (car it) 'b) 277 - (insert (propertize (cadr it) 'face '(bold variable-pitch)))) 284 + (insert (propertize (cadr it) 'face '(bold sbbs--variable-pitch)))) 278 285 ((eq (car it) 'i) 279 - (insert (propertize (cadr it) 'face '(italic variable-pitch)))) 286 + (insert (propertize (cadr it) 'face '(italic sbbs--variable-pitch)))) 280 287 ((eq (car it) 'code) 281 288 (insert (propertize (cadr it) 'face 'fixed-pitch))) 282 289 ((eq (car it) 'del) 283 290 (insert (propertize (cadr it) 'face 'sbbs--spoiler-face))) 284 291 ((eq (car it) 'a) 285 292 (let* ((text (caddr it)) 286 293 (link (plist-get (cadadr it) 'href))) ................................................................................ 384 391 (push (list (car thread) 385 392 (vector (substring (cdr (assq 'date (cdr thread))) 386 393 0 16) 387 394 (number-to-string 388 395 (cdr (assq 'messages (cdr thread)))) 389 396 (propertize 390 397 (cdr (assq 'headline (cdr thread))) 391 - 'face 'variable-pitch))) 398 + 'face 'sbbs--variable-pitch))) 392 399 ent)) 393 400 (setq-local tabulated-list-entries ent) 394 401 (tabulated-list-print t t) 395 402 (hl-line-highlight)))))) 396 403 397 404 (defun sbbs--thread-loader (status id buf range) 398 405 "Callback function for `url-retrieve' when loading thread.