Create a mouse encoder with the C API Configure tracking mode and output format (this example uses SGR) Set terminal geometry for pixel-to-cell coordinate mapping Create and configure a mouse event ...