Skip to content

Commit 76e3bad

Browse files
Merge pull request #20 from nilswagner/master
Tight layout
2 parents 59df72e + 20c880a commit 76e3bad

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

sectionproperties/post/post.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44

55
def setup_plot(ax, pause):
6-
"""Exectues code required to set up a matplotlib figure.
6+
"""Executes code required to set up a matplotlib figure.
77
88
:param ax: Axes object on which to plot
99
:type ax: :class:`matplotlib.axes.Axes`
@@ -13,6 +13,7 @@ def setup_plot(ax, pause):
1313

1414
if not pause:
1515
plt.ion()
16+
plt.tight_layout()
1617
plt.show()
1718
else:
1819
plt.ioff()
@@ -32,6 +33,7 @@ def finish_plot(ax, pause, title=''):
3233
ax.set_aspect('equal', anchor='C')
3334

3435
if pause:
36+
plt.tight_layout()
3537
plt.show()
3638
else:
3739
plt.draw()

0 commit comments

Comments
 (0)