An open API service indexing awesome lists of open source software.

https://github.com/websemantics/oea.svg

SVG GUI and Graphics Library built following Java Swing. The Oea Framework provides three Javascript libraries, 1- Draw2D.svg, 2- Java.js and 3- Swing.svg to build SVG GUI applications
https://github.com/websemantics/oea.svg

Last synced: 3 months ago
JSON representation

SVG GUI and Graphics Library built following Java Swing. The Oea Framework provides three Javascript libraries, 1- Draw2D.svg, 2- Java.js and 3- Swing.svg to build SVG GUI applications

Awesome Lists containing this project

README

        

# Oea.svg
> Updated : March 24, 2016

SVG GUI and Graphics Library built after Java AWT. The Oea Framework provides three Javascript libraries, 1- Java.js, 2- Draw2D.svg and 3- Swing.svg to build SVG GUI applications.

![Calc](https://raw.githubusercontent.com/websemantics/Oea.svg/master/img/screens/calc.png)

The example above is a working calculator built with Oea.svg.

For more examples click on [Live Demo](http://oeasvg.com)

## Java.js

This package container a number of core Java classes that was required to implement both, Draw2D.svg and Swing.svg. Two Java packages have been ported, AWT and Util. AWT classes included Event and Geom namespaces while Util package included generic classes such as Hastable, Vector, Enumeration and many other useful code.

## Draw2D.svg

The svgDraw2D package is written for SVG in JavaScript to decouple the manipulation of DOM/SVG interfaces from writing graphics applications. The package provides a higher level of abstraction to JavaScript developers to manipulate graphics independently from the DOM API. It also provides capabilities for drawing sophisticated two-dimensional shapes, working with fonts, text and text layout, controlling colours; and it features layering management, styled tool tips and desktop canvas. The work on the svgDraw2D package was inspired by the Java AWT package.

![Draw2D.svg](https://raw.githubusercontent.com/websemantics/Oea.svg/master/img/screens/draw2d.png)

## Swing.svg

Swing was the unofficial code name of the project that developed Java Foundational Classes (JFC) for Java. This inspired the name Swing.svg for this package.

Swing.svg offers classes to help in developing GUI components. There are two main sets of components in Swing.svg: Top Level Containers (e.g. Panel and Window) and Basic Components (e.g. Button and ScrollBox).

Top Level Components inherit indirectly from the Component class through EventManager, hence they support direct AWT-like events. The Window class for instance may enable AWT-events and choose to listen to them through Mouse Motion Interface or Mouse Interface. The AWT-events received by the Window class have been generated by the EventManager and delivered by ListenerManager.

Button class handles AWT-like events generated from an indirect source; EContainer. EContainer is the root of a tree of Basic Components. AWT-like events received by EContainer are processed and then routed down the containment hierarchy to a target component (similar to DOM).

The Swing.svg Package has adapted a look-and-feel similar to that of MS-Windows. This is temporary. The package supports a pluggable look-and-feel model.

![Swing.svg](https://raw.githubusercontent.com/websemantics/Oea.svg/master/img/screens/swing.png)

The above is a collection of all the GUI components supported by Swing.svg

Download the original paper published in 2005 with more details [here](https://github.com/websemantics/Oea.svg/raw/master/docs/svg_open_2005_mem.pdf)

## Change Log
All notable changes to this project will be documented in this file as per [Keep a CHANGELOG](http://keepachangelog.com). This project adheres to [Semantic Versioning](http://semver.org/).

### [0.1.5] - 2016-03-24
#### Fixed
- Fixed an issue with getting text node baseline.
- Fixed an issue with ColorComboBox trying to set background color for null node.
- Fixed an issue with Chrome 48 removing support for `SVGGraphicsElement.getTransformToElement`.

## Install

- Clone this repo

```
git clone https://github.com/websemantics/Oea.svg
```

- Install Node.js modules

```
cd Oea.svg

sudo npm install
```

- Install Bower dependencies

```
bower install
```

- View `demos` folder for examples

## Related Projects

* [Hotdraw.js](https://github.com/websemantics/Hotdraw.js) - or view a [Live Demo](http://oeasvg.com/bower_components/Hotdraw.js/index.html).

* [Browser.js](https://github.com/websemantics/Browser.js) - or view a [Live Demo](http://oeasvg.com/bower_components/Browserjs/demos/script/index.html).