File tree Expand file tree Collapse file tree 3 files changed +257
-153
lines changed
Expand file tree Collapse file tree 3 files changed +257
-153
lines changed Original file line number Diff line number Diff line change 1616### Bug fixes
1717
1818 * Fixed compatibility of ` mpu.colorbar ` with ` bbox_inches="tight" ` for matplotlib 3.4 and
19- newer ([ #26 ] ( https://github.com/mathause/mplotutils/pull/26 ) ).
19+ newer and refactor and extend tests ([ #26 ] ( https://github.com/mathause/mplotutils/pull/26 )
20+ and [ #40 ] ( https://github.com/mathause/mplotutils/pull/40 ) ).
2021
2122### Internal changes
2223
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ def colorbar(
1414 pad = None ,
1515 shift = "symmetric" ,
1616 shrink = None ,
17- ** kwargs
17+ ** kwargs ,
1818):
1919 """
2020 automatically resize colorbars on draw
@@ -389,7 +389,7 @@ def inner(event=None):
389389 height = size_scaled
390390 else :
391391 figure_aspect = np .divide (* f .get_size_inches ())
392- height = ( width * figure_aspect ) / (aspect )
392+ height = width * (aspect * figure_aspect )
393393
394394 left = posn1 .x0 + shift * full_width
395395 bottom = posn1 .y0 - (pad_scaled + height )
You can’t perform that action at this time.
0 commit comments