Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- The Library for Clipper - <b>l_hbar()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
                                 L_HBAR()


Syntax:        L_HBAR(<expN1>, <expN2>, <expN3>, <expN4>, <expN5>,
               <expN6>, <expN7>, <array1>, <expN8>, <expN9>, <array2>,


               <expN10>[,<array3>, <expN11>,...<array3+n>,
               <expN11+n>])


Purpose:       Draws horizontal bar graph using specified data.


Arguments:     <expN1> is the x co-ordinate of the upper left corner
               of the graph.

               <expN2> is the y co-ordinate of the upper left corner
               of the graph.

               <expN3> is the x co-ordinate of the lower right corner
               of the graph.

               <expN4> is the y co-ordinate of the lower right corner
               of the graph.

               <expN5> is the distance between the edges of successive
               bars.

               <expN6> is the width of a bar.

               <expN7> is the color code for the color of the axes.

               <array1> is the array containing the labels for the
               bars of the graph.

               <expN8> is the color code for the foreground color of
               the labels.

               <expN9> is the color code for the background color of
               the labels.

               <array2> is the array containing the first set of data
               items.

               <expN10> is the color code for the color by which
               <array2> data will be represented.

               <array3> is the array containing the second set of data
               items.

               <expN11> is the color code for the color by which
               <array3> data will be represented.

               <array3+n> is the array containing the final set of
               data items.

               <expN11+n> is the color code for the color by which
               <array3+n> data will be represented.


Returns:       Nothing.


Usage:         Useful for the graphical representation of data.


Examples:      USE Profits
               DECLARE arr[4]

               FOR i = 1 TO 4
                    arr[i] = 0
               NEXT i

               DO WHILE .NOT. EOF()
                  DO CASE
                     CASE Branch == "North"

                          arr[1] = arr[1] + Sales

                     CASE Branch == "South"
                          arr[2] = arr[2] + Sales

                     CASE Branch == "West"
                          arr[3] = arr[3] + Sales

                     CASE Branch == "East"
                          arr[4] = arr[4] + Sales

                     ENDCASE
                     SKIP
               ENDDO

               DECLARE labs[4]
               labs[1] = "North"
               labs[2] = "South"
               labs[3] = "West"
               labs[4] = "East"

               L_GMODE(18)
               L_TEXT("Horizontal BarGraph",1,60,60,14,2)
               L_HBAR(80,100,210,200,10,10,2,3,arr,labs,14,4)


Language:      C

See Also: L_GMODE() L_HSBAR() L_VBAR() L_VSBAR() L_TSIZE()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson