Google
 

Trailing-Edge - PDP-10 Archives - bb-h138e-bm_tops20_v6_1_distr - 6-1-sources/scrrev.bli
There are 10 other files named scrrev.bli in the archive. Click here to see a list.
 %TITLE 'SCRREV - reverse video screen mode'
MODULE SCRREV (				! Reverse video screen mode
		IDENT = '1-002'			! File: SCRREV.BLI Edit: JBS1002
		) =
BEGIN
!
!			  COPYRIGHT (c) 1981, 1985 BY
!	      DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.
!		ALL RIGHTS RESERVED.
!
! THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND  COPIED
! ONLY  IN  ACCORDANCE  WITH  THE  TERMS  OF  SUCH  LICENSE AND WITH THE
! INCLUSION OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR  ANY  OTHER
! COPIES  THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY
! OTHER PERSON.  NO TITLE TO AND OWNERSHIP OF  THE  SOFTWARE  IS  HEREBY
! TRANSFERRED.
!
! THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT  NOTICE
! AND  SHOULD  NOT  BE  CONSTRUED  AS  A COMMITMENT BY DIGITAL EQUIPMENT
! CORPORATION.
!
! DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR  RELIABILITY  OF  ITS
! SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DIGITAL.
!

!++
! FACILITY:	EDT -- The DEC Standard Editor
!
! ABSTRACT:
!
!	This module makes sure the screen is in reverse video.
!
! ENVIRONMENT:	Runs at any access mode - AST reentrant
!
! AUTHOR: Bob Kushlis, CREATION DATE: September 8, 1979
!
! MODIFIED BY:
!
! 1-001	- Original.  DJS 12-Feb-1981.  This module was created by
!	extracting the routine EDT$$SC_REVID  from module SCREEN.
! 1-002	- Regularize headers.  JBS 13-Mar-1981
!--

%SBTTL 'Declarations'
!
! TABLE OF CONTENTS:
!

REQUIRE 'EDTSRC:TRAROUNAM';

FORWARD ROUTINE
    EDT$$SC_REVID : NOVALUE;

!
! INCLUDE FILES:
!

REQUIRE 'EDTSRC:EDTREQ';

!
! MACROS:
!
!	NONE
!
! EQUATED SYMBOLS:
!

BIND
    REV_VIDEO = UPLIT (%STRING (%CHAR (ASC_K_ESC), '[7m'));

LITERAL
    REV_VIDEO_LEN = 4;

!
! OWN STORAGE:
!
!	NONE
!
! EXTERNAL REFERENCES:
!
!	In the routine
%SBTTL 'EDT$$SC_REVID  - reverse video the screen'

GLOBAL ROUTINE EDT$$SC_REVID 			! Make sure the screen is in reverse video
    : NOVALUE =

!++
! FUNCTIONAL DESCRIPTION:
!
!	This routine makes sure the screen is in reverse video mode.  Check
!	the flag, and if it is not, output the sequence to set reverse video
!	and set the reverse flag.
!
! FORMAL PARAMETERS:
!
!	NONE
!
! IMPLICIT INPUTS:
!
!	REVID
!	TI_TYP
!
! IMPLICIT OUTPUTS:
!
!	REVID
!
! ROUTINE VALUE:
!
!	NONE
!
! SIDE EFFECTS:
!
!	NONE
!
!--

    BEGIN

    EXTERNAL ROUTINE
	EDT$$FMT_LIT;

    EXTERNAL
	REVID,				! is reverse video on?
	TI_TYP;				! Terminal type.

    IF (.TI_TYP EQL TERM_VT100)
    THEN

	IF (.REVID EQL 0)
	THEN
	    BEGIN
	    EDT$$FMT_LIT (CH$PTR (REV_VIDEO), REV_VIDEO_LEN);
	    REVID = .REVID + 1;
	    END;

    END;


END
ELUDOM