furnace/res/make-iconfont.sh
tildearrow 44973de675 compress fonts using zlib
- smaller
- better
- ugly big-endian workaround no longer necessary
2024-04-07 16:08:38 -05:00

5 lines
316 B
Bash
Executable file

#!/bin/bash
# run after exporting to .ttf
echo "#include \"fonts.h\"" > ../src/gui/font_furicon.cpp
cat icons.ttf | zlib-flate -compress=9 | xxd -i -n "furIcons_compressed_data" | sed -r "s/^ +//g;s/, /,/g;s/ = /=/g;s/unsigned/const unsigned/g;s/compressed_data_len/compressed_size/" >> ../src/gui/font_furicon.cpp