home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frostbyte's 1980s DOS Shareware Collection
/
floppyshareware.zip
/
floppyshareware
/
BUER
/
TBW72.ZIP
/
TBD72.BAS
< prev
next >
Wrap
BASIC Source File
|
1988-11-19
|
13KB
|
384 lines
$INCLUDE "tbw72.inc"
CLS
textattr = SCREEN(1,1,1)
CALL Openwin(5,20,11,40,FNAttr(15,7),textattr,2,0,0,0)
CALL Printcwin(2,"TBW72")
SELECT CASE FNCurdisplay
CASE 0 : msg$ = "MONO"
CASE 1 : msg$ = "CGA"
CASE 2 : msg$ = "EGA"
CASE 3 : msg$ = "MCGA"
CASE 4 : msg$ = "VGA"
END SELECT
msg1$ = STR$(FNCurvideo)
msg$ = msg$ + " monitor in video mode "+msg1$
CALL Printcwin(3,msg$)
CALL Printcwin(5,"Copyright (C) 1988")
CALL Printcwin(6,"by Richard D. Fothergill")
x = 0
WHILE NOT INSTAT AND (x < 25000)
INCR x
WEND
CALL Closewin
IF INKEY$ <> "" THEN
a$ = INKEY$
a$ = CHR$(0)
END IF
done = 0
CALL Initmenus
CALL Openwin(1,1,3,80,FNAttr(7,1),FNAttr(15,1),2,0,0,0)
CALL Fakewin(3,1,22,80,FNAttr(7,1),FNAttr(15,1),14,0,0,0)
CALL Sprint(25,1," Use arrow keys to change selection - Return to select ",FNAttr(0,7))
WHILE NOT done
CALL Makehmenu(mitem$(),subitem$,mitemcount,mcurntpos,mstartpos,mhlattr,mflattr,mflon,mmenuspaces,mbarloc)
SELECT CASE mcurntpos
CASE 1 : CALL Fdemo
CASE 2 : CALL Tdemo
CASE 3 : CALL Sdemo
CASE 4 : CALL Edemo
CASE 5 : CALL Hdemo
CASE ELSE
CALL Closewin
CLS
CALL Openwin(9,16,8,52,FNAttr(0,7),FNAttr(1,7),2,0,0,0)
CALL Printcwin(3,"T B W")
CALL Printcwin(4,"7.2")
DELAY(3)
CALL Closewin
done = -1
END SELECT
WEND
CALL Textattr(textattr)
CLS
END
SUB Initmenus
SHARED mitem$(),subitem$,mitemcount,mcurntpos,mstartpos,mhlattr,mflattr,mflon,mmenuspaces,mbarloc
SHARED sitem$(),sliveitem$,sitemcount,scurntpos,sstartpos,shlattr,sflattr,snoattr,sbartype,sflon
SHARED eitem$(),eliveitem$,eitemcount,ecurntpos,estartpos,ehlattr,eflattr,enoattr,ebartype,eflon
SHARED hitem$(),hliveitem$,hitemcount,hcurntpos,hstartpos,hhlattr,hflattr,hnoattr,hbartype,hflon
IF FNCurvideo = 7 THEN menunoattr = FNAttr(0,0) ELSE menunoattr = FNAttr(8,1)
mcurntpos = 0
mstartpos = 1
mitem$(1) = "Frames"
mitem$(2) = "Titles"
mitem$(3) = "Shadows"
mitem$(4) = "Effects"
mitem$(5) = "Menus"
mitem$(6) = "Quit"
mitemcount = 6
mhlattr = FNAttr(0,7)
mflattr = FNAttr(15,1)
mflon = -1
mmenuspaces = 6
mbarloc = 1
subitem$ ="001110"
sliveitem$ = "11011011"
scurntpos = 0
sstartpos = 1
sitem$(1) = "Flat ( 0)"
sitem$(2) = "Reattribute (1, 2)"
sitem$(3) = "Solid (3, 4)"
sitem$(4) = "Light Hatch (5, 6)"
sitem$(5) = "Medium Hatch (7, 8)"
sitem$(6) = "Heavy Hatch (9,10)"
sitem$(7) = "Activate Items 3,6 "
sitem$(8) = "Deact. Items 3,6 "
sitemcount = 8
shlattr = FNAttr(0,7)
sflattr = FNAttr(15,1)
snoattr = menunoattr
sbartype = 1
sflon = -1
eliveitem$ = "11"
ecurntpos = 0
estartpos = 1
eitem$(1) = "Pop "
eitem$(2) = "Zoom "
eitemcount = 2
ehlattr = FNAttr(0,7)
eflattr = FNAttr(15,1)
enoattr = menunoattr
ebartype = 1
eflon = -1
hliveitem$ = "1111"
hcurntpos = 0
hstartpos = 1
hitem$(1) = "First Letter"
hitem$(2) = "Menu Bars "
hitem$(3) = "Types "
hitem$(4) = "General "
hitemcount = 4
hhlattr = FNAttr(0,7)
hflattr = FNAttr(15,1)
hnoattr = menunoattr
hbartype = 1
hflon = -1
END SUB
SUB Continue
CALL Sprintc(25,1,80," Press any key to continue... ",FNAttr(14,7))
WHILE NOT INSTAT
WEND
CALL Sprintc(25,1,80,"Use arrow keys to change selection - Return to select",FNAttr(0,7))
a$ = INKEY$
END SUB
SUB Fdemo
CALL Openwin(5,15,6,15,FNAttr(15,2),FNAttr(15,2),0,0,1,0)
CALL Titlewin(2,FNAttr(14,2),"[ Style 0 ]")
CALL Openwin(5,34,6,15,FNAttr(15,5),FNAttr(15,5),1,8,1,0)
CALL Titlewin(2,FNAttr(14,5),"[ Style 1 ]")
CALL Openwin(5,53,6,15,FNAttr(15,3),FNAttr(15,3),2,8,1,0)
CALL Titlewin(2,FNAttr(14,3),"[ Style 2 ]")
CALL Openwin(8,5,6,15,FNAttr(15,4),FNAttr(15,4),3,8,1,0)
CALL Titlewin(2,FNAttr(14,4),"[ Style 3 ]")
CALL Openwin(8,24,6,15,FNAttr(15,3),FNAttr(15,3),4,8,1,0)
CALL Titlewin(2,FNAttr(14,3),"[ Style 4 ]")
CALL Openwin(8,43,6,15,FNAttr(15,6),FNAttr(15,6),5,8,1,0)
CALL Titlewin(2,FNAttr(14,6),"[ Style 5 ]")
CALL Openwin(8,62,6,15,FNAttr(15,5),FNAttr(15,5),6,8,1,0)
CALL Titlewin(2,FNAttr(14,5),"[ Style 6 ]")
CALL Openwin(11,15,6,15,FNAttr(15,2),FNAttr(15,2),7,8,1,0)
CALL Titlewin(2,FNAttr(14,2),"[ Style 7 ]")
CALL Openwin(11,34,6,15,FNAttr(15,7),FNAttr(15,7),8,8,1,0)
CALL Titlewin(2,FNAttr(14,7),"[ Style 8 ]")
CALL Openwin(11,53,6,15,FNAttr(15,4),FNAttr(15,4),9,8,1,0)
CALL Titlewin(2,FNAttr(14,4),"[ Style 9 ]")
CALL Openwin(14,5,6,15,FNAttr(15,7),FNAttr(15,7),10,8,1,0)
CALL Titlewin(2,FNAttr(14,7),"[ Style 10]")
CALL Openwin(14,24,6,15,FNAttr(15,6),FNAttr(15,6),11,8,1,0)
CALL Titlewin(2,FNAttr(14,6),"[ Style 11]")
CALL Openwin(14,43,6,15,FNAttr(15,5),FNAttr(15,5),12,8,1,0)
CALL Titlewin(2,FNAttr(14,5),"[ Style 12]")
CALL Openwin(14,62,6,15,FNAttr(15,2),FNAttr(15,2),13,8,1,0)
CALL Titlewin(2,FNAttr(14,2),"[ Style 13]")
CALL Openwin(17,15,6,15,FNAttr(15,3),FNAttr(15,3),14,8,1,0)
CALL Titlewin(2,FNAttr(14,3),"[ Style 14]")
CALL Openwin(17,34,6,15,FNAttr(15,2),FNAttr(15,2),15,8,1,0)
CALL Titlewin(2,FNAttr(14,2),"[ Style 15]")
CALL Openwin(17,53,6,15,FNAttr(15,7),FNAttr(15,7),16,8,1,0)
CALL Titlewin(2,FNAttr(14,7),"[ Style 16]")
CALL Continue
FOR x = 1 TO 17
CALL Closewin
NEXT
END SUB
SUB Tdemo
CALL Openwin(8,8,10,68,FNAttr(15,5),FNAttr(15,5),2,0,1,0)
CALL Printcwin(3,"Titles may be placed in any of six different locations")
CALL Printcwin(4,"and in any color attribute!")
FOR x=1 TO 6
msg$ = STR$(x)
msg$ = "[ LOCATION "+msg$+" ]"
CALL Titlewin(x,FNAttr(9+x,5),msg$)
DELAY(1)
NEXT
CALL Continue
CALL Closewin
END SUB
SUB Sdemo
SHARED sitem$(),sliveitem$,sitemcount,scurntpos,sstartpos,shlattr,sflattr,snoattr,sbartype,sflon
CALL Openwin(3,30,10,25,FNAttr(7,1),FNAttr(15,1),10,8,1,0)
done = 0
WHILE NOT done
CALL Makevmenu(sitem$(),sliveitem$,sitemcount,scurntpos,sstartpos,shlattr,sflattr,snoattr,sbartype,sflon)
SELECT CASE scurntpos
CASE 1
CALL Openwin(10,4,7,74,FNAttr(15,5),FNAttr(15,5),2,0,0,0)
CALL Titlewin(2,FNAttr(15,5)," FLAT ")
CALL Openwin(11,8,10,30,FNAttr(15,3),FNAttr(0,3),1,0,0,0)
CALL Openwin(11,43,10,30,FNAttr(15,7),FNAttr(1,7),1,0,0,0)
CALL Continue
CALL Closewin
CALL Closewin
CALL Closewin
CASE 2
CALL Openwin(10,4,7,74,FNAttr(15,5),FNAttr(15,5),2,0,0,0)
CALL Titlewin(2,FNAttr(15,5)," REATTRIBUTE ")
CALL Openwin(11,8,10,30,FNAttr(15,3),FNAttr(0,3),2,8,1,0)
CALL Printcwin(7,"Left Shadow")
DELAY(2)
CALL Openwin(11,43,10,30,FNAttr(15,7),FNAttr(1,7),2,8,2,0)
CALL Printcwin(7,"Right Shadow")
CALL Continue
CALL Closewin
CALL Closewin
CALL Closewin
CASE 3
CALL Openwin(10,4,7,74,FNAttr(15,5),FNAttr(15,5),2,0,0,0)
CALL Titlewin(2,FNAttr(15,5)," SOLID ")
CALL Openwin(11,8,10,30,FNAttr(15,3),FNAttr(0,3),2,0,3,0)
CALL Printcwin(7,"Left Shadow")
DELAY(2)
CALL Openwin(11,43,10,30,FNAttr(15,7),FNAttr(1,7),2,0,4,0)
CALL Printcwin(7,"Right Shadow")
CALL Continue
CALL Closewin
CALL Closewin
CALL Closewin
CASE 4
CALL Openwin(10,4,7,74,FNAttr(15,5),FNAttr(15,5),2,0,0,0)
CALL Titlewin(2,FNAttr(15,5)," LT. HATCH ")
CALL Openwin(11,8,10,30,FNAttr(15,3),FNAttr(0,3),2,FNAttr(0,7),5,0)
CALL Printcwin(7,"Left Shadow")
DELAY(2)
CALL Openwin(11,43,10,30,FNAttr(15,7),FNAttr(1,7),2,FNAttr(0,7),6,0)
CALL Printcwin(7,"Right Shadow")
CALL Continue
CALL Closewin
CALL Closewin
CALL Closewin
CASE 5
CALL Openwin(10,4,7,74,FNAttr(15,5),FNAttr(15,5),2,0,0,0)
CALL Titlewin(2,FNAttr(15,5)," MED. HATCH ")
CALL Openwin(11,8,10,30,FNAttr(15,3),FNAttr(0,3),2,FNAttr(0,7),7,0)
CALL Printcwin(7,"Left Shadow")
DELAY(2)
CALL Openwin(11,43,10,30,FNAttr(15,7),FNAttr(1,7),2,FNAttr(0,7),8,0)
CALL Printcwin(7,"Right Shadow")
CALL Continue
CALL Closewin
CALL Closewin
CALL Closewin
CASE 6
CALL Openwin(10,4,7,74,FNAttr(15,5),FNAttr(15,5),2,0,0,0)
CALL Titlewin(2,FNAttr(15,5)," HEAVY HATCH ")
CALL Openwin(11,8,10,30,FNAttr(15,3),FNAttr(0,3),2,FNAttr(0,7),9,0)
CALL Printcwin(7,"Left Shadow")
DELAY(2)
CALL Openwin(11,43,10,30,FNAttr(15,7),FNAttr(1,7),2,FNAttr(0,7),10,0)
CALL Printcwin(7,"Right Shadow")
CALL Continue
CALL Closewin
CALL Closewin
CALL Closewin
CASE 7
MID$(sliveitem$,3) = "1"
MID$(sliveitem$,6) = "1"
CASE 8
MID$(sliveitem$,3) = "0"
MID$(sliveitem$,6) = "0"
CASE ELSE
CALL Closewin
done = -1
END SELECT
WEND
done = 0
END SUB
SUB Edemo
SHARED eitem$(),eliveitem$,eitemcount,ecurntpos,estartpos,ehlattr,eflattr,enoattr,ebartype,eflon
CALL Openwin(3,43,4,12,FNAttr(7,1),FNAttr(15,1),10,8,1,0)
done = 0
WHILE NOT done
CALL Makevmenu(eitem$(),eliveitem$,eitemcount,ecurntpos,estartpos,ehlattr,eflattr,enoattr,ebartype,eflon)
SELECT CASE ecurntpos
CASE 1
CALL Openwin(8,8,10,65,FNAttr(15,5),FNAttr(15,5),2,0,1,0)
CALL Printcwin(3,"Windows can be popped")
CALL Printcwin(4,"onto the screen.")
DELAY(2)
CALL Openwin(5,5,10,50,FNAttr(0,2),FNAttr(14,2),2,8,1,0)
DELAY(2)
CALL Openwin(13,15,10,60,FNAttr(1,3),FNAttr(15,3),3,8,1,0)
DELAY(2)
CALL Openwin(7,33,10,45,FNAttr(14,5),FNAttr(14,5),1,8,1,0)
CALL Continue
FOR x = 1 TO 4
CALL Closewin
NEXT
CASE 2
CALL Openwin(8,8,10,65,FNAttr(15,5),FNAttr(15,5),2,0,1,0)
CALL Printcwin(3,"Windows can be zoomed")
CALL Printcwin(4,"onto the screen.")
DELAY(2)
CALL Openwin(5,5,10,50,FNAttr(0,2),FNAttr(14,2),2,8,1,1)
DELAY(2)
CALL Openwin(13,15,10,60,FNAttr(1,3),FNAttr(15,3),3,8,1,1)
DELAY(2)
CALL Openwin(7,33,10,45,FNAttr(14,5),FNAttr(14,5),1,8,1,1)
DELAY(2)
CALL Openwin(7,20,12,40,FNAttr(15,4),FNAttr(14,4),2,8,1,1)
CALL Printcwin(5,"HOW ABOUT THAT !!!")
CALL Continue
FOR x = 1 TO 5
CALL Closewin
NEXT
CASE ELSE
CALL Closewin
done = -1
END SELECT
WEND
done = 0
END SUB
SUB Flhelp
CALL Openwin(12,13,7,55,FNAttr(1,7),FNAttr(1,7),2,0,1,1)
CALL Titlewin(2,FNAttr(15,7),"[ FIRST LETTER ]")
CALL Printwin(1,2,"To activate First Letter control you must set two")
CALL Printwin(2,2,"variables. FLOn must be set to -1 and you can")
CALL Printwin(3,2,"set FLAttr to the desired color you wish. Thats")
CALL Printwin(4,2,"all there is to it. Just be sure all strings begin")
CALL Printwin(5,2,"with a different letter.")
CALL Continue
CALL Closewin
END SUB
SUB Barhelp
CALL Openwin(12,13,7,55,FNAttr(1,7),FNAttr(1,7),2,0,1,1)
CALL Titlewin(2,FNAttr(15,7),"[ MENUBARS ]")
CALL Printwin(1,2,"There are currently four menu bar types:")
CALL Printwin(2,2," 0 - No visible bar 1 - Full width bar")
CALL Printwin(3,2," 2 - String width bar 3 - Pointer")
CALL Printwin(4,2,"You control what type is active by setting BarType")
CALL Printwin(5,2,"equal to the type desired.")
CALL Continue
CALL Closewin
END SUB
SUB Typehelp
CALL Openwin(12,13,7,55,FNAttr(1,7),FNAttr(1,7),2,0,1,1)
CALL Titlewin(2,FNAttr(15,7),"[ MENUTYPES ]")
CALL Printwin(1,2,"There are currently two menu types:")
CALL Printwin(2,2," 1 - Standard Vertical Menu (Makevmenu)")
CALL Printwin(3,2," 2 - Horizontal Menu (Makehmenu)")
CALL Continue
CALL Closewin
END SUB
SUB Generalhelp
CALL Openwin(12,13,7,55,FNAttr(1,7),FNAttr(1,7),2,0,1,1)
CALL Titlewin(2,FNAttr(15,7),"[ GENERAL ]")
CALL Printwin(1,2,"Remember MakeMenu is only a sub executed in a")
CALL Printwin(2,2,"predefined window so all window effects can be used")
CALL Printwin(3,2,"to enhance your menu. Including border and shadow,")
CALL Printwin(4,2,"as well as growing and all various color attribute")
CALL Printwin(5,2,"combinations. The choices are almost endless!")
CALL Continue
CALL Closewin
END SUB
SUB Hdemo
SHARED hitem$(),hliveitem$,hitemcount,hcurntpos,hstartpos,hhlattr,hflattr,hnoattr,hbartype,hflon
CALL Openwin(3,57,6,16,FNAttr(7,1),FNAttr(15,1),10,8,1,0)
done = 0
WHILE NOT done
CALL Makevmenu(hitem$(),hliveitem$,hitemcount,hcurntpos,hstartpos,hhlattr,hflattr,hnoattr,hbartype,hflon)
SELECT CASE hcurntpos
CASE 1 : CALL Flhelp
CASE 2 : CALL Barhelp
CASE 3 : CALL Typehelp
CASE 4 : CALL Generalhelp
CASE ELSE
CALL Closewin
done = -1
END SELECT
WEND
done = 0
END SUB