show_fonts¶
- show_fonts(*args, family=None, user=None, text=None, math=False, fallback=False, **kwargs)[source]¶
Generate a table of fonts. If a glyph for a particular font is unavailable, it is replaced with the “¤” dummy character.
- Parameters
*args (
str
orFontProperties
) – The font specs, font names, orFontProperties
s to show. If no positional arguments are passed and thefamily
argument is not passed, then the fonts found inuser_folder
andlocal_folders
and the availablerc['font.sans-serif']
fonts are shown.family (
{'tex-gyre', 'sans-serif', 'serif', 'monospace', 'cursive', 'fantasy'}
, optional) – The family from which available fonts are shown. Default is'sans-serif'
if no arguments were provided. Otherwise the default is to not show family fonts. The fonts belonging to each family are listed underrc['font.serif']
,rc['font.sans-serif']
,rc['font.monospace']
,rc['font.cursive']
, andrc['font.fantasy']
. The special family'tex-gyre'
includes the TeX Gyre fonts.user (
bool
, optional) – Whether to include fonts inuser_folder
andlocal_folders
at the top of the table. Default isTrue
if called without any arguments andFalse
otherwise.text (
str
, optional) – The sample text shown for each font. If not passed then default math or non-math sample text is used.math (
bool
, default:False
) – Whether the default sample text should show non-math Latin characters or or math equations and Greek letters.fallback (
bool
, default:False
) – Whether to use the fallback fontrc['mathtext.fallback']
for unavailable characters. IfFalse
the dummy glyph “¤” is shown for missing characters.**kwargs – Additional font properties passed to
FontProperties
. Default size is12
and default weight, style, and strength are'normal'
.
- Other Parameters
- Returns
proplot.figure.Figure
– The figure.proplot.gridspec.SubplotGrid
– The subplot grid.
See also