home *** CD-ROM | disk | FTP | other *** search
/ PC Online 1998 October / PCO_1098.ISO / filesbbs / os2 / bluecad.arj / BLUECAD.ZIP / macro.rx_ / test.rxm < prev   
Encoding:
Text File  |  1996-04-15  |  2.6 KB  |  63 lines

  1. /*****************************************************************************/
  2. /*                                                                                                           */
  3. /*  BlueCAD REXX Macro                                                                              */
  4. /*                                                                                                           */
  5. /*  Example of the use of REXX macro in BlueCAD                                            */
  6. /*                                                                                                           */
  7. /*  (c) 1995 CadWare s.r.l.                                                                          */
  8. /*                                                                                                           */
  9. /*****************************************************************************/
  10.  
  11.    call CADCmd deldraw
  12.  
  13.    step = 0
  14.    i = 0
  15.    col = 1
  16.    do while i < 21
  17.  
  18.      if col > 15 then col = 0
  19.                                               /* Modifies the current color */
  20.      call CADAttSet 'color', col
  21.                                                           /* Creates the segments */
  22.      call CADCrSegm step,0,2000,step
  23.      call CADCrSegm 0,step,step,2000
  24.                                                    /* Increments the counters */
  25.      i = i + 1
  26.      step = step + 100
  27.      col = col + 1
  28.      end
  29.                                                /* Optimal view of the drawings */
  30.    call CADCmd 'viewall'
  31.                                          /* Sets the rotation transformation */
  32.    call CADCmd 'rotapoint 1000,1000 10'
  33.  
  34.                                            /* Move command execution loop */
  35.    i = 0
  36.    do while i < 9
  37.      call CADCmd 'move sall'
  38.      i = i + 1
  39.      end
  40.  
  41.    step = 0
  42.    i = 0
  43.    col = 1
  44.    do while i < 21
  45.  
  46.      if col > 15 then col = 0
  47.                                               /* Modifies the current color */
  48.      call CADAttSet 'color', col
  49.                                                           /* Creates the segments */
  50.      call CADCrSegm step,0,2000,step
  51.      call CADCrSegm 0,step,step,2000
  52.                                                    /* Increments the counters */
  53.      i = i + 1
  54.      step = step + 100
  55.      col = col + 1
  56.      end
  57.  
  58.                               /* Setting color 1 at the end of the procedure */
  59.    call CADAttSet 'color', 1
  60.  
  61.                                                     /* Reading Warp logo */
  62.    call CADCmd 'bmpmerge c:\os2\bitmap\os2logo.bmp 750,750'
  63.