// Datix.h
// LaRev: 19.1.93 - 17:55

// Mit freundlicher Unterstützung durch:
// GadToolsBox V1.4
// which is (c) Copyright 1991,92 Jaba Development

#include <exec/types.h>
#include <intuition/intuition.h>
#include <intuition/classes.h>
#include <intuition/classusr.h>
#include <intuition/imageclass.h>
#include <intuition/gadgetclass.h>
#include <libraries/gadtools.h>
#include <graphics/displayinfo.h>
#include <graphics/gfxbase.h>
#include <libraries/dos.h>
#include <workbench/workbench.h>
#include <workbench/startup.h>

#include <clib/exec_protos.h>
#include <clib/intuition_protos.h>
#include <clib/gadtools_protos.h>
#include <clib/graphics_protos.h>
#include <clib/utility_protos.h>
#include <clib/dos_protos.h>
#include <clib/icon_protos.h>

#include <pragmas/exec_pragmas.h>
#include <pragmas/intuition_pragmas.h>
#include <pragmas/gadtools_pragmas.h>
#include <pragmas/graphics_pragmas.h>
#include <pragmas/utility_pragmas.h>
#include <pragmas/dos_pragmas.h>
#include <pragmas/icon_pragmas.h>

#include <string.h>

#define GetString( g ) ((( struct StringInfo * )g->SpecialInfo )->Buffer)
#define GetNumber( g ) ((( struct StringInfo * )g->SpecialInfo )->LongInt)

#define GD_Tag_Text                            0
#define GD_Jahr_Text                           1
#define GD_Zeit_Text                           2
#define GD_Monat_Text                          3
#define GD_Day_Inc                             4
#define GD_Hour_Inc                            5
#define GD_Minute_Inc                          6
#define GD_Hour_Dec                            7
#define GD_Minute_Dec                          8
#define GD_Day_Dec                             9
#define GD_Month_Inc                           10
#define GD_Month_Dec                           11
#define GD_Year_Inc                            12
#define GD_Year_Dec                            13
#define GD_Save_Button                         14

#define GDX_Tag_Text                           0
#define GDX_Jahr_Text                          1
#define GDX_Zeit_Text                          2
#define GDX_Monat_Text                         3
#define GDX_Day_Inc                            4
#define GDX_Hour_Inc                           5
#define GDX_Minute_Inc                         6
#define GDX_Hour_Dec                           7
#define GDX_Minute_Dec                         8
#define GDX_Day_Dec                            9
#define GDX_Month_Inc                          10
#define GDX_Month_Dec                          11
#define GDX_Year_Inc                           12
#define GDX_Year_Dec                           13
#define GDX_Save_Button                        14

#define Datix_CNT 15

extern struct Screen        *Scr;
extern UBYTE                 *PubScreenName;
extern APTR                  VisualInfo;
extern struct Window        *DatixWnd;
extern struct Gadget        *DatixGList;
extern struct IntuiMessage   DatixMsg;
extern UWORD                 DatixZoom[4];
extern struct Gadget        *DatixGadgets[15];
extern UWORD                 DatixLeft;
extern UWORD                 DatixTop;
extern UWORD                 DatixWidth;
extern UWORD                 DatixHeight;
extern UBYTE                *DatixWdt;
extern struct TextAttr      *Font, Attr;
extern UWORD                 FontX, FontY;
extern UWORD                 OffX, OffY;
extern struct IntuiText      DatixIText[];
extern UWORD                 DatixGTypes[];
extern struct NewGadget      DatixNGad[];
extern ULONG                 DatixGTags[];

extern int SetupScreen( void );
extern void CloseDownScreen( void );
extern void DatixRender( void );
extern int HandleDatixIDCMP( void );
extern int DatixCloseWindow();
extern int DatixVanillaKey();
extern int OpenDatixWindow( void );
extern void CloseDatixWindow( void );
