Commit Graph

342 Commits

Author SHA1 Message Date
Behdad Esfahbod 92b1e025c6 Move some code from hb-open-type-private.hh to hb-machinery-private.hh 2018-07-25 16:58:47 -07:00
Behdad Esfahbod 61eddbd8ef Fix infinite loop in loading num_glyphs within sanitizer 2018-07-23 14:44:10 -07:00
Behdad Esfahbod c6bc7c3831 Set num glyphs on sanitizer reference_table()
Move out-of-class definitions of two methods to hb-static so they
are accessible in libharfbuzz-subset.
2018-07-23 11:46:46 -07:00
Behdad Esfahbod 9401829d4e Remove Sanitizer<> 2018-07-22 22:50:58 -07:00
Behdad Esfahbod 9583e0077d Port more off of Sanitizer<> 2018-07-22 22:43:25 -07:00
Behdad Esfahbod e7737b41d7 Add sanitizer reference_table, also fix clang build
Clang is being really peculiar.  Fix with:

-  inline hb_blob_t *sanitize (hb_blob_t *blob) { return c->sanitize<Type> (blob); }
+  inline hb_blob_t *sanitize (hb_blob_t *blob) { return c[0].template/*clang idiosyncrasy*/sanitize_blob<Type> (blob); }
2018-07-22 22:24:31 -07:00
Behdad Esfahbod a8cc0b5907 Remove TODO that is not gonna be done
Previously the idea was to cache sanitize results externally (think,
in Fontconfig) and avoid resanitizing every time.  That's, not a good
idea.
2018-07-17 19:09:03 +02:00
Behdad Esfahbod be70738400 Move sanitizer code around a bit 2018-07-17 18:51:59 +02:00
Behdad Esfahbod db5d430eff [aat] Update for blob changes
Also, uncomment code again, just "if (0)" it out, so it doesn't get stale again.
2018-07-17 18:14:45 +02:00
Behdad Esfahbod bda242409f Implement C++11 <atomic> operations
Fixes https://github.com/harfbuzz/harfbuzz/issues/345
2018-07-16 15:45:22 +02:00
Behdad Esfahbod be458eb059 Include more basic internal headers from hb-private.hh 2018-07-10 14:41:04 +02:00
Behdad Esfahbod bddeb2b10c Minor renamings of internal inline functions 2018-07-10 14:13:21 +02:00
Ebrahim Byagowi 225b92b7d4
Support dfont font files (#949) 2018-07-01 14:32:00 +04:30
Behdad Esfahbod dcd1b07eea Add const OffsetTo<> dereference
Unused, but now that we have CrapPool, implement it.
2018-05-31 17:58:40 -07:00
Behdad Esfahbod 5d80129891 Add CrapPool
Common Regoin for Access Protection.  Like the NullPool, but writable.
2018-05-24 13:53:02 -07:00
Behdad Esfahbod 191c4edc54 Reinstante DEFINE_NULL_DATA
Seems like I messed up; buffer overrun got reported.
2018-05-09 15:31:57 -07:00
Behdad Esfahbod 63f57f4dab Mark more unsized array's as arrayZ 2018-05-08 16:56:11 -07:00
Behdad Esfahbod 2a2e28e701 Don't keep instance in hb_table_lazy_loader_t 2018-05-08 03:00:21 -07:00
Behdad Esfahbod 57bac8f699 Rename 2018-05-08 02:55:20 -07:00
Behdad Esfahbod 2a46a020fd Minor 2018-05-08 02:53:03 -07:00
Behdad Esfahbod eba1c16a60 Always lock blob in sanitize. Remove blob->lock_as() in favor of blob->lock() 2018-05-08 02:47:42 -07:00
Behdad Esfahbod b4fa505014 Move Sanitizer::lock_instance<>() to blob->lock_as<>(). 2018-05-08 02:45:08 -07:00
Behdad Esfahbod abc12f7b81 Move null pool to hb-private 2018-05-08 02:23:36 -07:00
Behdad Esfahbod 5b93f69169 Rename some X-terminated members to Z-terminated
X-terminated means don't access this, it's not located correctly.
Z-terminated means this is a C array with no bound checking.
2018-05-02 14:59:14 -04:00
Ebrahim Byagowi 816b8169a9 Resolve some of clang's double-promotion warnings 2018-04-23 11:38:45 -07:00
Ebrahim Byagowi 24b8b9b227 Resolve clang's used-but-marked-unused warnings 2018-04-23 11:38:45 -07:00
Ebrahim Byagowi f5811bad04
Add round to F2DOT14 inner store setter (#990)
It uses floor implicitly without it but explicit use of round will be more correct.
2018-04-17 09:13:03 +04:30
Ebrahim Byagowi ce99dd04de
Implement to_float and set_float of F2DOT14 (#984) 2018-04-15 22:08:50 +04:30
Ebrahim Byagowi 435b1878e7
Rename UINT24 to HBUINT24 for consistency (#983) 2018-04-15 21:18:48 +04:30
Ebrahim Byagowi f8bb582bcc
[ot-color] Cosmetic changes (#962) 2018-04-11 17:13:20 +04:30
Behdad Esfahbod a0dccb6188 Add NameID 2018-03-15 07:47:02 -07:00
Behdad Esfahbod 6418ae4e8a [color/COLR] Clean up 2018-03-15 07:47:02 -07:00
Behdad Esfahbod df1c7d5b60 Minor 2018-02-25 19:06:25 -08:00
Ebrahim Byagowi 1ab16f4556
[aat] Implement trak logic (#816) 2018-02-24 12:49:42 +03:30
Behdad Esfahbod ec2538c880 [subset] Fix checksum calc out-of-bounds access 2018-02-23 15:51:26 -08:00
Garret Rieger 2cc845f311 [subset] fix calculation of range shiftz. Should be 16 * len - searchRange not 16 * (len - searchRange). 2018-02-20 18:36:11 -08:00
Behdad Esfahbod e2d2d81984 Limit how much work sanitize() can do
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=6022
2018-02-18 17:28:53 -08:00
Behdad Esfahbod dde6448379 Another try at fixing multiple-defintion of NullPool
This one might do it...
2018-02-11 18:24:22 -08:00
Behdad Esfahbod cd32177a32 Try at fixing multiple-definition of NullPool
If we don't have visibility, make NullPool static.
2018-02-11 19:36:00 -06:00
Behdad Esfahbod 71130a20fa Replace Supplier.advance with Supplier::operator+= 2018-02-10 13:15:57 -06:00
Ebrahim Byagowi ad575a5f47
Fix cast warnings on clang (#768) 2018-02-10 19:50:11 +03:30
Behdad Esfahbod c479a59988 [subset] Assemble font 2018-02-07 21:26:04 -06:00
Behdad Esfahbod 2da0d87e76 Remove NullPool visibility hack
We keep a separate private NullPool in libharfbuzz-subset.so
This can fire back later since now there are two separate null objects,
and comparisons to the null pool can be confused.  Something to deal
with when it comes up. Ouch!
2018-02-07 12:44:35 -05:00
Rod Sheeter 38df1ec8e0 TEMPORARY: remove HB_INTERNAL from null pool so subset builds again 2018-02-07 12:41:21 -05:00
Behdad Esfahbod e6263c7142 [aat] Wire up table length to apply() 2018-01-15 15:37:55 -05:00
Behdad Esfahbod 9b82aa19d8 More warning fixes 2018-01-11 18:19:42 +01:00
Behdad Esfahbod ca42d96129 [aat] Implement RearrangementSubtable 2018-01-11 10:43:30 +01:00
Behdad Esfahbod 6b19178ee3 Prefix int types with HB
Such a headache that Windows defines UINT8, ...; Just prefix it.
2018-01-10 03:07:30 +01:00
Behdad Esfahbod 470fe5b603 [aat] Implement Lookup table
Untested, but compiles.
2018-01-10 02:50:49 +01:00
Behdad Esfahbod 7c7cb42d81 [aat] Update previous commits for rebase on master 2018-01-10 02:50:49 +01:00