... | ... | @@ -16,7 +16,7 @@ To map between an individual font in the **tff** file and the application code, |
|
|
|
|
|
To find an existing font name, search the *json* files for the font name using a text editor or a text search tool like grep.
|
|
|
|
|
|
**Qtawesome** loads its fonts under the *fa* handle. To see all of the possible handles take a look at [https://pypi.org/project/QtAwesome/](https://pypi.org/project/QtAwesome/).
|
|
|
**Qtawesome** loads its fonts under the *mdi<sup>1</sup>* handle. To see all of the possible handles take a look at [https://pypi.org/project/QtAwesome/](https://pypi.org/project/QtAwesome/).
|
|
|
**OpenLP** loads its fonts under the *op* handle.
|
|
|
|
|
|
This means it is obvious in the code where a font comes from. In python 3.7 this is where the files come from.
|
... | ... | @@ -37,9 +37,10 @@ The *ttf* files contain the actual icons and the *json* files contain the mappin |
|
|
/usr/lib/python3.7/site-packages/qtawesome/fonts/materialdesignicons-webfont.ttf
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
In addition to mapping icons, it is possible to amend a number of attributes. The array of icon mappings in the code allows this to happen.
|
|
|
If an icon is defined but not found, a default icon is provided so the code will load and work, you will just get a red cross.
|
|
|
|
|
|
---
|
|
|
|
|
|
<sup>1</sup>: OpenLP has changed, between versions 3.0.2 and 3.1.0, to use `mdi` icons (from materialdesignicons.com) instead of `fa` (Font Awesome). This was done due to questions regarding Font Awesome 5 license and Debian.
|
|
|
|