Description
Enables usage of GfxBuilder on your Griffon application.
Installation
The current version of griffon-gfx-plugin is 0.2.3
To install just issue the following command
griffon install-plugin gfx-builder
| Warning This plugin requires JDK6 to be installed, it will also constrain the running environment to JRE6 or above. |
Usage
Refer to GfxBuilder's documentation to know more about the graphical nodes. This builder also enables the following nodes to be used from swing:
| Node | Property | Type | Default | Required | Bindable | Notes |
|---|---|---|---|---|---|---|
| canvas [GfxCanvas] |
node | GfxNode | |
|
The following is an example of its usage (copy & paste it on SwingPad 0.4)
canvas(size: [200,200]) {
group(borderColor: 'none') {
antialias true
background(color: color('white'))
rect(x: 50, y: 50, w: 100, h: 100, fill: color('red'))
rect(x: 100, y: 100, w: 100, h: 100, fill: color('green'))
path {
moveTo(x: 100, y: 100)
lineTo(x: 150, y: 150)
lineTo(x: 50, y: 200)
close()
}
}
}


