README.rst
1|Travis Build Status| |Python Versions| |PyPI Version|
2
3fontmake
4========
5
6This library provides a wrapper for several other Python libraries which
7together compile fonts from various sources (.glyphs, .ufo) into
8binaries (.otf, .ttf).
9
10
11Installation
12~~~~~~~~~~~~
13
14Fontmake requires Python 2.7, 3.5 or later.
15
16Releases are available on `PyPI`_ and can be installed with `pip`_.
17
18.. code:: bash
19
20 pip install fontmake
21
22Use the ``-U``, ``--upgrade`` option to update fontmake and its dependencies
23to the newest available release:
24
25.. code:: bash
26
27 pip install -U fontmake
28
29Alternatively, you can download the git repository and install from source:
30
31.. code:: bash
32
33 git clone https://github.com/googlei18n/fontmake
34 cd fontmake
35 pip install .
36
37Developers who want to quickly test changes to the source code without
38re-installing, can use the "--editable" option when installing from a local
39source checkout:
40
41.. code:: bash
42
43 pip install -e .
44
45It is recommended to install fontmake inside a "virtual environment" to prevent
46conflicts between its dependencies and other modules installed globally.
47
48Alternatively, we also provide a self-contained, standalone version of fontmake
49that only requires a Python 3.6 or 3.7 installation to run. These are available
50to download from the fontmake `Github releases`_ page.
51You simply unzip them and run the included `fontmake` command from your console.
52
53Usage
54~~~~~
55
56After installation, you can use the ``fontmake`` console script. For example:
57
58.. code:: bash
59
60 fontmake -g MyFont.glyphs # outputs binary font files for masters only
61
62Use ``fontmake -h`` to see options for specifying different types of input and
63output.
64
65You can also use fontmake as a module to run intermediate steps in the build
66process, via methods of the ``fontmake.font_project.FontProject`` class.
67
68.. _virtualenv: https://virtualenv.pypa.io
69.. _venv: https://docs.python.org/3/library/venv.html
70.. _pip: https://pip.pypa.io
71.. _pip documentation: https://pip.readthedocs.io/en/stable/user_guide/#requirements-files
72.. _PyPI: https://pypi.org/project/fontmake
73.. _Github releases: https://github.com/googlei18n/fontmake/releases
74.. |Travis Build Status| image:: https://travis-ci.org/googlei18n/fontmake.svg
75 :target: https://travis-ci.org/googlei18n/fontmake
76.. |Python Versions| image:: https://img.shields.io/badge/python-2.7%2C%203.6-blue.svg
77.. |PyPI Version| image:: https://img.shields.io/pypi/v/fontmake.svg
78 :target: https://pypi.org/project/fontmake/
79