assorted fixes for 2d