TMetafile = object( TObj )
Object type to encapsulate metafile image.
type
TMetafileHeader = packed record
Key: Longint;
Handle: SmallInt;
Box: TSmallRect;
Inch: Word;
Reserved: Longint;
CheckSum: Word;
end;
const
Metafile Properties
Returns handle of enchanced metafile.
property Width: Integer;
Native width of the metafile.
property Height: Integer;
Native height of the metafile.
Metafile Methods
Returns TRUE if empty
function LoadFromStream( Strm: PStream ): Boolean;
Loads emf or wmf file format from stream.
function LoadFromFile( const Filename: AnsiString ): Boolean;
Loads emf or wmf from stream.
procedure Draw( DC: HDC; X, Y: Integer );
Draws enchanced metafile on DC.
procedure StretchDraw( DC: HDC; const R: TRect );
Draws enchanced metafile stretched.
function NewMetafile: PMetafile;
Creates metafile object.
function ComputeAldusChecksum(var WMF: TMetafileHeader): Word;
function SetEnhMetaFileBits(p1: UINT; p2: PAnsiChar): HENHMETAFILE; stdcall;
function PlayEnhMetaFile(DC: HDC; p2: HENHMETAFILE; const p3: TRect): BOOL; stdcall;