NSToolbarItem必须调整NSButton的大小

ego*_*dan 10 macos xcode macos-sierra xcode8

我正在尝试添加带纹理的圆形按钮NSToolbar.我使用Interface Builder添加NSButton到允许的工具栏项和默认项.

我正在使用window!.titleVisibility设置为的Safari样式工具栏.hidden.

Xcode 8打印此错误消息:

NSToolbarItem (<NSToolbarItem: 0x100c24000>) had to adjust the size of
<NSButton: 0x100c36690> from {43, 25} to {45, 27} as the height is expected to be
27.000000. Make sure that this toolbar item view has a valid frame/min/max size.
Run Code Online (Sandbox Code Playgroud)

这在以前的OS X版本中对我有用.

我尝试将最小和最大工具栏项高度设置为27,但Xcode会自动将最小值恢复为25.