Note that you can zoom and shift it interactively, something you could not do when you created the graphic from the command line. However, there is no need to assign initial values to the variables. While it does not matter much now, it will become problematic when we add interactive manipulation of x0 . To manipulate the tangence point, we add a vertical line at x0 . When the user clicks the figure, SysQuake evaluates the SQ script continuously until the mouse button is released.
Functions are available to know which object the mouse is over and where the mouse is.
We use a switch block to change x0 only when the user manipulates the vertical line, and we change x0 before we use it to calculate the tangent line. SysQuake LE User Manual Copyright 1998-2001, Yves Piguet . All rights reserved.