Skip to main content

Streamlined Cython bindings for the harfbuzz shaping engine

Project description

Travis Build Status Appveyor Build status PyPI

uharfbuzz

Streamlined Cython bindings for the HarfBuzz shaping engine.

Example

import uharfbuzz as hb
import sys


with open(sys.argv[1], 'rb') as fontfile:
    fontdata = fontfile.read()

text = sys.argv[2]

face = hb.Face(fontdata)
font = hb.Font(face)
upem = face.upem

font.scale = (upem, upem)
hb.ot_font_set_funcs(font)

buf = hb.Buffer()

buf.add_str(text)
buf.guess_segment_properties()

features = {"kern": True, "liga": True}
hb.shape(font, buf, features)

infos = buf.glyph_infos
positions = buf.glyph_positions

for info, pos in zip(infos, positions):
    gid = info.codepoint
    cluster = info.cluster
    x_advance = pos.x_advance
    x_offset = pos.x_offset
    y_offset = pos.y_offset
    print(f"gid{gid}={cluster}@{x_advance},{x_offset}+{y_offset}")

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

uharfbuzz-0.11.0.zip (29.4 kB view details)

Uploaded Source

Built Distributions

uharfbuzz-0.11.0-cp38-cp38-win_amd64.whl (311.4 kB view details)

Uploaded CPython 3.8 Windows x86-64

uharfbuzz-0.11.0-cp38-cp38-win32.whl (271.5 kB view details)

Uploaded CPython 3.8 Windows x86

uharfbuzz-0.11.0-cp38-cp38-manylinux2010_x86_64.whl (488.6 kB view details)

Uploaded CPython 3.8 manylinux: glibc 2.12+ x86-64

uharfbuzz-0.11.0-cp38-cp38-manylinux1_x86_64.whl (488.6 kB view details)

Uploaded CPython 3.8

uharfbuzz-0.11.0-cp38-cp38-macosx_10_9_x86_64.whl (476.6 kB view details)

Uploaded CPython 3.8 macOS 10.9+ x86-64

uharfbuzz-0.11.0-cp37-cp37m-win_amd64.whl (310.9 kB view details)

Uploaded CPython 3.7m Windows x86-64

uharfbuzz-0.11.0-cp37-cp37m-win32.whl (270.1 kB view details)

Uploaded CPython 3.7m Windows x86

uharfbuzz-0.11.0-cp37-cp37m-manylinux2010_x86_64.whl (486.9 kB view details)

Uploaded CPython 3.7m manylinux: glibc 2.12+ x86-64

uharfbuzz-0.11.0-cp37-cp37m-manylinux1_x86_64.whl (486.9 kB view details)

Uploaded CPython 3.7m

uharfbuzz-0.11.0-cp37-cp37m-macosx_10_9_x86_64.whl (475.9 kB view details)

Uploaded CPython 3.7m macOS 10.9+ x86-64

uharfbuzz-0.11.0-cp36-cp36m-win_amd64.whl (310.8 kB view details)

Uploaded CPython 3.6m Windows x86-64

uharfbuzz-0.11.0-cp36-cp36m-win32.whl (270.0 kB view details)

Uploaded CPython 3.6m Windows x86

uharfbuzz-0.11.0-cp36-cp36m-manylinux2010_x86_64.whl (487.4 kB view details)

Uploaded CPython 3.6m manylinux: glibc 2.12+ x86-64

uharfbuzz-0.11.0-cp36-cp36m-manylinux1_x86_64.whl (487.3 kB view details)

Uploaded CPython 3.6m

uharfbuzz-0.11.0-cp36-cp36m-macosx_10_9_x86_64.whl (476.5 kB view details)

Uploaded CPython 3.6m macOS 10.9+ x86-64

File details

Details for the file uharfbuzz-0.11.0.zip.

File metadata

  • Download URL: uharfbuzz-0.11.0.zip
  • Upload date:
  • Size: 29.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/2.7.17

File hashes

