home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frozen Fish 2: PC
/
frozenfish_august_1995.bin
/
bbs
/
d09xx
/
d0925.lha
/
DonsGenies
/
FrenchGenies.lha
/
Rexx
/
ZoomSurBoîte.pprx
< prev
Wrap
Text File
|
1993-08-03
|
954b
|
38 lines
/*
@BZoomSurBoεte @P @I Ecrit et ⌐ par Don Cox en juillet 1993
@IN'est pas du Domaine Publique. Tous Droits RΘservΘs.
Traduit par Fabien Larini le 02/08/93.
Ce GΘnie zoom sur la boεte active de telle sorte qu'elle remplisse l'Θcran.
NE MARCHE PAS SI IL N'Y A PAS DE BOITE ACTIVE.
*/
/* ZoomToBox */
/*
Zoom in or out so that the currently active box approximately fills the screen. Fails if there is no active box.
Written by Don Cox, July 93. Not Public Domain.
*/
trace n
address command
where = ppm_GetBoxPosition()
xpos = word(where,1)
ypos = word(where,2)
howbig = ppm_GetBoxSize()
width = word(howbig,1)
height = word(howbig,2)
widthmag = 1950/width /* 1950 is an arbitrary figure - edit it if you want to get different results */
heightmag = 1750/height /* likewise 1750 */
mag = min(widthmag,heightmag)
mag = trunc(mag)
if mag>400 then mag = 400
if mag<10 then mag = 10
call ppm_SetMagMode(mag)
call ppm_SetPagePosition(xpos,ypos)
exit