Listing: 1 (******************************************************************************) 2 (* SAMPLE04.MOD *) 3 (* *) 4 (* metaPort Usage *) 5 (* Taken from SAMPLE04.PAS - Metagraphics Software Corporation (c) 1987-1989 *) 6 (* *) 7 (* PSW 10/31/90 09:07pm *) 8 (******************************************************************************) 9 10 MODULE Sample04; 11 (* 12 * Graphix 13 * Release 3.7 14 * (c) Copyright 1986-1992 PMI 15 * Green Bay, Wisconsin 16 * (414) 468-6040 17 * All rights reserved 18 * 19 *) 20 21 IMPORT GrQry; 22 IMPORT GrConst; 23 IMPORT GrPorts; 24 IMPORT Meta; 25 IMPORT IO; 26 27 VAR 28 GrafixCard, 29 CommPort: INTEGER; 30 i, j, k: INTEGER; 31 scrnR: GrConst.rect; ***** ^ not supported yet 32 scrnPort, 33 alertPort: GrPorts.adsPort; ***** ^ not supported yet 34 alertPortRcd: GrPorts.metaPort; (* Allocate the port record *) ***** ^ not supported yet 35 36 PROCEDURE Alert(); 37 VAR 38 entryPort: GrPorts.adsPort; ***** ^ not supported yet 39 BEGIN 40 Meta.GetPort(entryPort); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 41 Meta.SetPort(alertPort); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 42 Meta.SetPort(entryPort) ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 43 END Alert; ***** ^ not supported yet 44 45 BEGIN 46 (* init the system *) 47 48 GrQry.GrInit(GrafixCard, CommPort); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 49 50 i := Meta.InitGrafix(-GrafixCard); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 51 52 IF (i # 0) THEN 53 (* Display reason for no go *) 54 GrQry.GrInitErr(GrafixCard, CommPort, i); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 55 END; 56 57 Meta.ScreenRect(scrnR); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 58 Meta.SetDisplay(GrConst.GrafPg0); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 59 Meta.EraseRect(scrnR); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 60 Meta.GetPort(scrnPort); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 61 62 alertPort := ADR(alertPortRcd); ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 63 Meta.InitPort(alertPort); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 64 65 Alert(); ***** ^ not supported yet ***** ^ not supported yet 66 67 Meta.SetPort(scrnPort); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 68 69 GrQry.GrQuit('', 0); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 70 END Sample04. 50 errors