home *** CD-ROM | disk | FTP | other *** search
- (*----------------------------------------------------------------------*)
- (* GLOBAL VARIABLE DEFINITIONS *)
- (*----------------------------------------------------------------------*)
-
- USES (* DOS but not IBM PC specific *)
- Dos;
-
- TYPE
-
- AnyStr = STRING[255] (* Matches any string for parameter passing *);
-
- String2 = STRING[2] (* Two character string *);
-
- String3 = STRING[3] (* Three character string *);
-
- String8 = STRING[8] (* Eight character string *);
-
- FileStr = STRING[65] (* File name string *);
-
- (*----------------------------------------------------------------------*)
- (* Error types for .ARC and .LBR files *)
- (*----------------------------------------------------------------------*)
-
- CONST
- Open_Error = 1 (* Error when opening file *);
- Format_Error = 2 (* .ARC/.LBR format bad *);
- End_Of_File = 3 (* End of .ARC/.LBR directory *);
-
- (*----------------------------------------------------------------------*)
- (* Global program variables *)
- (*----------------------------------------------------------------------*)
-
- CONST
- FF_Char : CHAR = ^L (* Form feed character *);
-
- TYPE
- Output_Buffer = ARRAY[1..4096] OF CHAR;
-
- VAR
- Cat_Drive : CHAR (* Drive to catalog *);
- Output_File : TEXT (* File to receive output *);
- Output_File_Name : AnyStr (* Output file name *);
- Output_File_Buffer : Output_Buffer (* Output file buffer *);
- Do_Printer_Format : BOOLEAN (* Format for printer *);
- Left_Margin : INTEGER (* Left margin *);
- Page_Size : INTEGER (* Page size for output *);
- Expand_Arcs : BOOLEAN (* TRUE to expand .ARC/.LBR *);
- Expand_Arcs_In : BOOLEAN (* TRUE to expand .ARC/.LBR *)
- (* in main catalog list *);
- Left_Margin_String : AnyStr (* Blanks for left margin *);
- ArcLbr_Indent : INTEGER (* Indent for .ARC/.LBR *);
- User_Break : BOOLEAN (* TRUE if ^C stops liting *);
- Find_Spec : AnyStr (* File spec for listing *);
- Entry_Spec : AnyStr (* Entry spec for listing *);
- Entry_Name : AnyStr (* Name portion, entry spec *);
- Entry_Ext : AnyStr (* Extension, entry spec *);
- Use_Entry_Spec : BOOLEAN (* TRUE to use entry spec *);
- Total_Files : LONGINT (* Total files found *);
- Total_Space : LONGINT (* Total space used *);
- Total_Entries : LONGINT (* Total entries found *);
- Total_ESpace : LONGINT (* Total space used, entries*);
- Total_Dirs : LONGINT (* Total dirs scanned *);
- Page_Number : INTEGER (* Current page number *);
- Lines_Left : INTEGER (* Lines left on cur. page *);
- Help_Only : BOOLEAN (* TRUE if doing help only *);
-
- (*----------------------------------------------------------------------*)
- (* Titles and subtitles for paginated listings *)
- (*----------------------------------------------------------------------*)
-
- VAR
- Volume_Title : AnyStr (* Main title for entire listing *);
- Subdir_Title : AnyStr (* Current subdirectory title *);
- File_Title : AnyStr (* Current .ARC/.LBR file if any *);
-
- (*----------------------------------------------------------------------*)
- (* Saved file names from nested directories *)
- (*----------------------------------------------------------------------*)
-
- CONST
- MaxFiles = 2048 (* Maximum files handled *);
-
- TYPE
-
- Short_Dir_Record = RECORD
- File_Attr : BYTE (* File attributes *);
- File_Time : LONGINT (* Creation time *);
- File_Size : LONGINT (* Size in bytes *);
- File_Name : STRING[12] (* File name *);
- END;
-
- VAR
- (* List of files in current and all *)
- (* previous directories along path *)
- (* back to root directory. *)
-
- File_Stack : ARRAY[1..MaxFiles] OF Short_Dir_Record;
-
- (* # of files currently saved *)
- File_Count : INTEGER;
-
- (*----------------------------------------------------------------------*)
- (* Names of the months for date conversions *)
- (*----------------------------------------------------------------------*)
-
- (* STRUCTURED *) CONST
- Month_Names : ARRAY[1..12] OF STRING[3] =
- ('Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun',
- 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec' );