Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[solved] my text goes under a the scrollers....



Ok I solved by self... sorry
I used contentSizeForFrameSize method!

Bye &thks
Andrea


Inizio messaggio inoltrato:

Da: Andrea Salomoni <email@hidden>
Data: 09 febbraio 2006 14:24:06 GMT+01:00
A: email@hidden
Oggetto: my text goes under a the scrollers....

Hi to all,

I created an NSScrollView and a NSTextView programmatically in this way:

NSScrollView *scrollview = [[NSScrollView alloc]
            initWithFrame:cFrame];
	NSSize contentSize = [scrollview contentSize];
	[scrollview setBorderType:NSNoBorder];
	[scrollview setAutohidesScrollers:YES];
	[scrollview setBorderType:NSBezelBorder];
	[scrollview setHasVerticalScroller:YES];
	[scrollview setHasHorizontalScroller:NO];
	[scrollview setAutoresizingMask:NSViewWidthSizable |
		NSViewHeightSizable];
	[startTab setView:scrollview];

// create the textview
	chatView = [[URLTextView alloc] initWithFrame:[scrollview frame]];
	// textView conf
	[chatView setEditable:YES];
	
	[[chatView textContainer]
            setContainerSize:NSMakeSize(contentSize.width, FLT_MAX)];
	[[chatView textContainer] setWidthTracksTextView:YES];
	[chatView  setFrame:[scrollview frame]];
	[scrollview setDocumentView:chatView];

But when I type some text my lines finish always under the scroller.... How can I do to stop the typing and force return?

Thank you all
Andrea
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/tech% 40metagraphics.it


This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/email@hidden

This email sent to email@hidden
References: 
 >my text goes under a the scrollers.... (From: Andrea Salomoni <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.