Draw a sphere: Difference between revisions

m (→‎{{header|Raku}}: Fix comment: Perl 6 --> Raku)
Line 4,609:
 
var s = Sphere(frame: CGRectMake(0, 0, 200, 200))
</lang>
 
In SwiftUI:
<lang Swift>
struct ContentView: View {
 
var body: some View {
 
let gradient = RadialGradient(gradient: Gradient(colors:[.white, .black]),
center: .init(x: 0.4, y: 0.4), startRadius: 10, endRadius: 100)
return Circle()
.fill(gradient)
.frame(width: 200, height: 200)
 
}
}
</lang>