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

Charts ScaleX problem #3616

Closed
quoctc opened this issue Aug 30, 2018 · 5 comments
Closed

Charts ScaleX problem #3616

quoctc opened this issue Aug 30, 2018 · 5 comments

Comments

@quoctc
Copy link

quoctc commented Aug 30, 2018

I want to auto scale chart by scaling X to fixing the size of my data. So my charts will not zoom in too much. It's will keep the same space between two points of x values in the chart. But when I call to scaleX by call this func:

chartView.zoomToCenter(scaleX: scale, scaleY: 1.0). It generates weird scaleX number, not my expected number

Here is the debug:
https://screencast.com/t/hGJv2Rl5

What did you expect to happen?

It's should be my scale nubmer that I'm giving. Or there is any function in the lib support it

What happened instead?

It's scale with a bigger number

Charts Environment

Charts version/Branch/Commit Number:
**Xcode version:9.4
**Swift version:4.0
Platform(s) running Charts:
macOS version running Xcode:

Demo Project

ℹ Please link to or upload a project we can download that reproduces the issue.

@quoctc
Copy link
Author

quoctc commented Aug 30, 2018

I know where is the issue. You are using scale by. So, I can fixed it now.

@liuxuan30
Copy link
Member

liuxuan30 commented Sep 19, 2018

then please file a PR, thank you

@quoctc
Copy link
Author

quoctc commented Sep 19, 2018

?

@liuxuan30
Copy link
Member

@quoctc

I know where is the issue. You are using scale by. So, I can fixed it now.

@quoctc
Copy link
Author

quoctc commented Sep 19, 2018

Oh, It does not need to create a PR, I just use a formula to change it

@quoctc quoctc closed this as completed Sep 19, 2018
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