Re: Button label and Orca



John,

Sorry that didn't work for you.  I forgot that i was working with a the
drop-down menu part of a MenuToolButton.

Here is some code (gtk#) that should at least make your button
accessible:

// button
Button plusButton = new Button("+");
     	
// create a new label with the text we want read
Label l = new Label("Hello World");

// create relationships between the button and the new label
l.Accessible.AddRelationship(Atk.RelationType.LabelFor,
plusButton.Accessible);
plusButton.Accessible.AddRelationship(Atk.RelationType.LabelledBy,
l.Accessible);

With this code you will see a button labelled "+", but Orca will read
"Hello world plus button."  The screen reader still reads the "+", but
it should at least make the button accessible.  I didn't see an obvious
way to have the screen reader not read the "plus."

Hope that helps,
Brian G. Merrell

>>> On Sat, Mar 15, 2008 at  6:28 AM, in message
<1205584094 5799 1 camel wendell-laptop>, Jonh Wendell
<jwendell gnome org>
wrote: 
> Em Sex, 2008-03-14 às 22:59 -0600, Brian Merrell escreveu:
>> I was trying to figure this out a few weeks ago.  Try calling the
set 
> description method instead of the set name method.  Orca reads the 
> description.
>> 
>> Brian G. Merrell
> 
> I was already setting the description... No luck. It insists in
reading
> the label :(
> 
> 
>> >>> On Fri, Mar 14, 2008 at  9:02 PM, in message
>> <1205550142 25706 5 camel wendell-laptop>, Jonh Wendell
<jwendell gnome org>
>> wrote: 
>> > Hi, folks.
>> > 
>> > I have a button with the label "+". Its A11y name -  set with
>> > atk_object_set_name() -  is "Increase Volume", but Orca insists
in
>> > reading "plus button".
>> > 
>> > Isn't A11y name preferable over the label text?
>> > 
>> > Looking at gail, gail_button_get_name() is correct. I don't know
if Orca
>> > uses this...
>> > 
>> > Am I doing something wrong?
>> > 
>> > Thanks,
>> 
>> 
> -- 
> Jonh Wendell
> www.bani.com.br



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]