



      SUBROUTINE SHOWTEXTIF (TEXT)



















      IMPLICIT      NONE
      CHARACTER*(*) TEXT
      LOGICAL       AHEAD







      IF (.NOT.AHEAD()) CALL SHOWTEXT (TEXT)





      RETURN
      END
      SUBROUTINE SHOWTEXT (TEXT)

















      IMPLICIT      NONE
      INCLUDE       'BIGINC.INC'
      INCLUDE       'OPTION.INC'
      INTEGER       LENTXT, I, GVFLEN, NLINES
      CHARACTER*(*) TEXT
      CHARACTER*80  BUF(MAXOPT)







      IF (TEXT(1:1).NE.'?') THEN
         IF (WIFPAR(1012).NE.0) CALL GVSTT6 ('?M4346')
         IF (GVFLEN(TEXT).GT.0) THEN
            CALL GVSFMT ('?FMT1341')
            WRITE (6,FMT,ERR=998) TEXT(1:GVFLEN(TEXT))
         END IF
         CALL GVSKIL
         GOTO 998
      END IF



      LENTXT=GVFLEN(TEXT)
      IF (LENTXT.LE.1) THEN
         CALL GVSTT6 ('?M4347')
         GOTO 998
      END IF



      CALL OPENUNIT88
      CALL CGETTEXT (TEXT,LENTXT,BUF,NLINES,MAXOPT) 
      DO 100 I=1,NLINES
         CALL GVSTT6 (BUF(I))
  100 CONTINUE



  998 CONTINUE


      RETURN
      END
      SUBROUTINE SHOWTEXTU (INUNIT,TEXT)

















      IMPLICIT      NONE
      INCLUDE       'BIGINC.INC'
      INCLUDE       'OPTION.INC'
      INTEGER       LENTXT, I, GVFLEN, NLINES, IUNIT, INUNIT
      LOGICAL       GVFFOP, GVFIBN
      CHARACTER*(*) TEXT
      CHARACTER*80  BUF(MAXOPT)







      IF (TEXT(1:1).NE.'?') THEN
         IF (WIFPAR(1012).NE.0) CALL GVSTT6 ('?M4348')
         IF (GVFLEN(TEXT).GT.0) THEN
            IF (WIFPAR(1012).NE.0) THEN
               CALL GVSFMT ('?FMT1341')
               WRITE (6,FMT,ERR=998) TEXT(1:GVFLEN(TEXT))
            ELSE
               CALL GVSFMT ('?FMT027A')
               WRITE (6,FMT,ERR=998) TEXT(1:GVFLEN(TEXT))
            END IF
         END IF
         CALL GVSKIL
         GOTO 998
      END IF
      IUNIT=INUNIT
      IF (.NOT.GVFIBN(IUNIT,1,120)) THEN
         CALL GVSTTE ('?M4821')
         CALL GVSKIL
         IUNIT=6
      ELSE
         IF (.NOT.GVFFOP(IUNIT)) THEN
            CALL GVSFMT ('?FMT1341')
            WRITE (6,FMT,ERR=998) IUNIT
            CALL GVSKIL
            GOTO 998
         END IF
      END IF



      LENTXT=GVFLEN(TEXT)
      IF (LENTXT.LE.1) THEN
         CALL GVSTT6 ('?M4349')
         GOTO 998
      END IF



      CALL CGETTEXT (TEXT,LENTXT,BUF,NLINES,MAXOPT) 
      DO 100 I=1,NLINES
         CALL GVSTTU (IUNIT,BUF(I))
  100 CONTINUE



  998 CONTINUE


      RETURN
      END
      SUBROUTINE SHOWTEXTTEX (TEXT)

















      IMPLICIT      NONE
      INCLUDE       'BIGINC.INC'
      INTEGER       LENTXT, I, GVFLEN, NLINES
      CHARACTER*(*) TEXT
      CHARACTER*80  BUF(60), LOCLIN







      IF (TEXT(1:1).NE.'?') THEN
         CALL GVSTT6 ('?M4350')
         IF (GVFLEN(TEXT).GT.0) THEN
            CALL GVSFMT ('?FMT1431')
            WRITE (6,FMT,ERR=998) TEXT(1:GVFLEN(TEXT))
         END IF
         CALL GVSKIL
         GOTO 998
      END IF



      LENTXT=GVFLEN(TEXT)
      IF (LENTXT.LE.1) THEN
         CALL GVSTT6 ('?M4351')
         GOTO 998
      END IF



      CALL OPENUNIT88
      CALL CGETTEXT (TEXT,LENTXT,BUF,NLINES,60) 
      DO 100 I=1,NLINES
         CALL GVSCTB (LOCLIN,80)
         CALL GVSSTX (LOCLIN,BUF(I))
         CALL TEXTXT (LOCLIN)
  100 CONTINUE



  998 CONTINUE


      RETURN
      END
      SUBROUTINE GETTEXT (INTEXT)

















      IMPLICIT      NONE
      INCLUDE       'BIGINC.INC'
      INTEGER       LENTXT, I, GVFLEN, NLINES
      CHARACTER*(*) INTEXT
      CHARACTER*80  BUF
      SAVE          BUF







      IF (INTEXT(1:1).NE.'?') THEN
         CALL GVSTT6 ('?M4354')
         IF (GVFLEN(INTEXT).GT.0) THEN
            CALL GVSFMT ('?FMT1343')
            WRITE (6,FMT,ERR=998) INTEXT(1:GVFLEN(INTEXT))
         END IF
         CALL GVSKIL
         GOTO 998
      END IF



      LENTXT=GVFLEN(INTEXT)



      CALL OPENUNIT88
      CALL CGETTEXT (INTEXT,LENTXT,BUF,NLINES,1) 
      IF (NLINES.EQ.0) THEN
         CALL GVSTTB ('?M4353')
         CALL GVSFMT ('?FMT1343')
         WRITE (6,FMT,ERR=998) INTEXT
         CALL GVSCTB (INTEXT,LEN(INTEXT))
         GOTO 998
      END IF





      DO 10 I=1,MIN(LEN(INTEXT),80)
         INTEXT(I:I)=BUF(I:I)
 10   CONTINUE
      IF (LEN(INTEXT).GT.80) THEN
         DO 20 I=81,LEN(INTEXT)
            INTEXT(I:I)=' '
 20      CONTINUE
      END IF



  998 CONTINUE


      RETURN
      END
      SUBROUTINE OPENUNIT88

















      IMPLICIT      NONE
      INCLUDE       'BIGINC.INC'
      LOGICAL       FIRST
      INTEGER       GVFLEN, I, L
      CHARACTER*132 LOCLIN
      CHARACTER*12  MESNAM
      SAVE          FIRST, MESNAM
      DATA FIRST    /.TRUE./
      DATA MESNAM   /'MESSAGES.TXT'/







      IF (FIRST) THEN
         CALL GVSCTB (LOCLIN,132)
         FIRST=.FALSE.
         L=GVFLEN(WHERIS)
         IF (L.LE.0) CALL GVSKIL
         DO 10 I=1,L
            LOCLIN(I:I)=WHERIS(I:I)
   10    CONTINUE
         DO 20 I=1,12
            LOCLIN(L+I:L+I)=MESNAM(I:I)
   20    CONTINUE
         CALL INITTEXT (LOCLIN,L+12)
      END IF





      RETURN
      END
      SUBROUTINE SETLANG (NEWLANG)

















      IMPLICIT      NONE
      INCLUDE       'LANGUA.INC'
      CHARACTER*(*) NEWLANG







      LANGUAGE=NEWLANG(1:1)
      CALL TEXTLANG (LANGUAGE)
      IF (LANGUAGE.EQ.'D') CALL SHOWTEXT ('?M0152')





      RETURN
      END
