Copyright | (c) 2013 Jeffrey Rosenbluth |
---|---|
License | BSD-style (see LICENSE) |
Maintainer | jeffrey.rosenbluth@gmail.com |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Utility functions to creating color schemes.
Synopsis
- type Kolor = Colour Double
- tint :: Double -> Kolor -> Kolor
- tone :: Double -> Kolor -> Kolor
- shade :: Double -> Kolor -> Kolor
- sliders :: Kolor -> Double -> (Double -> Double) -> (Double -> Double) -> Kolor
- rotateColor :: Double -> Kolor -> Kolor
- monochrome :: Kolor -> [Kolor]
- complement :: Kolor -> [Kolor]
- triad :: Kolor -> [Kolor]
- tetrad :: Kolor -> [Kolor]
- analogic :: Kolor -> [Kolor]
- accentAnalogic :: Kolor -> [Kolor]
- bwg :: Kolor -> [Kolor]
- colorRamp :: Int -> [Kolor] -> [Kolor]
Choosing color schemes
Synonym for Colour Double
Color utilities
tint :: Double -> Kolor -> Kolor Source #
Tints a color by adding blending t * white + (1 - t) color. t should be between 0 and 1.
tone :: Double -> Kolor -> Kolor Source #
Alter the tone of a color by adding blending t * gray + (1 - t) color. t should be between 0 and 1.
shade :: Double -> Kolor -> Kolor Source #
Shades a color by adding blending s * black + (1 - t) color. t should be between 0 and 1.
sliders :: Kolor -> Double -> (Double -> Double) -> (Double -> Double) -> Kolor Source #
Rotate a color and apply one function to its saturation and another to its value.
Color harmonies
monochrome :: Kolor -> [Kolor] Source #
Create a monochromatic set of 5 colors based in the input color.
complement :: Kolor -> [Kolor] Source #
A color harmony using the base color and its opposite.
tetrad :: Kolor -> [Kolor] Source #
Scheme based on 4 colors on a rectangle incscribed in the RYB color wheel.
analogic :: Kolor -> [Kolor] Source #
Chord base on three adjacent colors on the artists color wheel.
accentAnalogic :: Kolor -> [Kolor] Source #
Analogic chord plus the color opposite to the base color.