[INFORMATION] [TITLE]Untitled [AUTHOR] [COMMENT] [END INFORMATION] [SUBTITLE] 00:00:06.801,00:00:10.945 We're gonna do it from the angle of an assistive technology developer. 00:00:11.51,00:00:15.408 Sometimes applications are almost completely accessible 00:00:15.408,00:00:19.712 as much as the developer could possible do, 00:00:19.712,00:00:22.794 and we need bridge a certain gap, a usability gap. 00:00:22.794,00:00:26.513 And we do this by modifying the assistive technology 00:00:26.579,00:00:30.542 for that specific application and making sure that it really is usable. 00:00:30.605,00:00:32.942 First wer'e going to run Orca. 00:00:35.333,00:00:39.159 "Welcome to Orca. Orca screenreader/magnifier frame". 00:00:40.647,00:00:45.269 Notice that we are using XTerm to execute commands 00:00:45.269,00:00:49.520 and recieve debugging input. Xterm is inaccessible. 00:00:49.520,00:00:59.817 This is useful to avoid cyclical events. 00:00:59.923,00:01:04.626 Xterm's limitation is our advantage. 00:01:04.626,00:01:09.540 Now we are going to run a dialog, 00:01:09.699,00:01:13.820 And this is probably what we would usually get if we were 00:01:13.820,00:01:21.588 working at the desktop and we needed to know something important 00:01:21.535,00:01:22.909 that the computer would want to tell us. 00:01:22.962,00:01:24.962 This is what it would sound like, or look like: 00:01:24.962,00:01:29.198 "Information: Your 90 day trial license for the GNOME desktop has expired." 00:01:29.198,00:01:32.315 "Please purchase a boxed version from your local software retailer." 00:01:32.315,00:01:33.583 "'Close' button" 00:01:34.218,00:01:37.599 Ok. Today it looks a bit different. 00:01:37.599,00:01:40.981 Today we have somthing in the desktop called a notification daemon, 00:01:41.34,00:01:46.741 and it gives us a differnt kind of notification, it looks something like this: 00:01:49.595,00:01:55.513 Now you probably see it at the lower right corner, we are getting a very similar notification. 00:01:55.513,00:01:59.899 It didn't steal the focus from XTerm, as you could see from the Xterm frame, 00:01:59.899,00:02:07.86 And it basically let's us continue to do our work while unobtrusivley notifying us of something. 00:02:07.86,00:02:11.154 This is very good for a sighted user, but if you are using a screen reader, 00:02:11.154,00:02:19.186 this is not going to be sufficient, since it doesn't take focus, Orca is never going to actually 00:02:19.186,00:02:22.991 inform us that this message has popped up. 00:02:22.991,00:02:28.751 So we are going to need to script around it, to make sure that Orca works in some way or another. 00:02:53.534,00:03:00.298 OK, this is Accerciser, and here are all the running applications and they are 00:03:00.298,00:03:05.107 registered to the AT-SPI registry, one of them is the notification daemon. 00:03:05.107,00:03:13.561 So we could select it and in the event monitor we could filter out and make sure that we are 00:03:13.561,00:03:20.537 only listening, or only viewing events with the selected application as the source. 00:03:20.537,00:03:26.561 We will select all the event types since we don't really know what 00:03:26.561,00:03:36.865 we're looking for yet, and we're going to start our little demo again for notification 00:03:36.865,00:03:39.243 and see what kind of events we get. 00:03:42.202,00:03:49.71 So we get a bunch of events, and we'll see which events are useful 00:03:52.189,00:04:01.384 We have a few that have to do with lineage, one is a parent-change, and one is a child-add 00:04:03.392,00:04:08.729 These are fairly obscure events, and they could happen any time. 00:04:08.887,00:04:14.277 Probably the best event to look at over here, and depend on is window:create. 00:04:16.549,00:04:21.887 The popup dialog at the bottom is a top-level window. 00:04:22.521,00:04:29.390 We could basically decide that we are going to depend on window:create and have that event 00:04:29.390,00:04:32.772 trigger Orca into reading the notification. 00:04:33.723,00:04:40.910 Alright, we'll quit Accerciser. 00:04:42.759,00:04:52.218 And we'll display the actual needed script, we won't write it right now. 00:04:57.27,00:05:02.258 So this is a standard orca script, and the name of the file is notification-daemon.py 00:05:02.311,00:05:08.863 and this is important since the name of the script is what Orca looks for when it finds 00:05:08.863,00:05:11.981 an application and tries to map a script to it. 00:05:14.993,00:05:21.863 We add a "window:create" listener and a callback in this method 00:05:21.863,00:05:25.403 and this is the callback for "window:create". 00:05:25.403,00:05:34.17 Once a window is create we look for all the label accessibles 00:05:34.17,00:05:39.829 that are children of that top-level frame, basically. 00:05:39.829,00:05:48.442 And we grab all of thos labels, and after that we make an array of texts from all the 00:05:48.442,00:05:54.784 text interfaces of those labels and we simply prepend "Notification" to the begining. 00:05:55.999,00:06:03.238 Really not to much to this, and this is not a complete script in any way, 00:06:03.238,00:06:09.527 there is probably a lot more functionality that could be put in here. But this is enough for now 00:06:10.742,00:06:19.302 of course speech.speak is the ethod that will send the text to speech synthesis. 00:06:21.152,00:06:33.147 Let's exit gedit, and we're going to copy that file to Orca's scrip directory 00:06:34.891,00:06:42.447 That's the file we just looked at, we'll put it in .orca/orca-scripts. 00:06:42.447,00:06:46.886 Alright we put it there. Let's restart Orca 00:06:48.524,00:06:53.439 "Welcome to Orca, 'Orca screen reader/magnifier' frame, 'Preferences' button" 00:06:54.601,00:06:59.885 And, now we are going to run our notification popup demo. 00:07:00.361,00:07:05.540 "Notification: Your 90 day trial license for the GNOME desktop has expired." 00:07:05.540,00:07:08.974 "Please purchase a boxed version from your local software retailer." 00:07:08.974,00:07:15.263 Ok, our script works, and that's it! That's how you could use accerciser to 00:07:15.263,00:07:19.331 help improve your screen readers and other ATs.