Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

horizontal legend overlaps x-axis title #811

Closed
salim-b opened this issue Nov 23, 2016 · 0 comments
Closed

horizontal legend overlaps x-axis title #811

salim-b opened this issue Nov 23, 2016 · 0 comments

Comments

@salim-b
Copy link
Contributor

salim-b commented Nov 23, 2016

The problem occurs if the legend is positioned below (rather than to the right of) the plot area using legend = list(orientation = "h"). It aggravates in combination with multiline x-axis titles (using <br> tags).

Currently there's no way to control the spacing between the legend and the plotting area. Everything is auto-scaled, it is useless to set the bottom margin (margin = list(b = ...)) in this case because it refers to the space below the legend. The only way to make the whole x-axis title visible is to increase the height of the whole plot until the autoscaling sufficiently spreads the legend and the plotting area apart.

I try to illustrate the problem with the following 3 images which differ only in frame height:

height 700px:
example_height700

height 1000px:
example_height1000

height 1300px:
example_height1300

Here is the above plot hosted on plot.ly.

Update
Due to the suggestion of #812 (comment) I've also reported this over at plotly/plotly.js#1199

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants