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

Combined Chart, when highlight is active, bars hides line #3091

Closed
SentoCrespo opened this issue Dec 12, 2017 · 3 comments
Closed

Combined Chart, when highlight is active, bars hides line #3091

SentoCrespo opened this issue Dec 12, 2017 · 3 comments
Labels

Comments

@SentoCrespo
Copy link

Hi, I've set this:
self.graph.drawOrder = [DrawOrder.bar.rawValue, DrawOrder.line.rawValue]

And I have two data sets which appear correctly when nothing is highlighted
image

but when I select something (highlight) it gets hidden by the highlighted bar:
image

How could I keep the highlighted bar behind the line, as in the normal state? Any special property, delegate, something ovbious I'm missing?

Thanks a lot for your effort!

@liuxuan30
Copy link
Member

It seems a defect. highlight is called after drawing the data. If you give a solid color, it will cover the shape. take a look at open override func draw(_ rect: CGRect). To work around, you can change the order on your side.
I think this can be done using a switch either highlight before drawing the data or after. But not sure if there are any side effects.
Are you able to try?

@liuxuan30 liuxuan30 added the bug label Dec 14, 2017
@SentoCrespo
Copy link
Author

Seems to be working, thanks for your support :)

@liuxuan30
Copy link
Member

it's a defect. Let's keep it open

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

No branches or pull requests

2 participants