Hashes for uharfbuzz-0.11.0.zip
Algorithm Hash digest
SHA256 c54a0f8dcda6a51c0ff75545cd9244418cede11c1e50c00a0289061288e7a27f
MD5 a9871e0878919ad37433e771a04e3f94
BLAKE2b-256 e2d0cd0025874bbbb029c84e6c2d67b92ed951a497f8e549863d49054c07d4b6

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 311.4 kB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.5

File hashes

Hashes for uharfbuzz-0.11.0-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 e84a58ec8cf3e68b89a7beaf8e82bbbd55b4bbb63ec43b6c12ae78e0322e9a5b
MD5 0cc59e584b48b414c5b47b5aa893c20f
BLAKE2b-256 c7c5dde8489c81b3b80fa2d6ddef00f0271739708c91c5cad82944700dc7d4df

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp38-cp38-win32.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp38-cp38-win32.whl
  • Upload date:
  • Size: 271.5 kB
  • Tags: CPython 3.8, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.5

File hashes

Hashes for uharfbuzz-0.11.0-cp38-cp38-win32.whl
Algorithm Hash digest
SHA256 3aeb062d7782a53e144658ffad30b65dfb764f6b95de3e48effca861fd59c720
MD5 5ea59edc6e8c518145b9c604bf9c8283
BLAKE2b-256 254d8cafa36cd94914aaa163a96ba4d546a551bcb9d25918172e30643948edc8

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp38-cp38-manylinux2010_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp38-cp38-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 488.6 kB
  • Tags: CPython 3.8, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

File hashes

Hashes for uharfbuzz-0.11.0-cp38-cp38-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 d11069ca6cf4d4ed6b8e9f3038313fa5834fdbeb49d58fd1274cd1426d2bd0ce
MD5 014903f6ee88cef11492d4c95900616c
BLAKE2b-256 f777b0528af06185c30655851546657419a6c5cd5c8daf06c53402715962d4f6

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp38-cp38-manylinux1_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp38-cp38-manylinux1_x86_64.whl
  • Upload date:
  • Size: 488.6 kB
  • Tags: CPython 3.8
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

File hashes

Hashes for uharfbuzz-0.11.0-cp38-cp38-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 1ae452b26d56edd3fc11af2f81a35b3881fdb131d3a1cfc094b74b3a9a817e35
MD5 2c5be2ec420e49c28df9399824d83838
BLAKE2b-256 843730ca095c7e13a31fb7148e970eaca9a2581a144823966247f7b16960fdeb

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp38-cp38-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 476.6 kB
  • Tags: CPython 3.8, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/2.7.17

File hashes

Hashes for uharfbuzz-0.11.0-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 7a221c880645729f780140493628bca96efc63c8671d907e22c57a24ceffb342
MD5 149ef9f14b3ce631abf339d6757d5683
BLAKE2b-256 c26485ab5abff678cc2852ef9ff4eced6218d6b9fdbadb673231ed06e6f3b370

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 310.9 kB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.5

File hashes

Hashes for uharfbuzz-0.11.0-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 229bde0a6886e2b9f4901d83024378e61df9b591f55bc54c0a95748dc65005c9
MD5 1c8bbbc85e735872806e52607667558c
BLAKE2b-256 1c5789d2f0bc5e948091ff8c0319a8a47422259819e97ba29415127dd58d5eb6

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp37-cp37m-win32.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp37-cp37m-win32.whl
  • Upload date:
  • Size: 270.1 kB
  • Tags: CPython 3.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.5

File hashes

Hashes for uharfbuzz-0.11.0-cp37-cp37m-win32.whl
Algorithm Hash digest
SHA256 da629ecf6c4c0e5bbc26968d2817b5f9abb42a507d757fb37e785bb04d13cf6c
MD5 174e87f719c2362f75a4661f743e133d
BLAKE2b-256 058e0c12562d558c68da322def6a3bbfb411cc404150598f7d380511fe516f3f

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp37-cp37m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp37-cp37m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 486.9 kB
  • Tags: CPython 3.7m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

