EMF
1.0
|
Support different endian modes when reading and writing the metafile. More...
#include <libemf.h>
Support different endian modes when reading and writing the metafile.
To support different endian modes, rather than just writing the structures directly to a file via fwrite( &emr, ...), we have to write each element of the structure separately, swapping bytes as necessary. datastream supports this. Remarkably similar to the QDataStream class from Qt. So, too, for reading.
|
inline |
Constructor for DATASTREAM.
fp | optional file pointer (but must be assigned before any output occurs.) |
|
inline |
Output a byte to the stream (not swabbed or anything).
byte | byte to output. |
|
inline |
Output a (short) word to the stream (swabbed).
word | (short) word to output. |
|
inline |
Output a (short, 16-bit) word to the stream (swabbed).
word | (short, 16-bit) word to output. |
|
inline |
Output a double word (long) to the stream (swabbed).
dword | double word (long) to output. |
|
inline |
Output a long int to the stream (swabbed).
long_ | long int to output. |
|
inline |
Output a (long) int to the stream (swabbed).
int_ | (long) int to output. |
|
inline |
Output a (long) unsigned int to the stream (swabbed).
uint | (long) unsigned int to output. |
|
inline |
Output a single precision float to the stream (swabbed).
float_ | single precision float to output. |
|
inline |
Output a series of '\0's to pad out a record.
padding | simple padding structure (length and number of nulls). |
|
inline |
Output a RECTL structure.
rectl | structure to output. |
|
inline |
Output a SIZEL structure.
sizel | structure to output. |
|
inline |
Output a WCHAR string (note: the individual characters are swabbed).
wcharstr | structure to output. |
|
inline |
Output a single byte character string.
charstr | structure to output. |
|
inline |
Output an Enhanced Metafile Record header.
emr | Enhanced Metafile Record header to output. |
|
inline |
Output a POINT structure.
point | POINT to output. |
|
inline |
Output a POINTL structure.
pointl | POINTL to output. |
|
inline |
Output a POINT16 structure.
point | POINT16 to output. |
|
inline |
Output an XFORM structure.
xform | XFORM to output. |
|
inline |
Output an array of BYTEs.
array | array of BYTEs to output. |
|
inline |
Output an array of POINTLs.
array | array of POINTLs to output. |
|
inline |
Output an array of POINT16s.
array | array of POINT16s to output. |
|
inline |
Output an array of (long) ints.
array | array of (long) ints to output. |
|
inline |
Output an array of double words (longs).
array | array of double words (longs) to output. |
|
inline |
Output an Enhanced Metafile Text Record.
text | Enhanced Metafile Text Record to output. |
|
inline |
Output a Logical Pen definition.
pen | Logical Pen definition to output. |
|
inline |
Output an Extended Logical Pen definition.
pen | Extended Logical Pen definition to output. |
|
inline |
Output a Logical Brush definition.
brush | Logical Brush definition to output. |
|
inline |
Output a Logical Font definition (using WCHAR strings).
font | Logical Font definition to output. |
|
inline |
Output a Panose structure.
panose | Panose structure to output. |
|
inline |
Output an Extended Logical Font definition (using WCHAR strings).
font | Extended Logical Font definition to output. |
|
inline |
Output a Logical Palette.
palette | Logical Palette to output. |
|
inline |
Input a byte from the stream (not swabbed or anything).
byte | destination for input byte. |
|
inline |
Input a (short) word from the stream (swabbed).
word | destination for (short) word. |
|
inline |
Input a (short, 16-bit) word from the stream (swabbed).
word | destination for (short, 16-bit) word. |
|
inline |
Input a double word (long) from the stream (swabbed).
dword | destination for double word (long). |
|
inline |
Input a long int from the stream (swabbed).
long_ | destination for long int. |
|
inline |
Input a (long) int from the stream (swabbed).
int_ | destination for (long) int. |
|
inline |
Input a (long) unsigned int from the stream (swabbed).
uint | destination for (long) unsigned int. |
|
inline |
Input a single precision float from the stream (swabbed).
float_ | destination for single precision float. |
|
inline |
Input a RECTL structure.
rectl | destination of input RECTL. |
|
inline |
Input a SIZEL structure.
sizel | destination of input SIZEL. |
|
inline |
Input a WCHAR string (note: the individual characters are swabbed.)
wcharstr | destination of input WCHAR string. |
|
inline |
Input a single byte character string.
charstr | destination of input CHAR string. |
|
inline |
Input an Enhanced Metafile Record header.
emr | destination of Enhanced Metafile Record header. |
|
inline |
Input a POINT structure.
point | destination of input POINT. |
|
inline |
Input a POINTL structure.
pointl | destination of input POINTL. |
|
inline |
Input a POINT16 structure.
point | destination of input POINT16. |
|
inline |
Input an XFORM structure.
xform | destination of input XFORM. |
|
inline |
Input an array of BYTEs.
array | destination of array of input BYTEs. |
|
inline |
Input an array of POINTLs.
array | destination of array of input POINTLs. |
|
inline |
Input an array of POINT16s.
array | destination of array of input POINT16s. |
|
inline |
Input an array of (long) ints.
array | destination of array of input (long) ints. |
|
inline |
Input an array of double words (longs).
array | destination of array of input double words (longs). |
|
inline |
Input an Enhanced Metafile Text Record.
text | destination of Enhanced Metafile Text Record. |
|
inline |
Input a Logical Pen definition.
pen | destination of Logical Pen definition. |
|
inline |
Input an Extended Logical Pen definition.
pen | destination of Extended Logical Pen definition. |
|
inline |
Input a Logical Brush definition.
brush | destination of Logical Brush definition. |
|
inline |
Input a Logical Font definition (using WCHAR strings).
font | destination of Logical Font definition. |
|
inline |
Input a Panose structure.
panose | destinatino of input Panose structure. |
|
inline |
Input an Extended Logical Font definition (using WCHAR strings).
font | destination of Extended Logical Font definition. |
|
inline |
Input a Logical Palette.
palette | destination of input Logical Palette. |
|
inline |
Use the given FILE stream as the input/output destination.
fp | file point for i/o. |