2.3.6.16 GETCOLORTABLE Record

The GETCOLORTABLE Record gets color table values from the printer driver.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

RecordSize

RecordFunction

EscapeFunction

ByteCount

Start

ColorTableBuffer (variable)

...

RecordSize (4 bytes): A 32-bit unsigned integer that defines the number of WORD structures, defined in [MS-DTYP] section 2.2.61, in this record.

RecordFunction (2 bytes): A 16-bit unsigned integer that defines the record type. The lower byte MUST match the lower byte of the RecordType Enumeration (section 2.1.1.1) table value META_ESCAPE.

EscapeFunction (2 bytes): A 16-bit unsigned integer that defines the escape function. The value MUST be 0x0005 (GETCOLORTABLE) from the MetafileEscapes Enumeration (section 2.1.1.17).

ByteCount (2 bytes): A 16-bit unsigned integer that specifies the size, in bytes, of the record data that follows.

Start (2 bytes): A 16-bit unsigned integer that defines the offset from the beginning of the record to the start of the color table data in the ColorTable field.

ColorTableBuffer (variable): A buffer containing the color table that is obtained from the printer driver, which is not required to be contiguous with the static part of the record.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

UndefinedSpace (variable)

...

ColorTable (variable)

...

UndefinedSpace (variable): An optional field that MUST be ignored.

ColorTable (variable): An array of bytes that define the color table. The location of this field within the record is specified by the Start field.

See section 2.3.6 for the specification of other Escape Record Types.