Skip to content

Commit 7af51c1

Browse files
committed
Merge commit '43a778492219032b9d747112e412dec2201d2667'
2 parents 5786d2b + 43a7784 commit 7af51c1

File tree

210 files changed

+1628
-899
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

210 files changed

+1628
-899
lines changed

.ci/publish_release_artifact.sh

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,11 @@ fi
1111
if ! hash ghr 2> /dev/null; then
1212
_GHR_VER=v0.14.0
1313
_GHR=ghr_${_GHR_VER}_linux_amd64
14-
mkdir -p $HOME/.local/bin
1514
curl -sfL https://github.com/tcnksm/ghr/releases/download/$_GHR_VER/$_GHR.tar.gz |
16-
tar xz -C $HOME/.local/bin --strip-components=1 $_GHR/ghr
15+
tar xz -C . --strip-components=1 $_GHR/ghr
1716
fi
1817

19-
ghr -replace \
18+
./ghr -replace \
2019
-u $CIRCLE_PROJECT_USERNAME \
2120
-r $CIRCLE_PROJECT_REPONAME \
2221
$CIRCLE_TAG \

.ci/requirements.txt

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -60,28 +60,28 @@ meson==1.7.0 \
6060
--hash=sha256:08efbe84803eed07f863b05092d653a9d348f7038761d900412fddf56deb0284 \
6161
--hash=sha256:ae3f12953045f3c7c60e27f2af1ad862f14dee125b4ed9bcb8a842a5080dbf85
6262
# via -r requirements.in
63-
ninja==1.11.1.3 \
64-
--hash=sha256:04d48d14ea7ba11951c156599ab526bdda575450797ff57c6fdf99b2554d09c7 \
65-
--hash=sha256:114ed5c61c8474df6a69ab89097a20749b769e2c219a452cb2fadc49b0d581b0 \
66-
--hash=sha256:17978ad611d8ead578d83637f5ae80c2261b033db0b493a7ce94f88623f29e1b \
67-
--hash=sha256:1ad2112c2b0159ed7c4ae3731595191b1546ba62316fc40808edecd0306fefa3 \
68-
--hash=sha256:2883ea46b3c5079074f56820f9989c6261fcc6fd873d914ee49010ecf283c3b2 \
69-
--hash=sha256:28aea3c1c280cba95b8608d50797169f3a34280e3e9a6379b6e340f0c9eaeeb0 \
70-
--hash=sha256:2b4879ea3f1169f3d855182c57dcc84d1b5048628c8b7be0d702b81882a37237 \
71-
--hash=sha256:53409151da081f3c198bb0bfc220a7f4e821e022c5b7d29719adda892ddb31bb \
72-
--hash=sha256:56ada5d33b8741d298836644042faddebc83ee669782d661e21563034beb5aba \
73-
--hash=sha256:7fa2247fce98f683bc712562d82b22b8a0a5c000738a13147ca2d1b68c122298 \
74-
--hash=sha256:8c4bdb9fd2d0c06501ae15abfd23407660e95659e384acd36e013b6dd7d8a8e4 \
75-
--hash=sha256:a27e78ca71316c8654965ee94b286a98c83877bfebe2607db96897bbfe458af0 \
76-
--hash=sha256:a38c6c6c8032bed68b70c3b065d944c35e9f903342875d3a3218c1607987077c \
77-
--hash=sha256:a4a3b71490557e18c010cbb26bd1ea9a0c32ee67e8f105e9731515b6e0af792e \
78-
--hash=sha256:b6966f83064a88a51693073eea3decd47e08c3965241e09578ef7aa3a7738329 \
79-
--hash=sha256:bc3ebc8b2e47716149f3541742b5cd8e0b08f51013b825c05baca3e34854370d \
80-
--hash=sha256:edfa0d2e9d7ead1635b03e40a32ad56cc8f56798b6e2e9848d8300b174897076
63+
ninja==1.11.1.4 \
64+
--hash=sha256:055f386fb550c2c9d6157e45e20a84d29c47968876b9c5794ae2aec46f952306 \
65+
--hash=sha256:096487995473320de7f65d622c3f1d16c3ad174797602218ca8c967f51ec38a0 \
66+
--hash=sha256:2ab67a41c90bea5ec4b795bab084bc0b3b3bb69d3cd21ca0294fc0fc15a111eb \
67+
--hash=sha256:4617b3c12ff64b611a7d93fd9e378275512bb36eff8babff7c83f5116b4f8d66 \
68+
--hash=sha256:5713cf50c5be50084a8693308a63ecf9e55c3132a78a41ab1363a28b6caaaee1 \
69+
--hash=sha256:6aa39f6e894e0452e5b297327db00019383ae55d5d9c57c73b04f13bf79d438a \
70+
--hash=sha256:9c29bb66d2aa46a2409ab369ea804c730faec7652e8c22c1e428cc09216543e5 \
71+
--hash=sha256:b33923c8da88e8da20b6053e38deb433f53656441614207e01d283ad02c5e8e7 \
72+
--hash=sha256:c3b96bd875f3ef1db782470e9e41d7508905a0986571f219d20ffed238befa15 \
73+
--hash=sha256:cede0af00b58e27b31f2482ba83292a8e9171cdb9acc2c867a3b6e40b3353e43 \
74+
--hash=sha256:cf4453679d15babc04ba023d68d091bb613091b67101c88f85d2171c6621c6eb \
75+
--hash=sha256:cf554e73f72c04deb04d0cf51f5fdb1903d9c9ca3d2344249c8ce3bd616ebc02 \
76+
--hash=sha256:cfdd09776436a1ff3c4a2558d3fc50a689fb9d7f1bdbc3e6f7b8c2991341ddb3 \
77+
--hash=sha256:d3090d4488fadf6047d0d7a1db0c9643a8d391f0d94729554dbb89b5bdc769d7 \
78+
--hash=sha256:d4a6f159b08b0ac4aca5ee1572e3e402f969139e71d85d37c0e2872129098749 \
79+
--hash=sha256:ecce44a00325a93631792974659cf253a815cc6da4ec96f89742925dfc295a0d \
80+
--hash=sha256:f6186d7607bb090c3be1e10c8a56b690be238f953616626f5032238c66e56867
8181
# via -r requirements.in
8282

