diff options
| author | Dan Allen <dan.j.allen@gmail.com> | 2022-10-12 04:04:14 -0600 |
|---|---|---|
| committer | Dan Allen <dan.j.allen@gmail.com> | 2022-10-12 04:05:53 -0600 |
| commit | c11b95df5c9f98446491b4a972694275b112a389 (patch) | |
| tree | 9f9949c51af0272602996d3e2ef8a98a650d35f1 | |
| parent | 250115101a36e52c962596dd01dd5c4abd199ba2 (diff) | |
add another hint about using shorthand to map font to all four font styles
| -rw-r--r-- | docs/modules/theme/pages/font.adoc | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/docs/modules/theme/pages/font.adoc b/docs/modules/theme/pages/font.adoc index d6123cdd..f097e931 100644 --- a/docs/modules/theme/pages/font.adoc +++ b/docs/modules/theme/pages/font.adoc @@ -78,10 +78,29 @@ font: catalog: merge: true Your Font: - normal: /path/to/your/font.ttf + normal: /path/to/your/FontName-Regular.ttf + italic: /path/to/your/FontName-Italic.ttf + bold: /path/to/your/FontName-Bold.ttf + bold_italic: /path/to/your/FontName-BoldItalic.ttf heading: font-family: Your Font ---- -If you're referring to a bundled font, you'll need to prefix the path with `GEM_FONTS_DIR` (or add it to the value of the `pdf-fontsdir` attribute) so the converter can find and register it. +If you want to refer to a bundled font in your font catalog, you need to prefix the path with `GEM_FONTS_DIR` (or add `GEM_FONTS_DIR` to the value of the `pdf-fontsdir` attribute) so the converter can find and register it. You can find the bundle font definitions in default theme. + +If your font only has a single style, or you want to use the same style for all four font styles, assign the font path directly to the key that declares the font name: + +.Mapping a single font to all four font styles +[,yaml] +---- +extends: default +font: + catalog: + merge: true + Your Font: /path/to/your/FontName-Regular.ttf +heading: + font-family: Your Font +---- + +When not using this shorthand, you must map all four font styles. |
