按钮图标:圆形关闭图标
我见过其他应用程序使用圆形图标来关闭视图。我发现的唯一类似的图标是 UIBarButtonSystemItemStop。但这仅呈现一个旋转的十字,周围有边框(与按钮一样)。
我宁愿拥有类似 UIButtonTypeInfoLight
的东西。如果使用此按钮,则看不到边框。该图标也是一个圆形灰色图标,其中有一个符号(此处为 i 符号)。还有更多这种风格的图标可用吗? UIBarButtonSystemItem
和 UIButtonType
都没有提供这一点。
我还看到了 UIButtonTypeInfoLight
风格的雷电图标。这些图标是自己做的吗?如果是,如何将它们包含在内以使边框不可见?
I've seen other apps are using a round icon for closing a view. The only similar icon I found is UIBarButtonSystemItemStop
. But this presents only a rotated cross with a border (as always with buttons) around it.
I rather would like have something like a UIButtonTypeInfoLight
. If this button is used, no border is visible. Also the icon is a round grey icon with a symbol (here i symbol) in it. Are there further icons in this style available? Neither UIBarButtonSystemItem
nor UIButtonType
is offering that.
I have also seen a thunderbolt icon in the style of UIButtonTypeInfoLight
. Are these icons self made? If yes, how are they included so that no border is visible?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这些按钮是自定义的。
您可以使用
[UIBarButtonItem initWithCustomView:]
将任何自定义视图嵌入到栏中。您可以将
UIButton
与UIButtonTypeCustom
类型一起使用,以便获得没有边框的按钮。还将showsTouchWhenHighlighted
设置为YES
,以便该按钮像信息按钮一样发光。These buttons are custom.
You can embed any custom view into bar using
[UIBarButtonItem initWithCustomView:]
.You can use
UIButton
withUIButtonTypeCustom
type so that you have button with no border. Also setshowsTouchWhenHighlighted
toYES
so that button glows like info button.