******************************************************************************** * * Display the current terminal type * * Module %M% Version %I% Date %H% * * (c) Copyright 1998 Ardent Software Inc. - All Rights Reserved * This is unpublished proprietary source code of Ardent Software Inc. * The copyright notice above does not evidence any actual or intended * publication of such source code. * ******************************************************************************* * * Maintenence log - insert most recent change descriptions at top * * Date.... GTAR# WHO Description......................................... * 10/14/98 23801 SAP Change copyrights. * 06/25/96 18695 EAP Fixed to handle PADDING.CHARACTER of \200 * 04/05/95 15740 JC Added fields 15 and 16 for NLS map information. * 09/14/93 12302 JSW Use 64 as PI/Open flavor (see flavor.h) * 07/16/93 12302 ALC Converted to produce either PI/open format or * uniVerse format of SYSTEM.RETURN.CODE dependant * on the value returned by the SYSTEM(1001) func. * 06/11/93 11665 MGM On some terminals PADDING.CHARACTER is \200 or * SQLNUL. The src buffer would be set to null by * Fconcat. I removed PADDING.CHARACTER since * it does not seem to be used. * 07/25/88 - - Maintenence log purged at 5.2.1, see release 5.1.10. * ******************************************************************************* $include UNIVERSE.INCLUDE TERMINFO quiet = 0 flavor = system(1001) dim line(6) matparse line from upcase(trim(@sentence)), " " if inmat() = 0 then x = 6 else x = inmat() for i = 1 to x if line(i) = "HUSH" then quiet = 1; i = 99 next * Independant fields * src = @term.type src := @fm:@CRTWIDE src := @fm:@CRTHIGH if flavor = 64 then src := @fm:not(AUTOMATIC.RIGHT.MARGIN) end else src := @fm:AUTOMATIC.RIGHT.MARGIN end src := @fm:'0' src := @fm:if VIDEO.SPACES < 0 then "0" else VIDEO.SPACES * Flavour dependant fields * if flavor = 64 then if ISNULL(PADDING.CHARACTER) then src := @fm:"" end else src := @fm:PADDING.CHARACTER end src := @fm:field(TERMINAL.NAME, "|", dcount(TERMINAL.NAME,"|")) src := @fm:INIT.2STRING src := @fm:"Press any key to continue..." src := @fm:"any key" src := @fm:"no" src := @fm src := @fm:@TTY end else src := @fm:field(TERMINAL.NAME, "|", dcount(TERMINAL.NAME,"|")) src := @fm:"Press any key to continue..." src := @fm:"any key" if ISNULL(PADDING.CHARACTER) then src := @fm:"" end else src := @fm:PADDING.CHARACTER end src := @fm:INIT.2STRING src := @fm:"no" src := @fm src := @fm:@TTY end * Add NLS map information src := @fm:system(103) src := @fm:system(104) if not(quiet) then print src<7>:" (":src<1>:")" print "Width : ":src<2> print "Depth : ":src<3> if system(100) then print "Map : ":src<15> end end @system.return.code = src