/* This Genie puts a decorative border around a box, using data stored in the genie. The resulting border is merged into a single box. The current line and fill colours are used.
Genie written and ⌐ by Don Cox July 92. Bug fixes Jan 93. Not public domain. All rights reserved. */
trace n
address command
signal on error
signal on syntax
signal on halt
signal on break_c
signal on break_d
signal on break_e
if ~show("l", "gdarexxsupport.library") then
if ~addlib("gdarexxsupport.library", 0, -30,0) then
do
call ppm_Inform(1,"Please install the gdarexxsupport.library in your libs: directory before running this Genie.")
end
call ppm_AutoUpdate(0)
call SafeEndEdit.rexx()
cr="0a"x
CurrentUnits = ppm_GetUnits()
select
when CurrentUnits = 1 then do
units="inches"
mul = 1
mul2 = 72
end
when CurrentUnits = 2 then do
units="mm"
mul = 10
mul2 = 28.4
end
otherwise do
call ppm_SetUnits(2)
units="mm"
mul = 10
mul2 = 28.4
end
end
mainbox = ppm_ClickOnBox(" Click on box to be given a border")
/* Place Corner Units. Setting angle before position is best for these as the basic unit is always at 0 degrees. It gives good results with boxes smaller than 2.5 mm. (Contrast BordersRepeats which has position before angle. */