struct Clock

Overview

Draws a simple anolog clock

Included Modules

Defined in:

clock.cr

Constant Summary

HOURS_PER_DAY = 24
MINUTES_PER_DAY = HOURS_PER_DAY * 60
SECONDS_PER_DAY = MINUTES_PER_DAY * 60.0
TWO_PI = Math::PI * 2

Constructors

Instance Method Summary

Constructor Detail

def self.new(center : CG2d::Vec(Int32), radius : Int32) #

[View source]

Instance Method Detail

def center : Vec(Int32) #

[View source]
def center=(center : Vec(Int32)) #

[View source]
def colors : Hash(String, RGB(UInt8)) #

[View source]
def colors=(colors : Hash(String, RGB(UInt8))) #

[View source]
def draw_arm(drawable, rads, length, color) #

[View source]
def draw_to(drawable, time = Time.local) #

[View source]
def radius : Int32 #

[View source]
def radius=(radius : Int32) #

[View source]