Sitemap
Mobile App Development Publication

Sharing iOS, Android and relevant Mobile App Development Technology and Learning

Learning iOS

Rendering System Images in SwiftUI

5 min readMar 1, 2024

--

SF Symbol Images
layer representation in system images
Without Rendering mode all layers are black
//We will use this example
struct ContentView: View {
var body: some View {
ZStack {
RadialGradient(gradient: Gradient(colors:[ .orange, .pink]), center: .top, startRadius: 50, endRadius: 900)
.ignoresSafeArea()
HStack(spacing: 10) {
Image(systemName: "cloud.rainbow.half.fill")
Image(systemName: "thermometer.sun.fill")
Image(systemName: "cloud.sun.rain.fill")
}
//1.
// .symbolRenderingMode(.multicolor)
//2.
// .foregroundStyle( Color.green,Color.black,Color.blue)

.font(.system(size: 60))
}
}
}
struct ContentView: View {
var body: some View {
ZStack {
RadialGradient(gradient: Gradient(colors:[ .orange, .pink]), center: .top, startRadius: 50, endRadius: 900)
.ignoresSafeArea()
HStack(spacing: 10) {
Image(systemName: "cloud.rainbow.half.fill")
Image(systemName: "thermometer.sun.fill")
Image(systemName: "cloud.sun.rain.fill")
Image(systemName: "humidity.fill")
}
// .symbolRenderingMode(.multicolor)
//2.
.foregroundStyle(Color.purple,Color.green,Color.yellow)
.font(.system(size: 60))
}
}
}
symbolrenderingmode generated by foregroundstyle API

--

--

Mobile App Development Publication
Mobile App Development Publication

Published in Mobile App Development Publication

Sharing iOS, Android and relevant Mobile App Development Technology and Learning

Balraj Verma
Balraj Verma

Written by Balraj Verma

Share What I Learn 😊 | Mobile Developer

Responses (1)