I changed three default settings in X11 by issuing these unix
commands in a terminal window: defaults write com.apple.x11 wm_ffm true
defaults write com.apple.x11 wm_click_through -bool true
defaults write com.apple.x11 no_quit_alert true The
first two of these get rid of the annoying, non-canonical
click-to-focus property, and the third gets rid of a warning window
that pops up and prevents you from logging out if X11 is running.
man Xquartz and man quartz-wm for more
information and other possibilities.
Apple provides a one-button mouse by default. I strongly
recommend replacing this lobotomized mouse with a standard
third-party multi-button mouse with a scroll-wheel. Apple provides
the driver for such mice by default, and these mice tend to work
better if one does not install the third-party drivers that
come with multi-button mice. Just plug in the mouse to any USB port
on your computer and it simply works.
This behavior is only pathological on OS X and is a result of
the unusual ``rootless'' mode of running X11. On other unix
systems, a root xterm session is always run first, and this always
reads the .bash_profile file; subsequent invocations of
xterm will inherit the settings found in .bash_profile,
allowing finer control.
Python uses a GUI called Tkinter, which in turn relies upon Tk
being present. Normally, this is an X-windows based GUI
environment, and is thus absent from a default OS X installation.
Recently, most of the functionality of Tcl and Tk has been
``ported'' to an Aqua environment, and this is provided with the
default installation of OS X 10.4.x in
/System/Library/Frameworks. If for example you have
installed the X-windows version of Tcl Tk with the package
management system Fink, the Python compilation will use the
X-windows version of Tkinter unless you ensure that
/usr/bin is prepended to the PATH.
When this string is embedded in the argument of an osascript
command, the double quotes required by the AppleScript programming
language to be around the name of the application must each be
escaped with a backslash as shown.
AppleScript is a syntactically brain-damaged monstrosity of a
programming language. There are several books devoted to explaining
its Kafkaeqsue syntax, but none have managed to impart their wisdom
unto me. It tries to have an ``English-like'' syntax, resulting in
a verbose, confusing language that is difficult to use.
It is often quite helpful to think of these sorts of
interactions in terms of analogies having to do either with occult
paranormal phenomena or else intermediary vector bosons, for
purposes of absolute clarity.
OS X, and at least some GNU/Linux systems, assigns uid numbers
sequentially to each new user, starting with 501. Other systems
assign large random numbers, which makes the appearance of this
sort of security anomaly (or hole) statistically much more
unlikely.