Skip to content

#441 Fill not working #2837

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

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

#441 Fill not working #2837

wants to merge 4 commits into from

Conversation

semirke
Copy link

@semirke semirke commented Feb 21, 2017

This pull request is a proposed to solve #441 (#441)
Basically the vanishing fillings were caused by scattered Float.NaNs.
I tested this solution with NaNs missing from the beginning, end and in between, however, to much and scattered NaNs could maybe still render a graph useless.

Ps: sorry for the in between commits, my git is a bit rusty...

int sIdx = startIndex;
while(Float.isNaN(dataSet.getEntryForIndex(sIdx).getY())
&& sIdx < endIndex ) sIdx++;

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could've added a check for success.

@noberasco
Copy link

Hi @semirke,

I'm trying your fix as I'm affected by the same issue.
However, I find that the LineChart issue with NaN values is not limited to the chart fill.
If the portion of LineChart visible on screen starts with a NaN, than the whole chart won't be visible until you move/zoom it so that it starts with a valid number.

@noberasco
Copy link

Here is a quick fix for my chart-not-drawing issue:
#2878

@almic
Copy link
Contributor

almic commented Oct 28, 2018

Thank you for this, but there's been changes to the repo since this. If you resolve the conflicts, then I can merge it.

@almic almic added the fix fixes a bug or otherwise incorrect behavior label Oct 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix fixes a bug or otherwise incorrect behavior
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants