Re: NSTableview background image for column?
Re: NSTableview background image for column?
- Subject: Re: NSTableview background image for column?
- From: Izak van Langevelde <email@hidden>
- Date: Sat, 24 Apr 2010 15:52:24 -0400
The table shows a so-called 'exposure sheet' for an animation, where each row corresponds to one frame, and the columns correspond to the various foreground and background animation layers. There is one column for audio, and for synchronization purposes it is nice to show a wave form of the audio. However, the waveform is fixed, i.e. not editable, so adding and deleting table rows only affects the position fn table rows with respect to the audio: the audio is background, both as audio and as picture. Columns are not sortable, although it would be nice to be able to reorder them.
So, 'slicing' the wave form to fit the cells of the audio column will do, but then removing/reordering/adding a row from the table means that lots of cell images need to be shuffled to restore the audio track.
On 2010-04-24, at 2:44 PM, Andy Lee wrote:
> What about a custom table cell whose draw method draws the appropriate subrectangle of the image? Would that work? You might have to work around the table's intercellSpacing so there aren't breaks in the image.
>
> What's in this image anyway? I'm having a hard time imagining an app that would use a table column this way. Are the columns of your table sortable, and if so, does the image remain the same?
>
> --Andy
>
>
> On Apr 24, 2010, at 2:28 PM, Izak van Langevelde wrote:
>
>> An NSTableView needs a column with one single image, spanning the entire column.
>>
>> I have got this working by setting as the background colour of the NSTableView a pattern, consisting of the background image, scaled big enough so it does not tile. However, this is somewhat limiting with respect to column reordering and resizing.
>>
>> I considered using an NSImageView next to theNSTableView within the same NSScrollView, or making a table cell span all rows, but each of these has its own problems.
>>
>> Any suggestions on how to improve?
>>
>> Regards,
>> Izak
>> ---
>> Grinnikend door het leven...
>
>
---
Grinnikend door het leven...
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden