Page 1 of 1

PostPosted: Mon May 24, 2004 5:55 pm
by johncraw
I was looking for some code to produce graphs in Designer. Since
I did not find anything I created one.
I have tried to make it general purpose, since my application
requires different graphs, with differing series, ranges etc.
I offer it here to anyone else that might require this functionality.

The following box describes the code, as well as how to obtain
it. One note: This has not been tried on a Real device, however
it functions in the Palm and Sony emulators.

* GraphGadget
* Author: John Crawford
* email:
* Release history:
* Version Date Changes
* 1.0.0 05/20/2004 - Initial release
* Description:
* This is a general purpose graph gadget for Orbforms
* Designer. All of the drawing functions are contained within
* this file, as well as translation of values into graph
* locations.
* Highlights:
* - Can display up to 6 series.
* - Each series can contain up to 12 points
* - Each series can have a different marker
* - There is a large selection of colours. The colours will map
* to 1,2,4, and 8 bit codes. Note: The graph background
* colour that I use is white. Any colour, other than white,
* that would map to white will be changed to the next valid
* value.
* - The graph can display a title, x and y axis labels, and a
* legend. These may be turned off and on as required.
* - The legend names will be in the same colour as the series
* they represent.
* - By selecting a point on a series the value for that point
* will be displayed in the upper left corner of the graph,
* beside the title. (the title must be enabled for this to
* work)
* - If there are multiple series on a graph, you may select
* the legend name for that series, and all other series will
* disappear. This can be useful in a graph with a lot of
* series that you want to view the points for one of them.
* Selecting a point below or above the legend will redisplay
* all series.
* - The values displayed will be in the range between the
* minimum and maximum values in the series.
* - Multiple graph are supported
* - A graph can be repositioned, and/or resized. Note: No
* checking is done to ensure that the graph is within the
* screen area. This may cause a distorted view, or an error.
* - The gadget control does not have a visible property that
* can be read, only written. I have added one which is
* set when the gadget visibility is set.
* Using:
* The demo application, which is distributed with this code,
* should give enough information to get you started
* Getting the code:
* I do not have a website, or ftp site. Send an email to me
* and I will send you a zipped version of the GraphG application.
* This is the demo as well as the GraphGadget code
* Note: Please use the following subject for the email:
* "GraphGadget code request"
* This will help me sort the real from the Spam
* Changes and fixes:
* The gadget as is satisfies my requirement, which is the most
* important thing to me. If someone finds a problem, or has a
* change suggestion I will see about adding/fixing, and
* distribution of new versions, when I can.
* Disclaimer:
* This code is supplied as is, with no stated, or implied
* warranty. You may use, and distribute this code freely as
* you see fit. If you do distribute this to others please leave
* this section unchanged.
* You are responsible for making sure that the code functions
* as you require.

PostPosted: Mon Jul 26, 2004 6:02 pm
by johncraw
Someone made a request for the package today. However I accidentaly (stupidly) deleted the message before I sent it. Would the person please resend the request.
Thanks, and sorry
John Crawford

PostPosted: Sat Nov 20, 2004 4:47 pm
by johncraw
I have updated the graph gadget for Version 3 of designer. There was only one change:
in the GRAPHGAD.OC file change:

object Graph


struct Graph

everything else remains the same.