1 \section{\class{wxMask
}}\label{wxmask
}
3 This class encapsulates a monochrome mask bitmap, where the masked area is black and
4 the unmasked area is white. When associated with a bitmap and drawn in a device context,
5 the unmasked area of the bitmap will be drawn, and the masked area will not be drawn.
7 \wxheading{Derived from
}
9 \helpref{wxObject
}{wxobject
}
11 \wxheading{Include files
}
17 \helpref{wxCore
}{librarieslist
}
21 A mask may be associated with a
\helpref{wxBitmap
}{wxbitmap
}. It is used in
\helpref{wxDC::Blit
}{wxdcblit
} when
22 the source device context is a
\helpref{wxMemoryDC
}{wxmemorydc
} with wxBitmap selected into it that
27 \helpref{wxBitmap
}{wxbitmap
},
\helpref{wxDC::Blit
}{wxdcblit
},
\helpref{wxMemoryDC
}{wxmemorydc
}
29 \latexignore{\rtfignore{\wxheading{Members
}}}
31 \membersection{wxMask::wxMask
}\label{wxmaskctor
}
33 \func{}{wxMask
}{\void}
37 \func{}{wxMask
}{\param{const
\helpref{wxBitmap
}{wxbitmap
}\&
}{bitmap
}}
39 Constructs a mask from a monochrome bitmap.
41 \pythonnote{This is the default constructor for wxMask in wxPython.
}
43 \func{}{wxMask
}{\param{const
\helpref{wxBitmap
}{wxbitmap
}\&
}{bitmap
},
\param{const
\helpref{wxColour
}{wxcolour
}\&
}{colour
}}
45 Constructs a mask from a bitmap and a colour that indicates the background.
47 \pythonnote{wxPython has an alternate wxMask constructor matching this
48 form called
{\tt wxMaskColour
}.
}
50 \func{}{wxMask
}{\param{const wxBitmap\&
}{bitmap
},
\param{int
}{ index
}}
52 Constructs a mask from a bitmap and a palette index that indicates the background. Not
53 yet implemented for GTK.
55 \wxheading{Parameters
}
57 \docparam{bitmap
}{A valid bitmap.
}
59 \docparam{colour
}{A colour specifying the transparency RGB values.
}
61 \docparam{index
}{Index into a palette, specifying the transparency colour.
}
63 \membersection{wxMask::
\destruct{wxMask
}}\label{wxmaskdtor
}
65 \func{}{\destruct{wxMask
}}{\void}
67 Destroys the wxMask object and the underlying bitmap data.
69 \membersection{wxMask::Create
}\label{wxmaskcreate
}
71 \func{bool
}{Create
}{\param{const wxBitmap\&
}{bitmap
}}
73 Constructs a mask from a monochrome bitmap.
75 \func{bool
}{Create
}{\param{const wxBitmap\&
}{bitmap
},
\param{const wxColour\&
}{colour
}}
77 Constructs a mask from a bitmap and a colour that indicates the background.
79 \func{bool
}{Create
}{\param{const wxBitmap\&
}{bitmap
},
\param{int
}{ index
}}
81 Constructs a mask from a bitmap and a palette index that indicates the background. Not
82 yet implemented for GTK.
84 \wxheading{Parameters
}
86 \docparam{bitmap
}{A valid bitmap.
}
88 \docparam{colour
}{A colour specifying the transparency RGB values.
}
90 \docparam{index
}{Index into a palette, specifying the transparency colour.
}