adg-demo: corrected custom error handler
piston: allow exporting with custom suffix
piston: improved suffix handling

Avoid to pick the greedest suffix (such as "pdf.png" in a.pdf.png) but
take the shortest ending one ("png").
adg-demo: improved UI initialization

There is no need (and in some case it is plain wrong) to initialize the
interface in the "clicked" callback: it will be called multiple times.
adg-demo: refactored UI handling

Refactored main level code and put regeneration after data changes in
only one place.
s/adg-demo:regenerate/piston:refresh/

Moved code that refreshes the part after data changes from adg-demo to
piston.lua and renamed to refresh. It will be shared in other
piston-based applications.
adg-web: first implementation

This script is yet able to generate a png file with all the data
overridable from the command line.

A typical example could look like this:

lua adg-web.lua A=70 B=15 C=30 > result.png