File hashes

Hashes for uharfbuzz-0.11.0-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 747e2f9934a3af5d3cd3eaad31c76ba74a0ab5074cdfad4c7336be048fcd8e18
MD5 b86149acb78fff4ba468308851650726
BLAKE2b-256 026b6489f66e8d3ba63a9f4effd8ac076776b56b75ec7d29e3dfef932be15b32

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp37-cp37m-manylinux1_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp37-cp37m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 486.9 kB
  • Tags: CPython 3.7m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

File hashes

Hashes for uharfbuzz-0.11.0-cp37-cp37m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 6a7cc3e4b45bb10d708581dedd4f7061618c1466005d23c3065912cbfd0f0c8d
MD5 3addac7e9016af27aad5760fe79b6857
BLAKE2b-256 642b1c0a8365dbce999a5f8375b87c808eeb3348cdeacc9baa61595ec4b2d9bd

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp37-cp37m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp37-cp37m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 475.9 kB
  • Tags: CPython 3.7m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/2.7.17

File hashes

Hashes for uharfbuzz-0.11.0-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 dbfe4105f7b87c9b315485db0723703dce7a7a8226efedd57164a077c6504317
MD5 2e396c58bae8be0d344915b977fbec1f
BLAKE2b-256 babd7227fe2ad031ba48b44334ed1c929617ea4a20c61f0482dc21275a2186cf

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 310.8 kB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.5

File hashes

Hashes for uharfbuzz-0.11.0-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 2ec98b8ba349bbe2ce1ed2d05125d23dcdefb581f317198ca90557451fcd4767
MD5 3d44c64db37d93d6237747b49489627d
BLAKE2b-256 34633510345071a13a2524010fd6d660d4ebaaf905b1bf2ffeb1db608e70c45a

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp36-cp36m-win32.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp36-cp36m-win32.whl
  • Upload date:
  • Size: 270.0 kB
  • Tags: CPython 3.6m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.5

File hashes

Hashes for uharfbuzz-0.11.0-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 32bf51ce7a89ec9ec26867c9fd3dc72c5a6961a7c0513ec43f85c252776a3c8f
MD5 62a2ff3393eb86c8c19f652fef935d22
BLAKE2b-256 eb2f2421fc90bb7e1c7611fbe00008dc3ae1afb1cba89cc85e8d98b89c400fb4

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp36-cp36m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp36-cp36m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 487.4 kB
  • Tags: CPython 3.6m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

File hashes

Hashes for uharfbuzz-0.11.0-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 f08bdda3e07779927f05143e78747448ee5eba423fa4bb2dd02a34495d87ee5c
MD5 d7d637ba1c45ef78ed972b0bfaa85ca9
BLAKE2b-256 cf36d7d1596436462674dbdf7b74646808ff77daddfdfc1739c77b852e668e39

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp36-cp36m-manylinux1_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp36-cp36m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 487.3 kB
  • Tags: CPython 3.6m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.6.7

File hashes

Hashes for uharfbuzz-0.11.0-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 cdb2f5a602b62b3d28b668c3c96f1d565af71cce126c26c405cc18c68d6d1462
MD5 3075fba81f382acedc0101567b412ff5
BLAKE2b-256 589d3036a93692470c215803725f124c5f5ac343ec75dd83910fff69d1448c8f

See more details on using hashes here.

File details

Details for the file uharfbuzz-0.11.0-cp36-cp36m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: uharfbuzz-0.11.0-cp36-cp36m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 476.5 kB
  • Tags: CPython 3.6m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/2.7.17

File hashes

Hashes for uharfbuzz-0.11.0-cp36-cp36m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 1c7c59d1aad13057e6cda1805d07cb1f67c4d89d7f171c8fe9a8c5ea2ad0da6f
MD5 be6626c2b1c141e689ce2ba81a372480
BLAKE2b-256 981534fce8e6d1dc0aab2c82eba5727dec39089b0696ac26abe616aa0fed5a6f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page