8383
# The following packages are considered to be unsafe in a requirements file:
84-
setuptools==76.0.0 \
85-
--hash=sha256:199466a166ff664970d0ee145839f5582cb9bca7a0a3a2e795b6a9cb2308e9c6 \
86-
--hash=sha256:43b4ee60e10b0d0ee98ad11918e114c70701bc6051662a9a675a0496c1a158f4
84+
setuptools==78.1.0 \
85+
--hash=sha256:18fd474d4a82a5f83dac888df697af65afa82dec7323d09c3e37d1f14288da54 \
86+
--hash=sha256:3e386e96793c8702ae83d17b853fb93d3e09ef82ec62722e61da5cd22376dcd8
8787
# via -r requirements.in

.circleci/config.yml

Lines changed: 7 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ jobs:
3737
- run: meson dist --no-tests -Cbuild
3838
- persist_to_workspace:
3939
root: .
40-
paths: build/meson-dist/harfbuzz-*.tar.xz
40+
paths: [build/meson-dist/harfbuzz-*.tar.xz]
4141

4242
publish-dist:
4343
executor: dist-executor
@@ -58,21 +58,6 @@ jobs:
5858
- run: meson compile -Cbuild -j9
5959
- run: RUN_VALGRIND=1 meson test -Cbuild -t 10 --no-suite=slow --wrap='valgrind --leak-check=full --error-exitcode=1' --print-errorlogs --num-processes=$(($(nproc)/2 + 1))
6060

