next up previous contents index
Next: GKSPACK Error Messages Up: GKSPACK Previous: GKSPACK

List of routines

  1. CALL GCATOG(WKID) or CALL GCGTOA(WKID)

    Input:

    WKID
    GKS workstation identifier of the terminal (INTEGER).

    GCGTOA and GCATOG work only on GKSGRAL with the CERN-supplied driver versions as the routines require modifications to the driver code. The DECGKS version tests the workstation type; if it is VXUIS or VXXW it does nothing, otherwise it writes an error message on the file GKSPACK.ERR.

    The routines change a terminal from graphics to alpha mode (GCGTOA) and from alpha to graphics mode (GCATOG). The terminal must be an activated GKS workstation. Thus they allow the application to perform FORTRAN I/O to the terminal during a graphics session. The effect on the terminal depends on its capabilities. For example, as Pericom PG terminals do not have a dialog area, calling GCGTOA causes the bell to ring and the program then halts until the operator presses return. This gives the user time to look at the image drawn in graphics mode before switching the screen to the alpha-numeric bit plane. However, on terminals with a dialog area (e.g. Pericom MG series and Tektronix 4107 compatible terminals), the FORTRAN I/O will appear immediately overlayed with the graphics.

    After the FORTRAN I/O has been performed the application must call GCATOG to reset the graphics environment. Note that GCGTOA returns immediately, without waiting for a user action. Thus, if one wishes the program to wait until the user has read a message and is ready to continue, then it is essential to include a READ statement, as the following program fragment illustrates:

          CALL GCGTOA (WKID)
          WRITE(*,*) ' GIVE X COORDINATE: '
    C  Wait for a reply
          READ (*,*) X
          CALL GCATOG (WKID)
    
  2. CALL GCCDWN(WKID, RWIN, TITLE)

    This routine is described fully in section on Page gif. The DECGKS version is a dummy.

    Input:

    WKID (I)
    Workstation Identifier
    RWIN (R*4)
    Window Size
    TITLE (C)
    Window title
  3. CALL GCINIT(IDTERM, TERMTP, IDFILE, LUFILE, KERFIL)

    Input:

    IDTERM
    GKS workstation ID for terminal (INTEGER). If ≤0 or in batch no terminal is assigned.
    TERMTP
    GKS terminal workstation type (INTEGER). Note that this number depends on the terminal and the GKS implementation you are using.
    IDFILE
    GKS workstation ID for disk file output (INTEGER). No file is output if ≤0 .
    LUFILE
    FORTRAN logical unit number for disk file output (INTEGER). Not used if IDFILE ≤0 .
    KERFIL
    FORTRAN logical unit number for the GKS error file (INTEGER).

    GCINIT provides an easy initialization of GKS for interactive or batch applications. If TERMTP=0 GCINIT will prompt the interactive user for the terminal type and connection ID. LUFILE and KERFIL are Fortran logical unit numbers and no file names are assigned as these can easily be provided by the user. Note that the logical unit numbers 91, 92, 93 are reserved for GKSGRAL and, to avoid nasty surprises, do not use 5, 6 or 7. The current values for LUFILE and their effect are:

         LUFILE<=0    An interactive dialog will guide the user.
       0<LUFILE<100   GKS Appendix E metafile on unit LUFILE.
     100<LUFILE<200   PostScript file on unit LUFILE-100.
     200<LUFILE<300   Encapsulated PostScript file on LUFILE-200.
    1000<LUFILE<1100  Tektronix 4014 style file on unit LUFILE-1000
    
    For example, LUFILE=109 would produce PostScript output on the Fortran file defined by logical unit=9. Output of Tektronix 4014 escape codes is available under VMS and Aegis. It can be provided under VM/CMS if requested.

  4. CALL GCGIMP (MAXTYP, GKSNWT, GKSSYN, GKSWCN, GKSWTP)

    Supplies information in implementation file. See introduction to this section for file naming details.

    Input:

    MAXTYP (I)
    maximum number of wk types (i.e. dimension of output arrays)

    Output:

    GKSNWT (I)
    number of wk types in the implementation file
    GKSSYN (C*6)
    array (dimension MAXTYP) with the workstation types names (e.g. "VXUIS ")
    GKSWCN (I)
    array (dimension MAXTYP) with the workstation connection id's
    GKSSYN (I)
    array (dimension MAXTYP) with the workstation types integer values (e.g. 41)
  5. CALL GCIMPL(IMPLEM)

    Supplies implementation name string.

    Output:

    IMPLEM (C*6)
    Name of implementation
    .pa
  6. CALL GCGWTC(WKTYP, CONID)

    Asks the user to enter interactively a workstation type, and provides the list of the available workstation types if the user enters '?'. Automatically returns to the program the connection id to be used for the selected workstation type.

    Output:

    WKTYP (I)
    Workstation Type
    CONID (I)
    Connection Id
  7. CALL GCNAME(WKID, STRING)

    Input:

    WKID (I)
    GKS workstation identifier of the metafile receiving the frame (INTEGER).
    STRING (C*7)
    The name of the frame (CHARACTER*(*)).

    GCNAME enables the user to give the name 'STRING' to the current frame when output to a metafile for inclusion in compound documents. The name 'STRING' may also be used by GRVIEW and GRCONV to select frames on the metafile. Users of this facility must place the call to GCNAME before outputting any primitives to a new frame. For examples of its use, see on Page gif and on Page gif.

    Restrictions: Only the first 7 characters of 'STRING' are used. If less than 7 characters are given 'STRING' will be padded with '$'s (dollars). For VM/CMS system reasons, the character set for 'STRING' can only contain upper-case alphabetic, the digits 0-9, and the dollar sign ('$'), so lower-case characters are converted to upper-case.

  8. CALL GCQWKN(WKID, IERR, CONID, WKNAM)

    Analog to the routine GQWKC but returns a workstation type name instead of a workstation type integer value.

    Input:

    WKID (I)
    Workstation Id

    Output:

    IERR (I)
    value returned by GQWKC
    CONID (I)
    Connection Id
    WKNAM (C*6)
    Workstation Name (e.g. "VXUIS ")
  9. CALL GCSDWN(WKTYP, RWIN, TITLE)

    This routine is described fully in section on Page gif. The DECGKS version is a dummy.

    Input:

    WKTYP (I)
    Workstation Type
    RWIN (R*4)
    Window Size
    TITLE (C)
    Window title
  10. CALL GCSTOP

    GCSTOP deactivates and closes all GKS workstations and closes GKS.

  11. CALL GCWTPC(WKTYP, WKTSYN)

    Returns the workstation type name corresponding to a workstation type integer value.

    Input:

    WKTYP (I)
    Workstation Type (e.g. 41 for DECGKS)

    Output:

    WKSTYN (C*6)
    Workstation Type Name (e.g. "VXUIS ")
  12. CALL GCWTPI(WKTSYN, CONID, WKTYP)

    Get workstation type and connection id corresponding to a given workstation type name (e.g. 'VXXW').

    Input:

    WKSTYN (C*6)
    Workstation Type Name

    Output:

    WKTYP (I)
    Workstation Type
    CONID (I)
    Connection Id
  13. CALL GPRMPT(WKID, PROMPT, LSTRI, REPLY)

    Input:

    WKID
    GKS workstation identifier of the terminal (INTEGER).
    PROMPT
    Application prompt (CHARACTER *(*)).

    Output:

    LSTRI
    Length of reply (INTEGER).
    REPLY
    User reply (CHARACTER).

    GPRMPT gives a prompt and waits for a reply from the user in a GKS interactive graphics program. As an example, GPRMPT could be used to hold a picture on the screen until the user was ready to view the next one, or terminate the program. If the user hits only a Carriage Return then LSTRI=0 and 'REPLY' is not defined. For example:

          CALL GPRMPT(WKID, 'Type RETURN or QUIT', LSTRI, REPLY)
          IF(LSTRI.GT.0) THEN
    C       Call STOPPG to do whatever you want to do on QUIT
            IF REPLY(1:4) .EQ. 'QUIT') CALL STOPPG
          ENDIF
    

    Currently the prompt is put into a GKS segment which is deleted after the reply. If a segment is open when GPRMPT is called, the prompt will be added to it but it will not be deleted. This could be confusing and should be avoided by closing an open segment before calling GPRMPT. If the workstation is not a terminal or the job is in batch GPRMPT does nothing.

    Restrictions: If GPRMPT is used repeatedly within one picture, the prompts will overprint if the terminal does not have selective erasure. If long prompts and/or small workstation windows are used the prompt will be truncated.

  14. CALL GRQSK(WKID, LDSTK, NMAX, ISTATS, IT, NP, PX, PY)

    Emulates the GTSGRAL request stroke (locator loop) which requires a button push to input each point. This is in contrast to the DECGKS implementation of GRQSK which reads the current cursor position in a loop with fixed time or position intervals. If it is intended to use this routine to replace the version of GRQSK in the GKS library it must be linked ahead of the library.

    Input:

    WKID (I)
    Workstation Identifier
    LDSTK (I)
    Stroke logical device
    NMAX (I)
    Maximum number of points

    Output:

    ISTATS (I)
    Status
    IT (I)
    Normalization Transformation Number
    NP (I)
    Number of points returned
    PX (I*NMAX)
    X coordinates
    PY (I*NMAX)
    Y coordinates
  15. CALL GUARC(XM,YM,XP,YP,XH,YH,XQ,YQ)

    Emulation of GTS-GRAL utility to draw a circular arc defined by 4 points.

    Input:

    XM, YM
    Mid point of arc
    XP, YP
    Start point
    XH, YH
    Point on arc
    XQ, YQ
    Point on end radius of arc
  16. CALL GUBEZ1(N,XP,YP)

    Emulation of GTS-GRAL utility to draw a Bezier curve defined by a Bezier polygon.

    Input:

    N (I)
    Dimension of XP, YP
    XP, YP
    Points on Bezier polygon
    .pa
  17. CALL GUCIR1(XM,YM,XP,YP)

    Emulation of GTS-GRAL utility to draw a circle defined by (midpoint, peripheral point).

    Input:

    XM, YM
    Mid point of circle
    XP, YP
    Peripheral point on circle
  18. CALL GUCIR2(XM,YM,R)

    Emulation of GTS-GRAL utility to draw a circle defined by (midpoint, radius).

    Input:

    XM, YM
    Mid point of circle
    R
    Radius
  19. CALL GUCUR1(N,XP,YP)

    Emulation of GTS-GRAL utility to draw a curve defined by interpolating points.

    Input:

    N (I)
    Dimension of XP, YP
    XP, YP
    Points in polygon.
  20. CALL GUELL1(XM,YM,A,B)

    Emulation of GTS-GRAL utility to draw an ellipse defined by (midpoint, semi-axes). An ellipse is drawn with midpoint XM,YM; the length of semi-axis in the X-direction is A, and in the Y-direction is B.

    Input:

    XM, YM
    Midpoint of Ellipse
    A, B
    Semi-axes of ellipse in X and Y directions
  21. CALL GUELL2(XM,YM,A,B,BEGRAD,ENDRAD,ROTATE)

    Emulation of GTS-GRAL utility to draw an elliptical arc specified by the midpoint XM,YM, the size of the semi-axes in direction X and Y (A, B), and BEGRAD and ENDRAD which define the radius of the start and end points. The ellipse is rotated with angle ROTATE in an anti-clockwise direction.

    Input:

    XM, YM
    Midpoint of Ellipse
    A, B
    Semi-axes of ellipse in X and Y directions
    BEGRAD
    Angle of arc start point
    ENDRAD
    Angle of arc end point
    ROTATE
    Angle of anti-clockwise rotation
    .pa
  22. CALL GUMEN2(WK,DNR,CHECXL,CHECXH,CHECYL,CHECYH,MENU)

    Emulation of GTS-GRAL utility to define a menu in a given echo area.

    Input:

    WKID (I)
    Workstation Id
    DNR (I)
    Device Number
    CHECXL
    Echo area X Lower Bound
    CHECHL
    Echo area X Higher Bound
    CHECYL
    Echo area Y Lower Bound
    CHECYL
    Echo area Y Higher Bound
    MENU (C)
    String of menu items separated by ',' and terminated by '.'.
  23. CALL GUNERR(N)

    Dummy routine which writes error message to file GTSTODEC.ERR.

    Output:

    N
    Number of GKS errors which occurred.
  24. CALL GUSIGD(FLAG)

    Dummy routine which writes error message to file GTSTODEC.ERR.

    Input:

    FLAG (L)
    Set (.TRUE.) or reset (.FALSE.) simulation flag.


next up previous contents index
Next: GKSPACK Error Messages Up: GKSPACK Previous: GKSPACK


Janne Saarela
Mon Apr 3 17:00:12 METDST 1995