home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Nebula
/
nebula.bin
/
SourceCode
/
Palettes
/
Clocks
/
DigitalClock.h
< prev
next >
Wrap
Text File
|
1992-12-05
|
2KB
|
81 lines
//----------------------------------------------------------------------------------------------------
//
// DigitalClock
//
// Inherits From: Clock
//
// Declared In: DigitalClock.h
//
// Class Description
//
// DigitalClock adds behavior required for specific graphical
// representation. A DigitalClock is a fixed size view (64 x 64).
// It draws only a background image (or color) and time and
// date information (no clock face image). Two styles are available.
// Standard, where all text is drawn horizontally. And Diagonal,
// where the time information is drawn diagonally (no date information
// is displayed with this style).
//
//
// Disclaimer
//
// You may freely copy, distribute and reuse this software and its
// associated documentation. I disclaim any warranty of any kind,
// expressed or implied, as to its fitness for any particular use.
//
//----------------------------------------------------------------------------------------------------
#import "Clock.h"
#define DIGITAL_STYLE_STANDARD 0
#define DIGITAL_STYLE_DIAGONAL 1
@interface DigitalClock : Clock
{
Font* timeFont;
Font* dateFont;
Font* yearFont;
int style;
NXColor timeColor;
NXColor dateColor;
BOOL wantsYear;
}
//----------------------------------------------------------------------------------------------------
// Setting Style
//-----------------------------------------------------------------------------------------------------
- style: (int) aStyle;
- (int) style;
//----------------------------------------------------------------------------------------------------
// Enabling Year Display
//-----------------------------------------------------------------------------------------------------
- wantsYear: (BOOL) aFlag;
- (BOOL) wantsYear;
//----------------------------------------------------------------------------------------------------
// Accessing Display Colors
//----------------------------------------------------------------------------------------------------
- timeColor: (NXColor) aColor;
- dateColor: (NXColor) aColor;
- (NXColor) timeColor;
- (NXColor) dateColor;
//----------------------------------------------------------------------------------------------------
// Action Methods
//----------------------------------------------------------------------------------------------------
- takeClockStyleFlagFrom :sender;
- takeWantsYearFlagFrom :sender;
- takeTimeColorFrom: sender;
- takeDateColorFrom: sender;
@end