10REM >TitlTop
20REM by Steven Flintham
30REM
40REM A demonstration of one style of
mode 7 display.
50REM
60REM Sunday 6th September 1992
70:
80MODE 7
90VDU 23;8202;0;0;0;
100PROCdisable
110PROCinit
120PROCshow`style
130PROClist`program
140PROCenable
150END
160:
170DEF PROCdisable
180*FX229,1
190*FX4,2
200ENDPROC
210:
220DEF PROCinit
230ON ERROR MODE 7:REPORT:PRINT " at l
ine ";ERL:PROCenable:END
240ENDPROC
250:
260DEF PROCenable
270*FX229,0
280*FX4,0
290ENDPROC
300:
310DEF PROCshow`style
320PROCtitle("Mode 7 layout demonstrat
ion",3,4)
330PRINTTAB(7,24);CHR$131;"(C) Steven
Flintham 1992";TAB(0,3);
340PRINT "This is a demonstration of o
ne of the"
350PRINT "simplest mode 7 screen layou
ts. However,it can be very effective and
does leave"
360PRINT "a lot of the screen free for
the programto use."
370PRINT'"Note that the heading and te
xt at the"
380PRINT "bottom of the screen are bot
h correctly"
390PRINT "centered. When centering in
mode 7, it"
400PRINT "is important to allow for th
e space"
410PRINT "taken up by the control code
s -"
420PRINT "especially in 'reversed' are
as like the"
430PRINT "heading."
440PRINT'"Using a text window can avoi
d problems"
450PRINT "with scrolling. Press SPACE
to"
460PRINT "demonstrate this."
470*FX21
480REPEAT UNTIL GET=32
490ENDPROC
500:
510DEF PROCtitle(title$,fore%,back%)
520LOCAL x%
530x%=20-LEN(title$)/2
540PRINTTAB(x%-4,0);CHR$141;CHR$(128+b
ack%);CHR$157;CHR$(128+fore%);title$;"
";CHR$156
550PRINTTAB(x%-4,1);CHR$141;CHR$(128+b
ack%);CHR$157;CHR$(128+fore%);title$;"
";CHR$156
560ENDPROC
570:
580DEF PROClist`program
590VDU 28,0,22,39,3
600CLS
610*FX138,0,76
620*FX138,0,73
630*FX138,0,83
640*FX138,0,84
650*FX138,0,13
660ENDPROC