61-
minsize:
62-
docker:
63-
- image: ubuntu
64-
steps:
65-
- checkout
66-
- run: apt update
67-
- run: DEBIAN_FRONTEND=noninteractive apt install -y ninja-build binutils gcc g++ pkg-config ragel libfreetype6-dev libglib2.0-dev libcairo2-dev python3 python3-pip python3-venv
68-
- run: |
69-
python3 -m venv venv
70-
source venv/bin/activate
71-
pip3 install meson==0.56.0
72-
meson setup build --buildtype=minsize
73-
meson compile -Cbuild
74-
meson test -Cbuild --print-errorlogs
75-
7661
asan-ubsan:
7762
docker:
7863
- image: ubuntu
@@ -141,7 +126,7 @@ jobs:
141126
source venv/bin/activate
142127
pip3 install meson==1.6.0
143128
bash .ci/build-win.sh 32
144-
meson devenv -Cbuild-win32 meson test --print-errorlogs --suite=harfbuzz
129+
meson devenv -Cbuild-win32 meson test -t 10 --print-errorlogs --suite=harfbuzz
145130
- store_artifacts:
146131
path: harfbuzz-win32.zip
147132
- persist_to_workspace:
@@ -154,6 +139,8 @@ jobs:
154139
- checkout
155140
- attach_workspace:
156141
at: .
142+
- run: apt update
143+
- run: DEBIAN_FRONTEND=noninteractive apt install -y curl
157144
- run: |
158145
mv harfbuzz-win32{,-$CIRCLE_TAG}.zip
159146
.ci/publish_release_artifact.sh harfbuzz-win32-$CIRCLE_TAG.zip
@@ -170,7 +157,7 @@ jobs:
170157
source venv/bin/activate
171158
pip3 install meson==1.6.0
172159
bash .ci/build-win.sh 64
173-
meson devenv -Cbuild-win64 meson test --print-errorlogs --suite=harfbuzz
160+
meson devenv -Cbuild-win64 meson test -t 10 --print-errorlogs --suite=harfbuzz
174161
- store_artifacts:
175162
path: harfbuzz-win64.zip
176163
- persist_to_workspace:
@@ -183,6 +170,8 @@ jobs:
183170
- checkout
184171
- attach_workspace:
185172
at: .
173+
- run: apt update
174+
- run: DEBIAN_FRONTEND=noninteractive apt install -y curl
186175
- run: |
187176
mv harfbuzz-win64{,-$CIRCLE_TAG}.zip
188177
.ci/publish_release_artifact.sh harfbuzz-win64-$CIRCLE_TAG.zip
@@ -207,7 +196,6 @@ workflows:
207196
branches:
208197
ignore: /.*/
209198
- fedora-valgrind
210-
- minsize
211199
- asan-ubsan
212200
- tsan
213201
- msan

NEWS

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,34 @@
1+
Overview of changes leading to 11.0.0
2+
Friday, April 4, 2025
3+
====================================
4+
- The change in version 10.3.0 to apply “trak” table tracking values to glyph
5+
advances directly has been reverted as it required every font functions
6+
implementation to handle it, which breaks existing custom font functions.
7+
Tracking is instead back to being applied during shaping.
8+
- When `directwrite` integration is enabled, we now link to `dwrite.dll`
9+
instead of dynamically loading it.
10+
- A new experimental APIs for getting raw “CFF” and “CFF2” CharStrings.
11+
- We now provide manpages for the various command line utilities. Building
12+
manpages requires “help2man” and will be skipped if it is not present.
13+
- The command line utilities now set different return value for different kinds
14+
of failures. Details are provided in the manpages.
15+
- Various fixes and improvements to `fontations` font functions.
16+
- All shaping operations using the `ot` shaper have become memory
17+
allocation-free.
18+
- Glyph extents returned by `hb-ot` and `hb-ft` font functions are now rounded
19+
in stead of flooring/ceiling them, which also matches what other font
20+
libraries do.
21+
- Fix “AAT” deleted glyph marks interfering with fallback mark positioning.
22+
- Glyph outlines emboldening have been moved out of `hb-ot` and `hb-ft` font
23+
functions to the HarfBuzz font layer, so that it works with any font
24+
functions implementation.
25+
- Fix our fallback C++11 atomics integration, which seems to not be widely
26+
used.
27+
- Various testing fixes and improvements.
28+
- Various subsetting fixes and improvements.
29+
- Various other fixes and improvements.
30+
31+
132
Overview of changes leading to 11.0.0
233
Monday, March 24, 2025
334
====================================

