From 836a72fbf6ae23b6abd5a9833bd83c960497b4c0 Mon Sep 17 00:00:00 2001 From: bth Date: Tue, 9 Jun 2026 12:38:02 -0700 Subject: [PATCH] minmo : minmo-use-ascii call tty-type once on load --- packages/minmo.el | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/packages/minmo.el b/packages/minmo.el index 9216d28..79bdf35 100644 --- a/packages/minmo.el +++ b/packages/minmo.el @@ -63,13 +63,17 @@ and their respective faces.") (defcustom minmo-use-ascii nil - "whether to use ascii symbols instead of unicode" - :type '(boolean)) + "Whether to use ascii symbols instead of unicode. Defaults to ascii if +`tty-type' is not an xterm derivative." + :type '(boolean) + :set (lambda (sym val) + (if (not (string-prefix-p "xterm" (tty-type))) + (set sym t) + (set sym val)))) (defun minmo--status-string-face (status fstype) (let* ( - (encoding (if (or minmo-use-ascii (not (string-prefix-p "xterm" (tty-type)))) - 'ascii 'unicode)) + (encoding (if minmo-use-ascii 'ascii 'unicode)) (row (cdr (assoc status minmo-status-alist))) (str (cdr (assoc encoding (car row)))) (face (cdr (assoc fstype (cdr row))))