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.1.zip (321.2 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.1-py2.py3-none-any.whl (272.5 kB view details)

Uploaded Python 2Python 3

File details

Details for the file glyphsLib-2.2.1.zip.

File metadata

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

File hashes

Hashes for glyphsLib-2.2.1.zip
Algorithm Hash digest
SHA256 d1e920e3969434ca1701887ac98372bff5dd0642af8a2b386504dff266610a3f
MD5 2f1d898f460593daf2af8308ed2771f2
BLAKE2b-256 bb05f41a770ca77d04096249fd274b5ee7ace07f2ee640b52e1b387af20789f0

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for glyphsLib-2.2.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 f56b1bf874b9f99228d610933a9cced919374da8a24059e927376a0a5355d081
MD5 75b0ce68ed1daed0ad5b8d7f96821de7
BLAKE2b-256 96018c2307fd8e99000339b8208fcb776edf31ef1df63a654237f0562df74fa0

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