README.md

Lines changed: 37 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,20 @@ will also find Win32/Win64 binary bundles that include `libharfbuzz` DLL,
3535
`hb-view.exe`, `hb-shape.exe`, and all dependencies.
3636

3737
The canonical source tree is available on [github][4].
38+
Both development and user support discussion around HarfBuzz happens on
39+
[github][4] as well.
3840

3941
The API that comes with `hb.h` will not change incompatibly. Other, peripheral,
4042
headers are more likely to go through minor modifications, but again, we do our
4143
best to never change API in an incompatible way. We will never break the ABI.
4244

43-
If you are not sure whether Pango or HarfBuzz is right for you, read [Pango vs
44-
HarfBuzz][5].
45+
The API and ABI are stable even across major version number jumps. In fact,
46+
current HarfBuzz is API/ABI compatible all the way back to the 0.9.x series.
47+
If one day we need to break the API/ABI, that would be called a new a library.
48+
49+
As such, we bump the major version number only when we add major new features,
50+
the minor version when there is new API, and the micro version when there
51+
are bug fixes.
4552

4653
## Development
4754

@@ -51,26 +58,34 @@ For custom configurations, see [CONFIG.md](CONFIG.md).
5158

5259
For testing and profiling, see [TESTING.md](TESTING.md).
5360

