Refinement to plotly, gr

This commit is contained in:
Nicholas Bauer 2021-11-21 19:55:09 -05:00
parent f9d9cba5ae
commit 1ad74fe129
2 changed files with 5 additions and 5 deletions

View File

@ -780,10 +780,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 = sp[:left_margin] == :match ? 2mm : sp[:left_margin] leftpad = sp[:left_margin]
toppad = sp[:top_margin] == :match ? 2mm : sp[:top_margin] toppad = sp[:top_margin]
rightpad = sp[:right_margin] == :match ? 2mm : sp[:right_margin] rightpad = sp[:right_margin]
bottompad = sp[:bottom_margin] == :match ? 2mm : sp[:bottom_margin] bottompad = 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)

View File

@ -211,7 +211,7 @@ function plotly_layout(plt::Plot)
w, h = plt[:size] w, h = plt[:size]
plotattributes_out[:width], plotattributes_out[:height] = w, h plotattributes_out[:width], plotattributes_out[:height] = w, h
plotattributes_out[:paper_bgcolor] = rgba_string(plt[:background_color_outside]) plotattributes_out[:paper_bgcolor] = rgba_string(plt[:background_color_outside])
plotattributes_out[:margin] = KW(:l => 0, :b => 20, :r => 0, :t => 20) plotattributes_out[:margin] = KW(:l => 0, :b => 0, :r => 0, :t => 0)
plotattributes_out[:annotations] = KW[] plotattributes_out[:annotations] = KW[]