procedure TForm1.Memo1DblClick(Sender: TObject);begin with Memo1 do begin SelStart:=SelStart-CaretPos.x; SelLength:=Length(Lines[CaretPos.y]) endend;