unit basicunit;
{$mode delphi} {$H+}
interface
uses  Classes, SysUtils;
Procedure ModulesInit;
Procedure ModulesDone;
procedure BASICmain;

Const DrawTimeInterval=0;
Const DrawStartDelay=0;
Const VirtualStackSize=65536;

implementation
uses Forms, math, graphics,
 Unix,dl,
  base,base2,textfrm,textfile,arrays,affine,graphsys,
  math2sub,datalist,baslib,graphlib,debugdg,paintfrm,
  MyThread,assignlib, mathlib0;
{$MAXFPUREGISTERS 0}





(* Modules initialize and dispose *)
Procedure ModulesInit;
begin
end;
Procedure ModulesDone;
begin
end;

(* Main Program *)
procedure BASICmain;
var _I:double=0;
var __own1_00000:double=0;
var __own2_00001:double=0;
procedure _0ARROW; overload; forward;
procedure _0ARROW; overload;
begin
{$MAXFPUREGISTERS 0}
try
//     PLOT AREA: 0,0 ; 3,0 ; 2,1 ; 2,0.5 ; 0,0.5
PLOTAREA([0,0,3,0,2,1,2,0.5,0,0.5]);
//  END PICTURE

except
on E:EMathError do begin
  RecoverFloatException; 
  raise EExtype.create(PropagatedExtype( EXTYPE(E,ExCode))) end;
on E:EDivByZero do begin
  RecoverFloatException; 
   raise EExtype.create(PropagatedExtype( EXTYPE(E,ExCode))) end;
on E:EExType do begin
   E.extype:=PropagatedExtype(E.Extype); raise end;
end;
end;
begin
//  PICTURE arrow

//  SET WINDOW 0,8,0,8
SetWindow(0,8,0,8, false );
//  FOR i=1 TO 6
__own1_00000 := 6 ;
_I := 1 ;
while (_I <= __own1_00000) do begin
//     SET AREA COLOR 1
setareacolor(1, false );
//     SET AREA STYLE "HATCH"
GraphLib.SetAreaStyle('HATCH');
//     SET AREA STYLE INDEX i
SetAreaStyleIndex(_I, false );
//     DRAW arrow WITH SHIFT(0,i)
PushTransform;  shift(0,_I); mlt_next;
BeamManage;
_0ARROW;
PopTransform;
BeamManage;

//     PLOT TEXT, AT 3,i : "AREA STYLE INDEX " & STR$(i) 
PlotText(3,_I,'AREA STYLE INDEX '+STR_s(_I));
//     SET AREA COLOR i+1
setareacolor(_I+1, false );
//     DRAW arrow WITH SHIFT(5,i)
PushTransform;  shift(5,_I); mlt_next;
BeamManage;
_0ARROW;
PopTransform;
BeamManage;

//  NEXT i   
_I := _I + 1 ;
end;
//  END

end;{end main}
initialization
  AppName:='/home/shiraishi/デスクトップ/BASICAcc/STATEMEN/AREASTYL';
  SystemStackSize := 66846720;
  signiwidth0:=13;
  TextMode := false ;
  GraphMode:= true ;
  BMPSize:=BMP801;
  TextProblemCoordinate:= false ;
  UseCharInput:= false ;
  FontCharSet:=1;
  FontSize:=0;
  FontName:='default';
  FontStyle:=[];
  FirstThreadPriority:=tpNormal;



Finalization



end.
