Re: NSScrollView & its width
Re: NSScrollView & its width
- Subject: Re: NSScrollView & its width
- From: Ken Thomases <email@hidden>
- Date: Sat, 6 Feb 2010 10:20:45 -0600
On Feb 5, 2010, at 5:27 PM, Knut Lorenzen wrote:
> Am 05.02.2010 um 01:10 schrieb Mark Sanvitale:
>
> <...>
>
>> (I repeat, this is only a somewhat educated stab-in-the-dark, i.e. I have used NSTextContainer's setWidthTracksTextView method. More informed people should still be encouraged to reply.)
>
> Thanks for your thoughts, Mark.
>
> Settings setWidthTracksTextView to NO works, but after doing that, the NSScrollView (parent of the TextView in question) clips the content to its own width :/
>
> Perhaps there is a good reason that even TextEdit does not support this?
What's the value of the text view's -isHorizontallyResizable/-setHorizontallyResizable: property? In IB, that's on the Size inspector, "Resizable: Horizontally".
I'm no expert in this area, and haven't tested, but it makes sense to me that if that's NO, then the text view won't claim to be as wide as the widest picture. Also, set its maximum width to something large, possibly the unlimited value that is the default for the maximum height.
The problem with that would be that it will probably choose to not wrap long lines, but just get wider to accommodate them.
Regards,
Ken
_______________________________________________
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