Complications are bits of watchOS application that can be put on the user's watch face and offer quick information, simply by looking at his/her Apple Watch, without opening the accompanying watchOS/iOS app. The Apple Watch ships with some default complications: Calendar, Weather, Activity, Battery (it shows only the watch’s battery level), etc.
There are 5 complication families. This article will show how to make 7 types of complications, from each complication family. 2 of the shown complications are only available in watchOS 5, and only on the Apple Watch Series 4 and up.
Recently, I had the chance to play with watchOS complications. This led me on a learning path.
There is a goodie at the end of the article :)
Before starting, I would like to point out a series of links that turned out to be useful on the subject of watchOS complications:
The center text is the text that will be in the "middle" of the ring.
The leading text will be in the bottom left of the ring, while the trailing text will be in the bottom right.
The gauge can be either filled-style or ring-style. In the above example, the ring-style is chosen. Depending on the start date and the end date provided, it will have a small circle that will move along the gauge.
The gaugeColors parameters has to be given an array of colors. If you provide gaugeColorLocations with a nil value, watchOS will place the colors in an even out manner.
let utilitarianSmall =CLKComplicationTemplateUtilitarianSmallRingText()
This complication is very similar to set up like the Circular Small one.
The examples show how to make a complication for only 7 out of the 11 types of complications.
Keep in mind that each complication has other possibilities to show the information — instead of a closed/open ring, one could only show text or only an image.
At the end
We gather all the complications available in one cheat sheet to make it easier to have an overview over the many complications that Apple has to offer.
You can find the name of the complication and links to Apple's documentation.
You can get the cheat sheet here
Swift Package Manager plugins are a great way of automating tasks, like, enforcing code conventions and style.
In this tutorial we're going to learn what are package plugins and implement 2 plugins; one that outputs code statistics and another that genera...
Hi, this is Bitcoin and from now on it will live with us!
Traditional money has long been outdated and is gradually losing its popularity.
In most cases, we already use electronic money.
But e-money is not much different from cash, except in form, but the...