[why]
We have an automation for adding glyphs to the original set.
If someone throws in the svg file and adds the glyph to the icons.tsv a
new original-source font is generated.
But the added glyphs are not patched in, because that would need a
change at font-patcher (adjust the end codepoint).
This can be forgotten easily.
[how]
The maximum codepoint of our own (original + seti) set is 0xE6FF. At
0xE700 the Devicons start.
The original-source generation script now checks the offset, they may
not be negative and on the positive end we may not leave our set-range.
If that happens the script fails thus the workflow fails.
Also increate the patch range in font-patcher. If there are no icons to
patch in the symbol font the codepoints are just ignored.
[note]
See also PR #1119
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
There is a bit of code that is not needed anymore (or was never needed).
This makes things look more complicated than they are.
[how]
1. It is plain wrong to write that we add one (1) glyph if we do not add
any glyph.
2. One (1) is added to index later anyhow, so we do not need to distort
the counting in the beginning (the code will run with index=1 for
both the first and the second patched in glyph).
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
Python 2 is long since EOL.
With the last commit we want to use Enums, which are not available in
Python 2.
I believe Python 2 broke some time before already, I stopped caring for
Python 2 some time ago.
This does not change any existing code. It just documents that there are
no efforts anymore to support Python 2.
This is PR #1121
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
With commit
621008773 font-patcher: Use WIN metrics in all conflicting cases
we intended to use the WIN metrics for the baseline to baseline
calculations for fonts that have contradicting (i.e. broken) metrices.
But we use the TYPO metrics instead.
[how]
This is obviously a typo in the code. To prevent such errors and improve
the readability we use Enums now. I believe we silently dropped support
for Python 2 some time back. And if not we drop it today :-}
[note]
Many thanks to Nathaniel Evan for again finding this bug!
Mentioned in: #1116
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
With commit
e69a025a8 font-patcher: Fix line gap redistribution
we fixed the wrong adding instead of subtraction of the bottom gap part
from the descenders.
At least this was done for HHEA and TYPO values.
With WIN values the descenders have positive (!) numbers, so the sign
was not changed for the WIN case.
But that is wrong, as we are already in the ymin xmax coordinate system
(and took the negative of the WIN descenders). So of course here also we
need to subtract and not add.
Mentioned in: #1116
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
Instead of redistributing the line gap we remove it.
At least when HHEA or TYPO metrics are used.
It's ok with WIN metrics.
[how]
If we have negative numbers for a gap and want to add more to it, where
'add' means 'make it more', we must of course _subtract_ the value.
But baseline-to-baseline code into function so we can check it after all
our gymnastics for correctness. It means the metrics.
[note]
Also correct out-of-sync comment.
Fixes: #1116
Reported-by: Nathaniel Evan <nathanielevan>
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
The heavy angle brackets (276E and 276F) are used for a lot of prompts,
but we do not yet patch them in and a lot of fonts do not bring them
themselves.
[how]
One time rip the glyphs out from Hack and patch them in always, but
careful (do not replace existing glyph).
We take the whole set 276C - 2771.
[note]
Usually we should never again need to run the generate-extraglyphs
script, we rip them out now and they look good. Whatever Hack does with
new versions we can follow but that is optional.
Related: #1110
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
A lot of issues arise here. Running through fontforge instead of direct
seems to be more compatibe across setups.
Fixes: #284
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
When changes are made to the font-patcher and fonts are patched with
that version we can not see which patcher has been used in the fonts
afterwards.
Would be good to have the usual version-patchversion number in the fonts
in these cases (i.e. `v2.3.3-7` for 7 commits after `2.3.3`).
I did this manually before, but it is always a hassle.
[how]
If the font-patcher is run directly from a git repo and git is installed
we try to get the latest tag version including patch number.
If and only if that is successful and that version is 'newer' than the
version encoded in the font-patcher script the git version is trusted
more.
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
After adding a contributor with allcontributors the website is not
updated.
[how]
Obviously there is a setting if a dependant workflow should be started.
Set that value to 'true'.
Also fix commented-out section of workflow triggers for 'release', that
should not be triggered by allcontributors, when that is commented-in
again (if ever).
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
Some fonts have invalid (or unset) Panose flags. When we create a "Nerd
Font Mono" font the Panose proportion is set to 'monospace'. This
make the font selectable in certain applications that need monospaced
fonts.
After #764 the "Nerd Font" variant shall (again) be detected as
monospaced font, but the glyphs have a big right side bearing (hang into
the next 'cell'). So we need to set the Panose bits there also.
[how]
We already have a check if the font is propably monospaced, independent
from Panose. This is used to prevent --mono patching on originally
proportional fonts.
If we find out with that check that the font is (most probably)
monospaced we also set the appropriate bits in Panose; unless Panose has
valid values that contradict that change.
Fixes: #1098
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
The (old) Material Design Icons are to be removed.
We should communicate that on the Cheat Sheet.
[how]
See commit
4452ceee5 Add possibility to add "obsolete" to glyphs
that implements the CSS stuff to display an 'obsolete' marker.
Change the cheat-sheet generatot to actually insert the markers for the
appropriate codepoints. That is, the codepoints are not checked but the
ID.
Fixes: #1096
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
Some font previews in the gh-pages are obviously wrong (showing some
fallback font).
[how]
Recreate all image previes from current master branch.
To make this more easy:
- Add commented out code that displays command to install just the
needed fonts but all the needed fonts
- Add commented out code that displays the family names of the needed
fonts - these have to be in sync with the fonts.json database
Fixes: #489
Reported-by: CosmosAtlas
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
The implode function can not work correctly because the bash pattern
expansion inserts blanks in unexpected places.
[how]
Use a dump loop instead of being smart.
Fixes: #280
Reported-by: Geoffrey Biggs <gbiggs>
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
When --quiet and --no-progressbar is given we get a lot of empty lines
in the output.
[how]
Just output the carriage return when we have output som eunterminated
stuff before.
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
When a certain 'higher codepoint' glyph is needed for a substitution or
ligature rule of a basic glyph and we replace the 'higher codepoint'
glyph with a symbol that stylistic set or ligature will be broken.
[how]
We can not determine if a certain glyph is the _target_ of a pos-sub
rule (at least I could not find a way). What we do is remove all pos-sub
entries that _start_ at a symbol-patched glyph [1], but that is not the
same.
Instead of walking through all substitution tables we just examine the
'basic glyphs' and also protect all glyphs that they reference through
most of the possub tables.
In fact I encountered only "Substitution" entries and never "Ligature"
entries, but we handle both alike. "Pair", "AltSub", and "MultSub" are
not handled, but could be added if need be.
[1] #711Fixes: #901
Reported-by: Xiangyu Zhu <frefreak.zxy@gmail.com>
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
All/most fonts are now available as Arch Community packages and not as
AUR anymore.
[how]
Instead of listing all individually link to search page.
Make sure the Symbols Only font in Community is also found.
Fixes: #1057
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
It's a pain to have the addition of contributors automated via
all-contributors bot, but then it does not end up on the webpage.
[how]
I'm not sure it will automatically be triggered (pretty sure it will
not), but at least one can clickstart manually the workflow.
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
The script is not a 'proper' script with shebang.
The CONTRIBUTORS.md format changed.
We want to incorporate this as CI workflow.
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
In the course of #271 the source for SourceCodePro switched: Before we
used SourceCode Powerline [1], afterwards the original one [2].
One font file has been forgotten, as the font files were differently
named in both variants.
This caused issed with parallel build in the CI and font tweaking (which
is done as additional process after the actual patching).
[note]
[1] https://github.com/ryanmcilmoyl/sourceCodePro-Powerline
[2] https://github.com/adobe-fonts/source-code-pro/releases/tag/2.030R-ro%2F1.050R-it
Maybe, this is not entirely clear, and the 'Powerline' variant does not
have an Italic style.
Fixes: #1084
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
The JetBrains Mono family names are still broken.
The commit
b98c2a19 Fix JetBrains Mono Family names
did not do much, because it was not activated with gotta-patch-em.
The previous commit fixed that.
Put the fonts in the repo are still wrong. Repatching those gives a
chance to test them properly before v3.0.0.
[how]
Run gotta-patch-em with version set to v3.3.3-p6 because thats the git
status right now.
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
JetBrains Mono is patched without `--makegroups`, although it is
specified in the `config.cfg`.
[how]
As with the licenses the code expects a specific font directory depth.
That is violated with some fonts, for example JetBrains Mono.
The config is never found.
Compare commit
8a749ab21 patch-em-all: Fix missing licenses
Fixes: #1081
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
I'm not sure why it has been in the code like this, and I removed these
strange globs already before in some places [1].
find -name "*.[o,t]tf"
actually allows
*.otf
*.ttf
*.,tf
[how]
Remove spurious comma in all `find` calls.
Systematically.
[note]
Just some commits mentioned here:
2ace3de8e7722458821ac6817bc729e2
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
With commit
6e361d40c cheat-sheet: Allow click to copy on hex value
(on branch gh-pages) we add the possibility to copy the raw hex code by
clicking on the hex number.
It would be more obvious if there is a tooltip.
[how]
Add tooltip via 'title' in cheat-sheet generator script.
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why]
Travis stopped working in 2021, and we would need to set up a new thing
somewhere else.
The shield is always red (because Travis stopped working at all), which
does not look good ;-)
See also #212
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
Also correct some metadata in package info.
Reason for this bugfix release is problem we had with 2.3.2 and Symbols
Only font. Tried to fix the release retroactively but Arch was faster.
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>