Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » 10 new Google Visualization widgets for RAP
10 new Google Visualization widgets for RAP [message #131772] Thu, 07 May 2009 21:31 Go to next message
David Donohue is currently offline David DonohueFriend
Messages: 104
Registered: July 2009
Senior Member
Google Visualization API consists of a number of charts, maps, and graphs
for the visualization of data. See
http://code.google.com/apis/visualization/documentation/gall ery.html

The 10 new widgets for Eclipse RAP include:
(1) MotionChart, which I believe is Google's implementation of the
Trendalyzer, as seen on gapminder.org and at TED -
http://www.ted.com/index.php/talks/hans_rosling_shows_the_be st_stats_you_ve_ever_seen.html
(2) line chart
(3) scatter chart
(4) partial implementation of GeoMap (regions supported, markers not
supported)
(5) pie chart
(6) column chart
(7) bar chart
(8) area chart
(9) gauge
(10) timeline

All widgets permit any supported settings to be passed into the widget.
Each widget expects a characteristic format of data. See the Google
Visualization API documentation for each widget.

All except gauge and motion chart send selection events to RAP.

Example code:
JSONGoogleDataTable dataTable = new JSONGoogleDataTable();
dataTable.addColumn("theyear", "Date", "string", null);
dataTable.addColumn("CO2", "CO2", "number", null);
dataTable.addColumn("Temperature", "Temperature", "number", null);
dataTable.addRow(new Object[] {"1970", 325, 14.1});
dataTable.addRow(new Object[] {"2009", 389, 14.7});
widgetData = dataTable.toString();

ColumnChart chart = new ColumnChart( composite, SWT.NONE );
chart.setWidgetOptions("{width: 300, height: 300}");
chart.setWidgetData(serializedData);
gridData = new GridData(300, 300);
chart.setLayoutData(gridData);

...

public void handleEvent(Event event) {
log.info("Event: " + event);
VisualizationWidget widget = (VisualizationWidget)event.widget;
log.info( "Selected item=" + widget.getSelectedItem() +
"; row=" + widget.getSelectedRow() +
"; column=" + widget.getSelectedColumn() +
"; value=" + widget.getSelectedValue());
}

Most are Flash components. No Google API key is required for the current
implementation.

I am currently hosting the code here in the repository for my project
INQLE, however I can put it elsewhere e.g. create a new project if folks
desire.
http://code.google.com/p/inqle/source/browse/#svn/trunk/org. inqle.ui.google.widgets

Many thanks to Ivan Furnadjiev, for his energetic help in the development
of these widgets! Thanks also to Christian Schmidt of Qooxdoo. Without
their help I could have not gotten this working.

David Donohue
Re: 10 new Google Visualization widgets for RAP [message #131912 is a reply to message #131772] Thu, 07 May 2009 21:50 Go to previous messageGo to next message
Chris Aniszczyk is currently offline Chris AniszczykFriend
Messages: 674
Registered: July 2009
Senior Member
David Donohue wrote:
> Many thanks to Ivan Furnadjiev, for his energetic help in the
> development of these widgets! Thanks also to Christian Schmidt of
> Qooxdoo. Without their help I could have not gotten this working.

AWESOME!

I think this stuff would be perfect for the RAP incubator!
http://www.eclipse.org/proposals/rap-incubator/

The project is still in the proposal phase but should have a creation
review.

What about you joining the project as a committer with the initial
contribution you have for the 10 viz widgets?

What does the RAP team think ;)?

Cheers,

Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
http://twitter.com/eclipsesource | http://twitter.com/caniszczyk
Re: 10 new Google Visualization widgets for RAP [message #131957 is a reply to message #131772] Fri, 08 May 2009 05:58 Go to previous messageGo to next message
Ivan Furnadjiev is currently offline Ivan FurnadjievFriend
Messages: 2426
Registered: July 2009
Location: Sofia, Bulgaria
Senior Member
Congratulations, David!!!

I'm glad to see that you successfully created these widgets.

Best,
Ivan

David Donohue wrote:
> Google Visualization API consists of a number of charts, maps, and
> graphs for the visualization of data. See
> http://code.google.com/apis/visualization/documentation/gall ery.html
>
> The 10 new widgets for Eclipse RAP include:
> (1) MotionChart, which I believe is Google's implementation of the
> Trendalyzer, as seen on gapminder.org and at TED -
> http://www.ted.com/index.php/talks/hans_rosling_shows_the_be st_stats_you_ve_ever_seen.html
>
> (2) line chart
> (3) scatter chart
> (4) partial implementation of GeoMap (regions supported, markers not
> supported)
> (5) pie chart
> (6) column chart
> (7) bar chart
> (8) area chart
> (9) gauge
> (10) timeline
>
> All widgets permit any supported settings to be passed into the
> widget. Each widget expects a characteristic format of data. See the
> Google Visualization API documentation for each widget.
>
> All except gauge and motion chart send selection events to RAP.
>
> Example code:
> JSONGoogleDataTable dataTable = new JSONGoogleDataTable();
> dataTable.addColumn("theyear", "Date", "string", null);
> dataTable.addColumn("CO2", "CO2", "number", null);
> dataTable.addColumn("Temperature", "Temperature", "number", null);
> dataTable.addRow(new Object[] {"1970", 325, 14.1});
> dataTable.addRow(new Object[] {"2009", 389, 14.7});
> widgetData = dataTable.toString();
> ColumnChart chart = new ColumnChart( composite, SWT.NONE );
> chart.setWidgetOptions("{width: 300, height: 300}");
> chart.setWidgetData(serializedData);
> gridData = new GridData(300, 300);
> chart.setLayoutData(gridData);
>
> ..
>
> public void handleEvent(Event event) {
> log.info("Event: " + event);
> VisualizationWidget widget = (VisualizationWidget)event.widget;
> log.info( "Selected item=" + widget.getSelectedItem() + ";
> row=" + widget.getSelectedRow() +
> "; column=" + widget.getSelectedColumn() +
> "; value=" + widget.getSelectedValue());
> }
>
> Most are Flash components. No Google API key is required for the
> current implementation.
> I am currently hosting the code here in the repository for my project
> INQLE, however I can put it elsewhere e.g. create a new project if
> folks desire.
> http://code.google.com/p/inqle/source/browse/#svn/trunk/org. inqle.ui.google.widgets
>
>
> Many thanks to Ivan Furnadjiev, for his energetic help in the
> development of these widgets! Thanks also to Christian Schmidt of
> Qooxdoo. Without their help I could have not gotten this working.
>
> David Donohue
>
Re: 10 new Google Visualization widgets for RAP [message #131969 is a reply to message #131912] Fri, 08 May 2009 13:27 Go to previous messageGo to next message
Rüdiger Herrmann is currently offline Rüdiger HerrmannFriend
Messages: 581
Registered: July 2009
Senior Member
Chris Aniszczyk wrote:
> David Donohue wrote:
>> Many thanks to Ivan Furnadjiev, for his energetic help in the
>> development of these widgets! Thanks also to Christian Schmidt of
>> Qooxdoo. Without their help I could have not gotten this working.
>
> AWESOME!
>
> I think this stuff would be perfect for the RAP incubator!
> http://www.eclipse.org/proposals/rap-incubator/
>
> The project is still in the proposal phase but should have a creation
> review.
>
> What about you joining the project as a committer with the initial
> contribution you have for the 10 viz widgets?
>
> What does the RAP team think ;)?
This is cool!
David, please let us know if you wish to become a committer on the
incubator and host your code there.

>
> Cheers,
>
> Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
> http://twitter.com/eclipsesource | http://twitter.com/caniszczyk
>
>
Re: 10 new Google Visualization widgets for RAP [message #132048 is a reply to message #131969] Fri, 08 May 2009 17:51 Go to previous messageGo to next message
David Donohue is currently offline David DonohueFriend
Messages: 104
Registered: July 2009
Senior Member
Chris, Rüdiger,
I will do whatever you suggest.
David Donohue
Re: 10 new Google Visualization widgets for RAP [message #132872 is a reply to message #132048] Thu, 14 May 2009 16:23 Go to previous message
Ralf Sternberg is currently offline Ralf SternbergFriend
Messages: 1313
Registered: July 2009
Senior Member

Hi David,
> Chris, Rüdiger,
> I will do whatever you suggest. David Donohue

that's a great contribution! Thanks for sharing this code.

We added your contribution as an initial work area to the RAP incubator
project proposal: http://www.eclipse.org/proposals/rap-incubator/

Ralf
Previous Topic:Styling CTabItem
Next Topic:setTextLimit for Text Doesn't Work?
Goto Forum:
  


Current Time: Thu Apr 25 00:06:51 GMT 2024

Powered by FUDForum. Page generated in 0.03936 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top