Skip to content

Overdrawing of images (and probably shapes) #1390

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

Closed
alexcjohnson opened this issue Feb 17, 2017 · 3 comments
Closed

Overdrawing of images (and probably shapes) #1390

alexcjohnson opened this issue Feb 17, 2017 · 3 comments
Assignees
Labels
bug something broken

Comments

@alexcjohnson
Copy link
Collaborator

When you combine a data-referenced layer-below image with multiple subplots, you get extra copies of the image (which in certain instances could end up on top even though you asked for below!).

  • Open the layout_image mock in test_dashboard
  • `Plotly.relayout(gd,{plot_bgcolor:'rgba(0,0,0,0)'})
  • You'll notice the R logo gets brighter. It's actually being drawn 3 times in the same place, so the effective opacity increases.
    • once in g.x2y2 g.imagelayer - where it's supposed to be
    • once in g.xy g.imagelayer - even though it gets correctly clipped to x2y2
    • once in g.xy2 g.imagelayer - which shouldn't even exist, but the mock forgets to anchor yaxis2 to x2. Perhaps this should be considered a separate bug? ie if xaxis2.anchor = 'y2' shouldn't yaxis2.anchor automatically default to x2? If you drag one of the subplots after setting the background transparent you'll see we're drawing gridlines for xaxis onto the upper subplot.

So the easiest test of fixing this bug would be to give that mock the transparent plot_bgcolor without changing the baseline image.

Shapes use a similar structure for data-referenced below-data display, so it likely has the same bug, but I haven't tested it there.

@alexcjohnson alexcjohnson added the bug something broken label Feb 17, 2017
@alexcjohnson
Copy link
Collaborator Author

Huh, I thought I could wait on this one, but looks like I may need to address it now as part of my work on the array relayout API...

@alexcjohnson alexcjohnson self-assigned this Feb 17, 2017
@alexcjohnson
Copy link
Collaborator Author

Turns out shapes had a different issue with my branch and do not suffer from this bug. I'll keep myself assigned here since I pretty much know what to do, but may be able to keep it separate after all.

@alexcjohnson
Copy link
Collaborator Author

closed by #1453

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

No branches or pull requests

1 participant