src/hb-ft.cc


Log

Author Commit Date CI Message
Behdad Esfahbod afae537c 2023-06-29T12:42:44 [cache] Minor remove .init() Use constructor.
Behdad Esfahbod 62fc27f3 2023-02-27T11:20:47 [ft] Enlarge glyph-cache value-size again 8bits just doesn't do it. It has caused cache-hammering and high CPU usage when the font is hinted. Fixes https://github.com/harfbuzz/harfbuzz/issues/4139
Behdad Esfahbod be1c14ee 2023-02-07T13:52:53 [embolden] Adjust font_h_extents
Behdad Esfahbod b350122f 2023-02-07T13:49:16 [embolden] Fix glyph_extents in hb-ft
Behdad Esfahbod 61a1a889 2023-02-07T13:47:04 [hb-ft] Fix --font-grade
Behdad Esfahbod aef002e0 2023-02-07T11:29:49 [embolden] Add in-place option Adds --font-grade to hb-view and hb-shape.
Behdad Esfahbod 2119eab6 2023-02-01T17:37:10 [embolden] Adjust advance values
Behdad Esfahbod e39104ba 2023-02-01T16:56:56 [font/util] Add emboldening API, --font-bold Needs documentation.
Behdad Esfahbod 70149885 2023-02-01T14:27:45 [font] Towards implementing emboldening
Behdad Esfahbod 277003d5 2023-01-30T22:43:01 [ft] Fit advance cache into short int
Behdad Esfahbod 1b53ed3c 2023-01-28T13:22:52 [cache] Remove empty fini()
Behdad Esfahbod e3778889 2023-01-26T13:26:47 [ft-colr] Conditionalize on (unreleased0 FreeType 2.13.0 That's the version that the color API is called stable, and includes changes that we rely on.
Behdad Esfahbod fecce62a 2023-01-10T13:13:43 [ft] Docs
Behdad Esfahbod 41484875 2023-01-09T13:47:59 [ft] Comment
Behdad Esfahbod d2aa2397 2023-01-09T13:43:56 Optimize non-slant extents code
Behdad Esfahbod 73dab7f7 2023-01-09T13:36:55 [ft] Fix slanting code
Behdad Esfahbod a5f1f3a0 2023-01-01T13:14:04 [ft] Conditionalize all COLOR code on >= 2.11.1 Fixes https://github.com/harfbuzz/harfbuzz/issues/3994
Matthias Clasen 67456a7a 2022-12-28T13:07:54 [ft] Some more docs clarifications
Matthias Clasen c612d068 2022-12-28T10:42:59 [ft] Clarify docs around faces too
Matthias Clasen 4dc955bb 2022-12-28T10:04:21 [ft] Clarify docs Add some clarifications on what fonts these apis work with.
Behdad Esfahbod ffa45f24 2022-12-25T17:14:45 [cairo] #ifdef HAVE_CAIRO
Behdad Esfahbod 79c5bb92 2022-12-24T12:57:33 [ft] Work around a freetype bug
Behdad Esfahbod 62bd26dd 2022-12-24T11:01:32 [ft] Pick largest bitmap size
Behdad Esfahbod f70c5d6f 2022-12-24T10:56:06 [paint] Continue returning bool from paint_image() https://github.com/harfbuzz/harfbuzz/commit/6ccbfabd4fcc5d4cca99be10552c270205fd7792#commitcomment-94127307
Behdad Esfahbod 346331d3 2022-12-24T10:35:26 [ft] Fix negative xscale
Behdad Esfahbod 9376e7a9 2022-12-24T10:31:30 [ft] Remove stale TODO
Behdad Esfahbod a7fd48c4 2022-12-24T10:28:41 [ft] Comment
Behdad Esfahbod bb45ba2f 2022-12-24T10:25:43 [ft] Fix negative y-scale
Behdad Esfahbod 583f010b 2022-12-23T12:10:22 [ft] Move lock only around clip_glyph
Behdad Esfahbod e2546f5a 2022-12-22T15:50:43 [ft] Add hb-ft-colr.hh
Behdad Esfahbod 381d410b 2022-12-22T13:21:48 [paint] Add HB_PAINT_IMAGE_FORMAT_BGRA and use it in hb-ft Now hb-ft can render color emoji as well. Just left COLRv2.
Behdad Esfahbod 72a169c8 2022-12-22T11:26:10 [ft] Paint COLRv0 glyphs
Behdad Esfahbod bb807f47 2022-12-22T10:51:26 [ft] Implement paint_glyph() for outline glyphs
Behdad Esfahbod 91c88050 2022-12-22T10:42:27 [ft] Use new name for draw API
Behdad Esfahbod d628aff9 2022-12-22T10:53:24 [ft] Apply slant in get_glyph_extents
Behdad Esfahbod a10ff205 2022-11-16T13:34:37 [ft] Comment
Martin Storsjö d88269c8 2022-10-28T22:17:15 freetype: Fix function signatures to match without casts Clang 16 has got a new stricter warning for casts of function types (see https://github.com/llvm/llvm-project/commit/1aad641c793090b4d036c03e737df2ebe2c32c57). This new warning gets included as part of the existing error diagnostic setting of -Wcast-function-type. This fixes errors like these: ../src/hb-ft.cc:1011:34: error: cast from 'void (*)(FT_Face)' (aka 'void (*)(FT_FaceRec_ *)') to 'FT_Generic_Finalizer' (aka 'void (*)(void *)') converts to incompatible function type [-Werror,-Wcast-function-type-strict] ft_face->generic.finalizer = (FT_Generic_Finalizer) hb_ft_face_finalize; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Behdad Esfahbod 23461b75 2022-08-19T09:48:12 [hb-ft] Only apply FT_Face's transform if we created FT_Face Fixes https://github.com/harfbuzz/harfbuzz/issues/3788 https://github.com/harfbuzz/harfbuzz/issues/3790
Behdad Esfahbod d7adc55e 2022-08-03T13:22:51 [ot-font] Allow 24bit glyphs in advance cache
Behdad Esfahbod ec90d1e1 2022-08-03T13:00:48 [cache] Add a non-threadsafe version Use in hb-ft, since already mutex'ed.
Behdad Esfahbod e387b3ac 2022-08-02T09:46:23 [ft] Try harder
Khaled Hosny 40a34689 2022-08-02T16:09:27 hb-ft: cast to float to help windows sqrtf
Behdad Esfahbod ba9b2053 2022-08-01T12:42:05 [ft] Try working around fonts with transform set Fixes https://github.com/harfbuzz/harfbuzz/issues/3772
Behdad Esfahbod 1ac21246 2022-07-25T08:40:02 [hb-ft] Fix bitmap font rendering with hb_ft_font_changed() Fixes https://github.com/harfbuzz/harfbuzz/issues/3754 Fixes https://github.com/harfbuzz/harfbuzz/issues/3755
Behdad Esfahbod 61d0c547 2022-07-23T13:25:54 [ft] Pass design, not normalized, coords to freetype Needed for avar2 to work.
Behdad Esfahbod cb5ca6be 2022-07-22T05:48:27 [ft] Actually call check_changed() from _changed() Ouch! Fixes https://github.com/harfbuzz/harfbuzz/issues/3746
Behdad Esfahbod fd535a24 2022-07-22T05:48:12 [ft] Remove check_changed from get_glyph_shape() Leftover.
Behdad Esfahbod 4f22397f 2022-07-18T11:03:54 [ft] A couple of introspection fixes
Behdad Esfahbod 6ed57de1 2022-07-15T15:09:28 [ft] Fix negative font sizes for bitmaps
Behdad Esfahbod 307ee9ba 2022-07-15T14:48:29 [ft] Fix bitmap-only vertical metrics
Behdad Esfahbod 87d338eb 2022-07-15T14:19:17 [ft] Fix test
Khaled Hosny e294200d 2022-07-15T21:36:50 [ft] Check for FT_Get_Transform at build time
Behdad Esfahbod 901236f7 2022-07-15T12:55:31 [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.
Behdad Esfahbod 3ac11056 2022-07-15T12:48:11 [ft] Fix scale when font-sizes are negative
Khaled Hosny 98e90cc6 2022-06-30T08:43:57 [docs] Reduce warnings Use markdown syntax for inline code blocks instead of %true, %false, and %NULL.
Khaled Hosny 8537d681 2022-06-27T20:51:16 4.4.0
Behdad Esfahbod 8c27c51c 2022-06-19T10:47:38 [arabic-pua] Rename symbols
Behdad Esfahbod 76989629 2022-06-19T10:41:45 [arabic-fallback] Disable PUA shaping under HB_NO_OT_SHAPER_ARABIC_FALLBACK
Behdad Esfahbod 55350377 2022-06-19T10:13:31 [cmap/ft] Only map 0xF000 range if font_page is NONE
Khaled Hosny 189e8c32 2022-06-18T13:28:54 [ft] Remap legacy Arabic PUA codepoints Similar to what ot font finctions does, to support Support legacy pre-OpenType Windows 3.1-era fonts.
Behdad Esfahbod d6dbc0d1 2022-06-05T00:58:53 [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)
Behdad Esfahbod fc4d42ff 2022-06-01T05:19:23 [ft] Add API to notify that hb_font_t changed New API: - hb_ft_hb_font_changed() Mostly reverts 56e0ff9ea129aa91dfcc746cd61f8cbbc427dba7 Related https://github.com/harfbuzz/harfbuzz/issues/2270 Fixes https://github.com/harfbuzz/harfbuzz/issues/3619
Behdad Esfahbod 80c49933 2022-05-23T19:02:27 [hb-ft] Adjust serial signature
Behdad Esfahbod 56e0ff9e 2022-05-20T12:30:46 [ft] If hb_font changed, update FT_Face Fixes https://github.com/harfbuzz/harfbuzz/issues/2270 Rather untested.
Behdad Esfahbod 8629df18 2022-05-20T12:06:22 [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 :(.
Behdad Esfahbod 05e82aa1 2022-05-20T12:17:31 [ft] Add missing lock to kerning function
Behdad Esfahbod 55804e8d 2022-05-20T11:40:44 [hb-ft] Minor rearrange of struct members To make clear what members the lock protects.
Behdad Esfahbod 6d0e67de 2022-03-21T21:07:11 [ot-font] Only use vmtx side-bearing if table exists Part of fixing https://github.com/harfbuzz/harfbuzz/issues/537
Behdad Esfahbod 59067db9 2022-02-07T17:55:01 [font/draw] Slant drawings Need to update hb_font_set_synthetic_slant() docs now that we do this.
Behdad Esfahbod 6d5b998f 2022-02-04T18:44:38 [ft/draw] Implement hb-draw for hb-ft
Behdad Esfahbod 002a1f70 2021-12-08T10:45:30 [ft] Disable vertical funcs if HB_NO_VERTICAL
Behdad Esfahbod ed116320 2021-09-14T07:09:54 Call atexit() via hb_atexit() Part of https://github.com/harfbuzz/harfbuzz/issues/3197
Behdad Esfahbod 2337f0d0 2021-07-08T10:58:50 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
Behdad Esfahbod 12a283d5 2021-02-22T12:50:41 m[ft] No need to use atomic ops for cached_x_scale We have added a mutex since, so no need for atomicity.
Khaled Hosny 9936490c 2020-12-31T00:19:29 [docs] Invalid use of "optional" annotation It is valid only for out and inout parameters. Fixes https://github.com/harfbuzz/harfbuzz/issues/1787
Khaled Hosny a31a51cd 2020-12-30T23:48:25 [docs] Complete hb-ft docs a bit
Khaled Hosny c7b2e64c 2020-12-27T00:53:23 [docs] make it clear that FT_Face must have size Fixes https://github.com/harfbuzz/harfbuzz/issues/2590
Khaled Hosny 22468c8a 2020-12-24T22:38:06 [docs] Give destroy callbacks have (optional) annotation
Behdad Esfahbod 26b9670d 2020-06-28T14:52:15 [ft] Better handle allocation failures Fixes https://github.com/harfbuzz/harfbuzz/issues/2513
Sebastian Rasmussen 2267da4e 2020-06-28T11:18:16 [ft] Do not deference ft_font if it is nullptr (#2502)
Sebastian Rasmussen dbf9896e 2020-06-28T10:57:34 [ft] Handle nullptr when destroying freetype font (#2494)
Behdad Esfahbod a11db0b9 2020-04-23T15:32:43 Merge branch 'master' into usermanual-integration
Ebrahim Byagowi f9bc3733 2020-04-17T22:37:48 2.6.5
n8willis b57b9042 2020-04-15T18:46:31 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.
n8willis 1bca2be2 2020-04-15T18:30:47 Rewrite hb_ft_font_set_funcs inline explanation
n8willis 80c01d76 2020-04-15T18:08:55 Update hb-ft.cc
n8willis 9b91669c 2020-04-13T16:40:15 Update hb-ft.cc
Behdad Esfahbod d5338ba1 2019-11-22T16:22:27 [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()
Behdad Esfahbod e4a101ed 2019-11-19T20:04:00 [ft] Fix for HB_NO_VAR build
Ebrahim Byagowi bb41b74f 2019-09-18T00:55:24 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)
Khaled Hosny 0954c8f7 2019-09-01T17:09:08 [ft] Prefer symbol cmap subtable if found (#1948) Similar to commit d304d60e4d49df14ed85d6646680085f27bafbf2 for ot-font.
Ebrahim Byagowi a0b4ac4d 2019-08-24T17:57:14 Turn 8 spaces to tab across the project According to the current code style of the project
Ebrahim Byagowi 9fea6b4d 2019-07-05T18:46:41 [amalgam] Use it in cmake port and fix conflicts (#1812)
Behdad Esfahbod aa3450ca 2019-06-17T22:41:49 [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.
Behdad Esfahbod bfb5569d 2019-06-17T14:06:04 Disable non-OpenType kerning with hb-ft in HB_TINY
Behdad Esfahbod 896416bd 2019-06-17T13:39:49 Partially revert "[ft/ot] Remove implementation of deprecated kerning funcs" This reverts commit 47030b1855f04c0d75899ffb6f5021fea3c19b90. Reverts only the hb-ft part, to reinstate non-OpenType kerning with FreeType. Fixes https://github.com/harfbuzz/harfbuzz/issues/1682
Nathan Willis 9126a5ff 2019-05-20T17:37:56 [Docs] Add gtk-doc comments to hb-ft.
Behdad Esfahbod 41248cce 2019-05-07T20:54:31 Remove MIN/MAX in favor of hb_min/hb_max
Behdad Esfahbod 54ece299 2019-04-16T16:45:53 Use type aliasing for meta-functions, ie. those returning a type
Behdad Esfahbod b986c6a3 2019-03-29T20:17:46 [C++11] Remove IntType::set() in favor of operator=