Skip to main content

bittty

A pure Python terminal emulator.

Demo

Run the standalone demo:

python ./demo/terminal.py

Or use the textual demo to see it in a TUI:

uvx textual-tty

Links

License

WTFPL with one additional clause

  1. Don't blame me

Do wtf you want, but don't blame me when it rips a hole in your trousers.

Recent changes

  • 🏃
  • 🏗️ rewrite architecture
  • 🐛 scroll region: scroll up in vim corrupts outside scroll region
  • 🏃 squeeze another 15% performance out of it
  • ✀ fix utf8 and escape code splitting across buffer boundaries
  • 🪟 tests run on Windows runner
  • 📉 added parser benchmarking and tui graphs
  • 🐌 use regex for parsing to speed things up a tad (~2x faster)
  • 📚 document half a billion DEC private modes we don't support
  • 🔙 DECLM - allow \n to act like \r\n so we don't have to rely on cooked input on the pty when using as a library.
  • 🖼️ DEC Special Graphics
  • 🐌 Faster colour/style parser
  • ⛓️‍💥 Split out from textual-tty into separate package

bugs / todo

  • Implement grapheme clustering (thanks Xavier G)
  • SIGWINCH handler atomicity + buffer resizes
  • architecture - pretty big
  • gui
    • make a terminal input class, for standalone input
    • make framebuffer.py
    • choose a display driver
  • performance improvements
    • reconsider CSI end char approach
    • line cache for outputs
    • [.] revisit colours / styles
  • scrollback buffer
    • implement logloglog for scrollback with wrapping
  • add terminal overlay visuals
    • bell flash effect
    • make cursor an overlay
    • make mouse an overlay
    • debug overlay for scroll regions
  • Support themes
  • bittty-specific escape sequences
    • visible mouse on / off
    • debugging info
    • record
    • list sequences + values
  • Document all the escape sequences
    • collect books for a terminal library

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bittty-0.1.0.tar.gz (78.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bittty-0.1.0-py3-none-any.whl (93.0 kB view details)

Uploaded Python 3

File details

Details for the file bittty-0.1.0.tar.gz.

File metadata

  • Download URL: bittty-0.1.0.tar.gz
  • Upload date:
  • Size: 78.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.20

File hashes

Hashes for bittty-0.1.0.tar.gz
Algorithm Hash digest
SHA256 fe60e15a9dee748253ecdac62bf050210eeb83a325dd521c914320cee6f8c75c
MD5 f28b0852272fc0a66f2378f8d7e27d22
BLAKE2b-256 a2b1f2e23062c4d4ae9e916bb560199e5683b33ef41eb5ad34b1daadc7487882

See more details on using hashes here.

File details

Details for the file bittty-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: bittty-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 93.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.20

File hashes

Hashes for bittty-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 668587b3212412e4ef3ee0e104cec1f9007121363598eb1bf8931eca78be758b
MD5 8fa204de84d6b3bee711c137ff3fd5cb
BLAKE2b-256 bfa7f531ad53eb75dddb9cab509429bd709fb501a8fa724d9d5e251539a96ab6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page