NSOulineView header cell font

跟風遠走 提交于 2019-12-04 05:20:00

问题


I'm trying to reduce the font size of the Header Cell in a NSOutlineView (source-list view-based). The problem is that using IB doesn't work for me (both modifying the font for NSTextField and NSTextFieldCell).

The views are returned by outlineView:viewForTableColumn:item: using makeViewWithIdentifier:owner:

Any ideas?


回答1:


These steps solved the problem.

1) Select the NSOutlineView in IB.

2) In the Size Inspector select Automatic for Size Style. If it is already selected, deselect and select it again (XCode bug?)

Now you can modify the font for the NSTextFieldCell (Header Cells and Data Cells) using IB.



来源:https://stackoverflow.com/questions/9383181/nsoulineview-header-cell-font

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!