procedure incptr;

begin

   pos ( ptr , 1 );
   write ( '   ' );

   if seiten
      then begin
           if ptr = 59
              then begin
                   offset := (offset + 60) mod (filez + 1);
                   list2;
                   ptr := 0;
                   end
              else begin
                   ptr := ptr + 1;
                   if (ptr + offset) mod (filez + 1) = 0
                      then incptr;
                   end;
           end
      else begin
           if ptr = filez - 1
              then ptr := 0
              else ptr := ptr + 1;
           end;

   pos ( ptr , 1 );
   write ( '==>' );
   commandzeile;

end; { incptr }


procedure decptr;

begin

   pos ( ptr , 1 );
   write ( '   ' );

   if seiten
      then begin
           if ptr = 0
              then begin
                   offset := (offset + filez - 59) mod (filez + 1);
                   list2;
                   ptr := 59;
                   end
              else begin
                   ptr := ptr - 1;
                   if (ptr + offset) mod (filez + 1) = 0
                      then decptr;
                   end;
           end
      else begin
           if ptr = 0
              then ptr := filez - 1
              else ptr := ptr - 1;
           end;

   pos ( ptr , 1 );
   write ( '==>' );
   commandzeile;

end; { decptr }
