Directory

← Back

GWT Graphics

A cross-browser vector graphics library for GWT

Author

Rating

The goal of the GWT Graphics library is to provide consistent cross-browser vector graphics library for Google Web Toolkit. Under the hood, the library uses to XML-based languages: SVG and VML. VML implementation is for Internet Explorer. Other browsers use SVG implementation.

Please note that GWT Graphics is a library for GWT. If you want to use it with Vaadin, you have to create your own Vaadin widget and use the library on the client-side.

For more information, see the related links!

Sample code

// Download gwt-graphics.jar and add it to the classpath of your project.
// Add the following line to the Module XML file of the project:
<inherits name='org.vaadin.gwtgraphics.GWTGraphics'/>


// After the above steps, you can use GWT Graphics in your project. 
// To draw something with the library, you have to add an instance of 
// DrawingArea to your application:
DrawingArea canvas = new DrawingArea(400, 400);
panel.add(canvas);

// After that you can start drawing. 
// For example, the following code draws a red circle :
Circle circle = new Circle(100, 100, 50);
circle.setFillColor("red");
canvas.add(circle);

Compatibility

(Loading compatibility data...)

Was this helpful? Need more help?
Leave a comment or a question below. You can also join the chat on Discord or ask questions on StackOverflow.

Version

  • IE9 uses SVG for rendering now
  • JavaDoc enhancements
  • GWT Graphics' version can be read from GWT Java code
  • Added Animate.onComplete() that is fired when animation completes
  • Bug fixes
Released
2011-08-31
Maturity
STABLE
License
Apache License 2.0

Compatibility

Framework
GWT 1.7+
Browser
Internet Explorer
Internet Explorer
Internet Explorer
Firefox
Opera
Safari
Google Chrome
Internet Explorer

GWT Graphics - Vaadin Add-on Directory

A cross-browser vector graphics library for GWT GWT Graphics - Vaadin Add-on Directory
The goal of the GWT Graphics library is to provide consistent cross-browser vector graphics library for Google Web Toolkit. Under the hood, the library uses to XML-based languages: SVG and VML. VML implementation is for Internet Explorer. Other browsers use SVG implementation. Please note that GWT Graphics is a library for GWT. If you want to use it with Vaadin, you have to create your own Vaadin widget and use the library on the client-side. For more information, see the related links!
Online