Converts between a POINTL structure expressed in HIMETRIC units (as is standard in OLE) and a POINTF structure expressed in units specified by the container. By converting the methods, the control can ensure that it sends coordinate information to the container in units that are directly usable in the container without additional conversion.
HRESULT TransformCoords(
POINTL* pPtlHimetric , //Address of POINTL structure
POINTF* pPtfContainer , //Address of POINTF structure
DWORD dwFlags //Flags indicating the exact conversion
);
Flag Value | Description |
---|---|
XFORMCOORDS_POSITION | The coordinates to convert represent a position point. Cannot be used with XFORMCOORDS_SIZE. |
XFORMCOORDS_SIZE | The coordinates to convert represent a set of dimensions. Cannot be used with XFORMCOORDS_POSITION. |
XFORMCOORDS_HIMETRICTOCONTAINER | The operation converts pptlHimetric into pptfContainer. Cannot be used with XFORMCOORDS_CONTAINERTOHIMETRIC. |
XFORMCOORDS_CONTAINERTOHIMETRIC | The operation converts pptfContainer into pptlHimetric. Cannot be used with XFORMCOORDS_HIMETRICTOCONTAINER. |
This method supports the standard return values E_INVALIDARG and E_UNEXPECTED, as well as the following:
A control uses this method when it has to send coordinates to a container within an event or some other custom call or when the control has container coordinates that it needs to convert into HIMETRIC units.
Windows NT: Use version 4.0 or later.
Windows: Use Windows 95 or later.
Windows CE: Unsupported.
Header: Declared in ocidl.h.