[ Previous | Next | Contents | Glossary | Home | Search ]
The graPHIGS Programming Interface: ISO PHIGS Subroutine Reference

SET EDIT MODE (PHOP,*,*,*)

Purpose

Use Set Edit Mode to set the current edit mode entry of the graPHIGS API state list to INSERT or REPLACE. If the application does not use this subroutine, then the edit mode defaults to INSERT.

When the application moves an element into an open structure, the edit mode determines how the element is to be placed into the structure:

  1. If the edit mode is set to REPLACE, then the graPHIGS API deletes the element at the element pointer. The incoming element takes its place. The graPHIGS API does not move the element pointer (so if another element is to be placed into the structure, then it replaces the last element that was just placed into the structure). If the element pointer is set to element 0, then the graPHIGS API inserts the incoming element into the structure and sets the element pointer to element 1.

  2. If the edit mode is set to INSERT, then the graPHIGS API inserts the incoming element into the open structure after the element at the element pointer. The graPHIGS API then increments the element pointer by 1 to point to the new element.

    The edit mode does not affect elements copied into the open structure by the Copy All Elements From Structure subroutine.

    Language Bindings

  3. C

    pset_edit_mode (edit_mode)

    Input Parameters

    Pedit_mode edit_mode
    Edit mode (0=PEDIT_INSERT, 1=PEDIT_REPLACE).

    FORTRAN

    PSEDM (editmo)

    Input Parameters

    integer editmo
    Edit mode (0=PINSRT, 1=PREPLC).

    Errors

    2
    Function Requires State (PHOP,*,*,*)

    Related Subroutines

  4. Inquire Edit Mode


  5. [ Previous | Next | Contents | Glossary | Home | Search ]