Field attributes

Description
Every position in the 3270 screen buffer has one or more attributes. In the output from the ReadBuffer action, these attributes have the following format.
 * attribute=value


 * attribute
 * A 2-digit hexadecimal number defining an attribute type.


 * value
 * A 2-digit hexadecimal number giving the attribute value.

Basic 3270 field attributes
Field attributes are an 8-bit field.

Colors
Neutral black represents the default foreground color. It displays as white on a white-on-black display, and black on a black-on-white display and on a printer. Neutral white represents the default background color. It displays as black on a white-on-black display, and white on a black-on-white display and on a printer.

How to determine the attributes for a buffer position
Figuring out the attributes for a buffer position follows a three simple rules.
 * The attributes of a Start Field character affect all of the buffer positions to the right of the Start Field, until another Start Field is encountered. "To the right" includes wrapping from one line to the next and from the bottom of the screen back up to the top.
 * A buffer position with additional field attributes overrides the Start Field attributes, and affects all of the buffer positions to the right, until another buffer position with additional field attributes overrides it or a Start Field is encountered. "To the right" is as described above.
 * Additional attributes are cumulative, so if (for example) buffer position 27 has an additional attribute for foreground color and buffer position 28 has an additional attribute for background color, then buffer position 28 should be rendered with both position 27's specified foreground and its own background color. Buffer position 29 should also be rendered with both position 27's foreground and 28's background (unless it has its own additional attributes or is a Start Field).