8000 Better align param comments in `Legend.__init__` signature. by anntzer · Pull Request #20333 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content

Better align param comments in Legend.__init__ signature. #20333

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
May 29, 2021
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
82 changes: 38 additions & 44 deletions lib/matplotlib/legend.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,50 +301,44 @@ def __str__(self):
return "Legend"

@docstring.dedent_interpd
def __init__(self, parent, handles, labels,
loc=None,
numpoints=None, # the number of points in the legend line
markerscale=None 8000 , # the relative size of legend markers
# vs. original
markerfirst=True, # controls ordering (left-to-right) of
# legend marker and label
scatterpoints=None, # number of scatter points
scatteryoffsets=None,
prop=None, # properties for the legend texts
fontsize=None, # keyword to set font size directly
labelcolor=None, # keyword to set the text color

# spacing & pad defined as a fraction of the font-size
borderpad=None, # the whitespace inside the legend border
labelspacing=None, # the vertical space between the legend
# entries
handlelength=None, # the length of the legend handles
handleheight=None, # the height of the legend handles
handletextpad=None, # the pad between the legend handle
# and text
borderaxespad=None, # the pad between the axes and legend
# border
columnspacing=None, # spacing between columns

ncol=1, # number of columns
mode=None, # mode for horizontal distribution of columns.
# None, "expand"

fancybox=None, # True use a fancy box, false use a rounded
# box, none use rc
shadow=None,
title=None, # set a title for the legend
title_fontsize=None, # the font size for the title
framealpha=None, # set frame alpha
edgecolor=None, # frame patch edgecolor
facecolor=None, # frame patch facecolor

bbox_to_anchor=None, # bbox that the legend will be anchored.
bbox_transform=None, # transform for the bbox
frameon=None, # draw frame
handler_map=None,
title_fontproperties=None, # properties for the legend title
):
def __init__(
self, parent, handles, labels,
loc=None,
numpoints=None, # number of points in the legend line
markerscale=None, # relative size of legend markers vs. original
markerfirst=True, # left/right ordering of legend marker and label
scatterpoints=None, # number of scatter points
scatteryoffsets=None,
prop=None, # properties for the legend texts
fontsize=None, # keyword to set font size directly
labelcolor=None, # keyword to set the text color

# spacing & pad defined as a fraction of the font-size
borderpad=None, # whitespace inside the legend border
labelspacing=None, # vertical space between the legend entries
handlelength=None, # length of the legend handles
handleheight=None, # height of the legend handles
handletextpad=None, # pad between the legend handle and text
borderaxespad=None, # pad between the axes and legend border
columnspacing=None, # spacing between columns

ncol=1, # number of columns
mode=None, # horizontal distribution of columns: None or "expand"

fancybox=None, # True: fancy box, False: rounded box, None: rcParam
shadow=None,
title=None, # legend title
title_fontsize=None, # legend title font size
framealpha=None, # set frame alpha
edgecolor=None, # frame patch edgecolor
facecolor=None, # frame patch facecolor

bbox_to_anchor=None, # bbox to which the legend will be anchored
bbox_transform=None, # transform for the bbox
frameon=None, # draw frame
handler_map=None,
title_fontproperties=None, # properties for the legend title
):
"""
Parameters
----------
Expand Down
0