Skip to main content

Tools for working with EOT (Embedded OpenType) font files

Project description

EOT tools

Tools for working with EOT (Embedded OpenType) font files.

About

Embedded OpenType (EOT) fonts are a font format mostly used in Microsoft applications. The primary usage has been as a webfont in Internet Explorer. Nowadays, it is mostly unused, but when dealing with legacy distributions, we might need a deeper look into their properties. Additionally, tools like Fontello still generate EOT font files by default.

When looking for FOSS tooling around EOT fonts, I could not find any reliable parser that would allow further inspection of these files. With the specification being publicly available and the files basically being a TTF file with some header/prefix, basic processing is rather straightforward. Thus, I decided to write a short script for it to later move it into a library to make metadata/property analysis of EOT possible.

The corresponding TTF files can be analyzed with a much wider variety of tools, for example, using the fonttools library.

Features

  • Read all defined properties.
  • Retrieve the embedded TTF file data. Currently limited to uncompressed and unencrypted data as this is what the test files I found use.

Installation

You can install this package from PyPI:

python -m pip install eot_tools

Alternatively, you can use the package from source directly after installing the required dependencies.

Usage

To load an EOT file, use the following code:

from eot_tools import EOTFile


eot = EOTFile("Maki.eot")
print(eot.family_name, eot.style_name, eot.version_name)

Once the file is loaded, you can use fonttools to load the actual font for example:

from io import BytesIO

from eot_tools import EOTFile
from fontTools.ttLib import TTFont


eot = EOTFile("Maki.eot")
with TTFont(file=BytesIO(eot.font_data)) as font:
    print(font)

License

This package is subject to the terms of the MIT license.

Project details


Download files

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

Source Distribution

eot_tools-0.1.0.tar.gz (67.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

eot_tools-0.1.0-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file eot_tools-0.1.0.tar.gz.

File metadata

  • Download URL: eot_tools-0.1.0.tar.gz
  • Upload date:
  • Size: 67.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for eot_tools-0.1.0.tar.gz
Algorithm Hash digest
SHA256 aab0b0b485162ba1630bd2413b0d20d332f44e9dcc0af7c24b2d70585916078a
MD5 56e67054ead3d3d83837e65d1337fe6a
BLAKE2b-256 cf12a578661ce3721161c1d273c2b1cc1edee04fb9c35a30c6f4071690037fd1

See more details on using hashes here.

Provenance

The following attestation bundles were made for eot_tools-0.1.0.tar.gz:

Publisher: release.yml on stefan6419846/eot_tools

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file eot_tools-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: eot_tools-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for eot_tools-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9c812db23cc9138063603a3f29362d4086c9583638b538bdac1ec4a99fe303da
MD5 fe52f04dadba927203e07ff2b86e6dc5
BLAKE2b-256 06bef6533a41f99b1be3747b88ba9cdd89f44d641272018f9283e8c88b7f7b6f

See more details on using hashes here.

Provenance

The following attestation bundles were made for eot_tools-0.1.0-py3-none-any.whl:

Publisher: release.yml on stefan6419846/eot_tools

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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