1 (* Copyright (C) 2005-2023 Free Software Foundation, Inc. *)
2 (* This file is part of Chisel.
4 Chisel is free software; you can redistribute it and/or modify it under
5 the terms of the GNU General Public License as published by the Free
6 Software Foundation; either version 3, or (at your option) any later
9 Chisel is distributed in the hope that it will be useful, but WITHOUT ANY
10 WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 You should have received a copy of the GNU General Public License along
15 with gm2; see the file COPYING. If not, write to the Free Software
16 Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *)
17 DEFINITION MODULE MakeBoxes ;
24 System : LOGITECH MODULA-2/86
25 Description: Provides a list of all possible box sizes.
26 Any number of unique boxes may be requested and deleted.
29 EXPORT QUALIFIED InitBoxes, KillBoxes,
30 AddBoxes, GetAndDeleteRandomBox ;
34 InitBoxes - Initializes a list of boxes.
35 An index to this box list is returned.
38 PROCEDURE InitBoxes () : CARDINAL ;
42 KillBoxes - Kills a complete box list.
45 PROCEDURE KillBoxes (BoxListIndex: CARDINAL) ;
49 AddBoxes - Adds a list of boxes MinX..MaxX, MinY..MaxY
50 to a box list BoxListIndex.
53 PROCEDURE AddBoxes (BoxListIndex: CARDINAL;
54 MinX, MinY, MaxX, MaxY: CARDINAL) ;
58 GetAndDeleteRandomBox - Returns a random box from the box list and
59 this box is then deleted from the list.
62 PROCEDURE GetAndDeleteRandomBox (BoxListIndex: CARDINAL;
63 VAR SizeX, SizeY: CARDINAL) ;