0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

ターミナルをシンプルにかわいく彩るライブラリ

Last updated at Posted at 2025-10-02

ターミナルに色を指定して出力するシンプルなライブラリ。

・ターミナルへ出力される文字をシンプルに色付けをして出力可能にするモジュール。

・呼び出し方法もシンプル

シンプルな呼び出し方法

from kawaii_colors import paint

text = "Python3 is Beautiful."
paint(text)

シンプルにカスタマイズして呼び出す方法

from kawaii_colors import Cprint

text = "Python3 is Beautiful."
options = {"font_weight": "bold", "color_code": "red"}
print(Cprint(text, options=options))

様々な呼び出し方法

text = "Python3 is Beautiful."
colors = [
    "gray",
    "blue",
    "cyan",
    "green",
    "purple",
    "red",
    "white",
    "yellow",
]
weights = [
    "bold",
    "bold_res",
    "italics",
    "italics_res",
    "underline",
    "underline_res",
]
for c in colors:
    for w in weights:
        paint(text, {"font_weight": w, "color_code": c})

シンプルな出力結果
image.png

以上。

記事もシンプル 笑

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?