开发者

How can i show an NSImage in front of a NSTextFieldCell in a NSTableView

开发者 https://www.devze.com 2023-01-14 03:35 出处:网络
I display a file list and want to show the file icon and editable file name in a NSTableColumn. Also what would be the best way to display an additional NSImage immediately behind the file name (i m

I display a file list and want to show the file icon and editable file name in a NSTableColumn.

Also what would be the best way to display an additional NSImage immediately behind the file name (i mean not adding an additional column at the right side for the sec开发者_运维技巧ond icon).


Okay i found the answer to both questions after 10 more minutes of googling.

Apples sample code:

http://developer.apple.com/mac/library/samplecode/SourceView/Introduction/Intro.html

contains a NSTextFieldCell subclass named ImageAndTextCell which promises to do what i want.

0

精彩评论

暂无评论...
验证码 换一张
取 消