Comments (6)
are you able to debug a little? it seems you could do this. normally just search for the value labels and see whether it goes into drawText. is it only happens on mac?
Thank you for the suggestion. This actually helped!
Starting from drawText,
I was able to determine that the bug is actually caused by the following line of code inside of the drawValues(context: CGContext) method in the BarChartRenderer.swift class:
`
Swift
guard viewPortHandler.isInBoundsY(rect.origin.y),
viewPortHandler.isInBoundsLeft(x)
else { continue }
`
And when I comment that code out, it displays the values as expected:
If someone could shed some light on this code, and tell us what its doing (and why it is causing this bug) that would be appreciated. Otherwise, its working fine without this code and hopefully it is fixed in the future.
from charts.
are you able to debug a little? it seems you could do this. normally just search for the value labels and see whether it goes into drawText. is it only happens on mac?
from charts.
Same issue here.
It happens randomly. I've tried changing constraints, font sizes, leftAxis spaceTop/spaceBottom and nothing consistently works.
Charts 3.2.2
iPhone 11 Pro Simulator
iOS 14.5
XCode 12.5
Swift 4
from charts.
Please help us. Thanks @danielgindi
from charts.
Hi @liuxuan30
I may find some time to debug. But not in the near future.
But it happens in iOS as well. Like I said it's easier to replicate on Mac.
Mac Catalyst in my case. Labels disappear randomly depending on the chart view frame size.
It's really easy to see on Mac as you can freely resize the app window.
On iOS it's a lottery. They can disappear depending what negative values you have. May disappear in portrait but not landscape and vice versa.
You should be able to replicate quite easily.
from charts.
Same issue here.
It happens randomly. I've tried changing storyboard constraints, font sizes, leftAxis spaceTop/spaceBottom and nothing consistently works.
Charts 3.2.2
iPhone 11 Pro Simulator iOS 14.5 XCode 12.5 Swift 4
Upgraded to version 4.1.0 and the issue still remains.
It seems to only happen when all values are negative, and it is still random.
iPhone 15 Pro Simulator
iOS 17.4
XCode 15.3
Swift 4
from charts.
Related Issues (20)
- DGCharts.framework/Headers/DGCharts-Swift.h:4769:2: Unsupported Swift architecture HOT 1
- Documentation not found
- dyld[1596]: Library not loaded: /System/Library/Frameworks/Charts.framework/Charts HOT 1
- DGCharts Y-axis labels are not aligned to left
- LineChartRenderer.drawHighlighted crash HOT 2
- CandleStickChart auto scaling min/max is not working correctly
- HighLight bar disable unselected
- Candle Chart, Stick not visible as expected
- [Unknown process name] CGAffineTransformInvert: singular matrix
- No chart data available
- Not able to archive because 'No such file or directory 'PackageFrameworks/DGChartsDynamic.framework/DGChartsDynamic'' HOT 4
- Future of DGCharts? HOT 5
- Depreciated functions used in ChartColorTemplates HOT 1
- more colors with barchart HOT 1
- How to make stacked line chart?
- Creating Stacked Bar Chart How To Round Corner Radius Of Bar and How To Set DataPoints Background Color
- BarChart: highlight x-axis value when tapped HOT 1
- Incorrect scale of candlestick chart
- Y-axis max label is less than the highest Y-Value
- Library not loaded on physical device HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from charts.