Closed iamgp closed 10 years ago
In fact, what's the best way to create our own style for the listitem?
Even though I have this in IB:
I get this when I run the app (I fixed the error i was getting):
(The height is normal height, not my higher height, and positioning is off)
Thanks
Is the Source List being correctly sized in its parent view in Interface Builder?
Yes.
On Fri, Sep 5, 2014 at 3:21 AM, Alex Rozanski notifications@github.com wrote:
Is the Source List being correctly sized in its parent view in Interface Builder?
Reply to this email directly or view it on GitHub: https://github.com/Perspx/PXSourceList/issues/47#issuecomment-54574381
It must be something to do with the height of the row.
If I have this in IB:
I still get this in the app:
Why:
textField
outlet? If so, I believe that NSTableCellView will automatically position the text field for you (as well as applying the correct styling).-setRowHeight:
methodOk, so I got it working.
For future reference (mostly for myself!), you can either set all row heights by:
[self.sourceList setRowSizeStyle:NSTableViewRowSizeStyleCustom];
[self.sourceList setRowHeight:40.0];
or dynamically by calling, then following the same stuff as the example using [aSourceList levelForItem:item]
:
- (CGFloat)sourceList:(PXSourceList *)aSourceList heightOfRowByItem:(id)item
Thanks for your help.
No worries. Glad you got it sorted!
Is there an easy way to remove the icon for the list item? I've tried creating my own listitem subclass but can't seem to get it right!
Thanks.