add :margins as an alias for :margin

This commit is contained in:
t-bltg 2021-07-08 11:33:05 +02:00
parent 4a18098944
commit f420363c03
2 changed files with 6 additions and 5 deletions

View File

@ -577,7 +577,8 @@ end
# margin # margin
add_aliases(:left_margin , :leftmargin ) add_aliases(:margins)
add_aliases(:left_margin , :leftmargin)
add_aliases(:top_margin , :topmargin) add_aliases(:top_margin , :topmargin)
add_aliases(:bottom_margin , :bottommargin) add_aliases(:bottom_margin , :bottommargin)
add_aliases(:right_margin ,:rightmargin) add_aliases(:right_margin ,:rightmargin)

View File

@ -751,10 +751,10 @@ function _update_min_padding!(sp::Subplot{GRBackend})
end end
end end
# Add margin given by the user # Add margin given by the user
leftpad = 2mm + sp[:left_margin] leftpad = 2mm + sp[:left_margin]
toppad = 2mm + sp[:top_margin] toppad = 2mm + sp[:top_margin]
rightpad = 2mm + sp[:right_margin] rightpad = 2mm + sp[:right_margin]
bottompad = 2mm + sp[:bottom_margin] bottompad = 2mm + sp[:bottom_margin]
# Add margin for title # Add margin for title
if sp[:title] != "" if sp[:title] != ""
gr_set_font(titlefont(sp), sp) gr_set_font(titlefont(sp), sp)