Skip navigation.
 
mlRe: Rotating an NSTableView.
FROM : Michael Nickerson
DATE : Sat May 03 01:53:38 2008

On May 1, 2008, at 8:27 AM, Peter Hudson wrote:
> I have an NSTable View inside an NSSplitView.
> I rotate the table view by sending  rotateByAngle:270  to the 
> enclosing scroll view.
> The table lands up exactly as I want it with vertical rows.


>
>
> The problem is that when I resize the split view the NSTableView 
> does not change size to fit the split view movement as it does when 
> the table is not rotated.
>
> Does anyone have any idea what is going on.  I've tried all the 
> usual games with setting frame and bounds etc - but to no avail.



It looks like there's a bug in NSScrollView, where it stops calling -
tile when it's rotated.

You can work around the problem by listening to the scroll view's 
frame change notifications, and calling -tile on it manually.


I submitted a bug against this with source code to demonstrate the 
problem: <rdar://5908380>


Corbin - there's also a bug where the table headers aren't drawn 
correctly when it's rotated.  I didn't submit a bug on that one - let 
me know if you'd like me to.  It'd take just a quick edit of the 
sample code I did above to have the table headers showing.


--------------------------------------
Darkshadow
(aka Michael Nickerson)
http://www.nightproductions.net

Related mailsAuthorDate
mlRotating an NSTableView. Peter Hudson May 1, 17:27
mlRe: Rotating an NSTableView. Corbin Dunn May 1, 22:47
mlRe: Rotating an NSTableView. Michael Nickerson May 3, 01:53