imj-base-0.1.0.2: Game engine with geometry, easing, animated text, delta rendering.

Safe HaskellNone
LanguageHaskell2010

Imj.Graphics.Text.ColorString

Contents

Description

A ColorString is a multicolored Text.

Synopsis

Type

Constructors

colored creates a ColorString using the specified foreground color on black background, wherease colored' allows you to chose both the background and the foreground colors.

And since ColorString is Monoid, we can write:

str = colored "Hello" white <> colored " World" yellow

Utilities

countChars :: ColorString -> Int Source #

Counts the chars in the ColorString

Reexports