Nscell Size Not Increasing With Row Height During Text Edit

限于喜欢 提交于 2019-12-25 03:08:49

问题


My NSTableView has variable height rows. The rows correctly resize after an edit of a cell has been completed, and during/after resizing the column/table. The Row also correctly resizes while a user is typing into the text cell.

However, the cell itself does NOT resize during editing to match the height of the row. Does anyone have any ideas on this? In this screenshot one end-edit has occurred already (which is why the text area is larger than 1 line) but there is currently enough text in the cell to account for about 5 lines, thus the height of the row is not matching what should be displayed.


回答1:


Both the textview and the cell have to have their autoresize set if you want them to automatically scale.

It looks like the cells in the Tag Name column are properly set to resize but that either the cell or the textview in the value column has not been. Check the sittings in Interface Builder.



来源:https://stackoverflow.com/questions/7301996/nscell-size-not-increasing-with-row-height-during-text-edit

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