Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 74093a6

Browse filesBrowse files
author
pwuertz
committed
fixed conversion from pt to inch in tight_layout
1 parent 267b0cf commit 74093a6
Copy full SHA for 74093a6

File tree

Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed

‎lib/matplotlib/tight_layout.py

Copy file name to clipboardExpand all lines: lib/matplotlib/tight_layout.py
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,15 +71,15 @@ def auto_adjust_subplotpars(fig, renderer,
7171

7272
rows, cols = nrows_ncols
7373

74-
pad_inches = pad * FontProperties(size=rcParams["font.size"]).get_size_in_points() / renderer.dpi
74+
pad_inches = pad * FontProperties(size=rcParams["font.size"]).get_size_in_points() / 72.
7575

7676
if h_pad is not None:
77-
vpad_inches = h_pad * FontProperties(size=rcParams["font.size"]).get_size_in_points() / renderer.dpi
77+
vpad_inches = h_pad * FontProperties(size=rcParams["font.size"]).get_size_in_points() / 72.
7878
else:
7979
vpad_inches = pad_inches
8080

8181
if w_pad is not None:
82-
hpad_inches = w_pad * FontProperties(size=rcParams["font.size"]).get_size_in_points() / renderer.dpi
82+
hpad_inches = w_pad * FontProperties(size=rcParams["font.size"]).get_size_in_points() / 72.
8383
else:
8484
hpad_inches = pad_inches
8585

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.