Re: NSTextView and the Text to Speech system shortcut
Re: NSTextView and the Text to Speech system shortcut
- Subject: Re: NSTextView and the Text to Speech system shortcut
- From: "I. Savant" <email@hidden>
- Date: Mon, 14 Jan 2008 11:01:43 -0500
> Would anyone be able to tell me what message is called on what object
> when that shortcut is used, or if the system is handling it entirely?
> I'd like to be able to override the command coming from there as well.
See "NSSpeechSynthesizer". Searching the API reference for "speak"
revealed this as the most likely candidate. There aren't many methods
and it looks fairly straightforward ...
Since services work on the selected text of whatever control
currently has focus, it's unlikely you'll be able to catch this
without a hack. Both NSTextView and this service likely create a
speech synthesizer with the default voice and hand it the selection
(or in the case of NSTextView, the entire text if there is no
selection) as a string to speak.
--
I.S.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden