CMFCControlRendererInfo Class
A helper class for passing parameters to CMFCControlRenderer Class.
class CMFCControlRendererInfo
Members
Public Constructors
Name |
Description |
---|---|
Constructs a CMFCControlRendererInfo object. |
|
CMFCControlRendererInfo::~CMFCControlRendererInfo |
Destructor. |
Public Methods
Name |
Description |
---|---|
Initializes public members, setting them to default values. |
|
Returns the resource ID of the image that CMFCControlRenderer uses for drawing. |
|
Sets the resource ID of the image that CMFCControlRenderer will use. |
|
Copy operator. Implements deep copy of class members. |
Data Members
Name |
Description |
---|---|
Indicates whether a premultiply check of 32-bit images that use the alpha channel is required for correct appearance. |
|
Transparent color of the image. Those parts of the image that are of this color will be transparent. |
|
Specifies corner sizes. |
|
An image rectangle. CMFCControlRenderer operates only on the portion of an image that is identified by this rectangle. |
|
Specifies the inner rectangle of the image. Usually it is m_rectImage reduced by m_rectCorner values. |
|
Specifies the borders of an image. |
|
The resource ID string of the image. |
|
The resource ID of the image. |
Remarks
This class supports the MFC framework infrastructure and is not intended to be used directly from your code.
Instantiate this class on the stack. Usually you will pass in all the required parameters by using one of its constructors, but you can also access its public data members directly.
Pass a reference to the instantiated class using CMFCControlRenderer::Create, which copies the parameters and stores them internally.
Example
The following example demonstrates how to use the construct a CMFCControlRendererInfo object. This code is part of the MSOffice2007Demo Sample: MFC Office Application.
// first parameter is resource string ID of the image
// second parameter is the default transparent color
// third parameter is the image rectangle
// fourth parameter is the image corners
// fifth parameter is the image sides
// sixth parameter is the inner image rectangle
// seventh parameter indicates that a check for 32-bit images with alpha channel is not required
CMFCControlRendererInfo params(_T(""), CLR_DEFAULT, CRect(0, 0, 350, 60), CRect(83, 58, 266, 1), CRect(0, 0, 0, 0), CRect(0, 0, 0, 0), FALSE);
Inheritance Hierarchy
Requirements
Header: afxcontrolrenderer.h