开发者

NSTextView does not have rounded corners in spite of using setConerRadius

开发者 https://www.devze.com 2023-03-01 14:47 出处:网络
I h开发者_运维知识库ave NSTextView and need rounded corners for the same. Hence i tried using setCornerRadius and set the value to 10, but i don\'t see the rounded corners in my UI.

I h开发者_运维知识库ave NSTextView and need rounded corners for the same. Hence i tried using setCornerRadius and set the value to 10, but i don't see the rounded corners in my UI. Any ideas?


Try setting it on the NSTextView's layer, not the NSTextView itself.

[[myTextView layer] setCornerRadius:10.0f];
0

精彩评论

暂无评论...
验证码 换一张
取 消