Skip to main content

A Python library for terminal manipulation and styling

Project description

ConsoleM

A powerful Python library for terminal manipulation and text styling. ConsoleM provides a simple and intuitive API for creating beautiful terminal applications with advanced features like cursor control, text styling, and keyboard input handling.

Features

  • Terminal Manipulation

    • Precise cursor movement (absolute and relative positioning)
    • Screen clearing and line management
    • Alternate screen support for full-screen applications
    • Terminal size detection and cursor position tracking
    • Cursor visibility control
    • Non-blocking keyboard input handling
  • Text Styling

    • Rich text formatting with intuitive markup syntax
    • 256-color support (foreground and background)
    • Text styles (bold, underline, italic, etc.)
    • Emoji support with automatic conversion
    • Easy-to-use BBCode-like markup syntax
    • Automatic style reset and cleanup
  • Input Handling

    • Non-blocking keyboard input capture
    • Key event queue management
    • Special key detection (arrows, function keys, etc.)
    • Thread-safe input processing
    • Clean shutdown handling

Installation

pip install ConsoleM

Quick Start

from ConsoleM import Terminal
from ConsoleM.Style.text import Text

# Create a terminal instance
term = Terminal()

# Print styled text
Text("[blue bold]Welcome to ConsoleM![/]").print()

# Get terminal size
width, height = term.get_terminal_size()
Text(f"[green]Terminal size: {width}x{height}[/]").print()

Documentation

For detailed documentation, visit: https://remi-avec-un-i.github.io/ConsoleM/

License

This project is licensed under the MIT License - see the LICENSE file for details.

Project details


Download files

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

Source Distribution

consolem-0.1.0.tar.gz (68.7 kB view details)

Uploaded Source

Built Distribution

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

consolem-0.1.0-py3-none-any.whl (48.6 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: consolem-0.1.0.tar.gz
  • Upload date:
  • Size: 68.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for consolem-0.1.0.tar.gz
Algorithm Hash digest
SHA256 b9827cc144b9e05a906a58fbf603b68abac0211582779dfe84b378a0cded0834
MD5 4d6400f373b2010ef430e83e993bace3
BLAKE2b-256 0b23241b281e41485e8c40a7b0d03ae1dce5059c5ae0e3840cd799d06413a7a7

See more details on using hashes here.

File details

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

File metadata

  • Download URL: consolem-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 48.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for consolem-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bba37a5f416a56c192e98216f4e5a8818c94f50d61560117c5d5abb290187703
MD5 55ce652763ba7439cf89886fd33f1ce5
BLAKE2b-256 8e51199be197d63ef37fd200eceda7c270b842379910edcdae973974ffb4d2b6

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