CSize Class |
Description
A CSize can be used anywhere that a SIZE structure could be used.
CSize Members
CSize | CSize(); CSize(int CX, int CY); CSize(SIZE sz); CSize(POINT pt); CSize(DWORD dw)Various methods of constructing the CSize object. |
operator LPSIZE();Returns the pointer to the SIZE object associated with this CSize.
BOOL operator == (SIZE sz) const;Returns TRUE if the co-ordinates of the source size and the CSize are equal.
BOOL operator != (SIZE sz) const;Returns TRUE if the of the source size and the CSize are not equal.
void operator += (SIZE sz);Adds the specified SIZE.
void operator -= (SIZE sz);Subtracts the specified SIZE.
CSize operator - () const;Returns the unary minus (additive inverse).
CSize operator + (SIZE sz) const;
CPoint operator + (POINT point) const;
CRect operator + (LPCRECT prc) const;Adds the point and returns the value.
CSize operator - (SIZE sz) const;
CPoint operator - (POINT point) const;
CRect operator - (LPCRECT prc) const;Subtracts the point and returns the value.
void SetSize(int CX, int CY);Sets the coordinates of the CSize.
Remarks
By default, the constructor sets all the size coordinates zero, but the CSize can also be constructed from two integers, a size, a point, or a dword.
The CSize class inherits from the SIZE structure. As a result, the data members of the underlying SIZE struct are also accessible as data members.
Summary Information
Header file | winutils.h |
Win32/64 support | Yes |
WinCE support | Yes |