hWndPt,hWnd:THandle;
pBuf:PChar;
pt:TPoint;
nMax:DWORD;
rect:TRect;
begin
    GetCursorPos(pt);
    nMax:=1024;
    hWndPt:=WindowFromPoint(pt);
    if hWndPt<>0 then
    begin
        GetMem(pBuf,1024);
        SendMessage(hWndPt,WM_GETTEXT,nMax,DWORD(pBuf));
        Memo1.Lines.Add(string(pbuf));
        FreeMem(pBuf);
    end;
    memo1.SelStart :=length(memo1.Text);
end;我通过以上程序代码,可以取得鼠标所在窗体的标题,我应该通过什么方式获得鼠标所在窗体的位置和大小呢?谢谢!