Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ psetexttextrep(3P+) — PHIGS 1.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

SET EXTENDED TEXT REPRESENTATION(3P+)  —  MISC. REFERENCE MANUAL PAGES

NAME

SET EXTENDED TEXT REPRESENTATION − use to define an extended text attribute representation bundle on a workstation

SYNOPSIS

C Syntax

void
psetexttextrep ( wsid, index, rep )
Pintwsid;workstation identifier
Pintindex;text bundle index number
Pexttxbundl∗rep;pointer to extended text representation

FORTRAN Syntax

SUBROUTINE psetr ( WKID, INDEX, TFONT, TPREC, TCEXPF, TSPACE, COLMOD, ITCOLR, TCOLR )
INTEGERWKIDworkstation identifier
INTEGERINDEXtext bundle index
INTEGERTFONTtext font
INTEGERTPRECtext precision
REALTCEXPFtext character expansion factor
REALTSPACEtext character spacing
INTEGERCOLMODcolour model
INTEGERITCOLRindirect colour index
REALTCOLR(3)direct colour value

Required PHIGS Operating States

(PHOP, WSOP, ∗, ∗)

DESCRIPTION

Purpose

SET EXTENDED TEXT REPRESENTATION defines an extended text attribute representation bundle on a workstation. 

This is a SunPHIGS Extension function based on PHIGS+ and is not part of the PHIGS standard. 

C Input Parameters

All of the following data types are predefined in phigs.h. 

wsidThe identifier of the workstation. 

indexThis is an index to the workstation text bundle table. 

repA pointer to a Pexttxbundl structure. Pexttxbundl is defined as:

typedef struct {
Pintfont;/∗ text font ∗/
Ptxprecprecision;/∗ text precision ∗/
Pfloatexp;/∗ character expansion factor ∗/
Pfloatspace;/∗ character spacing ∗/
Pgcolrcolour;/∗ text colour ∗/
} Pexttxbundl;

Ptxprec is defined as:

typedef enum {
PPSTRING,
PPCHAR,
PPSTROKE
} Ptxprec;

Pgcolr is defined as:

typedef struct {
Pint type;/∗ indirect, RGB, CIE, HSV, HLS ∗/
union {
   Pintindex;/∗ colour table index ∗/
   struct {
Pfloatx;/∗ red, hue, etc. ∗/
Pfloaty;/∗ green, saturation, lightness, etc. ∗/
Pfloatz;/∗ blue, value, saturation, etc. ∗/
   } general;
} val;
} Pgcolr;

FORTRAN Input Parameters

All of the following data types are predefined in phigs77.h. 

WKIDThe identifier of the workstation for which the text representation is being defined. 

INDEX
The index into the specified workstation text bundle table.

TFONT
The text font.

TPREC
The text precision.

TCEXPF
The text character expansion factor.

TSPACE
The text character spacing.

COLMOD
The colour model.  The predefined values are:

0PINDIRColour Index Specified
1PRGBRed, Green, and Blue
2PCIECIE Colour Model
3PHSVHue, Saturation, and Value
4PHLSHue, Lightness, and Saturation

ITCOLR
An integer index into the workstation colour table for determining the text colour. This value is only used if COLMOD is equal to PINDIR. 

TCOLR(3)
An array of reals containing the text colour. This array is unused if COLMOD is equal to PINDIR. 

TCOLR(1) = Red, Hue, etc.
TCOLR(2) = Green, Saturation, Lightness, etc.
TCOLR(3) = Blue, Value, Saturation, etc.

Execution

In the text bundle table of the workstation state list, the given index is associated with the specified parameters. 

The text precision value determines the fidelity with which the other aspects are used. The values of text precision, in order of increasing fidelity, are STRING, CHAR, and STROKE. During structure traversal, if the specified text precision is not available on a workstation, the value STRING is used on that workstation. 

The character expansion factor specifies the deviation of the width to height ratio of the characters from the ratio indicated by the font designer. During structure traversal, only the magnitude of the character expansion factor is considered. If the result of taking the absolute value of the character expansion factor value is less than the smallest supported character expansion factor on a workstation, the smallest supported character expansion factor on that workstation is used. 

Character spacing specifies how much additional space is inserted between two adjacent character bodies. Character spacing is specified as a fraction of the font-nominal character height. 

Text colour is a general colour, either an indirect or a direct colour in a specified colour model. If an indirect colour is specified and the specified colour index is not available during structure traversal, then colour index one is used. 

The extended text bundle table in the workstation state list has predefined entries taken from the workstation description table. A number of these entries are predefined for every workstation of category OUTPUT or OUTIN. Any table entry, including the predefined entries, may be redefined with this function. 

When either text, or annotation text, is displayed during structure traversal, the current text index in the PHIGS traversal state list refers to an entry in the extended text bundle table. If the current text index is not present in the extended text bundle table, then text index one is used. The setting of the corresponding Aspect Source Flags(ASFs) determines which aspects in the entry are used. 

ERRORS

003Ignoring function, function requires state (PHOP, WSOP, ∗, ∗)

054Ignoring function, the specified workstation is not open

059Ignoring function, the specified workstation does not have output capability (i.e., the workstation category is neither OUTPUT, OUTIN, nor MO)

103Ignoring function, setting this bundle table entry would exceed the maximum number of entries allowed in the workstation bundle table

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

110Ignoring function, the specified colour model is not available on the workstation

113Ignoring function, the colour index value is less than zero

SEE ALSO

SET INDIVIDUAL ASF (3P)
INQUIRE EXTENDED TEXT REPRESENTATION (3P+)
SET TEXT REPRESENTATION (3P)

Sun Release 4.0  —  Last change: 7 July 1989

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