FontForge_plugin of font checker frontend
Project description
Fontforge font checker plugin
Font checker wrapper for Fontforge
This plugin adds frontend of Fontbakery or Fontspector to Fontforge. Although Fontforge itself has built-in validation feature, these external tools provides more useful checks.
Python 3.9 or later required.
Install
pip3 install fontforge_fontchecker
Make sure Fontforge Python module is usable
In interactive mode of Python, run:
import fontforge
If it raises ModuleNotFoundError exception, install Fontforge first. If
installed, make sure the build option set that the Python module gets also
installed. If already so, Python interpreter does not recognize the module
path where the required module.
export PYTHONPATH=/path/to/fontforge/python/module:$PYTHONPATH
Configuration
This plugin has configuration menu. Select File > Configure Plugins... > Font checker and click Configure to open.
Configuration will be stored in
~/.config/fontforge/plugin/Font checker/config.toml (for Linux.)
Backend
Choose from auto (default), Fontbakery, or Fontspector. If auto, Fontspector will be preferred.
Either or both must be installed to your system; make sure you add the
backend executables to PATH. It is not this plugin itself which
checks fonts.
Check as
Unfortunately the external check tools cannot check SFDs (Fontforge's native file type) directly. Fonts must be exported so that the tools can check.
Choose from TTF (default) or UFO. Between these two, usually TTF is encouraged. Fontbakery's check against UFOs is quite incomplete.
Result for glyphs
This plugin can highlight glyphs with issues in the font view.
Enable or disable for 'color' or 'comment.'
Color for FAIL and WARN
If 'color' option is enabled, set what color shall be used for respective results. Hexadecimal color code such as #ffff00 or just ffff00. Defaults to #ff0000 (red) for FAIL and #ffff00 (lemon) for WARN.
Optionally, color names such as 'crimson' (= #dc143c) or 'goldenrod' (= #daa520) are accepted if webcolors module is available. Color names are case-insensitive.
Profile
Profiles are what specifies which set of checks will be executed. Choose from the list. If you want to use custom profile, edit the configuration file.
Default profile is 'Universal' which checks what considered as community best practice.
These 5 profiles are available for both Fontbakery and Fontspector (for the latter as built-in profiles):
- OpenType (standards compliance only)
- Univarsal
- Google Fonts
- ISO 15008 (in-car accessibility)
- Fontwerk
Explicit checks
Comma-separated list of check IDs (or part of them) which are to be explicitly executed. If specified, only those checks are executed.
Excluded checks
Comma-separated list of check IDs (or part of them) which are not to be executed. If specified, those checks are skipped.
Usage
This plugin adds following items into "Tools" menu:
- Check font
- Check current font
- Check font family
Check font
For TTF or UFO, check will be done against the file existing on disk. If such file has unsaved changes, asks which you intend: checking the files on disk or checking exported font including changes. For other files, the font will be exported into a temporary directory to check.
"Check current font" checks for a single font file.
"Check font family" checks font family to which current font belongs. Only opened files. Closed fonts are excluded. Fonts with family name different from that of current one are ignored.
If checks are done against TTF files directly (rather than through temporary files,) every font files (including closed ones) in the directory are checked as entire family.
Project-specific configuration file
If there is 'fontbakery.toml' or 'fontspector.toml' (for respective font check tools) in the same directory as the font file or the Git repository root directory in which the font, you will be asked if you intend to use that configuration file.
Highlight and add comment to glyphs with problems
When enabled by the configuration, glyphs with problems are highlighted with red or yellow, and the result on those glyphs are added as comment. Regardless of config, problematic glyphs will be selected.
Not all checks are supported.
View report
Once the check is finished, result summary is reported in warning log window, and you are asked if you would like to view details. It will open the browser to show the detail report.
| Symbol | Level | Explanation (from Fontbakery help text) |
|---|---|---|
| 💥 | ERROR | Something wrong with the font checker itself, possibly a bug. |
| ☠ | FATAL | An extremely severe issue that must be addressed immediately. |
| 🔥 | FAIL | A problem with the font that must be fixed. |
| ⚠️ | WARN | Something that you should consider addressing. |
| ℹ️ | INFO | Something useful, typically stats. |
| ⏩ | SKIP | The check does not apply to the given font. |
| ✅ | PASS | The font looks good for the given checking routine. |
These explanation texts are from Fontbakery; also apply to Fontspector. Symbols are the same as in HTML output.
Certain environments show the symbols as emojis.
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
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 fontforge_fontchecker-0.3.0.tar.gz.
File metadata
- Download URL: fontforge_fontchecker-0.3.0.tar.gz
- Upload date:
- Size: 14.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e75017c79f61499e78bfcf1f2a221532d167e03dc689b2eb2cb01bd1f11905ed
|
|
| MD5 |
aae25ca0f77f9ba8699d3a8b54a093d2
|
|
| BLAKE2b-256 |
7fe11578b38ad09cc39cecd8c7ddfe4492725f41463f151ed22ead6963e289df
|
Provenance
The following attestation bundles were made for fontforge_fontchecker-0.3.0.tar.gz:
Publisher:
python-publish.yml on MihailJP/fontforge-fontchecker
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
fontforge_fontchecker-0.3.0.tar.gz -
Subject digest:
e75017c79f61499e78bfcf1f2a221532d167e03dc689b2eb2cb01bd1f11905ed - Sigstore transparency entry: 1102577978
- Sigstore integration time:
-
Permalink:
MihailJP/fontforge-fontchecker@409737b7eb1dab73e8eafb7bf949eef3045a340c -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/MihailJP
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@409737b7eb1dab73e8eafb7bf949eef3045a340c -
Trigger Event:
release
-
Statement type:
File details
Details for the file fontforge_fontchecker-0.3.0-py3-none-any.whl.
File metadata
- Download URL: fontforge_fontchecker-0.3.0-py3-none-any.whl
- Upload date:
- Size: 12.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9eef355027393e38267aafb740f77b27dd197df564ab4b3550377827f3ae1403
|
|
| MD5 |
90fef6a515f9f374e6acbbecd4aacaa7
|
|
| BLAKE2b-256 |
ab9eb501d72d52213a127eed8edd941e39a20364db634627c26802ce2557678b
|
Provenance
The following attestation bundles were made for fontforge_fontchecker-0.3.0-py3-none-any.whl:
Publisher:
python-publish.yml on MihailJP/fontforge-fontchecker
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
fontforge_fontchecker-0.3.0-py3-none-any.whl -
Subject digest:
9eef355027393e38267aafb740f77b27dd197df564ab4b3550377827f3ae1403 - Sigstore transparency entry: 1102578044
- Sigstore integration time:
-
Permalink:
MihailJP/fontforge-fontchecker@409737b7eb1dab73e8eafb7bf949eef3045a340c -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/MihailJP
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@409737b7eb1dab73e8eafb7bf949eef3045a340c -
Trigger Event:
release
-
Statement type: