add plotting widget (with minor fixes)
make labels a factory function and add a demo