Design: 04.02.03.02/P10
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 10: Appearance of predefined text bundles
CHARACTERISTICS: ynny
OPERATOR SCRIPT:
WORKSTATION DESCRIPTION AND STATE LIST TABLES, INDICES 1-6: This
screen displays 7 pairs (consisting of the first 6, with one
repeated) of predefined text bundles and individual text
attributes. Identify the pair of text primitives that is
different.
WORKSTATION DESCRIPTION AND STATE LIST TABLES, INDICES > 6: This
screen displays several pairs (at most 8) of predefined text
bundles and individual text attributes. Identify the pair of
text primitives that is different.
PREDEFINED TEXT BUNDLES: This screen displays a sample (at most
8) of predefined text bundles and their bundle values for font,
precision, expansion, spacing, and color, as reported by <inquire
predefined text representation>. For each displayed bundle,
verify that 1) the actual appearance of the text agrees with the
aspect values reported on the screen and 2) these both agree with
any external documentation provided by the implementor.
DESIGN:
set all ASFs to BUNDLED
use <inquire text facilities> to determine:
nprei = number of predefined bundles
*** *** *** predefined text bundles 1-6 *** *** ***
numbun = 7
bundis = bundles to be displayed (1 to 6, with one repeated)
bundif = location of repeated bundle identifier (so that all 6
may be verified)
TEST: #SR 3 6 20 24
"Immediately after <open workstation>, the first 6 defined
text bundles of the WSL should appear as specified in
the corresponding predefined text bundles of the WDT."
The actual results (text primitives drawn from initial state of WSL)
are drawn on the left side of the picture. The corresponding
expected results (text primitives with individual attributes taken
from WDT) are drawn on the right side, except for one
text primitive which will be different.
actual:
for ix = 1 to numbun
display and label text "Bundles 1-6", under control of bundles
in bundis(ix)
next ix
expected:
set font, precision, expansion, spacing, and color ASF to individual
for ix = 1 to numbun
<inquire predefined text representation> on index
bundis(ix), determine:
pdfn = font
pdpr = precision
pdex = expansion
pdsp = spacing
pdci = color index
if (ix = bundif) then
if (pdfn = 1) then
pdfn = 2
else
pdfn = 1
endif
endif
draw text with pdfn, pdpr, pdex, pdsp, pdci
next ix
OPQA/WORKSTATION DESCRIPTION AND STATE LIST TABLES, INDICES 1-6:
Which pair of text primitives does NOT match?
pass/fail depending on (operator selects bundif)
*** *** *** predefined text bundles > 6 *** *** ***
if nprei <= 6 then
skip to end_comp_tables
endif
numbun = min (8, nprei-6)
bundis = distinct bundles to be displayed - randomly chosen
from [7,nprei] predefined bundles
TEST: #SR 3 6 20 24
"Immediately after <open workstation>, the defined text
bundles > 6 of the WSL should appear as specified in the
corresponding predefined text bundles of the WDT."
The actual results (text primitives drawn from initial state of WSL)
are drawn on the left side of the picture. The corresponding
expected results (text primitive with individual attributes copied
from WDT) are drawn on the right side, except for one
text primitive which will be different.
actual:
for ix = 1 to numbun
display and label text "Bundles > 6", under control of bundles
in bundis(ix)
next ix
expected:
set font, precision, expansion, spacing, and color ASF to individual
for ix = 1 to numbun
<inquire predefined text representation> on index
bundis(ix), determine:
pdfn = font
pdpr = precision
pdex = expansion
pdsp = spacing
pdci = color index
if (ix = bundif) then
if (pdfn = 1) then
pdfn = 2
else
pdfn = 1
endif
endif
draw text with pdfn, pdpr, pdex, pdsp, pdci
next ix
OPQA/WORKSTATION DESCRIPTION AND STATE LIST TABLES, INDICES > 6:
Which pair of text primitives does NOT match?
pass/fail depending on (operator selects bundif)
end_comp_tables:
*** *** *** *** predefined bundle descriptions *** *** *** ***
TEST: #SR 3 6 20
"The appearance of predefined text bundles should agree
with the descriptions supplied by the implementor."
numbun = min(8, nprei)
bundis = distinct bundles to be displayed, sorted
use two loops here so that plain text can be used for labelling
set all ASFs to BUNDLED
for ix = 1 to numbun
draw text "Phigs" using bundle bundis(ix)
next ix
set all ASFs to INDIVIDUAL
for ix = 1 to numbun
<inquire predefined text representation> on index
bundis(ix) to determine:
pdfn = font
pdpr = precision
pdex = expansion
pdsp = spacing
pdci = color index
display and label values for pdfn, pdpr, pdex, pdsp, pdci
next ix
OPQA/PREDEFINED TEXT BUNDLES: Does the appearance of each
text primitive agree with the displayed aspect values for that
bundle?
if (operator responds "yes") then
OPQA/PREDEFINED TEXT BUNDLES: If the implementor provides
external documentation, is it consistent with the
appearance of the text primitive and with the displayed
aspect values for every bundle identifier?
pass/fail depending on (operator responds "yes")
else
fail
endif
END PROGRAM 10