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

Scatterpoint invisible if colorAxis is present and value is NaN (even when markerfill is set) #2078

Open
Spordoz opened this issue May 1, 2024 · 2 comments

Comments

@Spordoz
Copy link

Spordoz commented May 1, 2024

Steps to reproduce

  1. Create a model
  2. Add axes (including a color axis)
  3. Add scatterseries which uses said color axis (renders fine) (actually set the colorAxisKey)
  4. Set value of all points of scatterseries of step 3 to match them to a color in colorAxis (all points have a value between min and max of the color axis)
  5. Add scatterseries which sets .markerfill instead (don't set colorAxisKey)
  6. Do not set value of points of scatterseries of step 5 (value is NaN)

Platform:
.NET version: .net742 and .net7.0 (tried on both)

Expected behaviour

Oxyplot plots the series using the markerfill value and ignores the value of the point or coloraxis since it doesnt need it.

(this image is after I have set all points to a value (0 in this case)
image

Actual behaviour

The scatterseries of step 5 will now be invisible. Selectable, but invisible.
The moment I give these points any value at all they are rendered

As far as I know value of a point shouldn't play any role if markerfill is set. But the moment I give it one (the value does actually not matter, the resulting color is always the same (markerfill color). Setting the InvalidNumberColor value of the color axis does nothing.

image

@VisualMelon
Copy link
Contributor

Does the color axis InvalidNumberColor change anything?

@Spordoz
Copy link
Author

Spordoz commented May 7, 2024

It seems I never finished that sentence. If I remember correctly setting LinearColorAxis.InvalidNumberColor changed nothing.
It shouldn't even be concerned with the colorAxis if Series.MarkerFill is set if I understand the code correctly. So maybe it is indeed ignoring the colorAxis and thus LinearColorAxis.InvalidNumberColor, but it is also ignoring Series.MarkerFill as long as no ScatterPoint.Value is set (NaN).

Edit: Just tested, LinearColorAxis.InvalidNumberColor indeed does nothing. Tried setting it on every other colorAxis and even making a seperate color axis that has it set specially for the NaN series.

Edits: Edited for clarity

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

No branches or pull requests

2 participants