Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have an application that needs the user to enter the x and y location of a couple of items on the screen. [Yes, this is crap and I'll replace it, but for now...]

On Mac OS X, I'm using Snapz Pro X. When I choose to take a snap of a selection, the interface displays the mouse cursor location. This is OK for my personal use, but I can't ask users to buy a $69 program for this function.

I thought I had a solution with the built-in program "Grab", but it reports the coordinates from the bottom left, and I need it from the top left.

I don't have access to Windows; not sure what to use there. I've not even been able to come up with good search terms since mouse and coordinates and x/y are so common. Ideas are welcome there. Extra credit: same x/y finder for Linux. A Java program would be OK too, since the main application is in Java.

share|improve this question
ACK! I've asked 4 questions in 1 (platform.each). But it would have seemed dumb to ask a separate question for each platform. Hm. – slothbear Dec 21 '09 at 5:05
The answers you folks posted helped me refine my search terms -- so I was able to find some more answers. Much appreciated! – slothbear Dec 24 '09 at 4:02
Uhm. Snapz Pro X has a 15-day free trial. After that, it watermarks the screen captures. And you don't even want the actual screen capture. Unless you think that's abusing the free trial. It's a great program; maybe they'll get hooked and buy it. – slothbear Dec 24 '09 at 4:09
I might as well be my own sock puppet at this point. – slothbear Dec 24 '09 at 4:09
See also Program for getting the cursor's x,y coordinates? with another suggestion for Windows. – slothbear Dec 25 '12 at 4:45

Point Position (for Windows) is a simple tool that lets you pick the coordinates for any point on your screen (using X,Y axis). Simply point one of the four corner arrows at the spot on your screen that you want to define and click the button to display the X/Y coordinates.

Point Position is freeware.

share|improve this answer
Upvote done. Isn't my recommendation beautiful, image and all? Would be a great pity to delete it :) – harrymc Dec 20 '09 at 21:35
I'll just upvote both of you, though merging answers like this would be better! – Ivo Flipse Dec 21 '09 at 12:06
@Ivo: No problem. We also upvoted each other. – harrymc Dec 21 '09 at 12:42
@Molly: It seems like the image carried the day. My apologies. – harrymc Dec 23 '09 at 14:25
Image was helpful, but since the answers were essentially the same, I accepted the one with lower reputation. Not sure why that would matter with reps in the Ks though. – slothbear Dec 24 '09 at 4:06

For Macintosh, use the built-in screen capture function. Press Command-Shift-4 to take a picture of part of the screen. The cursor switches to a crosshairs cursor that includes the x/y screen coordinates. Press ESC to cancel the operation

share|improve this answer
That works, but it's kind of tough to use in practice. The screen continues to update under the cursor (popups and junk in this case), plus the x/y numbers have poor contrasting colors and they're tiny. It sounds better to use the Grab program -- and teach them how to subtract the Y value from their screen height. You already have an ugly UI, what's one subtraction? – slothbear Dec 24 '09 at 4:12

For Windows you can use Point Position :

The way to use the application is very simple:

  • Move the window by putting your mouse cursor in the cross which is in the middle of it, and point one of the four corner arrows into the place of the screen you want to define.
  • Then push the button corresponding to the pointing arrow.
  • The text entries will take the color of the button, and they will show you the exact pointing position.


share|improve this answer
feel free to upvote my recommendation :) – Molly7244 Dec 20 '09 at 21:19
+1 i do like the picture, very cute :) – Molly7244 Dec 20 '09 at 21:51
I'll just upvote both of you, though merging answers like this would be better! – Ivo Flipse Dec 21 '09 at 12:07

I used Cursor Position from

From Mattlav Software: Cursor Position allows you to work out the exact X and Y position of your cursor even as you move it, it also tells you how many pixels you have gone across if you move the cursor with the application open.

share|improve this answer
Can you provide some details as to how the application solves the question? thanks. – suspectus Aug 26 '15 at 7:27
I edited the question – Ken Okech Aug 26 '15 at 8:10
That looks much better now. – suspectus Aug 26 '15 at 8:32
Nice app! Runs on Windows (not a dig, just noting since I included all platforms in the question). – slothbear Aug 26 '15 at 15:21

I was led to this page through a query of my own. I had a further search around and found xev (on Linux and Mac OS X.)

Here's the Mac OS X documentation:

The Bash commands

$ root=`xwininfo -root | grep xwininfo | sed 's/.*0x/0x/; s/ .*//'`

$ xev -id $root

provided me with the information required. :)

share|improve this answer
It is important to know that on OS X, the xev command requires installation of X11. This is an optional installation on later OS X systems. – slothbear Dec 25 '12 at 4:41

For Java, you can use the PointerInfo class, introduced in Java 1.5.

import java.awt.MouseInfo;
import java.awt.Point;

public class Portia {
     public static void main(String args[]) throws InterruptedException {
    	Thread.sleep(10000);  // some time for user to position mouse
    	Point spot = MouseInfo.getPointerInfo().getLocation();
share|improve this answer
up vote 0 down vote accepted

Quix App is a browser bookmarklet: cross-platform, no installation, no plug-ins.

Drag the bookmarklet to your bookmarks toolbar. Click. Enter the command ruler, and you get a nice cross-hairs cursor to work with, and an informative pop-up with all the coordinates.

alt text

share|improve this answer

Skitch from Evernote includes an x/y coordinate display while taking a screen snap. The numbers are small and don't have any contrast layer -- so they're hard to see on a black background. Skitch is currently free.

enter image description here

share|improve this answer

For Mac OS X, xScope is pretty good. Turn on the Loupe (magnify) tool to make it easier to see exactly where you are. Then use the Crosshair tool to locate the exact spot you need.

If you'd like to measure your spot from a place that is not relative to the screen origin, move the cursor to your local 0,0, then press Command-0 to set that spot as 0,0.

xScope is a commercial product from The iconfactory, $29.99 at this time. The app shows up in bundles regularly. But it must be worthwhile. Heck, the latest version boasts

70+ new features

share|improve this answer
Sockpuppet!!!!! – slothbear Jan 9 '14 at 0:34

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .