h02815
s 00001/00000/00086
d D 1.2 83/02/18 00:36:36 mjb 2 1
c fixed numerous bugs with insertion and pie data in general
e
s 00086/00000/00000
d D 1.1 83/01/20 11:10:55 tes 1 0
c date and time created 83/01/20 11:10:55 by tes
e
u
tes
mjb
U
t
T
I 1
subroutine gpeatt (page)
########################################################################
#                                                                      #
#          THIS MATERIAL IS CONFIDENTIAL AND IS FURNISHED UNDER        #
#          A WRITTEN LICENSE AGREEMENT.  IT MAY NOT BE USED,           #
#          COPIED OR DISCLOSED TO OTHERS EXCEPT IN ACCORDANCE          #
#          WITH THE TERMS OF THAT AGREEMENT.                           #
#                                                                      #
#          COPYRIGHT (C) 1982 GRAPHIC SOFTWARE SYSTEMS INC.            #
#          ALL RIGHTS RESERVED.                                        #
#                                                                      #
#     Function: Get current pie chart attributes (for pie edit menu)   #
#               and put into common                                    #
#                                                                      #
#     Input Parameters:                                                #
#            page - (integer) page of menu to get attributes from      #
#                                                                      #
#     Output Parameters:                                               #
#            none                                                      #
#                                                                      #
#     Routines Called:                                                 #
#            qgeta - get alpha data from menu                          #
#            qgetd - get decimal data from menu                        #
#            qgeti - get integer data from menu                        #
#                                                                      #
########################################################################
integer page

SHORTINT string(CHARxREALxLENGTH)
integer i, item, vitem, k, j, m, n, start, end

include(`gphcom')

   call qgeta (1, bptitl)     # current pie chart title
   call qgeta (2, bpsitl)     # current pie chart subtitle
    
   start = 1
   end = 8
   if (page == 2) {
      start = 9
      end = 16
      }
   
   k = (start-1)*2 + 1        # initialize pointers
   j = (start-1)*19 + 1
I 2
   m = (start-1)*5 + 1
E 2
   n = start

   do i = start, end {        # Re-initialize current page of data
      bpdata(m) = NUL
      m = m + 5
      }
   m = (start-1)*5 + 1        # Reset m pointer

   vitem = 11
   do i = start,end {             

      call qgeta (vitem, string)    # get character string and check if valid

      if (string(1) != NUL) {

         call qgetd (vitem, bpdata(m)) # current slice values
	 m = m + 5
         item = vitem - 8

         call qgeta (item, bplabl(j)) # current slice labels (eight at time)
         j = j + 19
         item = item + 16

         call qgeta (item, bpexfg(k)) # current explode flags 
         k = k + 2
         item = item + 8

         call qgeti (item, bpslcl(n)) # current slice color
         item = item + 8

         call qgeti (item, bpslfl(n)) # current slice fill pattern 
	 n = n + 1
	 }

      vitem = vitem + 1
      }

   call sqshpi                        # eliminate blank values 

return
end
E 1
