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

add animation for data lines and points #18

Closed
wants to merge 5 commits into from
Closed

Conversation

dhf
Copy link

@dhf dhf commented Jan 18, 2016

Animation is disabled by default. Also updated the sample project.

pryaniq and others added 5 commits January 15, 2016 10:54
How use:
yourSeriesName1.points = true
yourSeriesName1.points = false
chart.poinstWidth = 2.0

# Conflicts:
#	Source/Chart.swift
#	Source/ChartSeries.swift
@gpbl
Copy link
Owner

gpbl commented Jan 22, 2016

Hi @dhf thanks a lot for you PR!

The idea of supporting animations is tracked here (see also this PR) but the reason it's not implemented yet is that it is more difficult to implement as I thought.

Look for example how the animation works with the others examples:

With a single line chart it seems performing well, but

  • the animation's duration depends on the number of values, e.g. if there are less values it seems way too slow.
  • I expect the animation of a series with less values to end before the animation of a series with more values
  • the lines above and below the x-axis are rendered separately (so we can give a different color), hence the animation looks weird
  • background of filled series is not animated

I think we should find another way, maybe using a mask over the chart. I even would prefer to have the dots in a different PR, since it is another kind of enhancement. @pryaniq PR needs to be reviewed a bit, see discussion.

@dhf dhf closed this Mar 22, 2016
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.

None yet

3 participants