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

Fix template error bar coloring for bar plots #1643

Conversation

Olof-Hojvall
Copy link

Previous addition of bar outline in templates also changed color of error bars, since errorbar seems to use the colorof marker line over default. This shows a minimum change to fix it back, but I suspect that it would be preferably to set correct color it a better way. Would be happy to adjust the PR, if any suggestions on that could be done. Maybe something like default_line_color should be passed as argument like initialize_template(..., default_line_color=GRAY27) to allow templates to set the color of error bars.

See this notebooks for error and fix: https://nbviewer.jupyter.org/github/Olof-Hojvall/plotly.py/blob/error_bar_notebook/Bar%20Plot%20Errorbar%20Template%20Example.ipynb

Previous addition of bar outline in templates also changed error color
@Olof-Hojvall Olof-Hojvall force-pushed the template_error_bar_barplot_color_fix branch from 74be0c5 to a22ffc5 Compare June 28, 2019 14:33
@jonmmease
Copy link
Contributor

Thanks a lot for the report and fix @Olof-Hojvall. I just opened #1656 which has a small modification to your updates here, but built against the v4_integration branch. We're very close to the version 4.0 release, so new changes are going into that branch right now.

The modification I made is to set the error bar color to the template's font color. This way the same approach works for light and dark themes. See examples in the PR. Does that coloring approach work for you?

@Olof-Hojvall
Copy link
Author

Thanks, that looks good. I’ll close this one.

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

Successfully merging this pull request may close these issues.

2 participants