term.js icon indicating copy to clipboard operation
term.js copied to clipboard

abstract API to use with non-DOM ui

Open sidorares opened this issue 10 years ago • 2 comments

Hi,

I'd like to use term.js for standalone terminal implementation running in it's own X11 window (using node-x11). Would you be interested in refactor that abstract [keyboard, mouse] -> [ lines buffer ] interaction with some kind of abstraction layer, and DOM document/window/events would be a concrete implementation on top of that layer (in my case - X11 events and custom widget - fixed grid of chars with attributes) ?

sidorares avatar Apr 22 '14 01:04 sidorares

I've been planning on doing this for quite some time: make term.js headless, and have the user simply hook into a render method and a key emitter rather than assume the DOM's presence. I think I have my own local branch somewhere. I'll definitely look into it.

One of the reasons I want to do this is to be able to combine term.js with blessed to make some kind of Terminal widget, thus making terminal multiplexers trivial to implement.

chjj avatar May 01 '14 05:05 chjj

Thanks! Please post updates if you find time to work on this

sidorares avatar May 01 '14 06:05 sidorares