Re: NSWindow in main nib.
Re: NSWindow in main nib.
- Subject: Re: NSWindow in main nib.
- From: Jonathan Hess <email@hidden>
- Date: Thu, 22 May 2008 11:37:51 -0700
On May 22, 2008, at 3:05 AM, email@hidden wrote:
i'm usinf leopard machine.I've found a prooblem in my application,I
clicked on the zoom button of the window in interface builder3.0,Now i
couldn;t open that window and couldn't load at run time.
It sounds like you've run into a bug in IB. When you hit the zoom
button, IB zoomed your window to an incorrect size. You should be able
to fix this by selecting your window in the icon view in IB, and then
using the size inspector to change the size. After you do this, you
should be able to open/edit your window.
Jon Hess
i've set the bold menu item by setting the action addFontTrait in
fontmanager.Now it is working i can give the data's as bold italic
etc in
textView.
I tried to convert it to HTML form by using the code.
NSString * aTitle = @"Sample";
NSArray* excluded = [NSArray arrayWithObjects:
@"doctype",@"p",@"meta",@"xml",@"span", nil];
NSDictionary* attr = [NSDictionary dictionaryWithObjectsAndKeys:
NSHTMLTextDocumentType,
NSDocumentTypeDocumentAttribute,
aTitle, NSTitleDocumentAttribute,excluded,
NSExcludedElementsDocumentAttribute,
[NSNumber numberWithInt:
NSASCIIStringEncoding],
NSCharacterEncodingDocumentAttribute,nil];
NSData* tData = [str dataFromRange: NSMakeRange(0, [str
length])
documentAttributes: attr error: nil];
It giving html code, but it doesn;t giving <B>,<I>,<U> and colour tags
corresponding to the texts in textview.
Another qustion is how can i display this html code in my
textview,I've tried
NSDictionary ** dict = &attr;
NSData* tData = [str dataFromRange: NSMakeRange(0, [str
length])
documentAttributes: attr error: nil];
NSAttributedString *attrString = [[NSAttributedString
alloc]initWithHTML:
tData
documentAttributes: dict];
[[htmlView textStorage] setAttributedString: attrString];
But it also displays the same string not html code.
More speccific
My first question is how can i get underlinetext or italictext to
<u>unerlinetext</u> or <i> italictext </i> etc...
SEcond question is How can write html code to textView?if NSData gives
html code.
Expecting reply.
thanks
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden