= JavaFX Terminal Emulator Rahman Usta :doctype: article :encoding: utf-8 :lang: en :toc: left :numbered: :terminalfx-version: 1.2.0
== JavaFX Terminal Emulator
TerminalFX is a terminal (PTY) emulator application written in JavaFX 18.
We use https://github.com/traff/pty4j[Pty4J] to get VT codes from running process and https://chromium.googlesource.com/apps/libapps/+/master/hterm/[hterm.js] from Chromium project to interact with Pty4J. TerminalFX is using powerful JavaFX WebView component to run hterm.js.
== Features
== Usage
TerminalBuilder terminalBuilder = new TerminalBuilder(); TerminalTab terminal = terminalBuilder.newTerminal();
image::images\default.png[]
TerminalConfig darkConfig = new TerminalConfig(); darkConfig.setBackgroundColor(Color.rgb(16, 16, 16)); darkConfig.setForegroundColor(Color.rgb(240, 240, 240)); darkConfig.setCursorColor(Color.rgb(255, 0, 0, 0.5));
TerminalBuilder terminalBuilder = new TerminalBuilder(darkConfig); TerminalTab terminal = terminalBuilder.newTerminal();
image::images\dark.png[]
== CygWin Support
TerminalConfig cygwinConfig = new TerminalConfig(); cygwinConfig.setWindowsTerminalStarter("C:\cygwin64\bin\bash -i"); <1>
TerminalBuilder terminalBuilder = new TerminalBuilder(cygwinConfig); TerminalTab terminal = terminalBuilder.newTerminal();