Fixed bug where setting opacity to 0 was ignored. Fixes #628.