The sources are in a GitHub repository. To download the sources do:
git clone https://github.com/PerBothner/DomTerm
(Please help out with instructions for other platforms, especially Debian/Ubuntu, MacOS, *BSD, and Windows 10.)
On Fedora, you need to first:
sudo dnf install gcc make automake autoconf texinfo patch libwebsockets libwebsockets-devel json-c json-c-devel openssl-devel file-devel libcap-devel asciidoctor
--with-qtwebengine (recommended), also do:
sudo dnf install gcc-c++ qt5-qtbase-devel qt5-qtwebengine-devel qt5-qtwebchannel-devel
If configuring with
xxd - only needed at build time):
sudo dnf install vim-common
For Java classes, do:
sudo dnf install java-1.8.0-openjdk-devel
(You can also use Oracle JDK, version 8 or 9.)
which defines the
You can use
terminal.js in your own application.
However, there is also some utility code, include standalone
terminal emulator applications.
The best terminal emulator experience at this time is probably the combination of libwebsockets 2.2 with the Electron front-end.
Another good application is
It uses the C++-based Qt toolkit
Needed packages are included with Fedora 27.
(Reports of attempt to build or use qtdomterm on other platforms
would be welcome.)
Building the sample applications and libraries is a two-part process:
If building from the
This runs the GNU autotools (
Then run the
configure-options can be:
Build the C application
which uses libwebsockets.
lws-build is specified, it should be the path
build subdirectory of the libwebsockets compiled source tree.
Libwebsockets version 2.2 or newer is required, as older versions do not support flow control or paging.
This is the recommended “backend” and the default.
Build a WebSocket server, using Java WebSockets, which allows using any modern browser as a front-end. This server is no longer recommended or enabled by default.
This options adds the classes in
Generates help and man pages using AsciiDoctor.
The default is to do so if
asciidoctor is in the path.
Compile support for PTYs (pseudo-teletypes). This allows character mode: sending individual characters (rather than lines) from the front-end to the back-end. This is the default, except on Windows (which doesn’t support PTYs).
Use JavaFX to run standalone applications.
does not need to be specified if using Java SE 8.
It may be needed for OpenJDK or Java SE 7,
in which case it is either a path to
or (for convenience if using Java SE 7) the
Disable building anything that depends on Java.
Use Qt and QtWebEngine
qtdomterm, an advanced front-end that
supports multiple tabs, screen re-sizing, and other nice features.
For this you need the Qt development tools including QtWebEngine installed.
For Fedora, you also need:
sudo dnf install qt5-qtbase-devel qt5-qtwebchannel-devel qt5-qtwebengine-devel
to be compiled into the executable.
Otherwise, they are served from the compressed
This is an experimental feature to preload a library to interpose
some system functions. Most importantly it overrides
so that DomTerm gets notified on term terminal mode changes.
To test it, you can try either:
Either starts up a useable terminal emulator in a fresh window.
The former starts up a
bash shell, running in a PTY,
with a libwebsockets server. It also starts a stripped-down browser window,
using that for the input and output
The latter (obviously) runs qtdomterm.
qtdomterm executable has no external dependencies
(besides the Qt libraries), and you can copy to wherever you want it.