/////////////////////////////////////////////////////////////////////////////
// Name: metafile.h
-// Purpose: documentation for wxMetafileDC class
+// Purpose: interface of wxMetafileDC
// Author: wxWidgets team
// RCS-ID: $Id$
// Licence: wxWindows license
@library{wxcore}
@category{dc}
- @seealso
- wxMetafile, wxDC
+ @see wxMetafile, wxDC
*/
class wxMetafileDC : public wxDC
{
metafile is returned, and ownership of it passes to the calling
application (so it should be destroyed explicitly).
*/
- wxMetafile * Close();
+ wxMetafile* Close();
};
+
/**
@class wxMetafile
@wxheader{metafile.h}
@library{wxcore}
@category{FIXME}
- @seealso
- wxMetafileDC
+ @see wxMetafileDC
*/
class wxMetafile : public wxObject
{
/**
Returns @true if the metafile is valid.
*/
-#define bool Ok() /* implementation is private */
+ bool Ok();
/**
Plays the metafile into the given device context, returning
@true if successful.
*/
- bool Play(wxDC * dc);
+ bool Play(wxDC* dc);
/**
Passes the metafile data to the clipboard. The metafile can no longer be
used for anything, but the wxMetafile object must still be destroyed by
the application.
-
Below is a example of metafile, metafile device context and clipboard use
from the @c hello.cpp example. Note the way the metafile dimensions
are passed to the clipboard, making use of the device context's ability
};
+
// ============================================================================
// Global functions/macros
// ============================================================================
+/** @ingroup group_funcmacro_gdi */
+//@{
+
/**
Given a filename for an existing, valid metafile (as constructed using
- wxMetafileDC)
- makes it into a placeable metafile by prepending a header containing the given
- bounding box. The bounding box may be obtained from a device context after
- drawing
- into it, using the functions wxDC::MinX, wxDC::MinY, wxDC::MaxX and wxDC::MaxY.
-
- In addition to adding the placeable metafile header, this function adds
- the equivalent of the following code to the start of the metafile data:
+ wxMetafileDC) makes it into a placeable metafile by prepending a header
+ containing the given bounding box. The bounding box may be obtained from a
+ device context after drawing into it, using the functions wxDC::MinX(),
+ wxDC::MinY(), wxDC::MaxX() and wxDC::MaxY().
+
+ In addition to adding the placeable metafile header, this function adds the
+ equivalent of the following code to the start of the metafile data:
+
@code
SetMapMode(dc, MM_ANISOTROPIC);
- SetWindowOrg(dc, minX, minY);
- SetWindowExt(dc, maxX - minX, maxY - minY);
+ SetWindowOrg(dc, minX, minY);
+ SetWindowExt(dc, maxX - minX, maxY - minY);
@endcode
This simulates the wxMM_TEXT mapping mode, which wxWidgets assumes.
- Placeable metafiles may be imported by many Windows applications, and can be
- used in RTF (Rich Text Format) files.
+ Placeable metafiles may be imported by many Windows applications, and can
+ be used in RTF (Rich Text Format) files.
- @e scale allows the specification of scale for the metafile.
+ @a scale allows the specification of scale for the metafile.
This function is only available under Windows.
+
+ @header{wx/metafile.h}
*/
-bool wxMakeMetafilePlaceable(const wxString& filename, int minX,
- int minY,
- int maxX,
- int maxY,
- float scale=1.0);
+bool wxMakeMetafilePlaceable(const wxString& filename,
+ int minX, int minY,
+ int maxX, int maxY,
+ float scale = 1.0);
+
+//@}