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

Add `visible` style option for simple plotly/bokeh plots. #3948

Merged
merged 2 commits into from Sep 10, 2019

Conversation

@jonmmease
Copy link
Collaborator

commented Sep 7, 2019

Setting visible to False will fully hide the individual element trace.

This option is very useful for the linked selection effort...

Add `visible` style opt for trace-based plotly plots.
Setting to False will fully hide the individual trace
@jbednar

This comment has been minimized.

Copy link
Member

commented Sep 7, 2019

Is there a chance to unify this API with Bokeh?

@jonmmease

This comment has been minimized.

Copy link
Collaborator Author

commented Sep 7, 2019

Is there a chance to unify this API with Bokeh?

I'm not sure. Does anyone know if Bokeh plot elements have an equivalent property to hide everything? For the selection work I'm using the opacity style options to do this.

@jbednar

This comment has been minimized.

Copy link
Member

commented Sep 7, 2019

I'm not an expert at it, but Bokeh has a variety of related options like muted_alpha, muted_color, selection_glyph.visible, nonselection_glyph.visible, and so on; @philippjfr may be able to chat about it on Monday at see where things line up between the two backends.

@philippjfr

This comment has been minimized.

Copy link
Contributor

commented Sep 9, 2019

I'm not sure. Does anyone know if Bokeh plot elements have an equivalent property to hide everything?

Most bokeh elements indeed have a visible property and we should expose it.

@jonmmease

This comment has been minimized.

Copy link
Collaborator Author

commented Sep 9, 2019

Most bokeh elements indeed have a visible property and we should expose it.

Ok, thanks. I'll take a look

@jonmmease

This comment has been minimized.

Copy link
Collaborator Author

commented Sep 10, 2019

Alright, I added the visible style property to all of the simple (non-composite) Bokeh element plots. Basically, for all of the cases where all that is needed is to pass the property along to the single Bokeh glyph representing the element. I didn't do anything with the composite Bokeh elements to this point, as these will take some actual logic changes.

Sound alright for now?

@jonmmease jonmmease changed the title Plotly: Add `visible` style option for trace-based plotly plots. Add `visible` style option for simple plotly/bokeh plots. Sep 10, 2019

@philippjfr

This comment has been minimized.

Copy link
Contributor

commented Sep 10, 2019

Sound alright for now?

Yes, absolutely.

@jbednar

This comment has been minimized.

Copy link
Member

commented Sep 10, 2019

Great!

@philippjfr philippjfr merged commit a977c3d into master Sep 10, 2019

3 of 4 checks passed

continuous-integration/appveyor/pr AppVeyor build failed
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
coverage/coveralls Coverage remained the same at 88.097%
Details

@jonmmease jonmmease deleted the plotly_visible branch Sep 10, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.