/*========================================================================= Star3.c -- This module contains requester gadget definitions for the Parameters requester used in the Star Chart program. The gadgets and intuitexts in this module were build using the EGad Gadget Editor developed by the Programmer's network. (see later comments) Credits for Star Chart: Robert L. Hill of the Orange County, CA. Amiga Friends User Group wrote the original version of StarChart in AmigaBasic The star data and many of the main functions of this version are derived from that program. Ray R. Larson wrote the c version 1.0 of StarChart, 'intuitionizing' and enhancing the speed and functions of the original. Copyright (c) 1986 by Ray R. Larson This program may be freely distributed and copied, but may not be sold without the permission of the author. If you modify or enhance it, please include the above credits (and please send me a copy!). Ray R. Larson 6425 Central Ave. #304 El Cerrito, CA 94530 BitNet LARSON@UCBCMSA =========================================================================*/ /********************************************************************** * Gadget Structure Definitions * * The following structures were defined using the Gadget Editor created * by the Programmer's Network. * The credits for the Gadget Editor are: * * John Draper - Initial design, coordination, and integration. * Ray Larson - Images and Intuitext. * Brent Southard - Saving and restoring gadgets in binary form. * Dave Milligan - Gadget Editor Main menu. * * **********************************************************************/ /* The header files needed for gadget definitions */ #include #include #include #include #include #include #include #include /* Definitions for Gadget ID numbers */ #define LONGDEGGAD 0 #define LONGMINGAD 1 #define LATDEGGAD 2 #define YEARGAD 3 #define MONGAD 4 #define DAYGAD 5 #define HOURGAD 6 #define MINGAD 7 #define SECGAD 8 #define NORTHGAD 9 #define SOUTHGAD 10 #define CANGAD 11 #define OKGAD 12 /********************************************************************** * Text attribute structures used in rendering IntuiTexts **********************************************************************/ char def_font[] ="topaz.font"; struct TextAttr TxtAt_Plain = { (UBYTE *)def_font, 8, FS_NORMAL, FPF_ROMFONT}; struct TextAttr TxtAt_BIU = {(UBYTE *)def_font, 8, FSF_BOLD | FSF_ITALIC | FSF_UNDERLINED, FPF_ROMFONT}; struct TextAttr TxtAt_BU = {(UBYTE *)def_font, 8, FSF_BOLD | FSF_UNDERLINED, FPF_ROMFONT}; struct TextAttr TxtAt_BI = {(UBYTE *)def_font, 8, FSF_BOLD | FSF_ITALIC, FPF_ROMFONT}; struct TextAttr TxtAt_B ={(UBYTE *)def_font, 8, FSF_BOLD, FPF_ROMFONT}; struct TextAttr TxtAt_IU ={(UBYTE *)def_font, 8, FSF_ITALIC | FSF_UNDERLINED, FPF_ROMFONT}; struct TextAttr TxtAt_I ={(UBYTE *)def_font, 8, FSF_ITALIC, FPF_ROMFONT}; struct TextAttr TxtAt_U ={(UBYTE *)def_font, 8, FSF_UNDERLINED, FPF_ROMFONT}; /********************************************************************** * Border Definitions for ok gadget **********************************************************************/ SHORT ok_Pairs_2[] = { 0, 0, 70, 0, 70, 12, 0, 12, 0, 0 }; struct Border ok_bord_2 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&ok_Pairs_2, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the ok gadget. **********************************************************************/ struct IntuiText ok_Text_0 = { 3, 1, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 2, 2, /* LeftEdge, TopEdge */ &TxtAt_B, /* ITextFont Pointer */ /* The IText */ (UBYTE *)" OK ", NULL }; /********************************************************************** * Gadget Structure definition for the ok gadget. **********************************************************************/ struct Gadget ok = { NULL, /* NextGadget pointer */ 260, 175, /* LeftEdge, TopEdge */ 70, 12, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE, /* GadgetType */ BOOLGADGET | REQGADGET, (APTR)&ok_bord_2, /* GadgetRender */ NULL, /* SelectRender */ &ok_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ NULL, /* SpecialInfo */ OKGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for can gadget **********************************************************************/ SHORT can_Pairs_2[] = { 0, 0, 70, 0, 70, 12, 0, 12, 0, 0 }; struct Border can_bord_2 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&can_Pairs_2, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the can gadget. **********************************************************************/ struct IntuiText can_Text_0 = { 3, 1, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 2, 2, /* LeftEdge, TopEdge */ &TxtAt_B, /* ITextFont Pointer */ /* The IText */ (UBYTE *)" CANCEL ", NULL }; /********************************************************************** * Gadget Structure definition for the can gadget. **********************************************************************/ struct Gadget can = { &ok, /* NextGadget pointer */ 41, 175, /* LeftEdge, TopEdge */ 70, 12, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | ENDGADGET, /* GadgetType */ BOOLGADGET | REQGADGET, (APTR)&can_bord_2, /* GadgetRender */ NULL, /* SelectRender */ &can_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ NULL, /* SpecialInfo */ CANGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for south gadget **********************************************************************/ SHORT south_Pairs_3[] = { 0, 0, 64, 0, 64, 12, 0, 12, 0, 0 }; struct Border south_bord_3 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&south_Pairs_3, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the south gadget. **********************************************************************/ struct IntuiText south_Text_0 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 11, 1, /* LeftEdge, TopEdge */ &TxtAt_B, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"South", NULL }; /********************************************************************** * Gadget Structure definition for the south gadget. **********************************************************************/ struct Gadget south = { &can, /* NextGadget pointer */ 208, 155, /* LeftEdge, TopEdge */ 64, 12, /* Width, Height */ /* Gadget Flags */ GADGHNONE, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE, /* GadgetType */ BOOLGADGET | REQGADGET, (APTR)&south_bord_3, /* GadgetRender */ NULL, /* SelectRender */ &south_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ NULL, /* SpecialInfo */ SOUTHGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for north gadget **********************************************************************/ SHORT north_Pairs_4[] = { 0, 0, 60, 0, 60, 12, 0, 12, 0, 0 }; struct Border north_bord_4 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&north_Pairs_4, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the north gadget. **********************************************************************/ struct IntuiText north_Text_1 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 9, 1, /* LeftEdge, TopEdge */ &TxtAt_B, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"North", NULL }; struct IntuiText north_Text_0 = { 2, 1, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 40, -13, /* LeftEdge, TopEdge */ &TxtAt_BU, /* ITextFont Pointer */ /* The IText */ (UBYTE *)" Horizon ", &north_Text_1 /* NextText */ }; /********************************************************************** * Gadget Structure definition for the north gadget. **********************************************************************/ struct Gadget north = { &south, /* NextGadget pointer */ 96, 155, /* LeftEdge, TopEdge */ 60, 12, /* Width, Height */ /* Gadget Flags */ GADGHNONE, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE, /* GadgetType */ BOOLGADGET | REQGADGET, (APTR)&north_bord_4, /* GadgetRender */ NULL, /* SelectRender */ &north_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ NULL, /* SpecialInfo */ NORTHGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for sec gadget **********************************************************************/ SHORT sec_Pairs_5[] = { 0, 0, 39, 0, 39, 9, 0, 9, 0, 0 }; struct Border sec_bord_5 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&sec_Pairs_5, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the sec gadget. **********************************************************************/ struct IntuiText sec_Text_0 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ -8, -10, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Seconds", NULL }; /********************************************************************** * String information for the sec string gadget. **********************************************************************/ UBYTE sec_sbuf_1[6] = "0"; UBYTE sec_ubuf_1[6]; struct StringInfo sec_txstr_1 = { sec_sbuf_1, sec_ubuf_1, /* Buffer, UndoBuffer */ 0, 3, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 4, 263, 125, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the sec gadget. **********************************************************************/ struct Gadget sec = { &north, /* NextGadget pointer */ 263, 125, /* LeftEdge, TopEdge */ 39, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&sec_bord_5, /* GadgetRender */ NULL, /* SelectRender */ &sec_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&sec_txstr_1, /* SpecialInfo */ SECGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for min gadget **********************************************************************/ SHORT min_Pairs_6[] = { 0, 0, 38, 0, 38, 9, 0, 9, 0, 0 }; struct Border min_bord_6 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&min_Pairs_6, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the min gadget. **********************************************************************/ struct IntuiText min_Text_0 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ -9, -10, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Minutes", NULL }; /********************************************************************** * String information for the min string gadget. **********************************************************************/ UBYTE min_sbuf_2[6] = "0"; UBYTE min_ubuf_2[6]; struct StringInfo min_txstr_2 = { min_sbuf_2, min_ubuf_2, /* Buffer, UndoBuffer */ 0, 3, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 4, 162, 125, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the min gadget. **********************************************************************/ struct Gadget min = { &sec, /* NextGadget pointer */ 162, 125, /* LeftEdge, TopEdge */ 38, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&min_bord_6, /* GadgetRender */ NULL, /* SelectRender */ &min_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&min_txstr_2, /* SpecialInfo */ MINGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for hour gadget **********************************************************************/ SHORT hour_Pairs_7[] = { 0, 0, 38, 0, 38, 9, 0, 9, 0, 0 }; struct Border hour_bord_7 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&hour_Pairs_7, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the hour gadget. **********************************************************************/ struct IntuiText hour_Text_0 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ -1, -10, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Hours", NULL }; /********************************************************************** * String information for the hour string gadget. **********************************************************************/ UBYTE hour_sbuf_3[6] = "0"; UBYTE hour_ubuf_3[6]; struct StringInfo hour_txstr_3 = { hour_sbuf_3, hour_ubuf_3, /* Buffer, UndoBuffer */ 0, 3, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 4, 62, 125, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the hour gadget. **********************************************************************/ struct Gadget hour = { &min, /* NextGadget pointer */ 62, 125, /* LeftEdge, TopEdge */ 38, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&hour_bord_7, /* GadgetRender */ NULL, /* SelectRender */ &hour_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&hour_txstr_3, /* SpecialInfo */ HOURGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for day gadget **********************************************************************/ SHORT day_Pairs_8[] = { 0, 0, 42, 0, 42, 9, 0, 9, 0, 0 }; struct Border day_bord_8 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&day_Pairs_8, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the day gadget. **********************************************************************/ struct IntuiText day_Text_0 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 8, -10, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Day", NULL }; /********************************************************************** * String information for the day string gadget. **********************************************************************/ UBYTE day_sbuf_4[6] = "0"; UBYTE day_ubuf_4[6]; struct StringInfo day_txstr_4 = { day_sbuf_4, day_ubuf_4, /* Buffer, UndoBuffer */ 0, 3, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 5, 259, 97, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the day gadget. **********************************************************************/ struct Gadget day = { &hour, /* NextGadget pointer */ 259, 97, /* LeftEdge, TopEdge */ 42, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&day_bord_8, /* GadgetRender */ NULL, /* SelectRender */ &day_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&day_txstr_4, /* SpecialInfo */ DAYGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for mon gadget **********************************************************************/ SHORT mon_Pairs_9[] = { 0, 0, 41, 0, 41, 9, 0, 9, 0, 0 }; struct Border mon_bord_9 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&mon_Pairs_9, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the mon gadget. **********************************************************************/ struct IntuiText mon_Text_0 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 2, -9, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Month", NULL }; /********************************************************************** * String information for the mon string gadget. **********************************************************************/ UBYTE mon_sbuf_5[6] = "0"; UBYTE mon_ubuf_5[6]; struct StringInfo mon_txstr_5 = { mon_sbuf_5, mon_ubuf_5, /* Buffer, UndoBuffer */ 0, 3, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 5, 154, 97, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the mon gadget. **********************************************************************/ struct Gadget mon = { &day, /* NextGadget pointer */ 154, 97, /* LeftEdge, TopEdge */ 41, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&mon_bord_9, /* GadgetRender */ NULL, /* SelectRender */ &mon_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&mon_txstr_5, /* SpecialInfo */ MONGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for year gadget **********************************************************************/ SHORT year_Pairs_10[] = { 0, 0, 42, 0, 42, 9, 0, 9, 0, 0 }; struct Border year_bord_10 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&year_Pairs_10, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the year gadget. **********************************************************************/ struct IntuiText year_Text_1 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 7, -9, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Year", NULL }; struct IntuiText year_Text_0 = { 2, 1, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 19, -25, /* LeftEdge, TopEdge */ &TxtAt_BU, /* ITextFont Pointer */ /* The IText */ (UBYTE *)" Current Date and Time ", &year_Text_1 /* NextText */ }; /********************************************************************** * String information for the year string gadget. **********************************************************************/ UBYTE year_sbuf_6[6] = "0"; UBYTE year_ubuf_6[6]; struct StringInfo year_txstr_6 = { year_sbuf_6, year_ubuf_6, /* Buffer, UndoBuffer */ 0, 5, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 5, 58, 97, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the year gadget. **********************************************************************/ struct Gadget year = { &mon, /* NextGadget pointer */ 58, 97, /* LeftEdge, TopEdge */ 42, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&year_bord_10, /* GadgetRender */ NULL, /* SelectRender */ &year_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&year_txstr_6, /* SpecialInfo */ YEARGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for LatDeg gadget **********************************************************************/ SHORT LatDeg_Pairs_11[] = { 0, 0, 74, 0, 74, 9, 0, 9, 0, 0 }; struct Border LatDeg_bord_11 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&LatDeg_Pairs_11, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the LatDeg gadget. **********************************************************************/ struct IntuiText LatDeg_Text_1 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 77, 0, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Degrees", NULL }; struct IntuiText LatDeg_Text_0 = { 2, 1, /* FrontPen, BackPen */ JAM2, /* DrawMode */ -50, -12, /* LeftEdge, TopEdge */ &TxtAt_BU, /* ITextFont Pointer */ /* The IText */ (UBYTE *)" Latitude (0 to 90 Deg.) ", &LatDeg_Text_1 /* NextText */ }; /********************************************************************** * String information for the LatDeg string gadget. **********************************************************************/ UBYTE LatDeg_sbuf_7[6] = "0"; UBYTE LatDeg_ubuf_7[6]; struct StringInfo LatDeg_txstr_7 = { LatDeg_sbuf_7, LatDeg_ubuf_7, /* Buffer, UndoBuffer */ 0, 3, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 9, 127, 52, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the LatDeg gadget. **********************************************************************/ struct Gadget LatDeg = { &year, /* NextGadget pointer */ 127, 52, /* LeftEdge, TopEdge */ 74, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&LatDeg_bord_11, /* GadgetRender */ NULL, /* SelectRender */ &LatDeg_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&LatDeg_txstr_7, /* SpecialInfo */ LATDEGGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for LongMin gadget **********************************************************************/ SHORT LongMin_Pairs_12[] = { 0, 0, 53, 0, 53, 9, 0, 9, 0, 0 }; struct Border LongMin_bord_12 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&LongMin_Pairs_12, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the LongMin gadget. **********************************************************************/ struct IntuiText LongMin_Text_0 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 63, 0, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Minutes", NULL }; /********************************************************************** * String information for the LongMin string gadget. **********************************************************************/ UBYTE LongMin_sbuf_8[6] = "0"; UBYTE LongMin_ubuf_8[6]; struct StringInfo LongMin_txstr_8 = { LongMin_sbuf_8, LongMin_ubuf_8, /* Buffer, UndoBuffer */ 0, 3, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 6, 203, 25, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the LongMin gadget. **********************************************************************/ struct Gadget LongMin = { &LatDeg, /* NextGadget pointer */ 203, 25, /* LeftEdge, TopEdge */ 53, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&LongMin_bord_12, /* GadgetRender */ NULL, /* SelectRender */ &LongMin_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&LongMin_txstr_8, /* SpecialInfo */ LONGMINGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; /********************************************************************** * Border Definitions for LongDeg gadget **********************************************************************/ SHORT LongDeg_Pairs_13[] = { 0, 0, 53, 0, 53, 9, 0, 9, 0, 0 }; struct Border LongDeg_bord_13 = { -1, -1, /* LeftEdge, TopEdge */ 1, 3, JAM2, /* FrontPen, BackPen, DrawMode*/ 5, /* Count of XY pairs */ (SHORT *)&LongDeg_Pairs_13, /* XY pairs */ NULL /* Next Border */ }; /********************************************************************** * IntuiTexts for the LongDeg gadget. **********************************************************************/ struct IntuiText LongDeg_Text_1 = { 1, 0, /* FrontPen, BackPen */ JAM2, /* DrawMode */ 56, 0, /* LeftEdge, TopEdge */ &TxtAt_I, /* ITextFont Pointer */ /* The IText */ (UBYTE *)"Degrees", NULL }; struct IntuiText LongDeg_Text_0 = { 2, 1, /* FrontPen, BackPen */ JAM2, /* DrawMode */ -54, -13, /* LeftEdge, TopEdge */ &TxtAt_BU, /* ITextFont Pointer */ /* The IText */ (UBYTE *)" Longitude (-180 - 180 Deg.: 0 - 60 Min.) ", &LongDeg_Text_1 /* NextText */ }; /********************************************************************** * String information for the LongDeg string gadget. **********************************************************************/ UBYTE LongDeg_sbuf_9[6] = "0"; UBYTE LongDeg_ubuf_9[6]; struct StringInfo LongDeg_txstr_9 = { LongDeg_sbuf_9, LongDeg_ubuf_9, /* Buffer, UndoBuffer */ 0, 5, 0, /* BufferPos, MaxChars, DispPos */ 0, 0, /* UndoPos, NumChars */ 6, 69, 25, /* DispCount, CLeft, CTop */ 0x0, 0, /* LayerPtr, LongInt */ 0x0 /* AltKeyMap */ }; /********************************************************************** * Gadget Structure definition for the LongDeg gadget. **********************************************************************/ struct Gadget LongDeg = { &LongMin, /* NextGadget pointer */ 69, 25, /* LeftEdge, TopEdge */ 53, 9, /* Width, Height */ /* Gadget Flags */ GADGHCOMP, /* Activation Flags */ RELVERIFY | GADGIMMEDIATE | LONGINT | STRINGCENTER, /* GadgetType */ STRGADGET | REQGADGET, (APTR)&LongDeg_bord_13, /* GadgetRender */ NULL, /* SelectRender */ &LongDeg_Text_0, /* GadgetText */ 0x0, /* MutualExclude */ (APTR)&LongDeg_txstr_9, /* SpecialInfo */ LONGDEGGAD, /* GadgetID */ 0x1 /* UserData Pointer */ }; struct Gadget *ParamGads = &LongDeg;