Interface Builder 中的 PNG 透明度
我在 Interface Builder 中添加一个带有透明 PNG(导航栏中的徽标)的图像视图,但透明像素似乎呈现为白色。
我在 Interface Builder 中搜索了 PNG,但没有成功。有什么建议吗?
I'm adding an Image View in Interface Builder with a transparent PNG (A logo in the Navigation Bar) but the transparent pixels seems to render as white..
I searched for PNG in Interface Builder but no luck. any tips?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
确保视图属性的“绘图”部分中的“不透明”复选框未选中,并且背景的不透明度为 0。
Make sure the "Opaque" checkbox in the "Drawing" section of the view attributes is unchecked, and that the background has an opacity of 0.
在 Interface Builder 的 UIButton 中选择图像后,您需要告诉它使用不透明度 (alpha) 为 0 的背景。
After you select your image in a UIButton in Interface Builder, you need to tell it to use a background with 0 opacity (alpha).