[LON-CAPA-cvs] cvs: doc /rat rat.txt

matthew lon-capa-cvs@mail.lon-capa.org
Fri, 08 Mar 2002 14:33:40 -0000


This is a MIME encoded message

--matthew1015598020
Content-Type: text/plain

matthew		Fri Mar  8 09:33:40 2002 EDT

  Modified files:              
    /doc/rat	rat.txt 
  Log:
  Formatting changes to make it printable.
  
  
--matthew1015598020
Content-Type: text/plain
Content-Disposition: attachment; filename="matthew-20020308093340.txt"

Index: doc/rat/rat.txt
diff -u doc/rat/rat.txt:1.1.1.1 doc/rat/rat.txt:1.2
--- doc/rat/rat.txt:1.1.1.1	Tue Nov 16 12:36:55 1999
+++ doc/rat/rat.txt	Fri Mar  8 09:33:40 2002
@@ -14,32 +14,29 @@
 to do:
 * implement fancy resource rat widget
 
-
 * implement fancy resource linking information interface
   widget
 
-
 * implement resources on rat
 
 
-
 Program documentation
 GLOBAL VARIABLES
 
-row    array	maps row id to display  (example, d=row[i] where 'd' is display and 'i' is id)
-       used by	insertrow, findrow, horizontal, joinres, draw, main
+row          array   maps row id to display  (example, d=row[i] where 'd' is display and 'i' is id)
+             used by insertrow, findrow, horizontal, joinres, draw, main
 
-maxrow scalar	number of elements-2 in row array    (the last element number in the array, -1 for empty array)
-       used by	insertrow, findrow, horizontal, joinres, draw
+maxrow       scalar  number of elements-2 in row array    (the last element number in the array, -1 for empty array)
+             used by insertrow, findrow, horizontal, joinres, draw
 
-col    array	maps col id to display  (example, d=row[i] where 'd' is display and 'i' is id)
-       used by	insertrow, insertcol, findcol, maprow, comingthru, horizontal, joinres, drawrow, draw, main
+col          array   maps col id to display  (example, d=row[i] where 'd' is display and 'i' is id)
+             used by insertrow, insertcol, findcol, maprow, comingthru, horizontal, joinres, drawrow, draw, main
 
-maxcol scalar	number of elements-2 in col array    (the last element number in the array, -1 for empty array)
-       used by	insertcol, findcol, maprow, comingthru, insertport, drawrow, draw
+maxcol       scalar  number of elements-2 in col array    (the last element number in the array, -1 for empty array)
+             used by insertcol, findcol, maprow, comingthru, insertport, drawrow, draw
 
-colmap array	in order of display ids which object is in which column
-       used by	maprow, comingthru, insertport, horizontal, drawrow, draw, 
+colmap       array   in order of display ids which object is in which column
+             used by maprow, comingthru, insertport, horizontal, drawrow, draw, 
 
 colmap2	    array	temporary
 	    used by	drawrow
@@ -80,8 +77,6 @@
 data1,data2,data3,data4	array	 used to buffer memory so that javascript does not CRASH!
 			used by  drawrow, insertrow, insertport
 
-
-
 functions
 
 main - invokes RAT
@@ -102,71 +97,60 @@
       open, configure, and clear a debugging javascript window/                    /
                        |                                                          |
       go through all objects and display object information -----------------------
-                       |
       write out the value of col array ------- counting col ids from 0 to maxcol, print out a comma separated list of display locations
-                       |
       write out the value of row array ------- counting row ids from 0 to maxrow, print out a comma separated list of display locations
-                       |
-      find all the display rows (findrow) from 0 to last row, ------------------------------ findrow: does this my running through all rows and waiting till the value of an array
-                       |                                                                     index matches the row to display, returns row id
+      find all the display rows (findrow) from 0 to last row, 
+                       |                   findrow: does this my running through all rows and waiting till the value of an array
+                       |                   index matches the row to display, returns row id
         map this row (maprow), and output the results (colmap and rowcont) onto
-                       |________________________________
-                       |                                \
-                       |                                 -- a debugging window with column id, colmap, and rowcont
-                       |                                        where colmap specifies where objects occur within a row based on "display column" location
-                       |                                        where rowcont is the objects within a row and
+                       |________________
+                       |                \
+                       |                 -- a debugging window with column id, colmap, and rowcont
+                       |                    where colmap specifies where objects occur within a row based on "display column" location
+                       |                    where rowcont is the objects within a row and
 	    	       |  
                        |
                        |
                initialize display-to-id array rrow (so that rrow[display] equals original row id)
