Re: Word breaks ?
Re: Word breaks ?
- Subject: Re: Word breaks ?
- From: Ondra Cada <email@hidden>
- Date: Thu, 2 May 2002 17:32:43 +0200
On Thursday, May 2, 2002, at 04:21 , RFM wrote:
I haven't been able to find any Cocoa API calls related to word
breaks in a block of text in either NSLayoutManager, NSTextContainer, or
NSTextStorage. I'm trying to get the fragment rectangle for each word in
a block of text without having to scan for blanks in the text or
accumulate rectangles on a character basis. Is there anything available
that allows for obtaining the 'NSRange' of a word(s) in the text and
then from there getting the surrounding rectangle(s) of the word ??
What about +[NSCharacterSet letterCharacterSet] and either NSScanner, or
just plain ole rangeOfCharacterFromSet:? Works perfectly for me.
---
Ondra Hada
OCSoftware: email@hidden
http://www.ocs.cz
2K Development: email@hidden
http://www.2kdevelopment.cz
private email@hidden
http://www.ocs.cz/oc
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.