How to disable ligatures in WezTerm?
2023-08-01
Categories: Development Environment
As you may know, I switched to WezTerm and Helix a few months ago.
What surprised me is when I type !=
in Helix, it is rendered as ≠
.
This behaviour also occurs with other character combinations, for example:
<=
becomes rendered as≤
->
becomes rendered as→
===
becomes rendered as≡
My first guess was that Helix had something to do with the font rendering but I encountered the same issue when typing directly into terminal.
After some research, I found a relevant link which introduced me to the concept of “ligatures”.
It turns out that WezTerm uses JetBrains Mono as the default font, and this font comes with ligatures enabled. I do not like this feature because I want everything I type to be rendered exactly as it appears on my screen.
To disable ligatures, add the following line to the ~/.wezterm.lua
:
1config.harfbuzz_features = { 'calt=0' }
Related Posts:
- Turning Helix into an IDE with the help of WezTerm and CLI tools
- Debug Rust in Helix using lldb-vscode: display the contents of local string variables
- How to debug Rust in Helix?
- WezTerm: quickly select a command and open it in a new pane
- File tree workaround for Helix