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 (
strorFontProperties) – The font specs, font names, orFontPropertiess to show. If no positional arguments are passed and thefamilyargument is not passed, then the fonts found inuser_folder()andlocal_foldersand 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_foldersat the top of the table. Default isTrueif called without any arguments andFalseotherwise.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. IfFalsethe dummy glyph “¤” is shown for missing characters.**kwargs – Additional font properties passed to
FontProperties. Default size is12and default weight, style, and strength are'normal'.
- Other Parameters:
- Returns:
ultraplot.figure.Figure– The figure.ultraplot.gridspec.SubplotGrid– The subplot grid.
See also