Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions sectionproperties/post/post.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,15 @@ def plotting_context(

yield fig, ax

ax.set_aspect("equal", anchor="C")
ax.set_title(title)
plt.tight_layout()
ax.set_aspect("equal", anchor="C")

# if no axes was supplied, finish the plot and return the figure and axes
if ax_supplied:
# if an axis was supplied, don't continue with displaying or configuring the plot
return

# if no axes was supplied, finish the plot and return the figure and axes
plt.tight_layout()

if filename:
fig.savefig(filename, dpi=fig.dpi)
plt.close(fig) # close the figure to free the memory
Expand Down