summaryrefslogtreecommitdiff
path: root/fonts/thai/fonts-tlwg/scripts
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
committerNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
commite0c6872cf40896c7be36b11dcc744620f10adf1d (patch)
tree60335e10d2f4354b0674ec22d7b53f0f8abee672 /fonts/thai/fonts-tlwg/scripts
Initial commit
Diffstat (limited to 'fonts/thai/fonts-tlwg/scripts')
-rw-r--r--fonts/thai/fonts-tlwg/scripts/Makefile.am9
-rw-r--r--fonts/thai/fonts-tlwg/scripts/Makefile.in421
-rw-r--r--fonts/thai/fonts-tlwg/scripts/engkernpairs.txt304
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-otf.pe2
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-pfa.pe2
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-pfb.pe2
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-test-otf.pe7
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-test-pfa.pe3
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-test-pfb.pe3
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-test-ttf.pe10
-rwxr-xr-xfonts/thai/fonts-tlwg/scripts/gen-test-ttf.py22
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-ttf.pe6
-rwxr-xr-xfonts/thai/fonts-tlwg/scripts/gen-ttf.py11
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen-woff.pe2
-rw-r--r--fonts/thai/fonts-tlwg/scripts/gen.mk.am79
-rw-r--r--fonts/thai/fonts-tlwg/scripts/thaikernpairs.txt95
16 files changed, 978 insertions, 0 deletions
diff --git a/fonts/thai/fonts-tlwg/scripts/Makefile.am b/fonts/thai/fonts-tlwg/scripts/Makefile.am
new file mode 100644
index 0000000000..0d49c92d3d
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/Makefile.am
@@ -0,0 +1,9 @@
+MAINTAINERCLEANFILES = Makefile.in
+
+EXTRA_DIST = gen-ttf.pe gen-pfa.pe gen-pfb.pe gen-otf.pe gen-woff.pe \
+ gen.mk.am \
+ gen-test-ttf.pe gen-test-pfa.pe gen-test-pfb.pe gen-test-otf.pe \
+ gen-ttf.py \
+ gen-test-ttf.py \
+ engkernpairs.txt thaikernpairs.txt
+
diff --git a/fonts/thai/fonts-tlwg/scripts/Makefile.in b/fonts/thai/fonts-tlwg/scripts/Makefile.in
new file mode 100644
index 0000000000..f3ddd10164
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/Makefile.in
@@ -0,0 +1,421 @@
+# Makefile.in generated by automake 1.16.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2018 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+VPATH = @srcdir@
+am__is_gnu_make = { \
+ if test -z '$(MAKELEVEL)'; then \
+ false; \
+ elif test -n '$(MAKE_HOST)'; then \
+ true; \
+ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
+ true; \
+ else \
+ false; \
+ fi; \
+}
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+subdir = scripts
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
+mkinstalldirs = $(install_sh) -d
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+am__DIST_COMMON = $(srcdir)/Makefile.in
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AFM2TFM = @AFM2TFM@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+FCCACHE = @FCCACHE@
+FONTFORGE = @FONTFORGE@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LATEX_PACKAGE = @LATEX_PACKAGE@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+MAKEINFO = @MAKEINFO@
+MKDIR_P = @MKDIR_P@
+MKFONTDIR = @MKFONTDIR@
+MKFONTSCALE = @MKFONTSCALE@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PYTHON = @PYTHON@
+PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
+PYTHON_PLATFORM = @PYTHON_PLATFORM@
+PYTHON_PREFIX = @PYTHON_PREFIX@
+PYTHON_VERSION = @PYTHON_VERSION@
+RMDIR = @RMDIR@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+TEXHASH = @TEXHASH@
+TTMKFDIR = @TTMKFDIR@
+TYPE1INST = @TYPE1INST@
+UPDMAP = @UPDMAP@
+VERSION = @VERSION@
+VPTOVF = @VPTOVF@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+am__leading_dot = @am__leading_dot@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build_alias = @build_alias@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host_alias = @host_alias@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+otfdir = @otfdir@
+pdfdir = @pdfdir@
+pkgpyexecdir = @pkgpyexecdir@
+pkgpythondir = @pkgpythondir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+pyexecdir = @pyexecdir@
+pythondir = @pythondir@
+runstatedir = @runstatedir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+testfontdir = @testfontdir@
+texmfdir = @texmfdir@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+ttfdir = @ttfdir@
+type1dir = @type1dir@
+woffdir = @woffdir@
+MAINTAINERCLEANFILES = Makefile.in
+EXTRA_DIST = gen-ttf.pe gen-pfa.pe gen-pfb.pe gen-otf.pe gen-woff.pe \
+ gen.mk.am \
+ gen-test-ttf.pe gen-test-pfa.pe gen-test-pfb.pe gen-test-otf.pe \
+ gen-ttf.py \
+ gen-test-ttf.py \
+ engkernpairs.txt thaikernpairs.txt
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu scripts/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --gnu scripts/Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+tags TAGS:
+
+ctags CTAGS:
+
+cscope cscopelist:
+
+
+distdir: $(BUILT_SOURCES)
+ $(MAKE) $(AM_MAKEFLAGS) distdir-am
+
+distdir-am: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+ -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+clean: clean-am
+
+clean-am: clean-generic mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic cscopelist-am \
+ ctags-am distclean distclean-generic distdir dvi dvi-am html \
+ html-am info info-am install install-am install-data \
+ install-data-am install-dvi install-dvi-am install-exec \
+ install-exec-am install-html install-html-am install-info \
+ install-info-am install-man install-pdf install-pdf-am \
+ install-ps install-ps-am install-strip installcheck \
+ installcheck-am installdirs maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
+ pdf-am ps ps-am tags-am uninstall uninstall-am
+
+.PRECIOUS: Makefile
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/fonts/thai/fonts-tlwg/scripts/engkernpairs.txt b/fonts/thai/fonts-tlwg/scripts/engkernpairs.txt
new file mode 100644
index 0000000000..9e47945e48
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/engkernpairs.txt
@@ -0,0 +1,304 @@
+#This set of kernpairs is taken from Adobe Technical Note # 5091
+# Designing Multiple Master Fonts
+# Appendix E (page 69)
+#There were some typoes in the original. I've sometimes tried to guess what
+# was meant, other times just ignored it. I've probably made some typoes myself
+#PfaEdit will not produce a meaningful kerning pair with a space character.
+# and will probably fail on combinations like "r'" if the "'"'s bottom is
+# above the top of "r".
+
+#Format for this file:
+# The file may be in either Latin1 or UCS2. If in UCS2 it must begin with
+# the byte order character U+FEFF.
+# There must be exactly two characters on each line for it to be treated as
+# a kerning pair (otherwise it is treated as a comment).
+# A character may be represented either by itself or by its unicode value as
+# U+xxxx. Thus "To" could be represented as "TU+006f" or "U+0054o" or
+# "U+0054U+006F".
+
+#NOTE: Establishing a kerning pair for e does not establish a matching pair
+# for its accented varients. Each must be handled individually.
+
+AC
+AG
+AO
+AQ
+AT
+AU
+AV
+AW
+AY
+#Ap
+#Au
+Av
+Aw
+Ay
+A"
+A'
+AU+201d
+AU+2019
+#BA
+#B,
+#B.
+#CA
+#C.
+#C,
+DA
+DV
+DW
+DY
+D.
+D,
+FA
+Fa
+#Fe
+#Fi
+#Fo
+#Fr
+F.
+F,
+G.
+G,
+JA
+Ja
+Je
+Jo
+Ju
+J,
+J.
+KO
+#Ke
+#Ko
+#Ku
+Ky
+LT
+LV
+LW
+LY
+Ly
+L"
+L'
+LU+201d
+LU+2019
+NA
+N.
+N,
+OA
+#OT
+OV
+OW
+OX
+OY
+O,
+O.
+PA
+#Pa
+#Pe
+#Po
+P,
+P.
+QU
+#Q,
+Q.
+RO
+RT
+RU
+RV
+RW
+Ry
+#S,
+#S.
+TA
+#TO
+Ta
+Te
+#Th
+#Ti
+To
+Tr
+Tu
+Tw
+Ty
+#T:
+#T;
+T-
+T,
+T.
+UA
+U.
+U,
+VA
+VG
+VO
+Va
+Ve
+#Vi
+Vo
+Vu
+V:
+V;
+V-
+V,
+V.
+WA
+WO
+Wa
+We
+#Wh
+#Wi
+Wo
+Wu
+Wy
+W:
+W;
+W-
+W,
+W.
+YA
+YO
+#YS
+Ya
+Ye
+#Yi
+Yo
+Yu
+Y:
+Y;
+Y-
+Y,
+Y.
+#ab
+#ag
+#ap
+#at
+av
+aw
+ay
+#bb
+#bl
+#bu
+#bv
+#by
+#b,
+#b.
+#ch
+#ck
+#cl
+#cy
+#c,
+#c.
+#dd
+#dv
+#dw
+#dy
+#eb
+#eg
+#ep
+#ev
+#ew
+#ex
+#ey
+#e,
+#e.
+fa
+fe
+ff
+fi
+#fl
+fo
+ft
+#f"
+#f'
+#fU+201d
+#fU+2019
+f,
+f.
+#ga
+#ge
+#gg
+#gi
+#go
+#gr
+#gy
+#g,
+#g.
+#hy
+#iv
+#ke
+#ko
+#ky
+#lw
+#ly
+#mu
+#my
+#nu
+#ny
+#og
+#ov
+#ow
+#ox
+#oy
+#o,
+#o.
+#py
+#p,
+#p.
+#ra
+#rc
+#rd
+#re
+#rg
+#ri
+rk
+rl
+#rm
+#rn
+#ro
+#rp
+#rq
+#rr
+#rs
+#rt
+#ru
+#rv
+#ry
+#r:
+#r;
+r-
+r,
+r.
+#sw
+#s,
+#s.
+#va
+#ve
+#vo
+v,
+v.
+#wa
+#we
+#wh
+#wo
+w,
+w.
+#xe
+#ya
+#ye
+#yo
+y,
+y.
+#ze
+#zo
+,"
+,'
+"A
+'A
+U+201cA
+U+2018A
+#'d
+#'l
+#'r
+#'s
+#'t
+#'v
+
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-otf.pe b/fonts/thai/fonts-tlwg/scripts/gen-otf.pe
new file mode 100644
index 0000000000..5d14b2445a
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-otf.pe
@@ -0,0 +1,2 @@
+Open($1)
+Generate($1:t:r + ".otf")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-pfa.pe b/fonts/thai/fonts-tlwg/scripts/gen-pfa.pe
new file mode 100644
index 0000000000..c9080f7f99
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-pfa.pe
@@ -0,0 +1,2 @@
+Open($1)
+Generate($1:t:r + ".pfa")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-pfb.pe b/fonts/thai/fonts-tlwg/scripts/gen-pfb.pe
new file mode 100644
index 0000000000..e68c4691f3
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-pfb.pe
@@ -0,0 +1,2 @@
+Open($1)
+Generate($1:t:r + ".pfb")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-test-otf.pe b/fonts/thai/fonts-tlwg/scripts/gen-test-otf.pe
new file mode 100644
index 0000000000..deea1f5c09
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-test-otf.pe
@@ -0,0 +1,7 @@
+Open($1)
+SetFontNames("OTF"+$fontname, "OTF"+$familyname, "OTF"+$fullname)
+pref_fam=GetTTFName(0x409, 16)
+if (pref_fam != "")
+ SetTTFName(0x409, 16, "OTF"+pref_fam)
+endif
+Generate($fontname + ".otf")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-test-pfa.pe b/fonts/thai/fonts-tlwg/scripts/gen-test-pfa.pe
new file mode 100644
index 0000000000..114820bbfb
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-test-pfa.pe
@@ -0,0 +1,3 @@
+Open($1)
+SetFontNames("PS"+$fontname, "PS"+$familyname, "PS"+$fullname)
+Generate($fontname + ".pfb")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-test-pfb.pe b/fonts/thai/fonts-tlwg/scripts/gen-test-pfb.pe
new file mode 100644
index 0000000000..114820bbfb
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-test-pfb.pe
@@ -0,0 +1,3 @@
+Open($1)
+SetFontNames("PS"+$fontname, "PS"+$familyname, "PS"+$fullname)
+Generate($fontname + ".pfb")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-test-ttf.pe b/fonts/thai/fonts-tlwg/scripts/gen-test-ttf.pe
new file mode 100644
index 0000000000..8bc037ca25
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-test-ttf.pe
@@ -0,0 +1,10 @@
+Open($1)
+SetFontNames("TTF"+$fontname, "TTF"+$familyname, "TTF"+$fullname)
+pref_fam=GetTTFName(0x409, 16)
+if (pref_fam != "")
+ SetTTFName(0x409, 16, "TTF"+pref_fam)
+endif
+SetFontOrder(2)
+SelectAll()
+AutoInstr()
+Generate($fontname + ".ttf")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-test-ttf.py b/fonts/thai/fonts-tlwg/scripts/gen-test-ttf.py
new file mode 100755
index 0000000000..66f0b9b9b3
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-test-ttf.py
@@ -0,0 +1,22 @@
+#!/usr/bin/env python
+
+import sys
+import os
+import fontforge
+
+sfd_file = sys.argv[1]
+
+f = fontforge.open(sfd_file)
+
+# Prepend "TTF" prefix to font/family name
+f.fontname = "TTF" + f.fontname
+f.familyname = "TTF" + f.familyname
+f.fullname = "TTF" + f.fullname
+
+# Prepend "TTF" prefix to "Preferred Family"
+for name in f.sfnt_names:
+ if name[0] == "English (US)" and name[1] == "Preferred Family":
+ f.appendSFNTName(name[0], name[1], "TTF" + name[2])
+ break
+
+f.generate(f.fontname + ".ttf", layer="Quad")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-ttf.pe b/fonts/thai/fonts-tlwg/scripts/gen-ttf.pe
new file mode 100644
index 0000000000..94e200f9a5
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-ttf.pe
@@ -0,0 +1,6 @@
+Open($1)
+SetFontOrder(2)
+SelectAll()
+AutoInstr()
+Generate($1:t:r + ".ttf")
+
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-ttf.py b/fonts/thai/fonts-tlwg/scripts/gen-ttf.py
new file mode 100755
index 0000000000..e8fecc6a34
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-ttf.py
@@ -0,0 +1,11 @@
+#!/usr/bin/env python
+
+import sys
+import os
+import fontforge
+
+sfd_file = sys.argv[1]
+ttf_file = os.path.basename(sfd_file).replace(".sfd", ".ttf")
+
+f = fontforge.open(sfd_file)
+f.generate(ttf_file, layer="Quad")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen-woff.pe b/fonts/thai/fonts-tlwg/scripts/gen-woff.pe
new file mode 100644
index 0000000000..44cb9e15d7
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen-woff.pe
@@ -0,0 +1,2 @@
+Open($1)
+Generate($1:t:r + ".woff")
diff --git a/fonts/thai/fonts-tlwg/scripts/gen.mk.am b/fonts/thai/fonts-tlwg/scripts/gen.mk.am
new file mode 100644
index 0000000000..7f762559c0
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/gen.mk.am
@@ -0,0 +1,79 @@
+# Makefile.am common part
+#
+# Required variables from configure script:
+# - FONTFORGE
+# The path of fontforge command line
+# - INCLUDE_PFB
+# Condition whether to generate Type 1 fonts
+# - INCLUDE_TTF
+# Condition whether to generate TrueType fonts
+# - INCLUDE_OTF
+# Condition whether to generate OpenType fonts
+# - INCLUDE_TESTFONT
+# Condition whether to generate fonts for testing
+#
+# Required variables from component's Makefile
+# - FONTSOURCES : the list of *.sfd files to use as input
+#
+
+TTFFILES = $(FONTSOURCES:.sfd=.ttf)
+OTFFILES = $(FONTSOURCES:.sfd=.otf)
+AFMFILES = $(FONTSOURCES:.sfd=.afm)
+PFBFILES = $(FONTSOURCES:.sfd=.pfb)
+WOFFFILES = $(FONTSOURCES:.sfd=.woff)
+
+TESTTTFFILES = $(TTFFILES:%.ttf=TTF%.ttf)
+TESTOTFFILES = $(OTFFILES:%.otf=OTF%.otf)
+
+TESTAFMFILES = $(AFMFILES:%.afm=PS%.afm)
+TESTPFBFLES = $(PFBFILES:%.pfb=PS%.pfb)
+TESTTYPE1FILES = $(TESTPFBFILES) $(TESTAFMFILES)
+
+if INCLUDE_PFB
+TYPE1FILES = $(PFBFILES) $(AFMFILES)
+endif
+
+if INCLUDE_TTF
+ttf_DATA = $(TTFFILES)
+endif
+
+if INCLUDE_PFB
+type1_DATA = $(TYPE1FILES)
+endif
+
+if INCLUDE_OTF
+otf_DATA = $(OTFFILES)
+endif
+
+if INCLUDE_WOFF
+woff_DATA = $(WOFFFILES)
+endif
+
+if INCLUDE_TESTFONT
+testfont_DATA = $(TESTTTFFILES) $(TESTTYPE1FILES) $(TESTOTFFILES)
+endif
+
+CLEANFILES = *.ttf *.g2n *.pfb *.afm *.pfm *.otf *.woff *.enc *.tfm
+
+SUFFIXES: .sfd .ttf .otf .woff .pfb
+
+TTF%.ttf: %.sfd
+ $(top_srcdir)/scripts/gen-test-ttf.py $<
+
+OTF%.otf: %.sfd
+ $(FONTFORGE) -script $(top_srcdir)/scripts/gen-test-otf.pe $<
+
+PS%.afm PS%.pfb: %.sfd
+ $(FONTFORGE) -script $(top_srcdir)/scripts/gen-test-pfb.pe $<
+
+%.ttf: %.sfd
+ $(top_srcdir)/scripts/gen-ttf.py $<
+
+%.otf: %.sfd
+ $(FONTFORGE) -script $(top_srcdir)/scripts/gen-otf.pe $<
+
+%.woff: %.sfd
+ $(FONTFORGE) -script $(top_srcdir)/scripts/gen-woff.pe $<
+
+%.afm %.pfb: %.sfd
+ $(FONTFORGE) -script $(top_srcdir)/scripts/gen-pfb.pe $<
diff --git a/fonts/thai/fonts-tlwg/scripts/thaikernpairs.txt b/fonts/thai/fonts-tlwg/scripts/thaikernpairs.txt
new file mode 100644
index 0000000000..3ee1cc210c
--- /dev/null
+++ b/fonts/thai/fonts-tlwg/scripts/thaikernpairs.txt
@@ -0,0 +1,95 @@
+# Thai kern pairs
+# First created by Theppitak Karoonboonyanan <theppitak@gmail.com>
+
+# Note: no consonants are listed in the left side, because possible
+# intervening upper/lower marks can cancel the kerning and cause
+# inconsistent kerning over different cases.
+
+# Upper-right overshooting marks vs. Upper-left overshooting vowels
+U+f70bU+0e42
+U+f70bU+0e43
+U+f70bU+0e44
+U+f70cU+0e42
+U+f70cU+0e43
+U+f70cU+0e44
+U+f70eU+0e42
+U+f70eU+0e43
+U+f70eU+0e44
+U+0e4eU+0e42
+U+0e4eU+0e43
+U+0e4eU+0e44
+
+# Lower-right overshooting vowels vs. Lower-left overshooting consonants
+U+0e40U+0e0e
+U+0e40U+0e0f
+U+0e40U+0e20
+U+0e41U+0e0e
+U+0e41U+0e0f
+U+0e41U+0e20
+U+0e42U+0e0e
+U+0e42U+0e0f
+U+0e42U+0e20
+U+0e43U+0e0e
+U+0e43U+0e0f
+U+0e43U+0e20
+U+0e44U+0e0e
+U+0e44U+0e0f
+U+0e44U+0e20
+
+# Lower-right overshooting vowels vs. Lower-left spacing consonants
+U+0e40U+0e07
+U+0e40U+0e08
+U+0e40U+0e10
+U+0e40U+0e11
+U+0e40U+0e23
+U+0e40U+0e27
+U+0e41U+0e07
+U+0e41U+0e08
+U+0e41U+0e10
+U+0e41U+0e11
+U+0e41U+0e23
+U+0e41U+0e27
+U+0e42U+0e07
+U+0e42U+0e08
+U+0e42U+0e10
+U+0e42U+0e11
+U+0e42U+0e23
+U+0e42U+0e27
+U+0e43U+0e08
+U+0e44U+0e07
+U+0e44U+0e08
+U+0e44U+0e10
+U+0e44U+0e11
+U+0e44U+0e23
+U+0e44U+0e27
+
+# Lower-right overshooting vowels vs. Lower-left narrow spacing consonants
+U+0e40U+0e09
+U+0e40U+0e17
+U+0e40U+0e19
+U+0e40U+0e1e
+U+0e40U+0e1f
+U+0e40U+0e2b
+U+0e40U+0e2c
+U+0e41U+0e09
+U+0e41U+0e17
+U+0e41U+0e19
+U+0e41U+0e1e
+U+0e41U+0e1f
+U+0e41U+0e2b
+U+0e41U+0e2c
+U+0e42U+0e09
+U+0e42U+0e17
+U+0e42U+0e19
+U+0e42U+0e1e
+U+0e42U+0e1f
+U+0e42U+0e2b
+U+0e42U+0e2c
+U+0e43U+0e19
+U+0e44U+0e09
+U+0e44U+0e17
+U+0e44U+0e19
+U+0e44U+0e1e
+U+0e44U+0e1f
+U+0e44U+0e2b
+U+0e44U+0e2c