Find the system fonts filename.
Project description
FindSystemFontsFilename
This tool allows you to get the font filename on your system. It will collect TrueType (.ttf), OpenType (.otf) and TrueType Collection (.ttf) font format.
It uses some APIs to find the font filename:
- Windows: DirectWrite API
- macOS: Core Text API
- Linux: Fontconfig API
Installation
pip install FindSystemFontsFilename
How to use it
from find_system_fonts_filename import get_system_fonts_filename, FontConfigNotFound, OSNotSupported
try:
fonts_filename = get_system_fonts_filename()
except (FontConfigNotFound, OSNotSupported):
# Deal with the exception
# OSNotSupported can only happen in Windows and macOS
# - Windows Vista SP2 and more are supported
# - macOS 10.6 and more are supported
# FontConfigNotFound can only happen on Linux when Fontconfig could't be found.
pass
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
File details
Details for the file FindSystemFontsFilename-0.0.4.tar.gz
.
File metadata
- Download URL: FindSystemFontsFilename-0.0.4.tar.gz
- Upload date:
- Size: 9.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8743150d928556117498e3791d4da056432f7d197363cf3c22fd52f63dc61e8f |
|
MD5 | 3ba96f5de9a3452dcef3f0802ec90265 |
|
BLAKE2b-256 | 088b9d512e7ce30d3a41871216290c0554df7c67103180157f9a42e4ce3851a7 |
File details
Details for the file FindSystemFontsFilename-0.0.4-py3-none-any.whl
.
File metadata
- Download URL: FindSystemFontsFilename-0.0.4-py3-none-any.whl
- Upload date:
- Size: 12.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd78dac5deb13d1eb04b94619292fa3654ce4f63dd29677fd018765339945d65 |
|
MD5 | ee809082ec5dc087b06a443125043458 |
|
BLAKE2b-256 | df236b202a447ce58fc0cc9a0eaa098b0985b6cd31782c3aa6b17221c5064c68 |