Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Luca Saiu
Hello.

On 2015-04-13 at 21:21, Sam Spilsbury wrote:

> I initially thought you could probably hook into the function where
> text is rendered[1], but I don't know if that's exactly what you want.

I've looked there, but I don't think that's the right place either.  We
have to notify the accessibility bus that the text is changed when it
does.

> That said, I'm sure they all follow the same logic. Perhaps its a
> candidate for refactoring into a utility function in the text plugin,
> which can also emit such a signal?

If that's the clean way to do it, sure.  I'm asking to the Orca people
as well.

Thanks,

-- 
Luca Saiu
Hypra team (Accessible website in construction)
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Luca Saiu
Hello Samuel.

On 2015-04-13 at 15:44, Samuel Thibault wrote:

>  The screen-reader side of the discussion would then
> probably be the orca devel mailing list.

Thanks.  I'll write to the Orca list.

-- 
Luca Saiu
Hypra team (Accessible website in construction)
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Luca Saiu
Hello.

On 2015-04-13 at 09:25, Stephen M. Webb wrote:

> The
> preferred option would be to provide a
> separate plugin that performs the TTS as appropriate, and that plugin can pull
> in whatever evil necessities it wants.

Yes, this is very reasonable.

Speaking of that, is there an example in Compiz of conditional code
behaving differently when another module is loaded?  This would be
something like an optional module dependency.

If this were the route to follow then the code in
plugins/text/src/text.cpp would call the accessibility plugin if
enabled, and do nothing new if disabled.

Thanks,

-- 
Luca Saiu
Hypra team (Accessible website in construction)
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Luca Saiu
Hello.

On 2015-04-13 at 16:14, MC Return wrote:

> Have you tried to activate this option to see
> if it fixes your problem ?

I've tried it on the Application Switcher plugin; as far as I can see the
option is not available on the other switchers.

Anyway unfortunately no, vocalization doesn't happen until switching is
over and the selected window actually rises.  I was thinking that the
window decorator was responsible for vocalizing the title but now I see
that that's is not the case -- disabling emerald didn't change the
behavior.

Focus on Switch doesn't seem to have any effect with respect to title
vocalization.

> If the window title is vocalized after switching it probably is a reaction
> to the focus change and thus the functionality to trigger vocalization is
> already there

That's encouraging; things would be much simpler if it could be done
that way.  Worth investigating.

Thanks,

-- 
Luca Saiu
Hypra team (Accessible website in construction)
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread MC Return

On 04/13/2015 04:10 PM, MC Return wrote:

On 04/13/2015 03:10 PM, Luca Saiu wrote:

On 2015-04-13 at 15:05, Luca Saiu wrote:


I was initially surprised after discovering that the window title is not
drawn with GTK

Just to make this clear, the window title is vocalized *after* switching
window, but that's too late.  A blind user will want to cycle among the
open windows one by one before choosing one.

Thanks,

If the window title is vocalized after switching it probably is a 
reaction to the focus change and thus the functionality to trigger 
vocalization is already there - the solution would then be to simply 
add an option to change the focus on window selection, which the 
switcher plugin already has integrated (Focus On Switch). Have you 
tried to activate this option to see if it fixes your problem ?


Greetinx,
MC Return


___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Luis González
A curious thing:
In compiz v0.8.*, the screen reader correctly vocalizes the window
title. Maybe it would be an starting point, wouldn't it?

