added panning to piCanvas and error handling in piAtlas