Skip to content

Commit 411a0fc

Browse files
tacaswellmdboom
authored andcommitted
API: use 'best' for default legend location
Closes #4671
1 parent c84966c commit 411a0fc

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

lib/matplotlib/rcsetup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1027,7 +1027,7 @@ def validate_hist_bins(s):
10271027
'legend.fancybox': [False, validate_bool],
10281028

10291029
# at some point, legend.loc should be changed to 'best'
1030-
'legend.loc': ['upper right', validate_legend_loc],
1030+
'legend.loc': ['best', validate_legend_loc],
10311031

10321032
# this option is internally ignored - it never served any useful purpose
10331033
'legend.isaxes': [True, validate_bool],

matplotlibrc.template

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -383,6 +383,7 @@ backend : %(backend)s
383383
### Legend
384384
#legend.fancybox : False # if True, use a rounded box for the
385385
# legend, else a rectangle
386+
#legend.loc : best
386387
#legend.isaxes : True
387388
#legend.numpoints : 1 # the number of points in the legend line
388389
#legend.fontsize : large

0 commit comments

Comments
 (0)