[BRLTTY] BRLTTY and the latex-access project by means of python brlapi module

Samuel Thibault samuel.thibault at ens-lyon.org
Sun Nov 27 06:32:08 EST 2011


Daniel Dalton, le Sun 27 Nov 2011 17:22:31 +1100, a écrit :
> 1) I can write text to the display with the brlapi.writeText ()
> function, but if this text exceeds the length of the display how can I
> enable panning? 

You have to handle it in your application.

> 2) I know how to read keys pushed on the display. However, what is the
> best way to retrieve say the previous line if the prior line key is
> pressed? How can I work out where the beginning of the Braille window is
> so that my translation begins from the beginning of the Braille window
> to the end of the line. 

Since you handle the output yourself, you simply display the previous
line.

> 3) From my research it looks like I'm going to have to redefine every
> brltty key binding? Is this true?

Yes.

> I obviously need bindings to move the window around the screen, and each
> time repeat this process to display the mathematics. So does this mean
> I'll need to remap all the important keys on the display for my
> application? 

Yes. The advantage being that you can make it better fit what a "line"
is in your application, and not necessarily the width of the actual
screen.

> 4) When the user switches emacs buffers, or say opens a new screen
> terminal, I need to know when to leaveTtyMode. How could I detect when I
> need to leave tty mode?

Concerning "opening a new screen terminal", you don't need to leave,
it's the brlapi server which gets notified of the switch through another
way (a Linux ioctl, or the xbrlapi program). See part "3.1 VT switching"
of the brlapi manual.

Concerning emacs buffer switching, something has to be added indeed. I
don't know how you can request emacs to notify you when the user leaves
your buffer.

> Will I need to create a daemon and somehow check the user's
> whereabouts?

No need for concerning things that happen outside of emacs, it's all
handled by brltty.

> Or is it just best to leave it up to the user to
> turn off this functionality with perhaps a hotkey on the display,

It'd better to make it automatic.

> - How to move the display around the screen ie.e retreive the prior
> line, and keep track of where the display is? 

You do not need to, since it's you who decide what to show on the
display.

> - How to figure out where the beginning of the Braille window is
> actually sitting?

You know it already for the same reason.

> - I presume I will need to make my own key bindings?

Yes.

Samuel


More information about the BRLTTY mailing list