adg: implemented autoscale in AdgCanvas
commit45dbbfb65ec8a331481c389479bfda4b7451123b
authorNicola Fontana <ntd@entidi.it>
Sat, 2 Feb 2013 22:00:20 +0000 (2 23:00 +0100)
committerNicola Fontana <ntd@entidi.it>
Sat, 2 Feb 2013 22:00:20 +0000 (2 23:00 +0100)
tree3784ec8ef1293174774b8db52cf9ee0a63038078
parent8072ff454ce9688fe63b381ec39db0b5a61eea43
adg: implemented autoscale in AdgCanvas

Added a bunch of API for providing the autoscale feature.
adg_canvas_set_scale{,_valist}() provides a way to specify a list of
scaled to be applied in sequence when adg_canvas_autoscale() is called.
When the first proper scale is found, the scale is applied to the local
map and the drawing is centered.

Actually the APIs are quite bindings unfriendly but that solution to
that problem is postponed when resynchronizing adg-lua.

Closes issue #65: http://dev.entidi.com/p/adg/issues/65/
demo/adg-demo.c
demo/adg-demo.ui.in
src/adg/adg-canvas-private.h
src/adg/adg-canvas.c
src/adg/adg-canvas.h.in