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

Pending confirmation: Try to fix single dataSet with custom groupSpace issue #284 #285

Closed

Conversation

liuxuan30
Copy link
Member

for issue #284

How to test the difference:
Force groupSpace to return custom value or 0.8 like below:

    /// The spacing is relative to a full bar width
    public var groupSpace: CGFloat
    {
        get
        {
            if (_dataSets.count <= 1)
            {
                return 0.8
            }
            return _groupSpace
        }
        set
        {
            _groupSpace = newValue
        }
    }

@danielgindi
Copy link
Collaborator

@PhilJay do you see any possible sideeffects to this?

@liuxuan30
Copy link
Member Author

Why it forces to return 0.0 if only up to 1 dataSet. Is it allowed to return other value instead of 0.0 for this scenario?
I am not sure if it makes sense to return positive values. If not, then we can close it. I got this issue by QA testing.

@liuxuan30
Copy link
Member Author

@danielgindi I am occupied with some dev work recently, I will update as soon as I got some time.

@danielgindi danielgindi changed the title try to fix single dataSet with custom groupSpace issue #284 Pending confirmation: Try to fix single dataSet with custom groupSpace issue #284 Oct 1, 2015
@liuxuan30 liuxuan30 force-pushed the SingleDataSet+CustomGroupSpace branch from 1bfd928 to 618c44e Compare October 6, 2015 03:28
… groupSpace into account while calculating visibleXIndex and highlighting

add fix for horizontal bar chart

merge from master
@liuxuan30 liuxuan30 force-pushed the SingleDataSet+CustomGroupSpace branch from 618c44e to a2f1b1e Compare October 6, 2015 03:40
@liuxuan30
Copy link
Member Author

get some time to merge with master. The only problem still remains:

Why it forces to return 0.0 if only up to 1 dataSet?
Is it allowed to return other value instead of 0.0 for this scenario?
I am not sure if it makes sense to return positive values. 
If not, then we can close it. I got this issue by QA testing.

@liuxuan30
Copy link
Member Author

Today I have been thinking about this, groupSpace should be used when dataSets count > 1. Only one dataSet and setting groupSpace seems not make sense?

Besides, I found a bug that when trying to highlight the bars, the xIndex is not correct, due to the groupSpace is 0.8, not 0. Using 0.0 is correct highlighting. So I am thinking there must be some reasons to separate them. Closing this PR right now.

@liuxuan30 liuxuan30 closed this Oct 10, 2015
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.

2 participants