View Source Tux.Colors (Tux v0.4.0)

Basic functions wrapping a few IO.ANSI coloring functions for writing stylized output to the terminal.

bold/2 underline/2 + faint/2 gray/2 red/2 orange/2 yellow/2 green/2 blue/2

When you use Tux.Command this module is imported automatically along with the Tux.Help module.

Usage

import Tux.Colors

"""
This is some #{bold("bold text")} illustrating the #{underline("usage")}
of Tux.Colors module. This #{red("word", false)} however,
won't be colored because the second argument passed is false, which is useful
when you want to control the colored output based on some configuration flag
passed to the functions in this module.
"""

Summary

Functions

Return the term with style applied

Return the term with style applied

Return the term with style applied

Return the term with style applied

Return the term with style applied

Return the term with style applied

Return the term with style applied

Return text with underline style applied

Return the term with style applied

Functions

blue(term, enabled \\ true)

Return the term with style applied

bold(term, enabled \\ true)

Return the term with style applied

faint(term, enabled \\ true)

Return the term with style applied

gray(term, enabled \\ true)

Return the term with style applied

green(term, enabled \\ true)

Return the term with style applied

orange(term, enabled \\ true)

Return the term with style applied

red(term, enabled \\ true)

Return the term with style applied

underline(term, enabled \\ true)

Return text with underline style applied

yellow(term, enabled \\ true)

Return the term with style applied