2015-04-13 8:55 GMT-04:30, Stephen M. Webb :
> On 15-04-13 09:05 AM, Luca Saiu wrote:
>>
>> While playing with Compiz window switchers (there are several) I noticed
>> that the selected window name is displayed but not vocalized by the
>> screen reader.
>>
>> I was initially surprised after discovering that the window title is not
>> drawn with GTK; but I understand that Compiz itself does not actually
>> depend on GTK --- only the GTK window decorator and CCSM use it.  So
>> Compiz renders text using Cairo on top of an OpenGL surface, which is
>> all very reasonable.
>>
>> In this situation, what's the cleanest way of making the selected window
>> title accessible?  Is there an easy way of using ATK without making a
>> GTK label just for the purpose, or should I try some other route?
>
> I'm not sure if we want to start dragging all kinds of external dependencies
> into many generic plugins, especially
> massive foreign libraries like those from the Glib family (eg. ATK).  The
> preferred option would be to provide a
> separate plugin that performs the TTS as appropriate, and that plugin can
> pull in whatever evil necessities it wants.
>
> --
> Stephen M. Webb  
> ___
> compiz mailing list
> [email protected]
> http://lists.freedesktop.org/mailman/listinfo/compiz
>


-- 
Salu2
Luis F. González V.
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Stephen M. Webb
On 15-04-13 09:05 AM, Luca Saiu wrote:
> 
> While playing with Compiz window switchers (there are several) I noticed
> that the selected window name is displayed but not vocalized by the
> screen reader.
> 
> I was initially surprised after discovering that the window title is not
> drawn with GTK; but I understand that Compiz itself does not actually
> depend on GTK --- only the GTK window decorator and CCSM use it.  So
> Compiz renders text using Cairo on top of an OpenGL surface, which is
> all very reasonable.
> 
> In this situation, what's the cleanest way of making the selected window
> title accessible?  Is there an easy way of using ATK without making a
> GTK label just for the purpose, or should I try some other route?

I'm not sure if we want to start dragging all kinds of external dependencies 
into many generic plugins, especially
massive foreign libraries like those from the Glib family (eg. ATK).  The 
preferred option would be to provide a
separate plugin that performs the TTS as appropriate, and that plugin can pull 
in whatever evil necessities it wants.

-- 
Stephen M. Webb  
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Sam Spilsbury
Hey Luca

On Mon, Apr 13, 2015 at 9:10 PM, Luca Saiu  wrote:
> On 2015-04-13 at 15:05, Luca Saiu wrote:
>
>> I was initially surprised after discovering that the window title is not
>> drawn with GTK
>
> Just to make this clear, the window title is vocalized *after* switching
> window, but that's too late.  A blind user will want to cycle among the
> open windows one by one before choosing one.
>

That's an interesting question, since I suppose the text plugin (which
handles the drawing of the text for all switchers except
staticswitcher and the normal switcher) wasn't really written with
this in mind.

I imagine the end-goal here would probably be to find out when a
switcher intends to display text and then emit a signal of some sort
using d-bus.

I initially thought you could probably hook into the function where
text is rendered[1], but I don't know if that's exactly what you want.
Plugins can pre-render the texture containing the text at any time,
but its up to them to draw it on-screen.

That said, I'm sure they all follow the same logic. Perhaps its a
candidate for refactoring into a utility function in the text plugin,
which can also emit such a signal?

Sam.

[1] 
http://bazaar.launchpad.net/~compiz-team/compiz/0.9.12/view/head:/plugins/text/src/text.cpp#L370
[2] 
http://bazaar.launchpad.net/~compiz-team/compiz/0.9.12/view/head:/plugins/text/src/text.cpp#L481

> Thanks,
>
> --
> Luca Saiu
> Hypra team (Accessible website in construction)
> ___
> compiz mailing list
> [email protected]
> http://lists.freedesktop.org/mailman/listinfo/compiz



-- 
Sam Spilsbury
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Accessibility of Cairo/OpenGL text: ATK without GTK?

2015-04-13 Thread Luca Saiu
On 2015-04-13 at 15:05, Luca Saiu wrote:

> I was initially surprised after discovering that the window title is not
> drawn with GTK

Just to make this clear, the window title is vocalized *after* switching
window, but that's too late.  A blind user will want to cycle among the
open windows one by one before choosing one.

Thanks,

-- 
Luca Saiu
Hypra team (Accessible website in construction)
___
compiz mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/compiz