# XWin Server Resource File - EXAMPLE # Earle F. Philhower, III # Place in ~/.XWinrc or in /etc/X11/system.XWinrc # Keywords are case insensitive, comments legal pretty much anywhere # you can have an end-of-line # Comments begin with "#" or "//" and go to the end-of-line # Paths to commands are **cygwin** based (i.e. /usr/local/bin/xcalc) # Paths to icons are **WINDOWS** based (i.e. c:\windows\icons) # Menus are defined as... # MENU { # EXEC # ^^ This command will have any "%display%" # string replaced with the proper display # variable (i.e. 127.0.0.1:.0) # (This should only rarely be needed as # the DISPLAY environment variable is also # set correctly) # or MENU # or ALWAYSONTOP # ^^ Sets the window to display above all others # or RELOAD # ^^ Causes ~/.XWinrc or the system.XWinrc file # to be reloaded and icons and menus regenerated # or SEPARATOR # ... # } # Set the taskmar menu with # ROOTMENU # If you want a menu to be applied to all popup window's system menu # DEFAULTSYSMENU # To choose a specific menu for a specific WM_CLASS or WM_NAME use ... # SYSMENU { # # ... # } # When specifying an ICONFILE in the following commands several different # formats are allowed: # 1. Name of a regular Windows .ico format file # (ex: "cygwin.ico", "apple.ico") # 2. Name and index into a Windows .DLL # (ex: "c:\windows\system32\shell32.dll,4" gives the default folder icon # "c:\windows\system32\shell32.dll,5" gives the floppy drive icon) # 3. Index into XWin.EXE internal ICON resource # (ex: ",101" is the 1st icon inside XWin.exe) # To define where ICO files live (** Windows path**) # ICONDIRECTORY # NOTE: If you specify a fully qualified path to an ICON below # (i.e. "c:\xxx" or "d:\xxxx") # this ICONDIRECTORY will not be prepended # To change the taskbar icon use... # TRAYICON # To define a replacement for the standard X icon for apps w/o specified icons # DEFAULTICON # To define substitute icons on a per-window basis use... # ICONS { # # ... # } # In the case where multiple matches occur, the first listed in the ICONS # section will be chosen. # To disable exit confirmation dialog add the line containing SilentExit # DEBUG prints out the string to the XWin.log file // Below are just some silly menus to demonstrate writing your // own configuration file. menu devsystems { "host3 user" exec "xterm -T user@host3 -e ssh -Y user@host3" "host4 user" exec "xterm -T user@host4 -e ssh -Y user@host4" "host5 user" exec "xterm -T user@host5 -e ssh -Y user@host5" "host3 user" exec "xterm -T user@host3 -e ssh -Y user@host3" "host1 user" exec "xterm -T user@host1 -e ssh -Y user@host1" "host2 user" exec "xterm -T user@host2 -e ssh -Y user@host2" "host4 user" exec "xterm -T user@host4 -e ssh -Y user@host4" "host5 user" exec "xterm -T user@host5 -e ssh -Y user@host5" "host6 user" exec "xterm -T user@host6 -e ssh -Y user@host6" SEPARATOR "host1 user" exec "xterm -T user@host1 -e ssh -Y user@host1" SEPARATOR "hostgzt7 user" exec "xterm -T user@hostgzt7 -e ssh -Y user@nlbagzt7" } menu 4glesystems { "hosttldev1 user" exec "xterm -T user@hosttldev1 -e ssh -Y user@hosttldev1" "hosttldev1 user" exec "xterm -T user@hosttldev1 -e ssh -Y user@hosttldev1" } menu ccservers { "host user" exec "xterm -T user@host -e ssh -Y user@host" "host user" exec "xterm -T user@host -e ssh -Y user@host" "host user" exec "xterm -T user@host -e ssh -Y user@host" "host user" exec "xterm -T user@host -e ssh -Y user@host" "host bugs" exec "xterm -T bugs@host -e ssh -Y bugs@host" "host user" exec "xterm -T user@host -e ssh -Y user@host" SEPARATOR "host user" exec "xterm -T user@host -e ssh -Y user@host" "host user" exec "xterm -T user@host -e ssh -Y user@host" SEPARATOR "hostcc user" exec "xterm -T user@hostcc -e ssh -Y user@hostcc" "hostcc user" exec "xterm -T user@hostcc -e ssh -Y user@hostcc" "hostcc user" exec "xterm -T user@hostcc -e ssh -Y user@hostcc" "hostcc user" exec "xterm -T user@hostcc -e ssh -Y user@hostcc" } menu usersystems { "host3 user" exec "xterm -T user@host3 -e ssh -Y user@host3" "host4 user" exec "xterm -T user@host4 -e ssh -Y user@host4" "host5 user" exec "xterm -T user@host5 -e ssh -Y user@host5" "host3 user" exec "xterm -T user@host3 -e ssh -Y user@host3" "host1 user" exec "xterm -T user@host1 -e ssh -Y user@host1" "host2 user" exec "xterm -T user@host2 -e ssh -Y user@host2" "host4 user" exec "xterm -T user@host4 -e ssh -Y user@host4" "host5 user" exec "xterm -T user@host5 -e ssh -Y user@host5" "host6 user" exec "xterm -T user@host6 -e ssh -Y user@host6" SEPARATOR "host1 user" exec "xterm -T user@host1 -e ssh -Y user@host1" } menu usersystems { "host3 user" exec "xterm -T user@host3 -e ssh -Y user@host3" "host2 user" exec "xterm -T user@host2 -e ssh -Y user@host2" "host3 user" exec "xterm -T user@host3 -e ssh -Y user@host3" "host4 user" exec "xterm -T user@host4 -e ssh -Y user@host4" "host5 user" exec "xterm -T user@host5 -e ssh -Y user@host5" "host6 user" exec "xterm -T user@host6 -e ssh -Y user@host6" } // Make some menus... menu apps { xterm exec "xterm" "Emacs" exec "emacs" notepad exec notepad xload exec "xload -display %display%" # Comment } menu root { "Applications" menu apps SEPARATOR "Dev Systems" menu devsystems "ClearCase Servers" menu ccservers "SMS Systems" menu usersystems "Port Systems" menu usersystems "4GLE Systems" menu 4glesystems SEPARATOR FAQ EXEC "cygstart http://x.cygwin.com/docs/faq/cygwin-x-faq.html" "User's Guide" EXEC "cygstart http://x.cygwin.com/docs/ug/cygwin-x-ug.html" SEPARATOR "View logfile" EXEC "xterm -e less +F $XWINLOGFILE" SEPARATOR "Reload .XWinrc" RELOAD SEParATOR } menu aot { Separator "Always on Top" alwaysontop } menu xtermspecial { "Emacs" exec "emacs" "Always on Top" alwaysontop SepArAtor } RootMenu root DefaultSysMenu aot atend SysMenu { "xterm" xtermspecial atstart } # IconDirectory "c:\winnt\" # DefaultIcon "reinstall.ico" # Icons { # "xterm" "uninstall.ico" # } SilentExit DEBUG "Done parsing the configuration file..."