| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
title says 'min', code looks like it is 's' |
Sorry, something went wrong.
| """List the font filenames known to `fc-list` having the given extension. | ||
| """ | ||
| fontext = get_fontext_synonyms(fontext) | ||
| return [fname for fname in _call_fc_list() |
There was a problem hiding this comment.
This changes the return type?
Sorry, something went wrong.
There was a problem hiding this comment.
From a set represented as a {key: 1, key: 1, ...} dict to a list, yes. I can even document this as a API break :-)
Sorry, something went wrong.
There was a problem hiding this comment.
👍 , please document this. The duck typing of the likely usage is the same.
Sorry, something went wrong.
There was a problem hiding this comment.
done
Sorry, something went wrong.
There was a problem hiding this comment.
Looks like _call_fc_list always returns an empty list
Sorry, something went wrong.
| fname = six.text_type(fname, sys.getfilesystemencoding()) | ||
| except UnicodeDecodeError: | ||
| continue | ||
| return fnames |
There was a problem hiding this comment.
This looks like it will always come out empty.
Sorry, something went wrong.
|
fixed min->s |
Sorry, something went wrong.
Sorry, something went wrong.
| ``afm.get_fontconfig_fonts`` returns a list of paths and does not check for existence | ||
| ````````````````````````````````````````````````````````````````````````````````````` | ||
|
|
||
| ``afm.get_fontconfig_fonts`` used to return a set of paths encoded as a `{key: 1, ...}` dict, and checked for the existence of the paths. It now returns a list and dropped the existence check, as the same check is performed by the caller (``afm.findSystemFonts``) as well. |
There was a problem hiding this comment.
Pretty sure the backticks are the wrong way here, in that single ticks are references and double are code formatting (or at least the dict one needs to be doubled if the other references are not wanted.)
Sorry, something went wrong.
There was a problem hiding this comment.
fixed
Sorry, something went wrong.
We do not need to check filename validity in `_call_fc_list` as `findSystemFonts` already does it.
| Back | FazBrowse Home | New Git URL |
Alternative for #7532.
This implementation also avoids calling fc-list twice.
We do not need to check filename validity in _call_fc_list as
findSystemFonts already does it.