8000 DOC: make "family" less ambiguous in FontProperties docs by tacaswell · Pull Request #23526 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content

DOC: make "family" less ambiguous in FontProperties docs #23526

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 3, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 9 additions & 5 deletions lib/matplotlib/font_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -626,10 +626,10 @@ class FontProperties:
specification and *math_fontfamily* for math fonts:

- family: A list of font names in decreasing order of priority.
The items may include a generic font family name, either
'sans-serif', 'serif', 'cursive', 'fantasy', or 'monospace'.
In that case, the actual font to be used will be looked up
from the associated rcParam. Default: :rc:`font.family`
The items may include a generic font family name, either 'sans-serif',
'serif', 'cursive', 'fantasy', or 'monospace'. In that case, the actual
font to be used will be looked up from the associated rcParam during the
search process in `.findfont`. Default: :rc:`font.family`

- style: Either 'normal', 'italic' or 'oblique'.
Default: :rc:`font.style`
Expand Down Expand Up @@ -741,7 +741,11 @@ def __str__(self):

def get_family(self):
"""
Return a list of font names that comprise the font family.
Return a list of individual font family names or generic family names.

The font families or generic font families (which will be resolved
from their respective rcParams when searching for a matching font) in
the order of preference.
"""
return self._family

Expand Down
0