Skip to main content

Professional ANSI terminal styling and productivity tools

Project description

GitHub Sponsors

Kajotte Studio: Terminal Colors

Python Version Status Release MIT License

Dependabot Security Policy Python Quality Check Code Quality GitHub Actions Quality

A professional, zero-dependency ANSI color encapsulation library for Python. Designed by Kajotte Studio for developers who value clean code and terminal aesthetics.

PyPI - Version GitHub License


🚀 Overview

This package provides a complete set of ANSI escape sequences for terminal text styling. It includes standard and bright variants for both foreground and background colors.

Key Features:

  • Zero Dependencies: Pure Python, no external bloat.
  • Full Palette: 16 text colors and 16 background colors.
  • Minimalist API: Simple class-based access to ANSI codes.
  • Cross-Platform: Initialized for modern terminal emulators.

📥 Installation

You can install the package using one of the following methods:

Method 1: Official Stable Release (Recommended)

pip install kajotte-studio-tools

Method 2: Latest Development Version (GitHub)

pip install git+https://github.com/Kajotte-studio/Python-colors.git

🛠 Usage

Simply import the Colors class and use f-strings to style your output.

from kajotte_tools import Colors

Foreground colors

print(f"{Colors.GREEN}Success:{Colors.RESET} Operation completed.")
print(f"{Colors.BR_CYAN}Notice:{Colors.RESET} System update available.")

Background colors

print(f"{Colors.BG_RED}{Colors.WHITE} CRITICAL ERROR {Colors.RESET}")
print(f"{Colors.BG_BR_YELLOW}{Colors.BLACK} WARNING {Colors.RESET} Check logs.")

Alternative

import kajotte_tools as kt
print(kt.Colors.GREEN + "Clean code!" + kt.Colors.RESET)

Colors Preview

Instantly visualize the full palette of 32 colors and available formatting styles in your terminal.

Colors.preview()

Terminal Tokens

Standardized status indicators for your console applications. No more manual formatting!

from kajotte_tools import Tokens

print(f"{Tokens.SUCCESS} Operation completed!")
print(f"{Tokens.ERROR} Connection failed.")
print(f"{Tokens.INFO} System update available.")
print(f"{Tokens.WARN} Low disk space.")

You can preview all available tokens using:

Tokens.list_tokens()

Visual Progress Timer

Track your long-running tasks with a built-in progress bar and real-time countdown.

from kajotte_tools import Timer

# Create a timer for a 10-second task
session = Timer("Code Optimization", 10)
session.start()

Features:

  • Dynamic Progress Bar: Visual feedback of the task's completion.
  • Auto-formatting: Professional headers and completion summaries.
  • Time Management: Shows remaining time in seconds.

Perfect for background processes, data optimization, or educational sessions.


📝 Technical Reference

Detailed implementation details and the logic behind this class structure can be found in the technical documentation on the blog:

🔗 Internal Reference: index_blog_post_44_en.html


⚖️ License & Documentation

License: MIT License.

💡 Philosophy

"Simplicity is the ultimate sophistication."

Following the Kajotte Studio principle, this library provides only what is necessary, ensuring maximum performance and zero overhead for your CLI applications and bots.


MIT License
Developed by Kajotte Studio

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

kajotte_studio_tools-1.2.2.tar.gz (5.6 kB view details)

Uploaded Source

Built Distribution

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

kajotte_studio_tools-1.2.2-py3-none-any.whl (6.0 kB view details)

Uploaded Python 3

File details

Details for the file kajotte_studio_tools-1.2.2.tar.gz.

File metadata

  • Download URL: kajotte_studio_tools-1.2.2.tar.gz
  • Upload date:
  • Size: 5.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for kajotte_studio_tools-1.2.2.tar.gz
Algorithm Hash digest
SHA256 32b534a8775bee7e3e66e3772e4527a9634c5e1ac623ffe43b9ee2f801c57cce
MD5 73b634bf1fceb79460e9b6c1c4e5780a
BLAKE2b-256 f09561fb5d6ae1da3e5f8c43656fe0bd1689ee1634e7218def86093eeea42a6d

See more details on using hashes here.

File details

Details for the file kajotte_studio_tools-1.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for kajotte_studio_tools-1.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 92dae889e796161abfcd392ffc16c125e19e7c6172a25b0be2bc3d1426fa03fd
MD5 1dd77c13372dd1853925bd8e49ccac56
BLAKE2b-256 f984a761cc8b4be852be289f0a0e7716bdc41259f1c10dbd380f8e04b95a3737

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