API for seesaw.color - Seesaw

by Dave Ray

Full namespace name: seesaw.color

Overview

Functions for creating Swing colors. Note that these are implicit
in the core color options.

Public Variables and Functions



color

function
Usage: (color s)
       (color s a)
       (color r g b a)
       (color r g b)
Create a java.awt.Color object from args.

Examples:

  ; Named color with string or keyword
  (color "springgreen")
  (color :aliceblue)

  ; CSS-style hex color
  (color "#ff0000")

  ; Named color with alpha
  (color :aliceblue 128)

  ; CSS-style hex color with alpha
  (color "#ff0000" 128)

  ; RGB color
  (color 255 128 128)

  ; RGB color with alpha
  (color 255 128 128 224)

See:
  http://download.oracle.com/javase/6/docs/api/java/awt/Color.html
  http://www.w3.org/TR/css3-color/


default-color

function
Usage: (default-color name)
Retrieve a default color from the UIManager.

Examples:

  ; Return the look and feel's label foreground color
  (default-color "Label.foreground")

Returns a java.awt.Color instance or nil if not found.

See:
  http://download.oracle.com/javase/6/docs/api/javax/swing/UIManager.html#getColor%28java.lang.Object%29
Logo & site design by Tom Hickey.
Clojure auto-documentation system by Tom Faulhaber.