Skip to content

Commit 1144e8c

Browse files
authored
Merge pull request #8666 from anntzer/document-legend-right
Document 'right' legend position as alias for 'center right'.
2 parents 718ac86 + 7a776f1 commit 1144e8c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/matplotlib/legend.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ class Legend(Artist):
118118
'upper left' : 2,
119119
'lower left' : 3,
120120
'lower right' : 4,
121-
'right' : 5,
121+
'right' : 5, (same as 'center right', for back-compatibility)
122122
'center left' : 6,
123123
'center right' : 7,
124124
'lower center' : 8,

lib/matplotlib/offsetbox.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1007,13 +1007,13 @@ def __init__(self, loc,
10071007
**kwargs):
10081008
"""
10091009
loc is a string or an integer specifying the legend location.
1010-
The valid location codes are::
1010+
The valid location codes are::
10111011
10121012
'upper right' : 1,
10131013
'upper left' : 2,
10141014
'lower left' : 3,
10151015
'lower right' : 4,
1016-
'right' : 5,
1016+
'right' : 5, (same as 'center right', for back-compatibility)
10171017
'center left' : 6,
10181018
'center right' : 7,
10191019
'lower center' : 8,

0 commit comments

Comments
 (0)