tdsr icon indicating copy to clipboard operation
tdsr copied to clipboard

Integrating support in a terminal emulator

Open wez opened this issue 3 years ago • 2 comments

This isn't strictly about tdsr. I'm the author of WezTerm and I'm currently thinking about what a first-class terminal screen reader experience might look like.

I don't know much about screen readers or what the state of the art is for people that use them with terminal emulators. I found TDSR when googling; it seems to be the most modern implementation.

I'm interested to hear about what's important for the experience, and what things are difficult or perhaps impossible to do in tdsr that might be possible to do in the terminal emulator itself.

wez avatar Jun 17 '21 03:06 wez

One important thing tdsr does is autoreads the screen when new text is added, without interrupting old text. The way I chose to do it is to just read new writes that come in. Another way to do it is to diff the screen after a time. They both have advantages. This way is particularly sensitive to how different apps write their text. There's a popular Go readline implementation which rewrites the entire line on every keypress which is annoying to use.

Some things would be easier if the screen reader was integrated into the terminal. Right now, I don't have access to modern terminal features such as clickable links, text search or scrollback. If I want those, I have to use screen or write it into tdsr. Since tdsr also has to be a terminal to give me screen review, I also have to sometimes figure out what's different between tdsr's view of the screen and the terminal's view of the screen and fix it.

tspivey avatar Jun 21 '21 17:06 tspivey

Hi Wez,

One of my associates is Didier Spaier, the developer of Slint, a distribution derived from Slackware Linux. Didier wants to be able to provide a frame buffer terminal in the Slint installer, to support things like large fonts for low vision users. He also wants to be able to support braille and speech.

But as far as I know, most frame buffer terminal emulators don't support integrating with screen readers at all. An exception is nosh. I've been considering trying to pull out the userspace virtual terminal bits from Nosh to use in projects like Slint. While Nosh is large and complicated, it is modular, so this should be doable. Given that you're already developing a cross-platform terminal emulator and are interested in this topic, maybe an alternate approach would be extending your emulator?

I think ideally we'd like to be able to integrate a user-space terminal emulator with brltty and quite probably other user space screen readers like tdsr.

If you want to discuss any of this in detail, you might check out the #slint channel on libera.chat and reach out to "DidierSpaier".

CMB avatar Jun 25 '21 00:06 CMB