Design: 04.02.03.02/P11
This is an abstract, language-independent design. Grim
details may be found in the
corresponding source code.
You may return to the
documentation
for the module containing this program design, or to the
entire hierarchical table of
topics covered by the PVT.
PROGRAM 11: Text bundle index
CHARACTERISTICS: ynny
OPERATOR SCRIPT:
DEFINED TEXT INDICES: All text primitives but one are identical
(drawn with the same attributes). Identify the text primitive
that is different.
UNDEFINED TEXT INDICES: A reference text primitive is drawn above
a line with several other text primitives beneath it. Normally,
all of these will have the same attributes as the reference text
primitive. Count up and report the number of text primitives
below the line which match the reference text primitive in font,
precision, expansion, spacing, and color.
DESIGN:
set all ASFs to BUNDLED
<inquire workstation state table lengths> to determine
szbt = maximum size of text bundle table
*** *** *** text index *** *** ***
TEST: #SR 3 4 5 6
"A defined text index should cause the addressed entry in
the bundle table to be used when rendering a text
primitive."
bundis = number of bundles to be displayed = min(8, szbt)
set all text bundles in bundis to:
font = 1
precision = STROKE
expansion = 0.7
spacing = 0.1
color = 1
bundif = randomly selected bundle from bundis
set text bundle #bundif to:
font = 2
precision = STROKE
expansion = 1.1
spacing = 0.1
color = 1
Display and label the text primitive for each bundle in bundis
OPQA/DEFINED TEXT INDICES: which text primitive is different?
pass/fail depending on (text primitive with attributes from
bundle #bundif selected)
TEST: #SR 3 4 5 7
"An undefined text index should cause bundle number 1 in
the text bundle table to be used when rendering a text
primitive."
set text bundle #1 to:
font = 2
precision = STROKE
expansion = 0.8
spacing = 0.2
color = 2
u1,u2,u3 = 3 undefined, positive indices - all greater than
maximum defined index in bundle table (szbt)
explct = number of explicit text primitives using bundle #1 =
random integer from 0 to 4
draw reference text primitive "Test text" with bundle #1 near top
of display
draw line underneath
display interleaved, below line:
three text primitives "Test text" using bundle index u1,u2,u3,
explct text primitives "Test text" using bundle index 1
OPQA/UNDEFINED TEXT INDICES: How many of the text primitives
below the line have the same text attributes as the reference
text primitive above it?
pass/fail depending on (response = 3+explct)
END PROGRAM 11