From 9e16518644121cac1f8447ba97e01b24f2293adb Mon Sep 17 00:00:00 2001 From: Cytrogen Date: Wed, 11 Mar 2026 19:15:46 -0400 Subject: [PATCH] =?UTF-8?q?feat(ui):=20=E6=B7=BB=E5=8A=A0=E5=AD=97?= =?UTF-8?q?=E4=BD=93=E7=B2=BE=E7=BB=86=E6=8E=A7=E5=88=B6=E5=92=8C=E8=A7=86?= =?UTF-8?q?=E8=A7=89=E5=A2=9E=E5=BC=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 中英文字体分离: 代码用 JetBrains Mono + 思源黑体, 写作用 Source Serif 4 + 思源宋体,标题用 Open Sans + Noto Sans SC - Org-mode 代码块/表格强制等宽,正文变宽衬线 - 添加 Default-text-scale 全局字号缩放(C-M-=/C-M--) - 添加 Page-break-lines(^L 显示为分隔线) - 添加 Dimmer 非活动窗口变暗(30%) - 添加 Info-colors 文档彩色化 --- config/ui-theme-fonts.el | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/config/ui-theme-fonts.el b/config/ui-theme-fonts.el index 5f10d93540e2d5c9e0eb4347ce3b8b82fe0b612e..99540d9ecceb5acf3a96bb2bc6a97bb7b632ddec 100644 --- a/config/ui-theme-fonts.el +++ b/config/ui-theme-fonts.el @@ -1,6 +1,9 @@ ;;; ui-theme-fonts.el --- User interface, themes, and font configuration -*- lexical-binding: t -*- -;; Copyright (C) 2024 Cytrogen +;; Copyright (C) 2026 Cytrogen + +;; Many package selections and configurations adapted from +;; Steve Purcell's emacs.d: https://github.com/purcell/emacs.d ;; This file contains: ;; - Font configuration with CJK support @@ -259,5 +262,32 @@ Refactored to strictly separate Fixed Pitch (Code) and Variable Pitch (Writing) frame (my/setup-blog-fonts)))) (my/setup-blog-fonts)) +;; Default-text-scale — C-M-= / C-M-- 全局字体缩放 +(unless (package-installed-p 'default-text-scale) + (package-install 'default-text-scale)) +(require 'default-text-scale) +(default-text-scale-mode 1) + +;; Page-break-lines — ^L 显示为水平分隔线 +(unless (package-installed-p 'page-break-lines) + (package-install 'page-break-lines)) +(require 'page-break-lines) +(global-page-break-lines-mode 1) + +;; Dimmer — 非活动窗口变暗 +(unless (package-installed-p 'dimmer) + (package-refresh-contents) + (package-install 'dimmer)) +(require 'dimmer) +(setq dimmer-fraction 0.3) +(dimmer-configure-which-key) +(dimmer-configure-magit) +(dimmer-mode 1) + +;; Info-colors — Info 文档彩色化 +(unless (package-installed-p 'info-colors) + (package-install 'info-colors)) +(add-hook 'Info-selection-hook 'info-colors-fontify-node) + (provide 'ui-theme-fonts) ;;; ui-theme-fonts.el ends here \ No newline at end of file