6.1.3 Drawing the Zoom Box

The zoom box is defined by pressing a mouse button to mark the upper left corner of the desired box, and dragging the cursor to enlarge the box, then releasing the button. The contraints applied to the shape of the box vary slightly depending on which mouse button is held down. If the left button is pressed, then the aspect ratio of the zoom box will always match the current aspect ratio of the canvas viewport. If the right button is held down, then the zoom box will always be square. If the middle mouse button is used, the user may specify any aspect ratio.