Question: Write a Java program that displays in a frame a movable cross-hair made up of one horizontal line and one vertical line joining the left-right
Write a Java program that displays in a frame a movable cross-hair made up of one horizontal line and one vertical line joining the left-right and topbottom edges. The cross-hair should follow the mouse, such that the two lines intersect at the cursors position. Whenever the mouse button is pressed, the X-Y coordinates of the cursor position should be displayed near the cross point, either left or right, above or below, as necessary.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