61+
For using with Python, see [README.python.md](README.python.md). There is also [uharfbuzz](https://github.com/harfbuzz/uharfbuzz).
62+
5463
For cross-compiling to Windows from Linux or macOS, see [README.mingw.md](README.mingw.md).
5564

65+
To report bugs or submit patches please use [github][4] issues and pull-requests.
66+
67+
### Developer documents
68+
5669
To get a better idea of where HarfBuzz stands in the text rendering stack you
5770
may want to read [State of Text Rendering 2024][6].
5871
Here are a few presentation slides about HarfBuzz at the
5972
Internationalization and Unicode Conference over the years:
6073

61-
* November 2014, [Unicode, OpenType, and HarfBuzz: Closing the Circle][7],
62-
* October 2012, [HarfBuzz, The Free and Open Text Shaping Engine][8],
63-
* October 2009, [HarfBuzz: the Free and Open Shaping Engine][9].
64-
65-
Both development and user support discussion around HarfBuzz happens on the
66-
[github][4].
74+
- November 2014, [Unicode, OpenType, and HarfBuzz: Closing the Circle][7],
75+
- October 2012, [HarfBuzz, The Free and Open Text Shaping Engine][8],
76+
- October 2009, [HarfBuzz: the Free and Open Shaping Engine][9].
6777

68-
To report bugs or submit patches please use [github][4] issues and
69-
pull-requests.
78+
More presentations and papers are available on [behdad][11]'s website.
79+
In particular, the following documents are relevant to HarfBuzz development:
7080

71-
For a comparison of old vs new HarfBuzz memory consumption see [this][10].
81+
- 2025 — HarfBuzz Study: Caching — [Paper][12]
82+
- 2025 — HarfBuzz Study: `hb-decycler`[Paper][13]
83+
- 2022 — HarfBuzz Study: `hb-iter`[Paper][14]
84+
- 2022 — HarfBuzz Study: A C library written in C++ — [Paper][15]
85+
- 2022 — HarfBuzz Study: PackTab: A static integer table packer — [Paper][16]
86+
- 2014 — Reflections on Building the HarfBuzz Indic Shaper — [Paper][17]
87+
- 2012 — HarfBuzz Memory Consumption — [Paper][10]
7288

73-
<!--See past and upcoming [HarfBuzz Hackfests](https://freedesktop.org/wiki/Software/HarfBuzz/Hackfests/)!-->
7489

7590
## Name
7691

@@ -98,9 +113,15 @@ transliterated using the Latin script. It also means "talkative" or
98113
[2]: https://developer.apple.com/fonts/TrueType-Reference-Manual/RM06/Chap6AATIntro.html
99114
[3]: https://github.com/harfbuzz/harfbuzz/releases
100115
[4]: https://github.com/harfbuzz/harfbuzz
101-
[5]: http://mces.blogspot.com/2009/11/pango-vs-harfbuzz.html
102116
[6]: http://behdad.org/text2024
103-
[7]: https://goo.gl/FSIQuC
104-
[8]: https://goo.gl/2wSRu
117+
[7]: https://docs.google.com/presentation/d/1x97pfbB1gbD53Yhz6-_yBUozQMVJ_5yMqqR_D-R7b7I/preview
118+
[8]: https://docs.google.com/presentation/d/1ySTZaXP5XKFg0OpmHZM00v5b17GSr3ojnzJekl4U8qI/preview
105119
[9]: http://behdad.org/download/Presentations/slippy/harfbuzz_slides.pdf
106-
[10]: https://goo.gl/woyty
120+
[10]: https://docs.google.com/document/d/12jfNpQJzeVIAxoUSpk7KziyINAa1msbGliyXqguS86M/preview
121+
[11]: https://behdad.org/
122+
[12]: https://docs.google.com/document/d/1_VgObf6Je0J8byMLsi7HCQHnKo2emGnx_ib_sHo-bt4/preview
123+
[13]: https://docs.google.com/document/d/1Y-u08l9YhObRVObETZt1k8f_5lQdOix9TRH3zEXaoAw/preview
124+
[14]: https://docs.google.com/document/d/1o-xvxCbgMe9JYFHLVnPjk01ZY_8Cj0vB9-KTI1d0nyk/preview
125+
[15]: https://docs.google.com/document/d/18hI56KJpvXtwWbc9QSaz9zzhJwIMnrJ-zkAaKS-W-8k/preview
126+
[16]: https://docs.google.com/document/d/1Xq3owVt61HVkJqbLFHl73il6pcTy6PdPJJ7bSouQiQw/preview
127+
[17]: https://docs.google.com/document/d/1wMPwVNBvsIriamcyBO5aNs7Cdr8lmbwLJ8GmZBAswF4/preview

README.mingw.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ a few different ways to build and test HarfBuzz for Windows.
3030
- Ubuntu, 64bit: `apt install wine wine64`.
3131
- Mac: `brew install wine-stable`.
3232

33+
Note that to run Wine on Apple silicon systems, you need the Apple Rosetta translator.
34+
Follow the instructions you got from brew. This should do it:
35+
36+
- `softwareupdate --install-rosetta --agree-to-license`
37+
3338
2. Install the `mingw-w64` cross-compiler.
3439

3540
- Fedora, 32bit: `dnf install mingw32-gcc-c++`
@@ -41,7 +46,7 @@ a few different ways to build and test HarfBuzz for Windows.
4146
3. Install dependencies.
4247

4348
First, make sure you do not have the mingw32 harfbuzz package, as that will
44-
override our own build:
49+
override our own build with older `meson`:
4550

4651
- Fedora, 32bit: `dnf remove mingw32-harfbuzz`
4752
- Fedora, 64bit: `dnf remove mingw64-harfbuzz`

RELEASING.md

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,17 @@
33
- [ ] Open gitk and review changes since last release.
44

55
- [ ] Print all public API changes:
6-
`git diff $(git describe | sed 's/-.*//').. src/*.h`
6+
`git diff $(git describe | sed 's/-.*//').. src/*.h`
77

88
- [ ] Document them in NEWS.
9-
All API and API semantic changes should be clearly marked as API additions, API changes, or API deletions.
9+
All API and API semantic changes should be clearly marked as API additions, API changes, or API deletions.
1010

1111
- [ ] Document deprecations.
12-
Ensure all new API / deprecations are in listed correctly in docs/harfbuzz-sections.txt.
13-
If release added new API, add entry for new API index at the end of docs/harfbuzz-docs.xml.
12+
Ensure all new API / deprecations are listed correctly in docs/harfbuzz-sections.txt.
13+
If release added new API, add entry for new API index at the end of docs/harfbuzz-docs.xml.
1414

15-
If there's a backward-incompatible API change (including deletions for API used anywhere), that's a release blocker.
16-
Do NOT release.
15+
If there's a backward-incompatible API change (including deletions for API used anywhere), that's a release blocker.
16+
Do NOT release.
1717

1818
- [ ] Based on severity of changes, decide whether it's a minor or micro release number bump.
1919

@@ -26,12 +26,16 @@
2626
- [ ] Do a `meson test -Cbuild` so it both checks the tests and updates hb-version.h (use `git diff` to see if is really updated).
2727

2828
- [ ] Commit NEWS, meson.build, and src/hb-version.h, as well as any REPLACEME changes you made.
29-
The commit message is simply the release number, e. g. "1.4.7"
29+
The commit message is simply the release number, e. g. "1.4.7"
3030

3131
- [ ] Do a `meson dist -Cbuild` that runs the tests against the latest committed changes.
32-
If doesn't pass, something fishy is going on, reset the repo and start over.
32+
If it does not pass, something fishy is going on, reset the repo and start over.
3333

3434
- [ ] Tag the release and sign it: e.g. `git tag -s 1.4.7 -m 1.4.7`.
3535
Enter your GPG password.
3636

3737
- [ ] Push the commit and tag out: `git push --follow-tags`.
38+
39+
- [ ] There should be a GitHub release automatically created.
40+
When it does, go to that release page and add description.
41+
The description should be the NEWS file additions.

docs/harfbuzz-sections.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -955,6 +955,10 @@ hb_subset_serialize_object_t
955955
hb_subset_serialize_or_fail
956956
<SUBSECTION Private>
957957
hb_subset_input_override_name_table
958+
hb_subset_cff_get_charstring_data
959+
hb_subset_cff_get_charstrings_index
960+
hb_subset_cff2_get_charstring_data
961+
hb_subset_cff2_get_charstrings_index
958962
</SECTION>
959963

960964
<SECTION>

meson.build

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
project('harfbuzz', ['c', 'cpp'],
22
meson_version: '>= 0.55.0',
3-
version: '11.0.0',
3+
version: '11.0.1',
44
default_options: [
55
'cpp_eh=none', # Just to support msvc, we are passing -fno-exceptions also anyway
66
# 'cpp_rtti=false', # Do NOT enable, wraps inherit it and ICU needs RTTI
@@ -332,12 +332,16 @@ if host_machine.system() == 'windows' and not get_option('gdi').disabled()
332332
endif
333333
endif
334334

335+
directwrite_dep = []
335336
# DirectWrite (Windows)
336337
if host_machine.system() == 'windows' and not get_option('directwrite').disabled()
337338
if get_option('directwrite').enabled() and not cpp.has_header('dwrite_3.h')
338339
error('DirectWrite was enabled explicitly, but required header is missing.')
339340
endif
340-
conf.set('HAVE_DIRECTWRITE', 1)
341+
directwrite_dep = cpp.find_library('dwrite', required: get_option('directwrite'))
342+
if directwrite_dep.found()
343+
conf.set('HAVE_DIRECTWRITE', 1)
344+
endif
341345
endif
342346

343347
# CoreText (macOS)

src/OT/Layout/Common/CoverageFormat1.hh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ struct CoverageFormat1_3
7777

7878
bool intersects (const hb_set_t *glyphs) const
7979
{
80-
if (glyphArray.len > glyphs->get_population () * hb_bit_storage ((unsigned) glyphArray.len) / 2)
80+
if (glyphArray.len > glyphs->get_population () * hb_bit_storage ((unsigned) glyphArray.len))
8181
{
8282
for (auto g : *glyphs)
8383
if (get_coverage (g) != NOT_COVERED)

0 commit comments

Comments
 (0)