with-internal-metafile (
var
&key
pane
bounds
format
owner drawing-mode
) &body
body
=>
metafile
A variable.
A graphics port, or nil
.
A list of four integers. Can also be nil
on Microsoft Windows.
One of the keywords :enhanced
, :enhanced-plus
and :enhanced-gdi
.
Specifies the owner of the metafile, which calls to port-owner will return. This has an effect only when
pane
is nil
.
One of the keywords :compatible
and :quality
.
Lisp code.
The macro with-internal-metafile
creates a metafile containing records corresponding to the Graphics Ports operations in
body
that draw to
var
.
with-internal-metafile
behaves like with-external-metafile except that an object representing the metafile is returned, and no file is created on disk.
var
,
pane
,
bounds
,
format
,
drawing-mode
and
body
are interpreted as for with-external-metafile except that
format
cannot have the value :windows
.
Note:
GDI+ gives the best quality, so normally that what you want. But you cannot put a GDI+ only metafile on the clipboard, which is why the default is to make a "dual" metafile containing both GDI and GDI+ drawing. If are not going to put the metafile on the clipboard (by calling set-clipboard with
format
:metafile
) you can use
format
:enhanced-plus
which is slightly faster and uses less memory.
metafile must be freed after use, by calling free-metafile.
with-internal-metafile
is supported on GTK+ only where Cairo is supported (GTK+ version 2.8 and later).with-internal-metafile
is not implemented on X11/Motif.
(example-edit-file "capi/graphics/metafile")
(example-edit-file "capi/graphics/metafile-rotation")
CAPI User Guide and Reference Manual (Macintosh version) - 3 Aug 2017