Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ escape_-9(3P) — PHIGS 1.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

ESCAPE -9(3P)  —  SUNPHIGS LIBRARY

NAME

ESCAPE -9 − inquire extended text extent

SYNOPSIS

C Syntax

void
pescape ( func_id, in, out )
Pintfunc_id;escape function identifier
Pescapein∗in;input data for the function
Pescapeout∗out;OUT output data of the function

FORTRAN Syntax

SUBROUTINE pesc ( FCTID, LIDR, IDR, MLODR, LODR, ODR )
INTEGERFCTIDfunction identification
INTEGERLIDRdimension of input data record array
CHARACTER∗80IDR(LIDR) input data record
INTEGERMLODRmaximum length of output data record
INTEGERLODROUT number of array elements used in ODR
CHARACTER∗80ODR(MLODR) OUT output data record

Required PHIGS Operating States

(PHOP, ∗, ∗, ∗)

DESCRIPTION

Purpose

ESCAPE -9 performs the same function as INQUIRE TEXT EXTENT using the character sets and extended fonts attributes. 

C Input Parameters

func_id
The function identifier for this escape is PUESC_INQ_EXTENDED_TEXT_EXTENT, which is defined in phigs.h to be -9. 

in
A pointer to a Pescapein union containing the input data record uesc9_idatarec. It is defined as follows:

typedef struct {
Pwstypewst;/∗ workstation type ∗/
Pintcharset[4];/∗ character sets ∗/
Pintfont[4];/∗ extended fonts ∗/
Pfloatexp;/∗ char expansion factor ∗/
Pfloatsp;/∗ char spacing ∗/
Pfloatht;/∗ char height ∗/
Ptxpathpath;/∗ text path ∗/
Ptxhorhor;/∗ horizontal alignment ∗/
Ptxverver;/∗ vertical alignment ∗/
Pchar∗str;/∗ text string ∗/
} Puesc0009_idatarec;

The fields in this record correspond to the input parameters of INQUIRE TEXT EXTENT with one additional field to specify the character sets, and with a set of fonts instead of one. 

wstThe workstation type to use to resolve the font. 

charset
The character sets. See the Set Character Set for Codeset section of GENERALIZED STRUCTURE ELEMENT for the valid values. A character set is specified for each EUC code set. 

fontsThe fonts.  See the Set Font for Codeset section of GENERALIZED STRUCTURE ELEMENT for the valid values.  A font is specified for each EUC code set. 

expThe character expansion factor.  See SET CHARACTER EXPANSION FACTOR for the valid values. 

spThe character spacing.  See SET CHARACTER SPACING for the valid values. 

htThe character height.  See SET CHARACTER HEIGHT for the valid values. 

pathThe text path.  See SET TEXT PATH for the valid values. 

horThe horizontal alignment.  See SET TEXT ALIGNMENT for the valid values. 

verThe vertical alignment.  See SET TEXT ALIGNMENT for the valid values. 

strA pointer to the text string. 

C Output Parameters

outA pointer to a Pescapeout union containing the output data record, uesc9_odatarec.  It is defined as follows:

typedef struct {
Pinterror_ind;/∗ error indicator ∗/
Prectrect;/∗ extent rectangle ∗/
Ppointoffset;/∗ concatenation offset ∗/
} Puesc0009_odatarec;

The fields in this record correspond to the output parameters to INQUIRE TEXT EXTENT. 

error_ind
The error indicator.

rectA Prect structure in which to return the text extent.  Prect is defined in phigs.h as:

typedef struct {
Ppointll;/∗ lower left ∗/
Ppointur;/∗ upper right ∗/
} Prect;

Ppoint is defined in phigs.h as:

typedef struct {
Pfloatx;/∗ x coordinate ∗/
Pfloaty;/∗ y coordinate ∗/
} Ppoint;

offsetA Ppoint structure in which to return the concatenation offset. 

FORTRAN Input Parameters

FCTID
The function identifier of this escape is PUESCINQXTXEXT, which is defined in phigs77.h to be -9. 

LIDR
The dimension of IDR (returned by PACK DATA RECORD). 

IDR(LIDR)
An ESCAPE data record packed by PACK DATA RECORD when called with:

ILThe number of integers = 12. 

IAContains twelve integer values. 

Element 1 is the workstation type identifier. 

Elements 2 through 5 are the character sets for codesets 0 through 3.  See the Set Character Set for Codeset section of GENERALIZED STRUCTURE ELEMENT for the valid values. 

Element 6 through 9 are the fonts for codesets 0 through 3.  See the Set Font for Codeset section of GENERALIZED STRUCTURE ELEMENT for the valid values. 

Element 10 is the text path. See SET TEXT PATH for the valid values. 

Element 11 is the horizontal alignment. See SET TEXT ALIGNMENT for the valid values. 

Element 12 is the vertical alignment. See SET TEXT ALIGNMENT for the valid values. 

RLThe number of real values = 3. 

RAContains three real values. 

Element 1 is the character expansion factor. See SET CHARACTER EXPANSION FACTOR for the valid values. 

Element 2 is the character spacing. See SET CHARACTER SPACING for the valid values. 

Element 3 is the character height. See SET CHARACTER HEIGHT for the valid values. 

SLThe number of strings = 1. 

LSTRContains one integer, the length of the string. 

STRContains the string. 

MLODR
The maximum length of the output data record, ODR. 

FORTRAN Output Parameters

LODRThe length used in the output data record array, ODR. 

ODR(MLODR)
The output data record is stored in this array. When the output data record is passed to UNPACK DATA RECORD, the following fields should be returned:

ILThe number of integers = 1. 

IAContains the error indicator. 

RLThe number of real values = 6. 

RAContains six real values:

Element 1 is the x value of the lower left corner of the extent box. 

Element 2 is the x value of the upper right corner of the extent box. 

Element 3 is the y value of the lower left corner of the extent box. 

Element 4 is the y value of the upper right corner of the extent box. 

Element 5 is the x value of the concatenation offset. 

Element 6 is the y value of the concatenation offset. 

SLThe number of strings = 0. 

Execution

The Inquire Extended Text Extent escape performs the same function as INQUIRE TEXT EXTENT using the character sets and extended fonts attributes.  See INTRO_INTERNATIONALIZATION (7P) for a description of these attributes. 

ERRORS

-155Specified character set is invalid. 

-156Warning, one or more of the of the requested fonts is not available for

002Ignoring function, function requires state (PHOP, ∗, ∗, ∗)

052Ignoring function, workstation type not recognized by the implementation

059Ignoring function, the specified workstation does not have output capability

106Ignoring function, the specified font is not available for the requested text precision on the specified workstation

351Ignoring function, one of the fields within the escape data record is in error

SEE ALSO

INTRO INTERNATIONALIZATION (7P)
INQUIRE TEXT EXTENT (3P)

Sun Release 4.0  —  Last change: 31 July 1989

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026