Emacs 中完美的像素映射字体

Mat*_*iak 8 emacs fonts x11

在 Ubuntu 中,在 IntelliJ 中,字体 PragmataPro Mono 如下所示:

在此处输入图片说明

注意完美映射的像素。IntelliJ 设置Appearance & Behavior > Appearance > Antialiasing > Editor设置为No antialiasing.

在 Emacs 中,相同的字体是抗锯齿的:

在此处输入图片说明

如果我添加一个~/.Xresources包含的文件Emacs.font: PragmataPro Mono-12:antialias=false,那么 Emacs 看起来像这样:

在此处输入图片说明

字体会自动位图,但不是根据字体的规范。

如何在 Emacs 中复制 IntelliJ 的渲染?

我已经在 Ubuntu–Cinnamon 和 Arch–Xfce 上重现了这个问题。谢谢你。

cev*_*ing 2

如果您对渲染的抗锯齿版本的问题是外观太厚,您可以强制使用特定的字体提示。我在我的文件中以这种方式为 Lucida Console 字体执行此操作~/.Xresources

Emacs.font: Lucida Console-14:antialias=true:hinting=true:autohint=false:hintstyle=3
Run Code Online (Sandbox Code Playgroud)

可用的提示样式有:

hintnone        hintstyle       0
hintslight      hintstyle       1
hintmedium      hintstyle       2
hintfull        hintstyle       3
Run Code Online (Sandbox Code Playgroud)