Skip to content

elias8/libghostty

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

231 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ghostty's full VT engine, as a Flutter widget

libghostty flterm ci license

Ghostty's libghostty-vt engine for Dart, with a Flutter widget on top.

Dart bindings to libghostty-vt for VT parsing, key/mouse encoding, OSC/SGR parsing, and screen formatting. FFI on native, WASM on web.

import 'package:libghostty/libghostty.dart';

final terminal = Terminal(cols: 80, rows: 24)
  ..onWritePty = (data) => pty.write(data)
  ..onTitleChanged = () => print('title: ${terminal.title}');

terminal.write(ptyOutput);

Flutter widget that renders a libghostty Terminal with adaptive input, themes, selection, and scrollback.

import 'package:flterm/flterm.dart';

final controller = TerminalController()
  ..onOutput = (bytes) => pty.write(bytes)
  ..onResize = (size) => pty.resize(size.cols, size.rows);

ptyOutputStream.listen(controller.write);

TerminalView(controller: controller);

License

MIT. See LICENSE.

About

Dart bindings to libghostty-vt, the virtual terminal emulator from Ghostty.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors