Behdad Esfahbod
fd535a240b
[ft] Remove check_changed from get_glyph_shape()
...
Leftover.
2022-07-22 05:48:12 -06:00
Behdad Esfahbod
4f22397f05
[ft] A couple of introspection fixes
2022-07-18 11:03:54 -06:00
Behdad Esfahbod
6ed57de15c
[ft] Fix negative font sizes for bitmaps
2022-07-15 15:09:28 -06:00
Behdad Esfahbod
307ee9baff
[ft] Fix bitmap-only vertical metrics
2022-07-15 14:48:29 -06:00
Behdad Esfahbod
87d338eb61
[ft] Fix test
2022-07-15 14:26:47 -06:00
Khaled Hosny
e294200dac
[ft] Check for FT_Get_Transform at build time
2022-07-15 21:59:33 +02:00
Behdad Esfahbod
901236f721
[ft] Implement loading (color) bitmap fonts
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/489
Something about the vertical metrics is still off, not matching
hb-ot. I cannot figure out what.
2022-07-15 13:35:14 -06:00
Behdad Esfahbod
3ac110560d
[ft] Fix scale when font-sizes are negative
2022-07-15 12:48:11 -06:00
Khaled Hosny
98e90cc67c
[docs] Reduce warnings
...
Use markdown syntax for inline code blocks instead of %true, %false, and
%NULL.
2022-06-30 08:44:40 +02:00
Khaled Hosny
8537d68172
4.4.0
2022-06-27 20:51:16 +02:00
Behdad Esfahbod
8c27c51c27
[arabic-pua] Rename symbols
2022-06-19 10:47:38 -06:00
Behdad Esfahbod
7698962911
[arabic-fallback] Disable PUA shaping under HB_NO_OT_SHAPER_ARABIC_FALLBACK
2022-06-19 10:42:06 -06:00
Behdad Esfahbod
55350377b0
[cmap/ft] Only map 0xF000 range if font_page is NONE
2022-06-19 10:42:06 -06:00
Khaled Hosny
189e8c326e
[ft] Remap legacy Arabic PUA codepoints
...
Similar to what ot font finctions does, to support Support legacy
pre-OpenType Windows 3.1-era fonts.
2022-06-19 10:42:05 -06:00
Behdad Esfahbod
d6dbc0d175
[gi/ft] Silence warnings
...
gi doesn't understand that FT_Face is a pointer, and not bare struct.
So it skips these APIs anyway. Mark skip to silense the warning.
../src/hb-ft.cc:242: Warning: HarfBuzz: hb_ft_font_get_face: return value: Invalid non-constant return of bare structure or union; register as boxed type or (skip)
../src/hb-ft.cc:264: Warning: HarfBuzz: hb_ft_font_lock_face: return value: Invalid non-constant return of bare structure or union; register as boxed type or (skip)
2022-06-05 00:58:53 -06:00
Behdad Esfahbod
fc4d42ff99
[ft] Add API to notify that hb_font_t changed
...
New API:
- hb_ft_hb_font_changed()
Mostly reverts 56e0ff9ea1
Related https://github.com/harfbuzz/harfbuzz/issues/2270
Fixes https://github.com/harfbuzz/harfbuzz/issues/3619
2022-06-01 14:12:38 +01:00
Behdad Esfahbod
80c49933c6
[hb-ft] Adjust serial signature
2022-05-26 05:02:50 -06:00
Behdad Esfahbod
56e0ff9ea1
[ft] If hb_font changed, update FT_Face
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/2270
Rather untested.
2022-05-26 05:02:50 -06:00
Behdad Esfahbod
8629df188a
[ft] Discard advance cache if font changed
...
Uses newly added font serial API.
Part of https://github.com/harfbuzz/harfbuzz/issues/2270
But doesn't set new coords on the FT_Face. That's a lot more
work :(.
2022-05-26 05:02:50 -06:00
Behdad Esfahbod
05e82aa12e
[ft] Add missing lock to kerning function
2022-05-20 17:36:59 -06:00
Behdad Esfahbod
55804e8d68
[hb-ft] Minor rearrange of struct members
...
To make clear what members the lock protects.
2022-05-20 11:40:44 -06:00
Behdad Esfahbod
6d0e67dee0
[ot-font] Only use vmtx side-bearing if table exists
...
Part of fixing https://github.com/harfbuzz/harfbuzz/issues/537
2022-03-21 21:07:28 -06:00
Behdad Esfahbod
59067db9f4
[font/draw] Slant drawings
...
Need to update hb_font_set_synthetic_slant() docs now that we do this.
2022-02-13 13:21:14 -06:00
Behdad Esfahbod
6d5b998f25
[ft/draw] Implement hb-draw for hb-ft
2022-02-13 13:21:14 -06:00
Behdad Esfahbod
002a1f70b8
[ft] Disable vertical funcs if HB_NO_VERTICAL
2021-12-08 10:45:30 -08:00
Behdad Esfahbod
ed1163208d
Call atexit() via hb_atexit()
...
Part of https://github.com/harfbuzz/harfbuzz/issues/3197
2021-09-14 07:11:46 -04:00
Behdad Esfahbod
2337f0d047
Internally use hb_malloc/.../hb_free instead of malloc/.../free
...
Redefining those stock names as macros was conflicting with gcc 10
headers.
Fixes https://github.com/harfbuzz/harfbuzz/issues/3044
2021-07-08 10:54:09 -07:00
Behdad Esfahbod
12a283d513
m[ft] No need to use atomic ops for cached_x_scale
...
We have added a mutex since, so no need for atomicity.
2021-02-22 12:51:09 -07:00
Khaled Hosny
9936490c04
[docs] Invalid use of "optional" annotation
...
It is valid only for out and inout parameters.
Fixes https://github.com/harfbuzz/harfbuzz/issues/1787
2020-12-30 19:21:49 -08:00
Khaled Hosny
a31a51cdec
[docs] Complete hb-ft docs a bit
2020-12-30 19:21:49 -08:00
Khaled Hosny
c7b2e64c6d
[docs] make it clear that FT_Face must have size
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/2590
2020-12-30 11:50:49 -08:00
Khaled Hosny
22468c8a90
[docs] Give destroy callbacks have (optional) annotation
2020-12-24 22:38:06 +02:00
Behdad Esfahbod
26b9670d99
[ft] Better handle allocation failures
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/2513
2020-06-28 14:52:15 -07:00
Sebastian Rasmussen
2267da4ee0
[ft] Do not deference ft_font if it is nullptr ( #2502 )
2020-06-27 20:18:16 -07:00
Sebastian Rasmussen
dbf9896e7a
[ft] Handle nullptr when destroying freetype font ( #2494 )
2020-06-27 19:57:34 -07:00
Behdad Esfahbod
a11db0b9d4
Merge branch 'master' into usermanual-integration
2020-04-23 15:32:43 -07:00
Ebrahim Byagowi
f9bc373381
2.6.5
2020-04-17 23:49:56 +04:30
n8willis
b57b904242
Add detail to hb_ft_font_create inline comments
...
Providing lengthier explanation for how the destroy function works on the hb_font_t but that destroying the FT_Face (and not destroying it too early) remains the client's responsibility.
2020-04-15 18:46:31 +01:00
n8willis
1bca2be256
Rewrite hb_ft_font_set_funcs inline explanation
2020-04-15 18:30:47 +01:00
n8willis
80c01d7687
Update hb-ft.cc
2020-04-15 18:08:55 +01:00
n8willis
9b91669cb4
Update hb-ft.cc
2020-04-13 16:40:15 +01:00
Behdad Esfahbod
d5338ba189
[ft] Add locking FT_Face API
...
Now that we mutex our internal FT_Face, share it with clients.
New API:
- hb_ft_font_lock_face()
- hb_ft_font_unlock_face()
2019-11-22 16:22:27 -05:00
Behdad Esfahbod
e4a101ed38
[ft] Fix for HB_NO_VAR build
2019-11-19 20:04:00 -05:00
Ebrahim Byagowi
bb41b74fd1
Don't rely on undefined left shift of negative value behavior
...
Fixes this -fno-sanitize-recover=undefined check,
hb-ft.cc:869:27: runtime error: left shift of negative value -16384
#0 0x7ff8f47da843 in hb_ft_font_set_funcs /home/ebrahim/Desktop/harfbuzz/src/hb-ft.cc:869:27
#1 0x55f20a66c7d6 in font_options_t::get_font() const /home/ebrahim/Desktop/harfbuzz/util/options.cc:731:3
#2 0x55f20a668c1f in shape_consumer_t<output_buffer_t>::init(hb_buffer_t*, font_options_t const*) /home/ebrahim/Desktop/harfbuzz/util/./shape-consumer.hh:47:42
#3 0x55f20a668441 in main_font_text_t<shape_consumer_t<output_buffer_t>, 2147483647, 0>::main(int, char**) /home/ebrahim/Desktop/harfbuzz/util/./main-font-text.hh:75:14
#4 0x55f20a667f91 in main /home/ebrahim/Desktop/harfbuzz/util/hb-shape.cc:180:21
#5 0x7ff8f3df7ee2 in __libc_start_main (/usr/lib/libc.so.6+0x26ee2)
#6 0x55f20a6427ad in _start (/home/ebrahim/Desktop/harfbuzz/util/.libs/lt-hb-shape+0xd7ad)
2019-09-18 23:16:52 +04:30
Khaled Hosny
0954c8f7a0
[ft] Prefer symbol cmap subtable if found ( #1948 )
...
Similar to commit d304d60e4d
for ot-font.
2019-09-01 10:09:07 -05:00
Ebrahim Byagowi
a0b4ac4dce
Turn 8 spaces to tab across the project
...
According to the current code style of the project
2019-08-27 02:40:41 +04:30
Ebrahim Byagowi
9fea6b4dd4
[amalgam] Use it in cmake port and fix conflicts ( #1812 )
2019-07-05 18:46:41 +04:30
Behdad Esfahbod
aa3450cac1
[config] Don't compile disabled features
...
This makes it possible to include all .cc files into build, even if not
building CoreText, Uniscribe, etc.
This was mostly to help custom builders. But also means that we can
include all files in our own build system. Not sure if we should.
Definitely simplifies things, but slightly only.
2019-06-17 22:41:49 -07:00
Behdad Esfahbod
bfb5569d53
Disable non-OpenType kerning with hb-ft in HB_TINY
2019-06-17 14:06:04 -07:00
Behdad Esfahbod
896416bd4c
Partially revert "[ft/ot] Remove implementation of deprecated kerning funcs"
...
This reverts commit 47030b1855
.
Reverts only the hb-ft part, to reinstate non-OpenType kerning with
FreeType.
Fixes https://github.com/harfbuzz/harfbuzz/issues/1682
2019-06-17 13:39:49 -07:00