DEC GKS DEC PHIGS Building a Device Handler System for DEC GKS and DEC PHIGS

*HyperReader

  CONTENTS

  Title Page

  Copyright Page

  Preface

  1      Introduction

  1.1     Writing Handlers for Your Devices

  1.2     Device Handlers

  2      How GKS Works

  2.1     The GKS System
    2.1.1      Inquiries
    2.1.2      Transformations
    2.1.3      Input
    2.1.4      Output

  2.2     Communication Between the Kernel and Your Handler
    2.2.1      DEC GKS Data Types
    2.2.2      Parameter Passing

  3      How PHIGS Works

  3.1     The PHIGS System
    3.1.1      Inquiries
    3.1.2      Transformations
    3.1.3      Input
    3.1.4      Output

  3.2     Communication Between the Kernel and Your Handler
    3.2.1      DEC PHIGS Data Types
    3.2.2      Parameter Passing

  4      Building a Device Handler System

  4.1     Learning About Your Device

  4.2     Hardcopy Output Devices

  4.3     Building WDT Structures
    4.3.1      LIST_LINETYPES
    4.3.2      PREDEF_PLINE_BUNDLES
    4.3.3      LIST_MARKERS
    4.3.4      PREDEF_PMARK_BUNDLES
    4.3.5      LIST_FONT_INFORMATION
    4.3.6      TEXT_BUNDLES
    4.3.7      FILL_BUNDLES
    4.3.8      HATCH_STYLE
    4.3.9      PATT_BUNDLES
    4.3.10     COLOR_BUNDLES
    4.3.11     LIST_OF_GDP
    4.3.12     LIST_OF_ESCAPES
    4.3.13     PET_ARRAY
    4.3.14     INPUT_DEVICE_CHARACTERISTICS
    4.3.15     CHARACTER_INFO
    4.3.16     CHOICE_LIST
    4.3.17     ECHO_AREA_ARRAY
    4.3.18     ECHO_AREA_SET
    4.3.19     APPLICATION_PET_MAP_LIST

  4.4     Building the WDT
    4.4.1      Building the WDT for an MO Device Handler

  4.5     Sample WDT

  5      Device Handler Functions

  5.1     Parameter Passing

  5.2     Message and Constant Files

  5.3     Supporting Several Devices with a Single Handler

  5.4     Developing the Local Data Area Table

  5.5     Reentrance

  5.6     Opening the Workstation
    INQUIRE LOCAL DATA
    WORKSTATION INITIALIZATION

  5.7     Closing the Workstation
    WORKSTATION EXIT

  5.8     Required Output Functions
    CLEAR WORKSTATION
    DRAW LINE
    SET COLOR INDEX

  5.9     Optional Output Functions
    DRAW CELL ARRAY
    DRAW FILL AREA
    DRAW GDP
    DRAW MARKER
    HIGHLIGHT EXTENT
    DRAW TEXT
    SET CLIPPING RECTANGLE
    SET PATTERN REPRESENTATION
    SET COLOR REPRESENTATION

  5.10    Supplemental Text Functions
    INQUIRE FONT DESCRIPTION
    SET REALIZED TEXT

  5.11    Output Utility Function
    WS_MANAGER_UPDATE_VIEWPORT

  5.12    Input Functions
    5.12.1     HANDLER INPUT QIO
    5.12.2     ULTRIX Child Processes and SIGIO Handlers
    HANDLER INPUT
    WS_MANAGER_UPDATE_INPUT

  5.13    Optional Input Functions
    INPUT ARC
    INPUT CIRCLE
    INPUT ELLIPSE
    INPUT LINE
    INPUT MARKER
    INPUT OPTIONS
    INPUT TEXT
    SET INPUT TEXT
    INITIALIZE INPUT

  5.14    Other Optional Functions
    INQUIRE PIXEL ARRAY
    ESCAPE
    FREE WDT
    FLUSH OUTPUT
    MESSAGE
    INQUIRE WORKSTATION DESCRIPTION TABLE

  6      Assembling Your Device Handler

  6.1     Building the Device Function Table

  6.2     Building the VMS-Specific Device Function Table for GKS and PHIGS
    6.2.1      Linking Your Handler

  6.3     Building the ULTRIX-Specific Device Function Table for GKS
    6.3.1      Modifying DEC GKS Configuration File
    6.3.2      Linking the Application and New Device Handler with DEC GKS

  6.4     Building the ULTRIX-Specific Device Function Table for PHIGS
    6.4.1      Modifying the DEC PHIGS Configuration File
    6.4.2      Linking the Application and the New Device Handler with PHIGS

  6.5     Defining Device Handler Logical Names on VMS Systems
    6.5.1      Handler Logical Names
    6.5.2      Defining Device Handler Logical Names for GKS
    6.5.3      Defining Device Handler Logical Names for PHIGS
    6.5.4      Adding Logical Names to STARTUP.COM

  A   Sample Device Handler Program

  B   Device Handler Function Examples

  C   Device Handler Function Table Template

  EXAMPLES

  4-1        WDT Structure

  6-1        Sample DFT-Building Macro

  FIGURES

  1-1        The Application, Kernel, and Handlers

  1-2        Device Handler Diagram

  5-1        X and Y Vectors

  5-2        Pixel Array Dimensions

  TABLES

  1-1 Programming Languages Supported for Device Handlers

  2-1        GKS State Lists and Description Tables

  2-2        GKS Coordinate Systems

  2-3        DEC GKS Data Types

  2-4        Passing Mechanisms for DEC GKS Data Types

  3-1        PHIGS State Lists and Description Tables

  3-2        PHIGS Coordinate Systems

  3-3        DEC PHIGS Data Types

  3-4        Passing Mechanisms for DEC PHIGS Data Types

  4-1        Device Handler Workstation Description Table Structure

  4-2        Device Handler WDT Structure for an MO Device Handler

  5-1        Required and Optional Functions by Workstation Type

  5-2        Files that Define Status Codes and Constants

  5-3        Local Data Area Table Elements for All Workstation Types

  5-4        Local Data Area Table Contents for INPUT and OUTIN Handlers

  5-5        Local Data Area Table Contents for OUTIN and OUTPUT Handlers

  5-6        DRAW LINE ASF Flags-Bit Assignments

  5-7        DRAW FILL AREA ASF Flags-Bit Assignments

  5-8        DRAW MARKER ASF Flags-Bit Assignments

  5-9        DRAW TEXT ASF Flags-Bit Assignments

  5-10       Input Codes

  5-11       Input Events Data

  6-1        Keywords for DFT Functions