Behdad Esfahbod
29f60d1eaa
[cff] Remove init/fini from blend_arg_t
2022-01-18 11:58:16 -07:00
Behdad Esfahbod
213e3f09b1
[vector] Add TODO Emplace?
2022-01-18 11:53:52 -07:00
Garret Rieger
f1dc8b087c
[subset-cff] Convert subr_closures_t to constructor/destructor instead of init/fini.
2022-01-18 10:29:04 -08:00
Behdad Esfahbod
a48aa9850a
[subset-cff] Remove another set of fini_deep
2022-01-18 09:32:58 -07:00
Behdad Esfahbod
07474aa8c6
[subset-cff1] Remove a constructor/destructor pair
2022-01-18 09:29:43 -07:00
Behdad Esfahbod
a1e9a276eb
[subset-cff2] Drop an constructor/destructor pair
2022-01-18 09:27:32 -07:00
Behdad Esfahbod
035f03346d
[str_buff_vec_t] Remove unused fini method
2022-01-18 09:26:30 -07:00
Behdad Esfahbod
de2cef42b4
[bimap] Remove init/fini
2022-01-18 09:21:31 -07:00
Behdad Esfahbod
c3dd21f110
[cff] Remove unneeded init/fini
2022-01-18 09:11:08 -07:00
Behdad Esfahbod
15cceff3d7
[repacker] Replace fini_deep() with fini()
...
Vector calls destructor now.
2022-01-17 16:46:45 -07:00
Behdad Esfahbod
1198fb2468
[vector] Adjust construction criteria
2022-01-17 16:46:45 -07:00
Behdad Esfahbod
c58bfa35fb
[vector] Move semantics in vector remove()
2022-01-17 16:46:45 -07:00
Behdad Esfahbod
5946e945d5
[vector] Destruct in pop()
2022-01-17 16:46:45 -07:00
Behdad Esfahbod
7171917b52
[vector] Construct items when enlarging
2022-01-17 16:46:45 -07:00
Behdad Esfahbod
813eaba6ea
[vector] Start adding destruction
...
Now we need to remove manual destruction, ouch!
2022-01-17 16:46:45 -07:00
Behdad Esfahbod
65a22836f8
[vector] Add XXX markers for remaining places that need work
2022-01-17 16:46:45 -07:00
Behdad Esfahbod
92f179075f
Make hb_coerce static inline
...
That's the pattern we follow.
985b63b3ee (commitcomment-63973544)
2022-01-16 07:51:35 -07:00
Behdad Esfahbod
19793f333b
Better try at previous commit
...
985b63b3ee (commitcomment-63973544)
2022-01-16 07:49:40 -07:00
Behdad Esfahbod
1173ed1f7f
Try fix Mac build
...
985b63b3ee (commitcomment-63973544)
2022-01-16 07:48:02 -07:00
Behdad Esfahbod
c0f57ccc88
[algs] Add default-construtor to hb_pair_t
2022-01-16 07:01:05 -07:00
luz paz
e2e305066a
Fix various typos
...
Found via `codespell -q 3 -S ./perf/texts -L actualy,ba,beng,fo,gir,inout,nd,ot,pres,ro,te,teh,timne`
2022-01-16 05:39:03 -08:00
Behdad Esfahbod
589bea15b7
Fix previous commit
2022-01-15 17:55:10 -07:00
Behdad Esfahbod
b97e4f7084
Further adjust setlocale
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3375#issuecomment-1013783496
2022-01-15 17:47:51 -07:00
Behdad Esfahbod
63affc4eae
[vector] Move semantics when resizing
2022-01-15 12:24:20 -08:00
Behdad Esfahbod
1c50106608
[meta] Include <memory>, for addressof
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3375
2022-01-15 13:09:06 -07:00
Behdad Esfahbod
71e6f742a8
[meta] Remove unused hb_ref()
2022-01-15 13:09:06 -07:00
Garret Rieger
e30511a8de
[map] Correct previous commit, if (...) was reversed.
2022-01-14 16:48:42 -08:00
Garret Rieger
ff4e8c7eac
[map] Fix bad memory access if hb_map.fini() was called twice.
2022-01-14 16:42:39 -08:00
Behdad Esfahbod
8a69e00639
[meta] Use std::addressof() instead of hb_addressof()
2022-01-13 16:17:34 -07:00
Behdad Esfahbod
b7b0a15f7e
[meta] Remove hb_add_const
2022-01-13 15:33:27 -07:00
Behdad Esfahbod
3b2e604237
[meta] Use std::is_const instead of hb_is_const
2022-01-13 15:32:46 -07:00
Behdad Esfahbod
909dde9df1
[meta] Use std::is_reference instead of hb_is_reference
2022-01-13 15:30:10 -07:00
Behdad Esfahbod
47afb3ef04
[meta] Replace hb_is_pointer with std::is_pointer
2022-01-13 15:27:41 -07:00
Behdad Esfahbod
956e0a4d13
[map] Destruct objects
2022-01-13 15:07:10 -07:00
Behdad Esfahbod
bc0a5fdf43
[test-map] Add disabled tests with std::string
2022-01-13 13:34:22 -07:00
Behdad Esfahbod
985b63b3ee
[map] Allow invalid items to be pointer to static object
...
By derefencing them when necessary.
Also, we do not rely on trivially-copyable, so remove that assertion.
2022-01-13 13:33:07 -07:00
Behdad Esfahbod
98b26eedf5
[check-static-inits] Only check library object files
2022-01-13 13:12:10 -07:00
Behdad Esfahbod
1e27f95dc1
[algs] Add hb_coerce()
2022-01-13 13:10:47 -07:00
Behdad Esfahbod
5a91db1135
[map] Remove constexpr invalid items
...
These were non-workable in the general case, eg std::string.
2022-01-13 12:44:48 -07:00
Behdad Esfahbod
114046dc27
[map] Construct objects
2022-01-13 12:38:26 -07:00
Behdad Esfahbod
ca4f56bdc7
[map] Massage some more
...
Towards being able to store arbitrary types.
2022-01-13 12:18:59 -07:00
Behdad Esfahbod
cfe2b66114
[algs] Fix hash chaining to std::hash()
2022-01-13 12:18:59 -07:00
Garret Rieger
87496bf63e
[subset] fix fuzzer timeout if visisted_paint goes into error.
2022-01-13 11:08:24 -08:00
Khaled Hosny
0acf466c44
[doc] Fix hb_font_set_synthetic_slant param name
2022-01-13 01:29:30 +02:00
Behdad Esfahbod
fa12f1ae25
Rename method
2022-01-12 15:08:34 -07:00
Behdad Esfahbod
9408e0d6d1
Rename variable
2022-01-12 15:07:34 -07:00
Behdad Esfahbod
96c969c820
Preserve glyph props
2022-01-12 15:06:40 -07:00
Behdad Esfahbod
0b2c514fb4
More macro cleanup
2022-01-12 11:20:58 -07:00
Behdad Esfahbod
0a42f46ce9
Fix compiler warning
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3364
2022-01-12 11:16:17 -07:00
Matthias Clasen
72f0b24ee3
docs: Clarify variation apis ( #3363 )
...
Make it explicit that the variations setters
replace all existing variations, even if
not all axes are included in the provided
values.
Co-authored-by: Matthias Clasen <mclasen@redhat.com>
2022-01-12 11:08:02 -07:00
Matthias Clasen
befe3b5d5a
color: Document empty returns ( #3362 )
...
Document that the SVG and PNG getters return
the singleton empty blob if the glyph has no
color.
Fixes : #1413
Co-authored-by: Matthias Clasen <mclasen@redhat.com>
2022-01-12 11:07:25 -07:00
Behdad Esfahbod
13643934aa
Clean up HB_NO_SETLOCALE
...
https://github.com/harfbuzz/harfbuzz/pull/3358#pullrequestreview-850500143
2022-01-12 10:54:28 -07:00
Behdad Esfahbod
53847dba92
[algs] Call std::hash from hb_hash()
2022-01-12 10:35:28 -07:00
Behdad Esfahbod
74811c501d
[map] Map == / != use correct types
2022-01-12 10:35:28 -07:00
Behdad Esfahbod
ce7f19a2cc
Revert "[map] Actually use k/v invalid types for declaration!"
...
This reverts commit 6f559346ac
.
Err. My bad.
2022-01-10 14:40:27 -07:00
Behdad Esfahbod
6f559346ac
[map] Actually use k/v invalid types for declaration!
2022-01-10 14:29:36 -07:00
Behdad Esfahbod
a45a630539
Fix unintentional locale dependency ( #3358 )
...
Avoid unintentional locale dependency
hb_variation_to_string uses sprintf with %g, which will produce
a locale-dependent decimal point, which is not desired here.
The output is supposed to be compatible with CSS syntax, and
that always uses '.' for the decimal point.
Fix this by changing the per-thread locale to "C" around sprintf call.
Fixes https://github.com/harfbuzz/harfbuzz/issues/3355
Fixes https://github.com/harfbuzz/harfbuzz/pull/3357
Fixes https://github.com/harfbuzz/harfbuzz/pull/3358
Co-authored-by: Matthias Clasen <mclasen@redhat.com>
2022-01-08 16:47:33 -07:00
Matthias Clasen
d70825a6d1
docs: Add some details about coordinates
...
Mention what the effective values are when
coordinates have not been set.
2022-01-08 06:46:22 -08:00
Behdad Esfahbod
0a5c1c9705
[failing-alloc] Make it compile as C++ as well
2022-01-04 14:18:38 -07:00
Behdad Esfahbod
bea5369c6d
[buffer] Rename swap_buffers() to sync()
2022-01-04 10:52:05 -07:00
Behdad Esfahbod
d1e7df5c3f
[buffer] Add enter()/leave() pair around shape()
2022-01-04 07:32:04 -07:00
Behdad Esfahbod
43be5ba442
[buffer] Group shape-related members together
2022-01-04 07:26:53 -07:00
Behdad Esfahbod
52f5711ed0
[buffer] Add hb_buffer_create_similar()
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/1555
2022-01-03 11:57:42 -07:00
Behdad Esfahbod
f643b81ffc
[buffer] Clean up internal state bookkeeping
...
hb_buffer_reset() was NOT resetting cluster_level. Ouch! Fix that.
Part of https://github.com/harfbuzz/harfbuzz/issues/1555
2022-01-03 11:45:31 -07:00
Behdad Esfahbod
36e9f467a4
[buffer] Overlay segment-properties in hb_buffer_append()
...
Part of https://github.com/harfbuzz/harfbuzz/issues/1555
2022-01-03 11:23:14 -07:00
Behdad Esfahbod
6a66992842
Add hb_segment_properties_overlay()
...
New API:
+ hb_segment_properties_overlay()
2022-01-03 11:21:29 -07:00
Behdad Esfahbod
165a6073fa
Merge pull request #3338 from harfbuzz/slant
...
[font] Add public API for synthetic slant
2022-01-02 12:02:20 -07:00
Behdad Esfahbod
3fc2e654c0
[metrics] Fix slant calc
2022-01-02 11:56:45 -07:00
Behdad Esfahbod
a7751277e9
[docs] Add hb_font_[gs]et_synthetic_slant()
2022-01-02 11:50:02 -07:00
Behdad Esfahbod
4ab94443bb
[metrics] Ouch. Fix slant code
2022-01-02 11:26:45 -07:00
Behdad Esfahbod
f7d49d9c2b
[metrics] Simplify
2022-01-02 11:16:33 -07:00
Behdad Esfahbod
f1ba1f940f
[metrics] Only scale caret rise/run if font is slanted
2022-01-02 10:58:25 -07:00
Behdad Esfahbod
45c2b6e384
[metrics] Harden math
2022-01-02 10:57:19 -07:00
Behdad Esfahbod
fa008a021f
[metrics] Implement synthetic slant for caret slope
...
Part of https://github.com/harfbuzz/harfbuzz/pull/3338
2022-01-02 10:46:38 -07:00
Behdad Esfahbod
fc329f665f
[metrics] Scale up horizontal caret rise/run
...
Eg. if rise/run are 1/0, we now return upem/0. This is equivalent.
Part of https://github.com/harfbuzz/harfbuzz/pull/3338
2022-01-02 10:43:13 -07:00
Behdad Esfahbod
0df83f52a1
Fix test
2022-01-02 08:01:11 -07:00
Behdad Esfahbod
5b87c30d6b
[font] Mark hb_font_get_var_coords_design() non-experimental
...
Any remaining issue with the API will address later by deprecating it.
Fixes https://github.com/harfbuzz/harfbuzz/issues/1865
2022-01-02 07:53:45 -07:00
Behdad Esfahbod
2d42fc9fbb
[font] Load named-instance if face index top bits are set
...
This matches FreeType behavior.
Fixes https://github.com/harfbuzz/harfbuzz/issues/3348
2022-01-02 07:45:10 -07:00
Behdad Esfahbod
da7dba0002
[face] Clarify face_index handling
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3347
2022-01-01 11:20:20 -07:00
Behdad Esfahbod
6da4b80e5f
[hb-ot-var] Specify normalized 2.14 docs
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3345
2021-12-22 21:51:03 -07:00
Behdad Esfahbod
1b51be57dc
[hb-ot-var] Actually set in/out argument
...
Fixes https://github.com/harfbuzz/harfbuzz/pull/3344
2021-12-22 21:43:48 -07:00
Behdad Esfahbod
06ee40213c
Use invisible-glyph for spaces if font has no ASCII space
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3340
Should add tests ideally.
2021-12-22 21:34:44 -07:00
Behdad Esfahbod
602bd39680
[style] Adjust font slant angle for synthetic slant value
...
Part of https://github.com/harfbuzz/harfbuzz/pull/3338
2021-12-19 21:40:25 -08:00
Behdad Esfahbod
ff697debd8
[GPOS] Apply font synthetic slant
...
Part of fixing https://github.com/harfbuzz/harfbuzz/issues/3196
2021-12-19 21:20:25 -08:00
Behdad Esfahbod
810f5d71c7
[font] Add public API for slant
...
Not hooked up internally to anything.
New API:
+ hb_font_set_synthetic_slant()
+ hb_font_get_synthetic_slant()
Part of fixing https://github.com/harfbuzz/harfbuzz/issues/3196
2021-12-19 21:20:25 -08:00
Garret Rieger
067f90a820
[subset] Fix for fuzzer timeout.
...
Fixes https://oss-fuzz.com/testcase-detail/5549945449480192
In prune_langsys: move LangSys visited check up before any work is done for a LangSys. In this particular case the compare() method is responsible for the majority of the time spent and wasn't being guarded with a visisted check.
2021-12-14 17:34:21 -07:00
Garret Rieger
c4573c2ec7
[repacker] don't infinite loop if visited or roots is in error.
...
Fixes https://oss-fuzz.com/testcase-detail/5205038086094848
2021-12-14 15:57:48 -07:00
Khaled Hosny
be91d2917d
3.2.0
2021-12-12 04:45:54 +02:00
Garret Rieger
77507a1d8d
[subset] Don't double count visit lookups in closure_lookups
...
Each recursed lookup was getting counted once in closure_lookups() and then again in hb_closure_lookups_context_t::recurse.
2021-12-10 15:13:49 -07:00
Garret Rieger
d67025705f
[subset] reset the visited lookup count before each closure iteration.
2021-12-10 15:13:49 -07:00
Behdad Esfahbod
23159084b4
[morx] Reverse graphemese, not whole buffer
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3314
Supersedes https://github.com/harfbuzz/harfbuzz/pull/3315
2021-12-10 15:02:57 -07:00
Behdad Esfahbod
5b995526f7
[buffer] Fix reverse_group() to reverse() at the end
2021-12-10 14:59:56 -07:00
Behdad Esfahbod
21c4fc1011
[buffer] Add optional merge_clusters arg to reverse_groups()
2021-12-10 13:02:43 -07:00
Behdad Esfahbod
e949e51218
[ot-layout] Port foreach_grapheme to buffer foreach_group
2021-12-10 12:58:27 -07:00
Behdad Esfahbod
eb96e69d18
[buffer] Add foreach_group()
2021-12-10 12:55:29 -07:00
Behdad Esfahbod
1b78e04c78
[buffer] Add ::reverse_groups()
2021-12-10 12:45:43 -07:00
Behdad Esfahbod
4cd96e73e4
[buffer] Inline revers_range() / reverse()
2021-12-10 12:33:21 -07:00
Garret Rieger
5914acb3cb
[repacker] Clear distance and position cache when assigning a new space.
...
A change in space will effect the distance assigned to the node and any of it's children so clear the distance cache.
2021-12-10 11:09:03 -07:00
Qunxin Liu
706014f69d
[subset] (Chain)ContextSubst glyph_closure fix
...
- When pos_glyphs is empty, use current full glyphs set as input for
subsequent recursive closure process
- Also increase max_lookup_visit_count to 35000 cause a real font file hit
previous limit 20000 and some lookups are dropped unexpectedly
2021-12-10 11:08:36 -07:00
Garret Rieger
441877f56a
[repacker] add test case for using max priority to resolve an overflow.
2021-12-09 17:46:52 -07:00
Garret Rieger
be2c488e5d
[repacker] Improve vertex priority packing.
...
Previous priority implementation would move a node further back within it's layer, but at max priority was unable to move any further up than that. This updates the implementation to have 3 priority levels:
1. Distance is reduced by half of table size.
2. Distance is reduced by full table size (move to beginning of the layer).
3. Distance is set to 0. Vertex will be packed as soon as possible.
Also makes the iterative resolutions aware of max priority, so it won't keep trying to raise priority beyond the maximum.
2021-12-09 17:46:52 -07:00
David Corbett
2404617a60
Update language system tag registry to OT 1.9
2021-12-09 07:18:57 -07:00
Behdad Esfahbod
002a1f70b8
[ft] Disable vertical funcs if HB_NO_VERTICAL
2021-12-08 10:45:30 -08:00
Behdad Esfahbod
ef14cad736
[GPOS] Disable vertical advance if HB_NO_VERTICAL
2021-12-08 10:43:52 -08:00
Behdad Esfahbod
6ed22de127
[CONFIG] Fix HB_NO_VERTICAL build without HB_TINY
2021-12-08 10:40:40 -08:00
Behdad Esfahbod
53eebc7cd2
[CONFIG] Add HB_NO_VERTICAL
2021-12-08 08:34:20 -08:00
Behdad Esfahbod
9bc5d2903a
[TINY] Don't disable VORG table in any config profile
...
Is needed for vertical layout of CFF fonts.
Fixes https://github.com/harfbuzz/harfbuzz/discussions/3294#discussioncomment-1770313
2021-12-08 08:16:17 -08:00
Garret Rieger
3e4a25098d
[repacker] add a maximum number of roots that can be moved in one iteration.
...
Set to half of the roots in a space. This prevents the repacker from moving all roots in a space to a new space if their are overflows in every root.
2021-12-06 21:27:28 -07:00
Garret Rieger
02b12d7965
[repacker] Move all overflowing roots to a new space simultaneously.
2021-12-06 21:27:28 -07:00
Garret Rieger
fa966bcc29
[repacker] create repacker output buffer after final length is known.
...
Don't rely on a buffer provided by the caller, as it may not be large enough.
2021-12-06 21:27:28 -07:00
Qunxin Liu
51655a078e
[subset] COLR : only include glyphs after COLR closure
2021-12-06 13:29:21 -07:00
Behdad Esfahbod
70f8c57e5c
[buffer] Rename find_min_cluster
2021-12-04 19:49:23 -08:00
Behdad Esfahbod
94d43c008a
[buffer] Merge and rename clear_glyph_flags()
2021-12-04 16:56:39 -08:00
Behdad Esfahbod
b95d252fab
[CONFIG] Add HB_CONFIG_OVERRIDE_H to simplify config overrides
2021-12-03 11:49:55 -07:00
Qunxin Liu
74b46b29e7
[subset] MATH: don't serialize coverage table when iterator is empty
...
when iterator is empty, just set coverage offset to 0.
serialize() in coverage will at lease write out a 16-bit format header.
2021-12-03 08:00:33 -07:00
Garret Rieger
1d9ef3a75a
[subset] Actually fix end_cp unitialized warning.
2021-12-01 11:53:10 -07:00
Garret Rieger
d8635dfe5a
[subset] Fix warning about uninitialized use of end_cp.
2021-12-01 11:17:46 -07:00
Khaled Hosny
7608b19167
[directwrite] Set unsafe to break flag
...
Like the rest of platform shapers. Otherwise hb-shape --verify goes
crazy.
2021-12-01 19:55:48 +02:00
Khaled Hosny
361a438658
Revert "Revert "[hb-directwrite] Don't load dwrit.dll dynamically""
...
This reverts commit ecbe224743
.
It was causing directwrite shaper to crash in MSVC builds.
2021-12-01 19:55:48 +02:00
Khaled Hosny
549e2b7038
Revert "Remove direct link to dwrite from meson scripts"
...
This reverts commit 6ea6c581ed
.
2021-12-01 19:55:48 +02:00
Garret Rieger
071aea42c2
[iter] add specialized implementation for hb_concat forward when iterators are not random access.
2021-12-01 08:37:04 -07:00
Garret Rieger
2e935514d9
[iter] fix forward implementation in hb_concat().
...
Add test coverage for forward.
2021-12-01 08:37:04 -07:00
Garret Rieger
39e76af19e
[subset] add all_links () to object_t.
...
Helper to provide easy access to concatenated real and virtual links iterator.
2021-12-01 08:37:04 -07:00
Garret Rieger
9121ed0cec
[subset] Improve sharing of Ligature subtables.
...
Ligature subtables use virtual links to enforce an ordering constraint between the subtables and the coverage table. Unfortunately this has the sideeffect of prevent the subtables from being shared by another Ligature with a different coverage table since object equality compares all links real and virtual. This change makes virtual links stored separately from real links and updates the equality check to only check real links. If an object is de-duped any virtual links it has are merged into the object that replaces it.
2021-12-01 08:37:04 -07:00
Garret Rieger
ca22741110
[iter] add hb_concat (a, b).
...
Iterates over a, and then over b.
2021-12-01 08:37:04 -07:00
Garret Rieger
95329081c2
[subset] further optimize cmap4 packing.
2021-11-28 07:47:49 -07:00
Garret Rieger
599143824c
[subset] Don't pad glyphs when using long loca.
2021-11-26 18:01:04 -07:00
Garret Rieger
d9660fd58a
[subset] Make cmap4 packing more optimal.
...
The current CMAP4 implementation uses whatever the current codepoint ranges are and then encodes them as indivudal glyph ids or as a delta if possible. However, it's often possible to save bytes by splitting up existing ranges and encoding parts of them using deltas where the cost of splitting the range is less than encoding each glyph individual.
2021-11-26 13:21:50 -07:00
Khaled Hosny
8aed5c21a3
3.1.2
2021-11-26 17:54:18 +02:00
Qunxin Liu
903a6baece
[subset] layout_features filtering fix
...
we should not use get_size (), which returns length * item_size
2021-11-25 11:24:41 -07:00
Khaled Hosny
69d8f27c69
[meson] Require 0.55.0
...
We implicitly require it for building ragel subproject. This new version
requirement should satisfied in both Fedora 33 and Debian bullseye, and
not be too cutting edge for us.
2021-11-22 03:11:36 +02:00
Qunxin Liu
84dc4e85e8
[subset] avoid writing out duplicate extra glyph names in post table
...
Add check for possible duplicate with other name index
2021-11-19 17:22:35 -07:00
Behdad Esfahbod
325f26290e
[array] Fix a couple constexpr warnings
...
./subprojects/harfbuzz/src/hb-array.hh:71:25: warning: 'constexpr' non-static member function will not be implicitly 'const' in C++14; add 'const' to avoid a change in behavior [-Wconstexpr-not-const]
constexpr hb_array_t& operator = (const hb_array_t<U> &o)
^
const
../subprojects/harfbuzz/src/hb-array.hh:72:5: warning: use of this statement in a constexpr function is a C++14 extension [-Wc++14-extensions]
{ arrayZ = o.arrayZ; length = o.length; backwards_length = o.backwards_length; return *this; }
^
../subprojects/harfbuzz/src/hb-array.hh:329:32: warning: 'constexpr' non-static member function will not be implicitly 'const' in C++14; add 'const' to avoid a change in behavior [-Wconstexpr-not-const]
constexpr hb_sorted_array_t& operator = (const hb_array_t<U> &o)
^
const
../subprojects/harfbuzz/src/hb-array.hh:330:5: warning: use of this statement in a constexpr function is a C++14 extension [-Wc++14-extensions]
{ hb_array_t<Type> (*this) = o; return *this; }
^
4 warnings generated.
2021-11-19 17:19:09 -07:00
Behdad Esfahbod
98fefd5ded
Merge pull request #3301 from harfbuzz/hashmap-classes
...
Hashmap classes
2021-11-19 13:34:53 -07:00
Qunxin Liu
ca418cac74
[subset] keep features that have FeatureParams and the tag is "size"
2021-11-19 13:31:25 -07:00
Qunxin Liu
e88fc41ef3
[subset] inputSequence could be empty, change the sanity check
2021-11-19 12:57:43 -07:00
Behdad Esfahbod
4731b10736
[array] Mark constructors constexpr
...
../src/hb-map.hh:44:38: note: non-constexpr constructor 'hb_array_t' cannot be used in a constant expression
static constexpr K INVALID_KEY = kINVALID;
^
2021-11-19 12:33:37 -07:00
Behdad Esfahbod
1da7423ed9
[array] Add constructor taking std::nullptr_t
...
Not all impls implement nullptr_t in a way that would automatically
convert to what we were accepting.
In file included from ../src/test-map.cc:27:
../src/hb-map.hh:44:22: error: no viable conversion from 'nullptr_t' to 'const hb_array_t<const char>'
static constexpr K INVALID_KEY = kINVALID;
^ ~~~~~~~~
2021-11-19 12:11:41 -07:00
Behdad Esfahbod
e456922a76
[test] Fix nullptr_t scope issue
2021-11-19 12:04:08 -07:00
Behdad Esfahbod
5157cac0e2
[test] Silence unused-variable erros in test
2021-11-19 12:03:10 -07:00
Behdad Esfahbod
394f772937
[map] Allow storing classes in the hashmap
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3293
The trick was to change the type of the invalid key/value to be non-class.
2021-11-19 11:49:23 -07:00
Behdad Esfahbod
cba17fd101
[array] Add default methods again, this time the full set
...
Should add tests.
2021-11-19 11:49:03 -07:00
Garret Rieger
a75b96f7e5
[sanitize] In lookup sanitize don't try to access subtable 0 if it isn't there.
2021-11-16 15:00:50 -08:00
Behdad Esfahbod
82a9f54410
[colr] Simplify sanitize
2021-11-10 10:50:38 -08:00
Garret Rieger
64b29dbd59
[subset] reuse colrv1 max nesting depth constant for sanitize.
2021-11-10 10:34:46 -07:00
Garret Rieger
ace98cc65f
[subset] Only sanitize recursion depth in COLR.
2021-11-10 10:34:46 -07:00
Garret Rieger
782a7377ad
[sanitize] add a maximum recursion depth for sanitize.
2021-11-10 10:34:46 -07:00
Khaled Hosny
cd5c6cd041
3.1.1
2021-11-08 06:59:55 +02:00
Matthias Clasen
1e07d42aa6
Typo fix
2021-11-07 07:58:28 +02:00
Matthias Clasen
1fd7fd9823
Cosmetics: Avoid confusing indentation
...
This line had me confused for a second because
the condition looked like a cast and the if just
looked misplaced. Add a line break to prevent
such confusion.
2021-11-06 09:19:55 -07:00