I liked the segmented Picker that I added to my precipitation chart so much that I used one to create a new "feels like" variation of the temperature chart.
But looks what happens with 24 entries and VoiceOver grouping entries together. VoiceOver is just saying "symbol" as if the SF Symbol was not there at all.
Today I started the short video series about #SwiftCharts by @StewartLynch
I finished the first one and nearly the second one that I will finish tomorrow. Also tomorrow I wanne try to code a LineMark chart because I have an app idea and for that I wanna use a LineMark chart. So far all the tutorials I found were for BarMarks but as I learned so far work most of the charts pretty similar. #Swift#SwiftUI#iOSDev
Surprised to see that in the iOS Weather app when you are using the largest accessibility text size the chart legend shows the large text, but each axis of the chart retains very small text.
I was talking with @Drwave in December about adding symbols to this chart to indicate the precipitation type and I just got it working for the first time!
I would be nice if I could get the symbols to appear above the chart instead of inside it, but at least I'm making progress.
Spent FAR too much time today wrangling with KeyValuePairs trying to get my chart legends looking like I want and was getting nowhere.
After doing more searches I finally found a StackOverflow post that made me realize that there are alternatives that don't use KeyValuePairs that let me build the legend dynamically.
I can't believe I didn't think of that. Now the legend only shows the precipitation types that are in the chart.
I have a SubView that shows a Swift Chart. The data passed to the chart is a let constant. In the onAppear for the chart I calculate some PointMarks to show.
Hours later when the chart's data changes the chart DOES update but the PointMarks do NOT.
I honestly thought that it was going to be simple adding PointMarks for high and low temperatures to this chart. I keep finding things that are making this challenging.
I realized that on a very hot day the "H" in the high PointMark is pushing the max of the chart to be 150F. That makes the "hot" color less intense since 150 is where it's the strongest.
Now I'm experimenting with putting the "H" below the PointMark for hotter temps.
The formula to make me nervous is new feature + iPhone SE + German + the largest accessibility text size.
Testing is going great and I'm really happy with how this new chart for @PleaseDontRain is looking. I'm so glad that we have Swift Charts now and don't have to make things like this ourselves anymore.
Also shoutout to @natpanferova for another great blog post about creating this chart.
The iPhone SE and the largest accessibility text sizes have not defeated me! I think I've finally got a chart I'm happy with concerning axis sizes and the popover. Thanks @ryanlintott !
One thing that I've noticed is that when I'm using my app to track a day I still found myself going to another weather app to look at the temperatures throughout the day.
Why not add that below the precipitation chart? And the popover that iOS 17 adds will let me show details about the hour.
Still very rough but I already like how it's progressing.
Last summer I experimented with adding a "lollipop" popover to my charts in Foodlapse but the implementation was kind of clunky/painful.
Now the functionality is built-in to Swift Charts and is a delight to use. I've already got this basic version implemented for my hourly precipitation charts.
I watched the WWDC video about interactivity with Swift Charts (very cool) but I'm confused about their example for selection. This raw selected date seems like something that would only be used by this View. Why is it a @\Binding instead of a @\State?
Some progress on next #Pipilo update. Added a way to view hashtag timelines with follow/unfollow action.
Video of Pipilo application where I view posts with #Swift hashtag, then navigate to #SwiftCharts. Video displays how navigation between posts work with horizontal swipes like in rest of the app. It also displays that there are actions to follow/unfollow hashtag or view timeline in browser.
I had a hunch that I could take on tasks that I used to do with Python + matplotlib + Jupyter with Swift Charts + SwiftUI + Playgrounds instead. But I had no idea it’d be this nice and easy. Plus I find the default result better looking and I have much more control over everything around the chart, like labels, titles etc.
This will change everything for me when working with charts.
Since people asked, I’ve posted the self-contained example as a gist on Github and added a button to export the page as a PDF. Works wonderfully, even from within a simple playground 🎉
NB: the PDF is not rasterised - you can select the text and zoom in without any loss of fidelity.