Image 1 — Meet KetraTerm: a modern, high-performance terminal
Image 2 — Meet KetraTerm: a modern, high-performance terminal
Image 3 — Meet KetraTerm: a modern, high-performance terminal
Image 4 — Meet KetraTerm: a modern, high-performance terminal

Meet KetraTerm: a modern, high-performance terminal

Modern TUIs, agentic coding tools, AI CLIs, interactive dashboards, remote workflows, and other advanced applications increasingly depend on precise Unicode handling, modern keyboard protocols, mouse tracking, alternate screen buffers, TrueColor, shell integration, and fast incremental rendering.

KetraTerm uses a terminal engine written from scratch in Kotlin rather than wrapping an existing emulator.

What makes it different?

Modern terminal compatibility

KetraTerm supports:

  • Unicode 17.0;
  • grapheme clusters and combining characters;
  • wide and zero-width characters;
  • complex emoji sequences and fallback fonts;
  • terminal-aware width handling;
  • gap-free box-drawing and block rendering;
  • 24-bit TrueColor;
  • modern underline styles;
  • alternate screen buffers;
  • modern mouse tracking;
  • bracketed paste;
  • Kitty keyboard protocol;
  • CSI-u and xterm modifyOtherKeys.

Its Unicode implementation goes beyond decoding UTF-8. KetraTerm handles grapheme segmentation and terminal display width so multilingual text, emoji, combining marks, and complex TUI layouts remain aligned to the terminal grid.

Performance-focused architecture

KetraTerm uses compact primitive-backed terminal storage instead of allocating a separate object for every screen cell.

Its parser and terminal mutation paths are designed for a low allocation profile, reducing garbage-collection pressure during heavy output.

The renderer tracks dirty regions and redraws only the content that actually changed rather than repainting the complete terminal for every update.

Terminal processing and UI rendering are decoupled, allowing the engine to continue consuming output while stable frames are painted.

This matters for modern TUIs, agentic tools, rapidly updating dashboards, large builds, and verbose logs.

Shell integration and native notifications

KetraTerm supports OSC 133 and OSC 7 shell integration, including:

  • command boundaries;
  • prompt tracking;
  • exit-status tracking;
  • command navigation;
  • current working directory updates.

It also supports native desktop notifications through OSC 9 and OSC 777 for long-running commands, builds, remote jobs, deployments, and background tasks.

More than a desktop application

The same KetraTerm engine powers:

  • the standalone desktop terminal;
  • a published JetBrains IDE plugin;
  • reusable Kotlin/JVM terminal libraries.

The desktop application includes shell discovery, configurable fonts and fallback fonts, themes, scrollback, command navigation, native notifications, shell integration, security controls, and TOML-based configuration.

The project is available under the Apache 2.0 license.

KetraTerm is already usable as a real terminal, but it remains under active development. New features, compatibility fixes, performance improvements, and UI refinements will continue to be released.

Try it with your real workflow.

If a modern TUI, agentic tool, shell, keyboard combination, Unicode sequence, or other terminal application does not behave correctly, please report it. Reproducible compatibility reports are the most useful feedback at this stage.

Website:
https://ketraterm.github.io/KetraTerm/

GitHub and desktop downloads:
https://github.com/ketraterm/KetraTerm

IntelliJ plugin:
https://plugins.jetbrains.com/plugin/32589-ketraterm

u/gagik894 — 5 days ago
▲ 13 r/Kotlin

Meet KetraTerm: a modern, high-performance terminal

I have released KetraTerm 0.1.0, a modern open-source terminal emulator implemented entirely in Kotlin.

It is available as:

  • a standalone desktop terminal for Windows, macOS, and Linux;
  • a published JetBrains IDE plugin;
  • reusable Kotlin/JVM terminal libraries.

KetraTerm does not depend on JediTerm and does not wrap another terminal engine. It includes its own streaming parser, UTF-8 decoder, terminal grid, scrollback model, Unicode handling, keyboard encoder, PTY integration, rendering pipeline, shell integration, and host security layer.

The main challenge: making a JVM terminal fast

A terminal processes a huge number of very small state changes.

A naive JVM implementation can easily allocate an object for every cell, produce temporary collections while parsing, repaint the whole terminal after minor updates, and put constant pressure on the garbage collector.

KetraTerm was designed around a different architecture.

The terminal grid uses compact primitive-backed storage rather than an object-per-cell model. Frequently executed parsing and mutation paths are designed for a low allocation profile.

The renderer tracks dirty regions and redraws only the content that actually changed.

Terminal mutation, frame publication, and UI painting are decoupled, allowing the parser to continue consuming output while the UI renders stable frames.

This architecture is designed to remain responsive during:

  • heavy command output;
  • rapidly updating TUIs;
  • agentic development tools and AI CLIs;
  • large builds;
  • verbose logs;
  • continuously updating dashboards;
  • long-running sessions where GC pressure matters.

Modern terminal capabilities

