How to apply .italic() to .largeTitle Font?

五迷三道 提交于 2020-05-09 08:15:33

问题


import SwiftUI
import PlaygroundSupport

struct ContentView: View {

    var body: some View {

        VStack {
            ForEach(Font.TextStyle.allCases, id: \.self) { style in
                Text(self.describe(style: style)).font(.system(style)).italic()
            }
        }
    }
    func describe(style: Font.TextStyle) -> String {
        var s: String = ""
        print(style, terminator: "", to: &s)
        return s
    }
}

PlaygroundPage.current.setLiveView(ContentView())

produce

is it a bug or I missed something?


回答1:


Final answer from Apple

Resolution:Investigation complete - Works as currently designed

Have a lot of fun with Apple ...



来源:https://stackoverflow.com/questions/59640260/how-to-apply-italic-to-largetitle-font

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!