From fbecabced2879d191d487f661e36dfa74f93f212 Mon Sep 17 00:00:00 2001 From: Benson Muite Date: Aug 21 2025 15:47:45 +0000 Subject: [PATCH 1/2] Naming options when a foundry is not registered https://github.com/weiweihuanghuang/fragment-mono/issues/9 --- diff --git a/guidelines/modules/ROOT/pages/FontsPolicy.adoc b/guidelines/modules/ROOT/pages/FontsPolicy.adoc index 4f4bfca..f349013 100644 --- a/guidelines/modules/ROOT/pages/FontsPolicy.adoc +++ b/guidelines/modules/ROOT/pages/FontsPolicy.adoc @@ -366,7 +366,7 @@ URL: Then it declares elements, that will be shared by all the packaged font families. Here, we only process one of those, but the block will be at the same place in the other patterns. [horizontal] -%\{foundry}:: an optional upstream identifier, when upstream publishes multiple font families, with consistent QA rules. Font families released by the same upstream will usually play well with one another. Marking them as such helps users choose good font package sets. +%\{foundry}:: an optional upstream identifier, when upstream publishes multiple font families, with consistent QA rules. Font families released by the same upstream will usually play well with one another. Marking them as such helps users choose good font package sets. If there is no registered foundry, the name or brandname of the typographer can be used instead provided it enables distinguishing the font. * for example, the https://fontlibrary.org/[Open Font Library] identifier is `oflb`. %\{fontlicense}:: the identifier of the font family license, according to our licensing rules. From 086a16fca93ceea51fe0daff135f4b5fa55533ba Mon Sep 17 00:00:00 2001 From: Benson Muite Date: Aug 21 2025 22:42:27 +0000 Subject: [PATCH 2/2] Break up long lines --- diff --git a/guidelines/modules/ROOT/pages/FontsPolicy.adoc b/guidelines/modules/ROOT/pages/FontsPolicy.adoc index f349013..9688c1e 100644 --- a/guidelines/modules/ROOT/pages/FontsPolicy.adoc +++ b/guidelines/modules/ROOT/pages/FontsPolicy.adoc @@ -4,9 +4,16 @@ The bulk of Fedora software relies on OpenType compliance and was tested against compliant fonts. -Unfortunately, most font makers feel the OpenType specification is a document written by “software people” for “software people”. They spurn its recommendations. They can not be relied upon to release fonts in a software-friendly state, nor to fix the resulting problems, nor to provide useful advice. +Unfortunately, most font makers feel the OpenType specification is a document written by “software people” for “software people”. +They spurn its recommendations. +They can not be relied upon to release fonts in a software-friendly state, +nor to fix the resulting problems, nor to provide useful advice. -To enable the packaging of fonts by non experts, <> provides a list of sanity rules. Most are short unambiguous one liners, easy to understand and apply. Do read this list, even if it feels long. Unless your upstream is a model of discipline, you WILL need it. Avoid <> if you do not feel ambitious – here be dragons. +To enable the packaging of fonts by non experts, <> provides a list of sanity rules. +Most are short unambiguous one liners, easy to understand and apply. +Do read this list, even if it feels long. +Unless your upstream is a model of discipline, you WILL need it. +Avoid <> if you do not feel ambitious – here be dragons. Once you sorted what to package using the checklist, the rpm-specific part of fonts packaging is simple: @@ -15,9 +22,14 @@ Once you sorted what to package using the checklist, the rpm-specific part of fo Fedora automation will do the rest. -<> provides in-depth documentation of those templates, and other operational tips. The operational tips are useful. The spec templates documentation, not so much. The templates are commented and will usually be self-explanatory. +<> provides in-depth documentation of those templates, and other operational tips. +The operational tips are useful. +The spec templates documentation, not so much. +The templates are commented and will usually be self-explanatory. -Lastly, <> provides some help, in case a third party attempts to confuse you. A lot of upstreams are dead set against applying OpenType recommendations. They will provide elaborate argumentation, on why the common rule does not apply to them. +Lastly, <> provides some help, in case a third party attempts to confuse you. +A lot of upstreams are dead set against applying OpenType recommendations. +They will provide elaborate argumentation, on why the common rule does not apply to them. == Checklist @@ -31,7 +43,9 @@ Lastly, <> provides some help, in case a third party attempts to conf === Packaging unit: an ideal font family -Because fonts upstreams are, on average, extremely messy, a large part of packaging fonts involves sorting files and fixing font file metadata to produce the consistent and reliable font catalog expected by applications and users. +Because fonts upstreams are, on average, extremely messy, +a large part of packaging fonts involves sorting files and fixing font file metadata to produce the consistent and +reliable font catalog expected by applications and users. [IMPORTANT] ==== @@ -43,7 +57,9 @@ Width∕Stretch:: Narrow, Condensed, Expanded… Slope/Slant:: Italic, Oblique Optical sizing:: Caption… -Those parameters correspond to the https://docs.microsoft.com/en-us/typography/opentype/spec/dvaraxisreg#registered-axis-tags[default axes] of OpenType variable fonts. +Those parameters correspond to the +https://docs.microsoft.com/en-us/typography/opentype/spec/dvaraxisreg#registered-axis-tags[default axes] +of OpenType variable fonts. ==== * [x] Packagers MUST apply the definition provided in this section to determine font family boundaries, @@ -56,7 +72,9 @@ See also the <> section. [NOTE] ==== .OpenType: one standard, five formats -https://en.wikipedia.org/wiki/OpenType[OpenType] uses an _SFNT_ container around bitmaps (`+*.otb+`) and outlines in _TT_ (`+*.ttf+`) or _CFF_ (`+*.otf+`) formats. Multiple fonts can be consolidated in a single collection (`+*.ttc+` or `+*.otc+`). +https://en.wikipedia.org/wiki/OpenType[OpenType] uses an _SFNT_ container around bitmaps (`+*.otb+`) and +outlines in _TT_ (`+*.ttf+`) or _CFF_ (`+*.otf+`) formats. +Multiple fonts can be consolidated in a single collection (`+*.ttc+` or `+*.otc+`). ==== * [x] Other font formats MUST be converted to OpenType, @@ -66,7 +84,9 @@ https://en.wikipedia.org/wiki/OpenType[OpenType] uses an _SFNT_ container around [NOTE] ==== .Font packages -A *font package*, is an installation (RPM) package, containing OpenType font files. It MAY be produced by a source (SRPM) package, that also produces other (font or non-font) packages. Other kinds of font packages are out of scope for this document. +A *font package*, is an installation (RPM) package, containing OpenType font files. +It MAY be produced by a source (SRPM) package, that also produces other (font or non-font) packages. +Other kinds of font packages are out of scope for this document. ==== * [x] A font family MUST NOT be packaged in multiple or mixed OpenType formats, @@ -79,18 +99,24 @@ A *font package*, is an installation (RPM) package, containing OpenType font fil === Fontconfig -* [x] Font packages SHOULD include the fontconfig files, that define the selection and substitution rules applying to their font files, +* [x] Font packages SHOULD include the fontconfig files, +that define the selection and substitution rules applying to their font files, ** written by the packager if upstream does not provide them. -* [x] Fontconfig rules MUST rewrite `family` and `style` when they are not compliant with https://docs.microsoft.com/en-us/typography/opentype/spec/name#name-ids[OpenType WWS] rules: +* [x] Fontconfig rules MUST rewrite `family` and `style` when they are not compliant with +https://docs.microsoft.com/en-us/typography/opentype/spec/name#name-ids[OpenType WWS] rules: ** `family` MUST NOT contain _Weight_, _Width_ or _Slope_ attributes (ideal WWS family name, Name ID 21), ** `style` MUST contain only _Weight_, _Width_ or _Slope_ attributes (ideal WWS subfamily name, Name ID 22), ** Name ID 21 & 22 fields may exist or not in the packaged font files, and may be correct or not. The packager MUST set the correct value at the fontconfig level if the value fontconfig extracts from font files is incorrect. * [x] Fontconfig rules MUST rewrite `family` to remove format attributes when they exist, ** for example: `OT`, `TT`, `Variable`, `Graphite`, `G`, etc, -** except when <>; in that case the removal MUST only be done for the font package providing the default format. +** except when <>; +in that case the removal MUST only be done for the font package providing the default format. * [x] Fontconfig rules MUST rewrite `family` to remove coverage attributes when they exist, ** for example: `Math`, `Emoji`, `Color Emoji`, `Hebrew`, `Arabic`, `Thai`, `LGC`, etc, -** except when several font files provide the same coverage, requiring a qualifier to distinguish between them; in that case the removal MUST be done for the default file, and other files MUST be treated as parts of separate font families. +** except when several font files provide the same coverage, +requiring a qualifier to distinguish between them; +in that case the removal MUST be done for the default file, +and other files MUST be treated as parts of separate font families. * [x] Fontconfig rules MUST rewrite `fullname` to `