Document Area
This section contains information on the document area of a WordPerfect 5.1 file that uses
single-byte and multi-byte codes.
Single-byte codes include control characters (values 1 to 31 [0x1F]), ASCII characters (values 32
to 126 [0x20 to 0x7E], space to tilde), and single-byte functions (values 128 to 191 [0x80 to
0xBF]). The values 0, 255 (0xFF), and 127 (0x7F) must not appear as single codes in a
WordPerfect document.
Multi-byte codes include fixed- and variable-length functions. These functions consist of a
group of bytes rather than a single byte and always begin and end with a function code (values
192 to 255 [0xC0 to 0xFF]) that indicates the type of function.
The multi-byte function codes are separated into two groups: fixed-length and variable-length.
The fixed-length functions have a predetermined length and have the following structure:
Begin function code (192-207 [0xC0-0xCF])
Data bytes
..
..
End function code (same as begin function code)
The smallest fixed-length, multi-byte function is at least three bytes long and consists of the
function code, a single data byte, and the function code again.
Each variable-length, multi-byte function has a subfunction code that follows the function code
and a short integer (16 bits), Length on each end of the function:
Begin function code (byte) (208-255 [0xD0-0xFF])
Begin subfunction code (byte)
Length (short)
Data bytes
..
..
Length (short)
End subfunction code (byte) (same as begin subfunction code)
End function code (byte) (same as begin function code)
Note: When creating a multi-byte function, the "old values" should be reserved with a 0 (null).
WordPerfect reformats retrieved files, inserts old values along with the existing new values, and
formats according to the new values (with the exception of footnotes). WordPerfect compares
the old values with the new values. WordPerfect formats to the set defaults--or as close to the
original as WP5.1 can calculate.
The hash value is an internal function of WordPerfect that does not have a purpose for a
third-party interface. A value of 0 can be placed in the code for any hash value to reserve space
in the function. This lets WordPerfect use that offset internally, as needed.
The smallest variable-length, multi-byte function is at least nine bytes long. The function code
for a variable-length function typically indicates a "class" or group of functions, and the
subfunction code gives the specific function within that group. The Length field is always the
number of data bytes in the function minus four. (The length does not include the beginning
Length and function codes.)
A variable-length, multi-byte function code that has a text field in it (that is, "Footnote text,"
"Endnote text," "Text box text," etc.) obeys all of the same rules as the body of the WordPerfect
document area.
This text field can have many of the same function codes that are found in the body of the
document. So don't assume that there is only text in these fields any more than you would
assume that there is just text in the main body of a WordPerfect document file. This "nesting" of
function codes inside of the text fields of other function codes is quite common and should
always be expected.
The following sections contain lists of the five different code types found in a WordPerfect 5.1
document: control characters; ASCII characters; single-byte functions; fixed-length, multi-byte
functions; and variable-length, multi-byte functions.
Note: When you design code to read a WordPerfect document, remember that WPCorp codes
may be added to at any time. So design your reading code to encounter any possible code, and
not just the specific, un-reserved codes that are documented here.
If your reading code doesn't recognize the code, it should skip over the code and read the next
piece of information in the file.
As a help, the defined lengths of the unused 200-207 (0xC8-0xCF) function codes are
documented at the end of the Fixed-Length, Multi-Byte Functions section.
Control Characters (0x01 to 0x1F)
Value | Control Character | Meaning | |
1 | Ctrl-A | Reserved | |
2 | Ctrl-B | Page # printed here | |
3 | Ctrl-C | Merge codes C | |
4 | Ctrl-D | Merge codes D | |
5 | Ctrl-E | Merge codes E | |
6 | Ctrl-F | Merge codes F | |
7 | Ctrl-G | Merge codes G | |
8 | Ctrl-H | Reserved | |
9 | Ctrl-I | Reserved | |
10 (0xA) | Ctrl-J | Hard return | |
11 (0xB) | Ctrl-K | Soft page | |
12 (0xC) | Ctrl-L | Hard page | |
13 (0xD) | Ctrl-M | Soft return | |
14 (0xE) | Ctrl-N | Merge codes N | |
15 (0xF) | Ctrl-O | Merge codes O | |
16 (0x10) | Ctrl-P | Merge codes P | |
17 (0x11) | Ctrl-Q | Merge codes Q | |
18 (0x12) | Ctrl-R | Merge codes R | |
19 (0x13) | Ctrl-S | Merge codes S | |
20 (0x14) | Ctrl-T | Merge codes T | |
21 (0x15) | Ctrl-U | Merge codes U | |
22 (0x16) | Ctrl-V | Merge codes V | |
23 (0x17) | Ctrl-W | Reserved | |
24 (0x18) | Ctrl-X | Reserved | |
25 (0x19) | Ctrl-Y | Reserved | |
26 (0x1A) | Ctrl-Z | Reserved | |
27 (0x1B) | Ctrl-[ | Reserved | |
28 (0x1C) | Ctrl-\ | Reserved | |
29 (0x1D) | Ctrl-] | Reserved | |
30 (0x1E) | Ctrl-^ | Reserved | |
31 (0x1F) | Ctrl-_ | Reserved |
See the WordPerfect 5.0 Reference Manual.
For information about the DOS third-party interface codes, see the DOS Third-Party Interface section of the PC Developer's Toolkit manual.
ASCII Characters (32 to 126 [0x20 to 0x7E])
Value | Character | |
32 (0x20) | Space | |
33 (0x21) | ! | |
34 (0x22) | " | |
35 (0x23) | # | |
36 (0x24) | $ | |
37 (0x25) | % | |
38 (0x26) | & | |
39 (0x27) | ' | |
40 (0x28) | ( | |
41 (0x29) | ) | |
42 (0x2A) | * | |
43 (0x2B) | + | |
44 (0x2C) | , | |
45 (0x2D) | - | |
46 (0x2E) | . | |
47 (0x2F) | / | |
48 (0x30) | 0 | |
49 (0x31) | 1 | |
50 (0x32) | 2 | |
51 (0x33) | 3 | |
52 (0x34) | 4 | |
53 (0x35) | 5 | |
54 (0x36) | 6 | |
55 (0x37) | 7 | |
56 (0x38) | 8 | |
57 (0x39) | 9 | |
58 (0x3A) | : | |
59 (0x3B) | ; | |
60 (0x3C) | < | |
61 (0x3D) | = | |
62 (0x3E) | > | |
63 (0x3F) | ? | |
64 (0x40) | @ | |
65 (0x41) | A | |
66 (0x42) | B | |
67 (0x43) | C | |
68 (0x44) | D | |
69 (0x45) | E | |
70 (0x46) | F | |
71 (0x47) | G | |
72 (0x48) | H | |
73 (0x49) | I | |
74 (0x4A) | J | |
75 (0x4B) | K | |
76 (0x4C) | L | |
77 (0x4D) | M | |
78 (0x4E) | N | |
79 (0x4F) | O | |
Value | Character | |
80 (0x50) | P | |
81 (0x51) | Q | |
82 (0x52) | R | |
83 (0x53) | S | |
84 (0x54) | T | |
85 (0x55) | U | |
86 (0x56) | V | |
87 (0x57) | W | |
88 (0x58) | X | |
89 (0x59) | Y | |
90 (0x5A) | Z | |
91 (0x5B) | [ | |
92 (0x5C) | \ | |
93 (0x5D) | ] | |
94 (0x5E) | ^ | |
95 (0x5F) | _ | |
96 (0x60) | ` | |
97 (0x61) | a | |
98 (0x62) | b | |
99 (0x63) | c | |
100 (0x64) | d | |
101 (0x65) | e | |
102 (0x66) | f | |
103 (0x67) | g | |
104 (0x68) | h | |
105 (0x69) | i | |
106 (0x6A) | j | |
107 (0x6B) | k | |
108 (0x6C) | l | |
109 (0x6D) | m | |
110 (0x6E) | n | |
111 (0x6F) | o | |
112 (0x70) | p | |
113 (0x71) | q | |
114 (0x72) | r | |
115 (0x73) | s | |
116 (0x74) | t | |
117 (0x75) | u | |
118 (0x76) | v | |
119 (0x77) | w | |
120 (0x78) | x | |
121 (0x79) | y | |
122 (0x7A) | z | |
123 (0x7B) | { | |
124 (0x7C) | | | |
125 (0x7D) | } | |
126 (0x7E) | ~ | |
Value | Meaning | |
128 (0x80) | Temporary (always deleted) | |
129 (0x81) | Right justification ON (WP5.0) | |
130 (0x82) | Right justification OFF (WP5.0) | |
131 (0x83) | Soft end center/align | |
132 (0x84) | Reserved | |
133 (0x85) | Temporary (place saver) | |
134 (0x86) | Center page top to bottom | |
135 (0x87) | Columns ON | |
136 (0x88) | Columns OFF (at top of page) | |
137 (0x89) | Reserved | |
138 (0x8A) | Widow/Orphan ON | |
139 (0x8B) | Widow/Orphan OFF | |
140 (0x8C) | Combination hard return/soft page added for WP5.1 | |
141 (0x8D) | Footnote/Endnote # (inside footnote/endnote) | |
142 (0x8E) | Figure # (inside caption) | |
143 (0x8F) | Hard end of center/align added for WP5.1 | |
144 (0x90) | Deletable return at end of line (DSRt) |
Note: The WP formatter creates the DSRt. It cannot be used by programmers.
145 (0x91) | Deletable return at end of page (DSPg) | |
146 (0x92) | End of page that is deleted when forward formatted | |
147 (0x93) | Invisible return in line (SRt that turns into a space) | |
148 (0x94) | Invisible return at end of line (147 [0x93] turns into this code at end of line) | |
149 (0x95) | Invisible return at end of page (147 [0x93] turns into this code at end of page) | |
150 (0x96) | Block ON | |
151 (0x97) | Block OFF | |
152 (0x98) | Table of contents page # place holder | |
153 (0x99) | Dormant hard return added for WP5.1 | |
154 (0x9A) | Cancel hyphenation | |
155 (0x9B) | End of generated text (end of table of contents) | |
156 (0x9C) | Reserved | |
157 (0x9D) | Reserved | |
158 (0x9E) | Hyphenation OFF | |
159 (0x9F) | Hyphenation ON | |
160 (0xA0) | Hard space | |
161 (0xA1) | Do subtotal | |
162 (0xA2) | Subtotal entry | |
163 (0xA3) | Do total | |
164 (0xA4) | Total entry | |
165 (0xA5) | Do grand total | |
166 (0xA6) | Calculation column | |
167 (0xA7) | Math ON | |
168 (0xA8) | Math OFF | |
169 (0xA9) | Hard hyphen in line (The <Home><-> command in the user interface) |
Value | Meaning | |
170 (0xAA) | Hard hyphen at end of line (169 [0xA9] is converted to this when at end of line) | |
171 (0xAB) | Hard hyphen at end of page (169 [0xA9] is converted to this when at end of page) |
Note: Codes 170 (0xAA) and 171 (0xAB) may not be at the end of a line or page if the document
was saved with "Fast Save" set to "Yes."
172 (0xAC) | Soft hyphen in line (The <CTRL><-> command from the user interface) | |
173 (0xAD) | Soft hyphen at end of line (172 [0xAC] is converted to this code if at end of line) | |
174 (0xAE) | Soft hyphen at end of page (172 [0xAC] is converted to this code if at end of page) | |
175 (0xAF) | Columns OFF at end of line | |
176 (0xB0) | Columns OFF at end of page | |
177 (0xB1) | Math negate | |
178 (0xB2) | Outline OFF added for WP5.1 | |
179 (0xB3) | Reverse Direction On Hebrew/Arabic versions only | |
180 (0xB4) | Reverse Direction Off Hebrew/Arabic versions only | |
181-188 (0xB5-0xBC) | Reserved | |
189 (0xBD) | Auto code placement on added for WP5.1 UNIX only | |
190 (0xBE) | Auto code placement off added for WP5.1 Unix only | |
191 (0xBF) | Unknown single-byte function | |
Function Name: Extended Character
Size in Bytes: 4
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (192 [0xC0]) | |
1 | 1 byte | Character code | |
2 | 1 byte | Character set (0-0-12 [0xC]) See WordPerfect Reference. | |
3 | 1 byte | End function code (192 [0xC0]) | |
Function Name: Center/Align/Tab/Left Margin Release
Size in Bytes: 9
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (193 [0xC1]) | |
1 | 1 byte | Flags: | |
bit 0 = reserved | |||
bit 1 = 0 if the type (tab, align, etc.) is hard added for WP5.1 | |||
= 1 if soft tab | |||
bit 2 = 1this bit will be set when a tab is entered within a table, for positioning within the table cell (Ctrl-V, Tab) added for WP5.1 | |||
bit 3 = 0 align on alignment character or center on column | |||
= 1 right-justified tab or centered tab | |||
bit 4 = 1 dot leader | |||
bit 5 = 1 center between margins, flush right to right margin | |||
bits 6-7 | |||
= 0 tab | |||
= 1 align (bit 6 set if center or align) | |||
= 2 left margin release | |||
= 3 center | |||
2 | short | Absolute position of start text (wpu) | |
4 | short | Absolute center/align/tab position (wpu) | |
6 | short | Screen column position of start text (su) modified for WPWin 5.1 | |
8 | 1 byte | End function code (193 [0xC1]) | |
Use the following formula to determine if a document came from DOS or Windows. Offset 2 is
position in wpu's; Offset 6 is position in screen units.
if( (screen units > 0) && (document is WP5.1 format) )
then
result = position wpu's/screen units
if ( (result > 3) && (result < 30) )
then document is a Windows type
column to view document = position wpu's/120
else document is DOS type
column to view document = screen units
end if
else document is WP5.0 format
column to view document = screen units
end if
Function Code: 194 (0xC2)
Function Name: Indent
Size in Bytes: 11
Structure: | Offset | Size | Meaning |
0 | 1byte | Begin function code (194 [0xC2]) | |
1 | 1byte | Flags: | |
bit 0 = 0 left indent | |||
= 1 left/right indent | |||
bit 4 = 1 dot leader | |||
2 | short | Difference between old and new temp margins (wpu) | |
4 | short | Absolute position of start of text (wpu) ("Old Current Column Number [su]" in WP5.0) | |
6 | short | Absolute indent position (wpu) | |
8 | short | Screen column position of start of text (su) modified for WPWin 5.1 | |
10 | 1 byte | End function code (194 [0xC2]) | |
Function Name: Attribute ON
Size in Bytes: 3
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (195 [0xC3]) | |
1 | 1 byte | Attribute type | |
0 = extra large | |||
1 = very large | |||
2 = large | |||
3 = small | |||
4 = fine | |||
5 = superscript | |||
6 = subscript | |||
7 = outline | |||
8 = italics | |||
9 = shadow | |||
10 (0xA) = redline | |||
11 (0xB) = double underline | |||
12 (0xC) = bold | |||
13 (0xD) = strikeout | |||
14 (0xE) = underline | |||
15 (0xF) = small caps | |||
21 byteEnd function code (195 [0xC3]) | |||
Function Name: Attribute OFF
Size in Bytes: 3
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (196 [0xC4]) | |
1 | 1 byte | Attribute type (same as Attribute ON) | |
2 | 1 byte | End function code (196 [0xC4]) | |
Function Name: Block Protect
Size in Bytes: 5
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (197 [0xC5]) | |
1 | 1 byte | Definition byte | |
0=Block Protect ON | |||
1=Block Protect OFF, outside of columns and inside of columns defined as "Parallel with Block Protect ON" | |||
3=Block Protect OFF inside any other type of column. | |||
2 | short | # of vertical 1200ths in block (wpu) | |
4 | 1 byte | End function code (197 [0xC5]) | |
Function Name: End of Indent
Size in Bytes: 6
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (198 [0xC6]) | |
1 | short | effective temporary right margin for the indent code associated with this end of indent (wpu) | |
3 | short | effective temporary left margin for the indent code associated with this end of indent (wpu) | |
5 | 1 byte | End function code (198 [0xC6]) | |
Function Name: Different Display Character when Hyphenated (applies only to International Language Modules)
Size in Bytes: 7
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (199 [0xC7]) | |
1 | 1 byte | Flags: | |
bit 0= 0 if no hyphenation next to function | |||
= 1 if word is hyphenated next to function | |||
bit 1 = 0 if function is after the hyphenation | |||
= 1 if function precedes the hyphenation | |||
2 | short | Character when in line | |
4 | short | Character when hyphenated | |
6 | 1 byte | End function code (199 [0xC7]) | |
Note: Function codes 200 through 207 (0xC8 through 0xCF) are reserved for future use. They
have the following defined lengths, so you can make your program upwardly compatible.
Function Code: 200 (0xC8)
Size in Bytes: 4
Function Code: 201 (0xC9)
Size in Bytes: 5
Function Code: 202 (0xCA)
Size in Bytes: 6
Function Code: 203 (0xCB)
Size in Bytes: 6
Function Code: 204 (0xCC)
Size in Bytes: 8
Function Code: 205 (0xCD)
Size in Bytes: 10
Function Code: 206 (0xCE)
Size in Bytes: 10
Function Code: 207 (0xCF)
Size in Bytes: 12
Variable-Length, Multi-Byte Functions (208 to 255 [0xD0 to 0xFF])
The following is a summary of the variable-length, multi-byte functions.
Subfunction | Function Name |
254 (0xFE) | Unknown |
Subfunction | Function Name | ||||||||
0 | Set Line Height | ||||||||
1 | Left/Right Margin Set | ||||||||
2 | Spacing Set | ||||||||
3 | Hyphenation Zone Set | ||||||||
4 | Tab Set | ||||||||
5 | Top/Bottom Margin Set | ||||||||
6 | Justification added for WP5.1
7
| Suppress Page Characteristics
| 8
| Page Number Position
| 11 (0xB)
| Form
| |
Subfunction | Function Name |
0 | Color |
1 | Font Change |
2 | Color (DrawPerfect) added for WP5.1 |
3 | Font Pattern Attributes (DrawPerfect) |
Subfunction
Function Name
| 0
| Define Math Columns
| 1
| Define Columns (Newpaper)
| 2
| Paragraph Number Definition
| 3
| Footnote Options
| 4
| Endnote Options
| 5
| Graphics Box Options for Figures
| 6
| Graphics Box Options for Tables
| 7
| Graphics Box Options for Text Boxes
| 8
| Graphics Box Options for User-Defined Boxes
| 9
| Graphics Box Options for Equations added for WP5.1
| 10 (0xA)
| Reserved
| 11 (0xB)
| Define Tables (Table Def) added for WP5.1
| 12 (0xC)
| Reserved
| 13 (0xD)
| Define Link Start added for WP5.1
| 14 (0xE)
| Define Link End addid for WP5.1
| 15 (0xF)
| Define DDE Link Start added for WP5.1
| 16 (0x10)
| Define DDE Link End added for WP5.1
| 17 (0x11)
| Border Options
| |
Subfunction | Function Name |
0 | Set Alignment Character |
1 | Set Underline Mode |
2 | Set Footnote Number |
3 | Set Endnote Number |
4 | Set Page Number |
5 | Line Numbering |
6 | Advance to Page Position |
7 | Force Odd/Even Page |
8 | Character at Baseline in Fixed Line Height added for 6/89 version of WP5.0 and for WP5.1 |
9 | Reserved |
10 (0xA) | Character/Space Width |
11 (0xB) | Space Expansion |
12 (0xC) | Set Graph Box Number for Figures |
13 (0xD) | Set Graph Box Number for Tables |
14 (0xE) | Set Graph Box Number for Text Boxes |
15 (0xF) | Set Graph Box Number for User-Defined Boxes |
16 (0x10) | Set Graph Box Number for Equations added for WP5.1 |
17 (0x11) | Set Language |
18 (0x12) | Set Page Number Style added for WP5.1 |
19 (0x13) | Set Direction Hebrew/Arabic WP5.1 only |
Subfunction | Function Name |
0 | End of Page Function (only group 0 required) |
1 | Beginning of Line Function added for WP5.1 |
2 | Graph Box Information Function |
3 | Marker for Repositioning |
4 | Function to Contain Non-Editable/Displayable Text added for WP5.1 |
5 | Justification Information added for WP5.1 |
6 | Valid On Marker for Undo added for WP5.1 |
7 | Valid On Marker for Undo added for WP5.1 |
8 | Invalid Function for Undo |
9 | Display Information for Table, Beginning for Row Codes |
14 (0xE) | Data Marker for Intellitag only |
Subfunction | Function Name |
0 | Header A |
1 | Header B |
2 | Footer A |
3 | Footer B |
0 | Footnote |
1 | Endnote |
Subfunction | Function Name |
0 | Begin Marked Text |
1 | End Marked Text |
2 | Define Marked Text |
3 | Index Entry |
4 | Table of Authority Entry |
5 | Endnotes Print Here |
6 | Save Page Information |
7 | Auto Reference Definition |
8 | Auto Reference Tag |
9 | Include Subdocument |
10 (0xA) | Start of Included Subdocument |
11 (0xB) | End of Included Subdocument |
Subfunction | Function Name |
0 | Date Function |
1 | Paragraph Number |
2 | Overstrike |
3 | Page Number Style Insert added for WP5.1 |
Subfunction | Function Name |
0 | Embedded Printer Command |
1 | Conditional End of Page Function |
2 | Comment |
3 | Kerning |
4 | Outline On added for WP5.1 |
5 | Leading Adjustment added for WP5.1 |
6 | Kerning |
7 | Kerning |
8 | Macro added for WP5.1 |
Subfunction | Function Name | ||||||
0 | Figure | ||||||
1 | Table | ||||||
2 | Text Box | ||||||
3 | User-Defined Box | ||||||
4 | Equation added for WP5.1
5
| Horizontal Line
| 6
| Vertical Line
| |
Subfunction | Function Name |
0 | Begin Style ON (paired) |
1 | End Style ON (paired) |
2 | Global ON (open style) |
3 | Style OFF |
Subfunction
Function Name
| 0
| Beginning of Column (Cell) at End of Line
| 1
| Beginning of Row at End of Line
| 2
| Table Off at End of Line
| 3
| Reserved
| |
Subfunction
Function Name
| 0
| Reserved
| 1
| Beginning of Row at End of Page
| 2
| Table Off at End of Page
| 3
| Beginning of Row/Hard Page Break
| |
Subfunction
Function Name
| 32-99 (0x20-0x63)
| Enhanced Merge Command Codes
| |
Subfunction
Function Name
| 0
| Equation Nested Function added for WP5.1
| |
Subfunction
Function Name
| 0
| Start Tag
| 1
| End Tag
| 2
| Conversion Rule
| 3
| Ignore On
| 4
| Ignore Off
| 5
| Entity Reference On
| 6
| Entity Reference Off
| |
Unknown is reserved for [UNKNOWN]
Subfunction: 254 (0xFE)
Function Name: Unknown
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (254 [0xFE]) | |
1 | 1 byte | Begin subfunction code (254 [0xFE]) | |
2 | short | Length (variable) | |
4 | variable | Data | |
.. | short | Length (variable) | |
.. | 1 byte | End subfunction code (254 [0xFE]) | |
.. | 1 byte | End function code (254 [0xFE]) | |
Function Code: 208 (0xD0)
Subfunction: 0
Function Name: Set Line Height
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (0) | |
2 | short | Length (8) | |
4 | short | Old line height (wpu) (no meaning in new values) | |
6 | short | New line height (wpu) (if value is (0), then auto line height) | |
8 | short | Length (8) | |
10 | 1 byte | End subfunction code (0) | |
11 | 1 byte | End function code (208 [0xD0]) | |
Subfunction: 1
Function Name: Left/Right Margin Set
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (1) | |
2 | short | Length (12 [0xC]) | |
4 | short | Old left margin (wpu) (no meaning in new values) | |
6 | short | Old right margin (wpu) (no meaning in new values) | |
8 | short | New left margin (wpu) | |
10 | short | New right margin (wpu) | |
12 | short | Length (12 [0xC]) | |
14 | 1 byte | End subfunction code (1) | |
15 | 1 byte | End function code (208 [0xD0]) | |
Function Code: 208 (0xD0)
Subfunction: 2
Function Name: Spacing Set
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (2) | |
2 | short | Length (8) | |
4 | short | Old spacing (the low byte is the fractional measure of the line and is in 1/256 of a line increment; the high byte is the # of lines) | |
6 | short | New spacing (same as above) | |
8 | short | Length (8) | |
10 | 1 byte | End subfunction code (2) | |
11 | 1 byte | End function code (208 [0xD0]) | |
Subfunction: 3
Function Name: Hyphenation Zone Set
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (3) | |
2 | short | Length (8) | |
4 | 1 byte | Old left hyphenation zone | |
5 | 1 byte | Old right hyphenation zone | |
6 | 1 byte | New left hyphenation zone | |
7 | 1 byte | New right hyphenation zone | |
8 | short | Length (8) | |
10 | 1 byte | End subfunction code (3) | |
11 | 1 byte | End function code (208 [0xD0]) | |
Function Code: 208 (0xD0)
Subfunction: 4
Function Name: Tab Set
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (4) | |
2 | short | Length = 208 (0xD0)(204 [0xCC] for WP5.0) | |
4 | 40 short int. | Old tab positions 40 max (wpu) (1 [0xFF] if not used) | |
84 | 20 bytes | 40 old tab types (1 nibble each, see offset 184) | |
104 | 40 short int. | New tab positions 40 max (wpu) (1 [0xFF] if not used) | |
184 | 20 bytes | 40 new tab types (1 nibble each) | |
Tab types: | |||
0 = Normal left justified tab | |||
1 = Centered tab | |||
2 = Right justified tab | |||
3 = Decimal-aligned tab | |||
4 = Left justified tab with a dot leader | |||
5 = Centered tab with a dot leader | |||
6 = Right justified tab with a dot leader | |||
7 = Decimal-aligned tab with a dot leader | |||
204 | short | Old left margin for relative tabs added for WP5.1 | |
206 | short | New left margin for relative tabs (wpu); if value is 1 (0xFF), tab type is absolute, otherwise this value is the left margin for relative tabs added for WP5.1 | |
208 | short | Length = 208 (0xD0) (204 [0xCC] for WP5.0) | |
210 | 1 byte | End subfunction code (4) | |
211 | 1 byte | End function code (208 [0xD0]) | |
Subfunction: 5
Function Name: Top/Bottom Margin Set
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (5) | |
2 | short | Length (12 [0xC]) | |
4 | short | Old top margin (wpu) (no meaning in new values) | |
6 | short | Old bottom margin (wpu) (no meaning in new values) | |
8 | short | New top margin (wpu) | |
10 | short | New bottom margin (wpu) | |
12 | short | Length (12 [0xC]) | |
14 | 1 byte | End subfunction code (5) | |
15 | 1 byte | End function code (208 [0xD0]) | |
Subfunction: 6
Function Name: Justification added for WP5.1
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (6) | |
2 | short | Length (6) | |
4 | 1 byte | Old justification mode | |
5 | 1 byte | New justification mode | |
= 0 left | |||
= 1 full | |||
= 2 center | |||
= 3 right | |||
= 4 decimal aligned (selectable only in tables) | |||
6 | short | Length (6) | |
8 | 1 byte | End subfunction code (6) | |
9 | 1 byte | End function code (208 [0xD0]) | |
Subfunction: 7
Function Name: Suppress Page Characteristics
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (7) | |
2 | short | Length (6) | |
4 | 1 byte | Old suppress code | |
5 | 1 byte | New suppress code | |
= 1 suppress page numbering | |||
= 2 suppress current page numbering and print page # at bottom center | |||
= 4 suppress header A | |||
= 8 suppress header B | |||
= 16 (0x10) suppress footer A | |||
= 32 (0x20) suppress footer B | |||
= 128 (0x80) this code NOT at top of page added for WP5.1 | |||
6 | short | Length (6) | |
8 | 1 byte | End subfunction code (7) | |
9 | 1 byte | End function code (208 [0xD0]) | |
Subfunction: 8
Function Name: Page Number Position
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (8) | |
2 | short | Length (10 [0xA]) | |
4 | 1 byte | Old position code (no meaning in new values) | |
5 | short | Old font height (wpu) (no meaning in new values) | |
7 | 1 byte | New position code | |
= 0 none | |||
= 1 top left | |||
= 2 top center | |||
= 3 top right | |||
= 4 alternating top left and right | |||
= 5 bottom left | |||
= 6 bottom center | |||
= 7 bottom right | |||
= 8 alternating bottom left and right | |||
8 | short | New font height (wpu) (0 = default) | |
10 | short | Length (10 [0xA]) | |
12 | 1 byte | End subfunction code (8) | |
13 | 1 byte | End function code (208 [0xD0]) | |
Subfunction: 11 (0xB)
Function Name: Form
Structure: | Offset | Size | Meaning |
0 | 1 byte | Begin function code (208 [0xD0]) | |
1 | 1 byte | Begin subfunction code (11 [0xB]) | |
2 | short | Length 247 (0xF7) (197 [0xC5] for WP5.0) | |
4 | short | Old desired length (no meaning in new values) | |
6 | short | Old desired width | |
8 | 1 byte | Old desired type | |
9 | 1 byte | Old desired type name length | |
10 | 41 bytes | Old desired type name | |
51 | short | Old effective length | |
53 | short | Old effective width | |
55 | 1 byte | Old effective type | |
56 | 1 byte | Old effective type name length | |
57 | 41 bytes | Old effective type name | |
98 | 1 byte | Old effective orientation (0 = port, 1 = land) | |
99 | short | New desired length | |
101 | short | New desired width1031 byteNew desired type | |
104 | 1 byte | New desired type name length | |
105 | 41 bytes | New desired type name | |
146 | short | New effective length | |
148 | short | New effective width | |
150 | 1 byte | New effective type | |
151 | 1 byte | New effective type name length | |
152 | 41 bytes | New effective type name | |
193 | 1 byte | New effective orientation (0 = port, 1 = land) | |
Offset | Size | Meaning | |
194 | 1 byte | Matched form # (offset into prefix Packet type 9) | |
195 | short | Matched form hash value | |
Added for WP5.1: | |||
197 | short | Old left margin (1200ths) | |
199 | short | Old right margin (1200ths) | |
201 | short | Old top margin (1200ths) | |
203 | short | Old bottom margin (1200ths) | |
205 | 1 byte | Old flag that indicates label form | |
Note: See new flag for description. | |||
206 | short | Old page where labels form is defined | |
208 | 1 byte | Old # of rows per page | |
209 | 1 byte | Old # of columns per page | |
210 | short | Old left offset--top left corner (1200ths) | |
212 | short | Old top offset--top left corner (1200ths) | |
214 | short | Old logical page width (1200ths) | |
216 | short | Old logical page length (1200ths) | |
218 | short | Old distance between label rows (1200ths) | |
220 | short | Old distance between label columns (1200ths) | |
222 | 1 byte | New flag that indicates label form | |
bit 0 = set if in label form | |||
bit 1 = set if label matched all others | |||
Note: This means labels are disabled. | |||
223 | short | New page where labels form is defined | |
225 | 1 byte | New # of rows per page | |
226 | 1 byte | New # of columns per page | |
227 | short | New left offset--top left corner (1200ths) | |
229 | short | New top offset--top left corner (1200ths) | |
231 | short | New logical page width (1200ths) | |
233 | short | New logical page length (1200ths) | |
235 | short | New distance between label rows (1200ths) | |
237 | short | New distance between label columns (1200ths) | |
239 | short | Label left margin (1200ths) | |
241 | short | Label right margin (1200ths) | |
243 | short | Label top margin (1200ths) | |
245 | short | Label bottom margin (1200ths) | |
247 | short | Length 247 (0xF7) (197 [0xC5] for WP5.0) | |
249 | 1 byte | End subfunction code (11 [0xB]) | |
250 | 1 byte | End function code (208 [0xD0]) |