GetMessagePos//确定光标的当前位置,请使用GetCursorPos函数。The return value specifies the x- and y-coordinates of the cursor position. The x-coordinate is the low order short and the y-coordinate is the high-order short.
ScreenToClient//Converts screen coordinates to client coordinates.
GetSystemMetrics//Retrieves the specified system metric or system configuration setting. [外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-umjQUAc7-1590070621220)(https://raw.githubusercontent.com/konalo-X/pic/master/20200521221408.png)]
//The pointer returned by this function can be used to access application information such as the main message-dispatch code or the topmost window.
CWinApp* AFXAPI AfxGetApp();//Allows you to register your own window classes.
LPCTSTR AFXAPI AfxRegisterWndClass(
UINT nClassStyle,
HCURSOR hCursor =0,
HBRUSH hbrBackground =0,
HICON hIcon =0);//Creates an overlapped, pop-up, or child window with the extended style specified in dwExStyle. virtual BOOL CreateEx(
DWORD dwExStyle,
LPCTSTR lpszClassName,
LPCTSTR lpszWindowName,
DWORD dwStyle,int x,int y,int nWidth,int nHeight,
HWND hWndParent,
HMENU nIDorHMenu,
LPVOID lpParam =NULL);virtual BOOL CreateEx(
DWORD dwExStyle,
LPCTSTR lpszClassName,
LPCTSTR lpszWindowName,
DWORD dwStyle,const RECT& rect,
CWnd* pParentWnd,
UINT nID,
LPVOID lpParam =NULL);//Sets the current background color to the specified color. virtual COLORREF SetBkColor(
COLORREF crColor
);//Retrieves the current color of the specified display element. Display elements are the parts of a window and the display that appear on the system display screen.
DWORD WINAPI GetSysColor(
__in int nIndex
);//Call this member function to write a character string at the specified location, expanding tabs to the values specified in the array of tab-stop positions. virtual CSize TabbedTextOut(int x,int y,
LPCTSTR lpszString,int nCount,int nTabPositions,
LPINT lpnTabStopPositions,int nTabOrigin
);
CSize TabbedTextOut(int x,int y,const CString& str,int nTabPositions,
LPINT lpnTabStopPositions,int nTabOrigin
);//调用此成员函数,以使用当前选中的字体在矩形区域内写入字符串。virtual BOOL ExtTextOut(int x,int y,
UINT nOptions,
LPCRECT lpRect,
LPCTSTR lpszString,
UINT nCount,
LPINT lpDxWidths
);
BOOL ExtTextOut(int x,int y,
UINT nOptions,
LPCRECT lpRect,const CString& str,
LPINT lpDxWidths
);//Allows a windowless OLE object to scroll an area within its in-place active image on the screen. voidScrollWindow(int xAmount,int yAmount,
LPCRECT lpRect =NULL,
LPCRECT lpClipRect =NULL);//Validates the client area within the given rectangle by removing the rectangle from the update region of the window. voidValidateRect(
LPCRECT lpRect
);//Call this member function to compute the width and height of a line of text using the current font to determine the dimensions.
CSize GetTextExtent(
LPCTSTR lpszString,int nCount
)const;
CSize GetTextExtent(const CString& str
)const//Sets the dimensions of CRect to the specified coordinates. voidSetRect(int x1,int y1,int x2,int y2
)throw//InflateRect inflates CRect by moving its sides away from its center. voidInflateRect(int x,int y
)throw();voidInflateRect(
SIZE size
)throw();voidInflateRect(
LPCRECT lpRect
)throw();voidInflateRect(int l,int t,int r,int b
)throw();//Call this member function to compute the required size of the window rectangle based on the desired client-rectangle size. virtualvoidCalcWindowRect(
LPRECT lpClientRect,
UINT nAdjustType = adjustBorder
);//Call this member function to change the size, position, and Z-order of chi