1 | /* |
---|
2 | * $Id: AClock.h,v 1.3 1999-01-29 00:39:25 ghudson Exp $ |
---|
3 | * |
---|
4 | * Copyright 1990, 1991 by the Massachusetts Institute of Technology. |
---|
5 | * |
---|
6 | * For copying and distribution information, please see the file |
---|
7 | * <mit-copyright.h>. |
---|
8 | * |
---|
9 | */ |
---|
10 | |
---|
11 | #ifndef _Xj_AClock_h |
---|
12 | #define _Xj_AClock_h |
---|
13 | |
---|
14 | #include "Jets.h" |
---|
15 | |
---|
16 | #define ANGLES 256 /* 1K of data for 90 degrees */ |
---|
17 | #define CIRCLE (4 * ANGLES) |
---|
18 | #define SCALE 65536 |
---|
19 | #undef PI |
---|
20 | #define PI 3.14159365358979 |
---|
21 | #define HALFPI (PI / 2.0) |
---|
22 | |
---|
23 | extern JetClass aClockJetClass; |
---|
24 | |
---|
25 | typedef struct {int littlefoo;} AClockClassPart; |
---|
26 | |
---|
27 | typedef struct _AClockClassRec { |
---|
28 | CoreClassPart core_class; |
---|
29 | AClockClassPart aClock_class; |
---|
30 | } AClockClassRec; |
---|
31 | |
---|
32 | extern AClockClassRec aClockClassRec; |
---|
33 | |
---|
34 | typedef struct { |
---|
35 | GC foregroundGC, backgroundGC, handsGC, highlightGC; |
---|
36 | int foreground, background, hands, highlight; |
---|
37 | Boolean reverseVideo; |
---|
38 | int centerx, centery; |
---|
39 | int xradius, yradius; |
---|
40 | int minorTick, majorTick; |
---|
41 | int minorStart, minorEnd; |
---|
42 | int majorStart, majorEnd; |
---|
43 | int padding; |
---|
44 | int secondStart, secondEnd, secondArc; |
---|
45 | int minuteStart, minuteEnd, minuteArc; |
---|
46 | int hourStart, hourEnd, hourArc; |
---|
47 | int h, m, s; |
---|
48 | int realized; |
---|
49 | int timerid; |
---|
50 | int update; |
---|
51 | Boolean keepRound; |
---|
52 | Boolean round; |
---|
53 | Pixmap mask; |
---|
54 | GC setGC, eraseGC; |
---|
55 | } AClockPart; |
---|
56 | |
---|
57 | typedef struct _AClockRec { |
---|
58 | CorePart core; |
---|
59 | AClockPart aClock; |
---|
60 | } AClockRec; |
---|
61 | |
---|
62 | typedef struct _AClockRec *AClockJet; |
---|
63 | typedef struct _AClockClassRec *AClockJetClass; |
---|
64 | |
---|
65 | #define XjCTick "Tick" |
---|
66 | #define XjNminorTick "minorTick" |
---|
67 | #define XjNmajorTick "majorTick" |
---|
68 | #define XjNmajorStart "majorStart" |
---|
69 | #define XjNmajorEnd "majorEnd" |
---|
70 | #define XjNminorStart "minorStart" |
---|
71 | #define XjNminorEnd "minorEnd" |
---|
72 | #define XjCArc "Arc" |
---|
73 | #define XjNsecondArc "secondArc" |
---|
74 | #define XjCHand "Hand" |
---|
75 | #define XjNsecondStart "secondStart" |
---|
76 | #define XjNsecondEnd "secondEnd" |
---|
77 | #define XjNminuteStart "minuteStart" |
---|
78 | #define XjNminuteEnd "minuteEnd" |
---|
79 | #define XjNhourStart "hourStart" |
---|
80 | #define XjNhourEnd "hourEnd" |
---|
81 | #define XjNminuteArc "minuteArc" |
---|
82 | #define XjNhourArc "hourArc" |
---|
83 | #define XjCUpdate "Update" |
---|
84 | #define XjNupdate "update" |
---|
85 | #define XjCInterval "Interval" |
---|
86 | #define XjNinterval "interval" |
---|
87 | #define XjCKeepRound "KeepRound" |
---|
88 | #define XjNkeepRound "keepRound" |
---|
89 | #define XjNhands "hands" |
---|
90 | #define XjNhighlight "highlight" |
---|
91 | #define XjCRound "Round" |
---|
92 | #define XjNround "round" |
---|
93 | |
---|
94 | #endif /* _Xj_AClock_h */ |
---|