]> gitweb.michael.orlitzky.com - charm-bypass.git/blob - sfd2woff.ff
COPYING: add to state the "or later" bit
[charm-bypass.git] / sfd2woff.ff
1 #!/usr/bin/env fontforge
2 #
3 # FontForge script that converts its first argument (a font file) to
4 # woff2, saving the results to its second argument (a path). See,
5 #
6 # https://fontforge.org/docs/tutorial/scripting-tutorial.html
7 #
8 # and the additional documentation for Generate() at
9 #
10 # https://fontforge.org/docs/scripting/scripting-alpha.html#Generate
11 #
12 # Specifically:
13 #
14 # fmflags&4 => generate a short "post" table with no glyph name info
15 # in it
16 #
17 # fmflags&8 => do not include ttf instructions
18 #
19 # fmflags&0x8000 => do not generate an FFTM table
20 #
21 # fmflags&0x40000 => do not do flex hints
22 #
23 # fmflags&0x80000 => do not include postscript hints
24 #
25 # And, according to python,
26 #
27 # >>> 0x4 + 0x8 + 0x8000 + 0x40000 + 0x80000
28 # 819212
29 #
30 Open($1);
31 Generate($2,"",819212);