应该没有,我来写一下吧,不知道对不对:
function inrange(p:point,r:rect):boolean;
begin
  result:=(p.x>=r.left) and (p.y>=r.top) and (p.x<=r.right) and (p.y<r.bottom);
end;

解决方案 »

  1.   

    //直接借用Api
    {$EXTERNALSYM PtInRect}
    function PtInRect(const lprc: TRect; pt: TPoint): BOOL; stdcall;
      

  2.   

    //Demo
    procedure TForm1.FormMouseMove(Sender: TObject; Shift: TShiftState; X,
      Y: Integer);
    begin
      if PtInRect(Rect(10, 10, 100, 100), Point(X, Y)) then
        Canvas.Pixels[X, Y] := clRed;
    end;
      

  3.   

    zswang(伴水)(被黑中) 真实高手,而且乐于助人,当我师傅吧
      

  4.   

    to V_Lucky(Lucky):我的电量还不够,但愿意和大家多多交流,各有所长,我也在不断向别人学习