Quicktip: Using X11 on OS X

1 Comment

I use X11 all the time as a preferred option to Terminal, which isn’t great if you use a lot of Unix apps, including wantitng to make the best use of emacs.

However, getting the geometry settings right for new windows can be a bit of a pain, especially because the standard xwininfo application doesn’t report completely reliably information for a window if you move it to the right spot. In particular, the annoying menubar means you lose pixels, but xwinfinfo doesn’t correctly report that difference.

The trick is to take 26 pixels off the geometry settings. So, for a machine running at 1600×1200, using the 120pt Courier font (actually -*-courier-*-r-*-*-*-120-*-*-*-*-*-*), the following will open a half-screen size Xterm on the left:

xterm -geometry 111×88+0-26

And this one half a size on the right:

xterm -geometry 111×88-0-26

Change your .Xdefaults geometry and your .xinitrc contents respectively and your windows will open up nicely just where you want them without requiring any movement. You’ll need to experiment with your own preferred font size and window size of course; the important thing for me was those 26 pixels.

1 Comment


My dream for X11 on MacOSX is having the X11 copy/cut/paste
buffer automatically copy into the system one rather than
having to use the “Copy” menu item (since I have disabled
apple/command so I can use it as meta).

Comments are closed.