Skip to main content

A bridge from Glyphs source files (.glyphs) to UFOs

Project description

Travis Build Status PyPI Version Codecov

glyphsLib

This library provides a bridge from Glyphs source files (.glyphs) to UFOs via defcon.

The main methods for conversion are found in __init__.py. Intermediate data can be accessed without actually writing UFOs, if needed.

Write and return UFOs

Masters:

master_dir = 'master_ufos'
ufos = glyphsLib.build_masters('MyFont.glyphs', master_dir)

Interpolated instances (depends on MutatorMath):

master_dir = 'master_ufos'
instance_dir = 'instance_ufos'
ufos = glyphsLib.build_instances('MyFont.glyphs', master_dir, instance_dir)

Load UFO objects without writing

ufos = glyphsLib.load_to_ufos('MyFont.glyphs')

Read and write Glyphs data as Python objects

from glyphsLib import GSFont

font = GSFont(glyphs_file)

font.save(glyphs_file)

The glyphsLib.classes module aims to provide an interface similar to Glyphs.app’s Python Scripting API.

Note that currently not all the classes and methods may be fully implemented. We try to keep up to date, but if you find something that is missing or does not work as expected, please open a issue.

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

glyphsLib-2.2.0.zip (320.9 kB view details)

Uploaded Source

Built Distribution

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

glyphsLib-2.2.0-py2.py3-none-any.whl (272.4 kB view details)

Uploaded Python 2Python 3

File details

Details for the file glyphsLib-2.2.0.zip.

File metadata

  • Download URL: glyphsLib-2.2.0.zip
  • Upload date:
  • Size: 320.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for glyphsLib-2.2.0.zip
Algorithm Hash digest
SHA256 1738e1e528e59dcc3a396256db7ce516b0e0659bcda4e27ebea8bed8021d850e
MD5 9d6163fd41f3daa0d789971dfd8b2736
BLAKE2b-256 46a61c8445747c19729ec5cdd425aa1eeba158a40cfc238988a12d1a4eff3ae4

See more details on using hashes here.

File details

Details for the file glyphsLib-2.2.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for glyphsLib-2.2.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 62ed6984220193a04ad2e6acae809e33a60f6d6c5160412728d131a9cabecf2d
MD5 d5080444727ae0cda30f42929d306de7
BLAKE2b-256 cc4f37847298cd1ea53ff59f0a86b94739b88ad6cfd3b332c7f351897c709860

See more details on using hashes here.

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