home *** CD-ROM | disk | FTP | other *** search
-
- /*
- *----------------------------------------------------------------*
- * ScrEdit.H - Turbo ScrEdit C Interface Header File *
- * *
- * <C>opyright 1989 by iHn Systems *
- * P.O. Box 1707 *
- * Tulare, CA. 93275-1707 *
- * *
- * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -*
- * The file PRINTME.1ST explains how to create the Turbo ScrEdit *
- * Interface object code libraries that this header file is used *
- * with. See Page 6 of PRINTME.1ST for more details. *
- * *
- *----------------------------------------------------------------*/
- #if defined (__TINY__) || defined (__SMALL__)
- #error "TINY and SMALL memory models are not supported";
- #endif
-
- typedef union
- {
- struct s1
- {
- char filler;
- char s_name [128] [17];
- unsigned char s_number [128];
- int s_recordnumber [128];
- int s_fieldsrecno [128];
- int s_rangerecno [128];
- unsigned char s_first [128];
- unsigned char s_count [128];
- unsigned char s_compiledind [128];
- int s_rangerecnext;
- int s_rangelinenext;
- int s_sfiled;
- }A;
- struct s2
- {
- char filler;
- char s_video [3840];
- char s_workarray [80] [2];
- }B;
- struct s3
- {
- char filler;
- unsigned char s_fieldname [128] [17];
- unsigned char s_row [128];
- unsigned char s_col [128];
- unsigned char s_len [128];
- unsigned char s_type [128];
- unsigned char s_prev [128];
- unsigned char s_next [128];
- unsigned char s_datalen [128];
- unsigned char s_normalbg [128];
- unsigned char s_normalfg [128];
- unsigned char s_promptbg [128];
- unsigned char s_promptfg [128];
- unsigned char s_displaybg [128];
- unsigned char s_displayfg [128];
- unsigned int s_rangenextrec [128];
- unsigned char s_rangenextline [128];
- }C;
- struct s4
- {
- char filler;
- char s_rangelist [51] [79];
- int s_rangerec [51];
- unsigned char s_rangeline [51];
- }D;
- } s_rec_def;
-
- s_rec_def *s_indx, *s_record, *s_field, *s_validate;
-
- int long S_CursorOld;
-
- enum S_Cursors
- {S_OFF,S_BOLD,S_NORMAL,S_INVERSEBOLD,S_INVERSENORMAL,S_GETCURSOR};
- void far *S_VideoMem;
- enum S_Cursors S_Cursor;
- char S_Sound;
- char S_HelpSound;
- char S_UserSound;
- char S_ErrorSound;
- char S_NumLock;
- char S_Fkey;
- char S_Shift;
- char S_Alt;
- char S_Ctrl;
- char S_Esc;
- char S_F1;
- char S_F2;
- char S_F3;
- char S_F4;
- char S_F5;
- char S_F6;
- char S_F7;
- char S_F8;
- char S_F9;
- char S_F10;
- char S_F11;
- char S_F12;
- char S_Enter;
- char S_BkSp;
- char S_Home;
- char S_Up;
- char S_PgUp;
- char S_Left;
- char S_Right;
- char S_End;
- char S_Down;
- char S_PgDn;
- char S_Ins;
- char S_Del;
- char S_Tab;
- char S_ShowStatus;
- char S_ScrollLock;
- char S_Caps;
- char S_LeftShift;
- char S_RightShift;
- char S_InsertMode;
- char S_InsertKey;
- char S_DeleteKey;
- char S_BackSpace;
- int S_FirstField;
- int S_Point;
- int S_Freq;
- int S_Dur;
- int S_HelpFreq;
- int S_HelpDur;
- int S_ErrorFreq;
- int S_ErrorDur;
- int S_UserFreq;
- int S_UserDur;
- unsigned char S_WorkStr [81];
- unsigned char S_Msg [81];
- unsigned char S_EditStr [81];
- unsigned char S_Blanks [81];
- unsigned char S_Ch;
- unsigned char S_ChangeScreen;
- unsigned char S_FirstTime = 1;
- unsigned char S_Sound_Hold;
- unsigned char S_Mono;
- unsigned char S_UpCase;
- unsigned char S_Validate_Finished;
- unsigned char S_ScreenValid;
- unsigned char S_Wait;
- unsigned char S_LeftArrow;
- unsigned char S_RightArrow;
- unsigned char
- S_DelayScreen,
- S_Delayed,
- S_FileOpen,
- S_EnterAsTab,
- S_FastVideo,
- S_PosLastChar,
- S_Bw,
- S_DupFields,
- S_SetDupeFields,
- S_EntryType,
- S_DispType,
- S_DupType,
- S_FType,
- S_InitialValue[81],
- S_EditMask [81],
- S_EditMaskTypes[7],
- S_AutoHelpMsg [81],
- S_ErrorMsg [81],
- S_UserMsg [81],
- S_QuickHelp,
- S_Force_EditMask,
- S_AutoHelp,
- S_AutoValidate,
- S_StLabelColor,
- S_StLabelFg,
- S_StLabelBg,
- S_StFg,
- S_StBg,
- S_UserFg,
- S_UserBg,
- S_ErrorFg,
- S_ErrorBg,
- S_HelpFg,
- S_HelpBg,
- S_StColor;
- int
- S_VRec,
- S_RecNo,
- S_ValidateLine,
- S_ValidateField,
- S_Str_Pos,
- S_Attrib,
- S_MessBg,
- S_MessFg,
- S_Num,
- S_F_Key,
- S_Direction,
- S_Decimal,
- S_PrevField,
- S_FieldNum,
- S_Sub,
- S_CurrLine,
- S_NextRec;
-
- unsigned char
- S_NewStr [81],
- S_Padding [81],
- S_WorkAttrib [81],
- S_NormAttrib [81],
- S_StPrev [41],
- S_StLine [41],
- S_StAttrib [41],
- S_Ins_Str [2],
- S_NextLine,
- S_Reverse,
- S_Skip,
- S_Matched,
- S_Min_Max_Loaded,
- S_EndofLine,
- S_InsideIf,
- S_CurStr[81],
- S_EditStrHold[81],
- S_CompMin[81],
- S_CompMax[81],
- S_CompField[81],
- S_OpCode[81],
- S_OpCode1[81];
-
- double
- S_Round [8] = {.5,.5,.05,.005,.0005,.00005,.000005,.0000005},
- S_Numeric,
- S_CompMin_Numeric,
- S_CompMax_Numeric;
-
- char S_MouseFirstTime = '1';
- unsigned char
- S_MouseInstalled,
- S_MouseVisable,
- S_MouseActive,
- S_MouseEvent,
- S_MsLeftPressed,
- S_MsRightPressed,
- S_MsMiddlePressed,
- S_MsLeftReleased,
- S_MsRightReleased,
- S_MsMiddleReleased;
-
- unsigned
- S_MsX,
- S_MsY,
- S_MsRowHold,
- S_MsColHold,
- S_MsRow,
- S_MsCol,
- S_MsAx,
- S_MsBx,
- S_MsCx,
- S_MsDx,
- S_Buttons;
-
- typedef struct{
- char far *Ptr[255];
- }S_Vectors;
- S_Vectors far *S_VectorRec;
-
- typedef struct {
- unsigned Ax, Bx, Cx, Dx;
- char MouseEvent;
- char MouseActive;
- } S_EventRecord;
- S_EventRecord far *S_Ms;
-
- void S_ActivateMouse(void);
- void S_AnalizeMouse(void);
- void S_DisableMouse(void);
- void S_HideMouse(void);
- void S_InitMouse(void);
- void S_MoveMouse(void);
- void S_RemoveMouse(void);
- void S_ResetMouse(void);
- void S_ResetMouseFlags(void);
- void S_RestoreMouse(void);
- void S_SetMouseCursor(char,char,char,char);
- void S_SetMouseEvent(char*);
- void far S_SetMouseFlags (void);
- void S_SetMouseRange(int,int,int,int);
- void S_ShowMouse(void);
-
- void S_ResetKeyFlags (void);
- void S_SetCursor(char);
- void S_Init(void);
- void S_OpenScreenFile (char*);
- void S_CloseScreenFile(void);
- void S_Beep(int,int);
- void S_Write (int,int,int,char*,char*);
- void S_DisplayMessage(int,int,char);
- void S_LoadScreen(char *);
- void S_DisplayScreenField(int,int,int,int,int,int,int,int,int,char);
- void S_EditString (int,int,int,int,int,int,int,int,int,int,int,int,char*);
-
- void S_NextKey(void);
- void S_ReadField(void);
- void S_ReadScreen(void);
- void S_ClearDupes(void);
- void S_StoreColorChanges(void);
- void S_RefreshScreen(void);
- void S_ClearScreen(int);
-
- unsigned char S_IsDupe(int);
- unsigned char S_SetDupe(int);
- unsigned char S_ReSetDupe(int);
- unsigned char S_ChangeScreenColor(int,int,int,int,int,int,int);
- unsigned char S_ChangeFieldColor(int,int,int,int);
- unsigned char S_SetDisplayOn(int);
- unsigned char S_SetDisplayOff(int);