vscode 配置Maple Mono 中英文等宽字体

作者:matrix 被围观: 274 次 发布时间:2025-03-19 分类:零零星星 | 无评论 »

https://font.subf.dev/zh-cn/

vscode的默认字体如果中英文混合的话会发现不等宽,也就是垂直方向无法完整对其。Maple Mono开源字体,正好可以完美显示。

环境:macos

安装

font-maple-mono-nf-cn 会包含nf图标以及中文字体。可以按需选择想要的字体集

$ brew install --cask font-maple-mono-nf-cn  

vscode配置

字体设置前面添加 Maple Mono NF CN,系统会优先匹配该字体。

不太喜欢符号(==,===,!=...)连写,可以配置连写规则来关闭:

~/Library/Application Support/Code/User/settings.json:

...
"editor.fontFamily": "Maple Mono NF CN, Menlo, Monaco, 'Courier New', monospace",
 "editor.fontLigatures": "'calt', 'ss04', 'ss01', 'ss02'",
...

editor.fontLigatures 配置连写规则

显示效果

[TODO],[FIXME]这些关键字连写特性可以触发高亮加粗,nf字体图标也可以显示。不错不错 就先这样了

参考:

https://github.com/subframe7536/maple-font/blob/variable/source/features/README.md#ligatures

其他nf字体图标: https://www.nerdfonts.com/cheat-sheet

其他文章:
本文固定链接:https://www.hhtjim.com/vscode-%e9%85%8d%e7%bd%aemaple-mono-%e4%b8%ad%e8%8b%b1%e6%96%87%e7%ad%89%e5%ae%bd%e5%ad%97%e4%bd%93.html
matrix
本文章由 matrix 于2025年03月19日发布在零零星星分类下,目前没有通告,你可以至底部留下评论。
转载请注明:vscode 配置Maple Mono 中英文等宽字体-HHTjim'S 部落格
关键字:,

添加新评论 »

 🙈 😱 😂 😛 😭 😳 😀 😆 👿 😉 😯 😮 😕 😎 😐 😥 😡 😈 💡

插入图片

NOTICE: You should type some Chinese word (like “你好”) in your comment to pass the spam-check, thanks for your patience!