Re: Custom NSTextView used as field editor doesn't support spoken keystrokes by VoiceOver
Re: Custom NSTextView used as field editor doesn't support spoken keystrokes by VoiceOver
- Subject: Re: Custom NSTextView used as field editor doesn't support spoken keystrokes by VoiceOver
- From: Daniel Schwill <email@hidden>
- Date: Thu, 8 Nov 2007 19:01:07 +0100
Hello James,
On 07.11.2007, at 23:43, James Dempsey wrote:
Daniel,
A few questions:
1. Is this NSTextView subclass being used in a cell in a table view
or outline view?
I use this NSTextView as the field editor for two NSTextFields as
well as directly as a text view (subview) in a plain view. It works
perfect directly used in the view, but doesn't work used in the
NSTextFields.
2. Could you run your app with the argument -
NSAccessibilityDebugLogLevel 1 and see if there are any errors
logged when you edit the field with VoiceOver running? Any output
would be helpful.
I ran the app with the argument -NSAccessibilityDebugLogLevel 1, but
there were no errors logged when I edited the field with VoiceOver
running.
3. What is the basic gist of the changes you've made to the
NSTextView? It may be you've overridden something that normally
sends an AX notification.
I've overridden some methods from NSResponder like insertText:,
moveUp:/-Down:/-Left:/-Right:, insertTab:/-Backtab: or paste: for
example to archive a special behavior of the field editor.
As mentioned above my custom NSTextView works fine with VoiceOver
when it is used directly as a text view in a plain view, but doesn't
work when it is used as a field editor for a text field.
Are there any additional steps needed when I create and use a custom
NSTextView as a field editor for a text field?
I'm currently using - (NSText *)fieldEditor:(BOOL)createFlag
forObject:(id)anObject of NSWindow to create and return my custom
NSTextView.
The code looks like this:
- (NSText *)fieldEditor:(BOOL)createFlag forObject:(id)anObject
{
if ([anObject isKindOfClass:[NCTextField class]])
{
if (textFieldEditor == nil && createFlag)
{
NCTextFieldEditor *newTextFieldEditor = [[NCTextFieldEditor
alloc] initWithFrame:NSZeroRect];
[newTextFieldEditor setRichText:YES];
[self setTextFieldEditor:newTextFieldEditor];
[newTextFieldEditor release];
}
return textFieldEditor;
}
return [super fieldEditor:createFlag forObject:anObject];
}
Regards,
Daniel
On Nov 6, 2007, at 2:08 AM, Daniel Schwill wrote:
Hi,
I'm using a custom NSTextView as the field editor for two fields
in my app, but VoiceOver doesn't speak the keystrokes when editing
these fields.
Any hints why this doesn't work with my custom NSTextView?
Is something missing in my custom NSTextView to support spoken
keystrokes by VoiceOver?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Accessibility-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden