Added zoom and pan functions