开发者

How can I display an Image in an NSTableView?

I have an NSTableView that is populating with my data source.

My data model has a URL to an image.

I would like to display an image next to some text in every cell of my NSTableView. Basically like a twitter client, image on th开发者_JS百科e left, with some text on the right.

I am not sure how to do this Cocoa? I am familiar with the process in Cocoa-Touch (by subclassing UITableViewCell).


You should drag NSImageCell onto the column you want your image to be displayed. Then adjust the value of the image via image cell bindings pane.


You can create a frame on each cell, and draw a picture in that. Refer here:

http://blog.webscale.co.in/?p=284

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