我可以删除弹出视图中的箭头吗?
我被要求删除弹出视图的箭头。
- 这是否违反了人机界面准则?
- 在另一个弹出窗口中显示一个弹出窗口是否明智?
- 如果不违反人机界面准则怎么办?
I am asked to removed the arrow of the popover view.
- Is that violating human interface guidelines ?
- Is it wise to show a popover inside another popover ?
- If it is not violating human interface guidelines how to do that ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(7)
对于斯威夫特
For Swift
当然,有很多人对此有要求,特别是当弹出窗口足够大并且箭头指向的点会被遮挡时。
没有任何可用性缺点。
Sure thing, and there is plenty of call for this, specifically when the popover is large enough and the point at where the arrow would point would be obscured.
There's no usability drawback whatsoever.
2012-03-07 人机界面指南,第 14 页隐式禁止省略或删除箭头。 114:“弹出窗口......始终显示一个箭头,指示它出现的位置。”
The omission or removal of the arrow is implicitly banned by the 2012-03-07 Human Interface Guidelines, p. 114: "A popover ... always displays an arrow that indicates the point from which it emerged."
隐藏弹出窗口箭头或将一个弹出窗口显示在另一个弹出窗口中听起来不太明智。我不确定 HIG 是否明确禁止这样做,但无论如何这都是一个可用性缺陷。如果您坚持,您可以绘制自己的无箭头弹出框,或者尝试使用在其顶部组成的某些视图来掩盖箭头。我认为重新考虑用户界面会更好。
Hiding the popover arrow or showing one popover inside another does not sound very wise. I’m not sure if this is explicitly forbidden by the HIG, but it’s a usability drawback anyway. If you insisted you could draw your own arrowless popover or try to mask the arrow using some view composed on the top of it. I think it would be much better to rethink the UI.
只需添加一些糖和 Swifty 代码:
扩展:
用法:
您可以更改变量的名称以满足您的需要。
Just to add some sugar and Swifty the code :
Extension:
Usage:
you can change the variable's name to fits your needs.
popoverMenuViewController?.permissedArrowDirections = []
popoverMenuViewController?.permittedArrowDirections = []