当前位置: 动力学知识库 > 问答 > 编程问答 >

osx - Unified NSToolBar/Titlebar with icons and labels?

问题描述:

Our designer wants a unified toolbar/titlebar (such as what Safari, XCode, et. al use) but wants labels under the icons. I have the display mode on my NSToolbar set to IconAndLabel but I still only get icons... if I do separate title and toolbars the labels show up.

I've found nothing in the docu or even via googling that suggests you're forced into icon-only view but that seems to be the case. What's the best way to get labels on these buttons? I want to avoid putting the labels in my image assets as that will complicate localization, so if that's the only choice I'd have to do it programmatically using a localized string.

网友答案:

As far as I know there is no way of having both the new unified toolbar and labels. Maybe you could put a bar under the toolbar that contains the labels, aligned perfectly to the images.

But do you really need the labels? Apple is trying get rid of them with the new toolbar design. Try to make your icons as self-explanatory as possible. Don't forget that there are tool tips available as well for the button titles..

分享给朋友:
您可能感兴趣的文章:
随机阅读: