summaryrefslogtreecommitdiff
path: root/makeglyphs
diff options
context:
space:
mode:
authorJames Bursa <james@netsurf-browser.org>2005-02-08 23:25:59 +0000
committerJames Bursa <james@netsurf-browser.org>2005-02-08 23:25:59 +0000
commit3b86ee8e511f8811189a381e4d1f8864e49f1e5f (patch)
tree61d32a5471e4f1613c06bd70ca654c6013d26502 /makeglyphs
parentc4580a33f78825e385626610fbbff9a675b248a4 (diff)
downloadlibrufl-3b86ee8e511f8811189a381e4d1f8864e49f1e5f.tar.gz
librufl-3b86ee8e511f8811189a381e4d1f8864e49f1e5f.tar.bz2
[project @ 2005-02-08 23:25:59 by bursa]
Support for non-Unicode Font Manager. svn path=/import/rufl/; revision=2444
Diffstat (limited to 'makeglyphs')
-rwxr-xr-xmakeglyphs21
1 files changed, 21 insertions, 0 deletions
diff --git a/makeglyphs b/makeglyphs
new file mode 100755
index 0000000..4cca836
--- /dev/null
+++ b/makeglyphs
@@ -0,0 +1,21 @@
+#!/usr/bin/perl -W
+
+%glyph = ();
+
+print "#include <stdlib.h>\n";
+print "#include \"rufl_internal.h\"\n";
+print "const struct rufl_glyph_map_entry rufl_glyph_map[] = {\n";
+
+while (<>) {
+ if (/^([0-9A-F]{4});([a-zA-Z0-9]+);/) {
+ $glyph{$2} = $1;
+ }
+}
+
+foreach $z (sort keys %glyph) {
+ print "\t{\"$z\", 0x$glyph{$z}},\n";
+}
+
+print "};\n";
+print "const size_t rufl_glyph_map_size = sizeof rufl_glyph_map /\n";
+print " sizeof rufl_glyph_map[0];\n";