Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #15131
| From | Mike Duffy <Use_guestbook_page@website.in.sig> |
|---|---|
| Newsgroups | comp.lang.javascript |
| Subject | Function to create SVG "guage" graphics. |
| Date | 2012-07-22 02:55 +0000 |
| Organization | Your Company |
| Message-ID | <XnsA097E92DFF469invalidcom@94.75.214.39> (permalink) |
First, here is some background info. I wanted to develop a script to generate graphical "guages" similar to those found at: https://google- developers.appspot.com/chart/interactive/docs/gallery/gauge I decided not to use the Google app itself because in the past they have dropped support for their apps. (Translate API a few years back, and Google chart API during the coming year.) Also, I really do not like the idea of using apps with no source or obfuscated source. I did consider putting effort into improving one of the various public javascript "libraries", but I do not really like their generalistic approach. I just wanted a simple self-contained function with no external dependencies. Thus, I have written my own guage function. You can see sample (SVG) outputs here: http://pages.videotron.com/duffym/guagedemo.htm It is not really intended as a demo of all capabilities. It is instead a tool to test the various execution paths within the function. My questions are: 1) I do not feel good about using javacript object notation to define the argument list. (On the above page, you can see the source code for the argument object.) Is there a better way? 2) Is there anyone at all who is interested in using this? If so, I will make it easier to download, explicitly designate it as GPL, and perhaps add some internal comments. 3) Is there a need for further complicating the colors? Does anyone feel that it would be useful (for example), to say that you want 10 to 20 in red, 20 to 40 in red graduating to yellow, etc. ? BTW, I have re-done my astronomy page to use SVG instead of the Google Chart API. -- http://pages.videotron.ca/duffym/index.htm
Back to comp.lang.javascript | Previous | Next — Next in thread | Find similar | Unroll thread
Function to create SVG "guage" graphics. Mike Duffy <Use_guestbook_page@website.in.sig> - 2012-07-22 02:55 +0000
Re: Function to create SVG "guage" graphics. "Mel Smith" <med_cutout_syntel@aol.com> - 2012-07-21 22:23 -0600
Re: Function to create SVG "guage" graphics. Dr J R Stockton <reply1230@merlyn.demon.co.uk.not.invalid> - 2012-07-23 19:34 +0100
Re: Function to create SVG "guage" graphics. Mike Duffy <Use_guestbook_page@website.in.sig> - 2012-07-24 00:46 +0000
Re: Function to create SVG "guage" graphics. Tim Slattery <Slattery_T@bls.gov> - 2012-07-24 08:50 -0400
Re: Function to create SVG "guage" graphics. Mike Duffy <Use_guestbook_page@website.in.sig> - 2012-07-24 21:53 +0000
Re: Function to create SVG "guage" graphics. Gene Wirchenko <genew@ocis.net> - 2012-07-24 16:40 -0700
Re: Function to create SVG "guage" graphics. "Leonardo Azpurua" <leonardo@exmvps.org> - 2012-07-24 21:45 -0430
Re: Function to create SVG "guage" graphics. Tim Slattery <Slattery_T@bls.gov> - 2012-07-25 09:08 -0400
Re: Function to create SVG "guage" graphics. Dr J R Stockton <reply1230@merlyn.demon.co.uk.not.invalid> - 2012-07-25 19:25 +0100
Re: Function to create SVG "guage" graphics. Dr J R Stockton <reply1230@merlyn.demon.co.uk.not.invalid> - 2012-07-26 19:30 +0100
csiph-web