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

font-patcher: Allow to specify custom symbolfont with absolute path

Open Finii opened this issue 3 years ago • 0 comments

[why] When one wants to use a custom symbol font and specifies it with an absolute path, the glyphdir is still prepended.

That means that the argument to --custom is always used as relative path (to --glyphdir), even when it starts with /. That is somehow unexpected or at least inconvenient.

Example: fontforge font-patcher --custom ~/Downloads/fa6.otf Inconsolata-Regular.otf

fa6.otf is searched for in ./src/glyphs/home/username/Downloads

[how] Use Python function that handles joining path fragments.

If a component is an absolute path, all previous components are thrown away.

Requirements / Checklist

What does this Pull Request (PR) do?

Allow (respect) absolute paths specified with --custom. No change for relative paths.

How should this be manually tested?

Any background context you can provide?

What are the relevant tickets (if any)?

Screenshots (if appropriate or helpful)

Finii avatar Feb 22 '22 15:02 Finii