-                       |
                initialize display-to-id array rcol (so that rcol[display] equals original col id)
-                       |
-               initialize row height and column width values where rh[1] is short row, rh[2] is tall row, cw[1] is skinny column, cw[2] is fat column
-                       |
+               initialize row height and column width values where rh[1] is short row, 
+                                  rh[2] is tall row, cw[1] is skinny column, cw[2] is fat column
                set javascript RAT display window options (javascript stuff...)
-                       |
                output HTML beginning to RAT display window
-                       |
                run through the rows to display, convert from display row # to row id (rrow) and draw in edit mode (drawrow)
                                                                                                                       |
-                                                                                                                      |
-                                                                                                           drawrow begins by clearing out and initializing
-                                                                                                           these temporary arrays
-                                                                                                               colmap,colmap2,colmap3,colmap4,colmap5
-                                                                                                           output HTML beginning to row set to rowtype height (from row id)
-                                                                                                           if there are contents in the row (rowcont[jid] display them (else just end HTML row)
-                                                                                                             run through all the objects in row
-                                                                                                             if object is a 'b'lock object
-                                                                                                               do a lot of amazing things to position resource within block
-                                                                                                                 and draw arrows connecting into block in another amazing feat of code
-                                                                                                             if object is a 'h'orizontal object
-                                                                                                               grab input column id and output column id
-                                                                                                               and depending whether input is less than output in display position
-                                                                                                                 draw left-right arrow line or right-left arrow line
-                                                                                                                 and set leftmost position and rightmost position
-                                                                                                               look at inupdown and outupdown
-                                                                                                               if inupdown (means what ??) then
-                                                                                                                 draw top-to-right line, set colmap2 and colmap3
-                                                                                                               else draw right-to-down line
-                                                                                                               if outupdown (means what ??) then
-                                                                                                                 draw top-to-left line, set colmap2 and colmap3
-                                                                                                               else draw left-to-down line
-                                                                                                             if object is a 'v'ertical object
-                                                                                                               set left to display column and USE THIS as the position
-                                                                                                               if there is another element found in the colmap
-                                                                                                                 it must be horizontal so draw top-down-right-left intersection ('tdrl')
-                                                                                                               else draw top-to-down or down-to-top depending on 'v'ertical object specification
-                                                                                                               set colmap2[left] and colmap3[left] to a plain vertical line
-                                                                                                             run through columns and draw cells
-                                 drawcell draws in edit mode html stuff  ------------------------------------- rtype is set to type of row, the cell is drawn with drawcell
-                                                                                                               then using colmap2 and colmap3 draw two more up-down elements
-                                                                                                               in rows below if rowtype is 2
-
-
-
-
-
+               drawrow:   drawrow begins by clearing out and initializing
+                          these temporary arrays
+                              colmap,colmap2,colmap3,colmap4,colmap5
+                          output HTML beginning to row set to rowtype height (from row id)
+                          if there are contents in the row (rowcont[jid] display them (else just end HTML row)
+                              run through all the objects in row
+                              if object is a 'b'lock object
+                                  do a lot of amazing things to position resource within block
+                                  and draw arrows connecting into block in another amazing feat of code
+                                  if object is a 'h'orizontal object
+                                    grab input column id and output column id
+                                    and depending whether input is less than output in display position
+                                      draw left-right arrow line or right-left arrow line
+                                      and set leftmost position and rightmost position
+                                    look at inupdown and outupdown
+                                    if inupdown (means what ??) then
+                                      draw top-to-right line, set colmap2 and colmap3
+                                    else draw right-to-down line
+                                    if outupdown (means what ??) then
+                                      draw top-to-left line, set colmap2 and colmap3
+                                    else draw left-to-down line
+                                  if object is a 'v'ertical object
+                                    set left to display column and USE THIS as the position
+                                    if there is another element found in the colmap
+                                      it must be horizontal so draw top-down-right-left intersection ('tdrl')
+                                    else draw top-to-down or down-to-top depending on 
+                                            'v'ertical object specification
+                                    set colmap2[left] and colmap3[left] to a plain vertical line
+                                  run through columns and draw cells
+                   drawcell draws in edit mode html stuff  ---- rtype is set to type of row, the cell is drawn with drawcell
+                                                                then using colmap2 and colmap3 draw two more up-down elements
+                                                                in rows below if rowtype is 2
 
 ***************
 joinres from A to B

--matthew1015598020--