Python script to convert font kerning data from Adobe fea format to UFO plist format and vice-versa
Project description
kern-convertor
kern-convertor is a Python utility for converting kerning data in AFDKO features.fea format into UFO-compatible groups.plist and kerning.plist files.
Features
-
Converts AFDKO-style kerning features into UFO-format kerning and group files for direct use in font editors or build processes.
-
Command-line interface for batch processing kerning data from feature files.
-
The fea2kern.py script provides the ability to convert UFO-format groups.plist and kerning.plist files back into Adobe FEA (features) syntax.
Installation
Install via pip from PyPI:
pip install kern-convertor
Usage
After installation, kern-convertor provides command-line scripts to generate kerning and group files from Adobe Feature File and vice-versa :
Convert Adobe Feature file to UFO plist format
To convert a features file to groups.plist:
kern-groups features.fea groups.plist
To convert kerning pairs to kerning.plist:
kern-convertor features.fea kerning.plist
Replace features.fea with the path to your AFDKO features file. Output .plist files can be copied into the appropriate UFO font directory.
Example
To convert your kerning feature file and save the outputs in the current directory:
kern-groups path/to/features.fea groups.plist
kern-convertor path/to/features.fea kerning.plist
Convert kerning data in ufo plist format to Adobe Fea format
fea2kern script converts existing UFO groups.plist and kerning.plist files to a FEA features format file.
Command
fea2kern path/to/groups.plist path/to/kerning.plist output.fea
The first argument is the path to groups.plist
The second argument is the path to kerning.plist
The third argument is the output .fea filename
Example
To generate an Adobe FEA kerning feature from UFO data:
fea2kern groups.plist kerning.plist features.fea
This command writes an AFDKO FEA kerning feature, reconstructed from the groups.plist and kerning.plist files, to features.fea.
Requirements
This tool requires Python 3.7 or later. Any additional dependencies will be installed automatically via pip.
License
See the LICENSE file for licensing details.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kern_convertor-0.1.1.tar.gz.
File metadata
- Download URL: kern_convertor-0.1.1.tar.gz
- Upload date:
- Size: 2.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9757704a68245fe21d9fc054147eca85c1d7bd166f86bbccdbb5737f2c98db96
|
|
| MD5 |
3a90144d31a2597901114c91a74e2a4f
|
|
| BLAKE2b-256 |
31b88a941f57fd2d8a8f746f25b4c5c2d61c38e11de0dc01ce762117c0ec80d0
|
File details
Details for the file kern_convertor-0.1.1-py3-none-any.whl.
File metadata
- Download URL: kern_convertor-0.1.1-py3-none-any.whl
- Upload date:
- Size: 2.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6c0e1d83df95158a3b8edec799a612caada3a29019dd5cfd69ccd7da5ba4e546
|
|
| MD5 |
f8a7cb797a48dbd66738bb33a16b082b
|
|
| BLAKE2b-256 |
686d9ed44869cbded6d52db7da5c9830c54a755c02a7aedc7a58ccfcce7343c4
|