Binary package “x2x” in ubuntu bionic

Link two X displays together, simulating a multiheaded display

 x2x joins a pair of X displays together, as if they were a single
 multiheaded display. The pointer can be warped between displays, or,
 depending on how you start x2x, can slide from one display to the
 other when it runs off the edge of the screen. Keyboard focus also
 moves between displays in the way you'd expect, and the X selection
 propagates around. This is useful when you have two displays on the
 same desk, as you can use a single keyboard and mouse to control
 both. (The displays being controlled remotely must support the XTEST
 extension. The servers shipped by Debian support this.)