[BRLTTY] attribute tracking, was re: Recommended live distribution

Nicolas Pitre nico at fluxnic.net
Wed Sep 19 14:04:28 EDT 2012


On Wed, 19 Sep 2012, Dave Mielke wrote:

> [quoted lines by Klaus Knopper on 2012/09/19 at 17:38 +0200]
> 
> >What about attribute cursor routing, automatic profile detection and
> >selection etc.?
> 
> i'm all for adding useful features. Perhaps you could describe how each of 
> these works so that we can try to get it right the first time.
> 
> For example, I understand what attribute-based routing is, but what I don't 
> know is the best way to define it.
> 
> I think I know what you mean by profiles - changing brltty's settings based on 
> the current foreground probram - but I'm not sure how detecting which program 
> is currently in the foreground is best done, especially given screen-managed 
> windows, ssh sessions, etc.

Let's answer this last question first.  The best approach would probably 
involve screen content signature. So, given a set of application profile 
specifications, the first item in each profile would describe some 
screen content that has to match for the profile to be activated.  That 
match would need to be reconfirmed whenever the screen content changes, 
and if the match fails then the search for another profile would happen.

For example, alpine always has "  ALPINE " at the top of the screen, 
lynx has a specific menu at the bottom, the newt-based Fedora 
configuration tools such as system-config-network-tui have the same set 
of color attributes (blue background, gray window boxes and black fonts, 
etc).  That would work even over a ssh session.

Now the actual color attribute for scroll bars used in those 
applications could then be specified in those profiles.  Or some 
keyboard macros, or shadowed screen area which shouldn't trigger 
auto-speak or cursor tracking, or specific screen area which should 
always be spoken out whenever they change, etc.

But for attribute tracking, it is probably a good idea to try to come up 
with an heuristic to determine the position of such bar cursor 
automatically, even without profile information. That's usually some 
background color surrounded by a different background color that can 
change despite the displayed text remaining the same.


Nicolas


More information about the BRLTTY mailing list