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

Stacked Bar Graph Label Base Offset #9

Closed
pmanavi opened this issue Aug 7, 2023 · 5 comments · Fixed by #10
Closed

Stacked Bar Graph Label Base Offset #9

pmanavi opened this issue Aug 7, 2023 · 5 comments · Fixed by #10

Comments

@pmanavi
Copy link

pmanavi commented Aug 7, 2023

Really like what you've done here but I believe you might have a bug with Stacked Bar charts. The labels do show up, but they fail to account for the base offset for each stacked bar. Do you by any chance have a solution for this?

@cleroux
Copy link
Owner

cleroux commented Aug 7, 2023

Hi @Manavi, thanks for bringing this to my attention.

I don't recall ever trying this plugin with stacked bar charts. They certainly were not my primary use case. So it's debatable as to whether it's a bug or just unsupported 😉 Although I agree it would be a nice feature.

I haven't used Flot in several years. I have precious little time to devote to maintaining this repo but I would be happy to review and accept a pull request to support stacked bar charts.

I would be interested to see a code snippet that reproduces the behavior you're describing.

I'm also curious to know which version of Flot you are using. This plugin was intended for v0.8.3 which was the last stable version before new maintainers took over circa 2019. I do not intend to update this plugin for versions newer than v0.8.3.

@cleroux
Copy link
Owner

cleroux commented Aug 8, 2023

@pmanavi I added support for stacked bar charts in #10 . Now that the plugin has basic functionality for stacked charts, if you find any bugs please feel free to create a pull request. Thanks!

@pmanavi
Copy link
Author

pmanavi commented Aug 9, 2023

Wow. I was out sick for a couple of days and you already took care of it. I will test it and let you know. Thank you.

@pmanavi
Copy link
Author

pmanavi commented Aug 9, 2023

@cleroux Everything is looking great. I tested it for all four options, and they all work. However, take a look at my plot below. I know that if the label doesn't fit within the bar, its programed to be pushed to an outside position, but is there anyway to turn that off?

Screenshot 2023-08-09 at 3 27 00 PM

@cleroux
Copy link
Owner

cleroux commented Aug 9, 2023

Added nudgeOversize option in #11 .Set it false in your label options.
Cheers.

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 a pull request may close this issue.

2 participants