KetraTerm currently supports:

  • Unicode 17.0;
  • grapheme clusters and combining characters;
  • wide, zero-width, and ambiguous-width characters;
  • complex emoji sequences and fallback fonts;
  • gap-free box-drawing and block rendering;
  • 24-bit TrueColor;
  • modern underline styles and underline colors;
  • alternate screen buffers;
  • modern mouse tracking;
  • bracketed paste;
  • Kitty keyboard protocol;
  • CSI-u;
  • xterm modifyOtherKeys;
  • OSC 133 and OSC 7 shell integration;
  • OSC 9 and OSC 777 desktop notifications.

The Unicode implementation is terminal-aware rather than merely UTF-8-aware. Grapheme segmentation and display width are handled as part of the fixed-cell terminal model.

Modular JVM architecture

KetraTerm is split into reusable modules for parsing, terminal state, input encoding, host operations, sessions, PTY transport, rendering, Swing integration, and workspace management.

The same terminal core powers both the standalone desktop application and the JetBrains plugin.

The project is available under the Apache 2.0 license, and development is active. New features, compatibility fixes, performance improvements, and API refinements will continue to be released.

I would especially appreciate feedback from Kotlin and JVM developers about the architecture, performance characteristics, public APIs, and possible embedding use cases.

I would also be interested in real-world workloads that are difficult for JVM applications: very heavy output, rapid redraws, large scrollback, complex Unicode, or demanding TUI applications.

GitHub:
https://github.com/ketraterm/KetraTerm

Website:
https://ketraterm.github.io/KetraTerm/

JetBrains plugin:
https://plugins.jetbrains.com/plugin/32589-ketraterm

u/gagik894 — 5 days ago
▲ 17 r/AndroidStudio+2 crossposts

Meet KetraTerm: a modern, high-performance terminal available as a JetBrains IDE plugin

Modern TUIs, agentic coding tools, AI CLIs, interactive dashboards, and other advanced terminal applications increasingly depend on precise Unicode layout, modern keyboard protocols, mouse tracking, TrueColor, alternate screen buffers, shell integration, and fast incremental rendering.

The current default terminal in JetBrains IDEs still has rendering and compatibility issues with some modern TUI applications and terminal workflows.

I wanted to see whether a new terminal engine, designed from the beginning for modern workloads and built entirely on the JVM, could provide a better experience without sacrificing performance.

So I built KetraTerm from scratch in Kotlin.

A JVM terminal does not have to be slow

Performance was one of the main design requirements from the beginning.

KetraTerm uses compact primitive-backed storage instead of allocating a separate object for every terminal cell. Its parser and terminal mutation paths are designed for a low allocation profile, reducing garbage-collection pressure during heavy output and rapid full-screen updates.

The renderer tracks dirty regions and redraws only the rows and cells that actually changed instead of continuously repainting the complete terminal.

Terminal processing, frame publication, and UI painting are also decoupled. This allows application output to continue being processed while the UI renders stable frames.

The result is an engine designed for demanding terminal workloads such as:

  • modern TUIs;
  • agentic development tools and AI CLIs;
  • continuously updating dashboards;
  • large builds;
  • verbose logs;
  • applications that redraw many times per second.

Modern terminal compatibility

KetraTerm supports:

  • Unicode 17.0;
  • grapheme clusters and combining characters;
  • wide and zero-width characters;
  • complex emoji sequences and fallback fonts;
  • terminal-aware character width handling;
  • gap-free box-drawing and block rendering;
  • 24-bit TrueColor;
  • modern underline styles and independent underline colors;
  • alternate screen buffers;
  • modern mouse tracking and high-resolution mouse coordinates;
  • bracketed paste;
  • Kitty keyboard protocol;
  • CSI-u and xterm modifyOtherKeys;
  • application cursor and keypad modes.

Its Unicode support is not limited to decoding UTF-8. KetraTerm handles grapheme segmentation and display width as part of the fixed-cell terminal model, helping multilingual text, emoji, combining marks, and complex TUI layouts remain correctly aligned.

Shell integration and notifications

KetraTerm supports OSC 133 and OSC 7 shell integration.

This allows it to understand command boundaries, prompts, exit statuses, and the current working directory instead of treating the entire session as an unstructured stream of text.

It also supports native desktop and in IDE notifications.

Already running inside JetBrains IDEs

The KetraTerm plugin embeds the complete KetraTerm terminal engine directly inside IntelliJ IDEA, Android Studio, PyCharm, WebStorm, CLion, and other compatible JetBrains IDEs.

The same engine also powers a standalone desktop terminal for Windows, macOS, and Linux.

KetraTerm 0.1.0 is now publicly available: desktop archives are available through GitHub Releases, and the source code is available under the Apache 2.0 license.

Development remains active. New features, compatibility improvements, performance refinements, and deeper IDE integrations will continue to be released.

If you use a modern TUI, agentic tool, shell workflow, or Unicode-heavy application that behaves incorrectly in your current IDE terminal, try the same workflow in KetraTerm.

Whether KetraTerm handles it better or still exposes a bug, please report the result. Real-world compatibility reports will help make KetraTerm better.

JetBrains plugin:
https://plugins.jetbrains.com/plugin/32589-ketraterm

Website:
https://ketraterm.github.io/KetraTerm/

GitHub and desktop downloads:
https://github.com/ketraterm/KetraTerm

u/gagik894 — 4 days ago