| Version: 3.2.8

Classes | Enumerations
dc.h File Reference

## Classes
struct | wxFontMetrics
| Simple collection of various font metrics. More...
class | wxDC
| A wxDC is a "device context" onto which graphics and text can be drawn. More...
class | wxDCClipper
| wxDCClipper is a helper class for setting a clipping region on a wxDC during its lifetime. More...
class | wxDCBrushChanger
| wxDCBrushChanger is a small helper class for setting a brush on a wxDC and unsetting it automatically in the destructor, restoring the previous one. More...
class | wxDCPenChanger
| wxDCPenChanger is a small helper class for setting a pen on a wxDC and unsetting it automatically in the destructor, restoring the previous one. More...
class | wxDCTextColourChanger
| wxDCTextColourChanger is a small helper class for setting a foreground text colour on a wxDC and unsetting it automatically in the destructor, restoring the previous one. More...
class | wxDCTextBgColourChanger
| wxDCTextBgColourChanger is a small helper class for setting a background text colour on a wxDC and unsetting it automatically in the destructor, restoring the previous one. More...
class | wxDCBgModeChanger
class | wxDCFontChanger
| wxDCFontChanger is a small helper class for setting a font on a wxDC and unsetting it automatically in the destructor, restoring the previous one. More...

## Enumerations
enum | wxRasterOperationMode { wxCLEAR , wxXOR , wxINVERT , wxOR_REVERSE , wxAND_REVERSE , wxCOPY , wxAND , wxAND_INVERT , wxNO_OP , wxNOR , wxEQUIV , wxSRC_INVERT , wxOR_INVERT , wxNAND , wxOR , wxSET }
| Logical raster operations which can be used with wxDC::SetLogicalFunction and some other wxDC functions (e.g. More...
enum | wxFloodFillStyle { wxFLOOD_SURFACE = 1 , wxFLOOD_BORDER }
| Flood styles used by wxDC::FloodFill. More...
enum | wxMappingMode { wxMM_TEXT = 1 , wxMM_METRIC , wxMM_LOMETRIC , wxMM_TWIPS , wxMM_POINTS }
| The mapping used to transform logical units to device units. More...

## Enumeration Type Documentation

## ◆ wxFloodFillStyle

enum wxFloodFillStyle

Flood styles used by wxDC::FloodFill.

Enumerator
wxFLOOD_SURFACE | The flooding occurs until a colour other than the given colour is encountered.
wxFLOOD_BORDER | The area to be flooded is bounded by the given colour.

## ◆ wxMappingMode

enum wxMappingMode

The mapping used to transform logical units to device units.

See wxDC::SetMapMode.

Enumerator
wxMM_TEXT | Each logical unit is 1 device pixel. This is the default mapping mode for all wxDC-derived classes.
wxMM_METRIC | Each logical unit is 1 millimeter.
wxMM_LOMETRIC | Each logical unit is 1/10 of a millimeter.
wxMM_TWIPS | Each logical unit is 1/20 of a "printer point", or 1/1440 of an inch (also known as "twip"). Equivalent to about 17.64 micrometers.
wxMM_POINTS | Each logical unit is a "printer point" i.e. 1/72 of an inch. Equivalent to about 353 micrometers.

## ◆ wxRasterOperationMode

enum wxRasterOperationMode

Logical raster operations which can be used with wxDC::SetLogicalFunction and some other wxDC functions (e.g.

wxDC::Blit and wxDC::StretchBlit).

The description of the values below refer to how a generic src source pixel and the corresponding dst destination pixel gets combined together to produce the final pixel. E.g. `wxCLEAR` and `wxSET` completely ignore the source and the destination pixel and always put zeroes or ones in the final surface.

Note that not all modes are supported under all platforms. Notably wxGTK3 and wxMac only support the following modes:

- wxCOPY
- wxOR
- wxNO_OP
- wxCLEAR
- wxXOR and only support the commonly used `wxINVERT` when the source colour is white (as it is implemented using wxCOMPOSITION_DIFF composition mode).

Enumerator
wxCLEAR | 0
wxXOR | src XOR dst
wxINVERT | NOT dst.
wxOR_REVERSE | src OR (NOT dst)
wxAND_REVERSE | src AND (NOT dst)
wxCOPY | src
wxAND | src AND dst
wxAND_INVERT | (NOT src) AND dst
wxNO_OP | dst
wxNOR | (NOT src) AND (NOT dst)
wxEQUIV | (NOT src) XOR dst
wxSRC_INVERT | (NOT src)
wxOR_INVERT | (NOT src) OR dst
wxNAND | (NOT src) OR (NOT dst)
wxOR | src OR dst
wxSET | 1