home *** CD-ROM | disk | FTP | other *** search
Wrap
/* Boxes Quick Runaround. This is for doing runarounds on bitmaps. Draw around the relevant area of your bitmap using the polygon tool (not the freehand tool). Double-click to finish. This genie will then set up the polygon box quickly to give a standard irregular runaround; you can process several boxes at once. ©Don Cox Dec 92. Freely usable for non-commercial purposes, but not Public Domain. */ trace r address command call SafeEndEdit.rexx() call ppm_AutoUpdate(0) currentunits = ppm_GetUnits() call ppm_SetUnits(2) currentline = ppm_GetLineWeight() currentfill = ppm_GetFillPattern() counter = 0 do forever box=ppm_ClickOnBox(" Click on polygon boxes for runarounds...") if box=0 then break counter=counter+1 boxes.counter=box call ppm_SelectBox(box) end if counter = 0 then exit_msg("No boxes selected") do i = 1 to counter box = boxes.i info = ppm_GetBoxInfo(box) boxtype = word(info,1) if upper(boxtype) ~= "STRUCTURED" then iterate /* Framedata setting not working Dec 92 */ framedata = ppm_GetBoxFrameData(box) parse var framedata linecolor "0a"x fillcolor "0a"x lw "0a"x linepattern "0a"x fp call ppm_SetBoxFrameData(box,linecolor,"Red","0.00",linepattern,0) call ppm_SetBoxStandoff(box,0.4) call ppm_SetBoxTextWrap(box,2,0) call ppm_SetBoxTransparent(box,1) end call ppm_SetUnits(currentunits) call ppm_SetLineWeight(currentline) call ppm_SetFillPattern(currentfill) call ppm_SetWireFrame(0) 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,"Resume") call ppm_ClearStatus() call ppm_AutoUpdate(1) exit end