Re: Addressbook style textfield
Re: Addressbook style textfield
- Subject: Re: Addressbook style textfield
- From: Andrew Kazmierski <email@hidden>
- Date: Sat, 06 Mar 2004 09:56:35 -0500
Thanks for the clarification. I'm not missing something simple after
all. :-\ However, I don't have time to wait until Apple releases the
code. I'm going to look into it myself and see if I can get anywhere.
In the mean time, if anyone can provide any assistance, it'd be greatly
appreciated by me and, I'm sure, many others.
Thanks,
Andrew
On Mar 6, 2004, at 6:48 AM, Jeremy Dronfield wrote:
On 6 Mar 2004, at 6:39 am, Andrew Kazmierski wrote:
What I still don't understand is how do you allow a single part of
the text view to be edited without allowing the other parts to be
edited? I'm probably missing something simple here...
No, you're missing something quite complex. It appears that the text
view overrides -mouseDown: and implements text view methods
-selectionRangeForProposedRange: and
-textView:willChangeSelectionFromCharacterRange:toCharacterRange: in
order to validate a selection whenever the user clicks in the view. In
other words, it has to establish whether the user clicked in a
non-editable portion of the view, clicked for the first time in an
editable area, or clicked for the second time in an editable area. It
then has to fix the selected range in order to draw the "raised"
effect.
Until Apple makes the sample code for this type of text view public
(which they surely will, since it's been leaking out via ADC TV)
mimicking this text view behaviour will remain a decidedly non-trivial
task.
-Jeremy
-----------------------------------------------------------
"The man who believes a thing is true because he feels it in his
bones, is not really very far removed from the man who believes it on
the authority of a policeman's truncheon." (E.M. Forster)
-----------------------------------------------------------
email@hidden
theLocustFarm.net:
- fractious fiction at http://freespace.virgin.net/jeremy.dronfield
-----------------------------------------------------------
_______________________________________________
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.
_______________________________________________
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.