FROM : I. Savant
DATE : Sun Feb 24 21:20:23 2008
> When I use [NSTextView insertText:@"Lyrics Code Here"];, it doesn't
> delete the current text so that is it is replaced for the user...
Why would you believe "insert" means anything but? If you read the
documentation on the text system, you'll get a better idea of where to
look for more answers.
You can ask the text view for its NSTextStorage (which is a
subclass of NSMutableAttributedString) and replace the contents with -
replaceCharactersInRange:withString: or -
replaceCharactersInRange:withAttributedString:
--
I.S.
DATE : Sun Feb 24 21:20:23 2008
> When I use [NSTextView insertText:@"Lyrics Code Here"];, it doesn't
> delete the current text so that is it is replaced for the user...
Why would you believe "insert" means anything but? If you read the
documentation on the text system, you'll get a better idea of where to
look for more answers.
You can ask the text view for its NSTextStorage (which is a
subclass of NSMutableAttributedString) and replace the contents with -
replaceCharactersInRange:withString: or -
replaceCharactersInRange:withAttributedString:
--
I.S.
| Related mails | Author | Date |
|---|---|---|
| Jeremy | Feb 24, 20:43 | |
| Gary L. Wade | Feb 24, 21:16 | |
| I. Savant | Feb 24, 21:20 | |
| Jeremy | Feb 24, 21:23 | |
| I. Savant | Feb 24, 21:28 | |
| I. Savant | Feb 24, 21:30 | |
| I. Savant | Feb 24, 21:33 | |
| Jeremy | Feb 24, 21:34 | |
| I. Savant | Feb 24, 21:38 | |
| Jeremy | Feb 24, 21:44 |






Cocoa mail archive

