home *** CD-ROM | disk | FTP | other *** search
-
- REM name: shapes.cdl
-
- REM date: 010389 simon izraelevitz
-
- REM task: This program calls cadl programs by indicating
- REM an icon on the screen.
-
- REM -----------------------------------------------
-
- REM initialize variables
- CLEAR
- hsize = 6.0
- vsize = 5.4
- hoffset = 0.25
- voffset = 0.1
- hstart = 0.0
- vstart = 0.0
- rows = 4
- columns = 4
- hinc = hsize / columns
- vinc = vsize / rows
- htx = hinc / 12
- vtx = vinc / 3
- wx1 = @xmin
- wy1 = @ymin
- wx2 = @xmax
- wy2 = @ymax
- curview = @view
- units = @units
- set unit, 0
- set view, 1
-
- REM Display shape icon menu and get choice
- :dspmenu
- DOSUB sh_scrn.cdl
-
- :getmenu
- menopt = 1
- GETPOS "Cursor-indicate CADL program to run", menopt
- IF (@key <= -2)
- GOTO end
- IF (@key != 1)
- GOTO getmenu
- col = floor (@xview / hinc)
- row = floor (@yview / vinc)
-
- ON col GOTO col1,col2,col3,col4,
-
- :col1
- ON row GOTO pos11,pos12,pos13,pos14,
-
- :col2
- ON row GOTO pos21,pos22,pos23,pos24,
-
- :col3
- ON row GOTO pos31,pos32,pos33,pos34,
-
- :col4
- ON row GOTO pos41,pos42,pos43,pos44,
-
- :pos11
- GOTO open
- :pos12
- DOSUB sh_rstr
- CHAIN sh_oval
- :pos13
- DOSUB sh_rstr
- CHAIN sh_kout
- :pos14
- DOSUB sh_rstr
- CHAIN sh_oslot
- :pos21
- GOTO open
- :pos22
- GOTO open
- :pos23
- DOSUB sh_rstr
- CHAIN sh_kin
- :pos24
- DOSUB sh_rstr
- CHAIN sh_rslot
- :pos31
- GOTO open
- :pos32
- GOTO open
- :pos33
- DOSUB sh_rstr
- CHAIN sh_2belt
- :pos34
- DOSUB sh_rstr
- CHAIN sh_sslot
- :pos41
- GOTO open
- :pos42
- GOTO open
- :pos43
- GOTO open
- :pos44
- DOSUB sh_rstr
- CHAIN sh_raslt
-
- :open
- PROMPT "No program is called by this box. Select again."
- WAIT 2
- GOTO getmenu
-
- :end
- DOSUB sh_rstr
-