program TstGraph;
uses
  Crt,
  Graph,
  ScGraph;

var
  grDriver, grMode : Integer;
  Radius : Integer;
  ErrCode : Integer;

begin
  writeln('Spusteni testu');

  grDriver := Detect;
  ErrCode := ScInitGraph(grDriver, grMode);
  if (ErrCode <> grOK) then
  begin
    Writeln('Graphics error:', GraphErrorMsg(ErrCode));
  end;

  for Radius := 1 to 5 do
    Circle(100, 100, Radius * 10);
  FillEllipse(GetMaxX div 2, GetMaxY div 2, 100, 50);


  line(10,10,200,200);
  OutTextXY(10, 200, 'Test vypisu');
  writeln('Pokusy');
  writeln('Pokusy');
  writeln('Pokusy');
  writeln('Pokusy');

  delay(10000);

  ScCloseGraph;

  writeln('Ukonceni testu');
{$ifdef MCP}
  repeat until false;
{$else}
  Writeln('Zmackni libovolnou klavesu');
  repeat until keypressed;
{$endif}

end.
