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

Stop axis labels duplicating #638

Closed
wants to merge 17 commits into from
Closed

Stop axis labels duplicating #638

wants to merge 17 commits into from

Conversation

noais
Copy link
Contributor

@noais noais commented Dec 30, 2015

This issue are documented in #315

noais and others added 16 commits September 22, 2015 23:43
* 'master' of https://github.com/noais/ios-charts:
  adding MaximumScaleX
  Repeated line removed from example
* commit 'bf7d7ff729c417b414059933c8b44b877e365743':
  Update README.md
  be explicit on how to install 'Charts' when using CocoaPods since there is another Pod called 'ios-charts'
# By Daniel Cohen Gindi (1) and david ferreira (1)
# Via david ferreira
* 'master' of https://github.com/noais/ios-charts:
  Bug fix setMaximumScaleY should be setMaximumScaleX
  Update README.md
* Daniel: (33 commits)
  Fix possible Index Out Of Bounds error
  Demo updates according to Android counterpart
  Fixed PieChart "chartValueNothingSelected" not firing when clicking outside of the chart
  Fixed a typo "hightlight"
  Fix disappearing line when zooming into LineChart
  Docs updates
  Some refactoring to axis limit line renderings
  Fixed demo to call setMaximumScaleX (Closes #418)
  Stop consequent calls to animate on different axis from interfering (Fixes #456)
  Tuned code styling
  Added Carthage support (Closes #217)
  Bumped to 2.1.4a
  Improvements to highlight animation phase applying
  Fix highlight arrow animation phaseY
  Fix highlight animation bug in stacked bar chart (Fixes #349)
  Fixed `copyWithZone` for latest Swift 2.0 changes (Fixes #410)
  Reduce to nil check only (Fixes #417)
  Avoid trying to draw cubic fill when there's no points (Fixes #419)
  Fix drawing of scatter custom shapes (Fixes #423)
  Removed CALayer extensions, as they are causing too much confusion
  ...
* commit '3f88894f31683888862cf14312db74b05c1a0101': (84 commits)
  Bar chart tests
  Make getBarBounds callable from Objective-C code (Fixes #570)
  round the float value before we cast to Int
  Update README.md
  Bumped to 2.1.6
  Fixed possible out-of-bounds exception when no ranges are present
  fix Scroll issue when the graph is in a UITableView
  Fixed (again...) the highlight vs. drag issue (Closes #520, closes #521)
  Update README.md
  Updated test snapshots for latest x-axis label offset changes
  A comment on how to record in tests
  Removed extraneous "y" (#512)
  Carthage folders should be ignored
  Implemented support for rotated labels on the x-axis
  Support for customizing description text position (Fixed #512)
  Match code styling to new-line brackets
  Adds test support without cocoapods
  Fixed conditions for hasNoDragOffset (Fixes #499, fixes #498)
  update targets to build framework with same name
  Fixed drag offset panning bug
  ...
* master: (51 commits)
  Bar chart tests
  Make getBarBounds callable from Objective-C code (Fixes #570)
  round the float value before we cast to Int
  Update README.md
  Bumped to 2.1.6
  Fixed possible out-of-bounds exception when no ranges are present
  fix Scroll issue when the graph is in a UITableView
  Fixed (again...) the highlight vs. drag issue (Closes #520, closes #521)
  Update README.md
  Updated test snapshots for latest x-axis label offset changes
  A comment on how to record in tests
  Removed extraneous "y" (#512)
  Carthage folders should be ignored
  Implemented support for rotated labels on the x-axis
  Support for customizing description text position (Fixed #512)
  Match code styling to new-line brackets
  Adds test support without cocoapods
  Fixed conditions for hasNoDragOffset (Fixes #499, fixes #498)
  update targets to build framework with same name
  Fixed drag offset panning bug
  ...
* commit 'cbe0bac08b0f7a2df43dc38e921c4609f29e3450':
  enable code coverage
  update tests to make more logical sense
  update carthage bootstrap action
  add ci file and script to run tests
  add missing images for bar chart tests
  Use nil coalescing in ChartDataSet's entryCount (Fixes #631)
  calcYValueSum should not be ABS (Fixes #604)
  Prevent the matrix from reaching invalid values (#417, #607, #577, #582)
  Removed ambiguity of _dataNotSet (Fixes #585)
  Fixed pie-chart highlight position while animating on X
  Allow setting the max pie-chart angle
  Remove useless parentheses causing swift build error - "Expression was too complex to be solved in reasonable time"
  Added automatically generated change log file
  add initialize dataSets in setter
* master:
  enable code coverage
  update tests to make more logical sense
  update carthage bootstrap action
  add ci file and script to run tests
  add missing images for bar chart tests
  Use nil coalescing in ChartDataSet's entryCount (Fixes #631)
  calcYValueSum should not be ABS (Fixes #604)
  Prevent the matrix from reaching invalid values (#417, #607, #577, #582)
  Removed ambiguity of _dataNotSet (Fixes #585)
  Fixed pie-chart highlight position while animating on X
  Allow setting the max pie-chart angle
  Remove useless parentheses causing swift build error - "Expression was too complex to be solved in reasonable time"
  Added automatically generated change log file
  add initialize dataSets in setter
@noais noais changed the title Noais Stop axis labels duplicating Dec 30, 2015
@liuxuan30
Copy link
Member

try squash first :)

@noais noais closed this Dec 31, 2015
@noais noais reopened this Dec 31, 2015
@noais
Copy link
Contributor Author

noais commented Dec 31, 2015

@liuxuan30 I only see only one commit:
"pick fb0672a Stop axis labels duplicating."

I don't have others.

screen shot 2015-12-31 at 09 12 46

@noais noais closed this Dec 31, 2015
@noais
Copy link
Contributor Author

noais commented Dec 31, 2015

@liuxuan30 I create another pull request with any changes.

Here in github I have this log:

    Merge remote-tracking branch 'origin/master'    eb38549
 @noais Bug fix setMaximumScaleY should be setMaximumScaleX b01fa5d
    Merge branch 'master' of https://github.com/noais/ios-charts …    f1005f0
    Merge branch 'Daniel' into Noais …    be91689
    Merge commit '3f88894f31683888862cf14312db74b05c1a0101' … 7f0010b
    Merge branch 'master' into Noais …    63f5f1d
    Merge commit 'cbe0bac08b0f7a2df43dc38e921c4609f29e3450' … 32e7d1b
    Merge branch 'master' into Noais …    52b68db
    Stop axis labels duplicating.

My log is:

commit 1297e7d4b3d24502441d8e249cc37f35c4a216ba
Author: David Miguel Vicente Ferreira <david.viceteferreira@gmail.com>
Date:   Wed Dec 30 11:34:26 2015 +0000

    Stop axis labels duplicating.

commit b3361b588ddf2553ea9de3ba0f0d289b5a258b55
Author: Petr Korolev <sky4winder@gmail.com>
Date:   Fri Dec 11 15:02:36 2015 +0200

    Added automatically generated change log file

@quoctc
Copy link

quoctc commented Mar 11, 2018

I have the same problem with x-Axis value, but I don't know why my issue does not go away:
https://screencast.com/t/qgIDx1eroZEv
This is my code:

    let xAxis = chartView.xAxis
    xAxis.labelFont = UIFont.robotoLight(size: 10) ?? .systemFont(ofSize: 10, weight: .light)
    xAxis.centerAxisLabelsEnabled = true
    xAxis.valueFormatter = IndexAxisValueFormatter()
    xAxis.granularityEnabled = true
    xAxis.granularity = 1.0 // only intervals of 1 day
    xAxis.labelTextColor = UIColor(color: Colors.colorWhite, alpha: 50)
    xAxis.labelPosition = .bottom
    xAxis.setLabelCount(count, force: true) //count is total of xLabels items

Thank for your help

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.

5 participants