Hacker News new | ask | show | jobs
by craftkiller 1 day ago
I agree, but FWIW it is pretty easy to disable ligatures system-wide with font config. Just drop this into ~/.config/fontconfig/conf.d/99-disable-ligatures.conf:

  <?xml version="1.0"?>
  <!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd">
  <fontconfig>
    <description>Disable ligatures</description>
    <match target="font">
      <edit name="fontfeatures" mode="append">
        <string>liga off</string>
        <string>dlig off</string>
        <string>rlig off</string>
      </edit>
    </match>
  </fontconfig>
(this naturally assumes you're using Linux. I have no idea what the closed source world uses for configuring fonts.)
1 comments

Won't that disable the real ligatures in non-monospaced fonts?
Yeah, you can change the block to filter to specific fonts or font families if you want. For example, in my configs I only apply that setting to the Cascadia Code font by doing:

  <match target="font">
    <test name="family" compare="eq" ignore-blanks="true">
      <string>Cascadia Code</string>
    </test>
    <edit name="fontfeatures" mode="append">
      <string>liga off</string>
      <string>dlig off</string>
      <string>rlig off</string>
    </edit>
  </match>