swiftui-charts Questions
1
I think this is a bug, it only appears when I try to access a custom color in the Assets Catalog. The color is displayed correctly but I have an error in the console.
No color named '...' found in...
Neubauer asked 17/6 at 21:1
3
Solved
I am using the new swift charts framework to display some data. In seeking to manually control the frequency of the x-axis AxisValueLabels, as well as adjust the color, I implemented the following:...
Salient asked 28/10, 2022 at 20:19
2
Solved
Looking over Apple Documentation I found a straightforward way of doing this provided your dataset is structured correctly (mine is not). I've been working with a CSV file containing rows structure...
Exegesis asked 20/10, 2022 at 2:25
2
I'm using Swift Charts in a SwiftUI app to make a line chart. I would like to rotate the Y axis label such that it reads from bottom to top. I tried to rotate the text but the rotation causes the l...
Brennan asked 3/12, 2022 at 4:28
3
In Swift Charts the signature for chartForegroundStyleScale to set the ShapeStyle for each data series is:
func chartForegroundStyleScale<DataValue, S>(_ mapping: KeyValuePairs<DataValue, ...
Impasse asked 6/10, 2022 at 12:18
3
Is it possible to create a pie / donut chart using Apple's new SwiftUI Charts framework?
There are images of a pie chart shown in the WWDC videos. Any help or code sample on how to create the pie c...
Strade asked 16/9, 2022 at 9:35
3
Using the new SwiftUI Charts framework, we can make a chart bigger than the visible screen and place it into a ScrollView to make it scrollable. Something like this:
var body : some View {
Geome...
Plata asked 6/11, 2022 at 10:38
1
Solved
I'm creating a chart in SwiftUI. It's weather related and I have the data successfully displaying. Now, I'm attempting to display the temperature on each symbol in the chart, but it only displays o...
Muzhik asked 7/2, 2023 at 16:23
1
Solved
I have created a chart view like below. I wanted to know how to change the bar mark when user tap on the bar.
Chart {
ForEach(Data.lastOneHour, id: \.day) {
BarMark(
x: .value("Month",...
Verulamium asked 2/1, 2023 at 6:30
3
Solved
Given this is a heart rate chart, I'm trying to make the chart's Y max scale 210 (bpm), e.g. .chartYScale(domain: 0 ... 210) however it only seems to scale correctly if I pass in 200 or 300, anythi...
Dynast asked 7/7, 2022 at 17:58
1
Solved
I have a Swift Chart that can toggle between line and bar marks.
I've added annotations to the top of each mark to display the value for each data point. On the bar chart, the annotations display c...
Fluted asked 11/9, 2022 at 5:56
1
Solved
I've got this very simple chart, nothing fancy - just takes up stock indicator prices and shows them.
VStack {
Chart {
ForEach(viewmodel.chartData1) { chartData in
LineMark(x: .value("date...
Accouplement asked 9/9, 2022 at 9:49
1
Solved
I have a Chart with WeatherKit.HourWeather objects spanning over multiple days on the x axis. However, I want to exclude the nighttime hours. It looks like I can do this with the chartXScale modifi...
Nb asked 28/8, 2022 at 9:35
2
Solved
I'm trying to add axis unit labels to a chart built with Swift Charts.
For example:
import SwiftUI
import Charts
struct ContentView: View {
struct ChartData: Identifiable {
var id: Double { xV...
Kleeman asked 6/7, 2022 at 6:59
1
© 2022 - 2024 — McMap. All rights reserved.