home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Inside Multimedia 1995 August
/
IMM0895.ISO01.iso
/
magazin
/
optix
/
disk2
/
optxfpac.set
/
SCROLBOX.OPT
< prev
next >
Wrap
Text File
|
1995-05-08
|
2KB
|
100 lines
def(i)
def(j)
def(k)
defs(text$)
procedure scrollbox(md,xl,yo,xr,yu,kcol,scol)
locals(i)
key(off)
keycol(kcol)
setcolor(scol)
if md=1
for i:=0 to yu-yo-1 do
copywin(xl,yo,xr,yo)
loadwin(xl,yu-1,16,0)
copywin(xl,yo+1,xr,yu)
loadwin(xl,yo,0,0)
next(i)
endif
if md=2
for i:=0 to yu-yo-1 do
copywin(xl,yu,xr,yu)
loadwin(xl,yo+1,16,0)
copywin(xl,yo,xr,yu-1)
loadwin(xl,yo+1,0,0)
next(i)
endif
if md=3
for i:=0 to xr-xl-1 do
copywin(xl,yo,xl+1,yu)
loadwin(xr-2,yo,16,0)
copywin(xl+1,yo,xr,yu)
loadwin(xl,yo,0,0)
next(i)
endif
if md=4
for i:=0 to xr-xl-1 do
copywin(xr-1,yo,xr,yu)
loadwin(xl+1,yo,16,0)
copywin(xl,yo,xr-1,yu)
loadwin(xl+1,yo,0,0)
next(i)
endif
return
procedure frame(xl,yo,xr,yu,col,dick)
locals(i,j)
viewport(xl,yo,xr,yu)
for i:=1 to dick/2 do
setcolor(col+i-1)
rectangle
incviewport
next(i)
if (dick/2)*2<>dick
incviewport
endif
for j:=1 to dick/2 do
setcolor(col+i-j)
rectangle
incviewport
next(j)
return
procedure setbox
frame(k,100,k+j+8,131,224,24)
viewport(k,100,k+j+8,130)
cbox(0,8,0)
printc(k+4+j/2,118,text$)
return
begin
readfont(1,'hel15x29.fnt')
font(1)
clearscreen(7)
gradation(224,239,32,8,5,63,63,63)
text$:='TEXT-SMOOTHSCROLLING'
textw(text$,j)
textcolor(24)
k:=xmax/2-j/2
viewport(k,100,k+j+8+40,170)
cbox(8,8,0)
setbox
scrollbox(1,k+1,101,k+j+6,130,8,14)
setbox
scrollbox(2,k+1,101,k+j+6,130,8,14)
setbox
scrollbox(3,k+1,101,k+j+6,130,8,14)
setbox
scrollbox(4,k+1,101,k+j+6,130,8,14)
copywin(k+1,101,k+j+8-2,130)
readsound('ping.snd')
startsound
for i:=0 to j+8 step 2 do
loadsprite(0,0,k+i,101,j+8-i,30)
next(i)
pause(1000)
end