blob: 5dff981efbe06639759359e541b24972e9d8d2ac [file] [log] [blame]
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +02001/*
Behdad Esfahbod0ab8c862012-05-11 01:25:34 +02002 * Copyright © 2011,2012 Google, Inc.
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +02003 *
4 * This is part of HarfBuzz, a text shaping library.
5 *
6 * Permission is hereby granted, without written agreement and without
7 * license or royalty fees, to use, copy, modify, and distribute this
8 * software and its documentation for any purpose, provided that the
9 * above copyright notice and the following two paragraphs appear in
10 * all copies of this software.
11 *
12 * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR
13 * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
14 * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN
15 * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
16 * DAMAGE.
17 *
18 * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING,
19 * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
20 * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
21 * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO
22 * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
23 *
Rod Sheeter0e088a62018-02-14 21:11:45 -080024 * Google Author(s): Behdad Esfahbod, Roderick Sheeter
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020025 */
26
27#ifndef HB_OT_HMTX_TABLE_HH
28#define HB_OT_HMTX_TABLE_HH
29
Behdad Esfahbodc77ae402018-08-25 22:36:36 -070030#include "hb-open-type.hh"
Behdad Esfahbodeab4feb2017-11-14 20:16:45 -080031#include "hb-ot-hhea-table.hh"
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -080032#include "hb-ot-os2-table.hh"
33#include "hb-ot-var-hvar-table.hh"
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020034
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020035/*
Ebrahim Byagowia02c3ee2018-04-12 13:38:19 +043036 * hmtx -- Horizontal Metrics
37 * https://docs.microsoft.com/en-us/typography/opentype/spec/hmtx
38 * vmtx -- Vertical Metrics
39 * https://docs.microsoft.com/en-us/typography/opentype/spec/vmtx
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020040 */
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020041#define HB_OT_TAG_hmtx HB_TAG('h','m','t','x')
Behdad Esfahbodd41b8092014-09-25 13:04:08 +030042#define HB_OT_TAG_vmtx HB_TAG('v','m','t','x')
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020043
44
Ebrahim Byagowia02c3ee2018-04-12 13:38:19 +043045namespace OT {
46
47
Behdad Esfahbodd41b8092014-09-25 13:04:08 +030048struct LongMetric
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020049{
Behdad Esfahbod082b79f2016-03-01 16:41:26 +090050 UFWORD advance; /* Advance width/height. */
Behdad Esfahbod8dc62962018-10-15 01:09:05 -070051 FWORD sb; /* Leading (left/top) side bearing. */
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020052 public:
53 DEFINE_SIZE_STATIC (4);
54};
55
Rod Sheeterfa877702018-02-14 14:16:25 -080056template <typename T, typename H>
Behdad Esfahboda11d9a02017-01-22 20:09:47 -080057struct hmtxvmtx
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020058{
Ebrahim Byagowib2ebaa92018-12-16 22:38:10 +033059 bool sanitize (hb_sanitize_context_t *c HB_UNUSED) const
Behdad Esfahbodde2118e2015-02-17 17:27:44 +030060 {
Behdad Esfahbodbe218c62012-11-23 15:32:14 -050061 TRACE_SANITIZE (this);
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020062 /* We don't check for anything specific here. The users of the
63 * struct do all the hard work... */
Behdad Esfahbodb4715902015-09-29 14:57:02 +010064 return_trace (true);
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +020065 }
66
Rod Sheeterfa877702018-02-14 14:16:25 -080067
Ebrahim Byagowib2ebaa92018-12-16 22:38:10 +033068 bool subset_update_header (hb_subset_plan_t *plan,
Garret Rieger03e88ea2019-01-28 16:15:06 -080069 unsigned int num_hmetrics) const
Rod Sheeterfa877702018-02-14 14:16:25 -080070 {
Ebrahim Byagowi11aa0462018-11-15 23:10:56 +033071 hb_blob_t *src_blob = hb_sanitize_context_t ().reference_table<H> (plan->source, H::tableTag);
72 hb_blob_t *dest_blob = hb_blob_copy_writable_or_fail (src_blob);
Garret Rieger0775bc02018-02-14 16:37:35 -080073 hb_blob_destroy (src_blob);
74
Rod Sheetere1587392018-02-14 19:22:37 -080075 if (unlikely (!dest_blob)) {
Rod Sheeterfa877702018-02-14 14:16:25 -080076 return false;
77 }
Rod Sheeterfa877702018-02-14 14:16:25 -080078
Rod Sheeter1efecd92018-02-14 18:42:29 -080079 unsigned int length;
Rod Sheeter0e088a62018-02-14 21:11:45 -080080 H *table = (H *) hb_blob_get_data (dest_blob, &length);
Behdad Esfahbodb986c6a2019-03-29 20:17:46 -070081 table->numberOfLongMetrics = num_hmetrics;
Rod Sheeterfa877702018-02-14 14:16:25 -080082
Garret Rieger251cc972018-05-30 12:23:51 -070083 bool result = plan->add_table (H::tableTag, dest_blob);
Garret Rieger0775bc02018-02-14 16:37:35 -080084 hb_blob_destroy (dest_blob);
85
86 return result;
Rod Sheeterfa877702018-02-14 14:16:25 -080087 }
88
Ebrahim Byagowib2ebaa92018-12-16 22:38:10 +033089 bool subset (hb_subset_plan_t *plan) const
Rod Sheeterfa877702018-02-14 14:16:25 -080090 {
91 typename T::accelerator_t _mtx;
Rod Sheeter0e088a62018-02-14 21:11:45 -080092 _mtx.init (plan->source);
Rod Sheeterfa877702018-02-14 14:16:25 -080093
94 /* All the trailing glyphs with the same advance can use one LongMetric
95 * and just keep LSB */
Garret Rieger03e88ea2019-01-28 16:15:06 -080096 unsigned int num_output_glyphs = plan->num_output_glyphs ();
97 unsigned int num_advances = _mtx.num_advances_for_subset (plan);
Rod Sheeterfa877702018-02-14 14:16:25 -080098
99 /* alloc the new table */
100 size_t dest_sz = num_advances * 4
Garret Rieger03e88ea2019-01-28 16:15:06 -0800101 + (num_output_glyphs - num_advances) * 2;
Garret Rieger4665aaa2018-02-23 15:36:14 -0800102 void *dest = (void *) malloc (dest_sz);
Rod Sheetere1587392018-02-14 19:22:37 -0800103 if (unlikely (!dest))
Rod Sheeterfa877702018-02-14 14:16:25 -0800104 {
105 return false;
106 }
Rod Sheeterfa877702018-02-14 14:16:25 -0800107 DEBUG_MSG(SUBSET, nullptr, "%c%c%c%c in src has %d advances, %d lsbs", HB_UNTAG(T::tableTag), _mtx.num_advances, _mtx.num_metrics - _mtx.num_advances);
Garret Rieger03e88ea2019-01-28 16:15:06 -0800108 DEBUG_MSG(SUBSET, nullptr, "%c%c%c%c in dest has %d advances, %d lsbs, %u bytes",
109 HB_UNTAG(T::tableTag), num_advances, num_output_glyphs - num_advances, (unsigned int) dest_sz);
Rod Sheeterfa877702018-02-14 14:16:25 -0800110
Rod Sheeterfa877702018-02-14 14:16:25 -0800111 // Copy everything over
Rod Sheeterfa877702018-02-14 14:16:25 -0800112 char * dest_pos = (char *) dest;
Garret Rieger1a948042018-03-19 18:39:22 -0700113
114 bool failed = false;
Garret Rieger03e88ea2019-01-28 16:15:06 -0800115 for (unsigned int i = 0; i < num_output_glyphs; i++)
Rod Sheeterfa877702018-02-14 14:16:25 -0800116 {
Garret Rieger03e88ea2019-01-28 16:15:06 -0800117 unsigned int side_bearing = 0;
118 unsigned int advance = 0;
119 hb_codepoint_t old_gid;
120 if (plan->old_gid_for_new_gid (i, &old_gid))
Rod Sheeterfa877702018-02-14 14:16:25 -0800121 {
Garret Rieger03e88ea2019-01-28 16:15:06 -0800122 // Glyph is not an empty glyph so copy advance and side bearing
123 // from the input font.
124 side_bearing = _mtx.get_side_bearing (old_gid);
125 advance = _mtx.get_advance (old_gid);
126 }
127
128 bool has_advance = i < num_advances;
129 if (has_advance)
130 {
Behdad Esfahbodb986c6a2019-03-29 20:17:46 -0700131 ((LongMetric *) dest_pos)->advance = advance;
132 ((LongMetric *) dest_pos)->sb = side_bearing;
Rod Sheeterfa877702018-02-14 14:16:25 -0800133 }
134 else
135 {
Behdad Esfahbodb986c6a2019-03-29 20:17:46 -0700136 *((FWORD *) dest_pos) = side_bearing;
Rod Sheeterfa877702018-02-14 14:16:25 -0800137 }
Garret Rieger03e88ea2019-01-28 16:15:06 -0800138 dest_pos += (has_advance ? 4 : 2);
Rod Sheeterfa877702018-02-14 14:16:25 -0800139 }
Rod Sheeter0e088a62018-02-14 21:11:45 -0800140 _mtx.fini ();
Rod Sheeterfa877702018-02-14 14:16:25 -0800141
142 // Amend header num hmetrics
Garret Rieger1a948042018-03-19 18:39:22 -0700143 if (failed || unlikely (!subset_update_header (plan, num_advances)))
Rod Sheeterfa877702018-02-14 14:16:25 -0800144 {
Rod Sheeter0e088a62018-02-14 21:11:45 -0800145 free (dest);
Rod Sheeterfa877702018-02-14 14:16:25 -0800146 return false;
147 }
148
149 hb_blob_t *result = hb_blob_create ((const char *)dest,
150 dest_sz,
151 HB_MEMORY_MODE_READONLY,
Garret Rieger4665aaa2018-02-23 15:36:14 -0800152 dest,
Rod Sheeterfa877702018-02-14 14:16:25 -0800153 free);
Garret Rieger251cc972018-05-30 12:23:51 -0700154 bool success = plan->add_table (T::tableTag, result);
Garret Rieger4665aaa2018-02-23 15:36:14 -0800155 hb_blob_destroy (result);
156 return success;
Rod Sheeterfa877702018-02-14 14:16:25 -0800157 }
158
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800159 struct accelerator_t
160 {
Rod Sheeterfa877702018-02-14 14:16:25 -0800161 friend struct hmtxvmtx;
162
Ebrahim Byagowib2ebaa92018-12-16 22:38:10 +0330163 void init (hb_face_t *face,
Garret Rieger03e88ea2019-01-28 16:15:06 -0800164 unsigned int default_advance_ = 0)
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800165 {
Behdad Esfahbod96f1f522018-02-12 18:48:51 -0800166 default_advance = default_advance_ ? default_advance_ : hb_face_get_upem (face);
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800167
168 bool got_font_extents = false;
Ebrahim Byagowif7cfe992018-12-08 13:40:44 +0330169 if (T::os2Tag != HB_TAG_NONE && face->table.OS2->is_typo_metrics ())
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800170 {
Ebrahim Byagowif7cfe992018-12-08 13:40:44 +0330171 ascender = abs (face->table.OS2->sTypoAscender);
172 descender = -abs (face->table.OS2->sTypoDescender);
173 line_gap = face->table.OS2->sTypoLineGap;
174 got_font_extents = (ascender | descender) != 0;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800175 }
176
Behdad Esfahbod9583e002018-07-22 22:40:32 -0700177 hb_blob_t *_hea_blob = hb_sanitize_context_t().reference_table<H> (face);
Behdad Esfahbodeba1c162018-05-08 02:47:42 -0700178 const H *_hea_table = _hea_blob->as<H> ();
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800179 num_advances = _hea_table->numberOfLongMetrics;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800180 if (!got_font_extents)
181 {
Behdad Esfahbod401cdf02018-10-23 17:00:49 -0700182 ascender = abs (_hea_table->ascender);
183 descender = -abs (_hea_table->descender);
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800184 line_gap = _hea_table->lineGap;
185 got_font_extents = (ascender | descender) != 0;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800186 }
187 hb_blob_destroy (_hea_blob);
188
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800189 has_font_extents = got_font_extents;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800190
Behdad Esfahbodbb9abb42018-11-11 00:39:52 -0500191 table = hb_sanitize_context_t().reference_table<hmtxvmtx> (face, T::tableTag);
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800192
193 /* Cap num_metrics() and num_advances() based on table length. */
Behdad Esfahbodbb9abb42018-11-11 00:39:52 -0500194 unsigned int len = table.get_length ();
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800195 if (unlikely (num_advances * 4 > len))
196 num_advances = len / 4;
197 num_metrics = num_advances + (len - 4 * num_advances) / 2;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800198
199 /* We MUST set num_metrics to zero if num_advances is zero.
200 * Our get_advance() depends on that. */
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800201 if (unlikely (!num_advances))
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800202 {
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800203 num_metrics = num_advances = 0;
Behdad Esfahbodda6aa3b2018-11-11 11:40:57 -0500204 table.destroy ();
Behdad Esfahbodbb9abb42018-11-11 00:39:52 -0500205 table = hb_blob_get_empty ();
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800206 }
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800207
Behdad Esfahbodbb9abb42018-11-11 00:39:52 -0500208 var_table = hb_sanitize_context_t().reference_table<HVARVVAR> (face, T::variationsTag);
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800209 }
210
Ebrahim Byagowie4120082018-12-17 21:31:01 +0330211 void fini ()
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800212 {
Behdad Esfahbodda6aa3b2018-11-11 11:40:57 -0500213 table.destroy ();
214 var_table.destroy ();
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800215 }
216
Behdad Esfahbod8dc62962018-10-15 01:09:05 -0700217 /* TODO Add variations version. */
Ebrahim Byagowib2ebaa92018-12-16 22:38:10 +0330218 unsigned int get_side_bearing (hb_codepoint_t glyph) const
Behdad Esfahbod8dc62962018-10-15 01:09:05 -0700219 {
220 if (glyph < num_advances)
221 return table->longMetricZ[glyph].sb;
222
Behdad Esfahbode0125022018-10-31 18:14:00 -0700223 if (unlikely (glyph >= num_metrics))
Behdad Esfahbod8dc62962018-10-15 01:09:05 -0700224 return 0;
225
226 const FWORD *bearings = (const FWORD *) &table->longMetricZ[num_advances];
227 return bearings[glyph - num_advances];
228 }
229
Ebrahim Byagowib2ebaa92018-12-16 22:38:10 +0330230 unsigned int get_advance (hb_codepoint_t glyph) const
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800231 {
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800232 if (unlikely (glyph >= num_metrics))
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800233 {
Behdad Esfahbod8dc62962018-10-15 01:09:05 -0700234 /* If num_metrics is zero, it means we don't have the metrics table
235 * for this direction: return default advance. Otherwise, it means that the
236 * glyph index is out of bound: return zero. */
237 if (num_metrics)
238 return 0;
239 else
240 return default_advance;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800241 }
242
Behdad Esfahboddff2c452018-09-10 23:29:26 +0200243 return table->longMetricZ[MIN (glyph, (uint32_t) num_advances - 1)].advance;
Rod Sheeterfa877702018-02-14 14:16:25 -0800244 }
245
Ebrahim Byagowib2ebaa92018-12-16 22:38:10 +0330246 unsigned int get_advance (hb_codepoint_t glyph,
247 hb_font_t *font) const
Rod Sheeterfa877702018-02-14 14:16:25 -0800248 {
Rod Sheeter0758cbc2018-02-15 11:29:01 -0800249 unsigned int advance = get_advance (glyph);
Ebrahim Byagowi11aa0462018-11-15 23:10:56 +0330250 if (likely (glyph < num_metrics))
Rod Sheeter0758cbc2018-02-15 11:29:01 -0800251 {
Behdad Esfahbod8dc62962018-10-15 01:09:05 -0700252 advance += (font->num_coords ? var_table->get_advance_var (glyph, font->coords, font->num_coords) : 0); // TODO Optimize?!
Rod Sheeter0758cbc2018-02-15 11:29:01 -0800253 }
Garret Rieger64cf53d2018-03-02 17:33:49 -0800254 return advance;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800255 }
256
Garret Rieger03e88ea2019-01-28 16:15:06 -0800257 unsigned int num_advances_for_subset (const hb_subset_plan_t *plan) const
258 {
259 unsigned int num_advances = plan->num_output_glyphs ();
260 unsigned int last_advance = _advance_for_new_gid (plan,
261 num_advances - 1);
262 while (num_advances > 1 &&
263 last_advance == _advance_for_new_gid (plan,
264 num_advances - 2))
265 {
266 num_advances--;
267 }
268
269 return num_advances;
270 }
271
272 private:
273 unsigned int _advance_for_new_gid (const hb_subset_plan_t *plan,
274 hb_codepoint_t new_gid) const
275 {
276 hb_codepoint_t old_gid;
277 if (!plan->old_gid_for_new_gid (new_gid, &old_gid))
278 return 0;
279
280 return get_advance (old_gid);
281 }
282
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800283 public:
284 bool has_font_extents;
Behdad Esfahbod48d16c22018-11-14 09:56:30 -0500285 int ascender;
286 int descender;
287 int line_gap;
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800288
Rod Sheeterfa877702018-02-14 14:16:25 -0800289 protected:
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800290 unsigned int num_metrics;
291 unsigned int num_advances;
292 unsigned int default_advance;
Behdad Esfahboda7f15952017-11-14 20:02:24 -0800293
Rod Sheeterfa877702018-02-14 14:16:25 -0800294 private:
Behdad Esfahbodbb9abb42018-11-11 00:39:52 -0500295 hb_blob_ptr_t<hmtxvmtx> table;
296 hb_blob_ptr_t<HVARVVAR> var_table;
Behdad Esfahboda85d7ea2017-11-14 20:00:34 -0800297 };
298
299 protected:
Behdad Esfahboddff2c452018-09-10 23:29:26 +0200300 UnsizedArrayOf<LongMetric>longMetricZ;/* Paired advance width and leading
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +0200301 * bearing values for each glyph. The
302 * value numOfHMetrics comes from
303 * the 'hhea' table. If the font is
304 * monospaced, only one entry need
305 * be in the array, but that entry is
306 * required. The last entry applies to
307 * all subsequent glyphs. */
Behdad Esfahboddff2c452018-09-10 23:29:26 +0200308/*UnsizedArrayOf<FWORD> leadingBearingX;*//* Here the advance is assumed
Behdad Esfahbodd41b8092014-09-25 13:04:08 +0300309 * to be the same as the advance
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +0200310 * for the last entry above. The
311 * number of entries in this array is
312 * derived from numGlyphs (from 'maxp'
Behdad Esfahbodd41b8092014-09-25 13:04:08 +0300313 * table) minus numberOfLongMetrics.
314 * This generally is used with a run
315 * of monospaced glyphs (e.g., Kanji
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +0200316 * fonts or Courier fonts). Only one
317 * run is allowed and it must be at
318 * the end. This allows a monospaced
Behdad Esfahbodd41b8092014-09-25 13:04:08 +0300319 * font to vary the side bearing
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +0200320 * values for each glyph. */
321 public:
Behdad Esfahboddff2c452018-09-10 23:29:26 +0200322 DEFINE_SIZE_ARRAY (0, longMetricZ);
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +0200323};
324
Rod Sheeterfa877702018-02-14 14:16:25 -0800325struct hmtx : hmtxvmtx<hmtx, hhea> {
Behdad Esfahbodef006542019-01-22 12:08:57 +0100326 static constexpr hb_tag_t tableTag = HB_OT_TAG_hmtx;
327 static constexpr hb_tag_t variationsTag = HB_OT_TAG_HVAR;
328 static constexpr hb_tag_t os2Tag = HB_OT_TAG_OS2;
Behdad Esfahbodd41b8092014-09-25 13:04:08 +0300329};
Rod Sheeterfa877702018-02-14 14:16:25 -0800330struct vmtx : hmtxvmtx<vmtx, vhea> {
Behdad Esfahbodef006542019-01-22 12:08:57 +0100331 static constexpr hb_tag_t tableTag = HB_OT_TAG_vmtx;
332 static constexpr hb_tag_t variationsTag = HB_OT_TAG_VVAR;
333 static constexpr hb_tag_t os2Tag = HB_TAG_NONE;
Behdad Esfahbodd41b8092014-09-25 13:04:08 +0300334};
Behdad Esfahbod7c8e8442012-08-28 17:57:49 -0400335
Behdad Esfahbod3a0b3a22018-08-26 15:11:24 -0700336struct hmtx_accelerator_t : hmtx::accelerator_t {};
337struct vmtx_accelerator_t : vmtx::accelerator_t {};
338
Behdad Esfahbod7d52e662012-11-16 18:49:54 -0800339} /* namespace OT */
Behdad Esfahbod7c8e8442012-08-28 17:57:49 -0400340
341
Behdad Esfahbod24bcdbc2011-08-24 19:13:15 +0200342#endif /* HB_OT_HMTX_TABLE_HH */