{
Get curve dump
}
function CurveDump(c:Integer):String;
 function Extract(c,i,j:Integer):String;
 var m:Integer;
 begin
  if i>j then Extract:='' else
  if i=j then Extract:=dump(crvx(c,i))+dump(crvy(c,i)) else begin
   m:=(i+j) div 2;
   Extract:=Extract(c,i,m)+Extract(c,m+1,j);
  end;
 end;
begin
 if IsSameText(RefInfo(c,'Type'),'Curve') then begin
  b:=crvlock(c);
  CurveDump:=Extract(c,1,Round(crvlen(c)));
  b:=crvunlock(c);
 end else CurveDump:='';
end;
