• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Eliminating the xterm
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Eliminating the xterm


  • Subject: Re: Eliminating the xterm
  • From: Martin Costabel <email@hidden>
  • Date: Tue, 20 Nov 2007 11:41:19 +0100

Jeremy Huddleston wrote:
Honestly, I think that's not a good idea. For one thing, X11.app (which has the preferences you are talking about) doesn't launch xterm at start. The /A/U/X11.app executes the command 'xterm' then quits. xterm then connects to the $DISPLAY socket. launchd starts /u/X/X11.app (the one with the preferences) which launches Xquartz, etc...

Reasonably, there should be a PreferencePane that you can open with System Preferences, without having to run X11.app. And instead of (or in addition to) the Dock item, there should be a menu bar item, similar to what you have for Bluetooth, Airport or Spaces. Then you could run the entries from the X11 Applications menu from that menu bar drop-down menu, also without having to start X11.app first. This would solve a lot of the usability problems.

As for the so-called race condition, I don't think there really is one. When you start xterm in order to launch X11, xterm has already "won" the race, because it starts before the X server gets a chance to read any Xresources file. What can be done is to run a short script along the lines of the traditional xinit/xinitrc script, only without starting a window manager, and *then* run xterm (or not if the user does not want one); something like the following (note that the first 'xrdb' already wakes up launchd and starts the X server):

  PATH=${PATH}:/usr/X11/bin
  if [ -f "$HOME/.Xresources" ]; then
    xrdb -merge "$HOME/.Xresources"
  fi
  if [ -f "$HOME/.Xmodmap" ]; then
    xmodmap "$HOME/.Xmodmap"
  fi
  xterm -ls &


A minimal version (tested inside your Xterm.app) would be

  /usr/X11/bin/xrdb -merge "$HOME/.Xresources"
  /usr/X11/bin/xterm -ls &

If this does not work, then you can speak of a race condition, but for me it worked all the time.

--
Martin




_______________________________________________ Do not post admin requests to the list. They will be ignored. X11-users mailing list (email@hidden) This email sent to email@hidden
  • Follow-Ups:
    • Re: Eliminating the xterm
      • From: "Nathaniel Gray" <email@hidden>
References: 
 >Fwd: Eliminating the xterm (From: "Nathaniel Gray" <email@hidden>)
 >Re: Eliminating the xterm (From: "Nathaniel Gray" <email@hidden>)
 >Re: Eliminating the xterm (From: Peter Collinson <email@hidden>)
 >Re: Eliminating the xterm (From: Ben Byer <email@hidden>)
 >Re: Eliminating the xterm (From: Francisco De La Cruz <email@hidden>)
 >Re: Eliminating the xterm (From: Bill Campbell <email@hidden>)
 >Re: Eliminating the xterm (From: Merton Campbell Crockett <email@hidden>)
 >Re: Eliminating the xterm (From: Bill Campbell <email@hidden>)
 >Re: Eliminating the xterm (From: "Mark E. Perkins" <email@hidden>)
 >Re: Eliminating the xterm (From: Martin Costabel <email@hidden>)
 >Re: Eliminating the xterm (From: Ben Byer <email@hidden>)
 >Re: Eliminating the xterm (From: Jeremy Huddleston <email@hidden>)
 >Re: Eliminating the xterm (From: Ben Byer <email@hidden>)
 >Re: Eliminating the xterm (From: Ralph Martin <email@hidden>)
 >Re: Eliminating the xterm (From: Jeremy Huddleston <email@hidden>)

  • Prev by Date: DS9 and static linking, was Re: The meaning(s) of $DISPLAY
  • Next by Date: Universally recommended workaround Xephyr not working for me...
  • Previous by thread: Re: Eliminating the xterm
  • Next by thread: Re: Eliminating the xterm
  • Index(es):
    • Date
    • Thread