/*-------------------------------------------------------------------+ | Copyright (c) 1996, SAS Institute Inc. | | Unpublished - All Rights Reserved | | S A S / C S A M P L E | | | | NAME: FSSLALL | | LANGUAGE: C | | PURPOSE: This program displays "HELLO, WORLD!" using SAS/C | | FSSL functions. See Example 1 pg. 32 in the | | SAS/C Full Screen Support Library User's Guide, | | Second Edition. | | (modified slightly to make it All resident) | | | | MVS - | | COMPILE, LINK: SUBMIT prefix.SAMPLE.AUX(FSSLALL) | | where "prefix" is the installation defined high-level| | qualifier for the SAS/C product. | | EXECUTE: execute under TSO, see below | | TSO - | | COMPILE: LC370 CLIST | | LINK: CLK370 CLIST | | EXECUTE: CALL your.load.lib(FSSLALL) | | | | MISC NOTES: SAS/C FSSL must be installed. | | | +-------------------------------------------------------------------*/ #define RES_FSSLSTD /* Include support for FSSL */ /* under TSO or CMS */ /*#define RES_FSSLISPF Include support for FSSL */ /* under ISPF interface */ #include /* Needed for All-Resident */ #include /* Standard header */ #include /* FSSL header */ #include /* Needed for sleep fn. */ char str[] ="HELLO, WORLD!"; /* String displayed */ void main(void) { char errmsg[132]; /* Error message buffer */ struct FS_TERMATTR *attr_ptr; /* Terminal attributes structure */ char *panel="panel"; /* Unique panel name */ /* initialize the field length,attributes, color */ int field_len = sizeof(str) - 1; int attr= PROTECTED | BRIGHT | BLINK ; int color=RED; /********************************************/ /* Begin Full-Screen Support Library Calls */ /********************************************/ fsinit(errmsg); /* Initialize full-screen env. */ attr_ptr=fsrttm();/* Return ptr to term. attrib. */ /********************************/ /* Define a panel and one field */ /********************************/ fsdfpn(panel,attr_ptr->prim_row, attr_ptr->prim_col); fsdffd(panel,1,12,33,field_len,str, &attr,color,BLANK); /*******************************************/ /* Display the panel and associated fields */ /*******************************************/ fsdspn(panel, DFLTVIEW, 1, 1, 1, 1, FS_FORCE); sleep(5); /* Pause for display */ /*************************************/ /* Terminate full-screen environment */ /*************************************/ fsterm(); }