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.


🚀 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

Install the package via pip:

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.1.tar.gz (5.5 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.1-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: kajotte_studio_tools-1.2.1.tar.gz
  • Upload date:
  • Size: 5.5 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.1.tar.gz
Algorithm Hash digest
SHA256 63b7aace5c64e79130c7644ab451bd90be1ec68c9f45c8e54af91083c93d8d0a
MD5 ea1ea07374f6cad4dcb0360bea843a35
BLAKE2b-256 c28533442357ddad145d2f44ec9724935b12a59cb9cb5ea4990246f92170aca0

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for kajotte_studio_tools-1.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 347f119abe96a433801bdcd0ec76f45d9ece91239c8faf226dac98e751712d77
MD5 cd4314eac839f9cc67533885fd70e659
BLAKE2b-256 cbac739e86924f5ef37b424b88a771c551448f50ec2237cee2ecec0785f93422

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