Transparent background WKWebView (NSView)

后端 未结 5 1626
野性不改
野性不改 2021-02-08 12:27

I am building a Mac application using Swift. Therefor, I want to make a WKWebView transparent, so it shows the text of the loaded HTML, but the background of my underlaying NSWi

5条回答
  •  星月不相逢
    2021-02-08 13:13

    It was not supported, then they fixed it:

    https://bugs.webkit.org/show_bug.cgi?id=134779

    The way to make it transparent is to:

    myWebView.opaque = false
    

提交回复
热议问题