Finished review/fixes of GDI category of functions and macros.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@52630 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -16,7 +16,5 @@ Interface) access.
|
|||||||
|
|
||||||
Related Overviews: @ref overview_dc
|
Related Overviews: @ref overview_dc
|
||||||
|
|
||||||
@header{wx/gdicmn.h}
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@@ -326,12 +326,22 @@ public:
|
|||||||
// Global functions/macros
|
// Global functions/macros
|
||||||
// ============================================================================
|
// ============================================================================
|
||||||
|
|
||||||
/**
|
/** @ingroup group_funcmacro_gdi */
|
||||||
This macro creates either a cursor (MSW) or an icon (elsewhere) with the given
|
//@{
|
||||||
name. Under MSW, the cursor is loaded from the resource file and the icon is
|
|
||||||
loaded from XPM file under other platforms.
|
/**
|
||||||
This macro should be used with
|
This macro creates either a cursor (MSW) or an icon (elsewhere) with the
|
||||||
@ref wxDropSource::wxdropsource "wxDropSource constructor".
|
given @a name (of type <tt>const char*</tt>). Under MSW, the cursor is
|
||||||
*/
|
loaded from the resource file and the icon is loaded from XPM file under
|
||||||
#define wxIconOrCursor wxDROP_ICON(const char* name) /* implementation is private */
|
other platforms.
|
||||||
|
|
||||||
|
This macro should be used with wxDropSource::wxDropSource().
|
||||||
|
|
||||||
|
@returns wxCursor on MSW, otherwise returns a wxIcon
|
||||||
|
|
||||||
|
@header{wx/dnd.h}
|
||||||
|
*/
|
||||||
|
#define wxDROP_ICON(name)
|
||||||
|
|
||||||
|
//@}
|
||||||
|
|
||||||
|
@@ -727,54 +727,87 @@ public:
|
|||||||
//@{
|
//@{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Returns the dimensions of the work area on the display. On Windows
|
This macro loads a bitmap from either application resources (on the
|
||||||
this means the area not covered by the taskbar, etc. Other platforms
|
platforms for which they exist, i.e. Windows and OS2) or from an XPM file.
|
||||||
are currently defaulting to the whole display until a way is found to
|
This can help to avoid using @ifdef_ when creating bitmaps.
|
||||||
provide this info for all window managers, etc.
|
|
||||||
|
@see @ref overview_bitmap, wxICON()
|
||||||
|
|
||||||
|
@header{wx/gdicmn.h}
|
||||||
*/
|
*/
|
||||||
void wxClientDisplayRect(int* x, int* y, int* width,
|
#define wxBITMAP(bitmapName)
|
||||||
int* height);
|
|
||||||
wxRect wxGetClientDisplayRect();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Returns the display size in pixels.
|
This macro loads an icon from either application resources (on the
|
||||||
*/
|
platforms for which they exist, i.e. Windows and OS2) or from an XPM file.
|
||||||
void wxDisplaySize(int* width, int* height);
|
This can help to avoid using @ifdef_ when creating icons.
|
||||||
wxSize wxGetDisplaySize();
|
|
||||||
|
|
||||||
/**
|
@see @ref overview_bitmap, wxBITMAP()
|
||||||
Returns the display size in millimeters.
|
|
||||||
*/
|
|
||||||
void wxDisplaySizeMM(int* width, int* height);
|
|
||||||
wxSize wxGetDisplaySizeMM();
|
|
||||||
|
|
||||||
/**
|
@header{wx/gdicmn.h}
|
||||||
This macro loads an icon from either application resources (on the platforms
|
|
||||||
for which they exist, i.e. Windows and OS2) or from an XPM file. It allows to
|
|
||||||
avoid using @c #ifdefs when creating icons.
|
|
||||||
|
|
||||||
@see @ref overview_wxbitmapoverview, wxBITMAP()
|
|
||||||
*/
|
*/
|
||||||
wxICON();
|
wxICON();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Returns @true if the display is colour, @false otherwise.
|
Returns @true if the display is colour, @false otherwise.
|
||||||
|
|
||||||
|
@header{wx/gdicmn.h}
|
||||||
*/
|
*/
|
||||||
bool wxColourDisplay();
|
bool wxColourDisplay();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
This macro loads a bitmap from either application resources (on the platforms
|
Returns the depth of the display (a value of 1 denotes a monochrome
|
||||||
for which they exist, i.e. Windows and OS2) or from an XPM file. It allows to
|
display).
|
||||||
avoid using @c #ifdefs when creating bitmaps.
|
|
||||||
|
|
||||||
@see @ref overview_wxbitmapoverview, wxICON()
|
@header{wx/gdicmn.h}
|
||||||
*/
|
|
||||||
#define wxBITMAP() /* implementation is private */
|
|
||||||
|
|
||||||
/**
|
|
||||||
Returns the depth of the display (a value of 1 denotes a monochrome display).
|
|
||||||
*/
|
*/
|
||||||
int wxDisplayDepth();
|
int wxDisplayDepth();
|
||||||
|
|
||||||
|
/**
|
||||||
|
Globally sets the cursor; only has an effect on Windows, Mac and GTK+. You
|
||||||
|
should call this function with wxNullCursor to restore the system cursor.
|
||||||
|
|
||||||
|
@see wxCursor, wxWindow::SetCursor()
|
||||||
|
|
||||||
|
@header{wx/gdicmn.h}
|
||||||
|
*/
|
||||||
|
void wxSetCursor(const wxCursor& cursor);
|
||||||
|
|
||||||
|
//@}
|
||||||
|
|
||||||
|
/** @ingroup group_funcmacro_gdi */
|
||||||
|
//@{
|
||||||
|
/**
|
||||||
|
Returns the dimensions of the work area on the display. On Windows this
|
||||||
|
means the area not covered by the taskbar, etc. Other platforms are
|
||||||
|
currently defaulting to the whole display until a way is found to provide
|
||||||
|
this info for all window managers, etc.
|
||||||
|
|
||||||
|
@header{wx/gdicmn.h}
|
||||||
|
*/
|
||||||
|
void wxClientDisplayRect(int* x, int* y, int* width, int* height);
|
||||||
|
wxRect wxGetClientDisplayRect();
|
||||||
|
//@}
|
||||||
|
|
||||||
|
/** @ingroup group_funcmacro_gdi */
|
||||||
|
//@{
|
||||||
|
/**
|
||||||
|
Returns the display size in pixels.
|
||||||
|
|
||||||
|
@header{wx/gdicmn.h}
|
||||||
|
*/
|
||||||
|
void wxDisplaySize(int* width, int* height);
|
||||||
|
wxSize wxGetDisplaySize();
|
||||||
|
//@}
|
||||||
|
|
||||||
|
/** @ingroup group_funcmacro_gdi */
|
||||||
|
//@{
|
||||||
|
/**
|
||||||
|
Returns the display size in millimeters.
|
||||||
|
|
||||||
|
@header{wx/gdicmn.h}
|
||||||
|
*/
|
||||||
|
void wxDisplaySizeMM(int* width, int* height);
|
||||||
|
wxSize wxGetDisplaySizeMM();
|
||||||
//@}
|
//@}
|
||||||
|
|
||||||
|
@@ -121,15 +121,14 @@ public:
|
|||||||
//@{
|
//@{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@header{wx/metafile.h}
|
|
||||||
|
|
||||||
Given a filename for an existing, valid metafile (as constructed using
|
Given a filename for an existing, valid metafile (as constructed using
|
||||||
wxMetafileDC) makes it into a placeable metafile by prepending a header
|
wxMetafileDC) makes it into a placeable metafile by prepending a header
|
||||||
containing the given bounding box. The bounding box may be obtained from a
|
containing the given bounding box. The bounding box may be obtained from a
|
||||||
device context after drawing into it, using the functions wxDC::MinX(),
|
device context after drawing into it, using the functions wxDC::MinX(),
|
||||||
wxDC::MinY(), wxDC::MaxX() and wxDC::MaxY(). In addition to adding the
|
wxDC::MinY(), wxDC::MaxX() and wxDC::MaxY().
|
||||||
placeable metafile header, this function adds the equivalent of the
|
|
||||||
following code to the start of the metafile data:
|
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
|
@code
|
||||||
SetMapMode(dc, MM_ANISOTROPIC);
|
SetMapMode(dc, MM_ANISOTROPIC);
|
||||||
@@ -138,14 +137,19 @@ public:
|
|||||||
@endcode
|
@endcode
|
||||||
|
|
||||||
This simulates the wxMM_TEXT mapping mode, which wxWidgets assumes.
|
This simulates the wxMM_TEXT mapping mode, which wxWidgets assumes.
|
||||||
|
|
||||||
Placeable metafiles may be imported by many Windows applications, and can
|
Placeable metafiles may be imported by many Windows applications, and can
|
||||||
be used in RTF (Rich Text Format) files. @a scale allows the specification
|
be used in RTF (Rich Text Format) files.
|
||||||
of scale for the metafile. This function is only available under Windows.
|
|
||||||
|
@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,
|
bool wxMakeMetafilePlaceable(const wxString& filename,
|
||||||
int minY,
|
int minX, int minY,
|
||||||
int maxX,
|
int maxX, int maxY,
|
||||||
int maxY,
|
|
||||||
float scale = 1.0);
|
float scale = 1.0);
|
||||||
|
|
||||||
//@}
|
//@}
|
||||||
|
Reference in New Issue
Block a user