Announcement

Collapse
No announcement yet.

Mausposition

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Mausposition

    Hallo!
    <br>
    Wie schaffe ich es, einen Kreis genau auf die Position zu bekommen, wo ich hinklicke?
    <br>
    Ich würde mich auf eine Antwort freuen

  • #2
    Hallo,

    Beispiel:

    <pre>
    procedure TForm1.FormMouseDown(Sender: TObject; Button: TMouseButton;
    Shift: TShiftState; X, Y: Integer);
    var pPos : TPoint;
    circle : TShape;
    begin
    circle := TShape.create(self);
    with circle do
    begin
    shape := stCircle;
    parent := self;
    left := x-(circle.width div 2);
    top := y-(circle.height div 2);
    end;
    end;
    </pre>

    Viel Erfolg..

    Comment


    • #3
      Vielen Dank für die Hilfe

      Comment

      Working...
      X