nerd-fonts icon indicating copy to clipboard operation
nerd-fonts copied to clipboard

Feature: stable codepoints

Open Finii opened this issue 3 years ago • 1 comments

Description

The Font Logos and Octicons codepoints depend on the parallel existence of FontAwesome. I.e. Font Logos is shifted of Octicons or FontAwesome is also present in the patched font; Octicons is shifted if FontAwesome is present.

This means that people, although using a Nerd Font, can expect the symbols in different locations. The reason is clear; people that just want one or some symbols and use a specifically patched font will be able to use the original symbol font codepoints.

But I guess that these uses are nonexisting. Almost all will use 'complete' patched fonts and that is what we deliver and document.

To make the documentation less complicated we should fix the code point ranges that a specific symbol set will be patched in at.

The two possible places where Octicons / Font Logos ends up are there since they have been added back in 2015/6 (commits 9620d47ae, f933b5a2).

Requirements / Checklist

What does this Pull Request (PR) do?

Make the codepoints of symbol sets stable, i.e. independent of other also incuded symbol sets.

It also drops SrcEnd from the patch table with 159820b. This improves the maintainability of the code and should be cherry-picked even if the complete PR is not merged.

How should this be manually tested?

Generate --complete font before and after this changes, fonts are identical (maybe use fontforge font compare, or cmp) (I did this).

Any background context you can provide?

What are the relevant tickets (if any)?

Came up with #762 i.e. on https://github.com/ryanoasis/nerd-fonts/wiki/Glyph-Sets-and-Code-Points.

Screenshots (if appropriate or helpful)

Finii avatar Feb 04 '22 11:02 Finii

Please consider 159820b independently, that commit just improves code maintainability with no functional change.

Finii avatar Feb 04 '22 12:02 Finii