纯色背景
Text("我是黄颜色背景")
.background(Color.yellow)
多层次背景颜色
Text("每种颜色大小不一致")
.background(Color.blue)
.frame(width: 300, height: 100)
.background(Color.yellow)
.frame(width: 400, height: 150)
.background(Color.red)
使用图片背景
Text("金克斯的含义,就是金克斯")
.foregroundColor(Color.white)
.font(Font.title)
.padding()
.background(Image("jks").opacity(1))