Skip to content

Instantly share code, notes, and snippets.

@ian-h-chamberlain
Created May 15, 2024 19:43
Show Gist options
  • Save ian-h-chamberlain/1e8efad269779256e125fabfc385a2ad to your computer and use it in GitHub Desktop.
Save ian-h-chamberlain/1e8efad269779256e125fabfc385a2ad to your computer and use it in GitHub Desktop.
fontforge remove `less_equal.alt` lookup
#!/usr/bin/env fontforge
import sys
import fontforge
def main():
for font_name in sys.argv[1:]:
font = fontforge.open(font_name)
# I never want any substitutions to result in <= (less_equal.alt) so just
# remove all lookup-subtables that lead to this glyph.
font["less_equal.alt"].removePosSub("*")
font.generate(font_name)
if __name__ == "__main__":
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment