home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frozen Fish 2: PC
/
frozenfish_august_1995.bin
/
bbs
/
d09xx
/
d0925.lha
/
DonsGenies
/
DonsGenies.lha
/
Don'sGenies
/
MarginsAllRound.pprx
< prev
next >
Wrap
Text File
|
1993-05-25
|
1KB
|
62 lines
/* This Genie puts an equal margin all round a box.
Written by Don Cox July '92 Not Public Domain. All rights reserved. */
signal on error
signal on syntax
address command
call SafeEndEdit.rexx()
cr="0a"x
CurrentUnits = ppm_GetUnits()
select
when CurrentUnits = 1 then units="inches"
when CurrentUnits = 2 then units="millimetres"
otherwise units ="points"
end
counter=0
do forever
box=ppm_ClickOnBox("Click on boxes to be changed")
if box=0 then break
counter=counter+1
boxes.counter=box
call ppm_SelectBox(box)
end
if counter=0 then exit_msg()
size = ppm_GetUserText(6,"Margin in "units)
if size = "" then exit_msg("Aborted by User")
if CurrentUnits = 2 then size = size/10 /* mm to cm */
else if CurrentUnits = 3 then size = size/12 /* points to picas */
do i=1 to counter
box=boxes.i
call ppm_SetBoxMargins(box,size,size,size,size)
end
call exit_msg()
end
error:
syntax:
do
exit_msg("Genie failed due to error: "errortext(rc))
end
exit_msg:
do
parse arg message
if message ~= "" then
call ppm_Inform(1,message)
call ppm_ClearStatus()
call ppm_AutoUpdate(1)
exit
end