与默认 emacs 分开改变 Emacs 迷你缓冲区的字体大小?

发布于 2024-12-11 15:27:22 字数 644 浏览 1 评论 0原文

我一直在尝试将 emacs 迷你缓冲区的字体/外观与 emacs 默认字体分开,但运气不佳。

具体来说,我有兴趣使迷你缓冲区字体大小更大,以便与 emacs MULE 一起使用,因为使用我当前的字体设置,或者如果我在“上网本”屏幕上使用 emacs,有时 MULE 中的字符选择选项是有点小。

在 emacs 中可以轻松访问的选项是 minibuffer-prompt 和 minibuffer-prompt。 minibuffer-prompt-properties,但这些仅适用于命令提示符,而不是常规的迷你缓冲区文本。

emacs 中似乎列出了许多迷你缓冲区变量,用于创建迷你缓冲区帧,或从迷你缓冲区窗口获取内容等。但这些与更改迷你缓冲区面无关。是否有可能与默认的 emacs 分开改变迷你缓冲区面?

一个有趣的选择是 oneonone emacs http://www.emacswiki.org/emacs/OneOnOneEmacs 项目。但是专用的迷你缓冲区帧可以改变吗?另外,在我彻底改变当前的 emacs 设置之前,我希望能够先改变字体或创建我自己的可改变的迷你缓冲区框架等......

任何帮助和/或创意想法将不胜感激。

I've been attempting to alter the font / face for the emacs minibuffer separately from emacs default fonts, but without much luck.

Specifically, I'm interested in making the minibuffer font size larger for use with the emacs MULE as, with my current font setting or if I'm using emacs on a "netbook" screen, sometimes the character selection options in the MULE are a bit small.

Options easily accessed within emacs are the minibuffer-prompt & minibuffer-prompt-properties, but these are only for command prompts and not the regular minibuffer text.

There seem to be a number of minibuffer variables listed in emacs for creating minibuffer frames, or getting contents from minibuffer windows, etc.. but these do not pertain to altering the minibuffer face. Is it even possible to alter the minibuffer face separately from the default emacs?

An interesting option is the oneonone emacs http://www.emacswiki.org/emacs/OneOnOneEmacs project. But could the dedicated minibuffer frame be altered? Also before I alter my current emacs set-up that drastically, I'd hope to be able to just alter fonts first or create my own alterable minibuffer frame, etc...

Any help and/or creative ideas would be greatly appreciated.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

生死何惧 2024-12-18 15:27:22

您可以通过 minibuffer-setup-hook 向迷你缓冲区添加自定义。在那里,您可以像这样进行一些面部重新映射

(add-hook 'minibuffer-setup-hook 'my-minibuffer-setup)
(defun my-minibuffer-setup ()
       (set (make-local-variable 'face-remapping-alist)
          '((default :height 2.0))))

根据需要更改 my-minibuffer-setup 的主体。上面的内容将默认面的高度加倍。

You can add customization to the minibuffer through the minibuffer-setup-hook. In there, you can do some face remapping like so:

(add-hook 'minibuffer-setup-hook 'my-minibuffer-setup)
(defun my-minibuffer-setup ()
       (set (make-local-variable 'face-remapping-alist)
          '((default :height 2.0))))

Change the body of the my-minibuffer-setup as desired. The above doubles the height of the default face.

樱花细雨 2024-12-18 15:27:22

是的,您可以轻松自定义独立迷你缓冲区框架的属性,包括其默认外观和字体。

您可以自定义 OneOnOneEmacs 用户选项1on1-minibuffer-frame-alistminibuffer-frame-alist - 它的帧参数值由 1on1-minibuffer-frame-alist 使用作为默认值。)

(或者您可以自定义标准选项 >font 框架参数是控制字体的参数(废话)。因此,您可以自定义选项1on1-minibuffer-frame-alist,更改其字体设置。

或者,您可以将 1on1-minibuffer-frame-font 设置为您想要的字体 - 它被 1on1-minibuffer-frame-alist< 用作字体设置的默认值/code> 每当 minibuffer-frame-alist 中没有明确的font 设置时。例如:

    (setq 1on1-minibuffer-frame-font
          "-*-Lucida Console-normal-r-*-*-14-112-96-96-c-*-iso8859-1")

如果您不想使用独立的迷你缓冲区帧,请参阅 Trey 的答案。

Yes, you can easily customize the properties of a standalone minibuffer frame, including its default face and font.

You can customize the OneOnOneEmacs user option 1on1-minibuffer-frame-alist. (Or you can customize the standard option minibuffer-frame-alist -- its frame parameter values are used as defaults by 1on1-minibuffer-frame-alist.)

The font frame parameter is the one that controls the font (duh). So you would customize option 1on1-minibuffer-frame-alist, changing its setting for the font.

Alternatively, you can just set 1on1-minibuffer-frame-font to the font you want -- it is used as the default value for the font setting by 1on1-minibuffer-frame-alist whenever there is no explicit font setting in minibuffer-frame-alist. For example:

    (setq 1on1-minibuffer-frame-font
          "-*-Lucida Console-normal-r-*-*-14-112-96-96-c-*-iso8859-1")

If you do not want to use a standalone minibuffer frame then see Trey's answer.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文