summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAkira Kakuto <kakuto@fuk.kindai.ac.jp>2018-11-30 01:09:56 +0000
committerAkira Kakuto <kakuto@fuk.kindai.ac.jp>2018-11-30 01:09:56 +0000
commite2012ff38bc208db38b47955974acfb658dafa9e (patch)
tree442c6ab6fc137e3650ae5a969910c6f0d19aa0ea
parentbfc1ab8d60cc7919762bc4d066355b1928690a76 (diff)
harfbuzz-2.2.0
git-svn-id: svn://tug.org/texlive/trunk@49277 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Build/source/libs/README2
-rw-r--r--Build/source/libs/harfbuzz/ChangeLog5
-rw-r--r--Build/source/libs/harfbuzz/TLpatches/ChangeLog5
-rw-r--r--Build/source/libs/harfbuzz/TLpatches/TL-Changes2
-rwxr-xr-xBuild/source/libs/harfbuzz/configure26
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/ChangeLog2439
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/NEWS35
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/README13
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/configure.ac3
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.am2
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.sources2
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/gen-emoji-table.py13
-rwxr-xr-xBuild/source/libs/harfbuzz/harfbuzz-src/src/gen-use-table.py7
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-common.hh72
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-feat-table.hh114
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-kerx-table.hh72
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-lcar-table.hh6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-morx-table.hh28
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-trak-table.hh1
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.cc227
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.h462
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.hh6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.cc4
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.hh8
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat.h38
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-atomic.hh2
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-blob.hh4
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-buffer.h2
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-common.cc14
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-debug.hh16
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-deprecated.h37
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-dsalgs.hh145
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-face.cc6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ft.cc14
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-glib.cc6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-icu.cc9
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-machinery.hh94
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-null.hh53
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-file.hh7
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-type.hh193
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-cmap-table.hh49
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-colr-table.hh16
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-svg-table.hh3
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-face.hh1
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-font.cc6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-glyf-table.hh8
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-kern-table.hh11
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-common.hh48
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gdef-table.hh27
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gpos-table.hh3
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsub-table.hh8
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsubgpos.hh5
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.cc69
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.hh3
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-map.hh4
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-math-table.hh10
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-post-table.hh6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-myanmar.cc21
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use-table.cc2
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use.cc48
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex.hh28
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.cc45
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.hh3
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var-fvar-table.hh179
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.cc76
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.h89
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-vorg-table.hh9
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-set.hh20
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shape.cc6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shaper.cc6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-static.cc10
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ucdn.cc6
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-unicode-emoji-table.hh189
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-uniscribe.cc4
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb-vector.hh95
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/hb.hh18
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/test-name-table.cc2
-rw-r--r--Build/source/libs/harfbuzz/harfbuzz-src/src/test-ot-color.cc14
-rw-r--r--Build/source/libs/harfbuzz/include/Makefile.am2
-rw-r--r--Build/source/libs/harfbuzz/include/Makefile.in3
-rw-r--r--Build/source/libs/harfbuzz/version.ac2
81 files changed, 4492 insertions, 856 deletions
diff --git a/Build/source/libs/README b/Build/source/libs/README
index 49178e4318a..05148b7c291 100644
--- a/Build/source/libs/README
+++ b/Build/source/libs/README
@@ -25,7 +25,7 @@ graphite2 1.3.12 - checked 16aug18
http://sourceforge.net/projects/silgraphite/files/graphite2/
(requires C++11)
-harfbuzz 2.1.3 - checked 19nov18
+harfbuzz 2.2.0 - checked 30nov18
http://www.freedesktop.org/software/harfbuzz/release/
icu 61.1 - checked 29mar18
diff --git a/Build/source/libs/harfbuzz/ChangeLog b/Build/source/libs/harfbuzz/ChangeLog
index 2a50efd0d6b..879151eddd5 100644
--- a/Build/source/libs/harfbuzz/ChangeLog
+++ b/Build/source/libs/harfbuzz/ChangeLog
@@ -1,3 +1,8 @@
+2018-11-30 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
+
+ Import harfbuzz-2.2.0.
+ * version.ac, include/Makefile.am: Adjusted.
+
2018-11-19 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
Import harfbuzz-2.1.3.
diff --git a/Build/source/libs/harfbuzz/TLpatches/ChangeLog b/Build/source/libs/harfbuzz/TLpatches/ChangeLog
index 32daa09b5ef..04eafb87164 100644
--- a/Build/source/libs/harfbuzz/TLpatches/ChangeLog
+++ b/Build/source/libs/harfbuzz/TLpatches/ChangeLog
@@ -1,3 +1,8 @@
+2018-11-30 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
+
+ Imported harfbuzz-2.2.0 source tree from:
+ http://www.freedesktop.org/software/harfbuzz/release/
+
2018-11-19 Akira Kakuto <kakuto@fuk.kindai.ac.jp>
Imported harfbuzz-2.1.3 source tree from:
diff --git a/Build/source/libs/harfbuzz/TLpatches/TL-Changes b/Build/source/libs/harfbuzz/TLpatches/TL-Changes
index 9d300f73c4a..ce348915506 100644
--- a/Build/source/libs/harfbuzz/TLpatches/TL-Changes
+++ b/Build/source/libs/harfbuzz/TLpatches/TL-Changes
@@ -1,4 +1,4 @@
-Changes applied to the harfbuzz-2.1.3/ tree as obtained from:
+Changes applied to the harfbuzz-2.2.0/ tree as obtained from:
http://www.freedesktop.org/software/harfbuzz/release/
Removed:
diff --git a/Build/source/libs/harfbuzz/configure b/Build/source/libs/harfbuzz/configure
index b15ef10f543..8b4f98cc176 100755
--- a/Build/source/libs/harfbuzz/configure
+++ b/Build/source/libs/harfbuzz/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for harfbuzz (TeX Live) 2.1.3.
+# Generated by GNU Autoconf 2.69 for harfbuzz (TeX Live) 2.2.0.
#
# Report bugs to <tex-k@tug.org>.
#
@@ -580,8 +580,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='harfbuzz (TeX Live)'
PACKAGE_TARNAME='harfbuzz--tex-live-'
-PACKAGE_VERSION='2.1.3'
-PACKAGE_STRING='harfbuzz (TeX Live) 2.1.3'
+PACKAGE_VERSION='2.2.0'
+PACKAGE_STRING='harfbuzz (TeX Live) 2.2.0'
PACKAGE_BUGREPORT='tex-k@tug.org'
PACKAGE_URL=''
@@ -1317,7 +1317,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures harfbuzz (TeX Live) 2.1.3 to adapt to many kinds of systems.
+\`configure' configures harfbuzz (TeX Live) 2.2.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1388,7 +1388,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of harfbuzz (TeX Live) 2.1.3:";;
+ short | recursive ) echo "Configuration of harfbuzz (TeX Live) 2.2.0:";;
esac
cat <<\_ACEOF
@@ -1495,7 +1495,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-harfbuzz (TeX Live) configure 2.1.3
+harfbuzz (TeX Live) configure 2.2.0
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2131,7 +2131,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by harfbuzz (TeX Live) $as_me 2.1.3, which was
+It was created by harfbuzz (TeX Live) $as_me 2.2.0, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@@ -4054,7 +4054,7 @@ fi
# Define the identity of the package.
PACKAGE='harfbuzz--tex-live-'
- VERSION='2.1.3'
+ VERSION='2.2.0'
# Some tools Automake needs.
@@ -4247,9 +4247,9 @@ WARNING_CFLAGS=$kpse_cv_warning_cflags
HB_VERSION_MAJOR=2
-HB_VERSION_MINOR=1
-HB_VERSION_MICRO=3
-HB_VERSION=2.1.3
+HB_VERSION_MINOR=2
+HB_VERSION_MICRO=0
+HB_VERSION=2.2.0
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
@@ -8143,7 +8143,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by harfbuzz (TeX Live) $as_me 2.1.3, which was
+This file was extended by harfbuzz (TeX Live) $as_me 2.2.0, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -8209,7 +8209,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-harfbuzz (TeX Live) config.status 2.1.3
+harfbuzz (TeX Live) config.status 2.2.0
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/ChangeLog b/Build/source/libs/harfbuzz/harfbuzz-src/ChangeLog
index a09a7a60e56..e6e9cd1ea96 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/ChangeLog
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/ChangeLog
@@ -1,3 +1,2442 @@
+commit 7b85081be4fbd6cad75dc28ae933ce920f71b22d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 29 11:34:22 2018 -0500
+
+ [icu] Minor
+
+ src/hb-icu.cc | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 0bcb1de1265368a27e53c6d935c965cbcb4130a0
+Merge: e0307de8 a85886fc
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 29 10:39:18 2018 -0500
+
+ Merge pull request #1418 from gvictor/replace_icu_deprecated
+
+ Replace @Deprecated ICU API - USCRIPT_CODE_LIMIT
+
+commit e0307de818ad1f70ef96938642bda61d7a62532a
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 29 11:36:05 2018 +0330
+
+ [test][aat.kern] More (#1427)
+
+ test/shaping/data/in-house/tests/macos.tests | 12 ++++++++----
+ 1 file changed, 8 insertions(+), 4 deletions(-)
+
+commit 949655aa7853a4513af6b5247b9822be38f5d322
+Merge: 7b78d223 d3d0f15f
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 28 17:21:57 2018 -0500
+
+ Merge pull request #1425 from mbutterick/patch-1
+
+ update simple shaping example (closes #298)
+
+commit d3d0f15f7d20bedf7018fb2fb652f92ff4159bd7
+Author: Matthew Butterick <mbutterick@users.noreply.github.com>
+Date: Wed Nov 28 13:46:12 2018 -0800
+
+ update simple shaping example (closes #298)
+
+ add call to `FT_Set_Char_Size`, otherwise default size remains at
+ `0`, and glyph positions come back as `0` too
+
+ docs/usermanual-getting-started.xml | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+commit 7b78d2233df0e51e2967bc54a9202b3f9e05059a
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 29 00:55:05 2018 +0330
+
+ [test][aat] Update expectency
+
+ It is not visually noticeable but apparently affected by kern format2
+ correct implementation.
+ I should've checked CoreText result which can't as CircleCI outage.
+
+ test/shaping/data/in-house/tests/macos.tests | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 5155067e10011f78f1ce35b3dadb062bccd3a706
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 29 00:07:00 2018 +0330
+
+ [test] Add test for format2 kern (#1423)
+
+ test/shaping/data/in-house/Makefile.sources | 1 +
+ .../fonts/e39391c77a6321c2ac7a2d644de0396470cd4bfe.ttf | Bin 0 ->
+ 34116 bytes
+ test/shaping/data/in-house/tests/kern-format2.tests | 3 +++
+ 3 files changed, 4 insertions(+)
+
+commit 42a2b496e428521151ff5cb07454d2e993f892cc
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 28 15:24:30 2018 -0500
+
+ [kerx] Fix Format2 index calc again
+
+ src/hb-aat-layout-common.hh | 14 ++++++++++++++
+ src/hb-aat-layout-kerx-table.hh | 2 +-
+ 2 files changed, 15 insertions(+), 1 deletion(-)
+
+commit 9e4f03b6ed80a81f8aee5ba93564f5eabab4299c
+Merge: 19863c80 a3267cf8
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 28 15:08:01 2018 -0500
+
+ Merge remote-tracking branch 'fdo/master'
+
+commit a3267cf803082af157a7f2b0026af2633b14f8e3
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 28 15:06:01 2018 -0500
+
+ [kern] Fix kern table Format2 offsetToIndex
+
+ Fixes https://github.com/harfbuzz/harfbuzz/issues/1421
+
+ src/hb-aat-layout-kerx-table.hh | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+commit f9a9c0fd1e561715d696c7bd840bab552d0718ee
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 28 14:51:56 2018 -0500
+
+ [kerx] Fix ClassTable implementation for 'kern' table Format 2
+
+ src/hb-aat-layout-common.hh | 8 +++++---
+ src/hb-aat-layout-kerx-table.hh | 10 ++--------
+ 2 files changed, 7 insertions(+), 11 deletions(-)
+
+commit 5b4a789ca857664668ff69936574dcd09bee6065
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 28 14:46:26 2018 -0500
+
+ [aat] Towards adding two ClassTable's
+
+ src/hb-aat-layout-common.hh | 40 ++++++++++++++++++++--------------------
+ 1 file changed, 20 insertions(+), 20 deletions(-)
+
+commit 19863c805982d5d1d059d4dd9376039d3fdaabcd
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Wed Nov 28 20:28:42 2018 +0330
+
+ [test][aat] Add a test and make macOS runners faster (#1422)
+
+ .circleci/config.yml | 15 +++-----
+ test/shaping/data/in-house/tests/macos.tests | 54
+ ++++++++++++++--------------
+ 2 files changed, 33 insertions(+), 36 deletions(-)
+
+commit 987f4187722a05e3f360b85c66309a351fc5d6ad
+Merge: 1042d9fb 4e2a03b6
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 27 17:40:32 2018 -0500
+
+ Merge pull request #1398 from Adenilson/bigInt01
+
+ Optimize harfbuzz big integer conversions
+
+commit 4e2a03b6b6e0c0d1c4edea10dc1aae63eeb6c581
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 27 17:40:09 2018 -0500
+
+ Comment
+
+ src/hb-machinery.hh | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+commit 4a719a7f4c997ea7e47588bc0288c97706dae015
+Author: Adenilson Cavalcanti <adenilson.cavalcanti@arm.com>
+Date: Tue Nov 20 14:41:19 2018 -0800
+
+ Optimize harfbuzz big integer conversions
+
+ Profiling showed that type conversions were adding considerable
+ cycles in time
+ spent doing text shaping.
+
+ The idea is to optimize it using native processor instructions to
+ help Blink
+ layout performance.
+
+ Doing further investigation revelead that compilers may not use the
+ proper instruction on ARM 32bits builds (i.e. REV16).
+
+ One way to insure that the generated ASM was ideal for both gcc/clang
+ was using __builtin_bswap16.
+
+ Added bonus is that we no longer need to test for CPU architecture.
+
+ src/hb-machinery.hh | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+commit a85886fc77083084e9a12ee15b47eab7876f9f53
+Author: Victor Chang <vichang@google.com>
+Date: Tue Nov 27 11:34:56 2018 +0000
+
+ Replace @Deprecated ICU API - USCRIPT_CODE_LIMIT
+
+ Use of the deprecated API USCRIPT_CODE_LIMIT prevents harfbuzz
+ using the ICU4C as a shared library.
+
+ The API has been replaced by u_getIntPropertyMaxValue(UCHAR_SCRIPT)
+
+ src/hb-icu.cc | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+commit 1042d9fbc05aff9d51f15c2824a8521e963d0acd
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Mon Nov 26 18:58:39 2018 +0330
+
+ [ci] Add .codecov.yml
+
+ Similar to
+ https://github.com/GoogleChrome/lighthouse/blob/master/.codecov.yml
+
+ No strong preference on commenting, feel free to enable it again
+
+ .codecov.yml | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+commit 97eaedca5de76c74534bab41562aee130098558a
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Mon Nov 26 16:58:58 2018 +0330
+
+ [test][aat] Enable Tamil MN test (#1414)
+
+ test/shaping/data/in-house/tests/macos.tests | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+commit 574d888c8a409295a952361a39c8e83a52a0fc3d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 16:51:22 2018 -0500
+
+ [aat] Ignore GSUB table of Muthu Foundry if they have morx table
+
+ Fixes https://github.com/harfbuzz/harfbuzz/issues/1410
+
+ src/hb-ot-layout-gpos-table.hh | 3 +++
+ src/hb-ot-layout-gsub-table.hh | 3 +++
+ src/hb-ot-layout-gsubgpos.hh | 5 +++++
+ src/hb-ot-layout.cc | 36 +++++++++++++++++++++++++++++++++++-
+ 4 files changed, 46 insertions(+), 1 deletion(-)
+
+commit 4151c2848d8df75b6d0a4f5d79bee843158aa4a4
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 16:38:36 2018 -0500
+
+ [GDEF] Move more code
+
+ src/hb-ot-layout-gdef-table.hh | 10 +++++++++-
+ src/hb-ot-layout.cc | 11 -----------
+ 2 files changed, 9 insertions(+), 12 deletions(-)
+
+commit 4f21703f225b6977196ef180e8d7300ea86d2cc3
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 15:59:18 2018 -0500
+
+ [GDEF] Move code around
+
+ src/hb-ot-layout-gdef-table.hh | 3 +++
+ src/hb-ot-layout.cc | 16 +++++++---------
+ 2 files changed, 10 insertions(+), 9 deletions(-)
+
+commit 4ed9fb1a0050f3151f9332f08c8bb2c13652c607
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 15:51:01 2018 -0500
+
+ [GDEF] Minor
+
+ src/hb-ot-layout.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 0e3a48e54248d69197e8fb23c824d987f91b3bf7
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sun Nov 25 13:37:23 2018 +0330
+
+ [test][aat] fix 10.13.6 Helvetica expectation
+
+ test/shaping/data/in-house/tests/macos.tests | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit cbc541b426f01717641f1f3529a7c9703aec7a28
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sun Nov 25 12:50:30 2018 +0330
+
+ [aat] Add m grave test (#1412)
+
+ test/shaping/data/in-house/tests/macos.tests | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+commit fa26ad0f48462063f2160a43cb62b018bb21e251
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sun Nov 25 11:25:17 2018 +0330
+
+ [aat] Fix macos expectation
+
+ test/shaping/data/in-house/tests/macos.tests | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 926f512f354835f8323bb2c2e58789dd918a9b65
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 01:14:40 2018 -0500
+
+ [aat.feat] Rework API and implementation
+
+ Fixes https://github.com/harfbuzz/harfbuzz/pull/1346
+
+ docs/harfbuzz-docs.xml | 5 +++
+ docs/harfbuzz-sections.txt | 7 ++--
+ src/hb-aat-layout-feat-table.hh | 89
+ +++++++++++++++++++++++------------------
+ src/hb-aat-layout.cc | 80 ++++++++++++++++--------------------
+ src/hb-aat-layout.h | 32 +++++++++------
+ test/api/test-aat-layout.c | 58 ++++++++++++++-------------
+ 6 files changed, 141 insertions(+), 130 deletions(-)
+
+commit 84dacbca7ea54a3ca2d5d711d50272a7f3baf456
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 12:08:36 2018 -0500
+
+ [aat.feat] Add _MAX_VALUE to enums
+
+ src/hb-aat-layout.h | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+commit 3922aae1620958768d3257c0988432d5609dca1b
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 11:02:04 2018 -0500
+
+ [aat.feat] Minor
+
+ src/hb-aat-layout-feat-table.hh | 12 ++----------
+ 1 file changed, 2 insertions(+), 10 deletions(-)
+
+commit 0f8e98eca2463da3b83d1b66a19259a584df1682
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 11:00:42 2018 -0500
+
+ [aat.feat] Whitespace
+
+ src/hb-aat-layout-feat-table.hh | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+commit c2256068339c9e10c8e6df5d1749be4b4eb04ad4
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 10:54:40 2018 -0500
+
+ [aat.feat] Port to SortedUnsizedArrayOf.bsearch()
+
+ src/hb-aat-layout-feat-table.hh | 19 +++++++------------
+ 1 file changed, 7 insertions(+), 12 deletions(-)
+
+commit 52ae9867efd6520d17306b9f3ad612fe5463e93d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 10:46:56 2018 -0500
+
+ [AAT.feat] Use lsearch for looking up SettingName's
+
+ They are not sorted.
+
+ src/hb-aat-layout-feat-table.hh | 18 ++++++------------
+ src/hb-open-type.hh | 16 ++++++++--------
+ src/hb-static.cc | 6 ++++--
+ 3 files changed, 18 insertions(+), 22 deletions(-)
+
+commit 44b9331f663c09174d94e06baf36d48a50599c42
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 10:30:35 2018 -0500
+
+ [aat] Fix include issues
+
+ src/Makefile.am | 2 ++
+ src/hb-aat.h | 2 ++
+ 2 files changed, 4 insertions(+)
+
+commit b206133d1f616339a57996b634dadc7f0a2c4cfb
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 14:05:11 2018 -0500
+
+ [aat] Move contents of hb-aat.h to hb-aat-layout.h
+
+ Since it was pages and pages...
+
+ src/Makefile.sources | 1 +
+ src/hb-aat-layout.cc | 1 -
+ src/hb-aat-layout.h | 452
+ +++++++++++++++++++++++++++++++++++++++++++++++++++
+ src/hb-aat-layout.hh | 1 -
+ src/hb-aat-map.hh | 1 -
+ src/hb-aat.h | 417
+ +----------------------------------------------
+ src/hb.hh | 2 +
+ 7 files changed, 458 insertions(+), 417 deletions(-)
+
+commit 2cb235d0210e74ea4ee123767b489301a9c340ab
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 12:23:35 2018 -0500
+
+ [aat.feat] Fix enum namespace
+
+ src/hb-aat-layout-feat-table.hh | 2 +-
+ src/hb-aat-layout-morx-table.hh | 4 +-
+ src/hb-aat-layout.cc | 150 ++++++------
+ src/hb-aat.h | 502
+ ++++++++++++++++++++--------------------
+ test/api/test-aat-layout.c | 2 +-
+ 5 files changed, 330 insertions(+), 330 deletions(-)
+
+commit 712762cabbbe85e6ab8361cd115c22a176827734
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 12:21:02 2018 -0500
+
+ Minor
+
+ src/hb-aat.h | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+commit e20f81f4fa977a8d22c6afee1e46fbf46bc182d9
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 11:57:42 2018 -0500
+
+ [aat] Rename feat API a bit more
+
+ docs/harfbuzz-sections.txt | 10 +++++-----
+ src/hb-aat-layout-feat-table.hh | 8 ++++----
+ src/hb-aat-layout.cc | 32 ++++++++++++++++----------------
+ src/hb-aat.h | 26 +++++++++++++-------------
+ test/api/test-aat-layout.c | 28 ++++++++++++++--------------
+ 5 files changed, 52 insertions(+), 52 deletions(-)
+
+commit 54f4c17f0a932b0ca0317e1ad5e5e43a11a83fd1
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Fri Nov 23 12:05:06 2018 +0330
+
+ [feat] Rename API uses of setting to selector
+
+ docs/harfbuzz-sections.txt | 6 +--
+ src/hb-aat-layout-feat-table.hh | 52 ++++++++++++------------
+ src/hb-aat-layout-morx-table.hh | 2 +-
+ src/hb-aat-layout.cc | 88
+ ++++++++++++++++++++---------------------
+ src/hb-aat-layout.hh | 4 +-
+ src/hb-aat-map.cc | 2 +-
+ src/hb-aat-map.hh | 2 +-
+ src/hb-aat.h | 20 +++++-----
+ test/api/test-aat-layout.c | 46 ++++++++++-----------
+ 9 files changed, 111 insertions(+), 111 deletions(-)
+
+commit 9c64b216ec7ae2c2c124ebd00dc6fa568752be78
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Fri Nov 23 11:44:53 2018 +0330
+
+ [feat] Apply renamings and add documentation
+
+ docs/harfbuzz-sections.txt | 10 ++++++++++
+ src/hb-aat-layout.cc | 44
+ ++++++++++++++++++++++++++++++++++++++------
+ src/hb-aat.h | 6 +++---
+ test/api/test-aat-layout.c | 28 ++++++++++++++--------------
+ 4 files changed, 65 insertions(+), 23 deletions(-)
+
+commit a8726cb4830f51a820db4bc6346ed09c91493817
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sat Nov 17 14:23:11 2018 +0330
+
+ [feat] Use bsearch
+
+ src/hb-aat-layout-feat-table.hh | 36 ++++++++++++++++++++++--------------
+ src/hb-aat-layout-morx-table.hh | 2 +-
+ src/hb.hh | 2 ++
+ 3 files changed, 25 insertions(+), 15 deletions(-)
+
+commit 4009a05ca7de21fff2176621597cd0cd01e9d80e
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sat Nov 17 11:30:50 2018 +0330
+
+ [feat] Address Behdad comments
+
+ src/hb-aat-layout-feat-table.hh | 114 ++++---
+ src/hb-aat-layout.cc | 14 +-
+ src/hb-aat.h | 673
+ +++++++++++++++++-----------------------
+ test/api/test-aat-layout.c | 88 +++---
+ 4 files changed, 423 insertions(+), 466 deletions(-)
+
+commit 19b6025534a98df96d67eee45c5c1ea6fbc1cc43
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sat Nov 17 01:07:09 2018 +0330
+
+ [feat] Address @behdad comments
+
+ src/Makefile.sources | 2 +-
+ src/hb-aat-layout-feat-table.hh | 82 +++----
+ src/hb-aat-layout-morx-table.hh | 2 +-
+ src/hb-aat-layout.cc | 104 ++++----
+ src/hb-aat-map.cc | 2 +-
+ src/hb-aat.h | 533
+ ++++++++++++----------------------------
+ src/hb-ot.h | 1 -
+ test/api/test-aat-layout.c | 84 +++----
+ 8 files changed, 282 insertions(+), 528 deletions(-)
+
+commit 9212ec203c948e290a1d92b701619ccdbc89377c
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Fri Nov 9 00:50:10 2018 +0330
+
+ [feat] Complete feature types list
+
+ src/hb-aat-layout-morx-table.hh | 2 +-
+ src/hb-aat-layout.cc | 154 ++++-----
+ src/hb-aat.h | 697
+ ++++++++++++++++++++++++++++++++++++++--
+ 3 files changed, 752 insertions(+), 101 deletions(-)
+
+commit fbad794bd2c574363a0c5c5fefabce764496f93c
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 1 22:24:42 2018 +0330
+
+ [feat] Add feature iteration API
+
+ src/hb-aat-layout-feat-table.hh | 36 +++++++++++++++++++++--------
+ src/hb-aat-layout.cc | 26 +++++++++++----------
+ src/hb-aat.h | 23 +++++++++++++++++--
+ test/api/test-aat-layout.c | 51
+ +++++++++++++++++++++++++++--------------
+ 4 files changed, 96 insertions(+), 40 deletions(-)
+
+commit 7a0471aa356bcd062d31a59bdb19c335249116c7
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 1 21:38:54 2018 +0330
+
+ [feat] Turn AAT feature id into enum
+
+ src/hb-aat-layout-feat-table.hh | 20 ++---
+ src/hb-aat-layout-morx-table.hh | 10 +--
+ src/hb-aat-layout.cc | 170
+ ++++++++++++++++++++--------------------
+ src/hb-aat-layout.hh | 6 +-
+ src/hb-aat-map.cc | 2 +-
+ src/hb-aat-map.hh | 4 +-
+ src/hb-aat.h | 64 +++++++++------
+ test/api/test-aat-layout.c | 8 +-
+ test/api/test-c.c | 1 +
+ 9 files changed, 150 insertions(+), 135 deletions(-)
+
+commit b233fa4bc9cdb1c6677b37106d96d878d6e03bfd
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 1 20:02:57 2018 +0330
+
+ [feat] Rename records to selectors as @drott
+
+ src/hb-aat-layout-feat-table.hh | 20 ++++++++++----------
+ src/hb-aat-layout.cc | 10 +++++-----
+ src/hb-aat.h | 4 ++--
+ 3 files changed, 17 insertions(+), 17 deletions(-)
+
+commit a157b3e4ebd57ad29f217c4cef6519e7398cfa5c
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 1 19:56:16 2018 +0330
+
+ [feat] Apply @behdad comments
+
+ src/Makefile.sources | 2 +-
+ src/hb-aat-layout-feat-table.hh | 1 +
+ src/hb-aat-layout.cc | 16 ++++++++--------
+ src/hb-aat-layout.hh | 2 +-
+ src/hb-aat-map.hh | 2 +-
+ src/{hb-aat-layout.h => hb-aat.h} | 22 +++++++++++++---------
+ src/hb-ot.h | 1 +
+ test/api/test-aat-layout.c | 14 +++++++-------
+ test/api/test-c.c | 1 -
+ 9 files changed, 33 insertions(+), 28 deletions(-)
+
+commit 3aff3f822f0d7bf7a2b5160ad93df3fe413c7c47
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 1 19:20:20 2018 +0330
+
+ [feat] Apply @drott and @jfkthame comments
+
+ src/hb-aat-layout-feat-table.hh | 14 ++++++--------
+ src/hb-aat-layout.cc | 12 +++++++-----
+ src/hb-aat-layout.h | 10 +++++-----
+ test/api/test-aat-layout.c | 4 ++--
+ 4 files changed, 20 insertions(+), 20 deletions(-)
+
+commit b791bbbae47aa19709da640a1dc5e84590c5c2c2
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 1 15:15:56 2018 +0330
+
+ [feat] Apply @jfkthame reviews
+
+ src/hb-aat-layout-feat-table.hh | 27 +++++++++++++++------------
+ src/hb-aat-layout.cc | 23 ++++++++++++-----------
+ src/hb-aat-layout.h | 14 +++++++++-----
+ test/api/fonts/aat-feat.ttf | Bin 0 -> 1132 bytes
+ test/api/test-aat-layout.c | 30 ++++++++++++++++++------------
+ 5 files changed, 54 insertions(+), 40 deletions(-)
+
+commit 95abd53758e281325b9124f0942aafb382a89090
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Thu Nov 1 13:14:29 2018 +0330
+
+ [feat] Expose public API
+
+ * hb_aat_get_feature_settings
+
+ src/Makefile.sources | 1 +
+ src/hb-aat-layout-feat-table.hh | 68 ++++++++++++++++++++++++++++++-
+ src/hb-aat-layout-morx-table.hh | 6 +--
+ src/hb-aat-layout.cc | 33 +++++++++++++++
+ src/hb-aat-layout.h | 75 ++++++++++++++++++++++++++++++++++
+ src/hb-aat-layout.hh | 7 ++--
+ src/hb-aat-map.hh | 5 ++-
+ src/hb-ot-face.hh | 1 +
+ test/api/Makefile.am | 1 +
+ test/api/test-aat-layout.c | 89
+ +++++++++++++++++++++++++++++++++++++++++
+ test/api/test-c.c | 1 +
+ 11 files changed, 278 insertions(+), 9 deletions(-)
+
+commit 264c4a539cbfd8d5e5f143206d9d27230a186897
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 00:30:08 2018 -0500
+
+ [test] Reorder test suites
+
+ aots is less interesting. Run text-rendering-tests before aots.
+
+ test/shaping/data/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 9326912941e5927bcfb4689689c954b9a3995baa
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 00:27:23 2018 -0500
+
+ [kerx] Fix crash
+
+ src/hb-machinery.hh | 2 ++
+ 1 file changed, 2 insertions(+)
+
+commit 6ee401049d475b2a2d9c859e6dbf8ff2750a1609
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sun Nov 25 00:21:13 2018 -0500
+
+ Simplify sanitize set_object() / fix bots
+
+ src/hb-machinery.hh | 26 +++++++++++++-------------
+ 1 file changed, 13 insertions(+), 13 deletions(-)
+
+commit c5a6b355e165e90d8d90454ceeca7b100282945f
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 23:49:23 2018 -0500
+
+ [kerx] Port to hb_sanitize_with_object_t
+
+ src/hb-aat-layout-kerx-table.hh | 19 +++++++------------
+ 1 file changed, 7 insertions(+), 12 deletions(-)
+
+commit c405ed0509afaa7c3846e8e461bedfbceb0cd937
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 23:46:15 2018 -0500
+
+ [morx] Port to hb_sanitize_with_object_t
+
+ src/hb-aat-layout-morx-table.hh | 18 +++++++++---------
+ 1 file changed, 9 insertions(+), 9 deletions(-)
+
+commit 1e8994221fb5cfdb1902d5249c7a75cde6d6e3c8
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 23:38:06 2018 -0500
+
+ Add hb_sanitize_with_object_t
+
+ Context manager.
+
+ src/hb-machinery.hh | 17 +++++++++++++++++
+ 1 file changed, 17 insertions(+)
+
+commit b3c5affc05a3c7bbcfbd98521703d3d3447fcd7d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 23:34:34 2018 -0500
+
+ Simplify sanitize set_object()
+
+ src/hb-aat-layout-kerx-table.hh | 12 ++++++------
+ src/hb-aat-layout-morx-table.hh | 10 +++++-----
+ src/hb-machinery.hh | 26 +++++++++++++-------------
+ 3 files changed, 24 insertions(+), 24 deletions(-)
+
+commit 3d3097269995aa227b4b198d4da2baf942b65c66
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 23:12:28 2018 -0500
+
+ [aat] Skip terminator in VarSizedBinSearchArray<>
+
+ Fixes shaping with Apple Chancery on 10.13 again. In that font,
+ there was a terminator segment, that was tripping off sanitize().
+
+ src/hb-aat-layout-common.hh | 6 ++++++
+ src/hb-open-type.hh | 21 ++++++++++++++++++++-
+ 2 files changed, 26 insertions(+), 1 deletion(-)
+
+commit 4202a3cde3b6065124feb7f4c662563de1e08126
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 22:48:34 2018 -0500
+
+ Minor
+
+ src/hb-open-type.hh | 21 ++++++++++++++++-----
+ 1 file changed, 16 insertions(+), 5 deletions(-)
+
+commit 1c2302bbf1d2d0e66f49ab54ad98d1b61bc5603d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 22:32:17 2018 -0500
+
+ [debug] Print function in return_trace()
+
+ src/hb-debug.hh | 16 +++++++++++-----
+ 1 file changed, 11 insertions(+), 5 deletions(-)
+
+commit 748198a6718adbb200ee24ac013c617f62c946a4
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 22:16:59 2018 -0500
+
+ Revert "[aat.morx] Remove set_object() business"
+
+ This reverts commit ae8ed58a6e53441d9ccbf67afd8a00b815cde99e.
+
+ Apparently this broke Apple Chancery from OS X 10.12 :(.
+ Investigating...
+
+ src/hb-aat-layout-morx-table.hh | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+commit c8a2dc820eb0ee3124e3762cb1167ac9e528ad28
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 22:16:53 2018 -0500
+
+ Revert "[aat.kerx] Remove kerx subtable boundary enforcement"
+
+ This reverts commit 15905a2a2998f7ddd964f920a4828602235d6b00.
+
+ src/hb-aat-layout-kerx-table.hh | 21 +++++++++++++++++++++
+ 1 file changed, 21 insertions(+)
+
+commit 9eeebd8ddedb96c03860ce7eb5500aafa3969d6b
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 22:16:47 2018 -0500
+
+ Revert "[sanitize] Remove now-unused set_object() machinery"
+
+ This reverts commit bbdb6edb3e1cea4c5b7076c4f6b3e6998ae36dae.
+
+ src/hb-machinery.hh | 25 ++++++++++++++++++++++++-
+ 1 file changed, 24 insertions(+), 1 deletion(-)
+
+commit 248ce22857c8918bf3468ef48d906de4c19c3d4d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 22:01:06 2018 -0500
+
+ [tests] Minor
+
+ test/shaping/run-tests.py | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit f47c5da0aa04a88b37d9c3af4730204319a9a36b
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 21:36:57 2018 -0500
+
+ [arrays] Use hb_array_t<> in all places with sub_array()
+
+ src/hb-aat-layout-lcar-table.hh | 6 +++---
+ src/hb-ot-layout-gdef-table.hh | 14 ++++++++------
+ src/hb-ot-math-table.hh | 10 ++++------
+ 3 files changed, 15 insertions(+), 15 deletions(-)
+
+commit 3246a8ebbd900bcc3e3c70532eab0f406b8f5c4a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 21:32:00 2018 -0500
+
+ [arrays] Merge ArrayOf's sub_array into hb_array_t's
+
+ src/hb-dsalgs.hh | 44 +++++++++++++++++++++++++++-----------------
+ src/hb-open-type.hh | 30 ++++++++++++++++++------------
+ 2 files changed, 45 insertions(+), 29 deletions(-)
+
+commit e6877e28cd30e89af7cce59d903184a5a01ec970
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sun Nov 25 02:12:40 2018 +0330
+
+ [test] Add the missed aots fonts
+
+ test/shaping/data/aots/fonts/classdef1_font1.otf | Bin 0 -> 6004 bytes
+ test/shaping/data/aots/fonts/classdef1_font2.otf | Bin 0 -> 6020 bytes
+ test/shaping/data/aots/tests/classdef1_empty.tests | 2 +-
+ 3 files changed, 1 insertion(+), 1 deletion(-)
+
+commit 825ea5a4607fafa11c56a72a82bda773f6b44e79
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sun Nov 25 01:59:54 2018 +0330
+
+ [test] Merge 10.12.6 and 10.13.6 tests, update to Apple Chancery fix
+
+ test/shaping/data/in-house/Makefile.sources | 3 +--
+ .../data/in-house/tests/macos-10.12.6.tests | 11 ---------
+ .../data/in-house/tests/macos-10.13.6.tests | 13 -----------
+ test/shaping/data/in-house/tests/macos.tests | 26
+ ++++++++++++++++++++++
+ 4 files changed, 27 insertions(+), 26 deletions(-)
+
+commit bbdb6edb3e1cea4c5b7076c4f6b3e6998ae36dae
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 17:15:38 2018 -0500
+
+ [sanitize] Remove now-unused set_object() machinery
+
+ src/hb-machinery.hh | 25 +------------------------
+ 1 file changed, 1 insertion(+), 24 deletions(-)
+
+commit 15905a2a2998f7ddd964f920a4828602235d6b00
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 17:14:39 2018 -0500
+
+ [aat.kerx] Remove kerx subtable boundary enforcement
+
+ Have not encountered fonts needing this, but same reasoning as
+ for morx (see previos commit.)
+
+ src/hb-aat-layout-kerx-table.hh | 21 ---------------------
+ 1 file changed, 21 deletions(-)
+
+commit ae8ed58a6e53441d9ccbf67afd8a00b815cde99e
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 17:11:09 2018 -0500
+
+ [aat.morx] Remove set_object() business
+
+ With OS X 10.13 Apple Chancery fails to ligate if we limit each morx
+ sub-chain to its declared length. Perhaps their newer compiler does
+ object-sharing across sub-chains. Anyway, since that's a valid, if
+ unspecified, way to compile tables, remove enforcement.
+
+ Probably do the same with kern/kerx.
+
+ src/hb-aat-layout-morx-table.hh | 8 --------
+ 1 file changed, 8 deletions(-)
+
+commit b518e5af9f66414396752069bb8f43466a9236fa
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sun Nov 25 01:39:00 2018 +0330
+
+ Add 10.13.6 aat fonts tests and bot (#1409)
+
+ .circleci/config.yml | 16
+ ++++++++++++++--
+ test/shaping/data/in-house/Makefile.sources | 3 ++-
+ .../in-house/tests/{macos.tests => macos-10.12.6.tests} | 2 --
+ test/shaping/data/in-house/tests/macos-10.13.6.tests | 13
+ +++++++++++++
+ 4 files changed, 29 insertions(+), 5 deletions(-)
+
+commit b7f7950e8fc4b9e229b466ac2453d57b8da9a5a6
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 15:56:17 2018 -0500
+
+ [aat] Add test for recent regression
+
+ test/shaping/data/in-house/tests/macos.tests | 1 +
+ 1 file changed, 1 insertion(+)
+
+commit ea9512e61a7ed333b810918e74cce4c8bd2291b9
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 15:49:33 2018 -0500
+
+ [tests] Redo test runner logging a bit
+
+ test/shaping/run-tests.py | 44
+ +++++++++++++++++++++++---------------------
+ 1 file changed, 23 insertions(+), 21 deletions(-)
+
+commit 5020affc3877d39377506245ecaf01a659eef82a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 15:42:11 2018 -0500
+
+ [tests] Minor
+
+ test/shaping/data/in-house/tests/macos.tests | 2 ++
+ 1 file changed, 2 insertions(+)
+
+commit ee3a3e10d45f5df1a74b65fbe3df77f8dd8f902e
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 15:37:01 2018 -0500
+
+ [tests/shaping] Allow comments in test files
+
+ Line should start with "# ".
+
+ test/shaping/run-tests.py | 17 +++++++++++++++--
+ 1 file changed, 15 insertions(+), 2 deletions(-)
+
+commit ed900ee9afa0dabdbf6bf9d2af46c2343a16773f
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 15:22:09 2018 -0500
+
+ [tests] Rename
+
+ test/shaping/data/in-house/Makefile.sources |
+ 2 +-
+ test/shaping/data/in-house/tests/{macos-10.12.tests => macos.tests} | 0
+ 2 files changed, 1 insertion(+), 1 deletion(-)
+
+commit 20edc70d537b01e8a384ee05673335f2f8a18238
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 14:52:34 2018 -0500
+
+ [morx/kerx] Fix sanitize regression
+
+ Broke in 8dcc1913a1670ede7b124f7b5b775d7ab8791386
+
+ If sanitizer is left with another object, it wouldn't work.
+
+ Better fix coming soon.
+
+ src/hb-aat-layout-kerx-table.hh | 6 +-----
+ src/hb-aat-layout-morx-table.hh | 4 +---
+ 2 files changed, 2 insertions(+), 8 deletions(-)
+
+commit 3cc14e78aeb1c70eb82891ab4513c0e7d0f59928
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sat Nov 24 20:49:21 2018 +0330
+
+ [test] Enable more of aots tests (#1408)
+
+ The ones commented out in this change should've be passed :/
+ a closer look is needed.
+
+ test/shaping/data/aots/Makefile.sources | 76
+ +++++++++++-----------
+ test/shaping/data/aots/hb-aots-tester.cpp | 1 +
+ test/shaping/data/aots/tests/classdef1_empty.tests | 2 +-
+ test/shaping/data/aots/tests/gsub3_1_simple.tests | 2 +-
+ .../data/aots/tests/lookupflag_ignore_attach.tests | 10 +--
+ 5 files changed, 46 insertions(+), 45 deletions(-)
+
+commit 24887d1115ee41cfad70577eb243382f6c23ab6e
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Sat Nov 24 20:07:24 2018 +0330
+
+ Add Adobe AOTS tests (#1395)
+
+ Annotated OpenType Specification or aots,
+ https://github.com/adobe-type-tools/aots
+ provides a set of tests for OpenType specification, this change add
+ those tests in addition
+ to modified version of their HarfBuzz test runner for generating
+ harfbuzz project specific tests.
+
+ configure.ac | 1 +
+ test/shaping/CMakeLists.txt | 13 +-
+ test/shaping/data/Makefile.am | 1 +
+ test/shaping/data/aots/COPYING | 13 +
+ test/shaping/data/aots/Makefile.am | 37 +++
+ test/shaping/data/aots/Makefile.sources | 126 ++++++++
+ test/shaping/data/aots/fonts/classdef1_font3.otf | Bin 0 -> 6060 bytes
+ test/shaping/data/aots/fonts/classdef1_font4.otf | Bin 0 -> 5984 bytes
+ test/shaping/data/aots/fonts/classdef2_font1.otf | Bin 0 -> 6004 bytes
+ test/shaping/data/aots/fonts/classdef2_font2.otf | Bin 0 -> 6016 bytes
+ test/shaping/data/aots/fonts/classdef2_font3.otf | Bin 0 -> 6052 bytes
+ test/shaping/data/aots/fonts/classdef2_font4.otf | Bin 0 -> 5984 bytes
+ test/shaping/data/aots/fonts/cmap0_font1.otf | Bin 0 -> 5196 bytes
+ test/shaping/data/aots/fonts/cmap10_font1.otf | Bin 0 -> 4968 bytes
+ test/shaping/data/aots/fonts/cmap10_font2.otf | Bin 0 -> 4960 bytes
+ test/shaping/data/aots/fonts/cmap12_font1.otf | Bin 0 -> 4980 bytes
+ test/shaping/data/aots/fonts/cmap14_font1.otf | Bin 0 -> 5028 bytes
+ test/shaping/data/aots/fonts/cmap2_font1.otf | Bin 0 -> 6000 bytes
+ test/shaping/data/aots/fonts/cmap4_font1.otf | Bin 0 -> 4964 bytes
+ test/shaping/data/aots/fonts/cmap4_font2.otf | Bin 0 -> 4956 bytes
+ test/shaping/data/aots/fonts/cmap4_font3.otf | Bin 0 -> 4956 bytes
+ test/shaping/data/aots/fonts/cmap4_font4.otf | Bin 0 -> 4972 bytes
+ test/shaping/data/aots/fonts/cmap6_font1.otf | Bin 0 -> 4948 bytes
+ test/shaping/data/aots/fonts/cmap6_font2.otf | Bin 0 -> 4944 bytes
+ test/shaping/data/aots/fonts/cmap8_font1.otf | Bin 0 -> 13224 bytes
+ .../data/aots/fonts/cmap_composition_font1.otf | Bin 0 -> 5096 bytes
+ .../aots/fonts/cmap_subtableselection_font1.otf | Bin 0 -> 6412 bytes
+ .../aots/fonts/cmap_subtableselection_font2.otf | Bin 0 -> 6140 bytes
+ .../aots/fonts/cmap_subtableselection_font3.otf | Bin 0 -> 5872 bytes
+ .../aots/fonts/cmap_subtableselection_font4.otf | Bin 0 -> 5600 bytes
+ .../aots/fonts/cmap_subtableselection_font5.otf | Bin 0 -> 5332 bytes
+ .../data/aots/fonts/gpos1_1_lookupflag_f1.otf | Bin 0 -> 5208 bytes
+ test/shaping/data/aots/fonts/gpos1_1_simple_f1.otf | Bin 0 -> 5136 bytes
+ test/shaping/data/aots/fonts/gpos1_1_simple_f2.otf | Bin 0 -> 5136 bytes
+ test/shaping/data/aots/fonts/gpos1_1_simple_f3.otf | Bin 0 -> 5136 bytes
+ test/shaping/data/aots/fonts/gpos1_1_simple_f4.otf | Bin 0 -> 5136 bytes
+ test/shaping/data/aots/fonts/gpos1_2_font1.otf | Bin 0 -> 5108 bytes
+ test/shaping/data/aots/fonts/gpos1_2_font2.otf | Bin 0 -> 5148 bytes
+ test/shaping/data/aots/fonts/gpos2_1_font6.otf | Bin 0 -> 5120 bytes
+ test/shaping/data/aots/fonts/gpos2_1_font7.otf | Bin 0 -> 5132 bytes
+ .../data/aots/fonts/gpos2_1_lookupflag_f1.otf | Bin 0 -> 5220 bytes
+ .../data/aots/fonts/gpos2_1_lookupflag_f2.otf | Bin 0 -> 5220 bytes
+ .../data/aots/fonts/gpos2_1_next_glyph_f1.otf | Bin 0 -> 5180 bytes
+ .../data/aots/fonts/gpos2_1_next_glyph_f2.otf | Bin 0 -> 5176 bytes
+ test/shaping/data/aots/fonts/gpos2_1_simple_f1.otf | Bin 0 -> 5148 bytes
+ test/shaping/data/aots/fonts/gpos2_2_font1.otf | Bin 0 -> 5148 bytes
+ test/shaping/data/aots/fonts/gpos2_2_font2.otf | Bin 0 -> 5188 bytes
+ test/shaping/data/aots/fonts/gpos2_2_font3.otf | Bin 0 -> 5188 bytes
+ test/shaping/data/aots/fonts/gpos2_2_font4.otf | Bin 0 -> 5148 bytes
+ test/shaping/data/aots/fonts/gpos2_2_font5.otf | Bin 0 -> 5140 bytes
+ test/shaping/data/aots/fonts/gpos3_font1.otf | Bin 0 -> 5120 bytes
+ test/shaping/data/aots/fonts/gpos3_font2.otf | Bin 0 -> 5160 bytes
+ test/shaping/data/aots/fonts/gpos3_font3.otf | Bin 0 -> 5164 bytes
+ .../data/aots/fonts/gpos4_lookupflag_f1.otf | Bin 0 -> 5256 bytes
+ .../data/aots/fonts/gpos4_lookupflag_f2.otf | Bin 0 -> 5240 bytes
+ .../data/aots/fonts/gpos4_multiple_anchors_1.otf | Bin 0 -> 5352 bytes
+ test/shaping/data/aots/fonts/gpos4_simple_1.otf | Bin 0 -> 5200 bytes
+ test/shaping/data/aots/fonts/gpos5_font1.otf | Bin 0 -> 5284 bytes
+ test/shaping/data/aots/fonts/gpos6_font1.otf | Bin 0 -> 5176 bytes
+ test/shaping/data/aots/fonts/gpos7_1_font1.otf | Bin 0 -> 5160 bytes
+ test/shaping/data/aots/fonts/gpos9_font1.otf | Bin 0 -> 5096 bytes
+ test/shaping/data/aots/fonts/gpos9_font2.otf | Bin 0 -> 5124 bytes
+ .../data/aots/fonts/gpos_chaining1_boundary_f1.otf | Bin 0 -> 5496 bytes
+ .../data/aots/fonts/gpos_chaining1_boundary_f2.otf | Bin 0 -> 5500 bytes
+ .../data/aots/fonts/gpos_chaining1_boundary_f3.otf | Bin 0 -> 5496 bytes
+ .../data/aots/fonts/gpos_chaining1_boundary_f4.otf | Bin 0 -> 5496 bytes
+ .../aots/fonts/gpos_chaining1_lookupflag_f1.otf | Bin 0 -> 5520 bytes
+ .../fonts/gpos_chaining1_multiple_subrules_f1.otf | Bin 0 -> 5592 bytes
+ .../fonts/gpos_chaining1_multiple_subrules_f2.otf | Bin 0 -> 5592 bytes
+ .../aots/fonts/gpos_chaining1_next_glyph_f1.otf | Bin 0 -> 5540 bytes
+ .../data/aots/fonts/gpos_chaining1_simple_f1.otf | Bin 0 -> 5488 bytes
+ .../data/aots/fonts/gpos_chaining1_simple_f2.otf | Bin 0 -> 5488 bytes
+ .../aots/fonts/gpos_chaining1_successive_f1.otf | Bin 0 -> 5524 bytes
+ .../data/aots/fonts/gpos_chaining2_boundary_f1.otf | Bin 0 -> 5704 bytes
+ .../data/aots/fonts/gpos_chaining2_boundary_f2.otf | Bin 0 -> 5708 bytes
+ .../data/aots/fonts/gpos_chaining2_boundary_f3.otf | Bin 0 -> 5704 bytes
+ .../data/aots/fonts/gpos_chaining2_boundary_f4.otf | Bin 0 -> 5704 bytes
+ .../aots/fonts/gpos_chaining2_lookupflag_f1.otf | Bin 0 -> 5728 bytes
+ .../fonts/gpos_chaining2_multiple_subrules_f1.otf | Bin 0 -> 5800 bytes
+ .../fonts/gpos_chaining2_multiple_subrules_f2.otf | Bin 0 -> 5800 bytes
+ .../aots/fonts/gpos_chaining2_next_glyph_f1.otf | Bin 0 -> 5744 bytes
+ .../data/aots/fonts/gpos_chaining2_simple_f1.otf | Bin 0 -> 5696 bytes
+ .../data/aots/fonts/gpos_chaining2_simple_f2.otf | Bin 0 -> 5696 bytes
+ .../aots/fonts/gpos_chaining2_successive_f1.otf | Bin 0 -> 5732 bytes
+ .../data/aots/fonts/gpos_chaining3_boundary_f1.otf | Bin 0 -> 5504 bytes
+ .../data/aots/fonts/gpos_chaining3_boundary_f2.otf | Bin 0 -> 5508 bytes
+ .../data/aots/fonts/gpos_chaining3_boundary_f3.otf | Bin 0 -> 5500 bytes
+ .../data/aots/fonts/gpos_chaining3_boundary_f4.otf | Bin 0 -> 5500 bytes
+ .../aots/fonts/gpos_chaining3_lookupflag_f1.otf | Bin 0 -> 5548 bytes
+ .../aots/fonts/gpos_chaining3_next_glyph_f1.otf | Bin 0 -> 5524 bytes
+ .../data/aots/fonts/gpos_chaining3_simple_f1.otf | Bin 0 -> 5496 bytes
+ .../data/aots/fonts/gpos_chaining3_simple_f2.otf | Bin 0 -> 5516 bytes
+ .../aots/fonts/gpos_chaining3_successive_f1.otf | Bin 0 -> 5544 bytes
+ .../data/aots/fonts/gpos_context1_boundary_f1.otf | Bin 0 -> 5480 bytes
+ .../data/aots/fonts/gpos_context1_boundary_f2.otf | Bin 0 -> 5480 bytes
+ .../data/aots/fonts/gpos_context1_expansion_f1.otf | Bin 0 -> 5492 bytes
+ .../aots/fonts/gpos_context1_lookupflag_f1.otf | Bin 0 -> 5508 bytes
+ .../aots/fonts/gpos_context1_lookupflag_f2.otf | Bin 0 -> 5500 bytes
+ .../fonts/gpos_context1_multiple_subrules_f1.otf | Bin 0 -> 5568 bytes
+ .../fonts/gpos_context1_multiple_subrules_f2.otf | Bin 0 -> 5568 bytes
+ .../aots/fonts/gpos_context1_next_glyph_f1.otf | Bin 0 -> 5500 bytes
+ .../data/aots/fonts/gpos_context1_simple_f1.otf | Bin 0 -> 5476 bytes
+ .../data/aots/fonts/gpos_context1_simple_f2.otf | Bin 0 -> 5468 bytes
+ .../aots/fonts/gpos_context1_successive_f1.otf | Bin 0 -> 5508 bytes
+ .../data/aots/fonts/gpos_context2_boundary_f1.otf | Bin 0 -> 5492 bytes
+ .../data/aots/fonts/gpos_context2_boundary_f2.otf | Bin 0 -> 5496 bytes
+ .../data/aots/fonts/gpos_context2_classes_f1.otf | Bin 0 -> 5540 bytes
+ .../data/aots/fonts/gpos_context2_classes_f2.otf | Bin 0 -> 5564 bytes
+ .../data/aots/fonts/gpos_context2_expansion_f1.otf | Bin 0 -> 5524 bytes
+ .../aots/fonts/gpos_context2_lookupflag_f1.otf | Bin 0 -> 5540 bytes
+ .../aots/fonts/gpos_context2_lookupflag_f2.otf | Bin 0 -> 5532 bytes
+ .../fonts/gpos_context2_multiple_subrules_f1.otf | Bin 0 -> 5600 bytes
+ .../fonts/gpos_context2_multiple_subrules_f2.otf | Bin 0 -> 5600 bytes
+ .../aots/fonts/gpos_context2_next_glyph_f1.otf | Bin 0 -> 5512 bytes
+ .../data/aots/fonts/gpos_context2_simple_f1.otf | Bin 0 -> 5508 bytes
+ .../data/aots/fonts/gpos_context2_simple_f2.otf | Bin 0 -> 5484 bytes
+ .../aots/fonts/gpos_context2_successive_f1.otf | Bin 0 -> 5544 bytes
+ .../data/aots/fonts/gpos_context3_boundary_f1.otf | Bin 0 -> 5476 bytes
+ .../data/aots/fonts/gpos_context3_boundary_f2.otf | Bin 0 -> 5472 bytes
+ .../aots/fonts/gpos_context3_lookupflag_f1.otf | Bin 0 -> 5512 bytes
+ .../aots/fonts/gpos_context3_lookupflag_f2.otf | Bin 0 -> 5504 bytes
+ .../aots/fonts/gpos_context3_next_glyph_f1.otf | Bin 0 -> 5496 bytes
+ .../data/aots/fonts/gpos_context3_simple_f1.otf | Bin 0 -> 5480 bytes
+ .../aots/fonts/gpos_context3_successive_f1.otf | Bin 0 -> 5516 bytes
+ .../data/aots/fonts/gsub1_1_lookupflag_f1.otf | Bin 0 -> 5208 bytes
+ test/shaping/data/aots/fonts/gsub1_1_modulo_f1.otf | Bin 0 -> 5216 bytes
+ test/shaping/data/aots/fonts/gsub1_1_simple_f1.otf | Bin 0 -> 5136 bytes
+ .../data/aots/fonts/gsub1_2_lookupflag_f1.otf | Bin 0 -> 5212 bytes
+ test/shaping/data/aots/fonts/gsub1_2_simple_f1.otf | Bin 0 -> 5140 bytes
+ .../data/aots/fonts/gsub2_1_lookupflag_f1.otf | Bin 0 -> 5224 bytes
+ .../aots/fonts/gsub2_1_multiple_sequences_f1.otf | Bin 0 -> 5248 bytes
+ test/shaping/data/aots/fonts/gsub2_1_simple_f1.otf | Bin 0 -> 5144 bytes
+ .../data/aots/fonts/gsub3_1_lookupflag_f1.otf | Bin 0 -> 5224 bytes
+ .../data/aots/fonts/gsub3_1_multiple_f1.otf | Bin 0 -> 5168 bytes
+ test/shaping/data/aots/fonts/gsub3_1_simple_f1.otf | Bin 0 -> 5144 bytes
+ .../data/aots/fonts/gsub4_1_lookupflag_f1.otf | Bin 0 -> 5220 bytes
+ .../aots/fonts/gsub4_1_multiple_ligatures_f1.otf | Bin 0 -> 5252 bytes
+ .../aots/fonts/gsub4_1_multiple_ligatures_f2.otf | Bin 0 -> 5252 bytes
+ .../aots/fonts/gsub4_1_multiple_ligsets_f1.otf | Bin 0 -> 5240 bytes
+ test/shaping/data/aots/fonts/gsub4_1_simple_f1.otf | Bin 0 -> 5148 bytes
+ test/shaping/data/aots/fonts/gsub7_font1.otf | Bin 0 -> 5096 bytes
+ test/shaping/data/aots/fonts/gsub7_font2.otf | Bin 0 -> 5116 bytes
+ .../data/aots/fonts/gsub_chaining1_boundary_f1.otf | Bin 0 -> 5516 bytes
+ .../data/aots/fonts/gsub_chaining1_boundary_f2.otf | Bin 0 -> 5520 bytes
+ .../data/aots/fonts/gsub_chaining1_boundary_f3.otf | Bin 0 -> 5520 bytes
+ .../data/aots/fonts/gsub_chaining1_boundary_f4.otf | Bin 0 -> 5520 bytes
+ .../aots/fonts/gsub_chaining1_lookupflag_f1.otf | Bin 0 -> 5544 bytes
+ .../fonts/gsub_chaining1_multiple_subrules_f1.otf | Bin 0 -> 5616 bytes
+ .../fonts/gsub_chaining1_multiple_subrules_f2.otf | Bin 0 -> 5616 bytes
+ .../aots/fonts/gsub_chaining1_next_glyph_f1.otf | Bin 0 -> 5560 bytes
+ .../data/aots/fonts/gsub_chaining1_simple_f1.otf | Bin 0 -> 5508 bytes
+ .../data/aots/fonts/gsub_chaining1_simple_f2.otf | Bin 0 -> 5512 bytes
+ .../aots/fonts/gsub_chaining1_successive_f1.otf | Bin 0 -> 5544 bytes
+ .../data/aots/fonts/gsub_chaining2_boundary_f1.otf | Bin 0 -> 5724 bytes
+ .../data/aots/fonts/gsub_chaining2_boundary_f2.otf | Bin 0 -> 5728 bytes
+ .../data/aots/fonts/gsub_chaining2_boundary_f3.otf | Bin 0 -> 5728 bytes
+ .../data/aots/fonts/gsub_chaining2_boundary_f4.otf | Bin 0 -> 5728 bytes
+ .../aots/fonts/gsub_chaining2_lookupflag_f1.otf | Bin 0 -> 5752 bytes
+ .../fonts/gsub_chaining2_multiple_subrules_f1.otf | Bin 0 -> 5824 bytes
+ .../fonts/gsub_chaining2_multiple_subrules_f2.otf | Bin 0 -> 5824 bytes
+ .../aots/fonts/gsub_chaining2_next_glyph_f1.otf | Bin 0 -> 5764 bytes
+ .../data/aots/fonts/gsub_chaining2_simple_f1.otf | Bin 0 -> 5716 bytes
+ .../data/aots/fonts/gsub_chaining2_simple_f2.otf | Bin 0 -> 5720 bytes
+ .../aots/fonts/gsub_chaining2_successive_f1.otf | Bin 0 -> 5752 bytes
+ .../data/aots/fonts/gsub_chaining3_boundary_f1.otf | Bin 0 -> 5528 bytes
+ .../data/aots/fonts/gsub_chaining3_boundary_f2.otf | Bin 0 -> 5532 bytes
+ .../data/aots/fonts/gsub_chaining3_boundary_f3.otf | Bin 0 -> 5524 bytes
+ .../data/aots/fonts/gsub_chaining3_boundary_f4.otf | Bin 0 -> 5524 bytes
+ .../aots/fonts/gsub_chaining3_lookupflag_f1.otf | Bin 0 -> 5572 bytes
+ .../aots/fonts/gsub_chaining3_next_glyph_f1.otf | Bin 0 -> 5548 bytes
+ .../data/aots/fonts/gsub_chaining3_simple_f1.otf | Bin 0 -> 5520 bytes
+ .../data/aots/fonts/gsub_chaining3_simple_f2.otf | Bin 0 -> 5540 bytes
+ .../aots/fonts/gsub_chaining3_successive_f1.otf | Bin 0 -> 5568 bytes
+ .../data/aots/fonts/gsub_context1_boundary_f1.otf | Bin 0 -> 5500 bytes
+ .../data/aots/fonts/gsub_context1_boundary_f2.otf | Bin 0 -> 5504 bytes
+ .../data/aots/fonts/gsub_context1_expansion_f1.otf | Bin 0 -> 5516 bytes
+ .../aots/fonts/gsub_context1_lookupflag_f1.otf | Bin 0 -> 5532 bytes
+ .../aots/fonts/gsub_context1_lookupflag_f2.otf | Bin 0 -> 5524 bytes
+ .../fonts/gsub_context1_multiple_subrules_f1.otf | Bin 0 -> 5592 bytes
+ .../fonts/gsub_context1_multiple_subrules_f2.otf | Bin 0 -> 5592 bytes
+ .../aots/fonts/gsub_context1_next_glyph_f1.otf | Bin 0 -> 5520 bytes
+ .../data/aots/fonts/gsub_context1_simple_f1.otf | Bin 0 -> 5500 bytes
+ .../data/aots/fonts/gsub_context1_simple_f2.otf | Bin 0 -> 5492 bytes
+ .../aots/fonts/gsub_context1_successive_f1.otf | Bin 0 -> 5528 bytes
+ .../data/aots/fonts/gsub_context2_boundary_f1.otf | Bin 0 -> 5516 bytes
+ .../data/aots/fonts/gsub_context2_boundary_f2.otf | Bin 0 -> 5516 bytes
+ .../data/aots/fonts/gsub_context2_classes_f1.otf | Bin 0 -> 5564 bytes
+ .../data/aots/fonts/gsub_context2_classes_f2.otf | Bin 0 -> 5584 bytes
+ .../data/aots/fonts/gsub_context2_expansion_f1.otf | Bin 0 -> 5544 bytes
+ .../aots/fonts/gsub_context2_lookupflag_f1.otf | Bin 0 -> 5560 bytes
+ .../aots/fonts/gsub_context2_lookupflag_f2.otf | Bin 0 -> 5552 bytes
+ .../fonts/gsub_context2_multiple_subrules_f1.otf | Bin 0 -> 5620 bytes
+ .../fonts/gsub_context2_multiple_subrules_f2.otf | Bin 0 -> 5620 bytes
+ .../aots/fonts/gsub_context2_next_glyph_f1.otf | Bin 0 -> 5536 bytes
+ .../data/aots/fonts/gsub_context2_simple_f1.otf | Bin 0 -> 5528 bytes
+ .../data/aots/fonts/gsub_context2_simple_f2.otf | Bin 0 -> 5504 bytes
+ .../aots/fonts/gsub_context2_successive_f1.otf | Bin 0 -> 5568 bytes
+ .../data/aots/fonts/gsub_context3_boundary_f1.otf | Bin 0 -> 5500 bytes
+ .../data/aots/fonts/gsub_context3_boundary_f2.otf | Bin 0 -> 5496 bytes
+ .../aots/fonts/gsub_context3_lookupflag_f1.otf | Bin 0 -> 5536 bytes
+ .../aots/fonts/gsub_context3_lookupflag_f2.otf | Bin 0 -> 5528 bytes
+ .../aots/fonts/gsub_context3_next_glyph_f1.otf | Bin 0 -> 5520 bytes
+ .../data/aots/fonts/gsub_context3_simple_f1.otf | Bin 0 -> 5504 bytes
+ .../aots/fonts/gsub_context3_successive_f1.otf | Bin 0 -> 5540 bytes
+ .../aots/fonts/lookupflag_ignore_attach_f1.otf | Bin 0 -> 5416 bytes
+ .../data/aots/fonts/lookupflag_ignore_base_f1.otf | Bin 0 -> 5256 bytes
+ .../fonts/lookupflag_ignore_combination_f1.otf | Bin 0 -> 5408 bytes
+ .../aots/fonts/lookupflag_ignore_ligatures_f1.otf | Bin 0 -> 5320 bytes
+ .../data/aots/fonts/lookupflag_ignore_marks_f1.otf | Bin 0 -> 5288 bytes
+ test/shaping/data/aots/hb-aots-tester.cpp | 343
+ +++++++++++++++++++++
+ test/shaping/data/aots/tests/classdef1.tests | 1 +
+ test/shaping/data/aots/tests/classdef1_empty.tests | 1 +
+ .../data/aots/tests/classdef1_multiple.tests | 1 +
+ .../shaping/data/aots/tests/classdef1_single.tests | 1 +
+ test/shaping/data/aots/tests/classdef2.tests | 1 +
+ test/shaping/data/aots/tests/classdef2_empty.tests | 1 +
+ .../data/aots/tests/classdef2_multiple.tests | 1 +
+ .../shaping/data/aots/tests/classdef2_single.tests | 1 +
+ .../data/aots/tests/gpos1_1_lookupflag.tests | 1 +
+ test/shaping/data/aots/tests/gpos1_1_simple.tests | 4 +
+ test/shaping/data/aots/tests/gpos1_2.tests | 1 +
+ .../data/aots/tests/gpos1_2_lookupflag.tests | 1 +
+ test/shaping/data/aots/tests/gpos2_1.tests | 2 +
+ .../data/aots/tests/gpos2_1_lookupflag.tests | 2 +
+ .../data/aots/tests/gpos2_1_next_glyph.tests | 2 +
+ test/shaping/data/aots/tests/gpos2_1_simple.tests | 2 +
+ test/shaping/data/aots/tests/gpos2_2.tests | 5 +
+ test/shaping/data/aots/tests/gpos3.tests | 11 +
+ .../shaping/data/aots/tests/gpos3_lookupflag.tests | 2 +
+ .../shaping/data/aots/tests/gpos4_lookupflag.tests | 2 +
+ .../data/aots/tests/gpos4_multiple_anchors.tests | 1 +
+ test/shaping/data/aots/tests/gpos4_simple.tests | 5 +
+ test/shaping/data/aots/tests/gpos5.tests | 2 +
+ test/shaping/data/aots/tests/gpos6.tests | 3 +
+ test/shaping/data/aots/tests/gpos7_1.tests | 2 +
+ test/shaping/data/aots/tests/gpos9.tests | 2 +
+ .../data/aots/tests/gpos_chaining1_boundary.tests | 4 +
+ .../aots/tests/gpos_chaining1_lookupflag.tests | 1 +
+ .../tests/gpos_chaining1_multiple_subrules.tests | 2 +
+ .../aots/tests/gpos_chaining1_next_glyph.tests | 1 +
+ .../data/aots/tests/gpos_chaining1_simple.tests | 11 +
+ .../aots/tests/gpos_chaining1_successive.tests | 1 +
+ .../data/aots/tests/gpos_chaining2_boundary.tests | 4 +
+ .../aots/tests/gpos_chaining2_lookupflag.tests | 1 +
+ .../tests/gpos_chaining2_multiple_subrules.tests | 2 +
+ .../aots/tests/gpos_chaining2_next_glyph.tests | 1 +
+ .../data/aots/tests/gpos_chaining2_simple.tests | 11 +
+ .../aots/tests/gpos_chaining2_successive.tests | 1 +
+ .../data/aots/tests/gpos_chaining3_boundary.tests | 4 +
+ .../aots/tests/gpos_chaining3_lookupflag.tests | 1 +
+ .../aots/tests/gpos_chaining3_next_glyph.tests | 1 +
+ .../data/aots/tests/gpos_chaining3_simple.tests | 11 +
+ .../aots/tests/gpos_chaining3_successive.tests | 1 +
+ .../data/aots/tests/gpos_context1_boundary.tests | 2 +
+ .../data/aots/tests/gpos_context1_expansion.tests | 1 +
+ .../data/aots/tests/gpos_context1_lookupflag.tests | 2 +
+ .../tests/gpos_context1_multiple_subrules.tests | 2 +
+ .../data/aots/tests/gpos_context1_next_glyph.tests | 1 +
+ .../data/aots/tests/gpos_context1_simple.tests | 3 +
+ .../data/aots/tests/gpos_context1_successive.tests | 1 +
+ .../data/aots/tests/gpos_context2_boundary.tests | 2 +
+ .../data/aots/tests/gpos_context2_classes.tests | 2 +
+ .../data/aots/tests/gpos_context2_expansion.tests | 1 +
+ .../data/aots/tests/gpos_context2_lookupflag.tests | 2 +
+ .../tests/gpos_context2_multiple_subrules.tests | 2 +
+ .../data/aots/tests/gpos_context2_next_glyph.tests | 1 +
+ .../data/aots/tests/gpos_context2_simple.tests | 3 +
+ .../data/aots/tests/gpos_context2_successive.tests | 1 +
+ .../data/aots/tests/gpos_context3_boundary.tests | 2 +
+ .../data/aots/tests/gpos_context3_lookupflag.tests | 2 +
+ .../data/aots/tests/gpos_context3_next_glyph.tests | 1 +
+ .../data/aots/tests/gpos_context3_simple.tests | 2 +
+ .../data/aots/tests/gpos_context3_successive.tests | 1 +
+ .../data/aots/tests/gsub1_1_lookupflag.tests | 1 +
+ test/shaping/data/aots/tests/gsub1_1_modulo.tests | 1 +
+ test/shaping/data/aots/tests/gsub1_1_simple.tests | 1 +
+ .../data/aots/tests/gsub1_2_lookupflag.tests | 1 +
+ test/shaping/data/aots/tests/gsub1_2_simple.tests | 1 +
+ .../data/aots/tests/gsub2_1_lookupflag.tests | 1 +
+ .../aots/tests/gsub2_1_multiple_sequences.tests | 1 +
+ test/shaping/data/aots/tests/gsub2_1_simple.tests | 2 +
+ .../data/aots/tests/gsub3_1_lookupflag.tests | 1 +
+ .../shaping/data/aots/tests/gsub3_1_multiple.tests | 1 +
+ test/shaping/data/aots/tests/gsub3_1_simple.tests | 1 +
+ .../data/aots/tests/gsub4_1_lookupflag.tests | 1 +
+ .../aots/tests/gsub4_1_multiple_ligatures.tests | 2 +
+ .../data/aots/tests/gsub4_1_multiple_ligsets.tests | 1 +
+ test/shaping/data/aots/tests/gsub4_1_simple.tests | 1 +
+ test/shaping/data/aots/tests/gsub7.tests | 2 +
+ .../data/aots/tests/gsub_chaining1_boundary.tests | 4 +
+ .../aots/tests/gsub_chaining1_lookupflag.tests | 1 +
+ .../tests/gsub_chaining1_multiple_subrules.tests | 2 +
+ .../aots/tests/gsub_chaining1_next_glyph.tests | 1 +
+ .../data/aots/tests/gsub_chaining1_simple.tests | 11 +
+ .../aots/tests/gsub_chaining1_successive.tests | 1 +
+ .../data/aots/tests/gsub_chaining2_boundary.tests | 4 +
+ .../aots/tests/gsub_chaining2_lookupflag.tests | 1 +
+ .../tests/gsub_chaining2_multiple_subrules.tests | 2 +
+ .../aots/tests/gsub_chaining2_next_glyph.tests | 1 +
+ .../data/aots/tests/gsub_chaining2_simple.tests | 11 +
+ .../aots/tests/gsub_chaining2_successive.tests | 1 +
+ .../data/aots/tests/gsub_chaining3_boundary.tests | 4 +
+ .../aots/tests/gsub_chaining3_lookupflag.tests | 1 +
+ .../aots/tests/gsub_chaining3_next_glyph.tests | 1 +
+ .../data/aots/tests/gsub_chaining3_simple.tests | 11 +
+ .../aots/tests/gsub_chaining3_successive.tests | 1 +
+ .../data/aots/tests/gsub_context1_boundary.tests | 2 +
+ .../data/aots/tests/gsub_context1_expansion.tests | 1 +
+ .../data/aots/tests/gsub_context1_lookupflag.tests | 2 +
+ .../tests/gsub_context1_multiple_subrules.tests | 2 +
+ .../data/aots/tests/gsub_context1_next_glyph.tests | 1 +
+ .../data/aots/tests/gsub_context1_simple.tests | 3 +
+ .../data/aots/tests/gsub_context1_successive.tests | 1 +
+ .../data/aots/tests/gsub_context2_boundary.tests | 2 +
+ .../data/aots/tests/gsub_context2_classes.tests | 2 +
+ .../data/aots/tests/gsub_context2_expansion.tests | 1 +
+ .../data/aots/tests/gsub_context2_lookupflag.tests | 2 +
+ .../tests/gsub_context2_multiple_subrules.tests | 2 +
+ .../data/aots/tests/gsub_context2_next_glyph.tests | 1 +
+ .../data/aots/tests/gsub_context2_simple.tests | 3 +
+ .../data/aots/tests/gsub_context2_successive.tests | 1 +
+ .../data/aots/tests/gsub_context3_boundary.tests | 2 +
+ .../data/aots/tests/gsub_context3_lookupflag.tests | 2 +
+ .../data/aots/tests/gsub_context3_next_glyph.tests | 1 +
+ .../data/aots/tests/gsub_context3_simple.tests | 2 +
+ .../data/aots/tests/gsub_context3_successive.tests | 1 +
+ .../data/aots/tests/lookupflag_ignore_attach.tests | 5 +
+ .../data/aots/tests/lookupflag_ignore_base.tests | 2 +
+ .../aots/tests/lookupflag_ignore_combination.tests | 3 +
+ .../aots/tests/lookupflag_ignore_ligatures.tests | 3 +
+ .../data/aots/tests/lookupflag_ignore_marks.tests | 1 +
+ test/shaping/run-tests.py | 9 +-
+ 332 files changed, 815 insertions(+), 3 deletions(-)
+
+commit ae96c98dfaef3a789227ffecd40b92518dface8a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 10:25:10 2018 -0500
+
+ [color] Use SortedUnsizedArrayOf<>
+
+ src/hb-ot-color-colr-table.hh | 16 ++--------------
+ 1 file changed, 2 insertions(+), 14 deletions(-)
+
+commit 4a3b20738fca3231e5d9a36adba333b5bce05f4a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 10:17:59 2018 -0500
+
+ [trak] Coment
+
+ src/hb-aat-layout-trak-table.hh | 1 -
+ 1 file changed, 1 deletion(-)
+
+commit 918b1ee54d43eb493c9226bff7677ed8ec07934b
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 10:09:17 2018 -0500
+
+ [arrays] Add not_found to reference bsearch as well
+
+ src/hb-open-type.hh | 16 ++++++++--------
+ 1 file changed, 8 insertions(+), 8 deletions(-)
+
+commit d77a098b735cf14aa601feab5bdb9f4e474c794f
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 10:06:13 2018 -0500
+
+ [arrays] Improve bfind() interface
+
+ Much more useful now. :)
+
+ src/hb-dsalgs.hh | 29 +++++++++++++++++++++++++----
+ src/hb-open-file.hh | 9 +--------
+ src/hb-open-type.hh | 12 ++++++++----
+ src/hb-ot-layout-common.hh | 10 ++--------
+ src/hb-set.hh | 6 +++---
+ src/hb-vector.hh | 6 ++++--
+ 6 files changed, 43 insertions(+), 29 deletions(-)
+
+commit 1204a247a5d9a4da39675d3da85d4fd3268a5b66
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 09:49:21 2018 -0500
+
+ [fuzzing] Add tests for previous commit
+
+ Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11526
+ Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11522
+
+ ...zz-testcase-minimized-hb-shape-fuzzer-5634620935110656 | Bin 0 ->
+ 41 bytes
+ ...zz-testcase-minimized-hb-shape-fuzzer-5716208469409792 | Bin 0 ->
+ 243 bytes
+ 2 files changed, 0 insertions(+), 0 deletions(-)
+
+commit 8dcc1913a1670ede7b124f7b5b775d7ab8791386
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 09:47:45 2018 -0500
+
+ [kerx/morx] Make sure object length is sanitized before accessing it
+
+ src/hb-aat-layout-kerx-table.hh | 5 +++++
+ src/hb-aat-layout-morx-table.hh | 5 +++++
+ 2 files changed, 10 insertions(+)
+
+commit 70d80c90fe2f4eca66bec3e1d313bbf7e4d0ab65
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:59:50 2018 -0500
+
+ [arrays] Port ArrayOf.qsort() and hb_vector_t.qsort() to hb_array_t
+
+ src/hb-dsalgs.hh | 14 ++++++++++++--
+ src/hb-open-type.hh | 14 ++++++++++++--
+ 2 files changed, 24 insertions(+), 4 deletions(-)
+
+commit 073d837aa2394d29dda72679802d583c559c3c5b
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:48:48 2018 -0500
+
+ [arrays] Port ArrayOf.qsort() to hb_array_t's
+
+ src/hb-open-type.hh | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+commit ad5c871d801b481f95dd32c8b65ecc70def597be
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:47:49 2018 -0500
+
+ [arrays] Add copy-constructor to hb_array_t and hb_sorted_array_t
+
+ src/hb-dsalgs.hh | 2 ++
+ 1 file changed, 2 insertions(+)
+
+commit 61de55bf496c1edb120e4d096140eb1125552bbe
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:45:58 2018 -0500
+
+ [arrays] Port hb_vector_t.qsort() to hb_array_t's
+
+ src/hb-dsalgs.hh | 16 +++++++++++++---
+ src/hb-vector.hh | 10 ++--------
+ 2 files changed, 15 insertions(+), 11 deletions(-)
+
+commit e3face8e791d677f94154e8a7f3d787d0d69a02f
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:42:17 2018 -0500
+
+ [arrays] Remove one flavor of hb_vector_t.qsort()
+
+ src/hb-vector.hh | 8 ++------
+ 1 file changed, 2 insertions(+), 6 deletions(-)
+
+commit 7c1600dcd9813ca560ecccc5c54877a5750caf4e
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:37:11 2018 -0500
+
+ [arrays] Add (unused) SortedUnsizedArrayOf<>
+
+ src/hb-open-type.hh | 21 +++++++++++++++++++++
+ 1 file changed, 21 insertions(+)
+
+commit e700392f5cbf366f1e03dc7e7b1a2eb6c3027b92
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:31:00 2018 -0500
+
+ [arrays] Port SortedArrayOf.bsearch/bfind to hb_sorted_array_t's
+
+ src/hb-dsalgs.hh | 9 +++------
+ src/hb-open-type.hh | 50
+ ++++++++++----------------------------------------
+ src/hb-vector.hh | 35 ++++++++++-------------------------
+ 3 files changed, 23 insertions(+), 71 deletions(-)
+
+commit e604306f2829804e9016966c1378166253b19d29
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:24:48 2018 -0500
+
+ [arrays] Port hb_vector_t.bsearch/bfind to (new) hb_sorted_array_t's
+
+ src/hb-dsalgs.hh | 63
+ +++++++++++++++++++++++++++++++++++++++++++++++++----
+ src/hb-open-type.hh | 12 ++++++----
+ src/hb-vector.hh | 57 +++++++++++++++++++-----------------------------
+ 3 files changed, 89 insertions(+), 43 deletions(-)
+
+commit 268eca24921e85eda98f4f0cce05d40c7235ba62
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:11:12 2018 -0500
+
+ [arrays] Port (unused) ArrayOf.lsearch() to hb_array_t's
+
+ src/hb-open-type.hh | 12 ++----------
+ 1 file changed, 2 insertions(+), 10 deletions(-)
+
+commit 830856ba6b9454bf507e00416f9d45e9975fb7dc
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:09:28 2018 -0500
+
+ [arrays] Port hb_vector_t.lsearch() to hb_array_t's
+
+ src/hb-dsalgs.hh | 26 +++++++++++++++++++++++---
+ src/hb-vector.hh | 16 ++++------------
+ 2 files changed, 27 insertions(+), 15 deletions(-)
+
+commit 96cf0889804b7d72a96274b25641bb18f7dd2e1e
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 01:07:15 2018 -0500
+
+ [arrays] More
+
+ src/hb-face.cc | 6 +++---
+ src/hb-vector.hh | 4 ++--
+ 2 files changed, 5 insertions(+), 5 deletions(-)
+
+commit 3e26c8d2b10fc08642c25c7f13aef68b0b1008f6
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:58:44 2018 -0500
+
+ [arrays] Update ArrayOf.lsearch()
+
+ Currently unused apparently
+
+ src/hb-open-type.hh | 17 +++++++++++++----
+ 1 file changed, 13 insertions(+), 4 deletions(-)
+
+commit 22e1857b01c71714245ddca05cb3fa0127bf7da2
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:53:19 2018 -0500
+
+ [arrays] Change argument type of cmp called by hb_vector_t.bsearch()
+
+ Towards consolidating all array bsearch/...
+
+ src/hb-aat-map.hh | 4 ++--
+ src/hb-ot-map.hh | 4 ++--
+ src/hb-set.hh | 2 +-
+ src/hb-vector.hh | 4 ++--
+ 4 files changed, 7 insertions(+), 7 deletions(-)
+
+commit 5fdf7b724eb3cb5ac60cd7f90d3250877ad7ca06
+Author: Nathan Willis <nwillis@glyphography.com>
+Date: Thu Nov 15 17:40:21 2018 -0600
+
+ Usermanual: clusters chapter; add brief grapheme definition and
+ clarify monotonous cluster handling.
+
+ docs/usermanual-clusters.xml | 56
+ ++++++++++++++++++++++++++++++--------------
+ 1 file changed, 39 insertions(+), 17 deletions(-)
+
+commit 939220e57da613e090d247aa1af2396c28370af4
+Author: Nathan Willis <nwillis@glyphography.com>
+Date: Thu Nov 15 15:47:03 2018 -0600
+
+ Usermanual: clusters chapter, minor updates.
+
+ docs/usermanual-clusters.xml | 25 ++++++++++++++++---------
+ 1 file changed, 16 insertions(+), 9 deletions(-)
+
+commit 53ac46e974cf0ee8720b40ef394714eb97ff53b9
+Author: Nathan Willis <nwillis@glyphography.com>
+Date: Mon Nov 12 12:17:06 2018 -0600
+
+ Usermanual: expand clusters chapter.
+
+ docs/usermanual-clusters.xml | 743
+ +++++++++++++++++++++++++++----------------
+ 1 file changed, 473 insertions(+), 270 deletions(-)
+
+commit 30cb45b3eaacda15cc45435815cae3fd50e87557
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:35:31 2018 -0500
+
+ Change ArrayOf.bsearch() return semantics
+
+ Towards consolidating all array bsearch/...
+
+ src/hb-aat-layout-kerx-table.hh | 16 +++-------------
+ src/hb-open-file.hh | 12 ++++++++----
+ src/hb-open-type.hh | 42
+ ++++++++++++++++++++++++++++++++---------
+ src/hb-ot-cmap-table.hh | 30 ++++++++++++-----------------
+ src/hb-ot-color-svg-table.hh | 3 +--
+ src/hb-ot-layout-common.hh | 29 +++++++++++-----------------
+ src/hb-ot-vorg-table.hh | 9 ++++-----
+ src/hb-vector.hh | 14 +++++++++-----
+ 8 files changed, 81 insertions(+), 74 deletions(-)
+
+commit 5cd9546ba73d9f8c8b7b8db0960d657c50b70f64
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:38:36 2018 -0500
+
+ Minor
+
+ src/hb-ot-layout-common.hh | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+commit fd94e729cb50f2b6bd83b80cbf400e10ac633a1c
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:45:55 2018 -0500
+
+ Whitespace
+
+ src/hb-ot-layout-common.hh | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+commit bb2a2065080a3099eb0dc82d1df0891ad2601316
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:31:40 2018 -0500
+
+ Assert that item-type of arrays have static size
+
+ src/hb-dsalgs.hh | 2 ++
+ src/hb-open-type.hh | 4 ++++
+ src/hb-vector.hh | 2 ++
+ 3 files changed, 8 insertions(+)
+
+commit 690d9eb83d3421b397b0cb824cd768d6d73cbf12
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:29:22 2018 -0500
+
+ [vector] Rename
+
+ src/hb-vector.hh | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+commit ba38378fd4374f3d44bdc9aa0de902401b60b13d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:27:57 2018 -0500
+
+ [aat] Minor
+
+ src/hb-aat-layout-common.hh | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+commit 39b9d63b014380d421cc9b94a49dd411c7a5aabf
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:25:40 2018 -0500
+
+ Add hb_static_size(T)
+
+ src/hb-null.hh | 19 +++++++++++++++++++
+ 1 file changed, 19 insertions(+)
+
+commit f99abcc37990a478189dda691d1fdac7b9d51386
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Sat Nov 24 00:22:21 2018 -0500
+
+ Add template-function convenience macros
+
+ src/hb-atomic.hh | 2 +-
+ src/hb-blob.hh | 4 ++--
+ src/hb-common.cc | 2 +-
+ src/hb-ft.cc | 2 +-
+ src/hb-null.hh | 11 ++++++-----
+ src/hb.hh | 3 +++
+ 6 files changed, 14 insertions(+), 10 deletions(-)
+
+commit ec83b2228e0bbb6df7e7b94dad49db32b041af4a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 19:58:49 2018 -0500
+
+ Add null bytes for CmapSubtableLongGroup
+
+ src/hb-ot-cmap-table.hh | 1 +
+ src/hb-static.cc | 4 +++-
+ 2 files changed, 4 insertions(+), 1 deletion(-)
+
+commit e2ffb33a534a427c760dae53d0469eeced4343ba
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 16:24:28 2018 -0500
+
+ Remove lsearch for small TableDirectorys
+
+ src/hb-open-file.hh | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+commit 04f7e5536924e7f277d72b8cb9d878239877c331
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 16:07:43 2018 -0500
+
+ [arrays] Add as_array() to hb_vector_t<>
+
+ src/hb-vector.hh | 3 +++
+ 1 file changed, 3 insertions(+)
+
+commit c514f65181390ab98b0f738632f71cda31e46b68
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 16:04:56 2018 -0500
+
+ [arrays] Add as_array() to ArrayOf<>
+
+ src/hb-open-type.hh | 3 +++
+ 1 file changed, 3 insertions(+)
+
+commit 9552f4ef0da0b7e1fb28cb2738b865888e7941d9
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 15:24:17 2018 -0500
+
+ [kern] Don't enforce length of last subtable
+
+ src/hb-aat-layout-kerx-table.hh | 19 +++++++++++++++++--
+ 1 file changed, 17 insertions(+), 2 deletions(-)
+
+commit 992b7128656e72f935089dc2e12c2d2a25511886
+Merge: c9cc96c0 018ba46e
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 13:49:34 2018 -0500
+
+ Merge pull request #1407 from harfbuzz/at-sign
+
+ Don't canonicalize '@' to '-' in language tags
+
+commit 018ba46e4d003a5dd0f6d2d899226129c4ef0c60
+Author: David Corbett <corbett.dav@husky.neu.edu>
+Date: Fri Nov 23 13:21:22 2018 -0500
+
+ Don't canonicalize '@' to '-' in language tags
+
+ Fixes #1406.
+
+ src/hb-common.cc | 2 +-
+ test/api/test-ot-tag.c | 3 +++
+ 2 files changed, 4 insertions(+), 1 deletion(-)
+
+commit c9cc96c0cfbbb87b9292e413d500a454182be9f4
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Fri Nov 23 19:58:56 2018 +0330
+
+ [aat] Update expectation
+
+ test/shaping/data/in-house/tests/macos-10.12.tests | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 748962264a9f098b32b9cb3fe4d18c786907a184
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 11:10:17 2018 -0500
+
+ [aat] Disable mark advance zeroing if kern table has state-machines
+
+ Geeza Pro for example, relies on that for fancy mark positioning.
+
+ Fixes https://github.com/harfbuzz/harfbuzz/issues/1405
+
+ src/hb-aat-layout-kerx-table.hh | 15 +++++++++++++++
+ src/hb-ot-kern-table.hh | 9 +++++++++
+ src/hb-ot-layout.cc | 6 ++++++
+ src/hb-ot-layout.hh | 3 +++
+ src/hb-ot-shape.cc | 4 +++-
+ 5 files changed, 36 insertions(+), 1 deletion(-)
+
+commit 3d2b98ef14af29acd74f01647bef60cd410825fb
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Fri Nov 23 10:45:44 2018 -0500
+
+ Minor
+
+ src/hb.hh | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+commit 341851efe158599a34d241a97593058a4333852e
+Author: Ebrahim Byagowi <ebrahim@gnu.org>
+Date: Fri Nov 23 15:40:05 2018 +0330
+
+ [aat] Add macOS specific tests (#1404)
+
+ .circleci/config.yml | 46
+ ++++++++++++++--------
+ test/shaping/CMakeLists.txt | 2 +
+ test/shaping/data/in-house/Makefile.sources | 1 +
+ test/shaping/data/in-house/tests/macos-10.12.tests | 10 +++++
+ test/shaping/run-tests.py | 38
+ ++++++++++++++----
+ 5 files changed, 73 insertions(+), 24 deletions(-)
+
+commit 22798e93c414a2655c757a6e41b300f67e04a9a3
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 22:47:51 2018 -0500
+
+ [use] Minor clarification
+
+ src/hb-ot-shape-complex-use.cc | 34 +++++++++++++++++-----------------
+ 1 file changed, 17 insertions(+), 17 deletions(-)
+
+commit a2d6c1075a5595a08ef09357293919d9df8eb64a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 22:40:57 2018 -0500
+
+ Minor tweak to FLAG64
+
+ src/hb.hh | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+commit 8280459e74cff2dec3de012abd309cda9578b759
+Merge: e4a4555d 3c7792ca
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 22:39:12 2018 -0500
+
+ Merge pull request #1291 from harfbuzz/use-reordering
+
+ [use] Fix reordering
+
+commit e4a4555d1e40dacdf72452805e9e6b6109627d63
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 22:17:49 2018 -0500
+
+ [cmap] Move code around
+
+ src/hb-ot-cmap-table.hh | 18 ++++++++++--------
+ 1 file changed, 10 insertions(+), 8 deletions(-)
+
+commit 758c9d68e2143493978d8ac8391f4af2a2abc26a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 22:16:12 2018 -0500
+
+ [morx/kerx] Limit range to subtable when sanitizing
+
+ src/hb-aat-layout-kerx-table.hh | 2 ++
+ src/hb-aat-layout-morx-table.hh | 2 ++
+ 2 files changed, 4 insertions(+)
+
+commit a9fe787a11fc391d9a43a4ea19e6eb1c474199bd
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 22:12:36 2018 -0500
+
+ [sanitizer] Add reset_object(), make set_object() do bounds-check
+
+ Affects morx/kerx run-time only currently. Will adjust their
+ sanitize next.
+
+ src/hb-aat-layout-kerx-table.hh | 1 +
+ src/hb-aat-layout-morx-table.hh | 1 +
+ src/hb-machinery.hh | 30 +++++++++++++++++++-----------
+ 3 files changed, 21 insertions(+), 11 deletions(-)
+
+commit 2c8188bf599e351a4e0804d74612f9643b3d2443
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 22:02:19 2018 -0500
+
+ [kerx] Make sure subtables are non-zero-length
+
+ Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11400
+
+ src/hb-aat-layout-kerx-table.hh | 1 +
+ src/hb-aat-layout-morx-table.hh | 2 +-
+ ...z-testcase-minimized-hb-shape-fuzzer-5722888989048832 | Bin 0 ->
+ 3608 bytes
+ 3 files changed, 2 insertions(+), 1 deletion(-)
+
+commit a9e0bdc35dfcbead7d4b6fa249d60ebedd7d43ca
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 21:30:04 2018 -0500
+
+ [GSUB] Don't flush glyphset during recursion in closure()
+
+ See comment.
+
+ Supercedes https://github.com/harfbuzz/harfbuzz/pull/1401
+ Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11366
+
+ src/hb-ot-layout-gsub-table.hh | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+commit 8982830d3ec54f50cc951de9569520fafc735e75
+Author: Garret Rieger <grieger@google.com>
+Date: Mon Nov 19 13:00:24 2018 -0800
+
+ [subset] add fuzzer testcase.
+
+ ...z-testcase-minimized-hb-subset-fuzzer-5067936541179904 | Bin 0 ->
+ 172 bytes
+ 1 file changed, 0 insertions(+), 0 deletions(-)
+
+commit d0e81b2cc85d09d01905c5fc5b3382c25eaa3bb3
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 21:20:39 2018 -0500
+
+ [set] Rename
+
+ src/hb-set.hh | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+commit e866910579e9cdc5b1ffa2e401fd0c056d44ca6a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 18:07:59 2018 -0500
+
+ Enforce requiring null_size even if min_size is 0
+
+ This concludes null-size enforcement changes
+
+ src/hb-null.hh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 4d4fd64ff47da04a7008d410c92e8fb4ad970781
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 18:07:36 2018 -0500
+
+ Allow non-nullable OffsetTo<> to non-Null'able objects
+
+ src/hb-open-type.hh | 16 +++++++++++++++-
+ 1 file changed, 15 insertions(+), 1 deletion(-)
+
+commit fa9f585ec53bc7145d3bed1a4bd756d64dae1e55
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 17:56:51 2018 -0500
+
+ [glyf] Don't mark structs UNBOUNDED
+
+ See comments.
+
+ src/hb-ot-glyf-table.hh | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+commit f47a60a7543dbaf41086c25a1a22ae518d8b92a9
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 17:53:29 2018 -0500
+
+ Mark UnsizedArrayOf<> as UNBOUNDED
+
+ Since min_size is 0, Null() still accepts this type.
+
+ src/hb-open-type.hh | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+commit 199a0f7b41b691e371487fd569c0d0146da3c3f3
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 17:31:07 2018 -0500
+
+ [ot-shape] Simplify logic
+
+ src/hb-ot-shape.cc | 9 ++++++---
+ 1 file changed, 6 insertions(+), 3 deletions(-)
+
+commit 014e4980ed9c8c473001abdb3a44121eb73fd50d
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 16:21:49 2018 -0500
+
+ Move
+
+ src/hb-ot-shape.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 62890dee18b88865a2014fb6a1322c1c9218bd49
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 16:20:29 2018 -0500
+
+ [aat] Zero mark advances if decided so even if there's cross-kerning
+
+ Cross-kerning can only take care of positioning vertically.
+ It doesn't
+ adjust mark advance...
+
+ src/hb-ot-shape.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit a201fa74cd67f36a402a5c8093889c9d793e9fd5
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 15:52:29 2018 -0500
+
+ [aat] Tweak fallback positioning logic when applying morx
+
+ Such that for Indic-like scripts (eg. Khmer), we don't do any
+ fallback mark
+ advance-zeroing / positioning, but we do for Latin, etc. Reuses
+ preferences
+ of our script-specific OpenType shapers for those.
+
+ Fixes regression: https://github.com/harfbuzz/harfbuzz/issues/1393
+ Which means, fixes again:
+ https://github.com/harfbuzz/harfbuzz/issues/1264
+ While not regressing: https://github.com/harfbuzz/harfbuzz/issues/1357
+
+ src/hb-ot-shape.cc | 38 +++++++++++++++++++++++---------------
+ src/hb-ot-shape.hh | 3 +++
+ 2 files changed, 26 insertions(+), 15 deletions(-)
+
+commit fa0bd8964d110c168a918bc331dcd350c3fed8c1
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 14:46:39 2018 -0500
+
+ [myanmar] Minor move
+
+ src/hb-ot-shape-complex.hh | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+commit 7dc561984bdb1f29f09ae0793195b5fbf772522b
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 14:45:46 2018 -0500
+
+ [myanmar] If there's no GSUB table, pick myanmar shaper
+
+ Needed for morx+kern mark-zeroing interaction. All other scripts
+ work this way.
+
+ src/hb-ot-shape-complex.hh | 16 +++++++++++++---
+ 1 file changed, 13 insertions(+), 3 deletions(-)
+
+commit 25f52f58c20715cc0dee2dd2885669078a128b08
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 14:41:01 2018 -0500
+
+ [myanmar] Remove myanmar_old shaper
+
+ Over time it has become the same as default shaper. So, remove.
+
+ src/hb-ot-shape-complex-myanmar.cc | 21 ---------------------
+ src/hb-ot-shape-complex.hh | 4 +---
+ 2 files changed, 1 insertion(+), 24 deletions(-)
+
+commit eeed802b1d0f932c61a088d3e0156ae70645b9e2
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:53:36 2018 -0500
+
+ Fix spurious gcc warnings
+
+ ../../src/hb-null.hh:53:39: warning: enum constant in boolean context
+ [-Wint-in-bool-context]
+
+ src/hb-null.hh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit b96ecb9971a9ad089a631d0139f05ae9d880fc55
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:49:12 2018 -0500
+
+ More
+
+ This makes more of the gcc spurious warning:
+
+ ../../src/hb-null.hh:53:39: warning: enum constant in boolean context
+ [-Wint-in-bool-context]
+
+ But not going to let that defeat correct code. Type to switch
+ to clang
+ as my main compiler...
+
+ src/hb-blob.hh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 2737aa81e5aee721e868bf0c72f19c0245c721fe
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:44:27 2018 -0500
+
+ Fix up recent change
+
+ Fixes https://github.com/harfbuzz/harfbuzz/issues/1300
+
+ src/hb-null.hh | 12 +++++++++---
+ src/hb-open-type.hh | 5 -----
+ src/hb-ot-glyf-table.hh | 4 ++--
+ 3 files changed, 11 insertions(+), 10 deletions(-)
+
+commit fffea5aff7a631eedd13c38c1fb7ea4f5f950930
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:25:34 2018 -0500
+
+ Minor
+
+ src/hb-open-type.hh | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+commit 209b58ef731f102b92179ed76551e2fd6b5ed075
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:22:33 2018 -0500
+
+ Minor
+
+ src/hb-ot-kern-table.hh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 3b9fd176e83bbebc4d0b5fc967c15b08fdef7015
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:18:55 2018 -0500
+
+ Disallow taking Null() of unbounded structs
+
+ Not sure I've marked all such structs. To be done as we discover.
+
+ Fixes https://github.com/harfbuzz/harfbuzz/issues/1300
+
+ src/hb-aat-layout-common.hh | 2 +-
+ src/hb-machinery.hh | 4 ++++
+ src/hb-ot-kern-table.hh | 2 +-
+ src/hb-ot-var-fvar-table.hh | 31 ++++++++++++++++---------------
+ 4 files changed, 22 insertions(+), 17 deletions(-)
+
+commit f2b91d6510face95008151bb0d25837723536f9f
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:10:22 2018 -0500
+
+ Use Type::null_size for our structs in Null(), sizeof() for other
+ types
+
+ src/hb-null.hh | 17 +++++++++++++++--
+ 1 file changed, 15 insertions(+), 2 deletions(-)
+
+commit 7dd945a8764cbbf76f686fd9387918b63f7d2fb4
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 01:05:02 2018 -0500
+
+ One more time..
+
+ src/hb-machinery.hh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit d062ad10de6c63d94676660b76526a160cf4299e
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 00:39:14 2018 -0500
+
+ Fix bots happy again, hopefully
+
+ So, our fallback static_assert cannot be had more than once per line
+ of source.
+
+ src/hb-machinery.hh | 16 +++++++---------
+ 1 file changed, 7 insertions(+), 9 deletions(-)
+
+commit fb10c021c8a32f8dc054f008caf86af82667e109
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Thu Nov 22 00:21:49 2018 -0500
+
+ Revert alignof() == 1 check
+
+ Bots not happy with using "this" inside assertion...
+
+ This reverts 2656644887e77a9d814bb12374af3c26b42fd935
+
+ src/hb-machinery.hh | 12 ++++--------
+ 1 file changed, 4 insertions(+), 8 deletions(-)
+
+commit 8d778877b88155dec1808a994416ead0b3d98ae7
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 23:46:09 2018 -0500
+
+ ..
+
+ src/hb-machinery.hh | 8 ++++++--
+ src/hb-null.hh | 4 ++--
+ 2 files changed, 8 insertions(+), 4 deletions(-)
+
+commit 8cfeed99486e87c3217dc141bc24b7768a460f32
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 23:42:31 2018 -0500
+
+ Minor
+
+ src/hb-machinery.hh | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit e5d954a2fb0c390ea67e83763e3c3a47caa2eb50
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 23:30:50 2018 -0500
+
+ Minor
+
+ src/hb-machinery.hh | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit e987059c618e03d2346c31ed64429d67ce0e367a
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 23:25:06 2018 -0500
+
+ Minor
+
+ src/hb-machinery.hh | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+commit a2b6d308a40d737f54a79f00bc7ace226bad5aaf
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 23:23:49 2018 -0500
+
+ Remove DEFINE_SIZE_ARRAY2
+
+ src/hb-machinery.hh | 6 ------
+ src/hb-ot-layout-common.hh | 8 ++++----
+ src/hb-ot-post-table.hh | 6 +++---
+ 3 files changed, 7 insertions(+), 13 deletions(-)
+
+commit 2656644887e77a9d814bb12374af3c26b42fd935
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 23:23:21 2018 -0500
+
+ Check alignof() structs are 1
+
+ src/hb-machinery.hh | 16 +++++++++++-----
+ 1 file changed, 11 insertions(+), 5 deletions(-)
+
+commit 6321fdf7040ce48e3de8d34fdcc57caa6433cb66
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 23:19:00 2018 -0500
+
+ Whitespace
+
+ src/hb-machinery.hh | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit f961c1eb88af0d178e5d3431b9d57bdf79669488
+Merge: ecdceea8 264439c6
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 17:27:27 2018 -0500
+
+ Merge pull request #1400 from harfbuzz/sharada-sandhi-mark
+
+ Test U+111C9 SHARADA SANDHI MARK
+
+commit 264439c6c308ac5f01c4ba4faf64daa2d642236a
+Author: David Corbett <corbett.dav@husky.neu.edu>
+Date: Wed Nov 21 16:33:45 2018 -0500
+
+ Test U+111C9 SHARADA SANDHI MARK
+
+ .../fonts/86cdd983c4e4c4d7f27dd405d6ceb7d4b9ed3d35.ttf | Bin 0 ->
+ 968 bytes
+ test/shaping/data/in-house/tests/use-syllable.tests | 1 +
+ 2 files changed, 1 insertion(+)
+
+commit ecdceea861952be003e1d435aa3282a4e3e200a9
+Merge: b89c7fd3 b3d5b0a5
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 16:12:32 2018 -0500
+
+ Merge pull request #1399 from harfbuzz/sharada-sandhi-mark
+
+ Fix USE categories for U+111C9 SHARADA SANDHI MARK
+
+commit b89c7fd3dc505a958dd4b6acec0e0f8e57224fd8
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Wed Nov 21 12:32:48 2018 -0500
+
+ Allow defining HB_USE_ATEXIT to 0
+
+ That's better use of that value than requiring extra macro
+ HB_NO_ATEXIT
+
+ src/hb-common.cc | 10 +++++-----
+ src/hb-ft.cc | 12 ++++++------
+ src/hb-glib.cc | 6 +++---
+ src/hb-icu.cc | 6 +++---
+ src/hb-ot-font.cc | 6 +++---
+ src/hb-shape.cc | 6 +++---
+ src/hb-shaper.cc | 6 +++---
+ src/hb-ucdn.cc | 6 +++---
+ src/hb-uniscribe.cc | 4 ++--
+ src/hb.hh | 5 ++++-
+ 10 files changed, 35 insertions(+), 32 deletions(-)
+
+commit b3d5b0a5d92115ca672b8103999ab7ac88e39a4a
+Author: David Corbett <corbett.dav@husky.neu.edu>
+Date: Wed Nov 21 11:35:44 2018 -0500
+
+ Fix USE categories for U+111C9 SHARADA SANDHI MARK
+
+ src/gen-use-table.py | 7 ++++++-
+ src/hb-ot-shape-complex-use-table.cc | 2 +-
+ 2 files changed, 7 insertions(+), 2 deletions(-)
+
+commit f48bb9a3939067f24a81007e642caaac77cc7167
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 20:40:55 2018 -0500
+
+ [var] Deprecated axis enumeration API and add new version
+
+ New version has axis flags.
+
+ New API:
+ +hb_ot_var_axis_info_t
+ +hb_ot_var_find_axis_info()
+ +hb_ot_var_get_axis_infos()
+
+ Deprecated API:
+ -HB_OT_VAR_NO_AXIS_INDEX
+ -hb_ot_var_axis_t
+ -hb_ot_var_find_axis()
+ -hb_ot_var_get_axes()
+
+ docs/harfbuzz-sections.txt | 14 +++---
+ src/hb-deprecated.h | 37 +++++++++++++++
+ src/hb-ot-var-fvar-table.hh | 112
+ ++++++++++++++++++++++++++++++++------------
+ src/hb-ot-var.cc | 43 ++++++++++++++---
+ src/hb-ot-var.h | 61 ++++++++++++------------
+ test/api/test-ot-face.c | 2 +-
+ 6 files changed, 192 insertions(+), 77 deletions(-)
+
+commit b2d803cef6974519d5892af2c9efeb8dfba87618
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 11:42:25 2018 -0500
+
+ Remove newly-added -hb_ot_var_axis_get_flags()
+
+ src/hb-ot-var-fvar-table.hh | 6 ------
+ src/hb-ot-var.cc | 12 ------------
+ src/hb-ot-var.h | 4 ----
+ 3 files changed, 22 deletions(-)
+
+commit 736897d7a1410fd281fbcedc084b85bf4ba1410c
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 11:40:43 2018 -0500
+
+ [var] Make sure hb_ot_var_axis_flags_t is int-sized
+
+ src/hb-ot-var.h | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+commit eab5d15f6156e771cb606b760dd170b96c5cd398
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 11:33:33 2018 -0500
+
+ [var] Move code
+
+ src/hb-ot-var.h | 27 ++++++++++++++-------------
+ 1 file changed, 14 insertions(+), 13 deletions(-)
+
+commit 064f703c7ac5a28803a8221720e922ea6dbd2505
+Merge: be1828da 82951182
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 16:29:30 2018 -0500
+
+ Merge pull request #1397 from harfbuzz/small-emoji-table
+
+ Shrink the emoji table by merging adjacent ranges
+
+commit 82951182799772a642d32195dd87e6f0c116f545
+Author: David Corbett <corbett.dav@husky.neu.edu>
+Date: Tue Nov 20 15:41:45 2018 -0500
+
+ Shrink the emoji table by merging adjacent ranges
+
+ src/gen-emoji-table.py | 13 +--
+ src/hb-unicode-emoji-table.hh | 189
+ ++++--------------------------------------
+ 2 files changed, 23 insertions(+), 179 deletions(-)
+
+commit be1828daaa1e1a72d971aed8d34fff54688d0f41
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 11:16:23 2018 -0500
+
+ [var] Fix type of coords returned
+
+ Ouch. Wonder how none of the bots caught the float->int truncation.
+
+ src/hb-ot-var-fvar-table.hh | 2 +-
+ src/hb-ot-var.cc | 2 +-
+ src/hb-ot-var.h | 2 +-
+ 3 files changed, 3 insertions(+), 3 deletions(-)
+
+commit 8f3ee17ae468950a34439785d2e6ac4182efb65c
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 01:38:23 2018 -0500
+
+ [travis] Update Coverity token
+
+ .travis.yml | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit f9552362986efd0973b2637d21b787edbc8479f2
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 01:21:36 2018 -0500
+
+ Add codecov.io badge
+
+ README | 13 +++++++------
+ 1 file changed, 7 insertions(+), 6 deletions(-)
+
+commit 831ba74382e35f110006539f22bebce4d57c8502
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 01:16:08 2018 -0500
+
+ Fix Codacy "issues"
+
+ src/test-name-table.cc | 2 +-
+ src/test-ot-color.cc | 14 +++++++-------
+ test/api/test-buffer.c | 5 +++--
+ test/api/test-object.c | 2 +-
+ test/api/test-ot-name.c | 2 +-
+ 5 files changed, 13 insertions(+), 12 deletions(-)
+
+commit c49e43c1ffee0e9664da6202ace493d932b725a1
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 01:06:50 2018 -0500
+
+ [travis] Another push for codecov.io after setting token
+
+ .travis.yml | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 96b24c5124a085b7601215360eed847ce5302699
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Tue Nov 20 01:03:42 2018 -0500
+
+ [travis] Add codecov.io
+
+ .travis.yml | 1 +
+ 1 file changed, 1 insertion(+)
+
+commit 3c7792ca326abfb989285f794d6ee71ad9f6bf89
+Author: David Corbett <corbett.dav@husky.neu.edu>
+Date: Sat Oct 20 15:02:26 2018 -0400
+
+ [use] Fix reordering
+
+ Fixes #1235.
+
+ src/hb-ot-shape-complex-use.cc | 48
+ ++++++++++++++-------
+ src/hb.hh | 2 +
+ .../4afb0e8b9a86bb9bd73a1247de4e33fbe3c1fd93.ttf | Bin 0 -> 1824 bytes
+ test/shaping/data/in-house/tests/use.tests | 3 ++
+ 4 files changed, 38 insertions(+), 15 deletions(-)
+
+commit 587d49fc657c10c8a20f2409a04d72bf80bb361e
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 14:27:19 2018 -0500
+
+ [fvar] Add named-instance API
+
+ Fixes https://github.com/harfbuzz/harfbuzz/issues/1241
+
+ docs/harfbuzz-sections.txt | 4 ++++
+ src/hb-ot-var-fvar-table.hh | 55
+ ++++++++++++++++++++++++++++++++++++++++++---
+ src/hb-ot-var.cc | 33 +++++++++++++++++++++++++++
+ src/hb-ot-var.h | 32 ++++++++++++++++++++++++++
+ 4 files changed, 121 insertions(+), 3 deletions(-)
+
+commit 46c0da820fc313bad8afaf019d2cd9065fa5f514
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 13:32:48 2018 -0500
+
+ Fix build
+
+ src/hb-dsalgs.hh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 56c9238d3da8c034336cf80ba37e03e33c493718
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 13:09:53 2018 -0500
+
+ [fvar] Rewrite sanitize
+
+ src/hb-ot-var-fvar-table.hh | 8 +++-----
+ 1 file changed, 3 insertions(+), 5 deletions(-)
+
+commit 4a6a692e3ea4fab632a0162c6d513dc151054d8f
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 13:04:43 2018 -0500
+
+ [fvar] Use hb_array_t for axes
+
+ src/hb-dsalgs.hh | 6 ++++++
+ src/hb-ot-var-fvar-table.hh | 14 ++++----------
+ 2 files changed, 10 insertions(+), 10 deletions(-)
+
+commit e0097396010c40cf62641cd12ceb12dd5d79c9c7
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 12:53:53 2018 -0500
+
+ [fvar] Minor
+
+ src/hb-ot-var-fvar-table.hh | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
+commit 1a2eb108b857de9c5e84cc5de0c12c7657e04498
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 12:36:56 2018 -0500
+
+ [ot-var] Add hb_ot_var_axis_get_flags()
+
+ Part of https://github.com/harfbuzz/harfbuzz/issues/1241
+
+ New API:
+ +hb_ot_var_axis_flags_t
+ +hb_ot_var_axis_get_flags
+
+ docs/harfbuzz-sections.txt | 2 ++
+ src/hb-buffer.h | 2 ++
+ src/hb-ot-var-fvar-table.hh | 9 +++++++++
+ src/hb-ot-var.cc | 12 ++++++++++++
+ src/hb-ot-var.h | 13 +++++++++++++
+ 5 files changed, 38 insertions(+)
+
+commit bd6b2ba1d3910cc259db7abeb6c9bd7ed9494857
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 11:34:56 2018 -0500
+
+ [ot-var] Add flags
+
+ Unfortunate that we don't have room in hb_ot_var_axis_t to expose
+ flags :(.
+
+ src/hb-ot-var-fvar-table.hh | 9 +++++++--
+ 1 file changed, 7 insertions(+), 2 deletions(-)
+
+commit c076c7b85ce4d069ae8b2b04143aca4c4f052ae9
+Author: Behdad Esfahbod <behdad@behdad.org>
+Date: Mon Nov 19 11:30:40 2018 -0500
+
+ [ot-var] Use hb_ot_name_id_t
+
+ src/hb-ot-var.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
commit e3a1a8350a6a7933b0a100194985f4425ab9de19
Author: Behdad Esfahbod <behdad@behdad.org>
Date: Fri Nov 16 16:53:25 2018 -0800
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/NEWS b/Build/source/libs/harfbuzz/harfbuzz-src/NEWS
index 9bfe99a2d68..ff4f6e29df2 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/NEWS
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/NEWS
@@ -1,3 +1,38 @@
+Overview of changes leading to 2.2.0
+Thursday, November 29, 2018
+====================================
+- Misc shaping bug fixes.
+- Add font variations named-instance API.
+- Deprecate font variations axis enumeration API and add replacement.
+- AAT shaping improvements:
+ o Fixed 'kern' table Format 2 implementation.
+ o Implement 'feat' table API for feature detection.
+ o Blacklist 'GSUB' table of fonts from 'MUTF' foundry that also have 'morx'.
+
+New API:
++hb_aat_layout_feature_type_t
++hb_aat_layout_feature_selector_t
++hb_aat_layout_get_feature_types()
++hb_aat_layout_feature_type_get_name_id
++hb_aat_layout_feature_selector_info_t
++HB_AAT_LAYOUT_NO_SELECTOR_INDEX
++hb_aat_layout_feature_type_get_selector_infos()
++hb_ot_var_axis_flags_t
++hb_ot_var_axis_info_t
++hb_ot_var_get_axis_infos()
++hb_ot_var_find_axis_info()
++hb_ot_var_get_named_instance_count()
++hb_ot_var_named_instance_get_subfamily_name_id()
++hb_ot_var_named_instance_get_postscript_name_id()
++hb_ot_var_named_instance_get_design_coords()
+
+Deprecated API:
++HB_OT_VAR_NO_AXIS_INDEX
++hb_ot_var_axis_t
++hb_ot_var_get_axes()
++hb_ot_var_find_axis()
+
+
Overview of changes leading to 2.1.3
Friday, November 16, 2018
====================================
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/README b/Build/source/libs/harfbuzz/harfbuzz-src/README
index 55775c8bf91..e50f8f06e5d 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/README
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/README
@@ -1,9 +1,10 @@
-[![Build Status](https://travis-ci.org/harfbuzz/harfbuzz.svg)](https://travis-ci.org/harfbuzz/harfbuzz)
-[![Build status](https://ci.appveyor.com/api/projects/status/0t0flrxpstj9lb9w?svg=true)](https://ci.appveyor.com/project/harfbuzz/harfbuzz)
-[![CircleCI](https://circleci.com/gh/harfbuzz/harfbuzz.svg?style=svg)](https://circleci.com/gh/harfbuzz/harfbuzz)
-[![Coverity](https://img.shields.io/coverity/scan/5450.svg)](https://scan.coverity.com/projects/behdad-harfbuzz)
-[![Codacy Badge](https://api.codacy.com/project/badge/Grade/f17f1708783c447488bc8dd317150eaa)](https://app.codacy.com/app/behdad/harfbuzz)
-[![Coverage Status](https://img.shields.io/coveralls/harfbuzz/harfbuzz.svg)](https://coveralls.io/r/harfbuzz/harfbuzz)
+[![Travis Build Status](https://travis-ci.org/harfbuzz/harfbuzz.svg)](https://travis-ci.org/harfbuzz/harfbuzz)
+[![AppVeyor Build Status](https://ci.appveyor.com/api/projects/status/0t0flrxpstj9lb9w?svg=true)](https://ci.appveyor.com/project/harfbuzz/harfbuzz)
+[![CircleCI Build Status](https://circleci.com/gh/harfbuzz/harfbuzz.svg?style=svg)](https://circleci.com/gh/harfbuzz/harfbuzz)
+[![Coverity Code Health](https://img.shields.io/coverity/scan/5450.svg)](https://scan.coverity.com/projects/behdad-harfbuzz)
+[![Codacy Code Health](https://api.codacy.com/project/badge/Grade/f17f1708783c447488bc8dd317150eaa)](https://app.codacy.com/app/behdad/harfbuzz)
+[![Codecov Code Coverage](https://codecov.io/gh/harfbuzz/harfbuzz/branch/master/graph/badge.svg)](https://codecov.io/gh/harfbuzz/harfbuzz)
+[![Coverals Code Coverage](https://img.shields.io/coveralls/harfbuzz/harfbuzz.svg)](https://coveralls.io/r/harfbuzz/harfbuzz)
[ABI Tracker](http://abi-laboratory.pro/tracker/timeline/harfbuzz/)
This is HarfBuzz, a text shaping library.
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/configure.ac b/Build/source/libs/harfbuzz/harfbuzz-src/configure.ac
index 95ab48f80ef..0649464386d 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/configure.ac
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/configure.ac
@@ -1,6 +1,6 @@
AC_PREREQ([2.64])
AC_INIT([HarfBuzz],
- [2.1.3],
+ [2.2.0],
[https://github.com/harfbuzz/harfbuzz/issues/new],
[harfbuzz],
[http://harfbuzz.org/])
@@ -508,6 +508,7 @@ test/api/Makefile
test/fuzzing/Makefile
test/shaping/Makefile
test/shaping/data/Makefile
+test/shaping/data/aots/Makefile
test/shaping/data/in-house/Makefile
test/shaping/data/text-rendering-tests/Makefile
test/subset/Makefile
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.am b/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.am
index b3cc42f3f84..c726cf2a660 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.am
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.am
@@ -424,6 +424,8 @@ HarfBuzz_0_0_gir_CFLAGS = \
-DHB_H_IN \
-DHB_OT_H \
-DHB_OT_H_IN \
+ -DHB_AAT_H \
+ -DHB_AAT_H_IN \
-DHB_GOBJECT_H \
-DHB_GOBJECT_H_IN \
-DHB_EXTERN= \
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.sources b/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.sources
index 3dcd771f4b5..ba90ef022ef 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.sources
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/Makefile.sources
@@ -181,6 +181,8 @@ HB_OT_RAGEL_sources = \
$(NULL)
HB_OT_headers = \
+ hb-aat.h \
+ hb-aat-layout.h \
hb-ot.h \
hb-ot-color.h \
hb-ot-font.h \
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-emoji-table.py b/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-emoji-table.py
index 278e0b2d4a7..9afe747dd7d 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-emoji-table.py
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-emoji-table.py
@@ -12,7 +12,7 @@ if len (sys.argv) != 2:
f = open(sys.argv[1])
header = [f.readline () for _ in range(10)]
-sets = OrderedDict()
+ranges = OrderedDict()
for line in f.readlines():
line = line.strip()
if not line or line[0] == '#':
@@ -25,9 +25,12 @@ for line in f.readlines():
else:
start = end = rang[0]
- if typ not in sets:
- sets[typ] = set()
- sets[typ].add((start, end))
+ if typ not in ranges:
+ ranges[typ] = []
+ if ranges[typ] and ranges[typ][-1][1] == start - 1:
+ ranges[typ][-1] = (ranges[typ][-1][0], end)
+ else:
+ ranges[typ].append((start, end))
@@ -49,7 +52,7 @@ print ()
print ('#include "hb-unicode.hh"')
print ()
-for typ,s in sets.items():
+for typ,s in ranges.items():
if typ != "Extended_Pictographic": continue
print()
print("static const struct hb_unicode_range_t _hb_unicode_emoji_%s_table[] =" % typ)
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-use-table.py b/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-use-table.py
index a8a7a23261b..099f6a18518 100755
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-use-table.py
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/gen-use-table.py
@@ -50,6 +50,8 @@ data[0][0x20F0] = defaults[0]
# TODO https://github.com/roozbehp/unicode-data/issues/9
data[0][0x11C44] = 'Consonant_Placeholder'
data[0][0x11C45] = 'Consonant_Placeholder'
+# TODO https://github.com/harfbuzz/harfbuzz/pull/1399
+data[0][0x111C8] = 'Consonant_Placeholder'
for u in range (0xFE00, 0xFE0F + 1):
data[0][u] = defaults[0]
@@ -168,7 +170,7 @@ def is_BASE(U, UISC, UGC):
def is_BASE_IND(U, UISC, UGC):
#SPEC-DRAFT return (UISC in [Consonant_Dead, Modifying_Letter] or UGC == Po)
return (UISC in [Consonant_Dead, Modifying_Letter] or
- (UGC == Po and not U in [0x104B, 0x104E, 0x2022, 0x11A3F, 0x11A45, 0x11C44, 0x11C45]) or
+ (UGC == Po and not U in [0x104B, 0x104E, 0x2022, 0x111C8, 0x11A3F, 0x11A45, 0x11C44, 0x11C45]) or
False # SPEC-DRAFT-OUTDATED! U == 0x002D
)
def is_BASE_NUM(U, UISC, UGC):
@@ -354,6 +356,9 @@ def map_to_use(data):
# TODO: https://github.com/harfbuzz/harfbuzz/issues/1105
if U == 0x11134: UISC = Gemination_Mark
+ # TODO: https://github.com/harfbuzz/harfbuzz/pull/1399
+ if U == 0x111C9: UISC = Consonant_Final
+
values = [k for k,v in items if v(U,UISC,UGC)]
assert len(values) == 1, "%s %s %s %s" % (hex(U), UISC, UGC, values)
USE = values[0]
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-common.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-common.hh
index 6572b26d86f..c0b0e3751f3 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-common.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-common.hh
@@ -69,13 +69,15 @@ struct LookupFormat0
UnsizedArrayOf<T>
arrayZ; /* Array of lookup values, indexed by glyph index. */
public:
- DEFINE_SIZE_ARRAY (2, arrayZ);
+ DEFINE_SIZE_UNBOUNDED (2);
};
template <typename T>
struct LookupSegmentSingle
{
+ enum { TerminationWordCount = 2 };
+
inline int cmp (hb_codepoint_t g) const {
return g < first ? -1 : g <= last ? 0 : +1 ;
}
@@ -134,6 +136,8 @@ struct LookupFormat2
template <typename T>
struct LookupSegmentArray
{
+ enum { TerminationWordCount = 2 };
+
inline const T* get_value (hb_codepoint_t glyph_id, const void *base) const
{
return first <= glyph_id && glyph_id <= last ? &(base+valuesZ)[glyph_id - first] : nullptr;
@@ -204,6 +208,8 @@ struct LookupFormat4
template <typename T>
struct LookupSingle
{
+ enum { TerminationWordCount = 1 };
+
inline int cmp (hb_codepoint_t g) const { return glyph.cmp (g); }
inline bool sanitize (hb_sanitize_context_t *c) const
@@ -357,6 +363,14 @@ struct Lookup
}
}
+ inline typename T::type get_class (hb_codepoint_t glyph_id,
+ unsigned int num_glyphs,
+ unsigned int outOfRange) const
+ {
+ const T *v = get_value (glyph_id, num_glyphs);
+ return v ? *v : outOfRange;
+ }
+
inline bool sanitize (hb_sanitize_context_t *c) const
{
TRACE_SANITIZE (this);
@@ -436,8 +450,10 @@ struct Entry
* which ensures that data has a simple sanitize(). To be determined
* if I need to remove that as well.
*
- * XXX Because we are a template, our DEFINE_SIZE_STATIC assertion
- * wouldn't be checked. */
+ * HOWEVER! Because we are a template, our DEFINE_SIZE_STATIC
+ * assertion wouldn't be checked, hence the line below. */
+ static_assert (T::static_size, "");
+
return_trace (c->check_struct (this));
}
@@ -472,7 +488,7 @@ struct StateTable
{
typedef typename Types::HBUINT HBUINT;
typedef typename Types::HBUSHORT HBUSHORT;
- typedef typename Types::ClassType ClassType;
+ typedef typename Types::ClassTypeNarrow ClassType;
enum State
{
@@ -630,6 +646,7 @@ struct StateTable
DEFINE_SIZE_STATIC (4 * sizeof (HBUINT));
};
+template <typename HBUCHAR>
struct ClassTable
{
inline unsigned int get_class (hb_codepoint_t glyph_id, unsigned int outOfRange) const
@@ -637,6 +654,12 @@ struct ClassTable
unsigned int i = glyph_id - firstGlyph;
return i >= classArray.len ? outOfRange : classArray.arrayZ[i];
}
+ inline unsigned int get_class (hb_codepoint_t glyph_id,
+ unsigned int num_glyphs HB_UNUSED,
+ unsigned int outOfRange) const
+ {
+ return get_class (glyph_id, outOfRange);
+ }
inline bool sanitize (hb_sanitize_context_t *c) const
{
TRACE_SANITIZE (this);
@@ -644,7 +667,7 @@ struct ClassTable
}
protected:
GlyphID firstGlyph; /* First glyph index included in the trimmed array. */
- ArrayOf<HBUINT8> classArray; /* The class codes (indexed by glyph index minus
+ ArrayOf<HBUCHAR> classArray; /* The class codes (indexed by glyph index minus
* firstGlyph). */
public:
DEFINE_SIZE_ARRAY (4, classArray);
@@ -655,15 +678,9 @@ struct ObsoleteTypes
static const bool extended = false;
typedef HBUINT16 HBUINT;
typedef HBUINT8 HBUSHORT;
- struct ClassType : ClassTable
- {
- inline unsigned int get_class (hb_codepoint_t glyph_id,
- unsigned int num_glyphs HB_UNUSED,
- unsigned int outOfRange) const
- {
- return ClassTable::get_class (glyph_id, outOfRange);
- }
- };
+ typedef ClassTable<HBUINT8> ClassTypeNarrow;
+ typedef ClassTable<HBUINT16> ClassTypeWide;
+
template <typename T>
static inline unsigned int offsetToIndex (unsigned int offset,
const void *base,
@@ -672,6 +689,13 @@ struct ObsoleteTypes
return (offset - ((const char *) array - (const char *) base)) / sizeof (T);
}
template <typename T>
+ static inline unsigned int byteOffsetToIndex (unsigned int offset,
+ const void *base,
+ const T *array)
+ {
+ return offsetToIndex (offset, base, array);
+ }
+ template <typename T>
static inline unsigned int wordOffsetToIndex (unsigned int offset,
const void *base,
const T *array)
@@ -684,16 +708,9 @@ struct ExtendedTypes
static const bool extended = true;
typedef HBUINT32 HBUINT;
typedef HBUINT16 HBUSHORT;
- struct ClassType : Lookup<HBUINT16>
- {
- inline unsigned int get_class (hb_codepoint_t glyph_id,
- unsigned int num_glyphs,
- unsigned int outOfRange) const
- {
- const HBUINT16 *v = get_value (glyph_id, num_glyphs);
- return v ? *v : outOfRange;
- }
- };
+ typedef Lookup<HBUINT16> ClassTypeNarrow;
+ typedef Lookup<HBUINT16> ClassTypeWide;
+
template <typename T>
static inline unsigned int offsetToIndex (unsigned int offset,
const void *base,
@@ -702,6 +719,13 @@ struct ExtendedTypes
return offset;
}
template <typename T>
+ static inline unsigned int byteOffsetToIndex (unsigned int offset,
+ const void *base,
+ const T *array)
+ {
+ return offset / 2;
+ }
+ template <typename T>
static inline unsigned int wordOffsetToIndex (unsigned int offset,
const void *base,
const T *array)
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-feat-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-feat-table.hh
index 87ab4abd3f0..4e63ec8e855 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-feat-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-feat-table.hh
@@ -39,6 +39,27 @@ namespace AAT {
struct SettingName
{
+ friend struct FeatureName;
+
+ int cmp (hb_aat_layout_feature_selector_t key) const
+ { return (int) key - (int) setting; }
+
+ inline hb_aat_layout_feature_selector_t get_selector (void) const
+ { return (hb_aat_layout_feature_selector_t) (unsigned) setting; }
+
+ inline void get_info (hb_aat_layout_feature_selector_info_t *s,
+ hb_aat_layout_feature_selector_t default_selector) const
+ {
+ s->name_id = nameIndex;
+
+ s->enable = (hb_aat_layout_feature_selector_t) (unsigned int) setting;
+ s->disable = default_selector == HB_AAT_LAYOUT_FEATURE_SELECTOR_INVALID ?
+ (hb_aat_layout_feature_selector_t) (s->enable + 1) :
+ default_selector;
+
+ s->reserved = 0;
+ }
+
inline bool sanitize (hb_sanitize_context_t *c) const
{
TRACE_SANITIZE (this);
@@ -51,35 +72,76 @@ struct SettingName
public:
DEFINE_SIZE_STATIC (4);
};
+DECLARE_NULL_NAMESPACE_BYTES (AAT, SettingName);
+
+struct feat;
struct FeatureName
{
+ int cmp (hb_aat_layout_feature_type_t key) const
+ { return (int) key - (int) feature; }
+
enum {
- Exclusive = 0x8000, /* If set, the feature settings are mutually exclusive. */
- NotDefault = 0x4000, /* If clear, then the setting with an index of 0 in
+ Exclusive = 0x8000, /* If set, the feature settings are mutually exclusive. */
+ NotDefault = 0x4000, /* If clear, then the setting with an index of 0 in
* the setting name array for this feature should
* be taken as the default for the feature
* (if one is required). If set, then bits 0-15 of this
* featureFlags field contain the index of the setting
* which is to be taken as the default. */
- IndexMask = 0x00FF /* If bits 30 and 31 are set, then these sixteen bits
+ IndexMask = 0x00FF /* If bits 30 and 31 are set, then these sixteen bits
* indicate the index of the setting in the setting name
* array for this feature which should be taken
* as the default. */
};
+ inline unsigned int get_selector_infos (unsigned int start_offset,
+ unsigned int *selectors_count, /* IN/OUT. May be NULL. */
+ hb_aat_layout_feature_selector_info_t *selectors, /* OUT. May be NULL. */
+ unsigned int *pdefault_index, /* OUT. May be NULL. */
+ const void *base) const
+ {
+ hb_array_t< const SettingName> settings_table = (base+settingTableZ).as_array (nSettings);
+
+ static_assert (Index::NOT_FOUND_INDEX == HB_AAT_LAYOUT_NO_SELECTOR_INDEX, "");
+
+ hb_aat_layout_feature_selector_t default_selector = HB_AAT_LAYOUT_FEATURE_SELECTOR_INVALID;
+ unsigned int default_index = Index::NOT_FOUND_INDEX;
+ if (featureFlags & Exclusive)
+ {
+ default_index = (featureFlags & NotDefault) ? featureFlags & IndexMask : 0;
+ default_selector = settings_table[default_index].get_selector ();
+ }
+ if (pdefault_index)
+ *pdefault_index = default_index;
+
+ if (selectors_count)
+ {
+ hb_array_t<const SettingName> arr = settings_table.sub_array (start_offset, selectors_count);
+ unsigned int count = arr.len;
+ for (unsigned int i = 0; i < count; i++)
+ settings_table[start_offset + i].get_info (&selectors[i], default_selector);
+ }
+ return settings_table.len;
+ }
+
+ inline hb_aat_layout_feature_type_t get_feature_type () const
+ { return (hb_aat_layout_feature_type_t) (unsigned int) feature; }
+
+ inline hb_ot_name_id_t get_feature_name_id () const { return nameIndex; }
+
inline bool sanitize (hb_sanitize_context_t *c, const void *base) const
{
TRACE_SANITIZE (this);
return_trace (likely (c->check_struct (this) &&
- (base+settingTable).sanitize (c, nSettings)));
+ (base+settingTableZ).sanitize (c, nSettings)));
}
protected:
HBUINT16 feature; /* Feature type. */
HBUINT16 nSettings; /* The number of records in the setting name array. */
LOffsetTo<UnsizedArrayOf<SettingName>, false>
- settingTable; /* Offset in bytes from the beginning of this table to
+ settingTableZ; /* Offset in bytes from the beginning of this table to
* this feature's setting name array. The actual type of
* record this offset refers to will depend on the
* exclusivity value, as described below. */
@@ -95,11 +157,47 @@ struct feat
{
static const hb_tag_t tableTag = HB_AAT_TAG_feat;
+ inline bool has_data (void) const { return version.to_int (); }
+
+ inline unsigned int get_feature_types (unsigned int start_offset,
+ unsigned int *count,
+ hb_aat_layout_feature_type_t *features) const
+ {
+ unsigned int feature_count = featureNameCount;
+ if (count && *count)
+ {
+ unsigned int len = MIN (feature_count - start_offset, *count);
+ for (unsigned int i = 0; i < len; i++)
+ features[i] = namesZ[i + start_offset].get_feature_type ();
+ *count = len;
+ }
+ return featureNameCount;
+ }
+
+ inline const FeatureName& get_feature (hb_aat_layout_feature_type_t feature_type) const
+ {
+ return namesZ.bsearch (featureNameCount, feature_type);
+ }
+
+ inline hb_ot_name_id_t get_feature_name_id (hb_aat_layout_feature_type_t feature) const
+ { return get_feature (feature).get_feature_name_id (); }
+
+ inline unsigned int get_selector_infos (hb_aat_layout_feature_type_t feature_type,
+ unsigned int start_offset,
+ unsigned int *selectors_count, /* IN/OUT. May be NULL. */
+ hb_aat_layout_feature_selector_info_t *selectors, /* OUT. May be NULL. */
+ unsigned int *default_index /* OUT. May be NULL. */) const
+ {
+ return get_feature (feature_type).get_selector_infos (start_offset, selectors_count, selectors,
+ default_index, this);
+ }
+
inline bool sanitize (hb_sanitize_context_t *c) const
{
TRACE_SANITIZE (this);
return_trace (likely (c->check_struct (this) &&
- names.sanitize (c, featureNameCount, this)));
+ version.major == 1 &&
+ namesZ.sanitize (c, featureNameCount, this)));
}
protected:
@@ -109,8 +207,8 @@ struct feat
/* The number of entries in the feature name array. */
HBUINT16 reserved1; /* Reserved (set to zero). */
HBUINT32 reserved2; /* Reserved (set to zero). */
- UnsizedArrayOf<FeatureName>
- names; /* The feature name array. */
+ SortedUnsizedArrayOf<FeatureName>
+ namesZ; /* The feature name array. */
public:
DEFINE_SIZE_STATIC (24);
};
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-kerx-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-kerx-table.hh
index f075a270a6b..7caf45d5dd1 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-kerx-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-kerx-table.hh
@@ -49,7 +49,7 @@ kerxTupleKern (int value,
const void *base,
hb_aat_apply_context_t *c)
{
- if (likely (!tupleCount)) return value;
+ if (likely (!tupleCount || !c)) return value;
unsigned int offset = value;
const FWORD *pv = &StructAtOffset<FWORD> (base, offset);
@@ -93,21 +93,11 @@ struct KernPair
template <typename KernSubTableHeader>
struct KerxSubTableFormat0
{
- inline int get_kerning (hb_codepoint_t left, hb_codepoint_t right) const
- {
- hb_glyph_pair_t pair = {left, right};
- int i = pairs.bsearch (pair);
- if (i == -1) return 0;
- return pairs[i].get_kerning ();
- }
-
inline int get_kerning (hb_codepoint_t left, hb_codepoint_t right,
- hb_aat_apply_context_t *c) const
+ hb_aat_apply_context_t *c = nullptr) const
{
hb_glyph_pair_t pair = {left, right};
- int i = pairs.bsearch (pair);
- if (i == -1) return 0;
- int v = pairs[i].get_kerning ();
+ int v = pairs.bsearch (pair).get_kerning ();
return kerxTupleKern (v, header.tuple_count (), this, c);
}
@@ -265,7 +255,7 @@ struct KerxSubTableFormat1
unsigned int tuple_count = MAX (1u, table->header.tuple_count ());
unsigned int kern_idx = Format1EntryT::kernActionIndex (entry);
- kern_idx = Types::offsetToIndex (kern_idx, &table->machine, kernAction.arrayZ);
+ kern_idx = Types::byteOffsetToIndex (kern_idx, &table->machine, kernAction.arrayZ);
const FWORD *actions = &kernAction[kern_idx];
if (!c->sanitizer.check_array (actions, depth, tuple_count))
{
@@ -402,9 +392,13 @@ struct KerxSubTableFormat2
unsigned int num_glyphs = c->sanitizer.get_num_glyphs ();
unsigned int l = (this+leftClassTable).get_class (left, num_glyphs, 0);
unsigned int r = (this+rightClassTable).get_class (right, num_glyphs, 0);
- unsigned int offset = l + r;
- const FWORD *v = &StructAtOffset<FWORD> (&(this+array), offset);
+
+ const UnsizedArrayOf<FWORD> &arrayZ = this+array;
+ unsigned int kern_idx = l + r;
+ kern_idx = Types::offsetToIndex (kern_idx, this, &arrayZ);
+ const FWORD *v = &arrayZ[kern_idx];
if (unlikely (!v->sanitize (&c->sanitizer))) return 0;
+
return kerxTupleKern (*v, header.tuple_count (), this, c);
}
@@ -447,19 +441,13 @@ struct KerxSubTableFormat2
c->check_range (this, array)));
}
- /* Note:
- * OT kern table specifies ClassTable as having 16-bit entries, whereas
- * AAT kern table specifies them as having 8bit entries.
- * I've not seen any fonts with this format in kern table.
- * We follow AAT. */
-
protected:
KernSubTableHeader header;
HBUINT rowWidth; /* The width, in bytes, of a row in the table. */
- OffsetTo<typename Types::ClassType, HBUINT, false>
+ OffsetTo<typename Types::ClassTypeWide, HBUINT, false>
leftClassTable; /* Offset from beginning of this subtable to
* left-hand class table. */
- OffsetTo<typename Types::ClassType, HBUINT, false>
+ OffsetTo<typename Types::ClassTypeWide, HBUINT, false>
rightClassTable;/* Offset from beginning of this subtable to
* right-hand class table. */
OffsetTo<UnsizedArrayOf<FWORD>, HBUINT, false>
@@ -812,6 +800,7 @@ struct KerxSubTable
{
TRACE_SANITIZE (this);
if (!u.header.sanitize (c) ||
+ u.header.length <= u.header.static_size ||
!c->check_range (this, u.header.length))
return_trace (false);
@@ -842,6 +831,21 @@ struct KerxTable
/* https://en.wikipedia.org/wiki/Curiously_recurring_template_pattern */
inline const T* thiz (void) const { return static_cast<const T *> (this); }
+ inline bool has_state_machine (void) const
+ {
+ typedef typename T::SubTable SubTable;
+
+ const SubTable *st = &thiz()->firstSubTable;
+ unsigned int count = thiz()->tableCount;
+ for (unsigned int i = 0; i < count; i++)
+ {
+ if (st->get_type () == 1)
+ return true;
+ st = &StructAfter<SubTable> (*st);
+ }
+ return false;
+ }
+
inline bool has_cross_stream (void) const
{
typedef typename T::SubTable SubTable;
@@ -920,9 +924,11 @@ struct KerxTable
if (reverse)
c->buffer->reverse ();
- c->sanitizer.set_object (*st);
-
- ret |= st->dispatch (c);
+ {
+ /* See comment in sanitize() for conditional here. */
+ hb_sanitize_with_object_t with (&c->sanitizer, i < count - 1 ? st : (const SubTable *) nullptr);
+ ret |= st->dispatch (c);
+ }
if (reverse)
c->buffer->reverse ();
@@ -951,8 +957,20 @@ struct KerxTable
unsigned int count = thiz()->tableCount;
for (unsigned int i = 0; i < count; i++)
{
+ if (unlikely (!st->u.header.sanitize (c)))
+ return_trace (false);
+ /* OpenType kern table has 2-byte subtable lengths. That's limiting.
+ * MS implementation also only supports one subtable, of format 0,
+ * anyway. Certain versions of some fonts, like Calibry, contain
+ * kern subtable that exceeds 64kb. Looks like, the subtable length
+ * is simply ignored. Which makes sense. It's only needed if you
+ * have multiple subtables. To handle such fonts, we just ignore
+ * the length for the last subtable. */
+ hb_sanitize_with_object_t with (c, i < count - 1 ? st : (const SubTable *) nullptr);
+
if (unlikely (!st->sanitize (c)))
return_trace (false);
+
st = &StructAfter<SubTable> (*st);
}
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-lcar-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-lcar-table.hh
index 43ac74f9c46..40d34f59bf0 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-lcar-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-lcar-table.hh
@@ -52,10 +52,10 @@ struct lcar
const OffsetTo<LigCaretClassEntry>* entry_offset = lookup.get_value (glyph,
font->face->get_num_glyphs ());
const LigCaretClassEntry& array = entry_offset ? this+*entry_offset : Null (LigCaretClassEntry);
- if (caret_count && *caret_count)
+ if (caret_count)
{
- const HBINT16 *arr = array.sub_array (start_offset, caret_count);
- unsigned int count = *caret_count;
+ hb_array_t<const HBINT16> arr = array.sub_array (start_offset, caret_count);
+ unsigned int count = arr.len;
for (unsigned int i = 0; i < count; ++i)
switch (format)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-morx-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-morx-table.hh
index 43073270264..171ee4a10b2 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-morx-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-morx-table.hh
@@ -911,14 +911,22 @@ struct ChainSubtable
}
}
+ inline bool apply (hb_aat_apply_context_t *c) const
+ {
+ TRACE_APPLY (this);
+ hb_sanitize_with_object_t with (&c->sanitizer, this);
+ return_trace (dispatch (c));
+ }
+
inline bool sanitize (hb_sanitize_context_t *c) const
{
TRACE_SANITIZE (this);
if (!length.sanitize (c) ||
- length < min_size ||
+ length <= min_size ||
!c->check_range (this, length))
return_trace (false);
+ hb_sanitize_with_object_t with (c, this);
return_trace (dispatch (c));
}
@@ -949,21 +957,21 @@ struct Chain
unsigned int count = featureCount;
for (unsigned i = 0; i < count; i++)
{
- const Feature &feature = featureZ[i];
- uint16_t type = feature.featureType;
- uint16_t setting = feature.featureSetting;
+ const Feature &feature = featureZ[i];
+ hb_aat_layout_feature_type_t type = (hb_aat_layout_feature_type_t) (unsigned int) feature.featureType;
+ hb_aat_layout_feature_selector_t setting = (hb_aat_layout_feature_selector_t) (unsigned int) feature.featureSetting;
retry:
- const hb_aat_map_builder_t::feature_info_t *info = map->features.bsearch (type);
+ const hb_aat_map_builder_t::feature_info_t *info = map->features.bsearch ((uint16_t) type);
if (info && info->setting == setting)
{
flags &= feature.disableFlags;
flags |= feature.enableFlags;
}
- else if (type == 3/*kLetterCaseType*/ && setting == 3/*kSmallCapsSelector*/)
+ else if (type == HB_AAT_LAYOUT_FEATURE_TYPE_LETTER_CASE && setting == HB_AAT_LAYOUT_FEATURE_SELECTOR_SMALL_CAPS)
{
/* Deprecated. https://github.com/harfbuzz/harfbuzz/issues/1342 */
- type = 37/*kLowerCaseType*/;
- setting = 1/*kLowerCaseSmallCapsSelector*/;
+ type = HB_AAT_LAYOUT_FEATURE_TYPE_LOWER_CASE;
+ setting = HB_AAT_LAYOUT_FEATURE_SELECTOR_LOWER_CASE_SMALL_CAPS;
goto retry;
}
}
@@ -1026,9 +1034,7 @@ struct Chain
if (reverse)
c->buffer->reverse ();
- c->sanitizer.set_object (*subtable);
-
- subtable->dispatch (c);
+ subtable->apply (c);
if (reverse)
c->buffer->reverse ();
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-trak-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-trak-table.hh
index 91c0f4562dc..5474d1d11b8 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-trak-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout-trak-table.hh
@@ -133,7 +133,6 @@ struct TrackData
if (!sizes) return 0.;
if (sizes == 1) return trackTableEntry->get_value (base, 0, sizes);
- /* TODO bfind() */
hb_array_t<const Fixed> size_table ((base+sizeTable).arrayZ, sizes);
unsigned int size_index;
for (size_index = 0; size_index < sizes - 1; size_index++)
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.cc
index d9580c15281..fae67800c00 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.cc
@@ -1,5 +1,6 @@
/*
* Copyright © 2017 Google, Inc.
+ * Copyright © 2018 Ebrahim Byagowi
*
* This is part of HarfBuzz, a text shaping library.
*
@@ -30,7 +31,7 @@
#include "hb-aat-layout.hh"
#include "hb-aat-layout-ankr-table.hh"
#include "hb-aat-layout-bsln-table.hh" // Just so we compile it; unused otherwise.
-#include "hb-aat-layout-feat-table.hh" // Just so we compile it; unused otherwise.
+#include "hb-aat-layout-feat-table.hh"
#include "hb-aat-layout-just-table.hh" // Just so we compile it; unused otherwise.
#include "hb-aat-layout-kerx-table.hh"
#include "hb-aat-layout-morx-table.hh"
@@ -38,86 +39,96 @@
#include "hb-aat-ltag-table.hh"
+/**
+ * SECTION:hb-aat-layout
+ * @title: hb-aat-layout
+ * @short_description: Apple Advanced Typography Layout
+ * @include: hb-aat.h
+ *
+ * Functions for querying OpenType Layout features in the font face.
+ **/
+
+
/* Table data courtesy of Apple. Converted from mnemonics to integers
* when moving to this file. */
static const hb_aat_feature_mapping_t feature_mappings[] =
{
- {HB_TAG ('a','f','r','c'), 11/*kFractionsType*/, 1/*kVerticalFractionsSelector*/, 0/*kNoFractionsSelector*/},
- {HB_TAG ('c','2','p','c'), 38/*kUpperCaseType*/, 2/*kUpperCasePetiteCapsSelector*/, 0/*kDefaultUpperCaseSelector*/},
- {HB_TAG ('c','2','s','c'), 38/*kUpperCaseType*/, 1/*kUpperCaseSmallCapsSelector*/, 0/*kDefaultUpperCaseSelector*/},
- {HB_TAG ('c','a','l','t'), 36/*kContextualAlternatesType*/, 0/*kContextualAlternatesOnSelector*/, 1/*kContextualAlternatesOffSelector*/},
- {HB_TAG ('c','a','s','e'), 33/*kCaseSensitiveLayoutType*/, 0/*kCaseSensitiveLayoutOnSelector*/, 1/*kCaseSensitiveLayoutOffSelector*/},
- {HB_TAG ('c','l','i','g'), 1/*kLigaturesType*/, 18/*kContextualLigaturesOnSelector*/, 19/*kContextualLigaturesOffSelector*/},
- {HB_TAG ('c','p','s','p'), 33/*kCaseSensitiveLayoutType*/, 2/*kCaseSensitiveSpacingOnSelector*/, 3/*kCaseSensitiveSpacingOffSelector*/},
- {HB_TAG ('c','s','w','h'), 36/*kContextualAlternatesType*/, 4/*kContextualSwashAlternatesOnSelector*/, 5/*kContextualSwashAlternatesOffSelector*/},
- {HB_TAG ('d','l','i','g'), 1/*kLigaturesType*/, 4/*kRareLigaturesOnSelector*/, 5/*kRareLigaturesOffSelector*/},
- {HB_TAG ('e','x','p','t'), 20/*kCharacterShapeType*/, 10/*kExpertCharactersSelector*/, 16},
- {HB_TAG ('f','r','a','c'), 11/*kFractionsType*/, 2/*kDiagonalFractionsSelector*/, 0/*kNoFractionsSelector*/},
- {HB_TAG ('f','w','i','d'), 22/*kTextSpacingType*/, 1/*kMonospacedTextSelector*/, 7},
- {HB_TAG ('h','a','l','t'), 22/*kTextSpacingType*/, 6/*kAltHalfWidthTextSelector*/, 7},
- {HB_TAG ('h','i','s','t'), 1/*kLigaturesType*/, 20/*kHistoricalLigaturesOnSelector*/, 21/*kHistoricalLigaturesOffSelector*/},
- {HB_TAG ('h','k','n','a'), 34/*kAlternateKanaType*/, 0/*kAlternateHorizKanaOnSelector*/, 1/*kAlternateHorizKanaOffSelector*/, },
- {HB_TAG ('h','l','i','g'), 1/*kLigaturesType*/, 20/*kHistoricalLigaturesOnSelector*/, 21/*kHistoricalLigaturesOffSelector*/},
- {HB_TAG ('h','n','g','l'), 23/*kTransliterationType*/, 1/*kHanjaToHangulSelector*/, 0/*kNoTransliterationSelector*/},
- {HB_TAG ('h','o','j','o'), 20/*kCharacterShapeType*/, 12/*kHojoCharactersSelector*/, 16},
- {HB_TAG ('h','w','i','d'), 22/*kTextSpacingType*/, 2/*kHalfWidthTextSelector*/, 7},
- {HB_TAG ('i','t','a','l'), 32/*kItalicCJKRomanType*/, 2/*kCJKItalicRomanOnSelector*/, 3/*kCJKItalicRomanOffSelector*/},
- {HB_TAG ('j','p','0','4'), 20/*kCharacterShapeType*/, 11/*kJIS2004CharactersSelector*/, 16},
- {HB_TAG ('j','p','7','8'), 20/*kCharacterShapeType*/, 2/*kJIS1978CharactersSelector*/, 16},
- {HB_TAG ('j','p','8','3'), 20/*kCharacterShapeType*/, 3/*kJIS1983CharactersSelector*/, 16},
- {HB_TAG ('j','p','9','0'), 20/*kCharacterShapeType*/, 4/*kJIS1990CharactersSelector*/, 16},
- {HB_TAG ('l','i','g','a'), 1/*kLigaturesType*/, 2/*kCommonLigaturesOnSelector*/, 3/*kCommonLigaturesOffSelector*/},
- {HB_TAG ('l','n','u','m'), 21/*kNumberCaseType*/, 1/*kUpperCaseNumbersSelector*/, 2},
- {HB_TAG ('m','g','r','k'), 15/*kMathematicalExtrasType*/, 10/*kMathematicalGreekOnSelector*/, 11/*kMathematicalGreekOffSelector*/},
- {HB_TAG ('n','l','c','k'), 20/*kCharacterShapeType*/, 13/*kNLCCharactersSelector*/, 16},
- {HB_TAG ('o','n','u','m'), 21/*kNumberCaseType*/, 0/*kLowerCaseNumbersSelector*/, 2},
- {HB_TAG ('o','r','d','n'), 10/*kVerticalPositionType*/, 3/*kOrdinalsSelector*/, 0/*kNormalPositionSelector*/},
- {HB_TAG ('p','a','l','t'), 22/*kTextSpacingType*/, 5/*kAltProportionalTextSelector*/, 7},
- {HB_TAG ('p','c','a','p'), 37/*kLowerCaseType*/, 2/*kLowerCasePetiteCapsSelector*/, 0/*kDefaultLowerCaseSelector*/},
- {HB_TAG ('p','k','n','a'), 22/*kTextSpacingType*/, 0/*kProportionalTextSelector*/, 7},
- {HB_TAG ('p','n','u','m'), 6/*kNumberSpacingType*/, 1/*kProportionalNumbersSelector*/, 4},
- {HB_TAG ('p','w','i','d'), 22/*kTextSpacingType*/, 0/*kProportionalTextSelector*/, 7},
- {HB_TAG ('q','w','i','d'), 22/*kTextSpacingType*/, 4/*kQuarterWidthTextSelector*/, 7},
- {HB_TAG ('r','u','b','y'), 28/*kRubyKanaType*/, 2/*kRubyKanaOnSelector*/, 3/*kRubyKanaOffSelector*/},
- {HB_TAG ('s','i','n','f'), 10/*kVerticalPositionType*/, 4/*kScientificInferiorsSelector*/, 0/*kNormalPositionSelector*/},
- {HB_TAG ('s','m','c','p'), 37/*kLowerCaseType*/, 1/*kLowerCaseSmallCapsSelector*/, 0/*kDefaultLowerCaseSelector*/},
- {HB_TAG ('s','m','p','l'), 20/*kCharacterShapeType*/, 1/*kSimplifiedCharactersSelector*/, 16},
- {HB_TAG ('s','s','0','1'), 35/*kStylisticAlternativesType*/, 2/*kStylisticAltOneOnSelector*/, 3/*kStylisticAltOneOffSelector*/},
- {HB_TAG ('s','s','0','2'), 35/*kStylisticAlternativesType*/, 4/*kStylisticAltTwoOnSelector*/, 5/*kStylisticAltTwoOffSelector*/},
- {HB_TAG ('s','s','0','3'), 35/*kStylisticAlternativesType*/, 6/*kStylisticAltThreeOnSelector*/, 7/*kStylisticAltThreeOffSelector*/},
- {HB_TAG ('s','s','0','4'), 35/*kStylisticAlternativesType*/, 8/*kStylisticAltFourOnSelector*/, 9/*kStylisticAltFourOffSelector*/},
- {HB_TAG ('s','s','0','5'), 35/*kStylisticAlternativesType*/, 10/*kStylisticAltFiveOnSelector*/, 11/*kStylisticAltFiveOffSelector*/},
- {HB_TAG ('s','s','0','6'), 35/*kStylisticAlternativesType*/, 12/*kStylisticAltSixOnSelector*/, 13/*kStylisticAltSixOffSelector*/},
- {HB_TAG ('s','s','0','7'), 35/*kStylisticAlternativesType*/, 14/*kStylisticAltSevenOnSelector*/, 15/*kStylisticAltSevenOffSelector*/},
- {HB_TAG ('s','s','0','8'), 35/*kStylisticAlternativesType*/, 16/*kStylisticAltEightOnSelector*/, 17/*kStylisticAltEightOffSelector*/},
- {HB_TAG ('s','s','0','9'), 35/*kStylisticAlternativesType*/, 18/*kStylisticAltNineOnSelector*/, 19/*kStylisticAltNineOffSelector*/},
- {HB_TAG ('s','s','1','0'), 35/*kStylisticAlternativesType*/, 20/*kStylisticAltTenOnSelector*/, 21/*kStylisticAltTenOffSelector*/},
- {HB_TAG ('s','s','1','1'), 35/*kStylisticAlternativesType*/, 22/*kStylisticAltElevenOnSelector*/, 23/*kStylisticAltElevenOffSelector*/},
- {HB_TAG ('s','s','1','2'), 35/*kStylisticAlternativesType*/, 24/*kStylisticAltTwelveOnSelector*/, 25/*kStylisticAltTwelveOffSelector*/},
- {HB_TAG ('s','s','1','3'), 35/*kStylisticAlternativesType*/, 26/*kStylisticAltThirteenOnSelector*/, 27/*kStylisticAltThirteenOffSelector*/},
- {HB_TAG ('s','s','1','4'), 35/*kStylisticAlternativesType*/, 28/*kStylisticAltFourteenOnSelector*/, 29/*kStylisticAltFourteenOffSelector*/},
- {HB_TAG ('s','s','1','5'), 35/*kStylisticAlternativesType*/, 30/*kStylisticAltFifteenOnSelector*/, 31/*kStylisticAltFifteenOffSelector*/},
- {HB_TAG ('s','s','1','6'), 35/*kStylisticAlternativesType*/, 32/*kStylisticAltSixteenOnSelector*/, 33/*kStylisticAltSixteenOffSelector*/},
- {HB_TAG ('s','s','1','7'), 35/*kStylisticAlternativesType*/, 34/*kStylisticAltSeventeenOnSelector*/, 35/*kStylisticAltSeventeenOffSelector*/},
- {HB_TAG ('s','s','1','8'), 35/*kStylisticAlternativesType*/, 36/*kStylisticAltEighteenOnSelector*/, 37/*kStylisticAltEighteenOffSelector*/},
- {HB_TAG ('s','s','1','9'), 35/*kStylisticAlternativesType*/, 38/*kStylisticAltNineteenOnSelector*/, 39/*kStylisticAltNineteenOffSelector*/},
- {HB_TAG ('s','s','2','0'), 35/*kStylisticAlternativesType*/, 40/*kStylisticAltTwentyOnSelector*/, 41/*kStylisticAltTwentyOffSelector*/},
- {HB_TAG ('s','u','b','s'), 10/*kVerticalPositionType*/, 2/*kInferiorsSelector*/, 0/*kNormalPositionSelector*/},
- {HB_TAG ('s','u','p','s'), 10/*kVerticalPositionType*/, 1/*kSuperiorsSelector*/, 0/*kNormalPositionSelector*/},
- {HB_TAG ('s','w','s','h'), 36/*kContextualAlternatesType*/, 2/*kSwashAlternatesOnSelector*/, 3/*kSwashAlternatesOffSelector*/},
- {HB_TAG ('t','i','t','l'), 19/*kStyleOptionsType*/, 4/*kTitlingCapsSelector*/, 0/*kNoStyleOptionsSelector*/},
- {HB_TAG ('t','n','a','m'), 20/*kCharacterShapeType*/, 14/*kTraditionalNamesCharactersSelector*/, 16},
- {HB_TAG ('t','n','u','m'), 6/*kNumberSpacingType*/, 0/*kMonospacedNumbersSelector*/, 4},
- {HB_TAG ('t','r','a','d'), 20/*kCharacterShapeType*/, 0/*kTraditionalCharactersSelector*/, 16},
- {HB_TAG ('t','w','i','d'), 22/*kTextSpacingType*/, 3/*kThirdWidthTextSelector*/, 7},
- {HB_TAG ('u','n','i','c'), 3/*kLetterCaseType*/, 14, 15},
- {HB_TAG ('v','a','l','t'), 22/*kTextSpacingType*/, 5/*kAltProportionalTextSelector*/, 7},
- {HB_TAG ('v','e','r','t'), 4/*kVerticalSubstitutionType*/, 0/*kSubstituteVerticalFormsOnSelector*/, 1/*kSubstituteVerticalFormsOffSelector*/},
- {HB_TAG ('v','h','a','l'), 22/*kTextSpacingType*/, 6/*kAltHalfWidthTextSelector*/, 7},
- {HB_TAG ('v','k','n','a'), 34/*kAlternateKanaType*/, 2/*kAlternateVertKanaOnSelector*/, 3/*kAlternateVertKanaOffSelector*/},
- {HB_TAG ('v','p','a','l'), 22/*kTextSpacingType*/, 5/*kAltProportionalTextSelector*/, 7},
- {HB_TAG ('v','r','t','2'), 4/*kVerticalSubstitutionType*/, 0/*kSubstituteVerticalFormsOnSelector*/, 1/*kSubstituteVerticalFormsOffSelector*/},
- {HB_TAG ('z','e','r','o'), 14/*kTypographicExtrasType*/, 4/*kSlashedZeroOnSelector*/, 5/*kSlashedZeroOffSelector*/},
+ {HB_TAG ('a','f','r','c'), HB_AAT_LAYOUT_FEATURE_TYPE_FRACTIONS, HB_AAT_LAYOUT_FEATURE_SELECTOR_VERTICAL_FRACTIONS, HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_FRACTIONS},
+ {HB_TAG ('c','2','p','c'), HB_AAT_LAYOUT_FEATURE_TYPE_UPPER_CASE, HB_AAT_LAYOUT_FEATURE_SELECTOR_UPPER_CASE_PETITE_CAPS, HB_AAT_LAYOUT_FEATURE_SELECTOR_DEFAULT_UPPER_CASE},
+ {HB_TAG ('c','2','s','c'), HB_AAT_LAYOUT_FEATURE_TYPE_UPPER_CASE, HB_AAT_LAYOUT_FEATURE_SELECTOR_UPPER_CASE_SMALL_CAPS, HB_AAT_LAYOUT_FEATURE_SELECTOR_DEFAULT_UPPER_CASE},
+ {HB_TAG ('c','a','l','t'), HB_AAT_LAYOUT_FEATURE_TYPE_CONTEXTUAL_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_ALTERNATES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_ALTERNATES_OFF},
+ {HB_TAG ('c','a','s','e'), HB_AAT_LAYOUT_FEATURE_TYPE_CASE_SENSITIVE_LAYOUT, HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_LAYOUT_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_LAYOUT_OFF},
+ {HB_TAG ('c','l','i','g'), HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES, HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_LIGATURES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_LIGATURES_OFF},
+ {HB_TAG ('c','p','s','p'), HB_AAT_LAYOUT_FEATURE_TYPE_CASE_SENSITIVE_LAYOUT, HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_SPACING_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_SPACING_OFF},
+ {HB_TAG ('c','s','w','h'), HB_AAT_LAYOUT_FEATURE_TYPE_CONTEXTUAL_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_SWASH_ALTERNATES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_SWASH_ALTERNATES_OFF},
+ {HB_TAG ('d','l','i','g'), HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES, HB_AAT_LAYOUT_FEATURE_SELECTOR_RARE_LIGATURES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_RARE_LIGATURES_OFF},
+ {HB_TAG ('e','x','p','t'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_EXPERT_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('f','r','a','c'), HB_AAT_LAYOUT_FEATURE_TYPE_FRACTIONS, HB_AAT_LAYOUT_FEATURE_SELECTOR_DIAGONAL_FRACTIONS, HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_FRACTIONS},
+ {HB_TAG ('f','w','i','d'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_MONOSPACED_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('h','a','l','t'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALT_HALF_WIDTH_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('h','i','s','t'), HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES, HB_AAT_LAYOUT_FEATURE_SELECTOR_HISTORICAL_LIGATURES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_HISTORICAL_LIGATURES_OFF},
+ {HB_TAG ('h','k','n','a'), HB_AAT_LAYOUT_FEATURE_TYPE_ALTERNATE_KANA, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_HORIZ_KANA_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_HORIZ_KANA_OFF},
+ {HB_TAG ('h','l','i','g'), HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES, HB_AAT_LAYOUT_FEATURE_SELECTOR_HISTORICAL_LIGATURES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_HISTORICAL_LIGATURES_OFF},
+ {HB_TAG ('h','n','g','l'), HB_AAT_LAYOUT_FEATURE_TYPE_TRANSLITERATION, HB_AAT_LAYOUT_FEATURE_SELECTOR_HANJA_TO_HANGUL, HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_TRANSLITERATION},
+ {HB_TAG ('h','o','j','o'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_HOJO_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('h','w','i','d'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_HALF_WIDTH_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('i','t','a','l'), HB_AAT_LAYOUT_FEATURE_TYPE_ITALIC_CJK_ROMAN, HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_ITALIC_ROMAN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_ITALIC_ROMAN_OFF},
+ {HB_TAG ('j','p','0','4'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS2004_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('j','p','7','8'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS1978_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('j','p','8','3'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS1983_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('j','p','9','0'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS1990_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('l','i','g','a'), HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES, HB_AAT_LAYOUT_FEATURE_SELECTOR_COMMON_LIGATURES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_COMMON_LIGATURES_OFF},
+ {HB_TAG ('l','n','u','m'), HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_CASE, HB_AAT_LAYOUT_FEATURE_SELECTOR_UPPER_CASE_NUMBERS, (hb_aat_layout_feature_selector_t) 2},
+ {HB_TAG ('m','g','r','k'), HB_AAT_LAYOUT_FEATURE_TYPE_MATHEMATICAL_EXTRAS, HB_AAT_LAYOUT_FEATURE_SELECTOR_MATHEMATICAL_GREEK_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_MATHEMATICAL_GREEK_OFF},
+ {HB_TAG ('n','l','c','k'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_NLCCHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('o','n','u','m'), HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_CASE, HB_AAT_LAYOUT_FEATURE_SELECTOR_LOWER_CASE_NUMBERS, (hb_aat_layout_feature_selector_t) 2},
+ {HB_TAG ('o','r','d','n'), HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_POSITION, HB_AAT_LAYOUT_FEATURE_SELECTOR_ORDINALS, HB_AAT_LAYOUT_FEATURE_SELECTOR_NORMAL_POSITION},
+ {HB_TAG ('p','a','l','t'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALT_PROPORTIONAL_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('p','c','a','p'), HB_AAT_LAYOUT_FEATURE_TYPE_LOWER_CASE, HB_AAT_LAYOUT_FEATURE_SELECTOR_LOWER_CASE_PETITE_CAPS, HB_AAT_LAYOUT_FEATURE_SELECTOR_DEFAULT_LOWER_CASE},
+ {HB_TAG ('p','k','n','a'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('p','n','u','m'), HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_NUMBERS, (hb_aat_layout_feature_selector_t) 4},
+ {HB_TAG ('p','w','i','d'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('q','w','i','d'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_QUARTER_WIDTH_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('r','u','b','y'), HB_AAT_LAYOUT_FEATURE_TYPE_RUBY_KANA, HB_AAT_LAYOUT_FEATURE_SELECTOR_RUBY_KANA_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_RUBY_KANA_OFF},
+ {HB_TAG ('s','i','n','f'), HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_POSITION, HB_AAT_LAYOUT_FEATURE_SELECTOR_SCIENTIFIC_INFERIORS, HB_AAT_LAYOUT_FEATURE_SELECTOR_NORMAL_POSITION},
+ {HB_TAG ('s','m','c','p'), HB_AAT_LAYOUT_FEATURE_TYPE_LOWER_CASE, HB_AAT_LAYOUT_FEATURE_SELECTOR_LOWER_CASE_SMALL_CAPS, HB_AAT_LAYOUT_FEATURE_SELECTOR_DEFAULT_LOWER_CASE},
+ {HB_TAG ('s','m','p','l'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_SIMPLIFIED_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('s','s','0','1'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ONE_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ONE_OFF},
+ {HB_TAG ('s','s','0','2'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWO_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWO_OFF},
+ {HB_TAG ('s','s','0','3'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THREE_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THREE_OFF},
+ {HB_TAG ('s','s','0','4'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOUR_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOUR_OFF},
+ {HB_TAG ('s','s','0','5'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIVE_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIVE_OFF},
+ {HB_TAG ('s','s','0','6'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIX_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIX_OFF},
+ {HB_TAG ('s','s','0','7'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVEN_OFF},
+ {HB_TAG ('s','s','0','8'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHT_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHT_OFF},
+ {HB_TAG ('s','s','0','9'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINE_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINE_OFF},
+ {HB_TAG ('s','s','1','0'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TEN_OFF},
+ {HB_TAG ('s','s','1','1'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ELEVEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ELEVEN_OFF},
+ {HB_TAG ('s','s','1','2'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWELVE_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWELVE_OFF},
+ {HB_TAG ('s','s','1','3'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THIRTEEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THIRTEEN_OFF},
+ {HB_TAG ('s','s','1','4'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOURTEEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOURTEEN_OFF},
+ {HB_TAG ('s','s','1','5'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIFTEEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIFTEEN_OFF},
+ {HB_TAG ('s','s','1','6'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIXTEEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIXTEEN_OFF},
+ {HB_TAG ('s','s','1','7'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVENTEEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVENTEEN_OFF},
+ {HB_TAG ('s','s','1','8'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHTEEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHTEEN_OFF},
+ {HB_TAG ('s','s','1','9'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINETEEN_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINETEEN_OFF},
+ {HB_TAG ('s','s','2','0'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWENTY_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWENTY_OFF},
+ {HB_TAG ('s','u','b','s'), HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_POSITION, HB_AAT_LAYOUT_FEATURE_SELECTOR_INFERIORS, HB_AAT_LAYOUT_FEATURE_SELECTOR_NORMAL_POSITION},
+ {HB_TAG ('s','u','p','s'), HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_POSITION, HB_AAT_LAYOUT_FEATURE_SELECTOR_SUPERIORS, HB_AAT_LAYOUT_FEATURE_SELECTOR_NORMAL_POSITION},
+ {HB_TAG ('s','w','s','h'), HB_AAT_LAYOUT_FEATURE_TYPE_CONTEXTUAL_ALTERNATIVES, HB_AAT_LAYOUT_FEATURE_SELECTOR_SWASH_ALTERNATES_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_SWASH_ALTERNATES_OFF},
+ {HB_TAG ('t','i','t','l'), HB_AAT_LAYOUT_FEATURE_TYPE_STYLE_OPTIONS, HB_AAT_LAYOUT_FEATURE_SELECTOR_TITLING_CAPS, HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_STYLE_OPTIONS},
+ {HB_TAG ('t','n','a','m'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_NAMES_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('t','n','u','m'), HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_MONOSPACED_NUMBERS, (hb_aat_layout_feature_selector_t) 4},
+ {HB_TAG ('t','r','a','d'), HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE, HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_CHARACTERS, (hb_aat_layout_feature_selector_t) 16},
+ {HB_TAG ('t','w','i','d'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_THIRD_WIDTH_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('u','n','i','c'), HB_AAT_LAYOUT_FEATURE_TYPE_LETTER_CASE, (hb_aat_layout_feature_selector_t) 14, (hb_aat_layout_feature_selector_t) 15},
+ {HB_TAG ('v','a','l','t'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALT_PROPORTIONAL_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('v','e','r','t'), HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_SUBSTITUTION, HB_AAT_LAYOUT_FEATURE_SELECTOR_SUBSTITUTE_VERTICAL_FORMS_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_SUBSTITUTE_VERTICAL_FORMS_OFF},
+ {HB_TAG ('v','h','a','l'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALT_HALF_WIDTH_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('v','k','n','a'), HB_AAT_LAYOUT_FEATURE_TYPE_ALTERNATE_KANA, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_VERT_KANA_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_VERT_KANA_OFF},
+ {HB_TAG ('v','p','a','l'), HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING, HB_AAT_LAYOUT_FEATURE_SELECTOR_ALT_PROPORTIONAL_TEXT, (hb_aat_layout_feature_selector_t) 7},
+ {HB_TAG ('v','r','t','2'), HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_SUBSTITUTION, HB_AAT_LAYOUT_FEATURE_SELECTOR_SUBSTITUTE_VERTICAL_FORMS_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_SUBSTITUTE_VERTICAL_FORMS_OFF},
+ {HB_TAG ('z','e','r','o'), HB_AAT_LAYOUT_FEATURE_TYPE_TYPOGRAPHIC_EXTRAS, HB_AAT_LAYOUT_FEATURE_SELECTOR_SLASHED_ZERO_ON, HB_AAT_LAYOUT_FEATURE_SELECTOR_SLASHED_ZERO_OFF},
};
const hb_aat_feature_mapping_t *
@@ -297,3 +308,65 @@ _hb_aat_language_get (hb_face_t *face,
{
return face->table.ltag->get_language (i);
}
+
+/**
+ * hb_aat_layout_get_feature_types:
+ * @face: a face object
+ * @start_offset: iteration's start offset
+ * @feature_count:(inout) (allow-none): buffer size as input, filled size as output
+ * @features: (out caller-allocates) (array length=feature_count): features buffer
+ *
+ * Return value: Number of all available feature types.
+ *
+ * Since: 2.2.0
+ */
+unsigned int
+hb_aat_layout_get_feature_types (hb_face_t *face,
+ unsigned int start_offset,
+ unsigned int *feature_count, /* IN/OUT. May be NULL. */
+ hb_aat_layout_feature_type_t *features /* OUT. May be NULL. */)
+{
+ return face->table.feat->get_feature_types (start_offset, feature_count, features);
+}
+
+/**
+ * hb_aat_layout_feature_type_get_name_id:
+ * @face: a face object
+ * @feature_type: feature id
+ *
+ * Return value: Name ID index
+ *
+ * Since: 2.2.0
+ */
+hb_ot_name_id_t
+hb_aat_layout_feature_type_get_name_id (hb_face_t *face,
+ hb_aat_layout_feature_type_t feature_type)
+{ return face->table.feat->get_feature_name_id (feature_type); }
+
+/**
+ * hb_aat_layout_feature_type_get_selectors:
+ * @face: a face object
+ * @feature_type: feature id
+ * @start_offset: iteration's start offset
+ * @selector_count: (inout) (allow-none): buffer size as input, filled size as output
+ * @selectors: (out caller-allocates) (array length=selector_count): settings buffer
+ * @default_index: (out) (allow-none): index of default selector if any
+ *
+ * If upon return, @default_index is set to #HB_AAT_LAYOUT_NO_SELECTOR_INDEX, then
+ * the feature type is non-exclusive. Otherwise, @default_index is the index of
+ * the selector that is selected by default.
+ *
+ * Return value: Number of all available feature selectors.
+ *
+ * Since: 2.2.0
+ */
+unsigned int
+hb_aat_layout_feature_type_get_selector_infos (hb_face_t *face,
+ hb_aat_layout_feature_type_t feature_type,
+ unsigned int start_offset,
+ unsigned int *selector_count, /* IN/OUT. May be NULL. */
+ hb_aat_layout_feature_selector_info_t *selectors, /* OUT. May be NULL. */
+ unsigned int *default_index /* OUT. May be NULL. */)
+{
+ return face->table.feat->get_selector_infos (feature_type, start_offset, selector_count, selectors, default_index);
+}
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.h b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.h
new file mode 100644
index 00000000000..696e9033409
--- /dev/null
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.h
@@ -0,0 +1,462 @@
+/*
+ * Copyright © 2018 Ebrahim Byagowi
+ *
+ * This is part of HarfBuzz, a text shaping library.
+ *
+ * Permission is hereby granted, without written agreement and without
+ * license or royalty fees, to use, copy, modify, and distribute this
+ * software and its documentation for any purpose, provided that the
+ * above copyright notice and the following two paragraphs appear in
+ * all copies of this software.
+ *
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR
+ * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
+ * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN
+ * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
+ * DAMAGE.
+ *
+ * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING,
+ * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
+ * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO
+ * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
+ */
+
+#ifndef HB_AAT_H_IN
+#error "Include <hb-aat.h> instead."
+#endif
+
+#ifndef HB_AAT_LAYOUT_H
+#define HB_AAT_LAYOUT_H
+
+#include "hb.h"
+
+#include "hb-ot.h"
+
+HB_BEGIN_DECLS
+
+/**
+ * hb_aat_layout_feature_type_t:
+ *
+ *
+ * Since: 2.2.0
+ */
+typedef enum
+{
+ HB_AAT_LAYOUT_FEATURE_TYPE_INVALID = 0xFFFF,
+
+ HB_AAT_LAYOUT_FEATURE_TYPE_ALL_TYPOGRAPHIC = 0,
+ HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES = 1,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CURISVE_CONNECTION = 2,
+ HB_AAT_LAYOUT_FEATURE_TYPE_LETTER_CASE = 3,
+ HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_SUBSTITUTION = 4,
+ HB_AAT_LAYOUT_FEATURE_TYPE_LINGUISTIC_REARRANGEMENT = 5,
+ HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_SPACING = 6,
+ HB_AAT_LAYOUT_FEATURE_TYPE_SMART_SWASH_TYPE = 8,
+ HB_AAT_LAYOUT_FEATURE_TYPE_DIACRITICS_TYPE = 9,
+ HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_POSITION = 10,
+ HB_AAT_LAYOUT_FEATURE_TYPE_FRACTIONS = 11,
+ HB_AAT_LAYOUT_FEATURE_TYPE_OVERLAPPING_CHARACTERS_TYPE = 13,
+ HB_AAT_LAYOUT_FEATURE_TYPE_TYPOGRAPHIC_EXTRAS = 14,
+ HB_AAT_LAYOUT_FEATURE_TYPE_MATHEMATICAL_EXTRAS = 15,
+ HB_AAT_LAYOUT_FEATURE_TYPE_ORNAMENT_SETS_TYPE = 16,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_ALTERNATIVES = 17,
+ HB_AAT_LAYOUT_FEATURE_TYPE_DESIGN_COMPLEXITY_TYPE = 18,
+ HB_AAT_LAYOUT_FEATURE_TYPE_STYLE_OPTIONS = 19,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE = 20,
+ HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_CASE = 21,
+ HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING = 22,
+ HB_AAT_LAYOUT_FEATURE_TYPE_TRANSLITERATION = 23,
+ HB_AAT_LAYOUT_FEATURE_TYPE_ANNOTATION_TYPE = 24,
+ HB_AAT_LAYOUT_FEATURE_TYPE_KANA_SPACING_TYPE = 25,
+ HB_AAT_LAYOUT_FEATURE_TYPE_IDEOGRAPHIC_SPACING_TYPE = 26,
+ HB_AAT_LAYOUT_FEATURE_TYPE_UNICODE_DECOMPOSITION_TYPE = 27,
+ HB_AAT_LAYOUT_FEATURE_TYPE_RUBY_KANA = 28,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CJK_SYMBOL_ALTERNATIVES_TYPE = 29,
+ HB_AAT_LAYOUT_FEATURE_TYPE_IDEOGRAPHIC_ALTERNATIVES_TYPE = 30,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CJK_VERTICAL_ROMAN_PLACEMENT_TYPE = 31,
+ HB_AAT_LAYOUT_FEATURE_TYPE_ITALIC_CJK_ROMAN = 32,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CASE_SENSITIVE_LAYOUT = 33,
+ HB_AAT_LAYOUT_FEATURE_TYPE_ALTERNATE_KANA = 34,
+ HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES = 35,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CONTEXTUAL_ALTERNATIVES = 36,
+ HB_AAT_LAYOUT_FEATURE_TYPE_LOWER_CASE = 37,
+ HB_AAT_LAYOUT_FEATURE_TYPE_UPPER_CASE = 38,
+ HB_AAT_LAYOUT_FEATURE_TYPE_LANGUAGE_TAG_TYPE = 39,
+ HB_AAT_LAYOUT_FEATURE_TYPE_CJK_ROMAN_SPACING_TYPE = 103,
+
+ _HB_AAT_LAYOUT_FEATURE_TYPE_MAX_VALUE= 0x7FFFFFFFu, /*< skip >*/
+} hb_aat_layout_feature_type_t;
+
+/**
+ * hb_aat_layout_feature_selector_t:
+ *
+ *
+ * Since: 2.2.0
+ */
+typedef enum
+{
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INVALID = 0xFFFF,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_ALL_TYPOGRAPHIC */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALL_TYPE_FEATURES_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALL_TYPE_FEATURES_OFF = 1,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_REQUIRED_LIGATURES_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_REQUIRED_LIGATURES_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_COMMON_LIGATURES_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_COMMON_LIGATURES_OFF = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_RARE_LIGATURES_ON = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_RARE_LIGATURES_OFF = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LOGOS_ON = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LOGOS_OFF = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_REBUS_PICTURES_ON = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_REBUS_PICTURES_OFF = 9,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DIPHTHONG_LIGATURES_ON = 10,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DIPHTHONG_LIGATURES_OFF = 11,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SQUARED_LIGATURES_ON = 12,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SQUARED_LIGATURES_OFF = 13,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ABBREV_SQUARED_LIGATURES_ON = 14,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ABBREV_SQUARED_LIGATURES_OFF = 15,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SYMBOL_LIGATURES_ON = 16,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SYMBOL_LIGATURES_OFF = 17,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_LIGATURES_ON = 18,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_LIGATURES_OFF = 19,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HISTORICAL_LIGATURES_ON = 20,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HISTORICAL_LIGATURES_OFF = 21,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_LIGATURES */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_UNCONNECTED = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PARTIALLY_CONNECTED = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CURSIVE = 2,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_LETTER_CASE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_UPPER_AND_LOWER_CASE = 0, /* deprecated */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALL_CAPS = 1, /* deprecated */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALL_LOWER_CASE = 2, /* deprecated */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SMALL_CAPS = 3, /* deprecated */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INITIAL_CAPS = 4, /* deprecated */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INITIAL_CAPS_AND_SMALL_CAPS = 5, /* deprecated */
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_SUBSTITUTION */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SUBSTITUTE_VERTICAL_FORMS_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SUBSTITUTE_VERTICAL_FORMS_OFF = 1,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_LINGUISTIC_REARRANGEMENT */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LINGUISTIC_REARRANGEMENT_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LINGUISTIC_REARRANGEMENT_OFF = 1,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_SPACING */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_MONOSPACED_NUMBERS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_NUMBERS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_THIRD_WIDTH_NUMBERS = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_QUARTER_WIDTH_NUMBERS = 3,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_SMART_SWASH_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_WORD_INITIAL_SWASHES_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_WORD_INITIAL_SWASHES_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_WORD_FINAL_SWASHES_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_WORD_FINAL_SWASHES_OFF = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LINE_INITIAL_SWASHES_ON = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LINE_INITIAL_SWASHES_OFF = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LINE_FINAL_SWASHES_ON = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LINE_FINAL_SWASHES_OFF = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NON_FINAL_SWASHES_ON = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NON_FINAL_SWASHES_OFF = 9,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_DIACRITICS_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SHOW_DIACRITICS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HIDE_DIACRITICS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DECOMPOSE_DIACRITICS = 2,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_VERTICAL_POSITION */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NORMAL_POSITION = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SUPERIORS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INFERIORS = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ORDINALS = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SCIENTIFIC_INFERIORS = 4,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_FRACTIONS */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_FRACTIONS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_VERTICAL_FRACTIONS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DIAGONAL_FRACTIONS = 2,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_OVERLAPPING_CHARACTERS_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PREVENT_OVERLAP_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PREVENT_OVERLAP_OFF = 1,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_TYPOGRAPHIC_EXTRAS */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HYPHENS_TO_EM_DASH_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HYPHENS_TO_EM_DASH_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HYPHEN_TO_EN_DASH_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HYPHEN_TO_EN_DASH_OFF = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SLASHED_ZERO_ON = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SLASHED_ZERO_OFF = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_FORM_INTERROBANG_ON = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_FORM_INTERROBANG_OFF = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SMART_QUOTES_ON = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SMART_QUOTES_OFF = 9,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PERIODS_TO_ELLIPSIS_ON = 10,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PERIODS_TO_ELLIPSIS_OFF = 11,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_MATHEMATICAL_EXTRAS */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HYPHEN_TO_MINUS_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HYPHEN_TO_MINUS_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ASTERISK_TO_MULTIPLY_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ASTERISK_TO_MULTIPLY_OFF = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SLASH_TO_DIVIDE_ON = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SLASH_TO_DIVIDE_OFF = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INEQUALITY_LIGATURES_ON = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INEQUALITY_LIGATURES_OFF = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_EXPONENTS_ON = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_EXPONENTS_OFF = 9,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_MATHEMATICAL_GREEK_ON = 10,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_MATHEMATICAL_GREEK_OFF = 11,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_ORNAMENT_SETS_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_ORNAMENTS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DINGBATS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PI_CHARACTERS = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_FLEURONS = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DECORATIVE_BORDERS = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INTERNATIONAL_SYMBOLS = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_MATH_SYMBOLS = 6,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_ALTERNATIVES */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_ALTERNATES = 0,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_DESIGN_COMPLEXITY_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DESIGN_LEVEL1 = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DESIGN_LEVEL2 = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DESIGN_LEVEL3 = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DESIGN_LEVEL4 = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DESIGN_LEVEL5 = 4,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_STYLE_OPTIONS */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_STYLE_OPTIONS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DISPLAY_TEXT = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ENGRAVED_TEXT = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ILLUMINATED_CAPS = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TITLING_CAPS = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TALL_CAPS = 5,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_SHAPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_CHARACTERS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SIMPLIFIED_CHARACTERS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS1978_CHARACTERS = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS1983_CHARACTERS = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS1990_CHARACTERS = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_ALT_ONE = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_ALT_TWO = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_ALT_THREE = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_ALT_FOUR = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_ALT_FIVE = 9,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_EXPERT_CHARACTERS = 10,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_JIS2004_CHARACTERS = 11,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HOJO_CHARACTERS = 12,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NLCCHARACTERS = 13,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRADITIONAL_NAMES_CHARACTERS = 14,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_NUMBER_CASE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LOWER_CASE_NUMBERS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_UPPER_CASE_NUMBERS = 1,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_TEXT_SPACING */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_TEXT = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_MONOSPACED_TEXT = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HALF_WIDTH_TEXT = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_THIRD_WIDTH_TEXT = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_QUARTER_WIDTH_TEXT = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALT_PROPORTIONAL_TEXT = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALT_HALF_WIDTH_TEXT = 6,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_TRANSLITERATION */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_TRANSLITERATION = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HANJA_TO_HANGUL = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HIRAGANA_TO_KATAKANA = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_KATAKANA_TO_HIRAGANA = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_KANA_TO_ROMANIZATION = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ROMANIZATION_TO_HIRAGANA = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ROMANIZATION_TO_KATAKANA = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HANJA_TO_HANGUL_ALT_ONE = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HANJA_TO_HANGUL_ALT_TWO = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HANJA_TO_HANGUL_ALT_THREE = 9,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_ANNOTATION_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_ANNOTATION = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_BOX_ANNOTATION = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ROUNDED_BOX_ANNOTATION = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CIRCLE_ANNOTATION = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INVERTED_CIRCLE_ANNOTATION = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PARENTHESIS_ANNOTATION = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PERIOD_ANNOTATION = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ROMAN_NUMERAL_ANNOTATION = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DIAMOND_ANNOTATION = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INVERTED_BOX_ANNOTATION = 9,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_INVERTED_ROUNDED_BOX_ANNOTATION= 10,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_KANA_SPACING_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_FULL_WIDTH_KANA = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_KANA = 1,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_IDEOGRAPHIC_SPACING_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_FULL_WIDTH_IDEOGRAPHS = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_IDEOGRAPHS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HALF_WIDTH_IDEOGRAPHS = 2,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_UNICODE_DECOMPOSITION_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CANONICAL_COMPOSITION_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CANONICAL_COMPOSITION_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_COMPATIBILITY_COMPOSITION_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_COMPATIBILITY_COMPOSITION_OFF = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRANSCODING_COMPOSITION_ON = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_TRANSCODING_COMPOSITION_OFF = 5,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_RUBY_KANA */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_RUBY_KANA = 0, /* deprecated - use HB_AAT_LAYOUT_FEATURE_SELECTOR_RUBY_KANA_OFF instead */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_RUBY_KANA = 1, /* deprecated - use HB_AAT_LAYOUT_FEATURE_SELECTOR_RUBY_KANA_ON instead */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_RUBY_KANA_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_RUBY_KANA_OFF = 3,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_CJK_SYMBOL_ALTERNATIVES_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_CJK_SYMBOL_ALTERNATIVES = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_SYMBOL_ALT_ONE = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_SYMBOL_ALT_TWO = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_SYMBOL_ALT_THREE = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_SYMBOL_ALT_FOUR = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_SYMBOL_ALT_FIVE = 5,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_IDEOGRAPHIC_ALTERNATIVES_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_IDEOGRAPHIC_ALTERNATIVES = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_IDEOGRAPHIC_ALT_ONE = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_IDEOGRAPHIC_ALT_TWO = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_IDEOGRAPHIC_ALT_THREE = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_IDEOGRAPHIC_ALT_FOUR = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_IDEOGRAPHIC_ALT_FIVE = 5,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_CJK_VERTICAL_ROMAN_PLACEMENT_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_VERTICAL_ROMAN_CENTERED = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_VERTICAL_ROMAN_HBASELINE = 1,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_ITALIC_CJK_ROMAN */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_CJK_ITALIC_ROMAN = 0, /* deprecated - use HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_ITALIC_ROMAN_OFF instead */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_ITALIC_ROMAN = 1, /* deprecated - use HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_ITALIC_ROMAN_ON instead */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_ITALIC_ROMAN_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CJK_ITALIC_ROMAN_OFF = 3,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_CASE_SENSITIVE_LAYOUT */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_LAYOUT_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_LAYOUT_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_SPACING_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CASE_SENSITIVE_SPACING_OFF = 3,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_ALTERNATE_KANA */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_HORIZ_KANA_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_HORIZ_KANA_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_VERT_KANA_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_ALTERNATE_VERT_KANA_OFF = 3,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_STYLISTIC_ALTERNATIVES */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_NO_STYLISTIC_ALTERNATES = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ONE_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ONE_OFF = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWO_ON = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWO_OFF = 5,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THREE_ON = 6,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THREE_OFF = 7,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOUR_ON = 8,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOUR_OFF = 9,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIVE_ON = 10,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIVE_OFF = 11,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIX_ON = 12,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIX_OFF = 13,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVEN_ON = 14,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVEN_OFF = 15,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHT_ON = 16,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHT_OFF = 17,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINE_ON = 18,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINE_OFF = 19,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TEN_ON = 20,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TEN_OFF = 21,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ELEVEN_ON = 22,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_ELEVEN_OFF = 23,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWELVE_ON = 24,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWELVE_OFF = 25,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THIRTEEN_ON = 26,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_THIRTEEN_OFF = 27,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOURTEEN_ON = 28,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FOURTEEN_OFF = 29,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIFTEEN_ON = 30,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_FIFTEEN_OFF = 31,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIXTEEN_ON = 32,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SIXTEEN_OFF = 33,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVENTEEN_ON = 34,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_SEVENTEEN_OFF = 35,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHTEEN_ON = 36,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_EIGHTEEN_OFF = 37,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINETEEN_ON = 38,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_NINETEEN_OFF = 39,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWENTY_ON = 40,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_STYLISTIC_ALT_TWENTY_OFF = 41,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_CONTEXTUAL_ALTERNATIVES */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_ALTERNATES_ON = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_ALTERNATES_OFF = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SWASH_ALTERNATES_ON = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_SWASH_ALTERNATES_OFF = 3,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_SWASH_ALTERNATES_ON = 4,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_CONTEXTUAL_SWASH_ALTERNATES_OFF= 5,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_LOWER_CASE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DEFAULT_LOWER_CASE = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LOWER_CASE_SMALL_CAPS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_LOWER_CASE_PETITE_CAPS = 2,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_UPPER_CASE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DEFAULT_UPPER_CASE = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_UPPER_CASE_SMALL_CAPS = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_UPPER_CASE_PETITE_CAPS = 2,
+
+ /* Selectors for #HB_AAT_LAYOUT_FEATURE_TYPE_CJK_ROMAN_SPACING_TYPE */
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_HALF_WIDTH_CJK_ROMAN = 0,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_PROPORTIONAL_CJK_ROMAN = 1,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_DEFAULT_CJK_ROMAN = 2,
+ HB_AAT_LAYOUT_FEATURE_SELECTOR_FULL_WIDTH_CJK_ROMAN = 3,
+
+ _HB_AAT_LAYOUT_FEATURE_SELECTOR_MAX_VALUE= 0x7FFFFFFFu, /*< skip >*/
+} hb_aat_layout_feature_selector_t;
+
+HB_EXTERN unsigned int
+hb_aat_layout_get_feature_types (hb_face_t *face,
+ unsigned int start_offset,
+ unsigned int *feature_count, /* IN/OUT. May be NULL. */
+ hb_aat_layout_feature_type_t *features /* OUT. May be NULL. */);
+
+HB_EXTERN hb_ot_name_id_t
+hb_aat_layout_feature_type_get_name_id (hb_face_t *face,
+ hb_aat_layout_feature_type_t feature_type);
+
+typedef struct hb_aat_layout_feature_selector_info_t
+{
+ hb_ot_name_id_t name_id;
+ hb_aat_layout_feature_selector_t enable;
+ hb_aat_layout_feature_selector_t disable;
+ /*< private >*/
+ unsigned int reserved;
+} hb_aat_layout_feature_selector_info_t;
+
+#define HB_AAT_LAYOUT_NO_SELECTOR_INDEX 0xFFFFu
+
+HB_EXTERN unsigned int
+hb_aat_layout_feature_type_get_selector_infos (hb_face_t *face,
+ hb_aat_layout_feature_type_t feature_type,
+ unsigned int start_offset,
+ unsigned int *selector_count, /* IN/OUT. May be NULL. */
+ hb_aat_layout_feature_selector_info_t *selectors, /* OUT. May be NULL. */
+ unsigned int *default_index /* OUT. May be NULL. */);
+
+
+HB_END_DECLS
+
+#endif /* HB_AAT_LAYOUT_H */
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.hh
index 1d3407971ea..5fd47ed62ad 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-layout.hh
@@ -35,9 +35,9 @@
struct hb_aat_feature_mapping_t
{
hb_tag_t otFeatureTag;
- uint16_t aatFeatureType;
- uint16_t selectorToEnable;
- uint16_t selectorToDisable;
+ hb_aat_layout_feature_type_t aatFeatureType;
+ hb_aat_layout_feature_selector_t selectorToEnable;
+ hb_aat_layout_feature_selector_t selectorToDisable;
static inline int cmp (const void *key_, const void *entry_)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.cc
index 8bc1a0c6159..1c65a6759bc 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.cc
@@ -37,8 +37,8 @@ void hb_aat_map_builder_t::add_feature (hb_tag_t tag,
if (tag == HB_TAG ('a','a','l','t'))
{
feature_info_t *info = features.push();
- info->type = 17/*kCharacterAlternativesType*/;
- info->setting = value;
+ info->type = HB_AAT_LAYOUT_FEATURE_TYPE_CHARACTER_ALTERNATIVES;
+ info->setting = (hb_aat_layout_feature_selector_t) value;
return;
}
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.hh
index 07454b2c167..b033e336872 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat-map.hh
@@ -65,8 +65,8 @@ struct hb_aat_map_builder_t
public:
struct feature_info_t
{
- uint16_t type;
- uint16_t setting;
+ hb_aat_layout_feature_type_t type;
+ hb_aat_layout_feature_selector_t setting;
unsigned seq; /* For stable sorting only. */
static int cmp (const void *pa, const void *pb)
@@ -77,9 +77,9 @@ struct hb_aat_map_builder_t
(a->seq < b->seq ? -1 : a->seq > b->seq ? 1 : 0);
}
- int cmp (const short unsigned int *ty) const
+ int cmp (unsigned int ty) const
{
- return (type != *ty) ? (type < *ty ? -1 : 1) : 0;
+ return (type != ty) ? (type < ty ? -1 : 1) : 0;
}
};
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat.h b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat.h
new file mode 100644
index 00000000000..c14313d1e2e
--- /dev/null
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-aat.h
@@ -0,0 +1,38 @@
+/*
+ * Copyright © 2018 Ebrahim Byagowi
+ *
+ * This is part of HarfBuzz, a text shaping library.
+ *
+ * Permission is hereby granted, without written agreement and without
+ * license or royalty fees, to use, copy, modify, and distribute this
+ * software and its documentation for any purpose, provided that the
+ * above copyright notice and the following two paragraphs appear in
+ * all copies of this software.
+ *
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR
+ * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
+ * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN
+ * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
+ * DAMAGE.
+ *
+ * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING,
+ * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
+ * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO
+ * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
+ */
+
+#ifndef HB_AAT_H
+#define HB_AAT_H
+#define HB_AAT_H_IN
+
+#include "hb.h"
+
+#include "hb-aat-layout.h"
+
+HB_BEGIN_DECLS
+
+HB_END_DECLS
+
+#undef HB_AAT_H_IN
+#endif /* HB_AAT_H */
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-atomic.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-atomic.hh
index 64ed257bdd2..265de1267ac 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-atomic.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-atomic.hh
@@ -282,7 +282,7 @@ struct hb_atomic_int_t
template <typename P>
struct hb_atomic_ptr_t
{
- typedef typename hb_remove_pointer<P>::value T;
+ typedef typename hb_remove_pointer (P) T;
inline void init (T* v_ = nullptr) { set_relaxed (v_); }
inline void set_relaxed (T* v_) { hb_atomic_ptr_impl_set_relaxed (&v, v_); }
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-blob.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-blob.hh
index 802b1f07eb6..bf2132bda99 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-blob.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-blob.hh
@@ -60,7 +60,7 @@ struct hb_blob_t
template <typename Type>
inline const Type* as (void) const
{
- return length < Type::min_size ? &Null(Type) : reinterpret_cast<const Type *> (data);
+ return length < hb_null_size (Type) ? &Null(Type) : reinterpret_cast<const Type *> (data);
}
inline hb_bytes_t as_bytes (void) const
{
@@ -86,7 +86,7 @@ struct hb_blob_t
template <typename P>
struct hb_blob_ptr_t
{
- typedef typename hb_remove_pointer<P>::value T;
+ typedef typename hb_remove_pointer (P) T;
inline hb_blob_ptr_t (hb_blob_t *b_ = nullptr) : b (b_) {}
inline hb_blob_t * operator = (hb_blob_t *b_) { return b = b_; }
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-buffer.h b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-buffer.h
index 99e01716fb2..f989d25d6b4 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-buffer.h
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-buffer.h
@@ -90,6 +90,8 @@ typedef struct hb_glyph_info_t
* the reshaping to a small piece around the
* breaking point only.
* @HB_GLYPH_FLAG_DEFINED: All the currently defined flags.
+ *
+ * Since: 1.5.0
*/
typedef enum { /*< flags >*/
HB_GLYPH_FLAG_UNSAFE_TO_BREAK = 0x00000001,
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-common.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-common.cc
index 37be8a34e04..c3cffccb189 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-common.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-common.cc
@@ -204,7 +204,7 @@ static const char canon_map[256] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, '-', 0, 0,
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 0, 0, 0, 0, 0, 0,
- '-', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
+ 0, 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 0, 0, 0, 0, '-',
0, 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 0, 0, 0, 0, 0
@@ -276,7 +276,7 @@ struct hb_language_item_t {
static hb_atomic_ptr_t <hb_language_item_t> langs;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void
free_langs (void)
{
@@ -323,7 +323,7 @@ retry:
goto retry;
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
if (!first_lang)
atexit (free_langs); /* First person registers atexit() callback. */
#endif
@@ -780,18 +780,18 @@ parse_uint32 (const char **pp, const char *end, uint32_t *pv)
#ifdef USE_XLOCALE
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_C_locale (void);
#endif
-static struct hb_C_locale_lazy_loader_t : hb_lazy_loader_t<hb_remove_pointer<HB_LOCALE_T>::value,
+static struct hb_C_locale_lazy_loader_t : hb_lazy_loader_t<hb_remove_pointer (HB_LOCALE_T),
hb_C_locale_lazy_loader_t>
{
static inline HB_LOCALE_T create (void)
{
HB_LOCALE_T C_locale = HB_CREATE_LOCALE ("C");
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_C_locale);
#endif
@@ -807,7 +807,7 @@ static struct hb_C_locale_lazy_loader_t : hb_lazy_loader_t<hb_remove_pointer<HB_
}
} static_C_locale;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_C_locale (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-debug.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-debug.hh
index d218e432810..f13cfddb9c5 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-debug.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-debug.hh
@@ -293,14 +293,16 @@ struct hb_auto_trace_t
if (plevel) --*plevel;
}
- inline ret_t ret (ret_t v, unsigned int line = 0)
+ inline ret_t ret (ret_t v,
+ const char *func = "",
+ unsigned int line = 0)
{
if (unlikely (returned)) {
fprintf (stderr, "OUCH, double calls to return_trace(). This is a bug, please report.\n");
return v;
}
- _hb_debug_msg<max_level> (what, obj, nullptr, true, plevel ? *plevel : 1, -1,
+ _hb_debug_msg<max_level> (what, obj, func, true, plevel ? *plevel : 1, -1,
"return %s (line %d)",
hb_printer_t<ret_t>().print (v), line);
if (plevel) --*plevel;
@@ -325,17 +327,21 @@ struct hb_auto_trace_t<0, ret_t>
const char *message,
...) HB_PRINTF_FUNC(6, 7) {}
- inline ret_t ret (ret_t v, unsigned int line HB_UNUSED = 0) { return v; }
+ inline ret_t ret (ret_t v,
+ const char *func HB_UNUSED = 0,
+ unsigned int line HB_UNUSED = 0) { return v; }
};
/* For disabled tracing; optimize out everything.
* https://github.com/harfbuzz/harfbuzz/pull/605 */
template <typename ret_t>
struct hb_no_trace_t {
- inline ret_t ret (ret_t v, unsigned int line HB_UNUSED = 0) { return v; }
+ inline ret_t ret (ret_t v,
+ const char *func HB_UNUSED = "",
+ unsigned int line HB_UNUSED = 0) { return v; }
};
-#define return_trace(RET) return trace.ret (RET, __LINE__)
+#define return_trace(RET) return trace.ret (RET, HB_FUNC, __LINE__)
/*
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-deprecated.h b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-deprecated.h
index e39b79f74e5..9ceb264816c 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-deprecated.h
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-deprecated.h
@@ -241,6 +241,43 @@ HB_EXTERN HB_DEPRECATED_FOR (hb_ot_tags_from_script_and_language) hb_tag_t
hb_ot_tag_from_language (hb_language_t language);
+typedef unsigned int hb_ot_name_id_t; /* Since is in hb-ot.h */
+
+/**
+ * HB_OT_VAR_NO_AXIS_INDEX:
+ *
+ * Since: 1.4.2
+ * Deprecated: 2.2.0
+ */
+#define HB_OT_VAR_NO_AXIS_INDEX 0xFFFFFFFFu
+
+/**
+ * hb_ot_var_axis_t:
+ *
+ * Since: 1.4.2
+ * Deprecated: 2.2.0
+ */
+typedef struct hb_ot_var_axis_t
+{
+ hb_tag_t tag;
+ hb_ot_name_id_t name_id;
+ float min_value;
+ float default_value;
+ float max_value;
+} hb_ot_var_axis_t;
+
+HB_EXTERN HB_DEPRECATED_FOR (hb_ot_var_get_axis_infos) unsigned int
+hb_ot_var_get_axes (hb_face_t *face,
+ unsigned int start_offset,
+ unsigned int *axes_count /* IN/OUT */,
+ hb_ot_var_axis_t *axes_array /* OUT */);
+
+HB_EXTERN HB_DEPRECATED_FOR (hb_ot_var_find_axis_info) hb_bool_t
+hb_ot_var_find_axis (hb_face_t *face,
+ hb_tag_t axis_tag,
+ unsigned int *axis_index,
+ hb_ot_var_axis_t *axis_info);
+
#endif
HB_END_DECLS
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-dsalgs.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-dsalgs.hh
index 7a207f5d24a..5773596019d 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-dsalgs.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-dsalgs.hh
@@ -560,9 +560,15 @@ struct hb_bytes_t
};
template <typename Type>
+struct hb_sorted_array_t;
+
+template <typename Type>
struct hb_array_t
{
+ static_assert ((bool) (unsigned) hb_static_size (Type), "");
+
inline hb_array_t (void) : arrayZ (nullptr), len (0) {}
+ inline hb_array_t (const hb_array_t &o) : arrayZ (o.arrayZ), len (o.len) {}
inline hb_array_t (Type *array_, unsigned int len_) : arrayZ (array_), len (len_) {}
inline Type& operator [] (unsigned int i) const
@@ -571,33 +577,160 @@ struct hb_array_t
return arrayZ[i];
}
- inline unsigned int get_size (void) const { return len * sizeof (Type); }
-
template <typename T> inline operator T * (void) const { return arrayZ; }
inline Type * operator & (void) const { return arrayZ; }
- inline hb_array_t<Type> sub_array (unsigned int start_offset, unsigned int seg_count) const
+ inline unsigned int get_size (void) const { return len * sizeof (Type); }
+
+ inline hb_array_t<Type> sub_array (unsigned int start_offset, unsigned int *seg_count /* IN/OUT */) const
{
+ if (!seg_count) return hb_array_t<Type> ();
+
unsigned int count = len;
if (unlikely (start_offset > count))
count = 0;
else
count -= start_offset;
- count = MIN (count, seg_count);
+ count = *seg_count = MIN (count, *seg_count);
return hb_array_t<Type> (arrayZ + start_offset, count);
}
+ inline hb_array_t<Type> sub_array (unsigned int start_offset, unsigned int seg_count) const
+ { return sub_array (start_offset, &seg_count); }
inline hb_bytes_t as_bytes (void) const
+ { return hb_bytes_t (arrayZ, len * sizeof (Type)); }
+
+ template <typename T>
+ inline Type *lsearch (const T &x,
+ Type *not_found = nullptr)
{
- return hb_bytes_t (arrayZ, len * sizeof (Type));
+ unsigned int count = len;
+ for (unsigned int i = 0; i < count; i++)
+ if (!this->arrayZ[i].cmp (x))
+ return &this->arrayZ[i];
+ return not_found;
+ }
+ template <typename T>
+ inline const Type *lsearch (const T &x,
+ const Type *not_found = nullptr) const
+ {
+ unsigned int count = len;
+ for (unsigned int i = 0; i < count; i++)
+ if (!this->arrayZ[i].cmp (x))
+ return &this->arrayZ[i];
+ return not_found;
}
- inline void free (void) { ::free ((void *) arrayZ); arrayZ = nullptr; len = 0; }
+ inline hb_sorted_array_t<Type> qsort (int (*cmp)(const void*, const void*))
+ {
+ ::qsort (arrayZ, len, sizeof (Type), cmp);
+ return hb_sorted_array_t<Type> (*this);
+ }
+ inline hb_sorted_array_t<Type> qsort (void)
+ {
+ ::qsort (arrayZ, len, sizeof (Type), Type::cmp);
+ return hb_sorted_array_t<Type> (*this);
+ }
+ inline void qsort (unsigned int start, unsigned int end)
+ {
+ end = MIN (end, len);
+ assert (start <= end);
+ ::qsort (arrayZ + start, end - start, sizeof (Type), Type::cmp);
+ }
+ inline void free (void)
+ { ::free ((void *) arrayZ); arrayZ = nullptr; len = 0; }
+
+ template <typename hb_sanitize_context_t>
+ inline bool sanitize (hb_sanitize_context_t *c) const
+ { return c->check_array (arrayZ, len); }
+
+ public:
Type *arrayZ;
unsigned int len;
};
+template <typename T>
+inline hb_array_t<T> hb_array (T *array, unsigned int len)
+{ return hb_array_t<T> (array, len); }
+
+enum hb_bfind_not_found_t
+{
+ HB_BFIND_NOT_FOUND_DONT_STORE,
+ HB_BFIND_NOT_FOUND_STORE,
+ HB_BFIND_NOT_FOUND_STORE_CLOSEST,
+};
+
+template <typename Type>
+struct hb_sorted_array_t : hb_array_t<Type>
+{
+ inline hb_sorted_array_t (void) : hb_array_t<Type> () {}
+ inline hb_sorted_array_t (const hb_array_t<Type> &o) : hb_array_t<Type> (o) {}
+ inline hb_sorted_array_t (Type *array_, unsigned int len_) : hb_array_t<Type> (array_, len_) {}
+
+ inline hb_sorted_array_t<Type> sub_array (unsigned int start_offset, unsigned int *seg_count /* IN/OUT */) const
+ { return hb_sorted_array_t<Type> (((const hb_array_t<Type> *) (this))->sub_array (start_offset, seg_count)); }
+ inline hb_sorted_array_t<Type> sub_array (unsigned int start_offset, unsigned int seg_count) const
+ { return sub_array (start_offset, &seg_count); }
+
+ template <typename T>
+ inline Type *bsearch (const T &x, Type *not_found = nullptr)
+ {
+ unsigned int i;
+ return bfind (x, &i) ? &this->arrayZ[i] : not_found;
+ }
+ template <typename T>
+ inline const Type *bsearch (const T &x, const Type *not_found = nullptr) const
+ {
+ unsigned int i;
+ return bfind (x, &i) ? &this->arrayZ[i] : not_found;
+ }
+ template <typename T>
+ inline bool bfind (const T &x, unsigned int *i = nullptr,
+ hb_bfind_not_found_t not_found = HB_BFIND_NOT_FOUND_DONT_STORE,
+ unsigned int to_store = (unsigned int) -1) const
+ {
+ int min = 0, max = (int) this->len - 1;
+ const Type *array = this->arrayZ;
+ while (min <= max)
+ {
+ int mid = ((unsigned int) min + (unsigned int) max) / 2;
+ int c = array[mid].cmp (x);
+ if (c < 0)
+ max = mid - 1;
+ else if (c > 0)
+ min = mid + 1;
+ else
+ {
+ if (i)
+ *i = mid;
+ return true;
+ }
+ }
+ if (i)
+ {
+ switch (not_found)
+ {
+ case HB_BFIND_NOT_FOUND_DONT_STORE:
+ break;
+
+ case HB_BFIND_NOT_FOUND_STORE:
+ *i = to_store;
+ break;
+
+ case HB_BFIND_NOT_FOUND_STORE_CLOSEST:
+ if (max < 0 || (max < (int) this->len && array[max].cmp (x) > 0))
+ max++;
+ *i = max;
+ break;
+ }
+ }
+ return false;
+ }
+};
+template <typename T>
+inline hb_sorted_array_t<T> hb_sorted_array (T *array, unsigned int len)
+{ return hb_sorted_array_t<T> (array, len); }
struct HbOpOr
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-face.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-face.cc
index e23842fb143..5b33784f45c 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-face.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-face.cc
@@ -588,10 +588,10 @@ struct hb_face_builder_data_t
{
struct table_entry_t
{
- inline int cmp (const hb_tag_t *t) const
+ inline int cmp (hb_tag_t t) const
{
- if (*t < tag) return -1;
- if (*t > tag) return -1;
+ if (t < tag) return -1;
+ if (t > tag) return -1;
return 0;
}
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ft.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ft.cc
index 9b9d787de41..633e0ecd2c8 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ft.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ft.cc
@@ -478,7 +478,7 @@ hb_ft_get_font_h_extents (hb_font_t *font HB_UNUSED,
return true;
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_ft_funcs (void);
#endif
@@ -504,7 +504,7 @@ static struct hb_ft_font_funcs_lazy_loader_t : hb_font_funcs_lazy_loader_t<hb_ft
hb_font_funcs_make_immutable (funcs);
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_ft_funcs);
#endif
@@ -512,7 +512,7 @@ static struct hb_ft_font_funcs_lazy_loader_t : hb_font_funcs_lazy_loader_t<hb_ft
}
} static_ft_funcs;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_ft_funcs (void)
{
@@ -744,11 +744,11 @@ hb_ft_font_create_referenced (FT_Face ft_face)
return hb_ft_font_create (ft_face, _hb_ft_face_destroy);
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_ft_library (void);
#endif
-static struct hb_ft_library_lazy_loader_t : hb_lazy_loader_t<hb_remove_pointer<FT_Library>::value,
+static struct hb_ft_library_lazy_loader_t : hb_lazy_loader_t<hb_remove_pointer (FT_Library),
hb_ft_library_lazy_loader_t>
{
static inline FT_Library create (void)
@@ -757,7 +757,7 @@ static struct hb_ft_library_lazy_loader_t : hb_lazy_loader_t<hb_remove_pointer<F
if (FT_Init_FreeType (&l))
return nullptr;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_ft_library);
#endif
@@ -773,7 +773,7 @@ static struct hb_ft_library_lazy_loader_t : hb_lazy_loader_t<hb_remove_pointer<F
}
} static_ft_library;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_ft_library (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-glib.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-glib.cc
index 23a0d89c86b..cb7e7096e34 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-glib.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-glib.cc
@@ -336,7 +336,7 @@ hb_glib_unicode_decompose (hb_unicode_funcs_t *ufuncs HB_UNUSED,
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_glib_funcs (void);
#endif
@@ -355,7 +355,7 @@ static struct hb_glib_unicode_funcs_lazy_loader_t : hb_unicode_funcs_lazy_loader
hb_unicode_funcs_make_immutable (funcs);
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_glib_funcs);
#endif
@@ -363,7 +363,7 @@ static struct hb_glib_unicode_funcs_lazy_loader_t : hb_unicode_funcs_lazy_loader
}
} static_glib_funcs;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_glib_funcs (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-icu.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-icu.cc
index 12864677c35..287f863404d 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-icu.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-icu.cc
@@ -65,7 +65,8 @@ hb_icu_script_from_script (hb_script_t script)
if (unlikely (script == HB_SCRIPT_INVALID))
return USCRIPT_INVALID_CODE;
- for (unsigned int i = 0; i < USCRIPT_CODE_LIMIT; i++)
+ unsigned int numScriptCode = 1 + u_getIntPropertyMaxValue (UCHAR_SCRIPT);
+ for (unsigned int i = 0; i < numScriptCode; i++)
if (unlikely (hb_icu_script_to_script ((UScriptCode) i) == script))
return (UScriptCode) i;
@@ -300,7 +301,7 @@ hb_icu_unicode_decompose (hb_unicode_funcs_t *ufuncs HB_UNUSED,
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_icu_funcs (void);
#endif
@@ -326,7 +327,7 @@ static struct hb_icu_unicode_funcs_lazy_loader_t : hb_unicode_funcs_lazy_loader_
hb_unicode_funcs_make_immutable (funcs);
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_icu_funcs);
#endif
@@ -334,7 +335,7 @@ static struct hb_icu_unicode_funcs_lazy_loader_t : hb_unicode_funcs_lazy_loader_
}
} static_icu_funcs;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_icu_funcs (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-machinery.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-machinery.hh
index 3c11243f5a1..39e962936db 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-machinery.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-machinery.hh
@@ -82,8 +82,7 @@ static inline Type& StructAfter(TObject &X)
/* Check _assertion in a method environment */
#define _DEFINE_INSTANCE_ASSERTION1(_line, _assertion) \
inline void _instance_assertion_on_line_##_line (void) const \
- { static_assert ((_assertion), ""); } \
- static_assert (true, "") /* So we require semicolon here. */
+ { static_assert ((_assertion), ""); }
# define _DEFINE_INSTANCE_ASSERTION0(_line, _assertion) _DEFINE_INSTANCE_ASSERTION1 (_line, _assertion)
# define DEFINE_INSTANCE_ASSERTION(_assertion) _DEFINE_INSTANCE_ASSERTION0 (__LINE__, _assertion)
@@ -96,32 +95,36 @@ static inline Type& StructAfter(TObject &X)
#define DEFINE_SIZE_STATIC(size) \
- DEFINE_INSTANCE_ASSERTION (sizeof (*this) == (size)); \
+ DEFINE_INSTANCE_ASSERTION (sizeof (*this) == (size)) \
inline unsigned int get_size (void) const { return (size); } \
- enum { static_size = (size) }; \
- enum { min_size = (size) }
+ enum { null_size = (size) }; \
+ enum { min_size = (size) }; \
+ enum { static_size = (size) }
#define DEFINE_SIZE_UNION(size, _member) \
- DEFINE_INSTANCE_ASSERTION (0*sizeof(this->u._member.static_size) + sizeof(this->u._member) == (size)); \
- static const unsigned int min_size = (size)
+ DEFINE_COMPILES_ASSERTION ((void) this->u._member.static_size) \
+ DEFINE_INSTANCE_ASSERTION (sizeof(this->u._member) == (size)) \
+ enum { null_size = (size) }; \
+ enum { min_size = (size) }
#define DEFINE_SIZE_MIN(size) \
- DEFINE_INSTANCE_ASSERTION (sizeof (*this) >= (size)); \
- static const unsigned int min_size = (size)
+ DEFINE_INSTANCE_ASSERTION (sizeof (*this) >= (size)) \
+ enum { null_size = (size) }; \
+ enum { min_size = (size) }
+
+#define DEFINE_SIZE_UNBOUNDED(size) \
+ DEFINE_INSTANCE_ASSERTION (sizeof (*this) >= (size)) \
+ enum { min_size = (size) }
#define DEFINE_SIZE_ARRAY(size, array) \
- DEFINE_INSTANCE_ASSERTION (sizeof (*this) == (size) + VAR * sizeof ((array)[0])); \
DEFINE_COMPILES_ASSERTION ((void) (array)[0].static_size) \
+ DEFINE_INSTANCE_ASSERTION (sizeof (*this) == (size) + VAR * sizeof ((array)[0])) \
+ enum { null_size = (size) }; \
enum { min_size = (size) }
#define DEFINE_SIZE_ARRAY_SIZED(size, array) \
- inline unsigned int get_size (void) const { return (size - (array).min_size + (array).get_size ()); } \
- DEFINE_SIZE_ARRAY(size, array)
-
-#define DEFINE_SIZE_ARRAY2(size, array1, array2) \
- DEFINE_INSTANCE_ASSERTION (sizeof (*this) == (size) + sizeof (this->array1[0]) + sizeof (this->array2[0])); \
- DEFINE_COMPILES_ASSERTION ((void) (array1)[0].static_size; (void) (array2)[0].static_size) \
- static const unsigned int min_size = (size)
+ inline unsigned int get_size (void) const { return (size - (array).min_size + (array).get_size ()); } \
+ DEFINE_SIZE_ARRAY(size, array)
/*
@@ -256,26 +259,36 @@ struct hb_sanitize_context_t :
inline void set_max_ops (int max_ops_) { max_ops = max_ops_; }
- /* TODO
- * This set_object() thing is to use sanitize at runtime lookup
- * application time. This is very distinct from the regular
- * sanitizer operation, so, eventually, separate into another
- * type and make hb_aat_apply_context_t use that one instead
- * of abusing this one.
- */
template <typename T>
- inline void set_object (const T& obj)
+ inline void set_object (const T *obj)
{
- this->start = (const char *) &obj;
- this->end = (const char *) &obj + obj.get_size ();
- assert (this->start <= this->end); /* Must not overflow. */
+ reset_object ();
+
+ if (!obj) return;
+
+ const char *obj_start = (const char *) obj;
+ const char *obj_end = (const char *) obj + obj->get_size ();
+ assert (obj_start <= obj_end); /* Must not overflow. */
+
+ if (unlikely (obj_end < this->start || this->end < obj_start))
+ this->start = this->end = nullptr;
+ else
+ {
+ this->start = MAX (this->start, obj_start);
+ this->end = MIN (this->end , obj_end );
+ }
}
- inline void start_processing (void)
+ inline void reset_object (void)
{
this->start = this->blob->data;
this->end = this->start + this->blob->length;
assert (this->start <= this->end); /* Must not overflow. */
+ }
+
+ inline void start_processing (void)
+ {
+ reset_object ();
this->max_ops = MAX ((unsigned int) (this->end - this->start) * HB_SANITIZE_MAX_OPS_FACTOR,
(unsigned) HB_SANITIZE_MAX_OPS_MIN);
this->edit_count = 0;
@@ -469,6 +482,23 @@ struct hb_sanitize_context_t :
bool num_glyphs_set;
};
+struct hb_sanitize_with_object_t
+{
+ template <typename T>
+ inline hb_sanitize_with_object_t (hb_sanitize_context_t *c,
+ const T& obj) : c (c)
+ {
+ c->set_object (obj);
+ }
+ inline ~hb_sanitize_with_object_t (void)
+ {
+ c->reset_object ();
+ }
+
+ private:
+ hb_sanitize_context_t *c;
+};
+
/*
* Serialize
@@ -691,6 +721,12 @@ struct BEInt<Type, 2>
}
inline operator Type (void) const
{
+#if defined(__GNUC__) || defined(__clang__)
+ /* Spoon-feed the compiler a big-endian integer with alignment 1.
+ * https://github.com/harfbuzz/harfbuzz/pull/1398 */
+ struct __attribute__((packed)) packed_uint16_t { uint16_t v; };
+ return __builtin_bswap16 (((packed_uint16_t *) this)->v);
+#endif
return (v[0] << 8)
+ (v[1] );
}
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-null.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-null.hh
index 25a24f05cb4..1583d5b90e0 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-null.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-null.hh
@@ -38,21 +38,60 @@
#define HB_NULL_POOL_SIZE 1024
+/* Use SFINAE to sniff whether T has min_size; in which case return T::null_size,
+ * otherwise return sizeof(T). */
+
+/* The hard way...
+ * https://stackoverflow.com/questions/7776448/sfinae-tried-with-bool-gives-compiler-error-template-argument-tvalue-invol
+ */
+
+template<bool> struct _hb_bool_type {};
+
+template <typename T, typename B>
+struct _hb_null_size
+{ enum { value = sizeof (T) }; };
+template <typename T>
+struct _hb_null_size<T, _hb_bool_type<(bool) (1 + (unsigned int) T::min_size)> >
+{ enum { value = T::null_size }; };
+
+template <typename T>
+struct hb_null_size
+{ enum { value = _hb_null_size<T, _hb_bool_type<true> >::value }; };
+#define hb_null_size(T) hb_null_size<T>::value
+
+/* This doesn't belong here, but since is copy/paste from above, put it here. */
+
+template <typename T, typename B>
+struct _hb_static_size
+{ enum { value = sizeof (T) }; };
+template <typename T>
+struct _hb_static_size<T, _hb_bool_type<(bool) (1 + (unsigned int) T::min_size)> >
+{ enum { value = T::static_size }; };
+
+template <typename T>
+struct hb_static_size
+{ enum { value = _hb_static_size<T, _hb_bool_type<true> >::value }; };
+#define hb_static_size(T) hb_static_size<T>::value
+
+
+/*
+ * Null()
+ */
extern HB_INTERNAL
hb_vector_size_impl_t const _hb_NullPool[(HB_NULL_POOL_SIZE + sizeof (hb_vector_size_impl_t) - 1) / sizeof (hb_vector_size_impl_t)];
/* Generic nul-content Null objects. */
template <typename Type>
static inline Type const & Null (void) {
- static_assert (sizeof (Type) <= HB_NULL_POOL_SIZE, "Increase HB_NULL_POOL_SIZE.");
+ static_assert (hb_null_size (Type) <= HB_NULL_POOL_SIZE, "Increase HB_NULL_POOL_SIZE.");
return *reinterpret_cast<Type const *> (_hb_NullPool);
}
-#define Null(Type) Null<typename hb_remove_const<typename hb_remove_reference<Type>::value>::value>()
+#define Null(Type) Null<typename hb_remove_const (typename hb_remove_reference (Type))> ()
/* Specializations for arbitrary-content Null objects expressed in bytes. */
#define DECLARE_NULL_NAMESPACE_BYTES(Namespace, Type) \
} /* Close namespace. */ \
- extern HB_INTERNAL const unsigned char _hb_Null_##Namespace##_##Type[Namespace::Type::min_size]; \
+ extern HB_INTERNAL const unsigned char _hb_Null_##Namespace##_##Type[Namespace::Type::null_size]; \
template <> \
/*static*/ inline const Namespace::Type& Null<Namespace::Type> (void) { \
return *reinterpret_cast<const Namespace::Type *> (_hb_Null_##Namespace##_##Type); \
@@ -60,7 +99,7 @@ static inline Type const & Null (void) {
namespace Namespace { \
static_assert (true, "Just so we take semicolon after.")
#define DEFINE_NULL_NAMESPACE_BYTES(Namespace, Type) \
- const unsigned char _hb_Null_##Namespace##_##Type[Namespace::Type::min_size]
+ const unsigned char _hb_Null_##Namespace##_##Type[Namespace::Type::null_size]
/* Specializations for arbitrary-content Null objects expressed as struct initializer. */
#define DECLARE_NULL_INSTANCE(Type) \
@@ -85,12 +124,12 @@ extern HB_INTERNAL
/* CRAP pool: Common Region for Access Protection. */
template <typename Type>
static inline Type& Crap (void) {
- static_assert (sizeof (Type) <= HB_NULL_POOL_SIZE, "Increase HB_NULL_POOL_SIZE.");
+ static_assert (hb_null_size (Type) <= HB_NULL_POOL_SIZE, "Increase HB_NULL_POOL_SIZE.");
Type *obj = reinterpret_cast<Type *> (_hb_CrapPool);
memcpy (obj, &Null(Type), sizeof (*obj));
return *obj;
}
-#define Crap(Type) Crap<typename hb_remove_const<typename hb_remove_reference<Type>::value>::value>()
+#define Crap(Type) Crap<typename hb_remove_const (typename hb_remove_reference (Type))> ()
template <typename Type>
struct CrapOrNull {
@@ -110,7 +149,7 @@ struct CrapOrNull<const Type> {
template <typename P>
struct hb_nonnull_ptr_t
{
- typedef typename hb_remove_pointer<P>::value T;
+ typedef typename hb_remove_pointer (P) T;
inline hb_nonnull_ptr_t (T *v_ = nullptr) : v (v_) {}
inline T * operator = (T *v_) { return v = v_; }
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-file.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-file.hh
index 2ef6d775f3f..af68892ab11 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-file.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-file.hh
@@ -111,12 +111,7 @@ typedef struct OffsetTable
{
Tag t;
t.set (tag);
- /* Linear-search for small tables to work around fonts with unsorted
- * table list. */
- int i = tables.len < 64 ? tables.lsearch (t) : tables.bsearch (t);
- if (table_index)
- *table_index = i == -1 ? (unsigned) Index::NOT_FOUND_INDEX : (unsigned) i;
- return i != -1;
+ return tables.bfind (t, table_index, HB_BFIND_NOT_FOUND_STORE, Index::NOT_FOUND_INDEX);
}
inline const TableRecord& get_table_by_tag (hb_tag_t tag) const
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-type.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-type.hh
index b1fcd68777f..f4d0238ea07 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-type.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-open-type.hh
@@ -231,22 +231,31 @@ struct FixedVersion
* Use: (base+offset)
*/
-template <typename Type, bool has_null_> struct assert_has_min_size { static_assert (Type::min_size > 0, ""); };
-template <typename Type> struct assert_has_min_size<Type, false> {};
+template <typename Type, bool has_null>
+struct _hb_has_null
+{
+ static inline const Type *get_null (void) { return nullptr; }
+ static inline Type *get_crap (void) { return nullptr; }
+};
+template <typename Type>
+struct _hb_has_null<Type, true>
+{
+ static inline const Type *get_null (void) { return &Null(Type); }
+ static inline Type *get_crap (void) { return &Crap(Type); }
+};
template <typename Type, typename OffsetType=HBUINT16, bool has_null=true>
struct OffsetTo : Offset<OffsetType, has_null>
{
- static_assert (sizeof (assert_has_min_size<Type, has_null>) || true, "");
-
inline const Type& operator () (const void *base) const
{
- if (unlikely (this->is_null ())) return Null (Type);
+ if (unlikely (this->is_null ())) return *_hb_has_null<Type, has_null>::get_null ();
return StructAtOffset<const Type> (base, *this);
}
inline Type& operator () (void *base) const
{
if (unlikely (this->is_null ())) return Crap (Type);
+ if (unlikely (this->is_null ())) return *_hb_has_null<Type, has_null>::get_crap ();
return StructAtOffset<Type> (base, *this);
}
@@ -322,6 +331,7 @@ struct OffsetTo : Offset<OffsetType, has_null>
DEFINE_SIZE_STATIC (sizeof (OffsetType));
};
template <typename Type, bool has_null=true> struct LOffsetTo : OffsetTo<Type, HBUINT32, has_null> {};
+
template <typename Base, typename OffsetType, bool has_null, typename Type>
static inline const Type& operator + (const Base &base, const OffsetTo<Type, OffsetType, has_null> &offset) { return offset (base); }
template <typename Base, typename OffsetType, bool has_null, typename Type>
@@ -335,6 +345,8 @@ static inline Type& operator + (Base &base, OffsetTo<Type, OffsetType, has_null>
template <typename Type>
struct UnsizedArrayOf
{
+ static_assert ((bool) (unsigned) hb_static_size (Type), "");
+
enum { item_size = Type::static_size };
HB_NO_CREATE_COPY_ASSIGN_TEMPLATE (UnsizedArrayOf, Type);
@@ -358,8 +370,20 @@ struct UnsizedArrayOf
inline unsigned int get_size (unsigned int len) const
{ return len * Type::static_size; }
- inline hb_array_t<Type> as_array (unsigned int len) { return hb_array_t<Type> (arrayZ, len); }
- inline hb_array_t<const Type> as_array (unsigned int len) const { return hb_array_t<const Type> (arrayZ, len); }
+ inline hb_array_t<Type> as_array (unsigned int len)
+ { return hb_array (arrayZ, len); }
+ inline hb_array_t<const Type> as_array (unsigned int len) const
+ { return hb_array (arrayZ, len); }
+
+ template <typename T>
+ inline Type &lsearch (unsigned int len, const T &x, Type &not_found = Crap (Type))
+ { return *as_array (len).lsearch (x, &not_found); }
+ template <typename T>
+ inline const Type &lsearch (unsigned int len, const T &x, const Type &not_found = Null (Type)) const
+ { return *as_array (len).lsearch (x, &not_found); }
+
+ inline void qsort (unsigned int len, unsigned int start = 0, unsigned int end = (unsigned int) -1)
+ { as_array (len).qsort (start, end); }
inline bool sanitize (hb_sanitize_context_t *c, unsigned int count) const
{
@@ -406,7 +430,7 @@ struct UnsizedArrayOf
public:
Type arrayZ[VAR];
public:
- DEFINE_SIZE_ARRAY (0, arrayZ);
+ DEFINE_SIZE_UNBOUNDED (0);
};
/* Unsized array of offset's */
@@ -419,9 +443,18 @@ struct UnsizedOffsetListOf : UnsizedOffsetArrayOf<Type, OffsetType, has_null>
{
inline const Type& operator [] (unsigned int i) const
{
- return this+this->arrayZ[i];
+ const OffsetTo<Type, OffsetType, has_null> *p = &this->arrayZ[i];
+ if (unlikely (p < this->arrayZ)) return Null (Type); /* Overflowed. */
+ return this+*p;
+ }
+ inline Type& operator [] (unsigned int i)
+ {
+ const OffsetTo<Type, OffsetType, has_null> *p = &this->arrayZ[i];
+ if (unlikely (p < this->arrayZ)) return Crap (Type); /* Overflowed. */
+ return this+*p;
}
+
inline bool sanitize (hb_sanitize_context_t *c, unsigned int count) const
{
TRACE_SANITIZE (this);
@@ -435,26 +468,39 @@ struct UnsizedOffsetListOf : UnsizedOffsetArrayOf<Type, OffsetType, has_null>
}
};
+/* An array with sorted elements. Supports binary searching. */
+template <typename Type>
+struct SortedUnsizedArrayOf : UnsizedArrayOf<Type>
+{
+ inline hb_sorted_array_t<Type> as_array (unsigned int len)
+ { return hb_sorted_array (this->arrayZ, len); }
+ inline hb_sorted_array_t<const Type> as_array (unsigned int len) const
+ { return hb_sorted_array (this->arrayZ, len); }
+
+ template <typename T>
+ inline Type &bsearch (unsigned int len, const T &x, Type &not_found = Crap (Type))
+ { return *as_array (len).bsearch (x, &not_found); }
+ template <typename T>
+ inline const Type &bsearch (unsigned int len, const T &x, const Type &not_found = Null (Type)) const
+ { return *as_array (len).bsearch (x, &not_found); }
+ template <typename T>
+ inline bool bfind (unsigned int len, const T &x, unsigned int *i = nullptr,
+ hb_bfind_not_found_t not_found = HB_BFIND_NOT_FOUND_DONT_STORE,
+ unsigned int to_store = (unsigned int) -1) const
+ { return as_array (len).bfind (x, i, not_found, to_store); }
+};
+
+
/* An array with a number of elements. */
template <typename Type, typename LenType=HBUINT16>
struct ArrayOf
{
+ static_assert ((bool) (unsigned) hb_static_size (Type), "");
+
enum { item_size = Type::static_size };
HB_NO_CREATE_COPY_ASSIGN_TEMPLATE2 (ArrayOf, Type, LenType);
- inline const Type *sub_array (unsigned int start_offset, unsigned int *pcount /* IN/OUT */) const
- {
- unsigned int count = len;
- if (unlikely (start_offset > count))
- count = 0;
- else
- count -= start_offset;
- count = MIN (count, *pcount);
- *pcount = count;
- return arrayZ + start_offset;
- }
-
inline const Type& operator [] (unsigned int i) const
{
if (unlikely (i >= len)) return Null (Type);
@@ -469,6 +515,20 @@ struct ArrayOf
inline unsigned int get_size (void) const
{ return len.static_size + len * Type::static_size; }
+ inline hb_array_t<Type> as_array (void)
+ { return hb_array (arrayZ, len); }
+ inline hb_array_t<const Type> as_array (void) const
+ { return hb_array (arrayZ, len); }
+
+ inline hb_array_t<const Type> sub_array (unsigned int start_offset, unsigned int count) const
+ { return as_array ().sub_array (start_offset, count);}
+ inline hb_array_t<const Type> sub_array (unsigned int start_offset, unsigned int *count /* IN/OUT */) const
+ { return as_array ().sub_array (start_offset, count);}
+ inline hb_array_t<Type> sub_array (unsigned int start_offset, unsigned int count)
+ { return as_array ().sub_array (start_offset, count);}
+ inline hb_array_t<Type> sub_array (unsigned int start_offset, unsigned int *count /* IN/OUT */)
+ { return as_array ().sub_array (start_offset, count);}
+
inline bool serialize (hb_serialize_context_t *c,
unsigned int items_len)
{
@@ -528,20 +588,15 @@ struct ArrayOf
return_trace (true);
}
- template <typename SearchType>
- inline int lsearch (const SearchType &x) const
- {
- unsigned int count = len;
- for (unsigned int i = 0; i < count; i++)
- if (!this->arrayZ[i].cmp (x))
- return i;
- return -1;
- }
+ template <typename T>
+ inline Type &lsearch (const T &x, Type &not_found = Crap (Type))
+ { return *as_array ().lsearch (x, &not_found); }
+ template <typename T>
+ inline const Type &lsearch (const T &x, const Type &not_found = Null (Type)) const
+ { return *as_array ().lsearch (x, &not_found); }
- inline void qsort (void)
- {
- ::qsort (arrayZ, len, sizeof (Type), Type::cmp);
- }
+ inline void qsort (unsigned int start = 0, unsigned int end = (unsigned int) -1)
+ { as_array ().qsort (start, end); }
inline bool sanitize_shallow (hb_sanitize_context_t *c) const
{
@@ -723,22 +778,31 @@ struct ArrayOfM1
template <typename Type, typename LenType=HBUINT16>
struct SortedArrayOf : ArrayOf<Type, LenType>
{
- template <typename SearchType>
- inline int bsearch (const SearchType &x) const
- {
- /* Hand-coded bsearch here since this is in the hot inner loop. */
- const Type *arr = this->arrayZ;
- int min = 0, max = (int) this->len - 1;
- while (min <= max)
- {
- int mid = ((unsigned int) min + (unsigned int) max) / 2;
- int c = arr[mid].cmp (x);
- if (c < 0) max = mid - 1;
- else if (c > 0) min = mid + 1;
- else return mid;
- }
- return -1;
- }
+ inline hb_sorted_array_t<Type> as_array (void)
+ { return hb_sorted_array (this->arrayZ, this->len); }
+ inline hb_sorted_array_t<const Type> as_array (void) const
+ { return hb_sorted_array (this->arrayZ, this->len); }
+
+ inline hb_array_t<const Type> sub_array (unsigned int start_offset, unsigned int count) const
+ { return as_array ().sub_array (start_offset, count);}
+ inline hb_array_t<const Type> sub_array (unsigned int start_offset, unsigned int *count /* IN/OUT */) const
+ { return as_array ().sub_array (start_offset, count);}
+ inline hb_array_t<Type> sub_array (unsigned int start_offset, unsigned int count)
+ { return as_array ().sub_array (start_offset, count);}
+ inline hb_array_t<Type> sub_array (unsigned int start_offset, unsigned int *count /* IN/OUT */)
+ { return as_array ().sub_array (start_offset, count);}
+
+ template <typename T>
+ inline Type &bsearch (const T &x, Type &not_found = Crap (Type))
+ { return *as_array ().bsearch (x, &not_found); }
+ template <typename T>
+ inline const Type &bsearch (const T &x, const Type &not_found = Null (Type)) const
+ { return *as_array ().bsearch (x, &not_found); }
+ template <typename T>
+ inline bool bfind (const T &x, unsigned int *i = nullptr,
+ hb_bfind_not_found_t not_found = HB_BFIND_NOT_FOUND_DONT_STORE,
+ unsigned int to_store = (unsigned int) -1) const
+ { return as_array ().bfind (x, i, not_found, to_store); }
};
/*
@@ -810,15 +874,36 @@ struct VarSizedBinSearchArrayOf
HB_NO_CREATE_COPY_ASSIGN_TEMPLATE (VarSizedBinSearchArrayOf, Type);
+ inline bool last_is_terminator (void) const
+ {
+ if (unlikely (!header.nUnits)) return false;
+
+ /* Gah.
+ *
+ * "The number of termination values that need to be included is table-specific.
+ * The value that indicates binary search termination is 0xFFFF." */
+ const HBUINT16 *words = &StructAtOffset<HBUINT16> (&bytesZ, (header.nUnits - 1) * header.unitSize);
+ unsigned int count = Type::TerminationWordCount;
+ for (unsigned int i = 0; i < count; i++)
+ if (words[i] != 0xFFFFu)
+ return false;
+ return true;
+ }
+
inline const Type& operator [] (unsigned int i) const
{
- if (unlikely (i >= header.nUnits)) return Null (Type);
+ if (unlikely (i >= get_length ())) return Null (Type);
return StructAtOffset<Type> (&bytesZ, i * header.unitSize);
}
inline Type& operator [] (unsigned int i)
{
+ if (unlikely (i >= get_length ())) return Crap (Type);
return StructAtOffset<Type> (&bytesZ, i * header.unitSize);
}
+ inline unsigned int get_length (void) const
+ {
+ return header.nUnits - last_is_terminator ();
+ }
inline unsigned int get_size (void) const
{ return header.static_size + header.nUnits * header.unitSize; }
@@ -842,7 +927,7 @@ struct VarSizedBinSearchArrayOf
{
TRACE_SANITIZE (this);
if (unlikely (!sanitize_shallow (c))) return_trace (false);
- unsigned int count = header.nUnits;
+ unsigned int count = get_length ();
for (unsigned int i = 0; i < count; i++)
if (unlikely (!(*this)[i].sanitize (c, base)))
return_trace (false);
@@ -853,7 +938,7 @@ struct VarSizedBinSearchArrayOf
{
TRACE_SANITIZE (this);
if (unlikely (!sanitize_shallow (c))) return_trace (false);
- unsigned int count = header.nUnits;
+ unsigned int count = get_length ();
for (unsigned int i = 0; i < count; i++)
if (unlikely (!(*this)[i].sanitize (c, base, user_data)))
return_trace (false);
@@ -864,7 +949,7 @@ struct VarSizedBinSearchArrayOf
inline const Type *bsearch (const T &key) const
{
unsigned int size = header.unitSize;
- int min = 0, max = (int) header.nUnits - 1;
+ int min = 0, max = (int) get_length () - 1;
while (min <= max)
{
int mid = ((unsigned int) min + (unsigned int) max) / 2;
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-cmap-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-cmap-table.hh
index b7d17018ac6..cdc610be3ea 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-cmap-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-cmap-table.hh
@@ -417,6 +417,7 @@ struct CmapSubtableLongGroup
public:
DEFINE_SIZE_STATIC (12);
};
+DECLARE_NULL_NAMESPACE_BYTES (OT, CmapSubtableLongGroup);
template <typename UINT>
struct CmapSubtableTrimmed
@@ -467,10 +468,7 @@ struct CmapSubtableLongSegmented
inline bool get_glyph (hb_codepoint_t codepoint, hb_codepoint_t *glyph) const
{
- int i = groups.bsearch (codepoint);
- if (i == -1)
- return false;
- hb_codepoint_t gid = T::group_get_glyph (groups[i], codepoint);
+ hb_codepoint_t gid = T::group_get_glyph (groups.bsearch (codepoint), codepoint);
if (!gid)
return false;
*glyph = gid;
@@ -517,7 +515,8 @@ struct CmapSubtableFormat12 : CmapSubtableLongSegmented<CmapSubtableFormat12>
{
static inline hb_codepoint_t group_get_glyph (const CmapSubtableLongGroup &group,
hb_codepoint_t u)
- { return group.glyphID + (u - group.startCharCode); }
+ { return likely (group.startCharCode <= group.endCharCode) ?
+ group.glyphID + (u - group.startCharCode) : 0; }
bool serialize (hb_serialize_context_t *c,
@@ -673,16 +672,12 @@ struct VariationSelectorRecord
hb_codepoint_t *glyph,
const void *base) const
{
- int i;
- const DefaultUVS &defaults = base+defaultUVS;
- i = defaults.bsearch (codepoint);
- if (i != -1)
+ if ((base+defaultUVS).bfind (codepoint))
return GLYPH_VARIANT_USE_DEFAULT;
- const NonDefaultUVS &nonDefaults = base+nonDefaultUVS;
- i = nonDefaults.bsearch (codepoint);
- if (i != -1 && nonDefaults[i].glyphID)
+ const UVSMapping &nonDefault = (base+nonDefaultUVS).bsearch (codepoint);
+ if (nonDefault.glyphID)
{
- *glyph = nonDefaults[i].glyphID;
+ *glyph = nonDefault.glyphID;
return GLYPH_VARIANT_FOUND;
}
return GLYPH_VARIANT_NOT_FOUND;
@@ -722,7 +717,7 @@ struct CmapSubtableFormat14
hb_codepoint_t variation_selector,
hb_codepoint_t *glyph) const
{
- return record[record.bsearch (variation_selector)].get_glyph (codepoint, glyph, this);
+ return record.bsearch (variation_selector).get_glyph (codepoint, glyph, this);
}
inline void collect_variation_selectors (hb_set_t *out) const
@@ -734,7 +729,7 @@ struct CmapSubtableFormat14
inline void collect_variation_unicodes (hb_codepoint_t variation_selector,
hb_set_t *out) const
{
- record[record.bsearch (variation_selector)].collect_unicodes (out, this);
+ record.bsearch (variation_selector).collect_unicodes (out, this);
}
inline bool sanitize (hb_sanitize_context_t *c) const
@@ -863,14 +858,6 @@ struct cmap
hb_vector_t<CmapSubtableLongGroup> format12_groups;
};
- inline bool sanitize (hb_sanitize_context_t *c) const
- {
- TRACE_SANITIZE (this);
- return_trace (c->check_struct (this) &&
- likely (version == 0) &&
- encodingRecord.sanitize (c, this));
- }
-
inline bool _create_plan (const hb_subset_plan_t *plan,
subset_plan *cmap_plan) const
{
@@ -1164,11 +1151,21 @@ struct cmap
key.platformID.set (platform_id);
key.encodingID.set (encoding_id);
- int result = encodingRecord.bsearch (key);
- if (result == -1 || !encodingRecord[result].subtable)
+ const EncodingRecord &result = encodingRecord.bsearch (key);
+ if (!result.subtable)
return nullptr;
- return &(this+encodingRecord[result].subtable);
+ return &(this+result.subtable);
+ }
+
+ public:
+
+ inline bool sanitize (hb_sanitize_context_t *c) const
+ {
+ TRACE_SANITIZE (this);
+ return_trace (c->check_struct (this) &&
+ likely (version == 0) &&
+ encodingRecord.sanitize (c, this));
}
protected:
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-colr-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-colr-table.hh
index fa40223b725..84c34332556 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-colr-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-colr-table.hh
@@ -66,13 +66,6 @@ struct BaseGlyphRecord
inline int cmp (hb_codepoint_t g) const
{ return g < glyphId ? -1 : g > glyphId ? 1 : 0; }
- static int cmp (const void *pa, const void *pb)
- {
- const hb_codepoint_t *a = (const hb_codepoint_t *) pa;
- const BaseGlyphRecord *b = (const BaseGlyphRecord *) pb;
- return b->cmp (*a);
- }
-
inline bool sanitize (hb_sanitize_context_t *c) const
{
TRACE_SANITIZE (this);
@@ -103,12 +96,7 @@ struct COLR
unsigned int *count, /* IN/OUT. May be NULL. */
hb_ot_color_layer_t *layers /* OUT. May be NULL. */) const
{
- const BaseGlyphRecord *rec = (BaseGlyphRecord *) bsearch (&glyph,
- &(this+baseGlyphsZ),
- numBaseGlyphs,
- sizeof (BaseGlyphRecord),
- BaseGlyphRecord::cmp);
- const BaseGlyphRecord &record = rec ? *rec : Null (BaseGlyphRecord);
+ const BaseGlyphRecord &record = (this+baseGlyphsZ).bsearch (numBaseGlyphs, glyph);
hb_array_t<const LayerRecord> all_layers ((this+layersZ).arrayZ, numLayers);
hb_array_t<const LayerRecord> glyph_layers = all_layers.sub_array (record.firstLayerIdx,
@@ -137,7 +125,7 @@ struct COLR
protected:
HBUINT16 version; /* Table version number (starts at 0). */
HBUINT16 numBaseGlyphs; /* Number of Base Glyph Records. */
- LOffsetTo<UnsizedArrayOf<BaseGlyphRecord>, false>
+ LOffsetTo<SortedUnsizedArrayOf<BaseGlyphRecord>, false>
baseGlyphsZ; /* Offset to Base Glyph records. */
LOffsetTo<UnsizedArrayOf<LayerRecord>, false>
layersZ; /* Offset to Layer Records. */
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-svg-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-svg-table.hh
index bad8ef549bb..ad3551035c8 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-svg-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-color-svg-table.hh
@@ -103,8 +103,7 @@ struct SVG
inline const SVGDocumentIndexEntry &get_glyph_entry (hb_codepoint_t glyph_id) const
{
- const SortedArrayOf<SVGDocumentIndexEntry> &docs = this+svgDocEntries;
- return docs[docs.bsearch (glyph_id)];
+ return (this+svgDocEntries).bsearch (glyph_id);
}
inline bool sanitize (hb_sanitize_context_t *c) const
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-face.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-face.hh
index 3ca875e7154..4a3260626c2 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-face.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-face.hh
@@ -65,6 +65,7 @@
HB_OT_TABLE(AAT, trak) \
HB_OT_TABLE(AAT, lcar) \
HB_OT_TABLE(AAT, ltag) \
+ HB_OT_TABLE(AAT, feat) \
/* OpenType variations. */ \
HB_OT_TABLE(OT, fvar) \
HB_OT_TABLE(OT, avar) \
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-font.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-font.cc
index b19b25a3eed..7c91362509c 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-font.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-font.cc
@@ -243,7 +243,7 @@ hb_ot_get_font_v_extents (hb_font_t *font,
return vmtx.has_font_extents;
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_ot_funcs (void);
#endif
@@ -269,7 +269,7 @@ static struct hb_ot_font_funcs_lazy_loader_t : hb_font_funcs_lazy_loader_t<hb_ot
hb_font_funcs_make_immutable (funcs);
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_ot_funcs);
#endif
@@ -277,7 +277,7 @@ static struct hb_ot_font_funcs_lazy_loader_t : hb_font_funcs_lazy_loader_t<hb_ot
}
} static_ot_funcs;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_ot_funcs (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-glyf-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-glyf-table.hh
index 5d9e7a201e7..c88f43385b4 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-glyf-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-glyf-table.hh
@@ -56,7 +56,9 @@ struct loca
protected:
UnsizedArrayOf<HBUINT8> dataZ; /* Location data. */
public:
- DEFINE_SIZE_ARRAY (0, dataZ);
+ DEFINE_SIZE_MIN (0); /* In reality, this is UNBOUNDED() type; but since we always
+ * check the size externally, allow Null() object of it by
+ * defining it MIN() instead. */
};
@@ -465,7 +467,9 @@ struct glyf
protected:
UnsizedArrayOf<HBUINT8> dataZ; /* Glyphs data. */
public:
- DEFINE_SIZE_ARRAY (0, dataZ);
+ DEFINE_SIZE_MIN (0); /* In reality, this is UNBOUNDED() type; but since we always
+ * check the size externally, allow Null() object of it by
+ * defining it MIN() instead. */
};
struct glyf_accelerator_t : glyf::accelerator_t {};
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-kern-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-kern-table.hh
index 14e0656842b..b57ebaea8dc 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-kern-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-kern-table.hh
@@ -154,7 +154,7 @@ struct KernSubTable
KernSubTableFormat3<KernSubTableHeader> format3;
} u;
public:
- DEFINE_SIZE_MIN (0);
+ DEFINE_SIZE_MIN (KernSubTableHeader::static_size);
};
@@ -274,6 +274,15 @@ struct kern
inline bool has_data (void) const { return u.version32; }
inline unsigned int get_type (void) const { return u.major; }
+ inline bool has_state_machine (void) const
+ {
+ switch (get_type ()) {
+ case 0: return u.ot.has_state_machine ();
+ case 1: return u.aat.has_state_machine ();
+ default:return false;
+ }
+ }
+
inline bool has_cross_stream (void) const
{
switch (get_type ()) {
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-common.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-common.hh
index 55b05b5136d..b5af73af64a 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-common.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-common.hh
@@ -128,15 +128,7 @@ struct RecordArrayOf : SortedArrayOf<Record<Type> >
}
inline bool find_index (hb_tag_t tag, unsigned int *index) const
{
- /* If we want to allow non-sorted data, we can lsearch(). */
- int i = this->/*lsearch*/bsearch (tag);
- if (i != -1) {
- if (index) *index = i;
- return true;
- } else {
- if (index) *index = Index::NOT_FOUND_INDEX;
- return false;
- }
+ return this->bfind (tag, index, HB_BFIND_NOT_FOUND_STORE, Index::NOT_FOUND_INDEX);
}
};
@@ -802,11 +794,11 @@ struct Lookup
HBUINT16 lookupFlag; /* Lookup qualifiers */
ArrayOf<Offset16>
subTable; /* Array of SubTables */
- HBUINT16 markFilteringSetX[VAR]; /* Index (base 0) into GDEF mark glyph sets
+/*HBUINT16 markFilteringSetX[VAR];*//* Index (base 0) into GDEF mark glyph sets
* structure. This field is only present if bit
* UseMarkFilteringSet of lookup flags is set. */
public:
- DEFINE_SIZE_ARRAY2 (6, subTable, markFilteringSetX);
+ DEFINE_SIZE_ARRAY (6, subTable);
};
typedef OffsetListOf<Lookup> LookupList;
@@ -823,8 +815,8 @@ struct CoverageFormat1
private:
inline unsigned int get_coverage (hb_codepoint_t glyph_id) const
{
- int i = glyphArray.bsearch (glyph_id);
- static_assert ((((unsigned int) -1) == NOT_COVERED), "");
+ unsigned int i;
+ glyphArray.bfind (glyph_id, &i, HB_BFIND_NOT_FOUND_STORE, NOT_COVERED);
return i;
}
@@ -896,12 +888,10 @@ struct CoverageFormat2
private:
inline unsigned int get_coverage (hb_codepoint_t glyph_id) const
{
- int i = rangeRecord.bsearch (glyph_id);
- if (i != -1) {
- const RangeRecord &range = rangeRecord[i];
- return (unsigned int) range.value + (glyph_id - range.start);
- }
- return NOT_COVERED;
+ const RangeRecord &range = rangeRecord.bsearch (glyph_id);
+ return likely (range.start <= range.end) ?
+ (unsigned int) range.value + (glyph_id - range.start) :
+ NOT_COVERED;
}
inline bool serialize (hb_serialize_context_t *c,
@@ -1194,10 +1184,7 @@ struct ClassDefFormat1
private:
inline unsigned int get_class (hb_codepoint_t glyph_id) const
{
- unsigned int i = (unsigned int) (glyph_id - startGlyph);
- if (unlikely (i < classValue.len))
- return classValue[i];
- return 0;
+ return classValue[(unsigned int) (glyph_id - startGlyph)];
}
inline bool sanitize (hb_sanitize_context_t *c) const
@@ -1265,10 +1252,10 @@ struct ClassDefFormat1
}
protected:
- HBUINT16 classFormat; /* Format identifier--format = 1 */
- GlyphID startGlyph; /* First GlyphID of the classValueArray */
+ HBUINT16 classFormat; /* Format identifier--format = 1 */
+ GlyphID startGlyph; /* First GlyphID of the classValueArray */
ArrayOf<HBUINT16>
- classValue; /* Array of Class Values--one per GlyphID */
+ classValue; /* Array of Class Values--one per GlyphID */
public:
DEFINE_SIZE_ARRAY (6, classValue);
};
@@ -1280,10 +1267,7 @@ struct ClassDefFormat2
private:
inline unsigned int get_class (hb_codepoint_t glyph_id) const
{
- int i = rangeRecord.bsearch (glyph_id);
- if (unlikely (i != -1))
- return rangeRecord[i].value;
- return 0;
+ return rangeRecord.bsearch (glyph_id).value;
}
inline bool sanitize (hb_sanitize_context_t *c) const
@@ -1568,9 +1552,9 @@ struct VarData
HBUINT16 itemCount;
HBUINT16 shortCount;
ArrayOf<HBUINT16> regionIndices;
- UnsizedArrayOf<HBUINT8>bytesX;
+/*UnsizedArrayOf<HBUINT8>bytesX;*/
public:
- DEFINE_SIZE_ARRAY2 (6, regionIndices, bytesX);
+ DEFINE_SIZE_ARRAY (6, regionIndices);
};
struct VariationStore
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gdef-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gdef-table.hh
index 22e07f7a4f3..a0ae27e75cb 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gdef-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gdef-table.hh
@@ -61,9 +61,10 @@ struct AttachList
const AttachPoint &points = this+attachPoint[index];
- if (point_count) {
- const HBUINT16 *array = points.sub_array (start_offset, point_count);
- unsigned int count = *point_count;
+ if (point_count)
+ {
+ hb_array_t<const HBUINT16> array = points.sub_array (start_offset, point_count);
+ unsigned int count = array.len;
for (unsigned int i = 0; i < count; i++)
point_array[i] = array[i];
}
@@ -216,9 +217,10 @@ struct LigGlyph
unsigned int *caret_count /* IN/OUT */,
hb_position_t *caret_array /* OUT */) const
{
- if (caret_count) {
- const OffsetTo<CaretValue> *array = carets.sub_array (start_offset, caret_count);
- unsigned int count = *caret_count;
+ if (caret_count)
+ {
+ hb_array_t <const OffsetTo<CaretValue> > array = carets.sub_array (start_offset, caret_count);
+ unsigned int count = array.len;
for (unsigned int i = 0; i < count; i++)
caret_array[i] = (this+array[i]).get_caret_value (font, direction, glyph_id, var_store);
}
@@ -406,9 +408,20 @@ struct GDEF
}
}
+ HB_INTERNAL bool is_blacklisted (hb_blob_t *blob,
+ hb_face_t *face) const;
+
struct accelerator_t
{
- HB_INTERNAL void init (hb_face_t *face);
+ inline void init (hb_face_t *face)
+ {
+ this->table = hb_sanitize_context_t().reference_table<GDEF> (face);
+ if (unlikely (this->table->is_blacklisted (this->table.get_blob (), face)))
+ {
+ hb_blob_destroy (this->table.get_blob ());
+ this->table = hb_blob_get_empty ();
+ }
+ }
inline void fini (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gpos-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gpos-table.hh
index 907fd463117..2589218de78 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gpos-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gpos-table.hh
@@ -1643,6 +1643,9 @@ struct GPOS : GSUBGPOS
inline bool sanitize (hb_sanitize_context_t *c) const
{ return GSUBGPOS::sanitize<PosLookup> (c); }
+ HB_INTERNAL bool is_blacklisted (hb_blob_t *blob,
+ hb_face_t *face) const;
+
typedef GSUBGPOS::accelerator_t<GPOS> accelerator_t;
};
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsub-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsub-table.hh
index 715317b59ab..27bd440dabf 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsub-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsub-table.hh
@@ -1449,7 +1449,10 @@ struct SubstLookup : Lookup
hb_closure_context_t::return_t ret = dispatch_recurse_func (c, lookup_index);
- c->flush ();
+ /* While in theory we should flush here, it will cause timeouts because a recursive
+ * lookup can keep growing the glyph set. Skip, and outer loop will retry up to
+ * HB_CLOSURE_MAX_STAGES time, which should be enough for every realistic font. */
+ //c->flush ();
return ret;
}
@@ -1483,6 +1486,9 @@ struct GSUB : GSUBGPOS
inline bool sanitize (hb_sanitize_context_t *c) const
{ return GSUBGPOS::sanitize<SubstLookup> (c); }
+ HB_INTERNAL bool is_blacklisted (hb_blob_t *blob,
+ hb_face_t *face) const;
+
typedef GSUBGPOS::accelerator_t<GSUB> accelerator_t;
};
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsubgpos.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsubgpos.hh
index 3d70c55c2ea..a9bfee155d8 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsubgpos.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout-gsubgpos.hh
@@ -2753,6 +2753,11 @@ struct GSUBGPOS
inline void init (hb_face_t *face)
{
this->table = hb_sanitize_context_t().reference_table<T> (face);
+ if (unlikely (this->table->is_blacklisted (this->table.get_blob (), face)))
+ {
+ hb_blob_destroy (this->table.get_blob ());
+ this->table = hb_blob_get_empty ();
+ }
this->lookup_count = table->get_lookup_count ();
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.cc
index 092633c5ddc..d0b22efe312 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.cc
@@ -34,15 +34,17 @@
#include "hb-ot-map.hh"
#include "hb-map.hh"
+#include "hb-ot-kern-table.hh"
#include "hb-ot-layout-gdef-table.hh"
#include "hb-ot-layout-gsub-table.hh"
#include "hb-ot-layout-gpos-table.hh"
#include "hb-ot-layout-base-table.hh" // Just so we compile it; unused otherwise
#include "hb-ot-layout-jstf-table.hh" // Just so we compile it; unused otherwise
-#include "hb-ot-kern-table.hh"
#include "hb-ot-name-table.hh"
+#include "hb-ot-os2-table.hh"
#include "hb-aat-layout-lcar-table.hh"
+#include "hb-aat-layout-morx-table.hh"
/**
@@ -66,6 +68,12 @@ hb_ot_layout_has_kerning (hb_face_t *face)
}
bool
+hb_ot_layout_has_machine_kerning (hb_face_t *face)
+{
+ return face->table.kern->has_state_machine ();
+}
+
+bool
hb_ot_layout_has_cross_kerning (hb_face_t *face)
{
return face->table.kern->has_cross_stream ();
@@ -89,10 +97,9 @@ hb_ot_layout_kern (const hb_ot_shape_plan_t *plan,
* GDEF
*/
-static bool
-_hb_ot_blacklist_gdef (unsigned int gdef_len,
- unsigned int gsub_len,
- unsigned int gpos_len)
+bool
+OT::GDEF::is_blacklisted (hb_blob_t *blob,
+ hb_face_t *face) const
{
/* The ugly business of blacklisting individual fonts' tables happen here!
* See this thread for why we finally had to bend in and do this:
@@ -111,8 +118,10 @@ _hb_ot_blacklist_gdef (unsigned int gdef_len,
* https://bugzilla.mozilla.org/show_bug.cgi?id=1279693
* https://bugzilla.mozilla.org/show_bug.cgi?id=1279875
*/
-#define ENCODE(x,y,z) ((int64_t) (x) << 32 | (int64_t) (y) << 16 | (z))
- switch ENCODE(gdef_len, gsub_len, gpos_len)
+#define ENCODE(x,y,z) (((uint64_t) (x) << 48) | ((uint64_t) (y) << 24) | (uint64_t) (z))
+ switch ENCODE(blob->length,
+ face->table.GSUB->table.get_length (),
+ face->table.GPOS->table.get_length ())
{
/* sha1sum:c5ee92f0bca4bfb7d06c4d03e8cf9f9cf75d2e8a Windows 7? timesi.ttf */
case ENCODE (442, 2874, 42038):
@@ -191,20 +200,6 @@ _hb_ot_blacklist_gdef (unsigned int gdef_len,
return false;
}
-void
-OT::GDEF::accelerator_t::init (hb_face_t *face)
-{
- this->table = hb_sanitize_context_t().reference_table<GDEF> (face);
-
- if (unlikely (_hb_ot_blacklist_gdef (this->table.get_length (),
- face->table.GSUB->table.get_length (),
- face->table.GPOS->table.get_length ())))
- {
- hb_blob_destroy (this->table.get_blob ());
- this->table = hb_blob_get_empty ();
- }
-}
-
static void
_hb_ot_layout_set_glyph_props (hb_font_t *font,
hb_buffer_t *buffer)
@@ -291,6 +286,38 @@ hb_ot_layout_get_ligature_carets (hb_font_t *font,
* GSUB/GPOS
*/
+bool
+OT::GSUB::is_blacklisted (hb_blob_t *blob HB_UNUSED,
+ hb_face_t *face) const
+{
+ /* Mac OS X prefers morx over GSUB. It also ships with various Indic fonts,
+ * all by 'MUTF' foundry (Tamil MN, Tamil Sangam MN, etc.), that have broken
+ * GSUB/GPOS tables. Some have GSUB with zero scripts, those are ignored by
+ * our morx/GSUB preference code. But if GSUB has non-zero scripts, we tend
+ * to prefer it over morx because we want to be consistent with other OpenType
+ * shapers.
+ *
+ * To work around broken Indic Mac system fonts, we ignore GSUB table if
+ * OS/2 VendorId is 'MUTF' and font has morx table as well.
+ *
+ * https://github.com/harfbuzz/harfbuzz/issues/1410
+ * https://github.com/harfbuzz/harfbuzz/issues/1348
+ * https://github.com/harfbuzz/harfbuzz/issues/1391
+ */
+ if (unlikely (face->table.OS2->achVendID == HB_TAG ('M','U','T','F') &&
+ face->table.morx->has_data ()))
+ return true;
+
+ return false;
+}
+
+bool
+OT::GPOS::is_blacklisted (hb_blob_t *blob HB_UNUSED,
+ hb_face_t *face HB_UNUSED) const
+{
+ return false;
+}
+
static const OT::GSUBGPOS&
get_gsubgpos_table (hb_face_t *face,
hb_tag_t table_tag)
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.hh
index db85508d2a4..a00b940b2ab 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-layout.hh
@@ -49,6 +49,9 @@ HB_INTERNAL bool
hb_ot_layout_has_kerning (hb_face_t *face);
HB_INTERNAL bool
+hb_ot_layout_has_machine_kerning (hb_face_t *face);
+
+HB_INTERNAL bool
hb_ot_layout_has_cross_kerning (hb_face_t *face);
HB_INTERNAL void
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-map.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-map.hh
index 8e1f5aa8c3e..0a5a4fbcb70 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-map.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-map.hh
@@ -57,8 +57,8 @@ struct hb_ot_map_t
unsigned int auto_zwj : 1;
unsigned int random : 1;
- inline int cmp (const hb_tag_t *tag_) const
- { return *tag_ < tag ? -1 : *tag_ > tag ? 1 : 0; }
+ inline int cmp (const hb_tag_t tag_) const
+ { return tag_ < tag ? -1 : tag_ > tag ? 1 : 0; }
};
struct lookup_map_t {
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-math-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-math-table.hh
index b8730497988..153a417959d 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-math-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-math-table.hh
@@ -509,9 +509,8 @@ struct MathGlyphAssembly
if (parts_count)
{
int scale = font->dir_scale (direction);
- const MathGlyphPartRecord *arr =
- partRecords.sub_array (start_offset, parts_count);
- unsigned int count = *parts_count;
+ hb_array_t<const MathGlyphPartRecord> arr = partRecords.sub_array (start_offset, parts_count);
+ unsigned int count = arr.len;
for (unsigned int i = 0; i < count; i++)
arr[i].extract (parts[i], scale, font);
}
@@ -556,9 +555,8 @@ struct MathGlyphConstruction
if (variants_count)
{
int scale = font->dir_scale (direction);
- const MathGlyphVariantRecord *arr =
- mathGlyphVariantRecord.sub_array (start_offset, variants_count);
- unsigned int count = *variants_count;
+ hb_array_t<const MathGlyphVariantRecord> arr = mathGlyphVariantRecord.sub_array (start_offset, variants_count);
+ unsigned int count = arr.len;
for (unsigned int i = 0; i < count; i++)
{
variants[i].glyph = arr[i].variantGlyph;
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-post-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-post-table.hh
index f80303cc8ba..98df3e7801c 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-post-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-post-table.hh
@@ -61,12 +61,12 @@ struct postV2Tail
ArrayOf<HBUINT16> glyphNameIndex; /* This is not an offset, but is the
* ordinal number of the glyph in 'post'
* string tables. */
- UnsizedArrayOf<HBUINT8>
- namesX; /* Glyph names with length bytes [variable]
+/*UnsizedArrayOf<HBUINT8>
+ namesX;*/ /* Glyph names with length bytes [variable]
* (a Pascal string). */
public:
- DEFINE_SIZE_ARRAY2 (2, glyphNameIndex, namesX);
+ DEFINE_SIZE_ARRAY (2, glyphNameIndex);
};
struct post
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-myanmar.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-myanmar.cc
index ca7b5a9b2d1..8fdf2f4bcfd 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-myanmar.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-myanmar.cc
@@ -391,27 +391,6 @@ const hb_ot_complex_shaper_t _hb_ot_complex_shaper_myanmar =
};
-/* Uniscribe seems to have a shaper for 'mymr' that is like the
- * generic shaper, except that it zeros mark advances GDEF_LATE. */
-const hb_ot_complex_shaper_t _hb_ot_complex_shaper_myanmar_old =
-{
- nullptr, /* collect_features */
- nullptr, /* override_features */
- nullptr, /* data_create */
- nullptr, /* data_destroy */
- nullptr, /* preprocess_text */
- nullptr, /* postprocess_glyphs */
- HB_OT_SHAPE_NORMALIZATION_MODE_DEFAULT,
- nullptr, /* decompose */
- nullptr, /* compose */
- nullptr, /* setup_masks */
- HB_TAG_NONE, /* gpos_tag */
- nullptr, /* reorder_marks */
- HB_OT_SHAPE_ZERO_WIDTH_MARKS_BY_GDEF_LATE,
- true, /* fallback_position */
-};
-
-
/* Ugly Zawgyi encoding.
* Disable all auto processing.
* https://github.com/harfbuzz/harfbuzz/issues/1162 */
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use-table.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use-table.cc
index bfc92d3b505..2f3eb703eaa 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use-table.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use-table.cc
@@ -544,7 +544,7 @@ static const USE_TABLE_ELEMENT_TYPE use_table[] = {
/* 11190 */ B, B, B, B, B, B, B, B, B, B, B, B, B, B, B, B,
/* 111A0 */ B, B, B, B, B, B, B, B, B, B, B, B, B, B, B, B,
/* 111B0 */ B, B, B, VPst, VPre, VPst, VBlw, VBlw, VBlw, VBlw, VBlw, VBlw, VAbv, VAbv, VAbv, VAbv,
- /* 111C0 */ H, B, R, R, O, O, O, O, O, FM, CMBlw, VAbv, VBlw, O, O, O,
+ /* 111C0 */ H, B, R, R, O, O, O, O, GB, FBlw, CMBlw, VAbv, VBlw, O, O, O,
/* 111D0 */ B, B, B, B, B, B, B, B, B, B, O, O, O, O, O, O,
/* Sinhala Archaic Numbers */
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use.cc
index af25b07f8cb..2e3f202f59d 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex-use.cc
@@ -432,7 +432,8 @@ record_pref (const hb_ot_shape_plan_t *plan HB_UNUSED,
static inline bool
is_halant (const hb_glyph_info_t &info)
{
- return info.use_category() == USE_H && !_hb_glyph_info_ligated (&info);
+ return (info.use_category() == USE_H || info.use_category() == USE_HVM) &&
+ !_hb_glyph_info_ligated (&info);
}
static void
@@ -449,19 +450,38 @@ reorder_syllable (hb_buffer_t *buffer, unsigned int start, unsigned int end)
hb_glyph_info_t *info = buffer->info;
-#define BASE_FLAGS (FLAG (USE_B) | FLAG (USE_GB))
+#define POST_BASE_FLAGS64 (FLAG64 (USE_FM) | \
+ FLAG64 (USE_FAbv) | \
+ FLAG64 (USE_FBlw) | \
+ FLAG64 (USE_FPst) | \
+ FLAG64 (USE_MAbv) | \
+ FLAG64 (USE_MBlw) | \
+ FLAG64 (USE_MPst) | \
+ FLAG64 (USE_MPre) | \
+ FLAG64 (USE_VAbv) | \
+ FLAG64 (USE_VBlw) | \
+ FLAG64 (USE_VPst) | \
+ FLAG64 (USE_VPre) | \
+ FLAG64 (USE_VMAbv) | \
+ FLAG64 (USE_VMBlw) | \
+ FLAG64 (USE_VMPst) | \
+ FLAG64 (USE_VMPre))
/* Move things forward. */
if (info[start].use_category() == USE_R && end - start > 1)
{
- /* Got a repha. Reorder it to after first base, before first halant. */
+ /* Got a repha. Reorder it towards the end, but before the first post-base
+ * glyph. */
for (unsigned int i = start + 1; i < end; i++)
- if ((FLAG_UNSAFE (info[i].use_category()) & (BASE_FLAGS)) || is_halant (info[i]))
+ {
+ bool is_post_base_glyph = (FLAG64_UNSAFE (info[i].use_category()) & POST_BASE_FLAGS64) ||
+ is_halant (info[i]);
+ if (is_post_base_glyph || i == end - 1)
{
- /* If we hit a halant, move before it; otherwise it's a base: move to it's
- * place, and shift things in between backward. */
+ /* If we hit a post-base glyph, move before it; otherwise move to the
+ * end. Shift things in between backward. */
- if (is_halant (info[i]))
+ if (is_post_base_glyph)
i--;
buffer->merge_clusters (start, i + 1);
@@ -471,21 +491,19 @@ reorder_syllable (hb_buffer_t *buffer, unsigned int start, unsigned int end)
break;
}
+ }
}
/* Move things back. */
- unsigned int j = end;
+ unsigned int j = start;
for (unsigned int i = start; i < end; i++)
{
uint32_t flag = FLAG_UNSAFE (info[i].use_category());
- if ((flag & (BASE_FLAGS)) || is_halant (info[i]))
+ if (is_halant (info[i]))
{
- /* If we hit a halant, move after it; otherwise it's a base: move to it's
- * place, and shift things in between backward. */
- if (is_halant (info[i]))
- j = i + 1;
- else
- j = i;
+ /* If we hit a halant, move after it; otherwise move to the beginning, and
+ * shift things in between forward. */
+ j = i + 1;
}
else if (((flag) & (FLAG (USE_VPre) | FLAG (USE_VMPre))) &&
/* Only move the first component of a MultipleSubst. */
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex.hh
index 2944d745c26..a2499de9c92 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape-complex.hh
@@ -57,7 +57,6 @@ enum hb_ot_shape_zero_width_marks_type_t {
HB_COMPLEX_SHAPER_IMPLEMENT (indic) \
HB_COMPLEX_SHAPER_IMPLEMENT (khmer) \
HB_COMPLEX_SHAPER_IMPLEMENT (myanmar) \
- HB_COMPLEX_SHAPER_IMPLEMENT (myanmar_old) \
HB_COMPLEX_SHAPER_IMPLEMENT (myanmar_zawgyi) \
HB_COMPLEX_SHAPER_IMPLEMENT (thai) \
HB_COMPLEX_SHAPER_IMPLEMENT (use) \
@@ -269,12 +268,25 @@ hb_ot_shape_complex_categorize (const hb_ot_shape_planner_t *planner)
return &_hb_ot_complex_shaper_khmer;
case HB_SCRIPT_MYANMAR:
- if (planner->map.chosen_script[0] == HB_TAG ('m','y','m','2'))
- return &_hb_ot_complex_shaper_myanmar;
- else if (planner->map.chosen_script[0] == HB_TAG ('m','y','m','r'))
- return &_hb_ot_complex_shaper_myanmar_old;
- else
+ /* If the designer designed the font for the 'DFLT' script,
+ * (or we ended up arbitrarily pick 'latn'), use the default shaper.
+ * Otherwise, use the specific shaper.
+ *
+ * If designer designed for 'mymr' tag, also send to default
+ * shaper. That's tag used from before Myanmar shaping spec
+ * was developed. The shaping spec uses 'mym2' tag. */
+ if (planner->map.chosen_script[0] == HB_TAG ('D','F','L','T') ||
+ planner->map.chosen_script[0] == HB_TAG ('l','a','t','n') ||
+ planner->map.chosen_script[0] == HB_TAG ('m','y','m','r'))
return &_hb_ot_complex_shaper_default;
+ else
+ return &_hb_ot_complex_shaper_myanmar;
+
+
+ /* https://github.com/harfbuzz/harfbuzz/issues/1162 */
+ case HB_SCRIPT_MYANMAR_ZAWGYI:
+
+ return &_hb_ot_complex_shaper_myanmar_zawgyi;
/* Unicode-2.0 additions */
@@ -375,10 +387,6 @@ hb_ot_shape_complex_categorize (const hb_ot_shape_planner_t *planner)
return &_hb_ot_complex_shaper_default;
else
return &_hb_ot_complex_shaper_use;
-
- /* https://github.com/harfbuzz/harfbuzz/issues/1162 */
- case HB_SCRIPT_MYANMAR_ZAWGYI:
- return &_hb_ot_complex_shaper_myanmar_zawgyi;
}
}
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.cc
index ccee8d34300..ef97435782c 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.cc
@@ -76,10 +76,16 @@ hb_ot_shape_planner_t::hb_ot_shape_planner_t (hb_face_t *fac
props (*props),
map (face, props),
aat_map (face, props),
- apply_morx (_hb_apply_morx (face)),
- shaper (apply_morx ?
- &_hb_ot_complex_shaper_default :
- hb_ot_shape_complex_categorize (this)) {}
+ apply_morx (_hb_apply_morx (face))
+{
+ shaper = hb_ot_shape_complex_categorize (this);
+
+ script_zero_marks = shaper->zero_width_marks != HB_OT_SHAPE_ZERO_WIDTH_MARKS_NONE;
+ script_fallback_mark_positioning = shaper->fallback_position;
+
+ if (apply_morx)
+ shaper = &_hb_ot_complex_shaper_default;
+}
void
hb_ot_shape_planner_t::compile (hb_ot_shape_plan_t &plan,
@@ -140,10 +146,17 @@ hb_ot_shape_planner_t::compile (hb_ot_shape_plan_t &plan,
plan.apply_kern = true;
}
- bool has_kern_mark = plan.apply_kern && hb_ot_layout_has_cross_kerning (face);
- plan.zero_marks = !plan.apply_morx && !plan.apply_kerx && !has_kern_mark;
+ plan.zero_marks = script_zero_marks &&
+ !plan.apply_kerx &&
+ (!plan.apply_kern || !hb_ot_layout_has_machine_kerning (face));
plan.has_gpos_mark = !!plan.map.get_1_mask (HB_TAG ('m','a','r','k'));
- plan.fallback_mark_positioning = !plan.apply_gpos && plan.zero_marks;
+
+ plan.adjust_mark_positioning_when_zeroing = !plan.apply_gpos &&
+ !plan.apply_kerx &&
+ (!plan.apply_kern || !hb_ot_layout_has_cross_kerning (face));
+
+ plan.fallback_mark_positioning = plan.adjust_mark_positioning_when_zeroing &&
+ script_fallback_mark_positioning;
/* Currently we always apply trak. */
plan.apply_trak = plan.requested_tracking && hb_aat_layout_has_tracking (face);
@@ -158,6 +171,7 @@ hb_ot_shape_plan_t::init0 (hb_face_t *face,
hb_ot_shape_planner_t planner (face,
&key->props);
+
hb_ot_shape_collect_features (&planner,
key->user_features,
key->num_user_features);
@@ -811,17 +825,16 @@ hb_ot_position_complex (const hb_ot_shape_context_t *c)
hb_glyph_info_t *info = c->buffer->info;
hb_glyph_position_t *pos = c->buffer->pos;
- /* If the font has no GPOS, AND, no fallback positioning will
- * happen, AND, direction is forward, then when zeroing mark
- * widths, we shift the mark with it, such that the mark
- * is positioned hanging over the previous glyph. When
+ /* If the font has no GPOS and direction is forward, then when
+ * zeroing mark widths, we shift the mark with it, such that the
+ * mark is positioned hanging over the previous glyph. When
* direction is backward we don't shift and it will end up
* hanging over the next glyph after the final reordering.
- * If fallback positinoing happens or GPOS is present, we don't
- * care.
+ *
+ * Note: If fallback positinoing happens, we don't care about
+ * this as it will be overriden.
*/
- bool adjust_offsets_when_zeroing = c->plan->fallback_mark_positioning &&
- !c->plan->shaper->fallback_position &&
+ bool adjust_offsets_when_zeroing = c->plan->adjust_mark_positioning_when_zeroing &&
HB_DIRECTION_IS_FORWARD (c->buffer->props.direction);
/* We change glyph origin to what GPOS expects (horizontal), apply GPOS, change it back. */
@@ -877,7 +890,7 @@ hb_ot_position_complex (const hb_ot_shape_context_t *c)
&pos[i].x_offset,
&pos[i].y_offset);
- if (c->plan->fallback_mark_positioning && c->plan->shaper->fallback_position)
+ if (c->plan->fallback_mark_positioning)
_hb_ot_shape_fallback_mark_position (c->plan, c->font, c->buffer);
}
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.hh
index 397634c25cc..6e1478d0085 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-shape.hh
@@ -77,6 +77,7 @@ struct hb_ot_shape_plan_t
bool zero_marks : 1;
bool fallback_glyph_classes : 1;
bool fallback_mark_positioning : 1;
+ bool adjust_mark_positioning_when_zeroing : 1;
bool apply_gpos : 1;
bool apply_kerx : 1;
@@ -113,6 +114,8 @@ struct hb_ot_shape_planner_t
hb_ot_map_builder_t map;
hb_aat_map_builder_t aat_map;
bool apply_morx : 1;
+ bool script_zero_marks : 1;
+ bool script_fallback_mark_positioning : 1;
const struct hb_ot_complex_shaper_t *shaper;
HB_INTERNAL hb_ot_shape_planner_t (hb_face_t *face,
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var-fvar-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var-fvar-table.hh
index 6d229c38625..fed334e8a61 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var-fvar-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var-fvar-table.hh
@@ -42,6 +42,11 @@ namespace OT {
struct InstanceRecord
{
+ friend struct fvar;
+
+ inline hb_array_t<const Fixed> get_coordinates (unsigned int axis_count) const
+ { return coordinatesZ.as_array (axis_count); }
+
inline bool sanitize (hb_sanitize_context_t *c, unsigned int axis_count) const
{
TRACE_SANITIZE (this);
@@ -52,7 +57,7 @@ struct InstanceRecord
protected:
NameID subfamilyNameID;/* The name ID for entries in the 'name' table
* that provide subfamily names for this instance. */
- HBUINT16 reserved; /* Reserved for future use — set to 0. */
+ HBUINT16 flags; /* Reserved for future use — set to 0. */
UnsizedArrayOf<Fixed>
coordinatesZ; /* The coordinates array for this instance. */
//NameID postScriptNameIDX;/*Optional. The name ID for entries in the 'name'
@@ -60,11 +65,16 @@ struct InstanceRecord
// * instance. */
public:
- DEFINE_SIZE_ARRAY (4, coordinatesZ);
+ DEFINE_SIZE_UNBOUNDED (4);
};
struct AxisRecord
{
+ enum
+ {
+ AXIS_FLAG_HIDDEN = 0x0001,
+ };
+
inline bool sanitize (hb_sanitize_context_t *c) const
{
TRACE_SANITIZE (this);
@@ -76,7 +86,7 @@ struct AxisRecord
Fixed minValue; /* The minimum coordinate value for the axis. */
Fixed defaultValue; /* The default coordinate value for the axis. */
Fixed maxValue; /* The maximum coordinate value for the axis. */
- HBUINT16 reserved; /* Reserved for future use — set to 0. */
+ HBUINT16 flags; /* Axis flags. */
NameID axisNameID; /* The name ID for entries in the 'name' table that
* provide a display name for this axis. */
@@ -96,42 +106,71 @@ struct fvar
return_trace (version.sanitize (c) &&
likely (version.major == 1) &&
c->check_struct (this) &&
+ axisSize == 20 && /* Assumed in our code. */
instanceSize >= axisCount * 4 + 4 &&
- axisSize <= 1024 && /* Arbitrary, just to simplify overflow checks. */
- instanceSize <= 1024 && /* Arbitrary, just to simplify overflow checks. */
- c->check_range (this, things) &&
- c->check_range (&StructAtOffset<char> (this, things),
- axisCount * axisSize + instanceCount * instanceSize));
+ get_axes ().sanitize (c) &&
+ c->check_range (get_instance (0), instanceCount, instanceSize));
}
inline unsigned int get_axis_count (void) const
{ return axisCount; }
- inline bool get_axis (unsigned int index, hb_ot_var_axis_t *info) const
+ inline void get_axis_deprecated (unsigned int axis_index,
+ hb_ot_var_axis_t *info) const
{
- if (unlikely (index >= axisCount))
- return false;
+ const AxisRecord &axis = get_axes ()[axis_index];
+ info->tag = axis.axisTag;
+ info->name_id = axis.axisNameID;
+ info->default_value = axis.defaultValue / 65536.;
+ /* Ensure order, to simplify client math. */
+ info->min_value = MIN<float> (info->default_value, axis.minValue / 65536.);
+ info->max_value = MAX<float> (info->default_value, axis.maxValue / 65536.);
+ }
- if (info)
+ inline void get_axis_info (unsigned int axis_index,
+ hb_ot_var_axis_info_t *info) const
+ {
+ const AxisRecord &axis = get_axes ()[axis_index];
+ info->axis_index = axis_index;
+ info->tag = axis.axisTag;
+ info->name_id = axis.axisNameID;
+ info->flags = (hb_ot_var_axis_flags_t) (unsigned int) axis.flags;
+ info->default_value = axis.defaultValue / 65536.;
+ /* Ensure order, to simplify client math. */
+ info->min_value = MIN<float> (info->default_value, axis.minValue / 65536.);
+ info->max_value = MAX<float> (info->default_value, axis.maxValue / 65536.);
+ info->reserved = 0;
+ }
+
+ inline unsigned int get_axes_deprecated (unsigned int start_offset,
+ unsigned int *axes_count /* IN/OUT */,
+ hb_ot_var_axis_t *axes_array /* OUT */) const
+ {
+ if (axes_count)
{
- const AxisRecord &axis = get_axes ()[index];
- info->tag = axis.axisTag;
- info->name_id = axis.axisNameID;
- info->default_value = axis.defaultValue / 65536.;
- /* Ensure order, to simplify client math. */
- info->min_value = MIN<float> (info->default_value, axis.minValue / 65536.);
- info->max_value = MAX<float> (info->default_value, axis.maxValue / 65536.);
- }
+ /* TODO Rewrite as hb_array_t<>::sub-array() */
+ unsigned int count = axisCount;
+ start_offset = MIN (start_offset, count);
- return true;
+ count -= start_offset;
+ axes_array += start_offset;
+
+ count = MIN (count, *axes_count);
+ *axes_count = count;
+
+ for (unsigned int i = 0; i < count; i++)
+ get_axis_deprecated (start_offset + i, axes_array + i);
+ }
+ return axisCount;
}
- inline unsigned int get_axis_infos (unsigned int start_offset,
- unsigned int *axes_count /* IN/OUT */,
- hb_ot_var_axis_t *axes_array /* OUT */) const
+ inline unsigned int get_axis_infos (unsigned int start_offset,
+ unsigned int *axes_count /* IN/OUT */,
+ hb_ot_var_axis_info_t *axes_array /* OUT */) const
{
if (axes_count)
{
+ /* TODO Rewrite as hb_array_t<>::sub-array() */
unsigned int count = axisCount;
start_offset = MIN (start_offset, count);
@@ -142,32 +181,48 @@ struct fvar
*axes_count = count;
for (unsigned int i = 0; i < count; i++)
- get_axis (start_offset + i, axes_array + i);
+ get_axis_info (start_offset + i, axes_array + i);
}
return axisCount;
}
- inline bool find_axis (hb_tag_t tag, unsigned int *index, hb_ot_var_axis_t *info) const
+ inline bool find_axis_deprecated (hb_tag_t tag,
+ unsigned int *axis_index,
+ hb_ot_var_axis_t *info) const
+ {
+ const AxisRecord *axes = get_axes ();
+ unsigned int count = get_axis_count ();
+ for (unsigned int i = 0; i < count; i++)
+ if (axes[i].axisTag == tag)
+ {
+ if (axis_index)
+ *axis_index = i;
+ get_axis_deprecated (i, info);
+ return true;
+ }
+ if (axis_index)
+ *axis_index = HB_OT_VAR_NO_AXIS_INDEX;
+ return false;
+ }
+
+ inline bool find_axis_info (hb_tag_t tag,
+ hb_ot_var_axis_info_t *info) const
{
const AxisRecord *axes = get_axes ();
unsigned int count = get_axis_count ();
for (unsigned int i = 0; i < count; i++)
if (axes[i].axisTag == tag)
{
- if (index)
- *index = i;
- return get_axis (i, info);
+ get_axis_info (i, info);
+ return true;
}
- if (index)
- *index = HB_OT_VAR_NO_AXIS_INDEX;
return false;
}
inline int normalize_axis_value (unsigned int axis_index, float v) const
{
- hb_ot_var_axis_t axis;
- if (!get_axis (axis_index, &axis))
- return 0;
+ hb_ot_var_axis_info_t axis;
+ get_axis_info (axis_index, &axis);
v = MAX (MIN (v, axis.max_value), axis.min_value); /* Clamp. */
@@ -180,17 +235,63 @@ struct fvar
return (int) (v * 16384.f + (v >= 0.f ? .5f : -.5f));
}
+ inline unsigned int get_instance_count (void) const
+ { return instanceCount; }
+
+ inline hb_ot_name_id_t get_instance_subfamily_name_id (unsigned int instance_index) const
+ {
+ const InstanceRecord *instance = get_instance (instance_index);
+ if (unlikely (!instance)) return HB_OT_NAME_ID_INVALID;
+ return instance->subfamilyNameID;
+ }
+
+ inline hb_ot_name_id_t get_instance_postscript_name_id (unsigned int instance_index) const
+ {
+ const InstanceRecord *instance = get_instance (instance_index);
+ if (unlikely (!instance)) return HB_OT_NAME_ID_INVALID;
+ if (instanceSize >= axisCount * 4 + 6)
+ return StructAfter<NameID> (instance->get_coordinates (axisCount));
+ return HB_OT_NAME_ID_INVALID;
+ }
+
+ inline unsigned int get_instance_coords (unsigned int instance_index,
+ unsigned int *coords_length, /* IN/OUT */
+ float *coords /* OUT */) const
+ {
+ const InstanceRecord *instance = get_instance (instance_index);
+ if (unlikely (!instance))
+ {
+ if (coords_length)
+ *coords_length = 0;
+ return 0;
+ }
+
+ if (coords_length && *coords_length)
+ {
+ hb_array_t<const Fixed> instanceCoords = instance->get_coordinates (axisCount)
+ .sub_array (0, *coords_length);
+ for (unsigned int i = 0; i < instanceCoords.len; i++)
+ coords[i] = instanceCoords.arrayZ[i].to_float ();
+ }
+ return axisCount;
+ }
+
protected:
- inline const AxisRecord * get_axes (void) const
- { return &StructAtOffset<AxisRecord> (this, things); }
+ inline hb_array_t<const AxisRecord> get_axes (void) const
+ { return hb_array (&(this+firstAxis), axisCount); }
- inline const InstanceRecord * get_instances (void) const
- { return &StructAtOffset<InstanceRecord> (get_axes () + axisCount, 0); }
+ inline const InstanceRecord *get_instance (unsigned int i) const
+ {
+ if (unlikely (i >= instanceCount)) return nullptr;
+ return &StructAtOffset<InstanceRecord> (&StructAfter<InstanceRecord> (get_axes ()),
+ i * instanceSize);
+ }
protected:
FixedVersion<>version; /* Version of the fvar table
* initially set to 0x00010000u */
- Offset16 things; /* Offset in bytes from the beginning of the table
+ OffsetTo<AxisRecord>
+ firstAxis; /* Offset in bytes from the beginning of the table
* to the start of the AxisRecord array. */
HBUINT16 reserved; /* This field is permanently reserved. Set to 2. */
HBUINT16 axisCount; /* The number of variation axes in the font (the
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.cc
index c97e9c49413..e327fb76243 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.cc
@@ -53,7 +53,6 @@
* @face: #hb_face_t to test
*
* This function allows to verify the presence of OpenType variation data on the face.
- * Alternatively, use hb_ot_var_get_axis_count().
*
* Return value: true if face has a `fvar' table and false otherwise
*
@@ -80,6 +79,7 @@ hb_ot_var_get_axis_count (hb_face_t *face)
* hb_ot_var_get_axes:
*
* Since: 1.4.2
+ * Deprecated: 2.2.0
**/
unsigned int
hb_ot_var_get_axes (hb_face_t *face,
@@ -87,13 +87,14 @@ hb_ot_var_get_axes (hb_face_t *face,
unsigned int *axes_count /* IN/OUT */,
hb_ot_var_axis_t *axes_array /* OUT */)
{
- return face->table.fvar->get_axis_infos (start_offset, axes_count, axes_array);
+ return face->table.fvar->get_axes_deprecated (start_offset, axes_count, axes_array);
}
/**
* hb_ot_var_find_axis:
*
* Since: 1.4.2
+ * Deprecated: 2.2.0
**/
hb_bool_t
hb_ot_var_find_axis (hb_face_t *face,
@@ -101,7 +102,68 @@ hb_ot_var_find_axis (hb_face_t *face,
unsigned int *axis_index,
hb_ot_var_axis_t *axis_info)
{
- return face->table.fvar->find_axis (axis_tag, axis_index, axis_info);
+ return face->table.fvar->find_axis_deprecated (axis_tag, axis_index, axis_info);
+}
+
+/**
+ * hb_ot_var_get_axis_infos:
+ *
+ * Since: 2.2.0
+ **/
+HB_EXTERN unsigned int
+hb_ot_var_get_axis_infos (hb_face_t *face,
+ unsigned int start_offset,
+ unsigned int *axes_count /* IN/OUT */,
+ hb_ot_var_axis_info_t *axes_array /* OUT */)
+{
+ return face->table.fvar->get_axis_infos (start_offset, axes_count, axes_array);
+}
+
+/**
+ * hb_ot_var_find_axis_info:
+ *
+ * Since: 2.2.0
+ **/
+HB_EXTERN hb_bool_t
+hb_ot_var_find_axis_info (hb_face_t *face,
+ hb_tag_t axis_tag,
+ hb_ot_var_axis_info_t *axis_info)
+{
+ return face->table.fvar->find_axis_info (axis_tag, axis_info);
+}
+
+
+/*
+ * Named instances.
+ */
+
+unsigned int
+hb_ot_var_get_named_instance_count (hb_face_t *face)
+{
+ return face->table.fvar->get_instance_count ();
+}
+
+hb_ot_name_id_t
+hb_ot_var_named_instance_get_subfamily_name_id (hb_face_t *face,
+ unsigned int instance_index)
+{
+ return face->table.fvar->get_instance_subfamily_name_id (instance_index);
+}
+
+hb_ot_name_id_t
+hb_ot_var_named_instance_get_postscript_name_id (hb_face_t *face,
+ unsigned int instance_index)
+{
+ return face->table.fvar->get_instance_postscript_name_id (instance_index);
+}
+
+unsigned int
+hb_ot_var_named_instance_get_design_coords (hb_face_t *face,
+ unsigned int instance_index,
+ unsigned int *coords_length, /* IN/OUT */
+ float *coords /* OUT */)
+{
+ return face->table.fvar->get_instance_coords (instance_index, coords_length, coords);
}
@@ -123,10 +185,10 @@ hb_ot_var_normalize_variations (hb_face_t *face,
const OT::fvar &fvar = *face->table.fvar;
for (unsigned int i = 0; i < variations_length; i++)
{
- unsigned int axis_index;
- if (hb_ot_var_find_axis (face, variations[i].tag, &axis_index, nullptr) &&
- axis_index < coords_length)
- coords[axis_index] = fvar.normalize_axis_value (axis_index, variations[i].value);
+ hb_ot_var_axis_info_t info;
+ if (hb_ot_var_find_axis_info (face, variations[i].tag, &info) &&
+ info.axis_index < coords_length)
+ coords[info.axis_index] = fvar.normalize_axis_value (info.axis_index, variations[i].value);
}
face->table.avar->map_coords (coords, coords_length);
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.h b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.h
index a2c0c5f2b02..b9d5e408df0 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.h
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-var.h
@@ -47,44 +47,85 @@ HB_BEGIN_DECLS
* fvar / avar
*/
+HB_EXTERN hb_bool_t
+hb_ot_var_has_data (hb_face_t *face);
+
+
+/*
+ * Variation axes.
+ */
+
+
+HB_EXTERN unsigned int
+hb_ot_var_get_axis_count (hb_face_t *face);
+
/**
- * hb_ot_var_axis_t:
+ * hb_ot_var_axis_flags_t:
+ * @HB_OT_VAR_AXIS_FLAG_HIDDEN: The axis should not be exposed directly in user interfaces.
*
- * Since: 1.4.2
+ * Since: 2.2.0
*/
-typedef struct hb_ot_var_axis_t {
- hb_tag_t tag;
- unsigned int name_id;
- float min_value;
- float default_value;
- float max_value;
-} hb_ot_var_axis_t;
+typedef enum { /*< flags >*/
+ HB_OT_VAR_AXIS_FLAG_HIDDEN = 0x00000001u,
-HB_EXTERN hb_bool_t
-hb_ot_var_has_data (hb_face_t *face);
+ _HB_OT_VAR_AXIS_FLAG_MAX_VALUE= 0x7FFFFFFFu, /*< skip >*/
+} hb_ot_var_axis_flags_t;
/**
- * HB_OT_VAR_NO_AXIS_INDEX:
+ * hb_ot_var_axis_info_t:
*
- * Since: 1.4.2
+ * Since: 2.2.0
*/
-#define HB_OT_VAR_NO_AXIS_INDEX 0xFFFFFFFFu
+typedef struct hb_ot_var_axis_info_t
+{
+ unsigned int axis_index;
+ hb_tag_t tag;
+ hb_ot_name_id_t name_id;
+ hb_ot_var_axis_flags_t flags;
+ float min_value;
+ float default_value;
+ float max_value;
+ /*< private >*/
+ unsigned int reserved;
+} hb_ot_var_axis_info_t;
HB_EXTERN unsigned int
-hb_ot_var_get_axis_count (hb_face_t *face);
+hb_ot_var_get_axis_infos (hb_face_t *face,
+ unsigned int start_offset,
+ unsigned int *axes_count /* IN/OUT */,
+ hb_ot_var_axis_info_t *axes_array /* OUT */);
+
+HB_EXTERN hb_bool_t
+hb_ot_var_find_axis_info (hb_face_t *face,
+ hb_tag_t axis_tag,
+ hb_ot_var_axis_info_t *axis_info);
+
+
+/*
+ * Named instances.
+ */
HB_EXTERN unsigned int
-hb_ot_var_get_axes (hb_face_t *face,
- unsigned int start_offset,
- unsigned int *axes_count /* IN/OUT */,
- hb_ot_var_axis_t *axes_array /* OUT */);
+hb_ot_var_get_named_instance_count (hb_face_t *face);
-HB_EXTERN hb_bool_t
-hb_ot_var_find_axis (hb_face_t *face,
- hb_tag_t axis_tag,
- unsigned int *axis_index,
- hb_ot_var_axis_t *axis_info);
+HB_EXTERN hb_ot_name_id_t
+hb_ot_var_named_instance_get_subfamily_name_id (hb_face_t *face,
+ unsigned int instance_index);
+HB_EXTERN hb_ot_name_id_t
+hb_ot_var_named_instance_get_postscript_name_id (hb_face_t *face,
+ unsigned int instance_index);
+
+HB_EXTERN unsigned int
+hb_ot_var_named_instance_get_design_coords (hb_face_t *face,
+ unsigned int instance_index,
+ unsigned int *coords_length, /* IN/OUT */
+ float *coords /* OUT */);
+
+
+/*
+ * Conversions.
+ */
HB_EXTERN void
hb_ot_var_normalize_variations (hb_face_t *face,
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-vorg-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-vorg-table.hh
index 98af00e14b2..a0480cbcb77 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-vorg-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ot-vorg-table.hh
@@ -63,11 +63,10 @@ struct VORG
inline int get_y_origin (hb_codepoint_t glyph) const
{
- int i = vertYOrigins.bsearch (glyph);
- if (i != -1)
- return vertYOrigins[i].vertOriginY;
-
- return defaultVertOriginY;
+ unsigned int i;
+ if (!vertYOrigins.bfind (glyph, &i))
+ return defaultVertOriginY;
+ return vertYOrigins[i].vertOriginY;
}
inline bool _subset (const hb_subset_plan_t *plan HB_UNUSED,
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-set.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-set.hh
index bc26ed3c03b..8b7a0f3d0c6 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-set.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-set.hh
@@ -45,7 +45,7 @@ struct hb_set_t
struct page_map_t
{
- inline int cmp (const page_map_t *o) const { return (int) o->major - (int) major; }
+ inline int cmp (const page_map_t &o) const { return (int) o.major - (int) major; }
uint32_t major;
uint32_t index;
@@ -341,11 +341,11 @@ struct hb_set_t
{
/* TODO perform op even if !successful. */
if (unlikely (!successful)) return;
- page_t *p = page_for (g);
- if (!p)
+ page_t *page = page_for (g);
+ if (!page)
return;
dirty ();
- p->del (g);
+ page->del (g);
}
inline void del_range (hb_codepoint_t a, hb_codepoint_t b)
{
@@ -357,10 +357,10 @@ struct hb_set_t
}
inline bool has (hb_codepoint_t g) const
{
- const page_t *p = page_for (g);
- if (!p)
+ const page_t *page = page_for (g);
+ if (!page)
return false;
- return p->has (g);
+ return page->has (g);
}
inline bool intersects (hb_codepoint_t first,
hb_codepoint_t last) const
@@ -544,7 +544,7 @@ struct hb_set_t
page_map_t map = {get_major (*codepoint), 0};
unsigned int i;
- page_map.bfind (map, &i);
+ page_map.bfind (map, &i, HB_BFIND_NOT_FOUND_STORE_CLOSEST);
if (i < page_map.len && page_map[i].major == map.major)
{
if (pages[page_map[i].index].next (codepoint))
@@ -575,7 +575,7 @@ struct hb_set_t
page_map_t map = {get_major (*codepoint), 0};
unsigned int i;
- page_map.bfind (map, &i);
+ page_map.bfind (map, &i, HB_BFIND_NOT_FOUND_STORE_CLOSEST);
if (i < page_map.len && page_map[i].major == map.major)
{
if (pages[page_map[i].index].previous (codepoint))
@@ -670,7 +670,7 @@ struct hb_set_t
{
page_map_t map = {get_major (g), pages.len};
unsigned int i;
- if (!page_map.bfind (map, &i))
+ if (!page_map.bfind (map, &i, HB_BFIND_NOT_FOUND_STORE_CLOSEST))
{
if (!resize (pages.len + 1))
return nullptr;
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shape.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shape.cc
index 270da3d77ca..45f3a6916e2 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shape.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shape.cc
@@ -48,7 +48,7 @@
**/
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_shaper_list (void);
#endif
@@ -69,7 +69,7 @@ static struct hb_shaper_list_lazy_loader_t : hb_lazy_loader_t<const char *,
shaper_list[i] = shapers[i].name;
shaper_list[i] = nullptr;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_shaper_list);
#endif
@@ -85,7 +85,7 @@ static struct hb_shaper_list_lazy_loader_t : hb_lazy_loader_t<const char *,
}
} static_shaper_list;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_shaper_list (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shaper.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shaper.cc
index abea544f8e8..b10927ecfcf 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shaper.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-shaper.cc
@@ -35,7 +35,7 @@ static const hb_shaper_entry_t all_shapers[] = {
#undef HB_SHAPER_IMPLEMENT
};
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_shapers (void);
#endif
@@ -80,7 +80,7 @@ static struct hb_shapers_lazy_loader_t : hb_lazy_loader_t<const hb_shaper_entry_
p = end + 1;
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_shapers);
#endif
@@ -96,7 +96,7 @@ static struct hb_shapers_lazy_loader_t : hb_lazy_loader_t<const hb_shaper_entry_
}
} static_shapers;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_shapers (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-static.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-static.cc
index 73d9528e64f..a22f729ef6e 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-static.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-static.cc
@@ -27,10 +27,12 @@
#include "hb.hh"
#include "hb-open-type.hh"
-#include "hb-ot-layout-common.hh"
-#include "hb-aat-layout-common.hh"
-
#include "hb-face.hh"
+
+#include "hb-aat-layout-common.hh"
+#include "hb-aat-layout-feat-table.hh"
+#include "hb-ot-layout-common.hh"
+#include "hb-ot-cmap-table.hh"
#include "hb-ot-head-table.hh"
#include "hb-ot-maxp-table.hh"
@@ -42,6 +44,8 @@ hb_vector_size_impl_t const _hb_NullPool[(HB_NULL_POOL_SIZE + sizeof (hb_vector_
DEFINE_NULL_NAMESPACE_BYTES (OT, Index) = {0xFF,0xFF};
DEFINE_NULL_NAMESPACE_BYTES (OT, LangSys) = {0x00,0x00, 0xFF,0xFF, 0x00,0x00};
DEFINE_NULL_NAMESPACE_BYTES (OT, RangeRecord) = {0x00,0x01, 0x00,0x00, 0x00, 0x00};
+DEFINE_NULL_NAMESPACE_BYTES (OT, CmapSubtableLongGroup) = {0x00,0x00,0x00,0x01, 0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00};
+DEFINE_NULL_NAMESPACE_BYTES (AAT, SettingName) = {0xFF,0xFF, 0xFF,0xFF};
/* Hand-coded because Lookup is a template. Sad. */
const unsigned char _hb_Null_AAT_Lookup[2] = {0xFF, 0xFF};
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ucdn.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ucdn.cc
index 3179683c261..10608aff518 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ucdn.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-ucdn.cc
@@ -222,7 +222,7 @@ hb_ucdn_decompose(hb_unicode_funcs_t *ufuncs HB_UNUSED,
}
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static void free_static_ucdn_funcs (void);
#endif
@@ -241,7 +241,7 @@ static struct hb_ucdn_unicode_funcs_lazy_loader_t : hb_unicode_funcs_lazy_loader
hb_unicode_funcs_make_immutable (funcs);
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_ucdn_funcs);
#endif
@@ -249,7 +249,7 @@ static struct hb_ucdn_unicode_funcs_lazy_loader_t : hb_unicode_funcs_lazy_loader
}
} static_ucdn_funcs;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_ucdn_funcs (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-unicode-emoji-table.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-unicode-emoji-table.hh
index 41199de53c8..1dd0b3211e8 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-unicode-emoji-table.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-unicode-emoji-table.hh
@@ -47,38 +47,9 @@ static const struct hb_unicode_range_t _hb_unicode_emoji_Extended_Pictographic_t
{0x25FB, 0x25FE},
{0x2600, 0x2605},
{0x2607, 0x2612},
- {0x2614, 0x2615},
- {0x2616, 0x2617},
- {0x2618, 0x2618},
- {0x2619, 0x2619},
- {0x261A, 0x266F},
- {0x2670, 0x2671},
- {0x2672, 0x267D},
- {0x267E, 0x267F},
- {0x2680, 0x2685},
- {0x2690, 0x2691},
- {0x2692, 0x269C},
- {0x269D, 0x269D},
- {0x269E, 0x269F},
- {0x26A0, 0x26A1},
- {0x26A2, 0x26B1},
- {0x26B2, 0x26B2},
- {0x26B3, 0x26BC},
- {0x26BD, 0x26BF},
- {0x26C0, 0x26C3},
- {0x26C4, 0x26CD},
- {0x26CE, 0x26CE},
- {0x26CF, 0x26E1},
- {0x26E2, 0x26E2},
- {0x26E3, 0x26E3},
- {0x26E4, 0x26E7},
- {0x26E8, 0x26FF},
- {0x2700, 0x2700},
- {0x2701, 0x2704},
- {0x2705, 0x2705},
- {0x2708, 0x2709},
- {0x270A, 0x270B},
- {0x270C, 0x2712},
+ {0x2614, 0x2685},
+ {0x2690, 0x2705},
+ {0x2708, 0x2712},
{0x2714, 0x2714},
{0x2716, 0x2716},
{0x271D, 0x271D},
@@ -105,163 +76,33 @@ static const struct hb_unicode_range_t _hb_unicode_emoji_Extended_Pictographic_t
{0x303D, 0x303D},
{0x3297, 0x3297},
{0x3299, 0x3299},
- {0x1F000, 0x1F02B},
- {0x1F02C, 0x1F02F},
- {0x1F030, 0x1F093},
- {0x1F094, 0x1F09F},
- {0x1F0A0, 0x1F0AE},
- {0x1F0AF, 0x1F0B0},
- {0x1F0B1, 0x1F0BE},
- {0x1F0BF, 0x1F0BF},
- {0x1F0C0, 0x1F0C0},
- {0x1F0C1, 0x1F0CF},
- {0x1F0D0, 0x1F0D0},
- {0x1F0D1, 0x1F0DF},
- {0x1F0E0, 0x1F0F5},
- {0x1F0F6, 0x1F0FF},
+ {0x1F000, 0x1F0FF},
{0x1F10D, 0x1F10F},
{0x1F12F, 0x1F12F},
- {0x1F16C, 0x1F16F},
- {0x1F170, 0x1F171},
- {0x1F17E, 0x1F17E},
- {0x1F17F, 0x1F17F},
+ {0x1F16C, 0x1F171},
+ {0x1F17E, 0x1F17F},
{0x1F18E, 0x1F18E},
{0x1F191, 0x1F19A},
{0x1F1AD, 0x1F1E5},
- {0x1F201, 0x1F202},
- {0x1F203, 0x1F20F},
+ {0x1F201, 0x1F20F},
{0x1F21A, 0x1F21A},
{0x1F22F, 0x1F22F},
{0x1F232, 0x1F23A},
{0x1F23C, 0x1F23F},
- {0x1F249, 0x1F24F},
- {0x1F250, 0x1F251},
- {0x1F252, 0x1F25F},
- {0x1F260, 0x1F265},
- {0x1F266, 0x1F2FF},
- {0x1F300, 0x1F320},
- {0x1F321, 0x1F32C},
- {0x1F32D, 0x1F32F},
- {0x1F330, 0x1F335},
- {0x1F336, 0x1F336},
- {0x1F337, 0x1F37C},
- {0x1F37D, 0x1F37D},
- {0x1F37E, 0x1F37F},
- {0x1F380, 0x1F393},
- {0x1F394, 0x1F39F},
- {0x1F3A0, 0x1F3C4},
- {0x1F3C5, 0x1F3C5},
- {0x1F3C6, 0x1F3CA},
- {0x1F3CB, 0x1F3CE},
- {0x1F3CF, 0x1F3D3},
- {0x1F3D4, 0x1F3DF},
- {0x1F3E0, 0x1F3F0},
- {0x1F3F1, 0x1F3F7},
- {0x1F3F8, 0x1F3FA},
- {0x1F400, 0x1F43E},
- {0x1F43F, 0x1F43F},
- {0x1F440, 0x1F440},
- {0x1F441, 0x1F441},
- {0x1F442, 0x1F4F7},
- {0x1F4F8, 0x1F4F8},
- {0x1F4F9, 0x1F4FC},
- {0x1F4FD, 0x1F4FE},
- {0x1F4FF, 0x1F4FF},
- {0x1F500, 0x1F53D},
- {0x1F546, 0x1F54A},
- {0x1F54B, 0x1F54F},
- {0x1F550, 0x1F567},
- {0x1F568, 0x1F579},
- {0x1F57A, 0x1F57A},
- {0x1F57B, 0x1F5A3},
- {0x1F5A4, 0x1F5A4},
- {0x1F5A5, 0x1F5FA},
- {0x1F5FB, 0x1F5FF},
- {0x1F600, 0x1F600},
- {0x1F601, 0x1F610},
- {0x1F611, 0x1F611},
- {0x1F612, 0x1F614},
- {0x1F615, 0x1F615},
- {0x1F616, 0x1F616},
- {0x1F617, 0x1F617},
- {0x1F618, 0x1F618},
- {0x1F619, 0x1F619},
- {0x1F61A, 0x1F61A},
- {0x1F61B, 0x1F61B},
- {0x1F61C, 0x1F61E},
- {0x1F61F, 0x1F61F},
- {0x1F620, 0x1F625},
- {0x1F626, 0x1F627},
- {0x1F628, 0x1F62B},
- {0x1F62C, 0x1F62C},
- {0x1F62D, 0x1F62D},
- {0x1F62E, 0x1F62F},
- {0x1F630, 0x1F633},
- {0x1F634, 0x1F634},
- {0x1F635, 0x1F640},
- {0x1F641, 0x1F642},
- {0x1F643, 0x1F644},
- {0x1F645, 0x1F64F},
- {0x1F680, 0x1F6C5},
- {0x1F6C6, 0x1F6CF},
- {0x1F6D0, 0x1F6D0},
- {0x1F6D1, 0x1F6D2},
- {0x1F6D3, 0x1F6D4},
- {0x1F6D5, 0x1F6DF},
- {0x1F6E0, 0x1F6EC},
- {0x1F6ED, 0x1F6EF},
- {0x1F6F0, 0x1F6F3},
- {0x1F6F4, 0x1F6F6},
- {0x1F6F7, 0x1F6F8},
- {0x1F6F9, 0x1F6F9},
- {0x1F6FA, 0x1F6FF},
+ {0x1F249, 0x1F3FA},
+ {0x1F400, 0x1F53D},
+ {0x1F546, 0x1F64F},
+ {0x1F680, 0x1F6FF},
{0x1F774, 0x1F77F},
- {0x1F7D5, 0x1F7D8},
- {0x1F7D9, 0x1F7FF},
+ {0x1F7D5, 0x1F7FF},
{0x1F80C, 0x1F80F},
{0x1F848, 0x1F84F},
{0x1F85A, 0x1F85F},
{0x1F888, 0x1F88F},
{0x1F8AE, 0x1F8FF},
- {0x1F90C, 0x1F90F},
- {0x1F910, 0x1F918},
- {0x1F919, 0x1F91E},
- {0x1F91F, 0x1F91F},
- {0x1F920, 0x1F927},
- {0x1F928, 0x1F92F},
- {0x1F930, 0x1F930},
- {0x1F931, 0x1F932},
- {0x1F933, 0x1F93A},
- {0x1F93C, 0x1F93E},
- {0x1F93F, 0x1F93F},
- {0x1F940, 0x1F945},
- {0x1F947, 0x1F94B},
- {0x1F94C, 0x1F94C},
- {0x1F94D, 0x1F94F},
- {0x1F950, 0x1F95E},
- {0x1F95F, 0x1F96B},
- {0x1F96C, 0x1F970},
- {0x1F971, 0x1F972},
- {0x1F973, 0x1F976},
- {0x1F977, 0x1F979},
- {0x1F97A, 0x1F97A},
- {0x1F97B, 0x1F97B},
- {0x1F97C, 0x1F97F},
- {0x1F980, 0x1F984},
- {0x1F985, 0x1F991},
- {0x1F992, 0x1F997},
- {0x1F998, 0x1F9A2},
- {0x1F9A3, 0x1F9AF},
- {0x1F9B0, 0x1F9B9},
- {0x1F9BA, 0x1F9BF},
- {0x1F9C0, 0x1F9C0},
- {0x1F9C1, 0x1F9C2},
- {0x1F9C3, 0x1F9CF},
- {0x1F9D0, 0x1F9E6},
- {0x1F9E7, 0x1F9FF},
- {0x1FA00, 0x1FA5F},
- {0x1FA60, 0x1FA6D},
- {0x1FA6E, 0x1FFFD},
+ {0x1F90C, 0x1F93A},
+ {0x1F93C, 0x1F945},
+ {0x1F947, 0x1FFFD},
};
#endif /* HB_UNICODE_EMOJI_TABLE_HH */
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-uniscribe.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-uniscribe.cc
index 1331704e9e9..1fae6435b2c 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-uniscribe.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-uniscribe.cc
@@ -245,7 +245,7 @@ static struct hb_uniscribe_shaper_funcs_lazy_loader_t : hb_lazy_loader_t<hb_unis
funcs->init ();
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
atexit (free_static_uniscribe_shaper_funcs);
#endif
@@ -261,7 +261,7 @@ static struct hb_uniscribe_shaper_funcs_lazy_loader_t : hb_lazy_loader_t<hb_unis
}
} static_uniscribe_shaper_funcs;
-#ifdef HB_USE_ATEXIT
+#if HB_USE_ATEXIT
static
void free_static_uniscribe_shaper_funcs (void)
{
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-vector.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-vector.hh
index 7056a5b5493..787512f9221 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-vector.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb-vector.hh
@@ -31,13 +31,15 @@
#include "hb.hh"
-template <typename Type, unsigned int StaticSize=8>
+template <typename Type, unsigned int PreallocedCount=8>
struct hb_vector_t
{
+ static_assert ((bool) (unsigned) hb_static_size (Type), "");
+
typedef Type ItemType;
enum { item_size = sizeof (Type) };
- HB_NO_COPY_ASSIGN_TEMPLATE2 (hb_vector_t, Type, StaticSize);
+ HB_NO_COPY_ASSIGN_TEMPLATE2 (hb_vector_t, Type, PreallocedCount);
inline hb_vector_t (void) { init (); }
inline ~hb_vector_t (void) { fini (); }
@@ -45,7 +47,7 @@ struct hb_vector_t
private:
unsigned int allocated; /* == 0 means allocation failed. */
Type *arrayZ_;
- Type static_array[StaticSize];
+ Type static_array[PreallocedCount];
public:
void init (void)
@@ -89,6 +91,16 @@ struct hb_vector_t
return arrayZ()[i];
}
+ inline hb_array_t<Type> as_array (void)
+ { return hb_array (arrayZ(), len); }
+ inline hb_array_t<const Type> as_array (void) const
+ { return hb_array (arrayZ(), len); }
+
+ inline hb_sorted_array_t<Type> as_sorted_array (void)
+ { return hb_sorted_array (arrayZ(), len); }
+ inline hb_sorted_array_t<const Type> as_sorted_array (void) const
+ { return hb_sorted_array (arrayZ(), len); }
+
template <typename T> inline operator T * (void) { return arrayZ(); }
template <typename T> inline operator const T * (void) const { return arrayZ(); }
@@ -209,75 +221,28 @@ struct hb_vector_t
}
inline void qsort (int (*cmp)(const void*, const void*))
- {
- ::qsort (arrayZ(), len, sizeof (Type), cmp);
- }
-
- inline void qsort (void)
- {
- ::qsort (arrayZ(), len, sizeof (Type), Type::cmp);
- }
-
- inline void qsort (unsigned int start, unsigned int end)
- {
- ::qsort (arrayZ() + start, end - start, sizeof (Type), Type::cmp);
- }
+ { as_array ().qsort (cmp); }
+ inline void qsort (unsigned int start = 0, unsigned int end = (unsigned int) -1)
+ { as_array ().qsort (start, end); }
template <typename T>
- inline Type *lsearch (const T &x)
- {
- Type *array = arrayZ();
- for (unsigned int i = 0; i < len; i++)
- if (0 == array[i].cmp (&x))
- return &array[i];
- return nullptr;
- }
+ inline Type *lsearch (const T &x, Type *not_found = nullptr)
+ { return as_array ().lsearch (x, not_found); }
template <typename T>
- inline const Type *lsearch (const T &x) const
- {
- const Type *array = arrayZ();
- for (unsigned int i = 0; i < len; i++)
- if (0 == array[i].cmp (&x))
- return &array[i];
- return nullptr;
- }
+ inline const Type *lsearch (const T &x, const Type *not_found = nullptr) const
+ { return as_array ().lsearch (x, not_found); }
template <typename T>
- inline Type *bsearch (const T &x)
- {
- unsigned int i;
- return bfind (x, &i) ? &arrayZ()[i] : nullptr;
- }
+ inline Type *bsearch (const T &x, Type *not_found = nullptr)
+ { return as_sorted_array ().bsearch (x, not_found); }
template <typename T>
- inline const Type *bsearch (const T &x) const
- {
- unsigned int i;
- return bfind (x, &i) ? &arrayZ()[i] : nullptr;
- }
+ inline const Type *bsearch (const T &x, const Type *not_found = nullptr) const
+ { return as_sorted_array ().bsearch (x, not_found); }
template <typename T>
- inline bool bfind (const T &x, unsigned int *i) const
- {
- int min = 0, max = (int) this->len - 1;
- const Type *array = this->arrayZ();
- while (min <= max)
- {
- int mid = ((unsigned int) min + (unsigned int) max) / 2;
- int c = array[mid].cmp (&x);
- if (c < 0)
- max = mid - 1;
- else if (c > 0)
- min = mid + 1;
- else
- {
- *i = mid;
- return true;
- }
- }
- if (max < 0 || (max < (int) this->len && array[max].cmp (&x) > 0))
- max++;
- *i = max;
- return false;
- }
+ inline bool bfind (const T &x, unsigned int *i = nullptr,
+ hb_bfind_not_found_t not_found = HB_BFIND_NOT_FOUND_DONT_STORE,
+ unsigned int to_store = (unsigned int) -1) const
+ { return as_sorted_array ().bfind (x, i, not_found, to_store); }
};
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb.hh b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb.hh
index 16ccf87ce97..6df0a55b1bb 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/hb.hh
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/hb.hh
@@ -47,6 +47,10 @@
#define HB_H_IN
#include "hb-ot.h"
#define HB_OT_H_IN
+#include "hb-aat.h"
+#define HB_AAT_H_IN
+
+#include "hb-aat.h"
#include <math.h>
#include <stdlib.h>
@@ -281,7 +285,7 @@ static int errno = 0; /* Use something better? */
# endif
#endif
-#if HAVE_ATEXIT
+#if defined(HAVE_ATEXIT) && !defined(HB_USE_ATEXIT)
/* atexit() is only safe to be called from shared libraries on certain
* platforms. Whitelist.
* https://bugs.freedesktop.org/show_bug.cgi?id=82246 */
@@ -313,6 +317,9 @@ static int errno = 0; /* Use something better? */
#ifdef HB_NO_ATEXIT
# undef HB_USE_ATEXIT
#endif
+#ifndef HB_USE_ATEXIT
+# define HB_USE_ATEXIT 0
+#endif
#define HB_STMT_START do
#define HB_STMT_END while (0)
@@ -443,9 +450,11 @@ typedef uint64_t hb_vector_size_impl_t;
* For example, for testing "x ∈ {x1, x2, x3}" use:
* (FLAG_UNSAFE(x) & (FLAG(x1) | FLAG(x2) | FLAG(x3)))
*/
-#define FLAG(x) (ASSERT_STATIC_EXPR_ZERO ((unsigned int)(x) < 32) + (1U << (unsigned int)(x)))
-#define FLAG_UNSAFE(x) ((unsigned int)(x) < 32 ? (1U << (unsigned int)(x)) : 0)
+#define FLAG(x) (ASSERT_STATIC_EXPR_ZERO ((unsigned)(x) < 32) + (((uint32_t) 1U) << (unsigned)(x)))
+#define FLAG_UNSAFE(x) ((unsigned)(x) < 32 ? (((uint32_t) 1U) << (unsigned)(x)) : 0)
#define FLAG_RANGE(x,y) (ASSERT_STATIC_EXPR_ZERO ((x) < (y)) + FLAG(y+1) - FLAG(x))
+#define FLAG64(x) (ASSERT_STATIC_EXPR_ZERO ((unsigned)(x) < 64) + (((uint64_t) 1ULL) << (unsigned)(x)))
+#define FLAG64_UNSAFE(x) ((unsigned)(x) < 64 ? (((uint64_t) 1ULL) << (unsigned)(x)) : 0)
/* Size signifying variable-sized array */
@@ -503,10 +512,13 @@ _hb_memalign(void **memptr, size_t alignment, size_t size)
/* Some really basic things everyone wants. */
template <typename T> struct hb_remove_const { typedef T value; };
template <typename T> struct hb_remove_const<const T> { typedef T value; };
+#define hb_remove_const(T) hb_remove_const<T>::value
template <typename T> struct hb_remove_reference { typedef T value; };
template <typename T> struct hb_remove_reference<T &> { typedef T value; };
+#define hb_remove_reference(T) hb_remove_reference<T>::value
template <typename T> struct hb_remove_pointer { typedef T value; };
template <typename T> struct hb_remove_pointer<T *> { typedef T value; };
+#define hb_remove_pointer(T) hb_remove_pointer<T>::value
/* Headers we include for everyone. Keep sorted. They express dependency amongst
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/test-name-table.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/test-name-table.cc
index 33305272945..58c98f07ab6 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/test-name-table.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/test-name-table.cc
@@ -48,7 +48,7 @@ main (int argc, char **argv)
for (unsigned int i = 0; i < count; i++)
{
- printf ("%d %s ",
+ printf ("%u %s ",
entries[i].name_id,
hb_language_to_string (entries[i].language));
diff --git a/Build/source/libs/harfbuzz/harfbuzz-src/src/test-ot-color.cc b/Build/source/libs/harfbuzz/harfbuzz-src/src/test-ot-color.cc
index 4b10e017743..4050a664d82 100644
--- a/Build/source/libs/harfbuzz/harfbuzz-src/src/test-ot-color.cc
+++ b/Build/source/libs/harfbuzz/harfbuzz-src/src/test-ot-color.cc
@@ -54,7 +54,7 @@ svg_dump (hb_face_t *face, unsigned int face_index)
const char *data = hb_blob_get_data (blob, &length);
char output_path[255];
- sprintf (output_path, "out/svg-%d-%d.svg%s",
+ sprintf (output_path, "out/svg-%u-%u.svg%s",
glyph_id,
face_index,
// append "z" if the content is gzipped, https://stackoverflow.com/a/6059405
@@ -108,7 +108,7 @@ png_dump (hb_face_t *face, unsigned int face_index)
const char *data = hb_blob_get_data (blob, &length);
char output_path[255];
- sprintf (output_path, "out/png-%d-%d-%d.png", glyph_id, strike, face_index);
+ sprintf (output_path, "out/png-%u-%u-%u.png", glyph_id, strike, face_index);
FILE *f = fopen (output_path, "wb");
fwrite (data, 1, length, f);
@@ -167,9 +167,8 @@ layered_glyph_dump (hb_face_t *face, cairo_font_face_t *cairo_face, unsigned int
// Render
unsigned int palette_count = hb_ot_color_palette_get_count (face);
- for (unsigned int palette = 0; palette < palette_count; palette++) {
- char output_path[255];
-
+ for (unsigned int palette = 0; palette < palette_count; palette++)
+ {
unsigned int num_colors = hb_ot_color_palette_get_colors (face, palette, 0, NULL, NULL);
if (!num_colors)
continue;
@@ -178,7 +177,8 @@ layered_glyph_dump (hb_face_t *face, cairo_font_face_t *cairo_face, unsigned int
hb_ot_color_palette_get_colors (face, palette, 0, &num_colors, colors);
if (num_colors)
{
- sprintf (output_path, "out/colr-%d-%d-%d.svg", gid, palette, face_index);
+ char output_path[255];
+ sprintf (output_path, "out/colr-%u-%u-%u.svg", gid, palette, face_index);
cairo_surface_t *surface = cairo_svg_surface_create (output_path, extents.width, extents.height);
cairo_t *cr = cairo_create (surface);
@@ -245,7 +245,7 @@ dump_glyphs (cairo_font_face_t *cairo_face, unsigned int upem,
// Render
{
char output_path[255];
- sprintf (output_path, "out/%d-%d.svg", face_index, i);
+ sprintf (output_path, "out/%u-%u.svg", face_index, i);
cairo_surface_t *surface = cairo_svg_surface_create (output_path, extents.width, extents.height);
cairo_t *cr = cairo_create (surface);
cairo_set_font_face (cr, cairo_face);
diff --git a/Build/source/libs/harfbuzz/include/Makefile.am b/Build/source/libs/harfbuzz/include/Makefile.am
index cb827c83b31..40fd2dd62fa 100644
--- a/Build/source/libs/harfbuzz/include/Makefile.am
+++ b/Build/source/libs/harfbuzz/include/Makefile.am
@@ -14,6 +14,8 @@ HARFBUZZ_BLD = $(top_builddir)
## common
hdr_links = \
$(HARFBUZZ_SRC)/hb.h \
+ $(HARFBUZZ_SRC)/hb-aat-layout.h \
+ $(HARFBUZZ_SRC)/hb-aat.h \
$(HARFBUZZ_SRC)/hb-blob.h \
$(HARFBUZZ_SRC)/hb-buffer.h \
$(HARFBUZZ_SRC)/hb-common.h \
diff --git a/Build/source/libs/harfbuzz/include/Makefile.in b/Build/source/libs/harfbuzz/include/Makefile.in
index 6d257007195..4abd75999eb 100644
--- a/Build/source/libs/harfbuzz/include/Makefile.in
+++ b/Build/source/libs/harfbuzz/include/Makefile.in
@@ -250,7 +250,8 @@ top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
HARFBUZZ_SRC = $(top_srcdir)/$(HARFBUZZ_TREE)/src
HARFBUZZ_BLD = $(top_builddir)
-hdr_links = $(HARFBUZZ_SRC)/hb.h $(HARFBUZZ_SRC)/hb-blob.h \
+hdr_links = $(HARFBUZZ_SRC)/hb.h $(HARFBUZZ_SRC)/hb-aat-layout.h \
+ $(HARFBUZZ_SRC)/hb-aat.h $(HARFBUZZ_SRC)/hb-blob.h \
$(HARFBUZZ_SRC)/hb-buffer.h $(HARFBUZZ_SRC)/hb-common.h \
$(HARFBUZZ_SRC)/hb-deprecated.h $(HARFBUZZ_SRC)/hb-face.h \
$(HARFBUZZ_SRC)/hb-font.h $(HARFBUZZ_SRC)/hb-map.h \
diff --git a/Build/source/libs/harfbuzz/version.ac b/Build/source/libs/harfbuzz/version.ac
index 0bc0610c400..e56953ba37f 100644
--- a/Build/source/libs/harfbuzz/version.ac
+++ b/Build/source/libs/harfbuzz/version.ac
@@ -8,4 +8,4 @@ dnl
dnl --------------------------------------------------------
dnl
dnl m4-include this file to define the current harfbuzz version
-m4_define([harfbuzz_version], [2.1.3])
+m4_define([harfbuzz_version], [2.2.0])