Microsoft Foundation Classes (mfc.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
CWnd::ScreenToClient
CWnd                                        Up Contents Index Back
──Microsoft Foundation Classes──────────────────────────────────────────────
 
  void ScreenToClient( LPPOINT lpPoint ) const;
  void ScreenToClient( LPRECT lpRect ) const;
 
  Parameter   Description
 
  <lpPoint>   Points to a CPoint or POINT structure that contains the
              screen coordinates to be converted.
 
  <lpRect>    Points to a CRect or RECT structure that contains the
              screen coordinates to be converted.
 
  Remarks
 
  Converts the screen coordinates of a given point or rect on the display
  to client coordinates.
 
  The ScreenToClient member function uses CWnd and the screen coordinates
  given in <lpPoint> or <lpRect> to compute client coordinates, and then
  replaces the screen coordinates with the client coordinates. The new
  coordinates are relative to the upper-left corner of the CWnd client
  area.
 
  The ScreenToClient formula assumes the given point is in screen
  coordinates.
 
  See Also
 
  CWnd::ClientToScreen, ::ScreenToClient
 
 
                                     -♦-