home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Datafile PD-CD 1B
/
DATAFILE_PDCD1B.iso
/
_pocketbk
/
pocketbook
/
003
/
table_zip
/
TABLE.OPL
next >
Wrap
Text File
|
1993-12-30
|
2KB
|
83 lines
REM Table v0.3
REM by Roger Burton-West <ubte30e@ucl.ac.uk>
REM copy freely and of your own will
PROC table:
local x%,y%,dy%,f%,s$(130),h%,xh%,i%(32),w%,k%
f%=7
s$="rom::\opd\*.fon"
dINIT "Choose font"
dCHOICE f%,"Font","S3 normal,S3 bold,S3 digit,Mono 8x8,Roman 8,Roman 11,Roman 13,Roman 16,Swiss 8,Swiss 11,Swiss 13,Swiss 16,Mono 6x6,Custom"
dFILE s$,"Custom font",8
if dialog=0
return
endif
busy "Working"+chr$(1),1
if f%=14
f%=gLOADFONT(s$)
endif
gFONT f%
gINFO i%()
gAT 0,7
gFONT 5
gPRINT peek$(addr(i%(9)))
h%=max(i%(4)+i%(5)+2,15)
xh%=h%*(int(i%(2)/30)-int(i%(1)/30)+1)
w%=gCREATE(0,0,480,xh%,0,0)
gUPDATE OFF
x%=0
dy%=0
do
gUSE 1
gFONT 5
gAT x%*14+60+7-gTWIDTH(gen$(x%,2))/2,11
gPRINT gen$(x%,2)
y%=int(i%(1)/30)
dy%=0
gUSE w%
gFONT f%
do
if x%=0
gFONT 5
gAT 40,(dy%+1)*h%-h%/2+4
gPRINT 30*y%
gFONT f%
endif
if x%+30*y%>=i%(1)
gAT x%*14+60+7-gTWIDTH(chr$(x%+30*y%))/2,(dy%+1)*h%-i%(4)
gPRINT chr$(x%+30*y%)
endif
y%=y%+1
dy%=dy%+1
until dy%=9 or x%+30*y%>i%(2)
x%=x%+1
until x%=30
busy off
gUPDATE ON
gUSE 1
y%=0
do
gUPDATE OFF
gAT 0,12
gCOPY w%,0,y%,480,min(xh%-y%,148),3
gUPDATE ON
gUPDATE
k%=get
if xh%>148
if k%=257
y%=min(y%+h%,xh%-148)
elseif k%=256
y%=max(y%-h%,0)
elseif k%=260
y%=0
elseif k%=261
y%=xh%-148
endif
endif
until k%<256
if f%>13
gUNLOADFONT f%
endif
gCLOSE w%
ENDP