plotly.py icon indicating copy to clipboard operation
plotly.py copied to clipboard

Legend not fully displayed in SVG

Open alvanuffelen opened this issue 1 year ago • 0 comments

The longest text of the legend gets cut off when saved to SVG.

fig = go.Figure()
fig.add_trace(go.Scatter(
    x=[1, 2, 3, 4, 5],
    y=[1, 2, 3, 4, 5],
    name="ShortTitle"
))
fig.add_trace(go.Scatter(
    x=[1, 2, 3, 4, 5],
    y=[5, 4, 3, 2, 1],
    name="ALongerTitle"
))
fig.write_image("test.svg")

test

Saving to another format gives the full legend.

alvanuffelen avatar Jul 17 '24 12:07 alvanuffelen