Subject: Frequently Asked Questions about X with Answers [long monthly posting] [For distribution with R6, parts of this document relating to older problems or containing commercial announcements have been removed.] [Based on the FAQ version Last-modified: 1994/05/01] This article contains the answers to some Frequently Asked Questions (FAQ) often seen in comp.windows.x. It is posted to help reduce volume in this newsgroup and to provide hard-to-find information of general interest. Please redistribute this article! This article includes answers to the following questions, which are loosely grouped into categories. Questions marked with a + indicate questions new to this issue; those with significant changes of content since the last issue are marked by !: 0) TOPIC: BASIC INFORMATION SOURCES AND DEFINITIONS 1)! What books and articles on X are good for beginners? 2) What courses on X and various X toolkits are available? 3)! What conferences on X are coming up? 4)! What X-related public mailing lists are available? 5)! How can I meet other X developers? (What X user groups are there?) 6) What related FAQs are available? 7) How do I ask a net-question so as to maximize helpful responses? 8) What publications discussing X are available? 9) What are these common abbreviations/acronyms? 10)! What is the ICCCM? (How do I write X-friendly applications?) 11)! What is the X Consortium, and how do I join? 12) Just what are OPEN LOOK and Motif? 13)! What is "low-bandwidth X" (LBX)? XRemote? PPP? SLIP? CSLIP? 14) TOPIC: USING X IN DAY-TO-DAY LIFE 15)! What are all these window managers? (Where can I get a "virtual" wm?) 16) Why does my X session exit when I kill my window manager (sic)? 17)! Can I save the state of my X session, like toolplaces does? 18) How do I use another window manager with DEC's session manager? 19) How do I change the keyboard auto-repeat rate? 20) How do I remap the keys on my keyboard to produce a string? 21)! How do I make a screendump or print my application (including menus)? 22) How do I make a color PostScript screendump of the X display? 23) How do I make a screendump including the X cursor? 24)! How do I convert or view Mac/TIFF/GIF/Sun/PICT/img/FAX images in X? 25) Where can I get an X-based 3-D object viewer? 26) How can I change the titlebar of my xterm window? 27)! Where can I find the xterm control sequences? 28)! How can I use characters above ASCII 127 in xterm ? 29) Why are my xterm menus so small (sic) ? 30) How can I print the current X selection? 31)! How does Xt use environment variables in loading resources? 32)! How to I have xdm put a picture behind the log-in window? 33) Why isn't my PATH set when xdm runs my .xsession file? 34)! How do I keep my $DISPLAY when I rlogin to another machine? 35) How can I design my own font? 36)! Why does adding a font to the server not work (sic)? 37) How do I convert a ".snf" font back to ".bdf" font? 38)! What is a general method of getting a font in usable format? 39) How do I use DECwindows fonts on my non-DECwindows server? 40)+ How do I get a font name from the structure? 41)! How can I set backgroundPixmap in a defaults file? (What is XPM?) 42) Why can't I override translations? Only the first item works. (sic) 43) How can I have a clock show different timezones? 44) I have xmh, but it doesn't work. Where can I get MH? 45) Why am I suddenly unable to connect to my Sun X server? 46) Why don't the R5 PEX demos work on my mono screen? 47)! How do I get my Sun Type-[45] keyboard fully supported by Xsun? 48) How do I report bugs in X? 49) Why do I get "Warning: Widget class version mismatch"? 50)! Why does my SPARC say "Mapping cg3c: No such device or address"? 51) Where can I find a dictionary server for xwebster? 52) TOPIC: OBTAINING X AND RELATED SOFTWARE AND HARDWARE 53) Is X public-domain software? 54)! How compatible are X11R3, R4, R5, R6? What changes are there? 55)! When is X11R6 available? 56)! What is Fresco? When is Fresco rumored to be available? 57)+ Where can I get X11R6 (source and/or binaries)? 58)! Where can I get X11R5 (source and/or binaries)? 59)! Where can I get XDM's Wraphelp.c ? 60)! Where can I get patches to X11R5? 61) What is the xstuff mail-archive? 62)! Where can I get X11R4 (source and binaries)? 63)! Where can I get OSF/Motif? 64) Does Motif work with X11R4? X11R5? 65) Where can I get toolkits implementing OPEN LOOK? 66) Where can I get other X sources? (including R5 modifications) 67)! Where can I get interesting widgets? 68) Where can I get a good file-selector widget? 69) Where can I find a hypertext widget in source code? 70)! What widget is appropriate to use as a drawing canvas? 71) What is the current state of the world in X terminals? 72) Where can I get an X server with a touchscreen or lightpen? 73)! Where can I get an X server on a PC (DOS or Unix)? 74) Where can I get an X server on a Macintosh running MacOS? 75) Where can I get X for the Amiga? 76) Where can I get a serial-based X server for connecting from home? 77) Where can I get a fast X server for a workstation? 78)! Where can I get a server for my high-end Sun graphics board? 79) Where can I get an "X terminal" server for my low-end Sun 3/50? 80) What terminal emulators other than xterm are available? 81) Does xterm offer colored text or a blinking cursor? 82)! Where can I get an X-based editor or word-processor? 83) Where can I get an X-based mailer? 84)! Where can I get an X-based paint/draw program? 85) Where can I get an X-based plotting program? 86) Where can I get an X-based graph-drawing program? 87) Where can I get an X-based spreadsheet? 88) Where can I get X-based project-management software? 89) Where can I get an X-based PostScript previewer? 90) Where can I get an X-based GKS package? 91)! Where can I get an X-based GL package? 92) Where can I get an X-based PEX package? 93) Where can I get an X-based TeX or DVI previewer? 94)! Where can I get an X-based troff previewer? 95)! Where can I get a WYSIWYG interface builder (or other shortcuts)? 96) Where can I find X tools callable from shell scripts? 97) Where can I get an X-based debugger? 98)! How can I "tee" an X program identically to several displays? 99)! Can I use C++ with X11? Motif? XView? 100) Where can I obtain alternate language bindings to X/Xt/Motif? 101) TOPIC: BUILDING THE X DISTRIBUTION [topic needs updating to R6] 102) What's a good source of information on configuring the X build? 103) Why doesn't my Sun with a cg6 work with R5? 104) Why doesn't my Sun with SunOS 4.1 know about _dlsym, etc.? 105) What is this "_get_wmShellWidgetClass undefined" error? 106) What's this problem with undefined _X symbols on SunOS 4.1.3? 107) Why does cc get used when I build X11R5 with gcc? 108) Why can't gcc 1.x compile X11R4 on my SPARC? 109) What are these I/O errors running X built with gcc? 110) What are these problems compiling X11R4 on the older Sun3? 111) What are these problems compiling the X server on SunOS 4.1.1? 112) What are these problems using R4 shared libraries on SunOS 4? 113) Can OLIT programs run with R5 Xt? (_XtQString undefined) 114)! How do I get around the SunOS 4.1 security hole? 115) How do I get around the frame-buffer security hole? 116) TOPIC: BUILDING X PROGRAMS 117)! What is Imake? 118)! Where can I get imake? 119)! I have a program with an Imakefile but no Makefile. What to do? 120) Why can't I link to the Xlib shape routines? 121) What are these problems with "_XtInherit not found" on the Sun? 122) TOPIC: PROGRAMMING PROBLEMS AND PUZZLES 123) Why doesn't my program get the keystrokes I select for (sic)? 124) How do I deiconify a window? 125) How do I figure out what window manager is running? 126) Is there a skeleton X program available? 127) Why does XtGetValues not work for me (sic)? 128) Why don't XtConfigureWidget/XtResizeWidget/XtMoveWidget work? 129) Why isn't there an XtReparentWidget call like XReparentWindow? 130) I'm writing a widget and can't use a float as a resource value. 131) Is this a memory leak in the X11R4 XtDestroyWidget()?! 132) Is this a memory leak in the X11R4 deletion of work procs?! 133) Why does the process size of my X programs go up,up,up? 134) Are callbacks guaranteed to be called in the order registered? 135) Why doesn't XtDestroyWidget() actually destroy the widget? 136) How do I query the user synchronously using Xt? 137) How do I determine the name of an existing widget? 138) Why do I get a BadDrawable error drawing to XtWindow(widget)? 139) Where can I get documentation on Xaw, the Athena widget set? 140) What's the difference between actions and callbacks? 141) How do I simulate a button press/release event for a widget? 142) Can I make Xt or Xlib calls from a signal handler? 143) What are these "Xlib sequence lost" errors? 144) How can my Xt program handle socket, pipe, or file input? 145) Why do I get a BadMatch error when calling XGetImage? 146) How can my application tell if it is being run under X? 147) How do I make a "busy cursor" while my application is computing? 148) How do I fork without hanging my parent X program? 149) Why doesn't anything appear when I run this simple program? 150) What is the difference between a Screen and a screen? 151) Can XGetWindowAttributes get a window's background pixel/pixmap? 152) How do I create a transparent window? 153) Why doesn't GXxor produce mathematically-correct color values? 154) Why does every color I allocate show up as black? 155) Why do I get a protocol error when creating a cursor (sic)? 156) Why can't my program get a standard colormap? 157) Why does the pixmap I copy to the screen show up as garbage? 158)! How can I most quickly send an image to the X server? 159) How do I check whether a window ID is valid? 160)! Can I have two applications draw to the same window? 161)! Why can't my program work with tvtwm or swm? 162) Can I rely on a server which offers backing store? 163) How do I catch the "close window" event to avoid "fatal IO error"? 164) How do I keep a window from being resized by the user? 165) How do I keep a window in the foreground at all times? 166) How do I make text and bitmaps blink in X? 167) How do I get a double-click in Xlib? 168)! How do I render rotated text? 169)! Why doesn't my multi-threaded X program work (sic) ? 170) What is the X Registry? (How do I reserve names?) If you have suggestions or corrections for any of these answers or any additional information, please send them directly to uunet!craft!faq; the information will be included in the next revision (or possibly the one after that; thanks for the many suggestions which haven't been incorporated yet). This version of the FAQ is in the process of having outdated information replaced by R6 information. This posting is intended to be distributed at approximately the beginning of each month. New versions are archived on ftp.x.org and rtfm.mit.edu and are also available from mail-server@rtfm.mit.edu and archive-server@nic.switch.ch (send "help"). ftp.x.org was previously known as export.lcs.mit.edu; x.org was previously known as expo.lcs.mit.edu. The information contained herein has been gathered from a variety of sources. In many cases attribution has been lost; if you would like to claim responsibility for a particular item, please let me know. Conventions used below: telephone numbers tend to be Bell-system unless otherwise noted; prices on items are not included; email addresses are those that work from the US. X Window System and Fresco are trademarks of the X Consortium, Inc. Other trademarks are the property of their respective owners. (Note: a script by George Ferguson (ferguson@cs.rochester.edu) to pretty-print this faq is available from ugle.unit.no:/pub/X11/contrib/xfaq2texinfo.) ---------------------------------------------------------------------- Subject: 0) TOPIC: BASIC INFORMATION SOURCES AND DEFINITIONS ---------------------------------------------------------------------- Subject: 1)! What books and articles on X are good for beginners? Ken Lee of SynOptics (klee@synoptics.com) regularly posts to comp.windows.x and ba.windows.x a bibliography containing cites of all known reference books and how-to manuals and also cites of selected technical articles on X and X programming; it is ftp-able as ftp.x.org:/contrib/Xbibliography and gatekeeper.dec.com:/pub/X11/contrib/Xbibliography Here is an unordered set of the reference books and tutorials most useful for beginners; most appear on that list [comments are gathered from a variety of places and are unattributable]: Asente, Paul J., and Swick, Ralph R., "X Window System Toolkit, The Complete Programmer's Guide and Specification", Digital Press, 1990. The bible on Xt. A treasury of information, excellent and invaluable. Distributed by Digital Press, ISBN 1-55558-051-3, order number EY-E757E-DP; and by Prentice-Hall, ISBN 0-13-972191-6. [The examples are on ftp.x.org in contrib/ and on gatekeeper.dec.com (16.1.0.2) in pub/X11/contrib as asente-swick.examples.tar.Z. They were also posted to comp.sources.x as xt-examples/part0[1-5].] Jones, Oliver, Introduction to the X Window System, Prentice-Hall, 1988, 1989. ISBN 0-13-499997-5. An excellent introduction to programming with Xlib. Written with the programmer in mind, this book includes many practical tips that are not found anywhere else. This book is not as broad as the O'Reilly Xlib tutorial, but Jones is an experienced X programmer and this shows in the quality and depth of the material in the book. Young, Doug. "The X Window System: Applications and Programming with Xt (Motif Version)," Prentice Hall, 1989 (ISBN 0-13-497074-8). The excellent tutorial "X Window System Programming and Applications with Xt," (ISBN 0-13-972167-3) updated for Motif. [Sources used to be on ftp.x.org; they are known to be also on ftp.funet.fi in /pub/X11/contrib/.] A Motif 1.2 version of this book is in progress. Young, Doug and John Pew, "The X Window System: Programming and Applications with Xt, OPEN LOOK Edition" (ISBN 0-13-982992-X). The tutorial rewritten for OLIT, with new examples and drag/drop information. [Examples are on ftp.x.org in youg.olit.tar.Z and in you OpenWindows 3 distribution in $OPENWINHOME/share/src/olit/olitbook.] Heller, Dan and Paula Ferguson. "Motif Programmers Manual". The 6th volume in the O'Reilly series covers application programming with Motif 1.2 and earlier, including UIL; it's full of good examples (ISBN 1-56592-016-3). Volume 6B is a reference book on Motif and UIL (ISBN ISBN 1-56592-038-4). [The examples are available on uunet in the nutshell archives.] Scheifler, Robert, and James Gettys, with Jim Flowers and David Rosenthal, "X Window System: The Complete Reference to Xlib, X Protocol, ICCCM, XLFD, X Version 11, Release 5, Third Edition," Digital Press, 1992. "The Bible" in its latest revision, an enhanced version of X documentation by the authors of the Xlib documentation. This is the most complete published description of the X programming interface and X protocol. It is the primary reference work and is not introductory tutorial documentation; additional tutorial works will usually be needed by most new X programmers. Digital Press order EY-J802E-DP, ISBN 0-13-971201-1. Nye, Adrian, "Xlib Programming Manual, Volume 1" and "Xlib Reference Manual, Volume 2," O'Reilly and Associates. The first volume is a tutorial with broad coverage of Xlib, and the second contains reference pages for Xlib functions and many useful reference appendices. Both cover X11R5 (and R4). ISBN 0-937175-26-9 (volume 1) and ISBN 0-937175-27-7 (volume 2). Nye, Adrian, and Tim O'Reilly, "X Toolkit Programming Manual, Volume 4," O'Reilly and Associates, 1989, 1992. The folks at O'Reilly give their comprehensive treatment to programming with the Xt Intrinsics, using the Athena Widgets in the examples; R5 versions are now available, as is a Motif 1.2 version (Volume 4M). O'Reilly, Tim, ed., "X Toolkit Reference Manual, Volume 5," O'Reilly and Associates. A professional reference manual for the X11R5 and X11R4 Xt. Mansfield, Niall. "The X Window System: A User's Guide," Addison-Wesley, 1989. A tutorial introduction to using X, now upgraded for R4. ISBN 0-201-51341-2. Quercia, Valerie and Tim O'Reilly. "X Window System User's Guide," O'Reilly and Associates. A tutorial introduction to using X. ISBN 0-937175-36-6. Covers R5; available in Athena and Motif editions. Mui, Linda and Eric Pearce. "X Window System Administrator's Guide for X11 R4 and R5" [ORA Volume 8]. Help for X users and administrators. ISBN 0-937175-83-8. Drafts of John Ousterhout's upcoming book on TCL/TK are on sprite.berkeley.edu (128.32.150.27) in /tcl. The final book will be published early 1994 by Addison-Wesley, ISBN #0-201-63337-X. (Prentice-Hall ordering is 201-767-5937. O'Reilly ordering is 800-998-9938 or 707-829-0515; ORA may also be contacted via email at order@ora.com or by logging into gopher.ora.com as gopher.) In addition, check the X11R4 and X11R5 core distribution in doc/tutorials for some useful papers and tutorials, particularly the file answers.txt. "Late Night's Top Ten X11 Questions" by Dave Lemke (lemke@ncd.com) and Stuart Marks (smarks@sun.com) answers other common questions and some of these here in more detail. A single volume, "Programmer's Supplement for R5" by David Flanagan, provides an overview of new R5 features; it includes man pages for Xlib, Xt, and Xmu. As of 10/93, its contents have been merged into other O'Reilly volumes and it is out of print. [ISBN 0-937175-86-2] ---------------------------------------------------------------------- Subject: 3)! What conferences on X are coming up? The Xhibition'94 trade show and conference, with tutorials, panels, presentations, and vendor exhibits, will be held at the San Jose Convention Center June 20-24. Information: +1 617 621 0060, xhibit@ics.com. The European X User Group holds an annual conference which typically includes includes paper presentations and a vendor exhibit. The 1994 conference will be at the Edinburgh Conference Centre on 27th and 28th October. Information: EXUG '94, PO Box 458, Cambridge, CB4 4AA Tel: 0954 789095, Fax: 0954 781797, Email: info@exug.demon.co.uk, WWW: . The Motif/COSE show is held in Washington to coincide with the FedUnix and the Federal Open Systems Conference. Information: motif@fedunix.org or paller@fedunix.org, 301-229-1062, fax 301-229-1063. The X Technical Conference is typically held in January in Boston. Registration information is available from registration@x.org, fax +1 617-253-7002. Other information is on ftp.x.org in /pub/DOCS/XConsortium/ (you can use the URL http://www.x.org/ftp/pub/DOCS/XConsortium). The XWorld Conference and Exhibition includes tutorials, panels, presentations and vendor exhibits. It is typically held in March in New York City. Other trade shows -- UnixExpo, Uniforum, Siggraph -- show an increasing presence of X, including tutorials and exhibits. ---------------------------------------------------------------------- Subject: 4)! What X-related public mailing lists are available? The xpert mailing list is the general, public mailing list on X maintained by the X Consortium. The mailings are gatewayed, so xpert is almost identical to the comp.windows.x Usenet newsgroup. *** If you get comp.windows.x, you don't need to *** *** be added to the xpert mailing list. *** Otherwise, you can join the list to receive X information electronically. It is best to find a local distribution; perhaps someone within your company is already receiving the mailing. As a last resort, send mail to xpert-request@x.org with a valid return electronic address. The xannounce mailing list carries major X announcements, such as new releases (including public patches from the Consortium), public reviews, adoption of standards by the X Consortium, and conference announcements. It does NOT carry advertisements, source code, patches, or questions. If you already receive the Usenet news group comp.windows.x.announce or the xpert mailing list, you don't need to be added to the xannounce mailing list. Otherwise, to subscribe, send a request to xannounce-request@x.org. Note: only redistribution addresses will be accepted for this list -- i.e. no personal addresses. If you wish to receive xannounce yourself, please contact your mail administrator to set up a local redistribution list and to put you on it. comp.windows.x.apps is not gatewayed to a mailing list. In addition, the X Consortium sponsors these public lists: bug-clx CLX bug reports and discussions x-ada X and ada x11-3d X and 3d graphics ximage image processing and X xvideo discussion of video extensions for X x-agent protocols for external agents (e.g. editres) To subscribe to any of the above mailing lists, send mail to the list with "-request" appended; this example adds pat@mumble.widget.com to the xpert mailing list: % mail xpert-request@x.org Subject: (none needed) subscribe xpert pat@mumble.widget.com ^D To unsubscribe: % mail xpert-request@x.org Subject: (none needed) unsubscribe ^D Other lists include: A mailing list for topics related to OPEN LOOK is sponsored by Greg Pasquariello of Unify corporation; send to openlook-request@unify.com (or openlook-request%unify@uunet.uu.net) for information. A mailing list for bugs in the publicly-available version of XView source, in particular, is sponsored by Sun; send for information to xviewbug-trackers-request@sun.com. A mailing list for topics related to Motif is sponsored by Brian Dealy; send to motif-request@lobo.gsfc.nasa.gov for information. (This group is gatewayed to comp.windows.x.motif.) A mailing list for topics related to the XPM pixmap-format is sponsored by Arnaud Le Hors of Group Bull; send to xpm-talk-request@sa.inria.fr for information. [1/91] A mailing list discussing InterViews can be subscribed to by sending to interviews-request@interviews.stanford.edu. A mailing list (amiga-x11@nic.funet.fi) for topics related to the port of X11 to the Amiga can be subscribed by sending to mailserver@nic.funet.fi a message containing Subject: Adding myself to AMIGA-X11 SUBS AMIGA-X11 Your Real Name A mailing list discussing multi-threaded Xlib can be subscribed to at mt-xlib-request@xsoft.xerox.com. A mailing list discussing the Andrew User Interface System (formerly Andrew Toolkit) is maintained by the Andrew Consortium. To subscribe, write to info-andrew-request@andrew.cmu.edu and specify whether you want messages in Andrew format or ASCII. The ASCII versions are copied to netnews group comp.soft-sys.andrew. A mailing list for the Motif-C++ bindings is sponsored by Ronald van Loon; subscribe to motif++-request@motif.hacktic.nl. A mailing list for SUIT users is available from suit-users-request@uvacs.cs.virginia.edu. A mailing list discussing the UIM/X builder can be subscribed to by sending a Subject line of "subscribe" to uimx-request@ivev.bau.tu-bs.de. A mailing list discussing the TeleUSE builder can be subscribed to by sending a request to teleusers-request@alsys.com. A mailing list discussing the Windowing Korn Shell may be subscribed to at wksh-request@usl.com. A mailing list for MetaCard users is available by sending to listserv@grot.starconn.com a message containing subscribe metacard-list firstname lastname quit ---------------------------------------------------------------------- Subject: 5)! How can I meet other X developers? (What X user groups are there?) O'Reilly and Associates sponsors a mailing list for the use of X user group organizers; subscribe by sending to listserv@ora.com the message "subscribe xgroups your@internet.address". Local area X user's groups are listed in Issue 4 of O'Reilly's X Resource journal; a list may also be available from xug@ics.com. The French X User Group is called AFUX and is based in Sophia Antipolis by CERICS. Information can be obtained from Miss Vasseur or Miss Forest; BP 148; 157, rue Albert Einstein; 06561 Valbonne Cedex; Phone: +33 93 95 45 00 / 45 01; Fax: +33 93 95 48 57. [10/90] The European X User Group was formed in 1989 to represent X users in Europe. It holds technical conferences at regular intervals. The EXUG also publishes a regular newsletter which is distributed free of charge to members. The EXUG also runs a email mailing list for members which is frequently used to address issues of European interest in X. Info: Tel: +44 (0) 954 789095; Fax: +44 (0) 954 781797; Email: info@exug.demon.co.uk ---------------------------------------------------------------------- Subject: 6) What related FAQs are available? Liam R. E. Quin (lee@sq.sq.com) posts a FAQ on Open Look to comp.windows.open-look. Brian Dealy posts a FAQ on Motif to comp.windows.x.motif. Peter Ware (ware@cis.ohio-state.edu) posts a FAQ for comp.windows.x.intrinsics; it is on ftp.x.org in contrib/FAQ-Xt. Art Mulder (art@cs.ualberta.ca) posts to comp.windows.x a FAQ on maximizing the performance of X. Steve Kotsopoulos (steve@ecf.toronto.edu) posts to comp.windows.x a FAQ about using X on Intel-based Unix systems. Justin Kibell (jck@citri.edu.au) posts to comp.windows.x a FAQ on games for X. Wade Guthrie (wade@nb.rockwell.com) posts to comp.windows.misc a FAQ which includes information on platform-independent GUI (PIGUI) development kits. Pete Phillips (pete@smtl.demon.co.uk) posts to comp.sources.wanted a FAQ on project-management programs. Wade Guthrie (wade@nb.rockwell.com) posts to comp.windows.misc a FAQ on on platform-independent GUI toolkits (PIGUI). The FAQ in alt.binaries.pictures contains information on viewing images with X and on massaging image formats. The FAQ in comp.mail.mh (gatewayed to MH-users@ics.uci.edu) includes a section on xmh. The FAQ in comp.lang.lisp contains information on several interface tools and toolkits. The FAQ for the Andrew User Interface System is available for ftp from emsworth.andrew.cmu.edu (128.2.45.40). ---------------------------------------------------------------------- Subject: 7) How do I ask a net-question so as to maximize helpful responses? When asking for help on the net or X mailing lists, be sure to include all information about your setup and what you are doing. The more specific you are, the more likely someone will spot an error in what you are doing. Without all the details, people who want to help you often have to guess -- if they are able to respond at all. Always mention what version of X you are using and where you got it from. If your server came from a different source as the rest of your X system, give details of that, too. Give the machine type, operating system, and O/S version for both the client and server machine. It may also be appropriate to mention the window manager, compiler, and display hardware type you are using. Then tell exactly what you are doing, exactly what happens, and what you expected/wanted to happen. If it is a command that fails, include the exact transcript of your session in the message. If a program you wrote doesn't work the way you expect, include as little of the source necessary (just a small test case, please!) for readers to reproduce the problem. ---------------------------------------------------------------------- Subject: 8) What publications discussing X are available? The trade magazines (Unix World, Unix Review, etc.) are publishing more articles on X. Two X-specific publications include: - O'Reilly and Associates publishes "The X Resource: A Practical Journal of the X Window System" (103 Morris St. #A, Sebastapol, CA 95472). Editorial information: Paula Ferguson (paula@ora.com). - The X Journal is started bi-monthly publication September 1991 on a variety of X topics. Subscription information: The X Journal, Subscriber Services, Dept XXX, P.O. Box 3000, Denville, NJ 07834, USA. Editorial information: editors%topgun@uunet.uu.net, editors@unx.com. ---------------------------------------------------------------------- Subject: 9) What are these common abbreviations/acronyms? Xt: The X Toolkit Intrinsics is a library layered on Xlib which provides the functionality from which the widget sets are built. An "Xt-based" program is an application which uses one of those widget sets and which uses Intrinsics mechanisms to manipulate the widgets. Xmu: The Xmu library is a collection of Miscellaneous Utility functions useful in building various applications and widgets. Xaw: The Athena Widget Set is the MIT-implemented sample widget set distributed with X11 source. Xm: The OSF/Motif widget set from the Open Software Foundation; binary kits are available from many hardware vendors. Xhp (Xw): The Hewlett-Packard Widget Set was originally based on R2++, but several sets of patches exist which bring it up to R3, as it is distributed on the X11R4 tapes. Supplemental patches are available to use it with R4/R5. CLX: The Common Lisp X Interface is a Common Lisp equivalent to Xlib. XDMCP: The X Display Manager Protocol provides a uniform mechanism for a display such as an X terminal to request login service from a remote host. XLFD: The X Logical Font Description Conventions describes a standard logical font description and conventions to be used by clients so that they can query and access those resources. RTFM: Common expert-speak meaning "please locate and consult the relevant documentation -- Read the Forgotten Manual". UTSL: A common expression meaning "take advantage of the fact that you aren't limited by a binary license -- Use The Source, Luke". API: Application-Programmer Interface. The function calls, etc., in a programming library. BDF: Bitmap Distribution Format; a human-readable format for uncompiled X fonts. GUI: graphical user interface. UIL: the User Interface Language, part of OSF/Motif which lets programmers specify a widget hierarchy in a simple text "outline" form WCL: the Widget Creation Language, a package which extends the understanding of the Xt resource format such that a widget hierarchy and actions on the widgets can be specified through the resources file GIL: the file format put out by Sun's OpenWindows Developers Guide 3.0 UIMS: User Interface Management System ---------------------------------------------------------------------- Subject: 10)! What is the ICCCM? (How do I write X-friendly applications?) The Inter-Client Communication Conventions Manual is one of the official X Consortium standards documents that define the X environment. It describes the conventions that clients must observe to coexist peacefully with other clients sharing the same server. If you are writing X clients, you need to read and understand the ICCCM, in particular the sections discussing the selection mechanism and the interaction between your client and the window manager. Alternate definition: the ICCCM is generally the M in "RTFM" and is the most-important of the least-read X documents. Get the ICCCM from these sources: - Version 2.0 of the ICCCM is an X Consortium standard as of R6. See xc/doc/specs/ICCCM in the R6 distribution. Older versions include: - as part of the R4 and R5 distributions - in the later editions of the Scheifler/Gettys "X Window System" book - as an appendix in some versions of O'Reilly's Volume 0, "X Protocol Reference Manual." A version in old copies of their Volume 1 is obsolete. The version in the Digital Press book is much more readable, thanks to the efforts of Digital Press's editors to improve the English and the presentation. [from David Rosenthal, 10/90] ---------------------------------------------------------------------- Subject: 11)! What is the X Consortium, and how do I join? The X Consortium was formed in January of 1988 to further the development of the X Window System and has as its major goal the promotion of cooperation within the computer industry in the creation of standard software interfaces at all layers in the X Window System environment. MIT for many years provided the vendor-neutral architectural and administrative leadership required to make the organization work. The X Consortium is now an independent consortium. Most of the Consortium's activities take place via electronic mail, with meetings when required. As designs and specifications take shape, interest groups are formed from experts in the participating organizations. Typically a small multi-organization architecture team leads the design, with others acting as close observers and reviewers. Once a complete specification is produced, it may be submitted for formal technical review by the Consortium as a proposed standard. The standards process typically includes public review (outside the Consortium) and a demonstration of proof of concept. Your involvement in the public review process or as a member of the Consortium is welcomed. Membership in the Consortium open to any organization; there are several membership categories. Write to Bob Scheifler, President, X Consortium, One Memorial Drive, Cambridge, MA 02142-1301, or send a message to membership@x.org, or look in /pub/DOCS/XConsortium on ftp.x.org, or use the URL http://www.x.org/ftp/pub/DOCS/XConsortium. [2/90; 9/93; 12/93; 5/94] ---------------------------------------------------------------------- Subject: 12) Just what are OPEN LOOK and Motif? OPEN LOOK and Motif are two graphical user interfaces (GUIs). OPEN LOOK was developed by Sun with help from AT&T and many industry reviewers; Motif was developed by the Open Software Foundation (OSF) with input from many OSF members. OPEN LOOK is primarily a user-interface specification and style-guide; there are several toolkits which can be used to produce OPEN LOOK applications. Motif includes an API specification; the only sanctioned Motif toolkit is the one from OSF. However, there are other toolkits which can be used to produce programs which look and behave like OSF/Motif; one of these, ParcPlace's (formerly Solbourne's) OI, is a "virtual toolkit" which provides objects in the style of OPEN LOOK and Motif, at the user's choice. OPEN LOOK GUI is also the name of a product from AT&T, comprising their OPEN LOOK Intrinsics Toolkit and a variety of applications. [Thanks to Ian Darwin, ian@sq.com, 5/91] With the recent COSE announcement it appears that Sun will be phasing out support for OPEN LOOK in favor of Motif. ---------------------------------------------------------------------- Subject: 13)! What is "low-bandwidth X" (LBX)? XRemote? PPP? SLIP? CSLIP? The one-line summary of LBX is: LBX = "XRemote" + reply/event/error compaction + caching There are several options for using X over serial lines: SLIP - Serial Line IP; this is both a mechanism and a protocol for sending IP packets over point-to-point serial links. It has been around for several years, and implementations are available for many of the major TCP/IP implementations. Most X Terminal vendors supply this as a checkoff item, although nobody really ever uses it since it is horribly slow. The TCP/IP headers add 40 bytes per packet and the TCP/IP encoding of the X protocol is rather verbose (rightfully so; it is optimized for packing and unpacking over high-speed links). CSLIP - Compressed header SLIP; this is a variant of SLIP that compresses the 40 bytes of TCP/IP headers down to about 5 or 6 bytes. It still doesn't do anything about reencoding the X protocol. Modems that do compression can help, but they increase packet latency (it takes time to dribble the uncompressed data through typical serial interfaces, plus the compression assembly time). PPP - Point-to-Point Protocol; this is an emerging standard for point-to-point links over serial lines that has a more complete set of option negotiation than SLIP. A growing number of people see the combination of PPP for the serial line management and CSLIP for the header compression as becoming common for running normal TCP/IP protocols over serial lines. Running raw X over the wire still needs compression somewhere to make it usable. XRemote - this is the name of both a protocol and set of products originally developed by NCD for squeezing the X protocol over serial lines. In addition to using a low level transport mechanism similar to PPP/CSLIP, XRemote removes redundancies in the X protocol by sending deltas against previous packets and using LZW to compress the entire data stream. This work is done by either a pseudo-X server or "proxy" running on the host or in a terminal server. There are several advantages to doing compression outside the modem: (1) You don't *have* to have compressing modems in there if you wouldn't otherwise be using them (e.g. if you were going to be directly connected), and (2) It reduces the I/O overhead by cutting down on the number of bytes that have to cross the serial interface, and (3) In addition to the effects of #2, it reduces the latency in delivering packets by not requiring the modem to buffer up the data waiting for blocks to compress. LBX - Low Bandwidth X; this is an X Consortium project that is working on a standard for this area. It is being chaired by NCD and Xerox and is using NCD's XRemote protocol as a stepping stone in developing the new protocol. LBX will go beyond XRemote by adding proxy caching of commonly-used information (e.g. connection setup data, large window properties, font metrics, keymaps, etc.) and a more efficient encoding of the X protocol. The hope is to have a Standard ready for public review in the first half of next year and a sample implementation available in R6. Additional technical information about how XRemote works and a few notes on how LBX might be different are available via anonymous ftp from ftp.x.org in contrib/ in the following files: XRemote-slides.ps slides describing XRemote XRemote-LBX-diffs.ps more slides describing some of LBX [information provided by Jim Fulton, jim@ncd.com; 7/92] There is also a set of slides on ftp.x.org from Jim Fulton's talk at the 7th X Technical Conference. LBX is designated as a work in progress in R6. See workInProgress/README and workInProgress/lbx/README in the R6 distribution for more information. ---------------------------------------------------------------------- Subject: 14) TOPIC: USING X IN DAY-TO-DAY LIFE ---------------------------------------------------------------------- Subject: 15)! What are all these window managers? (Where can I get a "virtual" wm?) The window manager in X is just another client -- it is not part of the X window system, although it enjoys special privileges -- and so there is no single window manager; instead, there are many, which support different ways for the user to interact with windows and different styles of window layout, decoration, and keyboard and colormap focus. In approximate chronological order (generally, the more recent ones conformant more with the ICCCM): wm: this simple title-bar window manager was phased out in R2 or R3 uwm: the Universal Window Manager is still popular for its speed, although it is very outdated. Moved to contrib/ on the R4 tape. twm (old): Tom's Window Manager was among the first non-MIT window managers and offered the user a great deal of customization options in a re-parenting window manager. awm: the Ardent Window Manager was for a while a hotbed for hackers and offered some features (dynamic menus) not found on more current window managers rtl: Siemen's window manager tiles windows so that they don't overlap and resizes the window with the focus to its preferred size. dxwm: Digital's dxwm is part of the DECwindows offering hpwm: HP's window manager offers a 3D look; it is a precursor of mwm mwm: the Motif window manager is part of the OSF/Motif toolkit tekwm: Tektronix's window manager offering olwm (Sun): olwm implements the OPEN LOOK GUI and some of the Style Guide functionality olwm (AT&T): ditto gwm: Bull's Generic Window Manager emulates others with a built-in Lisp interpreter. Version 1.7h (10/91) is on the R5 contrib tape; 1.7o is on avahi.inria.fr and ftp.x.org. [9/93] m_swm: the Sigma window manager is on the R4 tape pswm: Sun's PostScript-based pswm is part of the OpenWindows release swm: Solbourne's swm is based on the OI toolkit and offers multiple GUI support and also a panning virtual window; configuration information comes from the resources file. Sources are on ftp.x.org in contrib/swm.tar.Z; they require OI binaries. twm (new): the new Tab Window Manager from the R4 tape is a reworked twm and is the basis for several derivatives, including the one on the R5 tape vtwm: vtwm offers some of the virtual-desktop features of swm, with a single-root window implementation. A new version, vtwm-5.3, is based on the R5 twm and is available from ftp.x.org. [1/94] tvtwm: Tom's Virtual Tab Window Manager is also based on the new twm and provides a virtual desktop modeled on the virtual-root window of swm. It is available on ftp.x.org and mirroring archive servers. olvwm: the vtwm-style virtual-desktop added to Sun's olwm. It is available on archive servers; version 4.1 [2/94] is on ftp.x.org. mvwm: the vtwm-style virtual-desktop added to OSF's mwm. A beta version is floating around (most recently from suresh@unipalm.co.uk) but requires a source license to OSF/Motif 1.1.3 [3/92]. NCDwm: the window manager local to NCD terminals offers an mwm look XDSwm: the window manager local to Visual Technology's terminals is simple but full-featured. ctwm: Claude Lecommandeur's (lecom@sic.epfl.ch) modification of the R5 twm offers 32 virtual screens in the fashion of HP vuewm and also offers the window overview used in vtwm and tvtwm. Version 3.1 [2/94] source is on ftp.x.org. vuewm: HP's MWM-based window manager offers configurable workspaces. SAIC offers a version of this VUE environment. 4Dwm: SGI's enhanced MWM piewm: this version of tvtwm offers pie menus pmwm: IXI's Panorama version of MWM offers olvwm-like features. Info: +44 223 236 555, +1 408 427 7700; mmoore@x.co.uk or michaela@x.co.uk or laurie@ixi.com. fvwm: this virtual window manager has been rewritten from scratch and is very light on system resources (between half and two-thirds the memory usage of twm, on which it was based). fvwm offers most of the features others provide, plus additional features. Source is available from sunsite.unc.edu in /pub/Linux/X11/window-managers/; fvwm-1.20u-source.tar.z was current in 3/94. mwm 2.0: the 2.0 version of mwm, not generally released yet, includes support for multiple workspaces. Also of possible use is vr, by Richard Mauri (rmauri@netcom.com), on ftp.x.org and ftp.informatik.tu-muenchen.de (pub/comp/X11/contrib/clients/vr/vr-1.01.tar.Z); Vr is a workspace manager intended to be window-manager-independent. ---------------------------------------------------------------------- Subject: 16) Why does my X session exit when I kill my window manager (sic)? It needn't. What is probably happening is that you are running your window manager as the last job in your .xsession or .xinitrc file; your X session runs only as long as the last job is running, and so killing your window manager is equivalent to logging out. Instead, run the window manager in the background, and as the last job instead invoke something safe like: exec xterm -name Login -rv -iconic or any special client of your devising which exits on some user action. Your X session will continue until you explicitly logout of this window, whether or not you kill or restart your window manager. Alternatively, there is a chance that you are using OpenLook, which by default kills all clients on logging out. Change your Exit menu choice from EXIT to WMEXIT to correct this behavior. ---------------------------------------------------------------------- Subject: 17)! Can I save the state of my X session, like toolplaces does? Although no known window manager directly supports such a feature (olvwm and swm may come close) -- which may be equivalent to writing out a .xinitrc or .xsession file naming the geometry and WM_COMMAND of each application -- there is a contributed application which does much of what you are looking for, although it is not as complete as the SunView program toolplaces. Look for the application "xplaces" on an archive-server near you. There are several versions of this program floating around; look for a recent vintage. [10/90] Some new pseudo session-managers such as HP's vuewm provide for the saving of sessions including information on the geometry of currently-running applications and the resource database. [Bjxrn Stabell (bjoerns@staff.cs.uit.no); 3/93.] In Release 6 a new session management protocol was defined, called XSMP (see doc/specs/SM), for telling applications when to save their internal state and for managing user dialog during the save. R6 contains a very simple session manager that exercises this protocol in the workInProgress directory; look for xsm. R6 also added a new shell widget class to Xt to make it easier to write applications that react to messages from a session manager. The window managers still have to do the work to save the window positions. [Dave Wiggins (dpw@x.org); 5/94.] ---------------------------------------------------------------------- Subject: 18) How do I use another window manager with DEC's session manager? DEC's session manager will start dxwm up by default. To override this, add to your .Xdefaults file something like this line, naming the full pathname: sm.windowManagerName: /wherever/usr/bin/X11/your_favorite_wm ---------------------------------------------------------------------- Subject: 19) How do I change the keyboard auto-repeat rate? You can turn auto-repeat on or off by using "xset r on|off". The base X11 protocol, doesn't provide for varying the auto-repeat rate, which is a capability not supported by all systems. Some pre-R6 servers may provide command-line flags to set the rate at start-up time. If you have control over server start-up (see the man pages for xinit and xdm), you can invoke the server with the chosen settings; for example, you can start the R5 Xsun sample server with the options "-ar1 350 -ar2 30" to reduce the sensitivity of the keyboard. The R6 X Keyboard Extension provides a vendor-independent way to control repeat delay and rate. ---------------------------------------------------------------------- Subject: 20) How do I remap the keys on my keyboard to produce a string? There is no method of arranging for a particular string to be produced when you press a particular key. The xmodmap client, which is useful for moving your CTRL and ESC keys to useful places, just rearranges keys and does not do "macro expansion." Some (few) clients, including xterm and several X-based editors, accept a translation resource such as: xterm*VT100.Translations: #override \ F1: string("setenv DISPLAY unix:0") which permits the shorthand F1 to be pressed to reset the display locally within an xterm; it takes effect for new xterm clients. To include control characters in the string, use \nnn, where nnn is the octal encoding of the control character you want to include. Window managers, which could provide this facility, do not yet; nor has a special "remapper" client been made available. ---------------------------------------------------------------------- Subject: 21)! How do I make a screendump or print my application (including menus)? The xwd client in the X11 distributions can be used to select a window or the background. It produces an XWD-format file of the image of that window. The file can be post-processed into something useful or printed with the xpr client and your local printing mechanism. To print a screendump including a menu or other object which has grabbed the pointer, you can use this command: csh% sleep 10; xwd -root > output.xwd & and then spend 10 seconds or so setting up your screen; the entire current display will be saved into the file output.xwd. Note that xwd also has an undocumented (before R5) -id flag for specifying the window id on the command-line. [There are also unofficial patches on ftp.x.org to xwd for specifying the delay and the portion of the screen to capture.] Two publicly-available programs which allow interactive definition of arbitrary portions of the display and built-in delays are asnap and xgrabsc. There are several versions of xgrabsc; version 2.3, available on ftp.x.org [9/93] is the most recent. xgrab, part of the package, is an interactive front-end to xgrabsc. xsnap includes some asnap features and supersedes it; it also renders XPM output [version unknown]. It is available on ftp.x.org or avahi.inria.fr; see xsnap-pl2.tar.Z. A screen-dump and merge/edit program combining features of xwd and xpr is available from vernam.cs.uwm.edu as xdump1.0.tar.Z. Information: soft-eng@cs.uwm.edu. xprint, by Alberto Accomazzi (alberto@cfa.harvard.edu) is available from cfa0.harvard.edu (128.103.40.1) as /pub/wipl/xprint.export-2.1.tar.Z. The package allows users to create encapsulated color PostScript files which will print on any PostScript Level-1 compliant printer (black and white or color). To post-process the xwd output of some of these tools, you can use xpr, which is part of the X11 distribution (moved to contrib in R6). Also on several archives are xwd2ps and XtoPS, which produce Encapsulated PostScript with trimmings suitable for use in presentations (see ftp.x.org:contrib/xwd2ps.tar.Z and contrib/ImageMagick2.3.7.tar.Z). Also useful is the PBMPLUS/Netpbm package on many archive servers; and the Xim package contains Level 2 color PostScript output. The XV program can grab a portion of the X display, manipulate it, and save it in one of the available formats. ImageMagick has similar capabilities. Also: Some vendors' implementations of X (e.g. DECWindows and OpenWindows) include session managers or other desktop programs which include "print portion of screen" or "take a snapshot" options. Some platforms also have tools which can be used to grab the frame-buffer directly; the Sun systems, for example, have a 'screendump' program which produces a Sun raster file. Some X terminals have local screen-dump utilities to write PostScript to a local serial printer. Some vendors' implementations of lpr (e.g. Sony) include direct support for printing xwd files, but you'll typically need some other package to massage the output into a useful format which you can get to the printer. ---------------------------------------------------------------------- Subject: 22) How do I make a color PostScript screendump of the X display? If you need color PostScript in particular, you can - grab the screen-image using a program which can produce color PostScript, such as xgrabsc, xprint, and xv - grab the screen-image using xwd and post-process xwd into color PS. You can do this using xwd2ps or the XtoPS program from the ImageMagick distribution. The PBMPLUS/Netpbm package is also good for this, as is the Xim package. ---------------------------------------------------------------------- Subject: 23) How do I make a screendump including the X cursor? This can't be done unless the X server has been extended. Consider instead a system-dependent mechanism for, e.g., capturing the frame-buffer. ---------------------------------------------------------------------- Subject: 24)! How do I convert or view Mac/TIFF/GIF/Sun/PICT/img/FAX images in X? The likeliest program is an incarnation of Jef Poskanzer's useful++ Portable Bitmap Toolkit, which includes a number of programs for converting among various image formats. It includes support for many types of bitmaps, gray-scale images, and full-color images. PBMPLUS has been updated recently; the most recent version [12/91] is on ftp.x.org in contrib/pbmplus10dec91.tar.Z. Netpbm is based on the PBMPLUS 10dec91 release, with many additions and improvements. It is intended to be portable to many platforms while allowing for conversion of images between a variety of formats. The latest sources are on several sites, including wuarchive.wustl.edu (128.252.135.4) and peipa.essex.ac.uk (155.245.115.161). Contact oliver@fysik4.kth.se to be added to the netpbm mailing list. Another tool is San Diego Supercomputing Center's IMtools ('imconv' in particular), which packages the functionality of PBM into a single binary. It's available anonymous ftp from sdsc.edu (132.249.20.22). Useful for viewing and converting some image-formats is Jim Frost's xloadimage; the most recent [11/93] is on ftp.x.org in contrib/xloadimage.4.1.tar.Z. Graeme Gill's updates to an earlier version of xloadimage are also on ftp.x.org; see xli.README and xli.tar.Z.uu; version 1.15 was released 7/93. xv (X Image Viewer), written by bradley@cis.upenn.edu (John Bradley), can read and display pictures in Sun Raster, PGM, PBM, PPM, X11 bitmap, TIFF, GIF and JPEG. It can manipulate on the images: adjust, color, intensity, contrast, aspect ratio, crop). It can save images in all of the aforementioned formats plus PostScript. It can grab a portion of the X display, manipulate on it, and save it in one of the available formats. The program was updated 5/92; see the file contrib/xv-2.21.tar.Z on ftp.x.org. Version 3.00 [5/93] is distributed as shareware. The Fuzzy Pixmap Manipulation, by Michael Mauldin (mlm@nl.cs.cmu.edu). Conversion and manipulation package, similar to PBMPLUS. Version 1.0 available via FTP as nl.cs.cmu.edu:/usr/mlm/ftp/fbm.tar.Z, uunet.uu.net:pub/fbm.tar.Z, and ucsd.edu:graphics/fbm.tar.Z. The Img Software Set, by Paul Raveling , reads and writes its own image format, displays on an X11 screen, and does some image manipulations. Version 1.3 is available via FTP on ftp.x.org as contrib/img_1.3.tar.Z, along with large collection of color images. The Utah RLE Toolkit is a conversion and manipulation package similar to PBMPLUS. Available via FTP as cs.utah.edu:pub/urt-*, weedeater.math.yale.edu:pub/urt-*, and freebie.engin.umich.edu:pub/urt-*. Xim, The X Image Manipulator, by Philip Thompson, does essential interactive displaying, editing, filtering, and converting of images. There is a version in the X11R4 contrib area; but a more recent version (using R4 and Motif 1.1) is available from gis.mit.edu (18.80.1.118). Xim reads/writes gif, xwd, xbm, tiff, rle, xim, (writes level 2 eps) and other formats and also has a library and command-line utilities for building your own applications. ImageMagick by cristy@dupont.com is an X11 package for display and interactive manipulation of images. Includes tools for image conversion, annotation, compositing, animation, and creating montages. ImageMagick can read and write many of the more popular image formats (JPEG, TIFF, PNM, Postscript, ...). Available via FTP from ftp.x.org as contrib/ImageMagick2.3.6.tar.Z. [1/94] xtiff is a tool for viewing a TIFF file in an X window. It was written to handle as many different kinds of TIFF files as possible while remaining simple, portable and efficient. xtiff illustrates some common problems with building pixmaps and using different visual classes. It is distributed as part of Sam Leffler's libtiff package and it is also available on ftp.x.org and comp.sources.x. [dbs@decwrl.dec.com,10/90] xtiff 2.0 was announced in 4/91; it includes Xlib and Xt versions. A version of Lee Iverson's (leei@McRCIM.McGill.EDU) image-viewing tool is available as contrib/vimage-0.9.3.tar.Z on ftp.x.org. The package also includes an ImageViewPort widget and a FileDialog widget. [12/91;5/92] The Andrew User Interface System (version 5.2 and later) provides an image inset which can view many image formats. Like all Andrew insets, an image can be incorporated in a a document or sent in email via the MIME standard. The following formats can be read: Sunraster, GIF, Xbitmap, TIFF, Xpixmap, JPEG, PBM, XWD. The LUG (Libreria de Utilidades Graficas) is a library of subroutines offering several routines for the manipulation of images in several different formats. The distribution includes viewers for several different platforms. The distribution is on telva.ccu.uniovi.es (156.35.31.31): /uniovi/mathdept/src/liblug-1.0.1.tar.gz. The X Image Extension (XIE), an X Consortium standard in R6, provides facilities for transmitting displaying fax (G3, G4), TIFF, and JPEG images. [some material from Larry Carroll (larryc@poe.jpl.nasa.gov), 5/91] ---------------------------------------------------------------------- Subject: 25) Where can I get an X-based 3-D object viewer? xmgf by Paul Hoad (P.Hoad@ee.surrey.ac.uk) is an interactive tool for viewing 2D and 3D objects typically in gf/OFF/NFF/IGRIP/MINICAD/SLA/DXF format Sources are on ftp.x.org. Version 1.9.1 became available 12/93. x3d is a V.Fast 3D Object viewer for X it needs no special hardware or or widget libraries other that X and is optimized for speed. XGobi can be used to to view such data. VOGLE can be used to to view such data. ---------------------------------------------------------------------- Subject: 26) How can I change the titlebar of my xterm window? The solution involves sending an escape sequence to xterm which will cause it to update the property which the window manager relies upon for the string which appears in the window titlebar. A solution is as easy as typing this in an xterm running a shell: echo "ESC]2;TEXT^G" where ESC is the escape key, TEXT is the string you wish to have displayed, and ^G is a Control-G (the BEL character). Note that the semi-colon is demanded by more recent versions of xterm. (Some shells and editors need an escape character, typically ^V, before accepting control characters literally.) Here is a more complicated csh alias which changes the titlebar to the current working directory when you change directories: alias newcd 'cd \!*; echo -n ESC]2\;$cwd^G' (for other shells e.g. ksh you will need to write a function for cd to print this value). The digit '2' in these strings indicates to xterm that it should change only the title of the window; to change both the title and the name used in the icon, use the digit '0' instead, and use '1' to change only the icon name. Note: another way to do this, which prevents an incorrect display of the local directory if a modified `cd` is used in a subshell, is to wrap the escape sequences into the PS1 prompt itself. ---------------------------------------------------------------------- Subject: 27)! Where can I find the xterm control sequences? The best source of such information is in your R5/R6 sources in the file ctlseqs.ms (R6: xc/doc/specs/xterm/ctlseqs.ms); a PostScript version is in your R5 sources in mit/hardcopy/clients/ctlseqs.PS.Z and your R6 sources in xc/doc/hardcopy/xterm/ctlseqs.PS.Z. O'Reilly's Volume 3, the X User's Guide, both editions include an R5 version of the control sequences. Other good sources of information include the R4 version of that document and also the file in the R4 sources called mit/clients/xterm/ctlseq2.txt, a compilation put together by Skip Montanaro (GE CR&D) listing the VT100 sequences. It dates from R3 but is fairly accurate. A hardcopy version was published in the December 1989 XNextEvent (the XUG newsletter). In a pinch, a VT100 manual will do. [last updated 10/91] ---------------------------------------------------------------------- Subject: 28)! How can I use characters above ASCII 127 in xterm ? In order to use special characters such as the o-umlaut, you need to "stty pass8" (you may need "stty -parenb -istrip cs8" on strictly-POSIX systems) but also to use a charcell ISO8859 font, such as XTerm*font: -*-*-medium-r-normal-*-*-130-*-*-c-*-iso8859-1 XTerm*boldfont: -*-*-bold-r-normal-*-*-130-*-*-c-*-iso8859-1 [The family is intentionally unspecified in this example.] In addition, you may want to set this in your shell: setenv LC_CTYPE iso_8859_1 For a given character above 127, you can determine the key to use with the Alt modifier by finding the equivalent character below 127 (try using `man ascii`). For example, o-umlaut (v) is Alt-v and the section character (') is Alt-'. [thanks to Greg Holmberg (greg%thirdi@uunet.uu.net) and Stephen Gildea (gildea@x.org); 6/92] ---------------------------------------------------------------------- Subject: 29) Why are my xterm menus so small (sic) ? You are probably setting the geometry small accidentally. If you give a resource specification like this: xterm*geometry: 80x24 then you are asking for all widgets under xterm to have their geometry set to 80x24. For the main window, this is OK, as it uses characters for its size. But its popup menus don't; they are in pixels and show up small. To set only the terminal widget to have the specified geometry, name it explicitly: xterm*VT100.geometry: 80x24 ---------------------------------------------------------------------- Subject: 30) How can I print the current X selection? You could paste it into an xterm after executing the lpr command. However, a program by Richard Hesketh (rlh2@ukc.ac.uk) specifically for manipulating the selection will help; e.g. % xselection PRIMARY | lpr finds the primary selection and prints it. This command can be placed in a window-manager menu or in shell-scripts. xselection also permits the setting of the selection and other properties. A version is on ftp.x.org. Also available is ria.ccs.uwo.ca:pub/xget_selection.tar.Z, which can be adapted to do this. ---------------------------------------------------------------------- Subject: 31)! How does Xt use environment variables in loading resources? You can use several environment variables to control how resources are loaded for your Xt-based programs -- XFILESEARCHPATH, XUSERFILESEARCHPATH, and XAPPLRESDIR. These environment variables control where Xt looks for application-defaults files as an application is initializing. Xt loads at most one app-defaults file from the path defined in XFILESEARCHPATH and another from the path defined in XUSERFILESEARCHPATH. XAPPLRESDIR existed in R3 and before. As of R4, the Xt developers added the more sophisticated *SEARCHPATH mechanism, but left XAPPLRESDIR in place to avoid breaking existing software. Set XFILESEARCHPATH if software is installed on your system in such a way that app-defaults files appear in several different directory hierarchies. Suppose, for example, that you are running Sun's Open Windows, and you also have some R4 X applications installed in /usr/lib/X11/app-defaults. You could set a value like this for XFILESEARCHPATH, and it would cause Xt to look up app-defaults files in both /usr/lib/X11 and /usr/openwin/lib (or wherever your OPENWINHOME is located): setenv XFILESEARCHPATH /usr/lib/X11/%T/%N:$OPENWINHOME/lib/%T/%N The value of this environment variable is a colon-separated list of pathnames. The pathnames contain replacement characters as follows (see XtResolvePathname()): %N The value of the filename parameter, or the application's class name. %T The value of the file "type". In this case, the literal string "app-defaults" %C customization resource (R5/R6 only) %D site default value for XFILESEARCHPATH (R6 only) %S Suffix. None for app-defaults. %L Language, locale, and codeset (e.g. "ja_JP.EUC") %l Language part of %L (e.g. "ja") %t The territory part of the display's language string %c The codeset part of the display's language string Let's take apart the example. Suppose the application's class name is "Myterm". Also, suppose Open Windows is installed in /usr/openwin. (Notice the example omits locale-specific lookup.) /usr/lib/X11/%T/%N means /usr/lib/X11/app-defaults/Myterm $OPENWINHOME/lib/%T/%N means /usr/openwin/lib/app-defaults/Myterm As the application initializes, Xt tries to open both of the above app-defaults files, in the order shown. As soon as it finds one, it reads it and uses it, and stops looking for others. The effect of this path is to search first in /usr/lib/X11, then in /usr/openwin. Let's consider another example. This time, let's set XUSERFILESEARCHPATH so it looks for the file Myterm.ad in the current working directory, then for Myterm in the directory ~/app-defaults. setenv XUSERFILESEARCHPATH ./%N.ad:$HOME/app-defaults/%N The first path in the list expands to ./Myterm.ad. The second expands to $HOME/app-defaults/Myterm. This is a convenient setting for debugging because it follows the Imake convention of naming the app-defaults file Myterm.ad in the application's source directory, so you can run the application from the directory in which you are working and still have the resources loaded properly. NOTE: when looking for app-default files with XUSERFILESEARCHPATH, for some bizarre reason, neither the type nor file suffix is defined so %T and %S are useless. With R5 and R6, there's another twist. You may specify a customization resource value. For example, you might run the "myterm" application like this: myterm -xrm "*customization: -color" If one of your pathname specifications had the value "/usr/lib/X11/%T/%N%C" then the expanded pathname would be "/usr/lib/X11/app-defaults/Myterm-color" because the %C substitution character takes on the value of the customization resource. The default XFILESEARCHPATH, compiled into Xt, is: /usr/lib/X11/%L/%T/%N%C:\ (R5) /usr/lib/X11/%l/%T/%N%C:\ (R5) /usr/lib/X11/%T/%N%C:\ (R5) /usr/lib/X11/%L/%T/%N:\ /usr/lib/X11/%l/%T/%N:\ /usr/lib/X11/%T/%N (Note: some sites replace /usr/lib/X11 with a ProjectRoot in this batch of default settings.) The default XUSERFILESEARCHPATH, also compiled into Xt, is /%L/%N%C:\ (R5) /%l/%N%C:\ (R5) /%N%C:\ (R5) /%L/%N:\ /%l/%N:\ /%N: is either the value of XAPPLRESDIR or the user's home directory if XAPPLRESDIR is not set. If you set XUSERFILESEARCHPATH to some value other than the default, Xt ignores XAPPLRESDIR altogether. Notice that the quick and dirty way of making your application find your app-defaults file in your current working directory is to set XAPPLRESDIR to ".", a single dot. In R3, all this machinery worked differently; for R3 compatibilty, many people set their XAPPLRESDIR value to "./", a dot followed by a slash. [Thanks to Oliver Jones (oj@world.std.com); 2/93.] ---------------------------------------------------------------------- Subject: 32)! How to I have xdm put a picture behind the log-in window? R5/R6 users can specify the "setup" script that xdm runs by changing the entry in the xdm-config file (usually in /usr/lib/X11/xdm) to name a different script; the sample script distributed with the X distribution simply runs xconsole. See the SETUP PROGRAM section of the xdm man page in R6 for precise details. Pre-R5 versions of the xdm client could be spoofed by in changing xdm's xrdb resource in the xdm-config file to run a program to change the background before loading the resources; for example, your /usr/lib/X11/xdm/xdm-config file may add the line DisplayManager.0.authorize: false to permit unrestricted access to the display before log-in (beware!) and also DisplayManager*xrdb: /usr/lib/X11/xdm/new.xrdb where that file does something (for all connections) along the lines of: #!/bin/sh #comes in with arguments: -display :0 -load /usr/lib/X11/xdm/Xresources /usr/bin/X11/xsetroot -display $2 -bitmap /usr/lib/X11/xdm/new.bitmap /usr/bin/X11/xrdb $* Substitute xloadimage or xv for xsetroot, to taste. Note that this is a general hack that can be used to invoke a console window or any other client. [Thanks to Jay Bourland (jayb@cauchy.stanford.edu), 9/91] ---------------------------------------------------------------------- Subject: 33) Why isn't my PATH set when xdm runs my .xsession file? When xdm runs your .xsession it doesn't source your .cshrc or .login files. You can set the path explicitly as you normally could for any SH script; or you can place all environment-setting statements in a separate file and source it from both the .xsession file and your shell configuration file; or, if you set your PATH in your .cshrc file, the normal place, you can make your .xsession have PATH set simply by making it a csh script, i.e. by starting your .xsession file off with "#!/bin/csh". If this doesn't work, also try starting off with: #!/bin/sh # Reset path: PATH=`csh -c 'echo $PATH'` ; export PATH ---------------------------------------------------------------------- Subject: 34)! How do I keep my $DISPLAY when I rlogin to another machine? There are several ways to avoid having to do a "setenv DISPLAY ..." whenever you log in to another networked UNIX machine running X. A trivial solution, if your account is cross-mounted on both machines, is to have your .xsession write your DISPLAY variable to a file, and then in your login dot-files to check for the existence of that that file and use its contents as your DISPLAY. [Thanks to joachim.fricker@zh014.ubs.ubs.ch.] One solution is to use the clients/xrsh on the R5 contrib tape. It includes xrsh, a script to start an X application on remote machine, and xrlogin, a script to start a local xterm running rlogin to a remote machine. A more recent version is on export in xrsh-5.4.shar. One solution is to use the xrlogin program from der Mouse (mouse@larry.mcrcim.mcgill.edu). You can ftp caveat-emptor versions from 132.206.1.1, in X/xrlogin.c and X/xrlogind.c. The program packages up $TERM and $DISPLAY into a single string, which is stuffed into $TERM. rlogin then propagates $TERM normally; your .cshrc on the remote machine should contain eval `xrlogind` where xrlogind is a program that checks $TERM and if it is of the special format it recognizes, unpacks it and spits out setenv and unsetenv commands to recreate the environment variables. [11/90] In addition, if all you need to do is start a remote X process on another host, and you find rsh -n /usr/bin/X11/xterm -display $DISPLAY too simple (DISPLAY must have your real hostname), then this version of xrsh can be used to start up remote X processes. The equivalent usage would be xrsh xterm #! /bin/sh # start an X11 process on another host # Date: 8 Dec 88 06:29:34 GMT # From: Chris Torek # rsh $host -n "setenv DISPLAY $DISPLAY; exec $@ &/dev/null" # # An improved version: # rXcmd (suggested by John Robinson, jr@bbn.com) # (generalized for sh,ksh by Keith Boyer, keith@cis.ohio-state.edu) # # but they put the rcmd in ()'s which left zombies again. This # script combines the best of both. case $# in [01]) echo "Usage: $0 host x-cmd [args...]";; *) case $SHELL in *csh*) host="$1"; shift xhost "$host" > /dev/null rsh "$host" -n \ "setenv TERM xterm; setenv DISPLAY `hostname`:0; \ exec $* & /dev/null" & ;; *sh) host="$1"; shift xhost "$host" > /dev/null rsh "$host" -n \ "TERM=xterm export TERM; \ DISPLAY=`hostname`:0 export DISPLAY; \ LD_LIBRARY_PATH=/usr/X11/lib export LD_LIBRARY_PATH; \ PATH=\$PATH:/usr/X11/bin:/usr/bin/X11:/usr/local/bin; \ export PATH; \ exec $* < /dev/null > /dev/null 2>&1" & ;; esac ;; esac You may also want to look at programs/rstart in the R6 distribution; this remote execution protocol is intended to work in concert with session managers. ---------------------------------------------------------------------- Subject: 35) How can I design my own font? One way is to use the "bitmap" client or some other bitmap-editor (e.g. Sun's icon-editor tool, post-processed with pbmplus) to design the individual characters and then to do some large amount of post-processing to concatenate them into the BDF format. See Ollie Jones's article in the November 91 X Journal for more information. The R3 contrib/ area (in fonts/utils/ and in clients/xtroff) contained a number of useful utilities, including some to convert between BDF font format and a simple character format which can be edited with any text editor. An easier way is to use the "xfed" client to modify an existing font; a version is on the R4 or R5 X11R5 contrib tape in contrib/clients/xfed. Xfed was last seen on ftp.Informatik.Uni-Dortmund.DE [129.217.64.63], possibly as file /pub/windows/X/Diverse-X11-Sourcen/xfed.tar.Z. It can produce BDF-format fonts which can be compiled for a variety of X servers. The xfedor client from Group Bull permits creation of bitmaps, cursors, XPM1 pixmaps, and fonts. Binaries for common machines are on avahi.inria.fr in /pub; in addition, the sources (an old Xlib implementation) have been placed [5/91] in ftp.x.org:/contrib. If you are a MetaFont user you can use "mftobdf" from the SeeTeX distribution to convert PK, GF, and PXL fonts to BDF format; the distribution is on ftp.cs.colorado.edu and on ftp.x.org. The GNU package fontutils-0.4.tar.Z on prep.ai.mit.edu includes xbfe, a font editor, and a number of utilities for massaging font formats. The O'Reilly X Resource issue #2 contains an article on using these tools to modify a font. Fonts can be resized with Hiroto Kagotani's bdfresize; a new version is in ftp.cs.titech.ac.jp:/X11/contrib. bdffont in the Andrew User Interface System (versions 5.2.2 and higher) lets you create a font or edit an existing one. ---------------------------------------------------------------------- Subject: 36)! Why does adding a font to the server not work (sic)? After you have built the font using your system's font-compiler, installed it in some directory, and run `mkfontdir` or your system's equivalent (e.g. bldfamily for OpenWindows) in that directory, be sure to use `xset +fp $dir` to add that full path-name to the server's font-path, *or* if the directory is already in the path, use `xset fp rehash` so that the new fonts in that directory are actually found; it is this last step that you're probably leaving out. (You can also use `xset q` to make sure that that directory is in the path.) Sometimes your "xset +fp $dir" command fails with a BadValue error: X Error of failed request:BadValue (integer parameter out of range for operation) Major opcode of failed request: 51 (X_SetFontPath) This means the X server cannot find or read your font directory, or that your directory does not look like a font directory to the server. (The mention of an "integer parameter" in the message is spurious.) -- Is the font directory you're specifying readable from the SERVER's file system? Remember, it's the server, not the client, which interprets your font directory. Trouble in this area is especially likely when you issue an xset command with shell metacharacters in it (e.g. "xset +fp ~/myfonts") and the server is an X terminal or managed by xdm. -- Is the directory really a font directory? If you're running the sample X server (or most varieties of vendor servers) look in the directory for the file "fonts.dir". If you can't find that file, run mkfontdir(1). (If you're running OpenWindows, look for the file "Families.list". If you can't find it, run bldfamily(1).) -- If you're in a site where some people run X11Rn servers and others run a proprietary server with nonstandard font formats (OpenWindows, for example), make sure the font directory is right for the server you're using. Hint: if the directory contains .pcf and/or .snf files, it won't work for Open Windows. If the directory contains .ff and/or .fb files, it won't work for X11Rn. [thanks to der Mouse (mouse@larry.mcrcim.mcgill.edu) and to Oliver Jones (oj@pictel.com); 7/92 ] Note: some systems (e.g. X11R4 on AIX) need a trailing '/' in the directory name. ---------------------------------------------------------------------- Subject: 37) How do I convert a ".snf" font back to ".bdf" font? A tool called "snftobdf 1.6" can do this; it is available as: ftp.x.org:contrib/snftobdf-1.6.tar.Z crl.nmsu.edu:pub/misc/snftobdf-1.6.tar.Z ---------------------------------------------------------------------- Subject: 38)! What is a general method of getting a font in usable format? der Mouse's getbdf is one solution; it connects to a server and produces a .BDF file for any font the server is willing to let it. It can be used as an anything-to-BDF converter, but requires access to a server that can understand the font file, thus is both more and less powerful than other tools such as snftobdf. getbdf is on 132.206.1.1 in X/getbdf.c or available via mail from mouse@larry.McRCIM.McGill.EDU. [5/91] In addition, the R5/R6 program "fstobdf" can produce bdf for any font that the R5 server has access to. ---------------------------------------------------------------------- Subject: 39) How do I use DECwindows fonts on my non-DECwindows server? The DECwindows fonts typically don't exist on a non-DEC installation, but rewrite rules can be used to alias fonts used by DECwindows applications to standard X fonts of similar characteristics and size. Pick up the file contrib/DECwindows_on_X11R4_font.aliases from ftp.x.org; this file is for a sample R4 server. It can also serve as a starting point for creating a similar aliases file for the Open Windows server or other servers which do not use the X Consortium's font scheme. ---------------------------------------------------------------------- Subject: 40)+ How do I get a font name from the structure? You can't, although you can build up the font properties to rebuild a description of the font in XLFD format, which should be sufficient. This routine is derived from source provided by John L. Cwikla (cwikla@wri.com). #include #include /* Stolen from mit/fonts/lib/font/bitmap/bitscale.c */ enum scaleType { atom, pixel_size, point_size, resolution, resolution_x, resolution_y, average_width, scaledX, scaledY, unscaled, scaledXoverY, uncomputed, }; typedef struct _fontProp { char *name; Atom atom; enum scaleType type; char found; } fontProp; static fontProp fontNamePropTable[] = { { "FOUNDRY", 0, atom, 0}, { "FAMILY_NAME", 0, atom, 0}, { "WEIGHT_NAME", 0, atom, 0}, { "SLANT", 0, atom, 0}, { "SETWIDTH_NAME", 0, atom, 0}, { "ADD_STYLE_NAME", 0, atom, 0}, { "PIXEL_SIZE", 0, pixel_size, 0}, { "POINT_SIZE", 0, point_size, 0}, { "RESOLUTION_X", 0, resolution_x, 0}, { "RESOLUTION_Y", 0, resolution_y, 0}, { "SPACING", 0, atom, 0}, { "AVERAGE_WIDTH", 0, average_width, 0}, { "CHARSET_REGISTRY", 0, atom, 0}, { "CHARSET_ENCODING", 0, atom, 0}, #if 0 { "FONT", 0, atom, 0}, #endif /* 0 */ }; #define NUMITEMS(arr) ((int) (sizeof(arr) / sizeof(arr[0]))) void regenerateFontName(Display *display, XFontStruct *xfs) { int i; unsigned long retValue; if (xfs) { for(i=0;ia: beginning-of-line() \n\ Ctrle: end-of-line() ^ extra space The newline after that space is ending the translation definition. [Thanks to Timothy J. Horton, 5/91] ---------------------------------------------------------------------- Subject: 43) How can I have a clock show different timezones? One solution is xchron, in Volume 6 of comp.sources.x, which can show the time for timezones other than the local one. sunclock on ftp.x.org displays a world map with sun/dark areas and local and UTC time. The OpenWindows clock has a TimeZone property. Modifications to the Xaw clock widget to support hour and minute offsets were posted by David Herron (david@twg.com). A patch for the clock coming with the Xaw3D widgets introduces resources hourOffset, minuteOffset, gmt; it can be found at ftp.wu-wien.ac.at:pub/src/X11/wafe/xaw3d.Clock.patch. Alternatively, you can probably set the timezone in the shell from which you invoke the xclock or oclock, or use a script similar to this: #!/bin/sh TZ=PST8PDT xclock -name "Palmy" 2> /dev/null & TZ=EST5EDT xclock -name "Balmy" 2> /dev/null & ---------------------------------------------------------------------- Subject: 44) I have xmh, but it doesn't work. Where can I get MH? The xmh mail-reader requires the Rand MH mail/message handling system, which is not part of the UNIX software distribution for many machines. A list of various ftp, uucp, e-mail and US-mail sites for both xmh and MH is given in the monthly MH FAQ; one source is ics.uci.edu. ---------------------------------------------------------------------- Subject: 45) Why am I suddenly unable to connect to my Sun X server? After a seemingly random amount of time after the X server has been started, no other clients are able to connect to it. The default cron cleanup jobs supplied by Sun (for 4.0.3, at least) delete "old" (unreferenced) files from /tmp -- including /tmp/.X11-unix, which contains the socket descriptor used by X. The solution is to add "! -type s" to the find exclusion in the cron job. [10/90] ---------------------------------------------------------------------- Subject: 46) Why don't the R5 PEX demos work on my mono screen? The R5 sample server implementation works only on color screens, sorry. ---------------------------------------------------------------------- Subject: 47)! How do I get my Sun Type-[45] keyboard fully supported by Xsun? The R6 Xsun supports Sun Type-[45] keyboards; see the KEYBOARDS section of the Xsun man page. Many users wants the Num Lock key to light the Num Lock LED and have the appropriate effect on the numeric keypad. The R5 Xsun server as distributed by the Consortium doesn't do this but there are two different patches available. The first patch is written by Jonathan Lemon and fixes the Num Lock related problems. It is available from ftp.x.org in the file contrib/Xsun-R5.numlock_patch.Z . The second is written by Martin Forssen and fixes the Num Lock and Compose keys and adds support for the different national keyboard layouts for Type-4 and Type-5 keyboards. This patch is available from ftp.x.org in contrib/sunkbd.930314.tar.Z or via email from maf@dtek.chalmers.se. [thanks to Martin Forssen (maf@dtek.chalmers.se or maf@math.chalmers.se), 8/92] A set of patches by William Bailey (dbgwab@arco.com) was posted to newsgroups 11/92 to provide support for the Type-5 keyboard. (Note that use of xmodmap to map function and arrow keys can make the Type 5 keyboard more useful without needing these patches.) ---------------------------------------------------------------------- Subject: 48) How do I report bugs in X? Generally, report bugs you find to the organization that supplied you with the X Window System. If you received the R6 source distribution directly from the Consortium, please read the file xc/bug-report for instructions. [Look in mit/bug-report for R5, mit/doc/bugs/bug-report in R4.] [Thanks to Stephen Gildea , 5/91; 12/91] ---------------------------------------------------------------------- Subject: 49) Why do I get "Warning: Widget class version mismatch"? This error, which typically goes on to say, "widget 11004 vs. intrinsics 11003" indicates that the header files you included when building your program didn't match the header files that the Xt library you're linking against was built with; check your -I include path and -L link-path to be sure. However, the problem also occurs when linking against a version of the X11R4 Xt library before patch 10; the version number was wrong. Some Sun OW systems, in particular, were shipped with the flawed version of the library, and applications which link against the library typically give the warnings you have seen. ---------------------------------------------------------------------- Subject: 50)! Why does my SPARC say "Mapping cg3c: No such device or address"? The R6 sun ddx uses information returned by the device driver to do the right thing, so this problem should go away with R6, but the X Consortium does not have this configuration available to test it. This problem comes up on Sun SPARC Classic machines. There is no X Consortium fix for this problem, but the correction can be made to X11R5 sources by editing the file "src/mit/server/ddx/sun/sunCG3C.c". Find the second buffer definition that looks like this: typedef struct cg3bc { #ifdef sparc u_char mpixel[128*1024]; /* bit-per-pixel memory */ u_char epixel[128*1024]; /* enable plane */ #endif u_char cpixel[CG3B_HEIGHT][CG3B_WIDTH]; /* byte-per-pixel memory */ } CG3BC, CG3BCRec, *CG3BCPtr; and change the instances of "128*1024" to "96*1024". Then recompile the X server. [thanks to Russ Poffenberger (poffen@San-Jose.ate.slb.com)] ---------------------------------------------------------------------- Subject: 51) Where can I find a dictionary server for xwebster? Webster's still owns the copyright to the on-line copies of Webster's Dictionary which are found at various (university) sites. After it became aware that these sites were then acting as servers for other sites running xwebster and gnuemacs-webster, it asked that server sites close off external access. [The NeXT machine apparently is also licensed to have the dictionary. A Webster daemon for NeXT machines is available from iuvax.cs.indiana.edu (129.79.254.192) in "pub/webster/NeXT-2.0".] Unless you want to get a legal on-line copy yourself or can find a site which can grant you access, you are probably out of luck. However, if you are a legitimate site, you'll want to pick up the latest xwebster, as-is on ftp.x.org:contrib/xwebster.tar.Z [10/91]; the file xwebster.README includes discussions of the availability, illegality, and non-availability of dictionary servers. [courtesy steve@UMIACS.UMD.EDU (Steve Miller) and mayer@hplabs.hp.com (Niels Mayer) 11/90] ---------------------------------------------------------------------- Subject: 52) TOPIC: OBTAINING X AND RELATED SOFTWARE AND HARDWARE ---------------------------------------------------------------------- Subject: 53) Is X public-domain software? No. The X software is copyrighted by various institutions and is not "public domain", which has a specific legal meaning. However, the X distribution is available for free and can be redistributed without fee. Contributed software, though, may be placed in the public domain by individual authors. ---------------------------------------------------------------------- Subject: 54)! How compatible are X11R3, R4, R5, R6? What changes are there? The Release Notes for each release of X11 specify the changes from the previous release. The X Consortium tries very hard to maintain compatibility across releases. In the few places where incompatible changes were necessary, details are given in the Release Notes. Each X11 distribution site on the network also offers the Release Notes that go with the release they offer; the file typically can be found at the top of the distribution tree. [Stephen Gildea, 1/92] Things that are incompatible in R6: - R6 Xt requires R6 Xlib. - R6 Xaw no longer has Clock, Logo, and Mailbox widgets. - Imakefiles that used the symbol "SharedLibX" (like XPM) need to use "SharedLibX11" in R6. - R6 Xt retains binary compatibility with R5 for all data structures except WMShellPart. See section 13.4 of the Xt specification for more details. [Dave Wiggins (dpw@x.org)] The comp.windows.x.intrinsics FAQ-Xt lists Xt differences among these versions. ---------------------------------------------------------------------- Subject: 55)! When is X11R6 available? The tentative schedule (5/94) is: Public Release: May 2, 1994 Contrib contribution deadline: 11:59PM June 6, 1994 Contrib release: June 20, 1994 ---------------------------------------------------------------------- Subject: 56)! What is Fresco? When is Fresco rumored to be available? Fresco is a user-interface system specified in CORBA IDL. The sample implementation from the X Consortium is implemented in C++. Fresco should be available with X11R6, as a work-in-progress. It draws several design ideas from InterViews and will ultimately incorporate much of the functionality of Xt and Xlib, and add some significant new capabilities in the areas of structured graphics, device and resolution independent drawing models, a standard object model (OMG CORBA) and interface definition language (CORBA IDL), and application linking and embedding. There is a writeup on Fresco in the Proceedings of the 7th Annual X Technical Conference, published in Issue 5 of the X Resource, O'Reilly and Associates, ISBN 1-56592-020-1. [Information from Kaleb Keithley (kaleb@x.org) and Matt Landau (matt@x.org); 1/94; 4/94.] ---------------------------------------------------------------------- Subject: 57)+ Where can I get X11R6 (source and/or binaries)? Release 6 was made available to the public on May 2. As in the past, the Consortium encourages everyone to port their software to R6 within the first month that R6 is out, and contribute the software back for inclusion in a "final" R6 distribution. The X Consortium is making R6 available simultaneously on multiple ftp sites around the world; the Consortium is also offering R6 on CD-ROM, QIC-150 tape, and 8mm tape (tar format) and is distributing hardcopy documentation. Information: X Consortium, R6 Sales Center, 1 Memorial Drive, Cambridge, MA 02142-1301, USA. You will need about 140Mb of disk space to hold all of the Core distribution. PLEASE use a site that is close to you in the network. North America anonymous FTP: Location Address Directory -------- ------- --------- Cambridge, MA ftp.crl.research.digital.com Digital Equipment Corp. [192.58.206.2] /pub/X11/R6 Cambridge Research Laboratory /pub/X11/contrib Lowell, MA x11r6.uml.edu /pub/R6 UMass-Lowell [129.63.32.4] /contrib New York City, NY ftp.cs.columbia.edu /archives/X11R6/R6 Columbia University [128.59.26.5] /archives/X11R6/contrib Computer Science Dept Buffalo New York ftp.acsu.buffalo.edu /pub/R6 University at Buffalo [128.205.7.9] /pub/R6 Washington DC ftp.digex.net /pub/X11/R6 Digital Express Group, Inc. [128.219.128.109] /pub/X11/contrib Aberdeen Maryland ftp.arl.mil /pub/X11/R6 Army Research Laboratory [138.18.1.158] /pub/X11/contrib Falls Church, VA ftp.uu.net /systems/window-sys/X/R6 UUNET Technologies, Inc [192.48.96.9] /systems/window-sys/X/contrib Durham, NC ftp.duke.edu /pub/X11R6 Duke University [152.3.102.3] Oak Ridge, Tenn sws1.ctd.ornl.gov /unix/X11R6 Oak Ridge National Lab [128.219.128.109] /unix/X11R6/contrib Ann Arbor, MI ftp.merit.edu /X11R6 Merit Network, Inc. [35.1.1.48] /X11R6/contrib West Lafayette, Indiana ftp.cs.purdue.edu /pub/X11/R6 Purdue University [128.10.2.1] /pub/X11/R6 Dept of Computer Sciences Columbus, Ohio ftp.cis.ohio-state.edu /pub/X.V11R6/R6 The Ohio State University [128.146.8.52] /pub/X.V11R6/R6-contrib Dept of Computer and Information Science Albuquerque New Mexico ftp.eece.unm.edu /usr/ftp/pub/dist/X/X11R6 Electrical and [129.24.24.119] /usr/ftp/pub/dist/X/X11 Computer Engineering UNM Palo Alto, California gatekeeper.dec.com pub/X11/R6 Digital Equipment Corp [16.1.0.2] pub/X11/contrib Europe anonymous FTP: Vienna, Austria ftp.Austria.EU.net /pub/x11/x11r6 EUnet Austria [192.92.138.34] /pub/x11/x11r6/contrib Leuven, Belgium ftp.eunet.be /pub/R6 EUnet Belgium [192.92.130.1] /contrib Zagreb, Croatia ftp.zel.etf.hr /pub/X11/R6 Faculty of Electrical [161.53.65.13] /pub/X11/contrib Engineering, Dept of Electronics Prague, Czech Republic ftp.eunet.cz /pub/x11/R6 EUnet Czechia [193.85.1.11] /pub/x11/R6/contrib Copenhagen, Denmark ftp.denet.dk /pub/X11/X11R6 DENet [129.142.6.74] /pub/X11/contrib Copenhagen, Denmark osiris.dknet.dk /pub/X11/R6 DKnet / EUnet Denmark [193.88.44.45] /pub/X11/contrib Helsinki, Finland ftp.eunet.fi /X11R6/release EUnet Finland [192.26.119.1] /X11R6/contrib France (near Paris) ftp.inria.fr /X/X11R6 INRIA Rocquencourt [192.93.2.54] /X/xontrib Paris, France ftp.ibp.fr /pub/X11/R6 Institut Blaise Pascal [132.227.60.2] /pub/X11/contrib Dortmund, Germany ftp.germany.eu.net /pub/X11/XConsortium/pub/R6 EUnet Deutschland GmbH [192.76.144.75] /pub/X11/XConsortium/contrib Paderborn, Germany ftp.uni-paderborn.de /pub/X11/R6 University of Paderborn [131.234.2.32] /pub/X11/contrib Budapest, Hungary sunserv.sztaki.hu /pub/X11R6 HUNGARNET [192.84.227.1] /pub/R6-contrib Dublin, Ireland ftp.ieunet.ie /pub/R6 IEunet [192.111.39.3] /pub/R6/contrib Milano, Italy ftp.dsi.unimi.it /pub/R6 DSI, U of Milan [149.132.2.45] /export Milano, Italy ftp.iunet.it /X11/X11R6 IUnet NOC [192.106.1.6] /X11/contrib Oslo, Norway ftp.eunet.no /pub/X11/R6 EUnet Norway [193.71.1.7] /pub/X11/contrib Norway ftp.unit.no /pub/X11/R6 U. of Trondheim/SINTEF [129.241.1.97] /pub/X11/contrib Warsaw, Poland ftp.icm.edu.pl /pub/X11/R6 ICM, Warsaw University [XXX.XXX.XXX.XXX] /pub/X11/contrib Lisbon, Portugal relay.puug.pt /pub/X11R6 PUUG [193.126.4.65] /pub/X11R6/contrib Portuguese UNIX Users Group Moscow, Russia ftp.kiae.su /x11/X11R6 RELCOM/EUnet, KIAE [144.206.136.10] /x11/X11R6/contrib Lulea, Sweden ftp.luth.se /pub/X11/R6 Lulea University of Technology[130.240.18.2] /pub/X11/contrib Zurich, Switzerland ftp.eunet.ch /archive/software/X11R6 EUnet Switzerland [146.228.10.16] /archive/software/X Zurich, Switzerland ftp.switch.ch /mirror/X11/R6 SWITCH - Swiss Academic & [130.59.1.40] /mirror/X11/contrib Research Network Amsterdam, The Netherlands ftp.EU.net /X11/R6 EUnet Europe [192.16.202.2] /X11/contrib Amsterdam, The Netherlands ftp.NL.net /pub/windows/X/R6 NLnet [193.78.240.13] /pub/windows/X/contrib Canterbury, Kent, UK ftp.britain.eu.net /pub/X11R6 EUnet GB [192.91.199.5] /pub/X11R6-contrib London, UK src.doc.ic.ac.uk /packages/X11R6 SUNsite, Dept of Computing, [146.169.2.10] /packages/X11-contrib Imperial College East Asia anonymous FTP: Hong Kong ftp.cs.cuhk.hk /pub/X11R6 Computer Science Dept [137.189.4.57] /pub/Xcontrib The Chinese University of Hong Kong Taejon, Republic of Korea cair.kaist.ac.kr /pub/X11/R6 Center for Artificial [143.248.11.170] /pub/X11/contrib (not yet operational) Inteligence Research, KAIST Tokyo, Japan ftp.iij.ad.jp /pub/X/X11R6 Internet Initiative Japan [192.244.176.50] /pub/X/contrib Fukuoka, Japan ftp.ec.kyushu-u.ac.jp /pub/X11R6 Kyushu University [133.5.10.12] /pub/contrib Tokyo, Japan SunSITE.sut.ac.jp /pub/archives/X11/R6 Science University of Tokyo [133.31.30.7] /pub/archives/X11/R6contrib Tokyo, Japan ftp.u-tokyo.ac.jp /pub/X11R6 The University of Tokyo [130.69.254.254] /pub/X11R6-contrib Fujisawa, Japan sh.wide.ad.jp /X11R6 WIDE Project (Fujisawa) [133.4.11.11] /X11R6-contrib Nara, Japan wnoc-nara-ss2.wide.ad.jp /pub/X11R6 WIDE Project (Nara) [133.4.23.2] /pub/X11R6-contrib Tokyo, Japan ftp.inter.spin.ad.jp /pub/unix/R6 Roppongi, Minato-ku [165.76.8.4] /pub/unix/R6/contrib Spin project Taiwan NCTUCCCA.edu.tw /X/X11R6 Campus Computer [140.111.1.10] /X/contrib Communication Assoc. Australia anonymous FTP: Location Address Directory -------- ------- --------- Melbourne, Australia archie.AU X11/R6 AARNet archive server [139.130.23.2] X11/contrib Melbourne, Australia munnari.OZ.AU X.V11/R6 University of Melbourne [128.250.22.2] X.V11/contrib This list will be added to as more information on source locations and binary kits becomes available. ---------------------------------------------------------------------- Subject: 58)! Where can I get X11R5 (source and/or binaries)? Information about the Consortium's distribution of the sources on 6250bpi and QIC-24 tape and its distribution of hardcopy of the documents is available from Software Center, Technology Licensing Office, Massachusetts Institute of Technology, 28 Carleton Street, Room E32-300, Cambridge MA 02142-1324, phone: 617-258-8330. You will need about 100Mb of disk space to hold all of Core and 140MB to hold the Contrib software donated by individuals and companies. PLEASE use a site that is close to you in the network. Note that the RELEASE notes are generally available separately in the same directory; the notes list changes from previous versions of X and offer a guide to the distribution. North America anonymous FTP: California gatekeeper.dec.com pub/X11/R5 16.1.0.2 California soda.berkeley.edu pub/X11R5 128.32.131.179 Indiana mordred.cs.purdue.edu pub/X11/R5 128.10.2.2 Maryland ftp.brl.mil pub/X11R5 128.63.16.158 (good for MILNET sites) Massachusetts crl.dec.com pub/X11/R5 192.58.206.2 Massachusetts ftp.x.org pub/R5 198.112.44.100 (crl.dec.com is better) Michigan merit.edu pub/X11R5 35.1.1.42 Missouri wuarchive.wustl.edu packages/X11R5 128.252.135.4 Montana ftp.cs.montana.edu pub/X.V11R5 192.31.215.202 New Mexico pprg.eece.unm.edu pub/dist/X11R5 129.24.24.10 New York azure.acsu.buffalo.edu pub/X11R5 128.205.7.6 North Carolina cs.duke.edu dist/sources/X11R5 128.109.140.1 Ohio ftp.cis.ohio-state.edu pub/X.V11R5 128.146.8.52 Ontario ftp.cs.utoronto.ca pub/X11R5 128.100.1.105 Washington DC x11r5-a.uu.net X/R5 192.48.96.12 Washington DC x11r5-b.uu.net X/R5 137.39.1.12 Europe/Middle East/Australia anonymous FTP: Australia munnari.oz.au X.V11/R5 128.250.1.21 Denmark freja.diku.dk pub/X11R5 129.142.96.1 United Kingdom src.doc.ic.ac.uk graphics/X.V11R5 146.169.3.7 hpb.mcc.ac.uk pub/X11r5 130.88.200.7 Finland nic.funet.fi pub/X11/R5 128.214.6.100 France nuri.inria.fr X/X11R5 128.93.1.26 Germany ftp.germany.eu.net pub/X11/X11R5 192.76.144.129 Israel cs.huji.ac.il pub/X11R5 132.65.6.5 Italy ghost.sm.dsi.unimi.it pub/X11R5 149.132.2.1 Netherlands archive.eu.net windows/X/R5 192.16.202.1 Norway ugle.unit.no pub/X11R5 129.241.1.97 Norway nac.no pub/X11R5 129.240.2.40 Switzerland nic.switch.ch software/X11R5 130.59.1.40 Japan anonymous FTP: Kanagawa sh.wide.ad.jp X11R5 133.4.11.11 Kwansai ftp.ics.osaka-u.ac.jp X11R5 133.1.12.30 Kyushu wnoc-fuk.wide.ad.jp X11R5 133.4.14.3 TISN utsun.s.u-tokyo.ac.jp X11R5 133.11.11.11 Tokyo kerr.iwanami.co.jp X11R5 133.235.128.1 Tokyo scslwide.sony.co.jp pub/X11R5 133.138.199.1 UUCP: uunet for UUNET customers ~/X/R5 decwrl existing neighbors only ~/pub/X11/R5 osu-cis ~/X.V11R5 (not online until ~ 9 Sept) utai existing neighbors only ~/ftp/pub/X11R5 hp4nl Netherlands only ~uucp/pub/windows/X/R5 NFS: Missouri wuarchive.wustl.edu /archive/packages/X11R5 128.252.135.4 mount point: /archive AFS: Pennsylvania /afs/grand.central.org/pub/X11R5 NIFTP (hhcp, cpf, fcp, ...): United Kingdom uk.ac.ic.doc.src 00000510200001 user "guest" anon FTAM: United Kingdom 000005102000 (Janet) X.V11R5 146.169.3.7 (Internet) 204334504108 (IXI) ACSNet: Australia munnari.oz (fetchfile) X.V11/R5 Please fetch only one file at a time, after checking that a copy is not available at a closer site. [9/2/91; updated for contrib 10/91] Anyone in Europe can get a copy of the X.V11R5 distribution, including the core and contributed software and all official patches, free of charge. The only requirement is to agree to return the tapes, or equivalent new tapes. Only QIC and TK format cartridges can be provided. Contact: Jamie Watson, Adasoft AG, Nesslerenweg 104, 3084 Wabern, Switzerland. Tel: +41 31 961.35.70 or +41 62 61.41.21; Fax: +41 62 61.41.30; jw@adasoft.ch. UK sites can obtain X11 through the UKUUG Software Distribution Service, from the Department of Computing, Imperial College, London, in several tape formats. You may also obtain the source via Janet (and therefore PSS) using Niftp (Host: uk.ac.ic.doc.src Name: guest Password: your_email_address). Queries should be directed to Lee McLoughlin, 071-589-5111#5037, or to info-server@doc.ic.ac.uk or ukuug-soft@uk.ac.ic.doc (send a Subject line of "wanted"). Also offered are copies of comp.sources.x, the ftp.x.org contrib and doc areas and most other announced freely distributable packages. Various users' groups (e.g. SUG) offer X sources cheaply, typically on CD-ROM. Source for the Andrew User Interface System 6.2 are available on ftp.andrew.cmu.edu in pub/AUIS and via tape from the Andrew Consortium, School of Computer Science, Carnegie Mellon University, 5000 Forbes Ave., Pittsburgh PA 15217. Information: info-andrew-requests@andrew.cmu.edu, 412-268-6710, fax 412-621-8081. Binaries for X11R5, with shared libX11 and libXmu, for A/UX 2.0.1 are now available from wuarchive.wustl.edu:/archive/systems/aux/X11R5. Patches for X11R5 compiled with gcc (but not shared libraries) are also available. [John L. Coolidge (coolidge@cs.uiuc.edu, 10/91)] A binary tree for the Next by Douglas Scott (doug@foxtrot.ccmrc.ucsb.edu) is on foxtrot.ccmrc.ucsb.edu; it is missing the server, though. Binaries for the Sun386i are in vernam.cs.uwm.edu:/sun386i. Binaries for the HP-PA are on hpcvaaz.cv.hp.com (15.255.72.15). Binaries for the HP-PA are on ftp.cae.wisc.edu. Binaries of X11R5.26 for Sun3/SunOS4.1.1 systems are on ftp.cad.gatech.edu as X11R5.pl26.slim.sun3.gcc258.tar.gz; the distribution includes also binaries of common X tools. Binaries of X11R5 for Solaris 2, packaged for installation with pkgadd, are in camus.quintus.com:/pub/X11R5. Source and binaries for HP-UX 8.*/9.0(S300/400/700/800) and Domain 10.4 (68K, DN 10K) are available through the Interworks Users Group; contact Carol Relph at 508-436-5046, fax 508-256-7169, or relph_c@apollo.hp.com. Patches to X11R5 for Solaris 2.1 by Casper H.S. Dik (casper@fwi.uva.nl) et al are on ftp.x.org in contrib/{R5.SunOS5.patch.tar.Z,R5.SunOS5.patch.README}. Patches to X11R5 for the Sun Type 5 keyboard and the keyboard NumLock are available from William Bailey (dbgwab@arco.com). X servers for color and monochrome NeXT machines is on foxtrot.ccmrc.ucsb.edu in /pub/X11R5-MouseX.tar.Z. Source patches are expected to be on orst and sonata as X11R5-source.patch.tar.Z. An X11R5 package for multi-lingual users is available (for SunOS 4.1.3 and Solaris 2.1 and later) on ftp.waseda.ac.jp (133.9.1.32) in ftp/pub3/X11R5/binaries/. ---------------------------------------------------------------------- Subject: 59)! Where can I get XDM's Wraphelp.c ? X11R5/R6 supports a DES-based form of authorization. There are several implementations of the file Wraphelp.c, which may be missing from your distribution; one is on ftp.psy.uq.oz.au:/pub/X11R5. ---------------------------------------------------------------------- Subject: 60)! Where can I get patches to X11R5? The release of new public patches by the X Consortium is announced in the comp.windows.x.announce newsgroup. Patches themselves are available via ftp from ftp.x.org and from other sites from which X11 is available. They are now also distributed through the newsgroup comp.sources.x. Some source re-sellers may be including patches in their source distributions of X11. People without ftp access can use the xstuff mail server. It now has 26 patches for X11R5 [11/93]. Send to xstuff@x.org the Subject line send fixes # where # is the name of the patch and is usually just the number of the patch. There will be no more patches to X11R5. Here are a few complications: 1) fix 5 is in four parts; you need to request "5a", "5b", "5c" and "5d" separately 2) the file sunGX.uu, which was part of an earlier patch, was re-released with patch 7 [note: the file doesn't work with Solaris] 3) fix 8 is in two parts: "8a" and "8b" 4) fix 13 is in three parts: "13a", "13b", and "13c" 5) fix 16 is in two parts: "16a" and "16b" 6) fix 18 replaces the R5fix-test1 for the X Test Suite, which previously was optional 7) fix 19 also needs PEXlib.tar.Z, which you can obtain from xstuff by asking for "PEXlib.uu.[1234]". 8) fix 22 is in 9 parts, "22a" through "22i" The MIT Software Center, in addition to offering the entire system on tape, is offering a new tape with public patches 1-23. Tapes are available in 6250bpi 9-track reel-to-reel and QIC-24 cartridge formats. Information: +1 617 258 8330 ---------------------------------------------------------------------- Subject: 61) What is the xstuff mail-archive? The xstuff server is a mail-response program. That means that you mail it a request, and it mails back the response. Any of the four possible commands must be the first word on a line. The xstuff server reads your entire message before it does anything, so you can have several different commands in a single message (unless you ask for help). The xstuff server treats the "Subject:" header line just like any other line of the message. The archives are organized into a series of directories and subdirectories. Each directory has an index, and each subdirectory has an index. The top-level index gives you an overview of what is in the subdirectories, and the index for each subdirectory tells you what is in it. 1) The command "help" or "send help" causes the server to send you a more detailed version of this help file. 2) if your message contains a line whose first word is "index", then the server will send you the top-level index of the contents of the archive. If there are other words on that line that match the name of subdirectories, then the indexes for those subdirectories are sent instead of the top-level index. For example, you can say "send index fixes" (or "index fixes"). A message that requests an index cannot request data. 3) if your message contains a line whose first word is "send", then the xstuff server will send you the item(s) named on the rest of the line. To name an item, you give its directory and its name. For example send fixes 1 4 8a 8b 9 You may issue multiple send requests. The xstuff server contains many safeguards to ensure that it is not monopolized by people asking for large amounts of data. The mailer is set up so that it will send no more than a fixed amount of data each day. If the work queue contains more requests than the day's quota, then the unsent files will not be processed until the next day. Whenever the mailer is run to send its day's quota, it sends the requests out shortest-first. 4) Some mailers produce mail headers that are unusable for extracting return addresses. If you use such a mailer, you won't get any response. If you happen to know an explicit path, you can include a line like path foo%bar.bitnet@mitvma.mit.edu or path bar!foo!frotz in the body of your message, and the daemon will use it. The xstuff server itself can be reached at xstuff@x.org. If your mailer deals in "!" notation, try sending to {someplace}!mit-eddie!x.org!xstuff. [based on information from the X Consortium, 8/89, 4/90.] ---------------------------------------------------------------------- Subject: 62)! Where can I get X11R4 (source and binaries)? Note: X11R4 is used by Motif 1.1 implementations. However, it is becoming increasingly difficult to find in electronic form. This list has been winnowed down as sites are found to have removed R4 sources. You may be able to find R4 sources on machines offering X11R5 sources. European sites can obtain a free X11R4 distribution from Jamie Watson, who may be reached at chx400!pan!jw or jw@pan.uu.ch. [10/90] X11R4 is ftp-able from ftp.x.org (/pub/R4); these sites are preferable, though, and are more direct: Machine Internet FTP Location Name Address Directory -------- ------- -------- ------------- (2) Central USA giza.cis.ohio-state.edu 128.146.8.61 pub/X.V11R4 Southeast USA uunet.uu.net 192.48.96.2 X/R4 (4) UK Janet src.doc.ic.ac.uk 129.31.81.36 X.V11R4 UK niftp uk.ac.ic.doc.src (5) Australia munnari.oz.au 128.250.1.21 X.V11/R4 The giza.cis.ohio-state.edu site, in particular, is known to have much of the contrib stuff that can be found on ftp.x.org. The release is available to DEC Easynet sites as CRL::"/pub/X11/R4". Sites in Australia may contact this address: ftp.Adelaide.EDU.AU [129.127.40.3] and check the directory pub/X/R4. The machine shadows ftp.x.org and archives comp.sources.x. (Mark Prior, mrp@ucs.adelaide.edu.au, 5/90) A set of X11R4 binaries built by Tom Roell (roell@informatik.tu-muenchen.de) for the 386/ix will available from ftp.x.org in /contrib and in /pub/i386/X11R4 from 131.159.8.35 in Europe. Stephen Hite (shite@sinkhole.unf.edu) can also distribute to folks without ftp facilities via disks sent SASE; contact him for USmail and shipping details. [12/90] In addition, the binaries are available via uucp from szebra [1-408-739-1520, TB+ (PEP); ogin:nuucp sword:nuucp] in /usr2/xbbs/bbs/x. In addition, the source is on zok in /usrX/i386.R4server/. [2/91] In addition, if you are in the US, the latest SVR4 binary (April 15), patches, and fonts are available on piggy.ucsb.edu (128.111.72.50) in the directory /pub/X386, same filenames as above. (Please use after 6pm Pacific, as these are large files.) [5/91] A set of HP 9000/800 binaries is available on hpcvaaz.cv.hp.com (15.255.72.15) as ~ftp/pub/MitX11R4/libs.x800.Z. [2/91] A set of X11R4 binaries for the NeXT 2.x have been made available by Howie Kaye on cunixf.cc.columbia.edu A set of binaries by John Coolidge (coolidge@cs.uiuc.edu) for the Mac running A/UX 2.0 is available from wuarchive.wustl.edu in the file (/archive/systems/aux/X11R4/Xupdate2.tar.Z). Also in X11R4/diffs is a set of patches for making X11R4 with shared libraries with mkshlib. A complete distribution of SCO X11R4 binaries by Baruch Cochavy (blue@techunix.technion.ac.il) can be found on uunet. The server is Roell's X386 1.1b, compiled for ET4000 based SVGA boards. ---------------------------------------------------------------------- Subject: 63)! Where can I get OSF/Motif? You can obtain either OSF/Motif source or binaries from a number of vendors. Motif 1.2.4 source is now available; it is based on X11R5. Motif 1.1 is based on the R4.18 Intrinsics and is finished [7/92] at 1.1.5. A conformant Motif implementation not based on OSF-derived source is being developed by fox@crisp.demon.co.uk (Paul Fox). An OSF/Motif source license must be obtained from OSF before source can be obtained from the Open Software Foundation or any value-added vendor for any version. Various hardware vendors produce developer's toolkits of binaries, header files, and documentation; check your hardware vendor, particularly if that vendor is an OSF member. ---------------------------------------------------------------------- Subject: 64) Does Motif work with X11R4? X11R5? Motif 1.2 is based on X11R5. Motif 1.1, available in source form from OSF as of August 1990, uses the "vanilla" X11R4 Intrinsics, where "vanilla" means "with just a few patches"; the file fix-osf which OSF distributes is obsoleted by the Consortium's patches 15-17. The file fix-osf-1.1.1 distributed with the 1.1.1 version or its subsequent modification needs to be applied after fix-18, though. Motif 1.1.1 to 1.1.3 will work with X11R5 if X11R5 is compiled with -DMOTIFBC; 1.1.4 and later should work with the vanilla R5, although there are some known new geometry-management problems. ---------------------------------------------------------------------- Subject: 65) Where can I get toolkits implementing OPEN LOOK? Sun's XView has a SunView-style API. Version 3.2 is available (7/93) from xview.ucdavis.edu in /pub/XView/XView3.2 or ftp.x.org in /contrib/xview3.2. XView and X binaries for the Sun 386i ("roadrunner") are available for ftp from svin01.win.tue.nl (131.155.70.70), directory pub/X11R4_386i. Supported binaries of XView 2.0 or 3.0 include: [stuff censored] ---------------------------------------------------------------------- Subject: 66) Where can I get other X sources? (including R5 modifications) The MIT Software Center ships the X Test Suite on tape. A multi-threaded version of Xlib based on X11R5 patch 12 is now available for anonymous FTP from (new version 1/93): DEC on gatekeeper.dec.com (16.1.0.2) in /pub/X11/contrib/mt-xlib-1.1 MIT on ftp.x.org in /contrib/mt-xlib-1.1 Note that this source code will not become the Xlib used in X11R6, although the Consortium is planning to make Xlib thread-safe with that release. HP has made available drivers to permit the building of the X11R5 sample server on the HP 9000 Series 700 workstations; the files are on ftp.x.org in ~ftp/contrib/R5.HP.SRV. [8/92] The Edinburgh University Computing Service and European X User Group have created an on-line index of public domain X software. The index is available through gopher and provides an index of the ftp.x.org/contrib archive, the comp.sources.x archive and various X software found around the internet. The service holds manual pages, README files , etc which can be browsed through. A keyword search of the manual pages is also provided. Information: xindex@castle.edinburgh.ac.uk. User-contributed software is distributed through the newsgroup comp.sources.x, moderated by Chris Olson (chris@imd.sterling.com); also check that group for posting information. Richard Hesketh (rlh2@ukc.ac.uk) has been creating a list of freely- available X sources. The list is stored on ftp.x.org in contrib as x-source-list.Z. It lists the main storage locations for the program and international sites from which it may be ftp'ed. The machine ftp.x.org has a great deal of user-contributed software in the contrib/ directory; a good deal of it is present in current or earlier versions on the X11R3, X11R4, and X11R5 contrib tapes. There are also directories for fixes to contrib software. The file on ftp.x.org in contrib/0ftpxorg.dir.Z is a quick overall index of the software in that area, provided by Daniel Lewart (d-lewart@uiuc.edu). These sites used to and may still mirror ftp.x.org and are of particular use for Australasia: Anonymous ftp: ftp.Adelaide.EDU.AU; ACSnet Fetchfile: sirius.ua.oz. The material on giza.cis.ohio-state.edu, which tends to duplicate the ftp.x.org archives, is also available via anonymous UUCP from osu-cis, at TB+ and V.32 speeds. Write to uucp@cis.ohio-state.edu (same as osu-cis!uucp) for instructions. [the archive is now maintained by Karl Kleinpaste] A new west-coast UUCP X11 Archive is administered by Mark Snitily (mark@zok.uucp) and contains the full X11 distribution, the XTEST distribution, an entire archive of comp.sources.x and other goodies. The machine zok has a TB+ modem which will connect to 19.2K, 2400, 1200 baud (in that order). The anonymous UUCP account is UXarch with password Xgoodies. The modem's phone number is 408-996-8285. A sample Systems (or L.sys) entry might be: zok Any ACU 19200 4089968285 in:--in: UXarch word: Xgoodies To get a current listing of the files that are available, download the file "/usrX/ls-lR.Z". A full subject index of the comp.sources.x files is available in the file "/usrX/comp.sources.x/INDEX". The machine has just the one modem, so please do not fetch large amounts of data at one sitting. [courtesy Mark Snitily, 2/90] In addition, UUNET Source Archives tracks comp.sources.x and provides 800MB+ of compressed programs on 6250 bpi tapes or 1/4" tapes. It also mirrors ftp.x.org/contrib in its packages/X directory. ---------------------------------------------------------------------- Subject: 67)! Where can I get interesting widgets? The Free Widget Foundation (FWF) library sponsored by Brian Totty (totty@cs.uiuc.edu) is now [2/93] available on a.cs.uiuc.edu (128.174.252.1) in pub/fwf-v3.53.shar.Z. The set of widgets there is intended to form the basis for future contributions. To be added to the discussion list, send to listserv@cs.uiuc.edu a message saying "subscribe " where is one of free-widgets-announce, free-widgets-development, or free-widgets-bugs. An object like the Windows "combo box" is part of the Xm++ class library. Harald Albrecht's (albrecht@igpm.rwth-aachen.de) Motif implementation of the ComboBox object from MSWindows is available on ftp.informatik.rwth-aachen.de (137.226.112.172) in pub/packages/ComboBox and on ftp.x.org. Version 1.20b became available 2/94. A library by Jean Michel Leon (leon@sophia.inria.fr) which adds "inset" facilities to Xt is available on ftp.x.org in contrib/insetlib-0.2.tar.gz. The XmBoss widget by Doyle Davidson (doyle@ps.atl.sita.int) is a generic Motif 1.1 layout manager that implements geometry management through application callbacks; sources are on ftp.x.org. The Xew widget set by Markku Savela (savela@tel.vtt.fi) contains widgets for data representation. Version 2.0 [3/94] is on ftp.x.org in contrib/Xew-2.0.tar.Z. Peter Ware's Xo "Open Widget" set, which has Motif-like functionality, is on archive.cis.ohio-state.edu as pub/Xo/Xo-2.1.tar.Z [8/92]. The AthenaTools Plotter Widget Set Version 6-beta [7/92] maintained by Peter Klingebiel (klin@iat.uni-paderborn.de) includes many graph and plotting widgets; a copy is on ftp.x.org in plotter.v6b.tar.Z, plotter.doc.tar.Z, plotter.afm.tar.Z, and plotter.README. The latest versions may in fact be on ftp@uni-paderborn.de (131.234.2.32) in /unix/tools, which appears to contain version 6.0.7. A commercial product sharing the same origins is offered by Dovetail Consulting. An advance version of Marc Quinton's Motif port of the FWF MultiList widget is in ftp.stna7.stna.dgac.fr:pub/MultiList.tar.Z [143.196.9.31]. Additional widgets are available on the contrib/ portion of the X11R4 tapes; these include the Xcu set. Paul Johnston's (johnston@spc5.jpl.nasa.gov) X Control Panel widget set emulates hardware counterparts; sources are on ftp.x.org in Xc-1.3.tar.Z. O'Reilly Volume 4, Doug Young's book, the Asente/Swick book, and Jerry Smith's "Object-oriented Programming with the X Window System Toolkits" all include details on writing widgets and include several useful widgets; sources are typically on ftp.x.org and/or UUNET. Doug Young's book, in particular, contains a version of a tree-like layout object (root and multiple leaves). The Dirt interface builder includes the libXukc widet set which extends the functionality of Xaw. A graph widget and other 2D-plot and 3D-contour widgets by Sundar Narasimhan (sundar@ai.mit.edu) are available from ftp.ai.mit.edu as /pub/users/sundar/graph.tar.Z. The graph widget has been updated [3/91] with documentation and histogram capabilities. A graph widget is available from ftp.stna7.stna.dgac.fr in pub/Graph.tar.Z; it uses a segment list for drawing and hence supports a zoom operation. Ken Lee's Xm widget (demo) that uses Display PostScript to draw labels at a non-horizontal angle is on ftp.x.org in contrib/dpslabel.tar.Z. The Table widget (works like troff TBL tables) is available in several flavors, one of which is with the Widget Creation Library release (ftp.x.org:/contrib/Wcl-2.5.tar.Z). Bell Communications Research has developed a Matrix widget for complex application layouts; it's on ftp.x.org in contrib/Xbae-widgets-3.8.tar.Z [2/93. The distribution also includes a "caption" widget to associate labels with particular GUI components. (7/92) Dan Connolly's (connolly@convex.COM ??) XcRichText interprets RTF data; it's on ftp.x.org as contrib/XcRichText-1.2.tar.Z. The XmGraph Motif-based graphing widget is on iworks.ecn.uiowa.edu in /comp.hp/GUI_classic/XmGraph.tar.Z although it may not be stable. A TeX-style Layout widget by Keith Packard is described in the proceedings of the 7th X Technical Conference (O'Reilly X Resource issue 5); source is available on ftp.x.org contrib/Layout.tar.Z. A version of Lee Iverson's (leei@McRCIM.McGill.EDU) image-viewing tool is available as contrib/vimage-0.9.3.tar.Z on ftp.x.org. The package also includes an ImageViewPort widget and a FileDialog widget. [12/91;5/92] An MPEG viewer by Jan Newmarch (jan@ise.canberra.edu.au) is on ftp.x.org in mpeg_wdgt2.0b.tar; it requires Motif. In addition, the PEXt toolkit by Rich Thomson (rthomson@dsd.es.com) is available on ftp.x.org as PEXt.tar.Z; it includes a PEX widget making it easier to use PEX in Xt-based programs. A Motif port of the Xaw clock widget is in ftp.stna7.stna.dgac.fr in pub/Clock.tar.Z. A modification of the Xaw ScrollBar widget which supports the arrowhead style of other toolkits is on ftp.x.org in contrib/Xaw.Scrollbar.mta.Z. A release of the R5 Xaw widgets with a 3D visual appearance by Kaleb Keithley (now kaleb@x.org) is available on ftp.x.org in contrib/Xaw3d/R5/Xaw3d-0.6.tar.Z. The library, which is binary-compatible with Xaw, implements a 3D subclass which handles the extra drawing. The Andrew User Interface System supplies an extensive collection of widgets including full-blown editors for text, rasters, figures, tables, and so on. Also: The Xmt "Motif Tools", Dovetail Systems's shareware library of 9 widgets and many convenience functions, is available from ftp.x.org:contrib and ftp.ora.com:/pub/xbook/Xmt in xmt-README and xmt-1.0.tar.Z. A set of OSF/Motif compound widgets and support routines for 2D visualization is available from Ms Quek Lee Hian, National Computer Board, Republic of Singapore; Tel : (65)7720435; Fax : (65)7795966; leehian@iti.gov.sg, leehian@itivax.bitnet. ---------------------------------------------------------------------- Subject: 68) Where can I get a good file-selector widget? The Free Widget Foundation set offers a FileSelector widget, with separate directory path and file listing windows, and the FileComplete, which has emacs-style file completion and ~ expansion. Other available file-requestor widgets include the XiFileSelector from Iris Software's book, the xdbx file-selector extracted by David Nedde (daven@ivy.wpi.edu), and the FileNominator from the aXe distribution. The GhostView, Xfig, and vimage packages also include file-selector widgets. ---------------------------------------------------------------------- Subject: 69) Where can I find a hypertext widget in source code? A hypertext widget was posted to comp.sources.x. It can be found in volume 16 of the archives at ftp.uu.net under the name "hman". The distribution includes a hypertext widget with both Athena and Motif compatability (set at compile-time) and hman, a Motif-based man reference page reader that uses the widget to look up other man topics. [Joe Shelby (shelby@dirac.physics.jmu.edu); 6/93] ---------------------------------------------------------------------- Subject: 70)! What widget is appropriate to use as a drawing canvas? Some widget sets have a widget particularly for this purpose -- a WorkSpace or DrawingArea which doesn't display anything but lets your Xt application know when it has been re-exposed, resized, and when it has received user key and mouse input. The best thing to do for other widget sets -- including the Athena set -- is to create or obtain such a widget; this is preferable to drawing into a core widget and grabbing events with XtAddEventHandler(), which loses a number of benefits of Xt and encapsulation of the functionality . The publicly-available programs xball and xpic include other versions. The Display widget in the XG library (libXG-2.0.tar.Z on ftp.x.org) provides a generic way of drawing graphics in a widget. The Athena Widget manual (mit/doc/Xaw/Template in the R5 distribution, xc/doc/specs/Xaw/Template in the R6 distribution) includes a tutorial and source code to a simple widget which is suitable for use. The Free Widget Foundation set contains a Canvas widget. ---------------------------------------------------------------------- Subject: 71) What is the current state of the world in X terminals? Jim Morton (jim@applix.com) posts quarterly to comp.windows.x a list of manufacturers and terminals; it includes pricing information. ---------------------------------------------------------------------- Subject: 72) Where can I get an X server with a touchscreen or lightpen? Labtam (+61 3 587 1444, fax +61 3 580 5581) offers a 19" Surface Acoustic Wave touch-screen option on its Xengine terminals. Tektronix (1-800-225-5434) provides an X terminal with the Xtouch touch-screen. This terminal may also be resold through Trident Systems (703-273-1012). Metro Link (305-970-7353) supports the EloGraphics Serial Touch Screen Controllers. ---------------------------------------------------------------------- Subject: 73)! Where can I get an X server on a PC (DOS or Unix)? X11R6 contains sources for a number of X servers from XFree86, Inc.: XF86_S3, XF86_Mach8, XF86_Mach32, XF86_8514, XF86_Mono, XF86_Bdm, XF86_SVGA, and XF86_VGA16. See xc/programs/Xserver/hw/xfree86. Also included in R6 is Xsvga from SGCS and Thomas Roell; see xc/programs/Xserver/hw/svga. All of the above are Unix-based. X11R5 already provides a server to many 386/486 *Unixes* with support for many of the popular video graphics adapters; and for other non-MSDOS PCs you can obtain a server from these sources: XFree86 (formerly X386 1.2E) is an enhanced version of X386 1.2, which was distributed with X11R5; it includes many bug fixes, speed improvements, and other enhancements. Source for version 2.0 [10/93] is on ftp.x.org in pub/contrib, ftp.physics.su.oz.au in /XFree86, and ftp.win.tue.nl in /pub/XFree86. In addition, binaries are on ftp.physics.su.oz.au, and ftp.win.tue.nl among other systems. Info: x386@physics.su.oz.au. Note: this package obsoletes Glenn Lai's Speedup patches for an enhanced X11R5 server for 386 UNIXes with ET4000 boards (SpeedUp.tar.Z on ftp.x.org). ---------------------------------------------------------------------- Subject: 76) Where can I get a serial-based X server for connecting from home? sxpc 1.2 (by Robert Andrew Ryan (rr2b+@andrew.cmu.edu)) is a simple X protocol compressor. Sources are on atk.itc.cmu.edu (in sxpc-1.0.shar.Z), or from ftp.x.org (in contrib/sxpc-1.2.shar.Z) ---------------------------------------------------------------------- Subject: 80) What terminal emulators other than xterm are available? People from PCS have rewritten xterm from scratch using a multi-widget approach that can be used by applications. Emu supports features like color, blinking text/cursors. Emulations can be added on the fly; one emulation provided is for the Vt220. A version is on the R5 contrib tape; the newest release is on ftp.x.org [10/93] in contrib/emu.tar.gz. For more information, contact emu@pcs.com. A set of modifications for color support to xterm is on ftp.x.org in xterm_color.diffs.Z. mxterm, a Motif-based xterm is available from the Paderborner ftp-Server ftp@uni-paderborn.de (131.234.2.32), file /unix/X11/more_contrib/mxterm.tar.Z. A version is also on ftp.x.org, as is apparently a set of color modifications. The Color Terminal Widget provides ANSI-terminal emulation compatible with the VTx00 series; a version is on ftp.x.org in contrib/CTW-1.1.tar.Z. A Motif version is on ftp.stna7.stna.dgac.fr in pub/Term-1.0.tar.Z. kterm 4.1.2 is an X11R4-based vt100/vt102 (and Tektronix 4014) terminal emulator that supports display of Chinese, Japanese, and Korean text (in VT mode). Also supported are: ANSI color sequences, multi-byte word selection, limited Compound Text support, and tab and newline preservation in selections. kterm 4.1.2 is also available from these anonymous ftp sites: clr.nmsu.edu:pub/misc/kterm-4.1.2.tar.Z [128.123.1.14] ftp.x.org:contrib/kterm-4.1.2.tar.Z kum.kaist.ac.kr:pub/unix/Xstuffs/kterm-4.1.2.tar.Z [137.68.1.65] [courtesy of Mark Leisher ] kterm-5.2.0.tar.gz is now on ftp.x.org [1/94]. mterm, by mouse@larry.McRCIM.McGill.EDU, is an X terminal emulator which includes ANSI X3.64 and DEC emulation modes. mterm can be had by ftp to larry.mcrcim.mcgill.edu (132.206.1.1), in X/mterm.src/mterm.ball-o-wax. color_xterm is available from ftp.x.org. Cxterm is a Chinese xterm, which supports both GB2312-1980 and the so-called Big-5 encoding. Hanzi input conversion mechanism is builtin in cxterm. Most input methods are stored in external files that are loaded at run time. Users can redefine any existing input methods or create their own ones. The X11R5 cxterm is the rewritten of cxterm (version 11.5.1) based on X11R5 xterm; it is in the R5 contrib software. [thanks to Zhou Ning and Steinar Bang .] XVT is available on ftp.x.org's contrib in xvt-1.0.tar.Z and xvt-1.0.README. It is designed to offer xterm's functionality with lower swap space and may be of particular use on systems driving many X terminals. A second version, 2.0, is on unix.hensa.ac.uk in misc/unix/xvt/xvt-2.0.tar.Z (see also xvt-2.0.patch[12]). x3270 is in X11R5 contrib/. The typescript application and inset in the Andrew User Interface System offers a shell script interface. It does not provide curses support, but does permit general cut/copy/paste to construct commands or extract a portion of the log. hanterm (2.0), by jksong@cosmos.kaist.ac.kr, is an xterm modified to support Hangul (Korean writing system) input/output. It's available at several Korean archives(cair.kaist.ac.kr,kum.kaist.ac.kr,etc) and seoul.caltech.edu in the US. This version makes obsolete an older version not based on xterm. Another experimental hanterm implementation, hanterm (3.0 alpha), is underway by Chang Hyeong-Kyu at chk@ssp.etri.re.kr; it was written to support a 3-byte Hangul code (dictionary ordered), which can compose all possible Hangul characters. ---------------------------------------------------------------------- Subject: 81) Does xterm offer colored text or a blinking cursor? No; these features are not offered by the xterm program. However, several of the emulators mentioned above do offer these features; the list is partial: - mterm, color-xterm, CTW and emu support colored text - mterm and emu support blinking text - mterm and emu support block and underline text cursors - emu supports a blinking text cursor [Thanks to Michael Elbel (me@dude.pcs.com); 10/93] ---------------------------------------------------------------------- Subject: 82)! Where can I get an X-based editor or word-processor? You can ftp a version of GNU Emacs, the extensible, customizable, self-documenting, real-time display editor, including X11 support, from prep.ai.mit.edu [18.71.0.38]:/pub/gnu/. Version 19 has some mouse/menu support. Epoch is a modified version of Gnu Emacs (18) with additional facilities useful in an X environment. Current sources are on cs.uiuc.edu (128.174.252.1) in ~ftp/pub/epoch-files/epoch; the current [3/92] version is 4.0. [In Europe, try unido.informatik.uni-dortmund.de]. There are two subdirectories: epoch contains the epoch source, and gwm contains the source to the programmable window manager GWM, with which epoch works well.] You can get on the Epoch mailing list by sending a request to epoch-request@cs.uiuc.edu. Lucid Emacs is a version of GNU Emacs derived from an early version of Emacs version 19. It currently requires X Windows to run; X support is greatly enhanced over GNU Emacs version 18, including support for multiple X windows, input and display of all ISO-8859-1 (Latin1) characters, Zmacs/Lispm style region highlighting, a customizable Motif-like menubar, more powerful keymap support, flexible text attributes, support on regional and screen-local basis through X resources and/or lisp, and support for the X11 selection mechanism. Lucid Emacs is free; the latest version (9/93) is 19.8, and is available from labrea.stanford.edu (36.8.0.112) in the pub/gnu/lucid directory. The Andrew system on the X11 contrib tapes has been described as one of the best word-processing packages available. It supports word processing with multi-media embedded objects: rasters, tables/spread sheets, drawings, style editor, application builder, embedded programming language, &c. Release 5.1 became available 2 June 92. [Fred Hansen (wjh+@ANDREW.CMU.EDU)] You may be able to use the Remote Andrew Demo service to try this software; try "finger help@atk.itc.cmu.edu" for help. The InterViews C++ toolkit contains a WYSIWIG editor called Doc; it saves and loads files in a LaTeX-*like* format (not quite LaTeX). The package can also import idraw-PostScript drawings. aXe (by J.K.Wight@newcastle.ac.uk), a multi-buffer, multi-window text editor based around the Xaw Text Widget, is available on ftp.x.org and arjuna.newcastle.ac.uk (128.240.150.1) as aXe-6.0.tar.Z (also get the patch to 6.1) [1/94]. aXe offers a hypertext help system and extension via Tcl. TED is a simple Motif-based text editor; it is a wrapper around the Motif text widget which offers search/replace, paragraph formatting, and navigation features. TED is available from ftp.eos.ncsu.edu (152.1.9.25) as /pub/bill.tar.Z; here are also executables there. Point, by crowley@unmvax.cs.unm.edu (Charlie Crowley), is Tcl/Tk-based and offers dyanimic configuration and programming in the Tcl macro language. The editor is available from unmvax.cs.unm.edu (129.24.16.1) as pub/Point/point1.1-tar.Z. asedit, by Andrzej Stochniol (astoch@ic.ac.uk) is on ftp.x.org in contrib/asedit.tar.Z. It is a simple text editor built around the Motif Text widget. Version 1.2 was released 10/93. jed is available from rhino.cis.vutbr.cs in pub/software/czech. xcoral, a multi-window mouse-based text editor, is on ftp.inria.fr; it also has bindings similar to emacs and has a built-in browser for C and C++ code. A version is also on ftp.Uni-Oldenburg.DE in pub/unix/appl/edit/xcoral-2.1.tar.Z. The powerful "sam" editor by Rob Pike is split into a host portion and a front-end graphics portion, which now has an X implementation. sam is now available by anonymous ftp from research.att.com, in dist/sam/bundle.Z. Watch that space for updated versions. There is a mailing list for sam users; requests to . A set of extensions which augment the mouse activity with the keyboard is available from uxc.cso.uiuc.edu in pub/sam/samx2.shar.Z. [5/93] The vi-like-microemacs editor VILE supports a pure-X mode, in which it operates much like vi running in an xterm window. Version 4.5, which also supports Xt-based implemenations, including OLIT and Motif versions, is available on ftp.cayman.com in pub/vile. NEdit 3.0 (4/94) is a Motif-based text editor supporting multiple windows and multi-level undo. Sources are on ftp.x.org and fnpspb.fnal.gov. Information: edel@fnal.gov. BETH is a Browsing and Editing Tcl Hypertool available from harbor.ecn.purdue.edu in /pub/tcl/code/beth3.0.tar.gz. Info: svoboda@ece.cmu.edu (David Svoboda) A calendar/rolodex program from mengel@dcdmwm.fnal.gov (Marc Mengel) can browse and edit other colon-separated field files. It requires Tk. The DGC Tools, on harbor.ecn.purdue.edu in pub/tcl/code/dgctools-0.2.tar.Z, include Tke, a TclX/Tk-based multi-window X11 text editor. Info: dave_clemans@mentorg.com (Dave Clemans) The js tools, on harbor.ecn.purdue.edu in pub/tcl/code/jstools-tk3.2v1.0.tar.Z and on princeton.edu in pub/js/jstools-tk3.2v1.0.tar.Z, include a extensible text editor. Info: Jay Sekora (js@princeton.edu) Mxedit, a fully functional Tk based editor based on a stand-alone Tk edit widget, is on harbor.ecn.purdue.edu in pub/tcl/code/mxedit.2.1.tar.Z. and parcftp.xerox.com in pub/mxedit/mxedit.2.1.tar.Z. Info: welch@parc.xerox.com (Brent Welch) [thanks in part to Larry W. Virden (lvirden@cas.org)] ---------------------------------------------------------------------- Subject: 83) Where can I get an X-based mailer? xmh, an X interface to mh, is distributed with the X11 release. Xmail is an X-based window interface to Berkeley-style mail handlers; it is styled primarily after the Sunview mailtool application and builds on most Unix systems. The current release [1/92] is 1.4, available in the MIT X11R5 contrib tape and from ftp.x.org and uunet. Info: Jeff Markham, markham@cadence.com. adcmail (0.9 pre-release), on ftp.csc.liv.ac.uk provides all the normal mail facilities (message management, aliases, etc.); work is underway to tidy things up a little and to add MIME compliancy. MMH (My Mail Handler), a motif interface to the MH mail handler, is available from ftp.eos.ncsu.edu (152.1.9.25) in pub/bill.tar.Z; it is bundled with the TED editor, which it uses for composing messages. Motif 1.1 is required; if you don't have it, look for DEC and SPARC executables in the same place. Information and problems to: Erik Scott, escott@eos.ncsu.edu. [1/92] The Andrew Toolkit supports the Andrew Message System; it is available from ftp.x.org and many other X archives and from emsworth.andrew.cmu.edu (128.2.30.62), or send email to susan+@andrew.cmu.edu. Release 5.1 became available 2 June 92. You may be able to use the Remote Andrew Demo service to try this software; try "finger help@atk.itc.cmu.edu" for help. XMailTool is an Xaw-based interface to a BSD-style mail reader; version 2.0 was released 9/92. Information: Bob Kierski, bobo@cray.com or 612-683-5874. Cem is a Motif-based mailer using standard mailbox formats; it is on nelson.tx.ncsu.edu in pub/Cem. Information: Sam Moore (Sam_Moore@ncsu.edu). MuMail, an X-based elm-like mail program is available at sipb.mit.edu:/pub/seyon/MUMAIL or sunsite.unc.edu in /pub/Linux/system/Mail/Mumail-2.3b-tar.Z. Xelm is a work-in-progress by wing@dcs.warwick.ac.uk to construct an X version of the elm mailer. ---------------------------------------------------------------------- Subject: 84)! Where can I get an X-based paint/draw program? Drawing Packages: xpic is an object-oriented drawing program. It supports multiple font styles and sizes and variable line widths; there are no rotations or zooms. xpic is quite suitable as an interactive front-end to pic, though the xpic-format produced can be converted into PostScript. (The latest version is on the R4 contrib tape in clients/xpic.) xfig (original work by Supoj Sutanthavibul, with additional work and currently maintained by Brian V. Smith (bvsmith@lbl.gov)) is an object-oriented drawing program supporting compound objects. The xfig format can be converted to PostScript or other formats. Recent versions are on the R5 contrib tape or on ftp.x.org in /contrib/R5fixes (version 2.1.8 [10/93]). idraw supports numerous fonts and various line styles and arbitrary rotations. It supports zoom and scroll and color draws and fills. The file format is a PostScript dialect. It can import TIFF files. Distributed as a part of the InterViews C++ toolkit (current release 3.1, from interviews.stanford.edu) . tgif by William Cheng (william@oahu.cs.ucla.edu) is available from most uucp sites and also from ftp.x.org and from cs.ucla.edu. It is frequently updated; version 2.14 was released 8/93 (up to patch9 12/93). figure in the Andrew User Interface System (versions 5.2 and above) is a general drawing package which also allows arbitrary Andrew insets to be part of the drawing. Picasso 3.8, an interactive drawing tool in the style of idraw, is on zenon.inria.fr in pub/tk (it requires tk and tclX). Paint Packages: XPaint 2.1, by David Koblas (koblas@netcom.com), is a color bitmap/pixmap editing tool featuring most standard paint program options. It allows for the editing of multiple images simultaneously and supports various formats, including PPM, XBM, etc. The current version is available for ftp from ftp.x.org as contrib/xpaint-2.1.1.tar.Z [1/94] A new OpenWindows PostScript-based graphical editor named 'ice' is now [2/91] available for anonymous ftp from Internet host lamont.ldgo.columbia.edu (129.236.10.30). ice (Image Composition Environment) is an imaging tool that allows raster images to be combined with a wide variety of PostScript annotations in WYSIWYG fashion via X11 imaging routines and NeWS PostScript rasterizing. (It may require OpenWindows and Sun C++ 2.0.) The "pixmap" program by Lionel Mallet (mallet@sophia.inria.fr) for creating pixmaps is on the R5 contrib tape; it resembles the bitmap client. Version 2.4 is now available [2/94] on ftp.x.org and avahi.inria.fr. A version of Robert Forsman's (thoth@lightning.cis.ufl.edu) xscribble, an 8-bit paint program for X, is now on ftp.cis.ufl.edu in pub/thoth/. [2/93] pixt by J. Michael Flanery (flanery@mips.com) produces XPM output; it is available on ftp.x.org. xpe on ftp.x.org produces XPM output. Phoenix is a 24-bit editor for editing of photos, notably. An alpha is on nic.funet.fi:pub/graphics/packages/phoenix. Yaged (Yet Another Graphics EDitor) is an X/Motif(1.1) TIFF pixmap editor. Sources are on ftp.sbu.ac.uk in /pub/MotifStuff/yaged. [thanks in part to Stephen J. Byers (af997@cobcs1.cummins.com), J. Daniel Smith (dsmith@ann-arbor.applicon.slb.com), and David Koblas (koblas@netcom.com)] ---------------------------------------------------------------------- Subject: 85) Where can I get an X-based plotting program? These usually are available from uucp sites such as uunet or other sites as marked; please consult the archie server to find more recent versions. See also the comp.graphics FAQ. gnuplot X (xplot), PostScript and a bunch of other drivers. ftp.x.org [and elsewhere]:contrib/gnuplot3.4a.tar.Z gl_plot X output only [?] comp.sources.unix/volume18 graph+ yallara.cs.rmit.oz.au:/pub/graph+.tar.Z [131.170.24.42] comp.sources.unix/volume8 pdraw,drawplot 2D and 3D X,PS scam.berkeley.edu:/src/local/3dplot.tar.Z [128.32.138.1] scam.berkeley.edu:/src/local/contour.tar.Z [128.32.138.1] scam.berkeley.edu:/src/local/drawplot.tar.Z [128.32.138.1] uunet:~ftp/contrib/drawplot.tar.Z xgraph plot, zoom. Outputs PS or HPGL. shambhala.berkeley.edu:/pub/xgraph-11.tar.Z [128.32.132.54] sun1.ruf.uni-freiburg.de:X11/contrib/xgraph-11.tar.Z [132.230.1.1] nisc.jvnc.net:pub/xgraph-11.tar.Z [128.121.50.7] comp.sources.x/volume3 or many other sites ACE/gr (formerly xvgr and xmgr) XY plotting tools ftp.ccalmr.ogi.edu [129.95.72.34] XView version: /CCALMR/pub/acegr/xvgr-2.10.tar.Z Motif version: /CCALMR/pub/acegr/xmgr-2.10.tar.Z [mirrored on ftp.x.org in /contrib/acegr] XGobi An interactive dynamic scatter-plotting tool from Bellcore lib.stat.cmu.edu: general/xgobi* [log in as statlib with your email as the password; or send email to statlib@lib.stat.cmu.edu containing the one-line message "send xgobi from general"] Information from: Debby Swayne, dfs@bellcore.com. Robot a scientific XView-based graph plotting and data analysis tool ftp.astro.psu.edu:pub/astrod/robotx0.47.tar.Z [128.118.147.28] plotmtv a multi-purpose 2D/3D plotter tanqueray.berkeley.edu:/pub/Plotmtv1.3.1.tar.Z XgPlot Motif-based x-y graphing with a movie-loop display ftp.x.org:XgPlot-4.1.tar.Z [2/91. Thanks in part to: emv@ox.com (Ed Vielmetti); geoff@Veritas.COM (Geoffrey Leach); Paul A. Scowen (uk1@spacsun.rice.edu); black@beno.CSS.GOV (Mike Black)] ---------------------------------------------------------------------- Subject: 86) Where can I get an X-based graph-drawing program? Xgrab reads a textual specification of a graph, lays out the graph using heuristics to minimize the number of edge crossings, and displays the graph as labeled nodes and edges in an X window. Sources are on ftp.cs.washington.edu (128.95.1.4) as pub/xgrab.tar.Z. Interviews 2.6 is required. [12/93] The DaVinci visualization tool can be used to display graphs. ---------------------------------------------------------------------- Subject: 87) Where can I get an X-based spreadsheet? A version of "sc" for X and which supports Lotus files is available from vernam.cs.uwm.edu in xspread2.1.tar.Z. It also includes graphing functions. Information: soft-eng@cs.uwm.edu. The GNU package OLEO is available in prep.ai.mit.edu:pub/gnu/oleo-1.5.tar.Z; it can generate PostScript renditions of spreadsheets. ---------------------------------------------------------------------- Subject: 89) Where can I get an X-based PostScript previewer? Ghostscript is distributed by the Free Software Foundation (617-876-3296) and includes a PostScript interpreter and a library of graphics primitives. Version 2.6.1(.4) is now available; the major site is prep.ai.mit.edu, although ftp.cs.wisc.edu is also recommended. [6/93] Version 3.0 will include a full implementation of PostScript Level 2. GSPreview (by the Computing Laboratory of the University of Kent at Canterbury) is an X user interface (WCL-based) to the Ghostscript 2.4-2.6 interpreter. The source is available for anonymous ftp from ftp.x.org as gspreview.2.3.tar.Z. [6/93] GhostView (by Tim Theisen, tim@cs.wisc.edu) is full-function user interface for GhostScript. Check ftp.cs.wisc.edu or prep.ai.mit.edu for /pub/ghostview-1.5.tar.Z [7/93]. There are also several executables available on ftp.cs.wisc.edu:/pub/X/ghostview-exe for various architectures. XPsView (by Francois Bourdoncle, bourdoncle@prl.dec.com) is a Motif wrapper around PsView, which is a X11 DSC Document viewer that can use both XDPS and GhostScript as the interpreter engine. An early version was an the Alpha Freeware CD. More recent versions are on gatekeeper.dec.com in /pub/DEC/PRL/psview-1.32.tar.Z. ---------------------------------------------------------------------- Subject: 90) Where can I get an X-based GKS package? The latest freely-available XGKS can be obtained from xgks-request@unidata.ucar.edu; this is a 2c implementation derived from the X11R4 contrib XGKS from IBM and the University of Illinois. The release is on unidata.ucar.edu [128.117.140.3] as pub/xgks.tar.Z. [12/90] GKSUL is available from gks@ulowell.edu (ULowell CS department). It is a 2b implementation which includes drivers for a variety of devices. It can be passed an X window ID to use. The package includes both C and Fortran bindings. [11/90; from dsrand@mitre.org and from stew@hanauma.stanford.edu] An XgksWidget is produced by Neil Bowers (neilb@leeds.dcs; neilb@dcs.leeds.ac.uk); the latest [10/91] conforms with the new version of XGKS (2.4). It is available on ftp.x.org in contrib/xgks-widget.tar.Z. ---------------------------------------------------------------------- Subject: 91)! Where can I get an X-based GL package? Ygl 2.4 (by Fred Hucht, fred@thp.Uni-Duisburg.DE) emulates most of the two dimensional drawing routines and the window, queue, color (cmap/RGB) stuff, doublebuffering and more. Ygl is available [04/94] from ftp.thp.Uni-Duisburg.DE (134.91.141.1), as pub/source/X11/Ygl-2.4.tar.{Z|gz}. ---------------------------------------------------------------------- Subject: 92) Where can I get an X-based PEX package? The first official release of PEX is with X11R5; fix-22 brings the Sample Implementation server to version 5.1. The final PEX 5.1 Protocol specification is now available via anonymous ftp to ftp.x.org, in the directory /pub/DOCS/PEX/. Changes made from the Public Review draft are listed in the file "5.1P_changes" in that directory. [9/92] The final PEXlib 5.1 document is on ftp.x.org in pub/DOCS/PEXlib. [11/92] There is now available from the University of Illinois an implementation of the PEX 4.0 specification called UIPEX. It contains a "near- complete" implementation of PHiGS and PHiGS PLUS. The file pub/uipex/uipex.tar.Z is on a.cs.uiuc.edu (128.174.252.1); the porting platform was an RT running 4.3. Questions and comments can to go uipex@cs.uiuc.edu. In addition, the PEXt toolkit by Rich Thomson (rthomson@dsd.es.com) is available on ftp.x.org as PEXt.tar.Z; it includes a PEX widget making it easier to include PEX in Xt-based programs. ---------------------------------------------------------------------- Subject: 93) Where can I get an X-based TeX or DVI previewer? The xtex previewer for TeX files is available from a number of archive sites, including uunet; the current version is usually on ftp.cs.colorado.edu (128.138.204.31) in SeeTeX-2.18.5.tar.Z; pre-converted fonts are also on that machine. The distribution all includes "mftobdf" which converts PK, GF, and PXL fonts to BDF format, where they can then be compiled for use by your local X server. The xdvi dvi-previewer is fairly comprehensive and easy to use. It is also available from a number of sites, including uunet and ftp.x.org; current version is patchlevel 16 [12/92]. ---------------------------------------------------------------------- Subject: 94)! Where can I get an X-based troff previewer? xditview, a previewer for device-independent troff, is in contrib in X11R6; it was a supported client in X11R5 and X11R4. X11R4 also offers the contributed xtroff; an earlier version of xtroff also appeared on the R3 contributed source. In addition, the xman client can be used to preview troff documents which use the -man macros (i.e. man pages). If psroff is used its output can be viewed with a PostScript previewer. Groff, a C++-based [tn]roff document formatter from the Free Software Foundation, includes an X-based document previwer based probably on xditview. Groff can put out both dvi and PostScript, so xdvi or GhostView can be used to preview formatted documents. In addition: xproof, an X previewer for ditroff has been contributed by Marvin Solomon (solomon@cs.wisc.edu); version 3.5 is available on ftp.x.org in contrib/xproof*. [8/90] [mostly courtesy moraes@cs.toronto.edu (Mark Moraes)] [2/90] ---------------------------------------------------------------------- Subject: 95)! Where can I get a WYSIWYG interface builder (or other shortcuts)? A release of the DIRT interface builder by Richard Hesketh works with X11R5 and includes some support for the Motif widget set. It generates WCL-1.1 code. DIRT is known to be outdated. It is available through comp.sources.x archives. The InterViews 3.0.1 C++ toolkit contains a WYSIWIG interface builder called ibuild. ibuild generates code for an InterViews application complete with Imakefile and an X-resource file. Documentation is /pub/papers/ibuild.ps on interviews.stanford.edu (36.22.0.175). Quest Windows's (408-496-1900) ObjectViews C++ package includes an interactive building tool. Druid (Demonstrational Rapid User Interface Development) runs on SPARC machines using OSF/Motif 1.0; it is intended eventually to be a full UIMS but apparently now has only support for creating the presentation components, for which it generates C/UIL code. Info: Singh G, Kok CH, Ngan TY, "Druid: A System for Demonstrational Rapid User Interface Development". Proc. ACM SIGGRAPH Symp on User Interface Software and Technology (UIST'90). ACM, NY, 1990, pp:167-177. The XF builder (version 2.3.n) is a TCL/Tk builder; versions are on harbor.ecn.purdue.edu. You may subscribe to a mailing list by sending "sub xf-l " to listserv@tubvm.cs.tu-berlin.de. ADEW in the Andrew User Interface System supports WYSIWYG user interface construction with the full selection of AUIS insets, including text, rasters, tables, and the usual interactors. Semantics can be coded in C or in Ness, the AUIS extension language. Camel, a generic IDT for Xt widget sets, is available from R.N.Tearle@hertfordshire.ac.uk. Look for magazine reviews for more complete comparisons of meta-file formats, documentation, real ease-of-use, etc; Unix World and Unix Review often carry articles. See also SunExpert 5/93. In addition, these non-WYSIWYG but related products may help for goals of rapid prototyping of the application interface: WCL: the Widget Creation Library. Basically describes the widget hierarchy and actions in a resources file; available from fine archive servers everywhere, including devvax.jpl.nasa.gov (128.149.1.143) in pub/. Wcl provides a very thin layer over Xt without any internal tweaking. Version 2.5 is current [3/93]. TCL/TK: TK is a Motif-like object set for use with the TCL scripting language. There is also a package tclMotif on ftp.x.org which may be used to add TCL scripting to Motif programs; version 1.1 was released 2/94. WAFE: Wafe is a package that implements a symbolic interface to the Athena widgets (X11R5) and OSF/Motif. A typical Wafe application consists of two parts: a front-end (Wafe) and an application program which runs typically as a separate process. The application program can be implemented in an arbitrary programming language and talks to the front-end via stdio. Since Wafe (the front-end) was developed using the extensible TCL shell, an application program can dynamically submit requests to the front-end to build up the graphical user interface; the application can also down-load application specific procedures into the front-end, which can be executed without interaction with the application program. Wafe is available from ftp.wu-wien.ac.at:pub/src/X11/wafe/wafe-0.97.tar.gz [3/94]. wafeperl 0.2, which links Perl 4.036 to Wafe 0.96, is available [12/93] from ftp.wu-wien.ac.at in pub/src/X11/wafe/wafeperl-0.2.tar.gz. XGEN: a scripting language which can be used to prototype Motif environments; available on ftp.x.org. WINTERP: an Xlisp-based Motif toolkit allows for interpretive programming. The copy on the R4 tape is outdated; get a copy off ftp.x.org or email to winterp-source%hplnpm@hplabs.hp.com. The Serpent UIMS permits the building of user-interfaces without specific knowledge of coding but with an understanding of attributes being set on a particular [Motif] widget. Beta Release 1.2 is available from ftp.sei.cmu.edu (128.237.1.13) and can be found in /pub/serpent. Serpent is also available on ftp.x.org (18.24.0.11) in /contrib/serpent. Email questions can go to serpent@sei.cmu.edu. Garnet is a Common Lisp-based GUI toolkit. Information is available from garnet@cs.cmu.edu. Articles comparing these tools include: UnixWorld 5/92; SunWorld 12/92; LAN Computing 12/92; SunExpert 5/93. ---------------------------------------------------------------------- Subject: 96) Where can I find X tools callable from shell scripts? I want to have a shell script pop up menus and yes/no dialog boxes if the user is running X. Several tools in the R3 contrib/ area were developed to satisfy these needs: yorn pops up a yes/no box, xmessage displays a string, etc. There are several versions of these tools; few, if any, have made it to the R4 contrib/ area, though they may still be available on various archive sites. XScript, a collection of X shell scripts, is on csc.canberra.edu.au under /pub/motif/xscript and also on ftp.x.org; it includes several stand-alone X applications which can be embedded in shell scripts. XScript requires tclMotif 1.0 or later. In addition, Richard Hesketh (rlh2@ukc.ac.uk) has posted the xmenu package to comp.sources.x ("v08i008: xmenu") for 1-of-n choices. [7/90] Two versions of XPrompt have been posted to comp.sources.x, the latter being an unauthorized rewrite. [R. Forsman (thoth@reef.cis.ufl.edu), 1/91] There is a version of XMenu available from comp.sources.x; it is being worked on and will likely be re-released. xp-1.1.tar.Z, xpick-1.0.tar.Z and xzap-1.0.tar.Z on ftp.x.org's contrib/ are tools by Gerry.Tomlinson@newcastle.ac.UK which act as X versions of the simple display and choice-making tools in K&P. [4/92] xtpanel lets the user build a panel containing interactive objects such as buttons, sliders, text fields, etc., either from the command line or using a simple scripting language. It is available for anonymous ftp from hanauma.Stanford.EDU (36.51.0.16) as pub/X/xtpanel-3.01.tar.Z and may also be found in the alt.sources archives. ---------------------------------------------------------------------- Subject: 97) Where can I get an X-based debugger? xdbx, an X interface to the dbx debugger, is available via ftp from ftp.x.org. The current [1/91] version is 2.1 patchlevel 2. An X interface to gdb called xxgdb is more like xdbx 2.1.2. It is part of comp.sources.x volume 11 [2/91]; xxgdb-1.06.tar.Z is on ftp.x.org. mxgdb is a Motif interface to gdb by Jim Tsillas (jtsillas@proteon.com); version 1.2 was released 11/93. UPS is a source-level debugger which runs under the X11 (and SunView) window systems on Sun, DEC, and Linux platforms. It is available from ftp.x.org (18.24.0.11) as contrib/ups-2.45.tar.Z (also ups-2.45-to-2.45.2.patch.Z) and unix.hensa.ac.uk (129.12.21.7) in /pub/misc/unix/ups (or try mail to archive@unix.hensa.ac.uk). [10/92] Unofficial fixes by Rod Armstrong (rod@sj.ate.slb.com) are on unix.hensa.ac.uk in /misc/unix/ups/contrib/rod@sj.ate.slb.com. ---------------------------------------------------------------------- Subject: 98)! How can I "tee" an X program identically to several displays? There are several protocol multiplexer tools which provide for the simultaneous display of X clients on any number of machines: XMX (an X Protocol Multiplexor) is available from wilma.cs.brown.edu (128.148.33.66) as pub/xmx.tar.Z It works independently of the server and does not affect the application being shared; it was developed for use in the electronic classroom. An update is expected soon [5/93]. XTV is a conference program which can be used to duplicate the "chalkboard" on several displays. Release 1 is available on the X11R5 contrib tapes; a more recent version is on ftp.cs.odu.edu as pub/wahab/XTV.r2.tar.Z. SHX from Michael Altenhofen of Digital Equipment GmbH CEC Karlsruhe also does this; it is a "WYSIWIS" (What You See Is What I See) package in the context of a computer-based learning/training tool to provide online help from remote tutors but is also useful for general window sharing. Information: shX@nestvx.enet.dec.com. SHX can be found on ftp.x.org and gatekeeper.dec.com:/pub/X11/contrib/shX.tar.Z, crl.dec.com:/pub/X11/contrib/shX.tar.Z Modifications to SHX for color mapping and private color allocation by Mark J. Handley (M.Handley@cs.ucl.ac.uk) are on cs.ucl.ac.uk in car/shX.car.tar.Z. XTrap is implemented as a server/library extension and can be used to record and then replay an x session. It is available as ftp.x.org:/contrib/XTrapV33_X11R5.tar.Z. The XTEST and RECORD extensions in R6 provide input synthesis and protocol recording respectively. Taken together, they provide functionality similar to XTrap. wscrawl can be used as a "multi-person paint program". It's available on sax.stanford.edu as wscrawl.shar.Z. Binaries are on doppler.ncsc.org in pub/wscrawl. Shdr implements a simple shared whiteboard, without a chalk-passing mechanism. It's available on parcftp.xerox.com as pub/europarc/shdr.tar.Z. SketchPad 1.0 (3/93) is a distributed interactive graphical editor particularly designed for sketching. Sources have been posted to alt.sources and are available from ftp.igd.fhg.de (192.44.32.1) in ~ftp/incoming/sketchpad. The NESTOR project is described in "Upgrading A Window System For Tutoring Functions", Michael Altenhofen et al., the proceedings of the EXUG Conference 11/90. xmove actually moves a client from one server to another; it is on ftp.cs.columbia.edu in /pub/xmove. [Thanks in part to scott@spectra.com (Tim Scott), 5/91, and to Peter Cigehn (peter@lulea.trab.se), 8/92 ] ---------------------------------------------------------------------- Subject: 99)! Can I use C++ with X11? Motif? XView? The X11R4 and later header files are compatible with C++. The Motif 1.1 header files are usable as is inside extern "C" {...}. However, the definition of String in Intrinsic.h can conflict with the libg++ or other String class and needs to be worked around. Some other projects which can help: WWL, a set of C++ classes by Jean-Daniel Fekete to wrap X Toolkit widgets, available via anonymous FTP from ftp.x.org as contrib/WWL-1.2.tar.Z [7/92] or lri.lri.fr (129.175.15.1) as pub/WWL-1.2.tar.Z. It works by building a set of C++ classes in parallel to the class tree of the widgets. The C++ InterViews toolkit is obtainable via anonymous FTP from interviews.stanford.edu. InterViews uses a box/glue model similar to that of TeX for constructing user interfaces and supports multiple looks on the user interfaces. Some of its sample applications include a WYSIWIG document editor (doc), a MacDraw-like drawing program (idraw) and an interface builder (ibuild). THINGS, a class library written at the Rome Air Force Base by the Strategic Air Command, available as freeware on archive sites. Motif++ is a public-domain library that defines C++ class wrappers for Motif 1.1 and 1.2; it adds an "application" class for, e.g., initializing X, and also integrates WCL and the Xbae widget set. This work was developed by Ronald van Loon based on X++, a set of bindings done by the University of Lowell Graphics Research Laboratory. The current sources are available from decuac.dec.com (192.5.214.1) in /pub/X11/motif++.28.jul.93.tar.gz; in the UK check src.doc.ic.ac.uk. Send to motif++-request@motif.hacktic.nl to be added to the mailing list. Xm++ is a user interface framework for C++ using the Motif and Athena toolkits. Source is on ftp.x.org as contrib/Xm++.0.52.tar.Z; or email to xmplus@ani.univie.ac.at. The Theseus++ User Interface Toolkit Release 2.5.2 is a copylefted C++ user-interface toolkit for X and Motif. Sources are on archimedes.igd.fhg.de in /pub/Theseus++/theseus++-2.5.2. The source code examples for Doug Young's "Object-Oriented Programming with C++ and OSF/Motif" [ISBN 0-13-630252-1] do not include "widget wrappers" but do include a set of classes that encapsulates higher-level facilities commonly needed by Motif- or other Xt-based applications; check ftp.x.org in ~ftp/contrib/young.c++.tar.Z. UIT is a set of C++ classes embedding the XView toolkit; it is intended for use with Sun's OpenWindows Developers Guide 3.0 builder tool. Sources are on ftp.x.org as UIT.tar.Z. Version 2 was released 5/28/92. [Thanks to Douglas S. Rand (dsrand@mitre.org) and George Wu (gwu@tcs.com);2/91] ---------------------------------------------------------------------- Subject: 100) Where can I obtain alternate language bindings to X/Xt/Motif? Versions of the CLX Lisp bindings are part of the X11 core source distributions. A version of CLX is on the R5 tape [10/91]; version 5.0.2 [9/92] is on ftp.x.org in /contrib/CLX.R5.02.tar.Z. The SAIC Ada-X11 bindings are through anonymous ftp in /pub from stars.rosslyn.unisys.com (128.126.164.2) [perhaps falcon.stars.ballston.paramax.com (129.204.6.253)?] There is an X/Ada study team sponsored by NASA JSC, which apparently is working out bindings. Information: xada@ghg.hou.tx.us. GNU SmallTalk has a beta native SmallTalk binding to X called STIX (by Steven.Byrne@Eng.Sun.COM). It is still in its beginning stages, and documentation is sparse outside the SmallTalk code itself. The sources are available as /pub/gnu/smalltalk-1.1.1.tar.Z on prep.ai.mit.edu (18.71.0.38) or ugle.unit.no (129.241.1.97). Prolog bindings (called "XWIP") written by Ted Kim at UCLA while supported in part by DARPA are available by anonymous FTP from ftp.x.org:contrib/xwip.tar.Z or ftp.cs.ucla.edu:pub/xwip.tar.Z. These prolog language bindings depend on having a Quintus-type foreign function interface in your prolog. The developer has gotten it to work with Quintus and SICStus prolog. Inquiries should go to xwip@cs.ucla.edu. [3/90] Scheme bindings to Xlib, OSF/Motif, and Xaw are part of the Elk distribution; version 1.5a on ftp.x.org obsoletes the version on the R5 contrib tape. TCL bindings to Motif 1.[12] by Jan Newmarch (jan@pandonia.canberra.edu.au) are on csc.canberra.edu.au and ftp.x.org. Version 0.8 became available 11/93. x-scm, a bolt-on accessory for Aubrey Jaffer's "scm" Scheme interpreter that provides an interface to Xlib, Motif, and OpenLook, is now available via FTP from altdorf.ai.mit.edu:archive/scm/xscm1.05.tar.Z and nexus.yorku.ca:pub/scheme/new/xscm1.05.tar.Z. Ada bindings to Motif, explicitly, will eventually be made available by the Jet Propulsion Laboratories, probably through the normal electronic means. Advance information can be obtained from dsouleles@dsfvax.jpl.nasa.gov, who may respond as time permits. Also: the MIT Consortium, although not involved in producing Ada bindings for X, maintains a partial listing of people involved in X and Ada; information is available from Donna Converse, converse@x.org. ---------------------------------------------------------------------- Subject: 101) TOPIC: BUILDING THE X DISTRIBUTION [topic needs updating to R6] ---------------------------------------------------------------------- Subject: 102) What's a good source of information on configuring the X build? This FAQ includes information on a number of "gotchas" that can bite you on particular system. However, the best source of general information on building the X11 release is found in the Release Notes. The file is bundled separately from the rest of the release, so if it's become separated from your sources you can FTP another copy separately: the file RELNOTES.[ms,PS,TXT] at the top of the distribution. The file RELNOTES is also available from the xstuff mail server. In addition, O'Reilly & Associates' Volume 8 on X Administration includes information on configuring and building X. ---------------------------------------------------------------------- Subject: 103) Why doesn't my Sun with a cg6 work with R5? Apparently gcc is the problem; it seems to produce fine code for all Sun displays except for the cgsix. The new sunGX.o distributed with fix-07 may fix the problem (note: not known to work on Solaris). ---------------------------------------------------------------------- Subject: 104) Why doesn't my Sun with SunOS 4.1 know about _dlsym, etc.? If you get errors with _dlsym _dlopen _dlclose undefined, link with libdl.a. Add "-ldl" to your and eventually to your site.def. You may want to surround it with "-Bstatic -ldl -Bdynamic" if you add it to the EXTRA_LIBRARIES variable, since "syslibs" get added after EXTRA_LIBRARIES on the eventual compilation command; otherwise you may not have a shared libdl. (Or compile the stubs shared.) [thanks to Joe Backo (joe.backo@East.Sun.COM), 12/91] ---------------------------------------------------------------------- Subject: 105) What is this "_get_wmShellWidgetClass undefined" error? In SunOS 4.1.2 Sun fixed a shared-library bug in ld which conflicts with the way X builds the shared Xmu library, causing these symbols, notably, to be undefined when building some X11 clients on SunOS 4.1.[23]: _get_wmShellWidgetClass _get_applicationShellWidgetClass Compiling "-Bstatic -lXmu -Bdynamic" is overkill; be sure to set OSTeenyVersion correctly in the config/sun.cf file and rebuild X11R5. To solve the problem if you are using OpenWindows 3.0 (X11R4-based Xt), please contact your local Sun office and request the following patches: Patch i.d. Description 100512-02 4.1.x OpenWindows 3.0 libXt Jumbo patch 100573-03 4.1.x OpenWindows 3.0 undefined symbols when using shared libXmu [Greg Earle, earle@Sun.COM; 7/92] A source patch for use with the X11R4 libraries was developed by Conrad Kimball (cek@sdc.boeing.com); it retrofits into R4 some fixes made in R5 to get around this problem. The patch is on ftp.x.org in [1/93] contrib/X11R4_sunos4.1.2_patch_version3.Z ---------------------------------------------------------------------- Subject: 106) What's this problem with undefined _X symbols on SunOS 4.1.3? Make sure to set the OSTeenyVersion in the mit/config/sun.cf file if you see that vast numbers of Xlib functions are undefined: >cc -o bmtoa bmtoa.o -O -pipe -L../.././lib/Xmu -lXmu -L/work1/X11R5/lib >ld: Undefined symbol > _XGetVisualInfo > _XFree ... ---------------------------------------------------------------------- Subject: 107) Why does cc get used when I build X11R5 with gcc? When X11R5 was written gcc (version 1.X) did not support shared libraries. Those parts requiring shared libraries are compiled with cc, those that don't are compiled with gcc. ---------------------------------------------------------------------- Subject: 111) What are these problems compiling the X server on SunOS 4.1.1? The file isn't being found. Sun omitted from SunOS 4.1.1. Remove the #include from sunCG6C.c and replace it with the line #define CG6_VADDR_COLOR 0x70016000 The file has changed from earlier versions of SunOS and should not be copied from another distribution. ---------------------------------------------------------------------- Subject: 113) Can OLIT programs run with R5 Xt? (_XtQString undefined) This is a bug in the OLIT. _XtQString was an external symbol that existed in X11R4 (upon which OW 3.0's libXt is based). It wasn't documented and was removed in X11R5 (MIT's guarantee of upward compatibility between the R4 and R5 libraries only applied to the documented interface). A workaround is to temporarily set your LD_LIBRARY_PATH to point to the X11R4 or OpenWindows Xt library that you linked the program against. [10/92; from Barry Margolin (barmar@think.com); 3/93 from Jeff Francis (jpf@heliocentric.com)] ---------------------------------------------------------------------- Subject: 114)! How do I get around the SunOS 4.1 security hole? There is a security problem with certain R4 clients (xterm and xload) running under SunOS 4.1 that have been installed setuid root and are using shared libraries; to avoid the problem, do one of these: 1) make the program non-setuid. You should consult your system administrator concerning protection of resources (e.g. ptys and /dev/kmem) used by these programs, to make sure that you do not create additional security problems at your site. 2) relink the programs statically (using -Bstatic). 3) install the libraries before linking and link with absolute paths to the libraries. [from rws@x.org (Bob Scheifler), 12/90] Newer versions of xterm (R5/R6) do this automatically by rebuilding xterm against the newly-installed libraries when xterm is being installed; this prevents an suid program from being built with libraries specified relatively. Note that this may cause an inconvenience when doing the installation from NFS-mounted disks. Xload has been rewritten to avoid the problem. ---------------------------------------------------------------------- Subject: 115) How do I get around the frame-buffer security hole? On many systems the frame-buffer is unsecured by default; this permits anyone who can log into your workstation to peek at your windowing session by accessing the frame-buffer directly, or, as less of a privacy issue but perhaps more annoying, to [accidentally] start up a second X session on your console display. Check the man page for fbtab(5). [Thanks to Art Mulder (art@cs.ualberta.ca); 2/93.] ---------------------------------------------------------------------- Subject: 116) TOPIC: BUILDING X PROGRAMS ---------------------------------------------------------------------- Subject: 117)! What is Imake? Imake is not a replacement for the make program; instead, it is a makefile-generator that takes advantages of the include-file and macro- processing capabilities of the C preprocessor cpp to generate makefiles suitable for building software on a particular system. Although it is not specific to X, the X release uses it to help solve a number of the configuration issues that arise in making such a large system widely portable. Imake has a fairly steep learning curve, in part because the process by which the system-specific configuration files, system-independent configuration files, and individual Imakefiles are melded to produce a Makefile is not obvious. There have been several different versions of imake; the R3, R4, R5 and R6 versions are different. You can obtain information on imake from these sources: - - the release notes and imake man page include information on using Imake to build X - The R6 file xc/config/cf/README contains a list of imake variables - the R4 and R5 release notes and imake man page include information on using Imake to build X - the R4 and R5 file mit/config/README also contains useful information - on the R4 tapes, contrib/doc/imake/imake.tex is Mark Moraes' R3/R4 guide to imake. - the R5 mit/doc/config/usenixws/paper.ms contains a paper by Jim Fulton on an early version of Imake - Paul DuBois (dubois@primate.wisc.edu) has written a useful explanation of how Imake works and how to use it in configuring X for non- supported systems; the document is available from ftp.primate.wisc.edu in the directory ~ftp/pub/imake-stuff; look for config-X11R4.ms (troff) and config-X11R4.ps (PostScript). Some supplemental appendices are nearby. [7/91: document version is now 1.06] These imake papers are available by email; mail a message body of "send imake-stuff help" to almanac@primate.wisc.edu. They are also available by gopher to gopher.primate.wisc.edu under "Primate Center Software Archives". - see "System Administration - Imake: Friend or Foe?" by Dinah McNutt in the November 1991 issue of SunExpert. - German readers should expect in June 1992 an article "Das Meta-Make / I make, you make / Schwerelos" by Rainer Klute in "iX Multiuser-Multitasking-Magazin", directed at application programmers needing to write Imakefiles. An English-language derivative of this article is in The X Journal, issue 2:1. - The O'Reilly X Resource issue #2 contains Paul Davey's article on demystifying Imake. - Alain Brossard's working document full of tips on Imake is in sasun1.epfl.ch:pub/imakefile.1.Z. - O'Reilly has published (7/93) "Software Portability with imake" by Paul DuBois; ISBN 1-56592-055-4. The books electronic examples and additional software are on ftp.primate.wisc.edu in pub/imake-book; imake.tar.Z is a stand-alone imake installation. [1/91;12/91;5/92;8/92;7/93] ---------------------------------------------------------------------- Subject: 118)! Where can I get imake? Versions are distributed with the R4, R5, and R6 releases. An earlier version is distributed with the X11R3 release; some third-party toolkits redistribute versions of imake along with their own implementations of the template and configuration files. There are no real standards for such configuration files, although most *current* contributed software expects the templates distributed with X11R5. ftp.x.org contains the R5 distribution unpacked, so you can pick up imake without picking up the entire distribution. A stand-alone version of Imake, but one stemming from X11R5, is in ftp.germany.eu.net:pub/X11/misc/imake/imake-pure.tar.Z (192.76.144.75). A stand-alone version of Imake, but one stemming from X11R5, is in ftp.primate.wisc.edu:pub/imake-book/imake.tar.Z. ---------------------------------------------------------------------- Subject: 119)! I have a program with an Imakefile but no Makefile. What to do? If you have R4 or later installed on your system, run "xmkmf". This is a script which runs imake for you with the correct arguments. The output is a Makefile configured for your system and based on the Imakefile. Then run make, which will use that new Makefile to compile the program. ---------------------------------------------------------------------- Subject: 120) Why can't I link to the Xlib shape routines? When I try to compile certain programs, I get the following link error: Undefined: _XShapeQueryExtension _XShapeCombineMask These routines are actually part of the Shape Extension to X (SHAPE) which was introduced in the X11R4 distribution and allows non-rectangular windows. Like the other sample server extensions, the shape extension will only run on a server which supports it. Pre-X11R4 servers, as well as many vendor-supplied servers, do not support the shape extension, in which case they will display rectangular windows anyway. In order to use the shape extension, you must link to the library libXext.a. In the X11R4 distribution, this library and the associated includes will be in the mit/extensions directory. If you do not have these files, do not despair: many freeware programs which use the shape extension can also be compiled without it by removing the -DSHAPE define from the Makefile; you can probably do this and compile successfully against your older vendor-supplied X libraries. [from John B. Melby, melby%yk.fujitsu.co.jp@uunet.uu.net, 3/91] ---------------------------------------------------------------------- Subject: 122) TOPIC: PROGRAMMING PROBLEMS AND PUZZLES ---------------------------------------------------------------------- Subject: 123) Why doesn't my program get the keystrokes I select for (sic)? The window manager controls how the input focus is transferred from one window to another. In order to get keystrokes, your program must ask the window manager for the input focus. To do this, you must set up what are called "hints" for the window manager. If your applications is Xlib-based, you can use something like the following: XWMHints wmhints; ... wmhints.flags = InputHint; wmhints.input = True; XSetWMHints(dpy, window, &wmhints) If your application is based on the Xt Intrinsics, you can set the XtNinput resource to be True (as you probably want to in any case); if you don't have source, you can start up the application with the resource '*input:True'. Certain window managers, notably dxwm and olwm, are very picky about having this done. If you are using Sun's OpenWindows olwm, you can also add this resource to your defaults file to use clients that aren't ICCCM-compliant. OpenWindows.FocusLenience: true [mostly courtesy Dave Lemke of NCD and Stuart Marks of Sun] ---------------------------------------------------------------------- Subject: 124) How do I deiconify a window? To de-iconify a window, map it with XMapWindow(). To iconify a window, use XIconifyWindow(). ---------------------------------------------------------------------- Subject: 125) How do I figure out what window manager is running? You can't reliably tell; whatever mechanism you could use could be spoofed in any case. For most cases, you shouldn't care which window manager is running, so long as you do things in an ICCCM-conformant manner. There are some cases in which particular window managers are known to do things wrong; checking for particular hints placed on the window by the window manager so that you can sidestep the problem may be appropriate in these cases. Alternatively, it may be appropriate to determine which window manager is running in order to take advantage of specific *added* features (such as olwm's push-pin menus) in order to give your program *added* functionality. Beware of usurping the window manager's functions by providing that functionality even when it is missing; this surely leads to future compatibility problems. ---------------------------------------------------------------------- Subject: 126) Is there a skeleton X program available? There is no general framework such as the TransSkel program for the Macintosh which handles lots of the odds and ends and overhead of development under a window system and which can be used as a platform for additional development. In X, the problem is typically solved by using an interactive application builder tool or by using cut&paste on existing X applications. Good applications which you might look to manipulate when you want to "test just this one little thing" include contrib/clients/xskel, a simple R4 program that puts up a window and allows sketching in it and offers a starting point for quick hacks, the Xaw examples in the examples/ directory in the R3 and R4 distributions, and the Xlib "Hello World" example in the R3 doc/HelloWorld and R4 doc/tutorials/HelloWorld; an updated version of this program which uses R4 Xlib calls and current ICCCM conventions was posted in 2/90 to comp.windows.x by Glenn Widener of Tektronix. [3/90] In addition, a sample Xt program (for Xaw or Xm) by Rainer Klute showing how to open multiple displays and how to catch a broken display connection is available on ftp.x.org in contrib/mdisp.tar.Z. [4/92] A sample multi-display Xt/Xaw program by Oliver Jones is on ftp.x.org in contrib/MultiUserVote.tar.Z. (See also his article in The X Resource, Issue 3, "Multi-User Application Software Using Xt".) ---------------------------------------------------------------------- Subject: 127) Why does XtGetValues not work for me (sic)? The XtGetValues interface for retrieving resources from a widget is sensitive to the type of variable. Your code may be doing something like this: { Arg args[3]; int i; int sensitive; /* oops; wrong data type */ i=0; XtSetArg (args[i], XtNsensitive, &sensitive); i++; XtGetValues(widget, args, i ); ... } But XtNsensitive is a Boolean, which on most machines is a single byte; declaring the variable "sensitive" as Boolean works properly. This problem comes up often when using particular toolkits that redefine the Xt types Dimension and Position; code that assumes they are int will have similar problems if those types are actually short. In general: you are safe if you use the actual type of the resource, as it appears in the widget's man page. [11/90] ---------------------------------------------------------------------- Subject: 128) Why don't XtConfigureWidget/XtResizeWidget/XtMoveWidget work? You're probably trying to use these functions from application code. They should be used only internally to widgets; these functions are for a parent Composite widget to change the geometry of its children. An application which calls XtMoveWidget, for example, effectively defeats geometry negotiation and the Composite parent's internal state (if any) will no longer be correct. (The Xt specification goes into more detail.) The only way for your application to request a geometry change for a widget is to issue an XtSetValues call setting some of the geometry resources. Although this call will result in the widget-internal functions' being called, your application code must use the standard XtSetValues interface or risk the widgets' data becoming corrupted. Note that functions defined in , as these are, are typically reserved for use by widgets. Other promising functions, XtMakeGeometryRequest() and XtMakeResizeRequest(), are also for use only by widgets, in this case by a child to request a change from its parent. The Xlib calls XMoveWindow() and XResizeWindow() should similarly be avoided; they shouldn't be used to change XtNx, XtNy, XtNwidth, or XtNheight. ---------------------------------------------------------------------- Subject: 129) Why isn't there an XtReparentWidget call like XReparentWindow? Although there are various details of the current implementation of the Xt internals which make reparenting difficult, the major reason that no such call exists is that it remains undefined what the set of resources for the "new" widget should be. Resources are typically set based on the location in the instance hierarchy; what resources should change if the instance moves? What should happen to the widget's children? And by the time such semantics are defined, there would probably be little advantage over destroying the old widget and creating a new widget in the correct location with the desired resources, as setting the resources correctly is the majority of work in creating a new widget. Note that reparenting is possible in the OI toolkit. ---------------------------------------------------------------------- Subject: 130) I'm writing a widget and can't use a float as a resource value. Float resources are not portable; the size of the value may be larger than the size of an XtPointer. Try using a pointer to a float instead; the Xaw Scrollbar float resources are handled in this way. ---------------------------------------------------------------------- Subject: 133) Why does the process size of my X programs go up,up,up? Using "ps" may not show any decrease in memory size after a malloc/free pair. With most vendors' implementations of memory managers, the call to free does not return memory to the operating system; it is probably maintained on a free list for the process. In addition, ps may not be an accurate report of current memory usage requirements. ---------------------------------------------------------------------- Subject: 134) Are callbacks guaranteed to be called in the order registered? Although some books demonstrate that the current implementation of Xt happens to call callback procedures in the order in which they are registered, the specification does not guarantee such a sequence, and supplemental authoritative documents (i.e. the Asente/Swick volume) do say that the order is undefined. Because the callback list can be manipulated by both the widget and the application, Xt cannot guarantee the order of execution. In general, the callback procedures should be thought of as operating independently of one another and should not depend on side-effects of other callbacks operating; if a seqence is needed, then the single callback to be registered can explicitly call other functions necessary. [4/92; thanks to converse@x.org] ---------------------------------------------------------------------- Subject: 135) Why doesn't XtDestroyWidget() actually destroy the widget? XtDestroyWidget() operates in two passes, in order to avoid leaving dangling data structures; the function-call marks the widget, which is not actually destroyed until your program returns to its event-loop. ---------------------------------------------------------------------- Subject: 136) How do I query the user synchronously using Xt? It is possible to have code which looks like this trivial callback, which has a clear flow of control. The calls to AskUser() block until answer is set to one of the valid values. If it is not a "yes" answer, the code drops out of the callback and back to an event-processing loop: void quit(Widget w, XtPointer client, XtPointer call) { int answer; answer = AskUser(w, "Really Quit?"); if (RET_YES == answer) { answer = AskUser(w, "Are You Really Positive?"); if (RET_YES == answer) exit(0); } } A more realistic example might ask whether to create a file or whether to overwrite it. This is accomplished by entering a second event-processing loop and waiting until the user answers the question; the answer is returned to the calling function. That function AskUser() looks something like this, where the Motif can be replaced with widget-set-specific code to create some sort of dialog-box displaying the question string and buttons for "OK", "Cancel" and "Help" or equivalents: int AskUser(w, string) Widget w; char *string; { int answer=RET_NONE; /* some not-used marker */ Widget dialog; /* could cache&carry, but ...*/ Arg args[3]; int n = 0; XtAppContext context; n=0; XtSetArg(args[n], XmNmessageString, XmStringCreateLtoR(string, XmSTRING_DEFAULT_CHARSET)); n++; XtSetArg(args[n], XmNdialogStyle, XmDIALOG_APPLICATION_MODAL); n++; dialog = XmCreateQuestionDialog(XtParent(w), string, args, n); XtAddCallback(dialog, XmNokCallback, response, &answer); XtAddCallback(dialog, XmNcancelCallback, response, &answer); XtAddCallback(dialog, XmNhelpCallback, response, &answer); XtManageChild(dialog); context = XtWidgetToApplicationContext (w); while (answer == RET_NONE || XtAppPending(context)) { XtAppProcessEvent (context, XtIMAll); } XtDestroyWidget(dialog); /* blow away the dialog box and shell */ return answer; } The dialog supports three buttons, which are set to call the same function when tickled by the user. The variable answer is set when the user finally selects one of those choices: void response(w, client, call) Widget w; XtPointer client; XtPointer call; { int *answer = (int *) client; XmAnyCallbackStruct *reason = (XmAnyCallbackStruct *) call; switch (reason->reason) { case XmCR_OK: *answer = RET_YES; /* some #define value */ break; case XmCR_CANCEL: *answer = RET_NO; break; case XmCR_HELP: *answer = RET_HELP; break; default: return; } } and the code unwraps back to the point at which an answer was needed and continues from there. [Thanks to Dan Heller (argv@sun.com); note that the code in his book caches the dialog but neglects to make sure that the callbacks point to the current automatic "answer".] ---------------------------------------------------------------------- Subject: 137) How do I determine the name of an existing widget? I have a widget ID and need to know what the name of that widget is. Users of R4 and later are best off using the XtName() function, which will work on both widgets and non-widget objects. ---------------------------------------------------------------------- Subject: 138) Why do I get a BadDrawable error drawing to XtWindow(widget)? I'm doing this in order to get a window into which I can do Xlib graphics within my Xt-based program: > canvas = XtCreateManagedWidget ( ...,widgetClass,...) /* drawing area */ > ... > window = XtWindow(canvas); /* get the window associated with the widget */ > ... > XDrawLine (...,window,...); /* produces error */ The window associated with the widget is created as a part of the realization of the widget. Using a window id of None ("no window") could create the error that you describe. It is necessary to call XtRealizeWidget() before attempting to use the window associated with a widget. Note that the window will be created after the XtRealizeWidget() call, but that the server may not have actually mapped it yet, so you should also wait for an Expose event on the window before drawing into it. ---------------------------------------------------------------------- Subject: 139) Where can I get documentation on Xaw, the Athena widget set? Check ftp.x.org in /pub/R5untarred/mit/hardcopy for the originals of documentation distributed with X11R5. In R6, see xc/doc/specs/Xaw or xc/doc/hardcopy/Xaw. ---------------------------------------------------------------------- Subject: 140) What's the difference between actions and callbacks? Actions and callbacks may be closely tied; the user may click a mouse-button in an object's window, causing an action procedure in that particular object to be called. As part of its processing of the event, the action procedure may inform the application via a callback registered on the object. However, callbacks can be given for any reason, including some that don't arise as a result of user action; and many actions don't result in any notification to the application. Callbacks generally are a means of interaction between the user interface (UI) and some other piece of code interested in the "results"; the interested party to which the data is communicated is usually the application's back-end functions but may be another widget in a related part of the UI. For example, a text widget invokes a callback to say "the user just entered this text string; never mind what I had to do to get it or what X events took place." In object-oriented programming terminology, callback lists are messages defined by the widget class by which the widget istance notifies another entity that something significant has happened to the widget. Actions, however, constitute a widget's repertoire of internal i/o behaviors. Actions are not about results; actions are about "how", not "what" gets done. The text widget may define a dozen or two actions which define how the user can manipulate the text; the procedures for removing a line of text or switching two words can be associated with particular X event sequences (and in fact often rely on particular types of events). Actions are (in OOP terminology) methods of the widget class by which the widget responds to some external stimulus (one or more X events). To avoid confusing yourself on the issue of actions vs. callbacks, try thinking of actions defined by an application as methods *of the application* -- applications may define actions, as well -- by which the application responds to one or more X events (and happens to be handed an object handle as part of the method argument list). Similarly, callback handlers registered by an application with a widget can be thought of as methods of the application which respond to messages from a widget or widgets. [Thanks to Michael Johnson (michael@maine.maine.edu) and to Kerry Kimbrough] ---------------------------------------------------------------------- Subject: 141) How do I simulate a button press/release event for a widget? You can do this using XSendEvent(); it's likely that you're not setting the window field in the event, which Xt needs in order to match to the widget which should receive the event. If you're sending events to your own application, then you can use XtDispatchEvent() instead. This is more efficient than XSendEvent() in that you avoid a round-trip to the server. Depending on how well the widget was written, you may be able to call its action procedures in order to get the effects you want. [courtesy Mark A. Horstman (mh2620@sarek.sbc.com), 11/90] ---------------------------------------------------------------------- Subject: 142) Can I make Xt or Xlib calls from a signal handler? No. Xlib and Xt have no mutual exclusion for protecting critical sections. If your signal handler makes such a call at the wrong time (which might be while the function you are calling is already executing), it can leave the library in an inconsistent state. Note that the ANSI C standard points out that behavior of a signal handler is undefined if the signal handler calls any function other than signal() itself, so this is not a problem specific to Xlib and Xt; the POSIX specification mentions other functions which may be called safely but it may not be assumed that these functions are called by Xlib or Xt functions. You can work around the problem by setting a flag in the interrupt handler and later checking it with a work procedure or a timer event which has previously been added. R6 Xt will have support for signal handlers; there will be a mechanism to set a flag in a signal handler and XtAppNextEvent will notice that the flag has been set, and call the associated callbacks. Note: the article in The X Journal 1:4 and the example in old editions of O'Reilly Volume 6 are in error. [Thanks to Pete Ware (ware@cis.ohio-state.edu) and Donna Converse (converse@x.org), 5/92] An alternate solution is to create a pipe and add the read side of the pipe as an input event with XtAppAddInput; then write a byte to the write side of the pipe with your signal handler (write is re-entrant). The callback for the read side of the pipe reads the byte and does the actual processing that you intended. You may want the byte to be the signal number unless your callback handles only one kind. [Thanks to Steve Kappel (stevek@apertus.com)] ---------------------------------------------------------------------- Subject: 143) What are these "Xlib sequence lost" errors? You may see these errors if you issue Xlib requests from an Xlib error handler, or, more likely, if you make calls which generate X requests to Xt or Xlib from a signal handler, which you shouldn't be doing in any case. ---------------------------------------------------------------------- Subject: 144) How can my Xt program handle socket, pipe, or file input? It's very common to need to write an Xt program that can accept input both from a user via the X connection and from some other file descriptor, but which operates efficiently and without blocking on either the X connection or the other file descriptor. A solution is use XtAppAddInput(). After you open your file descriptor, use XtAppAddInput() to register an input handler. The input handler will be called every time there is something on the file descriptor requiring your program's attention. Write the input handler like you would any other Xt callback, so it does its work quickly and returns. It is important to use only non-blocking I/O system calls in your input handlers. Most input handlers read the file descriptor, although you can have an input handler write or handle exception conditions if you wish. Be careful when you register an input handler to read from a disk file. You will find that the function is called even when there isn't input pending. XtAppAddInput() is actually working as it is supposed to. The input handler is called whenever the file descriptor is READY to be read, not only when there is new data to be read. A disk file (unlike a pipe or socket) is almost always ready to be read, however, if only because you can spin back to the beginning and read data you've read before. The result is that your function will almost always be called every time around XtAppMainLoop(). There is a way to get the type of interaction you are expecting; add this line to the beginning of your function to test whether there is new data: if (ioctl(fd, FIONREAD, &n) == -1 || n == 0) return; But, because this is called frequently, your application is effectively in a busy-wait; you may be better off not using XtAppAddInput() and instead setting a timer and in the timer procedure checking the file for input. [courtesy Dan Heller (argv@ora.com), 8/90; mouse@larry.mcrcim.mcgill.edu 5/91; Ollie Jones (oj@pictel.com) 6/92] There are two alternatives: the simple one is to use XtAppAddTimeout instead of XtAppAddInput and check for input occasionally; the more complex solution, and perhaps the better one, is to popen or fork&exec a child which does blocking reads on the file, relaying what it has read to your application via a pipe or a socket. XtAppAddInput will work as expected on pipes and sockets. [Thanks to Kaleb Keithley (kaleb@x.org); 12/93] ---------------------------------------------------------------------- Subject: 145) Why do I get a BadMatch error when calling XGetImage? The BadMatch error can occur if the specified rectangle goes off the edge of the screen. If you don't want to catch the error and deal with it, you can take the following steps to avoid the error: 1) Make a pixmap the same size as the rectangle you want to capture. 2) Clear the pixmap to background using XFillRectangle. 3) Use XCopyArea to copy the window to the pixmap. 4) If you get a NoExpose event, the copy was clean. Use XGetImage to grab the image from the pixmap. 5) If you get one or more GraphicsExpose events, the copy wasn't clean, and the x/y/width/height members of the GraphicsExpose event structures tell you the parts of the pixmap which aren't good. 6) Get rid of the pixmap; it probably takes a lot of memory. [10/92; thanks to Oliver Jones (oj@pictel.com)] ---------------------------------------------------------------------- Subject: 146) How can my application tell if it is being run under X? A number of programs offer X modes but otherwise run in a straight character-only mode. The easiest way for an application to determine that it is running on an X display is to attempt to open a connection to the X server: display = XOpenDisplay(display_name); if (display) { do X stuff } else { do curses or something else } where display_name is either the string specified on the command-line following -display, by convention, or otherwise is (char*)NULL [in which case XOpenDisplay uses the value of $DISPLAY, if set]. This is superior to simply checking for the existence a -display command-line argument or checking for $DISPLAY set in the environment, neither of which is adequate. [5/91] ---------------------------------------------------------------------- Subject: 147) How do I make a "busy cursor" while my application is computing? Is it necessary to call XDefineCursor() for every window in my application? The easiest thing to do is to create a single InputOnly window that is as large as the largest possible screen; make it a child of your toplevel window (which must be realized) and it will be clipped to that window, so it won't affect any other application. (It needs to be as big as the largest possible screen in case the user enlarges the window while it is busy or moves elsewhere within a virtual desktop.) Substitute "toplevel" with your top-most widget here (similar code should work for Xlib-only applications; just use your top Window): unsigned long valuemask; XSetWindowAttributes attributes; /* Ignore device events while the busy cursor is displayed. */ valuemask = CWDontPropagate | CWCursor; attributes.do_not_propagate_mask = (KeyPressMask | KeyReleaseMask | ButtonPressMask | ButtonReleaseMask | PointerMotionMask); attributes.cursor = XCreateFontCursor(XtDisplay(toplevel), XC_watch); /* The window will be as big as the display screen, and clipped by its own parent window, so we never have to worry about resizing */ XCreateWindow(XtDisplay(toplevel), XtWindow(toplevel), 0, 0, 65535, 65535, (unsigned int) 0, 0, InputOnly, CopyFromParent, valuemask, &attributes); where the maximum size above could be replaced by the real size of the screen, particularly to avoid servers which have problems with windows larger than 32767. When you want to use this busy cursor, map and raise this window; to go back to normal, unmap it. This will automatically keep you from getting extra mouse events; depending on precisely how the window manager works, it may or may not have a similar effect on keystrokes as well. In addition, note also that most of the Xaw widgets support an XtNcursor resource which can be temporarily reset, should you merely wish to change the cursor without blocking pointer events. [thanks to Andrew Wason (aw@cellar.bae.bellcore.com), Dan Heller (argv@sun.com), and mouse@larry.mcrcim.mcgill.edu; 11/90,5/91] ---------------------------------------------------------------------- Subject: 148) How do I fork without hanging my parent X program? An X-based application which spawns off other Unix processes which continue to run after it is closed typically does not vanish until all of its children are terminated; the children inherit from the parent the open X connection to the display. What you need to do is fork; then, immediately, in the child process, close (ConnectionNumber(XtDisplay(widget))); to close the file-descriptor in the display information. After this do your exec. You will then be able to exit the parent. Alternatively, before exec'ing make this call, which causes the file descriptor to be closed on exec. (void) fcntl(ConnectionNumber(XDisplay), F_SETFD, 1); [Thanks to Janet Anstett (anstettj@tramp.Colorado.EDU), Gordon Freedman (gjf00@duts.ccc.amdahl.com); 2/91. Greg Holmberg (holmberg@frame.com), 3/93.] ---------------------------------------------------------------------- Subject: 149) Why doesn't anything appear when I run this simple program? > ... > the_window = XCreateSimpleWindow(the_display, > root_window,size_hints.x,size_hints.y, > size_hints.width,size_hints.height,BORDER_WIDTH, > BlackPixel(the_display,the_screen), > WhitePixel(the_display,the_screen)); > ... > XSelectInput(the_display,the_window,ExposureMask|ButtonPressMask| > ButtonReleaseMask); > XMapWindow(the_display,the_window); > ... > XDrawLine(the_display,the_window,the_GC,5,5,100,100); > ... You are right to map the window before drawing into it. However, the window is not ready to be drawn into until it actually appears on the screen -- until your application receives an Expose event. Drawing done before that will generally not appear. You'll see code like this in many programs; this code would appear after the window was created and mapped: while (!done) { XNextEvent(the_display,&the_event); switch (the_event.type) { case Expose: /* On expose events, redraw */ XDrawLine(the_display,the_window,the_GC,5,5,100,100); break; ... } } Note that there is a second problem: some Xlib implementations don't set up the default graphics context to have correct foreground/background colors, so this program could previously include this code: ... the_GC_values.foreground=BlackPixel(the_display,the_screen); /* e.g. */ the_GC_values.background=WhitePixel(the_display,the_screen); /* e.g. */ the_GC = XCreateGC(the_display,the_window, GCForeground|GCBackground,&the_GC_values); ... Note: the code uses BlackPixel and WhitePixel to avoid assuming that 1 is black and 0 is white or vice-versa. The relationship between pixels 0 and 1 and the colors black and white is implementation-dependent. They may be reversed, or they may not even correspond to black and white at all. Also note that actually using BlackPixel and WhitePixel is usually the wrong thing to do in a finished program, as it ignores the user's preference for foreground and background. And also note that you can run into the same situation in an Xt-based program if you draw into the XtWindow(w) right after it has been realized; it may not yet have appeared. ---------------------------------------------------------------------- Subject: 150) What is the difference between a Screen and a screen? The 'Screen' is an Xlib structure which includes the information about one of the monitors or virtual monitors which a single X display supports. A server can support several independent screens. They are numbered unix:0.0, unix:0.1, unix:0.2, etc; the 'screen' or 'screen_number' is the second digit -- the 0, 1, 2 which can be thought of as an index into the array of available Screens on this particular Display connection. The macros which you can use to obtain information about the particular Screen on which your application is running typically have two forms -- one which takes a Screen and one with takes both the Display and the screen_number. In Xt-based programs, you typically use XtScreen(widget) to determine the Screen on which your application is running, if it uses a single screen. (Part of the confusion may arise from the fact that some of the macros which return characteristics of the Screen have "Display" in the names -- XDisplayWidth, XDisplayHeight, etc.) ---------------------------------------------------------------------- Subject: 151) Can XGetWindowAttributes get a window's background pixel/pixmap? No. Once set, the background pixel or pixmap of a window cannot be re-read by clients. The reason for this is that a client can create a pixmap, set it to be the background pixmap of a window, and then free the pixmap. The window keeps this background, but the pixmap itself is destroyed. If you're sure a window has a background pixel (not a pixmap), you can use XClearArea() to clear a region to the background color and then use XGetImage() to read back that pixel. However, this action alters the contents of the window, and it suffers from race conditions with exposures. [courtesy Dave Lemke of NCD and Stuart Marks of Sun] Note that the same applies to the border pixel/pixmap. This is a (mis)feature of the protocol which allows the server is free to manipulate the pixel/pixmap however it wants. By not requiring the server to keep the original pixel or pixmap, some (potentially a lot of) space can be saved. [courtesy Jim Fulton, then of X Consortium] ---------------------------------------------------------------------- Subject: 152) How do I create a transparent window? A completely transparent window is easy to get -- use an InputOnly window. In order to create a window which is *mostly* transparent, you have several choices: - the SHAPE extension first released with X11R4 offers an easy way to make non-rectangular windows, so you can set the shape of the window to fit the areas where the window should be nontransparent; however, not all servers support the extension. - a machine-specific method of implementing transparent windows for particular servers is to use an overlay plane supported by the hardware. Note that there is no X notion of a "transparent color index". - a generally portable solution is to use a large number of tiny windows, but this makes operating on the application as a unit difficult. - a final answer is to consider whether you really need a transparent window or if you would be satisfied with being able to overlay your application window with information; if so, you can draw into separate bitplanes in colors that will appear properly. [thanks to der Mouse, mouse@lightning.McRCIM.McGill.EDU, 3/92; see also The X Journal 1:4 for a more complete answer, including code samples for this last option] ---------------------------------------------------------------------- Subject: 153) Why doesn't GXxor produce mathematically-correct color values? When using GXxor you may expect that drawing with a value of black on a background of black, for example, should produce white. However, the drawing operation does not work on RGB values but on colormap indices. The color that the resulting colormap index actually points to is undefined and visually random unless you have actually filled it in yourself. [On many X servers Black and White often 0/1 or 1/0; programs taking advantage of this mathematical coincidence will break.] If you want to be combining colors with GXxor, then you should be allocating a number of your own color cells and filling them with your chosen pre-computed values. If you want to use GXxor simply to switch between two colors, then you can take the shortcut of setting the background color in the GC (graphics context) to 0 and the foreground color to a value such that when it draws over red, say, the result is blue, and when it draws over blue the result is red. This foreground value is itself the XOR of the colormap indices of red and blue. [Thanks to Chris Flatters (cflatter@zia.aoc.nrao.EDU) and Ken Whaley (whaley@spectre.pa.dec.com), 2/91] ---------------------------------------------------------------------- Subject: 154) Why does every color I allocate show up as black? Make sure you're using 16 bits and not 8. The red, green, and blue fields of an XColor structure are scaled so that 0 is nothing and 65535 is full-blast. If you forget to scale (using, for example, 0-255 for each color) the XAllocColor function will perform correctly but the resulting color is usually black. [Thanks to Paul Asente, asente@adobe.com, 7/91] ---------------------------------------------------------------------- Subject: 155) Why do I get a protocol error when creating a cursor (sic)? You may have had this code working on a monochrome system by coincidence. Cursor pixmaps must always have a depth of 1; when you create the cursor pixmap use the depth of 1 rather than the default depth of the screen. ---------------------------------------------------------------------- Subject: 156) Why can't my program get a standard colormap? I have an image-processing program which uses XGetRGBColormap() to get the standard colormap, but it doesn't work. XGetRGBColormap() when used with the property XA_RGB_DEFAULT_MAP does not create a standard colormap -- it just returns one if one already exists. Use xstdcmap or do what it does in order to create the standard colormap first. [1/91; from der Mouse (mouse@larry.mcrcim.mcgill.edu)] ---------------------------------------------------------------------- Subject: 157) Why does the pixmap I copy to the screen show up as garbage? The initial contents of pixmaps are undefined. This means that most servers will allocate the memory and leave around whatever happens to be there -- which is usually garbage. You probably want to clear the pixmap first using XFillRectangle() with a function of GXcopy and a foreground pixel of whatever color you want as your background (or 0L if you are using the pixmap as a mask). [courtesy Dave Lemke of NCD and Stuart Marks of Sun] ---------------------------------------------------------------------- Subject: 158)! How can I most quickly send an image to the X server? The fastest mechanism may be to use an XImage and the shared-memory extension to reduce the transmission time. The MIT-SHM code, documentation, and example client programs can be found on the X11R5 source tape; many vendors also support the extension. If bandwidth is a problem, the X Image Extension has facilities for transmitting compressed images. ---------------------------------------------------------------------- Subject: 159) How do I check whether a window ID is valid? My program has the ID of a window on a remote display. I want to check whether the window exists before doing anything with it. Because X is asynchronous, there isn't a guarantee that the window would still exist between the time that you got the ID and the time you sent an event to the window or otherwise manipulated it. What you should do is send the event without checking, but install an error handler to catch any BadWindow errors, which would indicate that the window no longer exists. This scheme will work except on the [rare] occasion that the original window has been destroyed and its ID reallocated to another window. You can use this scheme to make a function which checks the validity of a window; you can make this operation almost synchronous by calling XSync() after the request, although there is still no guarantee that the window will exist after the result (unless the sterver is grabbed). On the whole, catching the error rather than pre-checking is preferable. [courtesy Ken Lee (klee@synoptics.com), 4/90; 12/93] ---------------------------------------------------------------------- Subject: 160)! Can I have two applications draw to the same window? Yes. The X server assigns IDs to windows and other resources (actually, the server assigns some bits, the client others), and any application that knows the ID can manipulate the resource [almost any X server resource, except for GCs and private color cells, can be shared]. The problem you face is how to disseminate the window ID to multiple applications. A simple way to handle this (and which solves the problem of the applications' running on different machines) is in the first application to create a specially-named property on the root-window and put the window ID into it. The second application then retrieves the property, whose name it also knows, and then can draw whatever it wants into the window. [Note: this scheme works iff there is only one instance of the first application running, and the scheme is subject to the limitations mentioned in the Question about using window IDs on remote displays.] Note also that you will still need to coordinate any higher-level cooperation among your applications; you may find the Synchronization extension in R6 useful for this. Note also that two processes can share a window but should not try to use the same server connection. If one process is a child of the other, it should close down the connection to the server and open its own connection. Note also that Display IDs and GC values describe addresses local to an application and cannot be transmitted to another application; note also that if you are using Xt you may not share widget IDs, which are local to the client. Note also that several clients may draw to a window but for particular X events such as button-presses only one client can receive the event. [mostly courtesy Phil Karlton (karlton@wpd.sgi.com) 6/90] ---------------------------------------------------------------------- Subject: 161)! Why can't my program work with tvtwm or swm? A number of applications, including xwd, xwininfo, and xsetroot, do not handle the virtual root window which tvtwm and swm use; they typically return the wrong child of root. A general solution is to add this code or to use it in your own application where you would normally use RootWindow(dpy,screen): /* Function Name: GetVRoot * Description: Gets the root window, even if it's a virtual root * Arguments: the display and the screen * Returns: the root window for the client */ #include Window GetVRoot(dpy, scr) Display *dpy; int scr; { Window rootReturn, parentReturn, *children; unsigned int numChildren; Window root = RootWindow(dpy, scr); Atom __SWM_VROOT = None; int i; __SWM_VROOT = XInternAtom(dpy, "__SWM_VROOT", False); XQueryTree(dpy, root, &rootReturn, &parentReturn, &children, &numChildren); for (i = 0; i < numChildren; i++) { Atom actual_type; int actual_format; long nitems, bytesafter; Window *newRoot = NULL; if (XGetWindowProperty(dpy, children[i], __SWM_VROOT, 0, 1, False, XA_WINDOW, &actual_type, &actual_format, &nitems, &bytesafter, (unsigned char **) &newRoot) == Success && newRoot) { root = *newRoot; break; } } XFree((char *)children); return root; } [courtesy David Elliott (dce@smsc.sony.com). Similar code is in ssetroot, a version of xsetroot distributed with tvtwm. 2/91] A header file by Andreas Stolcke of ICSI on ftp.x.org:contrib/vroot.h functions similarly by providing macros for RootWindow and DefaultRootWindow; code can include this header file first to run properly in the presence of a virtual desktop. (Note the possible race condition.) ---------------------------------------------------------------------- Subject: 162) Can I rely on a server which offers backing store? You can assume only that the X server has the capability of doing backing store and that it might do so and keep your application's visuals up-to-date without your program's involvement; however, the X server can run out of resources at any time, so you must be able to handle the exposure events yourself. You cannot rely on a server which offers backing store to maintain your windows' contents on your behalf. ---------------------------------------------------------------------- Subject: 163) How do I catch the "close window" event to avoid "fatal IO error"? Several windows managers offer a function such as f.kill or f.delete which sends a message to the application that it should delete its window; this is usually interpreted as a shutdown message. The application needs to catch the WM_DELETE_WINDOW client message. There is a good example in the xcalc sources in X11R5. Motif-based applications should in addition set the resource XmNdeleteResponse on the top-level shell to XmDO_NOTHING, whether they are using the Motif window manager or not. If the application doesn't handle this message the window manager may wind up calling XKillClient, which disconnects the client from the display and typically gives an Xlib error along the lines of "fatal IO error 32 (Broken pipe)". [Thanks to Kaleb Keithley, kaleb@x.org; 11/93] ---------------------------------------------------------------------- Subject: 164) How do I keep a window from being resized by the user? Resizing the window is done through the window manager; window managers can pay attention to the size hints your application places on the window, but there is no guarantee that the window manager will listen. You can try setting the minimum and maximum size hints to your target size and hope for the best. Note that you may wish to reconsider your justification for this restriction. ---------------------------------------------------------------------- Subject: 165) How do I keep a window in the foreground at all times? It's rather antisocial for an application to constantly raise itself [e.g. by tracking VisibilityNotify events] so that it isn't overlapped -- imagine the conflict between two such programs running. The only sure way to have your window appear on the top of the stack is to make the window override-redirect; this means that you are temporarily assuming window-management duties while the window is up, so you want to do this infrequently and then only for short periods of time (e.g. for popup menus or other short parameter-setting windows). [thanks to der Mouse (mouse@larry.mcrcim.mcgill.edu); 7/92] ---------------------------------------------------------------------- Subject: 166) How do I make text and bitmaps blink in X? There is no easy way. Unless you're willing to depend on some sort of extension (as yet non-existent), you have to arrange for the blinking yourself, either by redrawing the contents periodically or, if possible, by playing games with the colormap and changing the color of the contents. [Thanks to mouse@larry.mcrcim.mcgill.edu (der Mouse), 7/91] ---------------------------------------------------------------------- Subject: 167) How do I get a double-click in Xlib? Users of Xt have the support of the translation manager to help get notification of double-clicking. There is no good way to get only a double-click in Xlib, because the protocol does not provide enough support to do double-clicks. You have to do client-side timeouts, unless the single-click action is such that you can defer actually taking it until you next see an event from the server. Thus, you have to do timeouts, which means system-dependent code. On most UNIXish implementations, you can use XConnectionNumber to get the file descriptor of the X connection and then use select() or something similar on that. Note that many user-interface references suggest that a double-click be used to extend the action indicated by a single-click; if this is the case in your interface then you can execute the first action and as a compromise check the timestamp on the second event to determine whether it, too, should be the single-click action or the double-click action. [Thanks to mouse@larry.mcrcim.mcgill.edu (der Mouse), 4/93] ---------------------------------------------------------------------- Subject: 168)! How do I render rotated text? The X Logical Font Description was enhanced for R6 to allow embedding a transformation matrix in certain fields of an XLFD name. Thus arbitrary rotation, scaling, shearing, etc. are possible. To draw text along an arbitrarily sloped line, open a font with the appropriate rotation transformation and individually place and draw each character. Drawing text along a curve requires a different font for each character orientation needed. The overhead of opening so many fonts is somewhat mitigated by another XLFD extension which allows you to ask for a subset of the characters. See section 4 of xc/doc/specs/XLFD/xlfd.tbl.ms in the R6 distribution. Also see The X Resource, Issue Nine, p. 211, "New Font Technology for X11R6," Nathan Meyers. (Note: due to changes after publication deadline, the information in the Meyers paper about the syntax of character set subsetting is out of date.) These capabilities are also available to an R5 X server using an R6 font server. If you are not using R6, your only choice, if you want to stay within the core X protocol, is to render the text into a pixmap, read it back via XGetImage(), rotate it "by hand" with whatever matrices you want, and put it back to the server via XPutImage(); more specifically: Your only choice, if you want to stay within the core X protocol, is to render the text into a pixmap, read it back via XGetImage(), rotate it "by hand" with whatever matrices you want, and put it back to the server via XPutImage(); more specifically: 1) create a bitmap B and write your text to it. 2) create an XYBitmap image I from B (via XGetImage). 3) create an XYBitmap Image I2 big enough to handle the transformation. 4) for each x,y in I2, I2(x,y) = I(a,b) where a = x * cos(theta) - y * sin(theta) b = x * sin(theta) + y * cos(theta) 5) render I2 Note that you should be careful how you implement this not to lose bits; an algorithm based on shear transformations may in fact be better. The high-level server-extensions and graphics packages available for X also permit rendering of rotated text: Display PostScript, PEX, PHiGS, and GKS, although most are not capable of arbitrary rotation and probably do not use the same fonts that would be found on a printer. In addition, if you have enough access to the server to install a font on it, you can create a font which consists of letters rotated at some predefined angle. Your application can then itself figure out placement of each glyph. [courtesy der Mouse (mouse@larry.mcrcim.mcgill.edu), Eric Taylor (etaylor@wilkins.bmc.tmc.edu), and Ken Lee (klee@synoptics.com), 11/90; Liam Quin (lee@sq.com), 12/90; Dave Wiggins (dpw@x.org), 5/94.] InterViews (C++ UI toolkit, in the X contrib software) has support for rendering rotated fonts in X. It could be one source of example code. [Brian R. Smith (brsmith@cs.umn.edu), 3/91] Another possibility is to use the Hershey Fonts; they are stroke-rendered and can be used by X by converting them into XDrawLine requests. [eric@pencom.com, 10/91] The xrotfont program by Alan Richardson (mppa3@syma.sussex.ac.uk) (posted to comp.sources.x July 14 1992) paints a rotated font by implementing the method above and by using an outline (Hershey) font. The xvertext package by Alan Richardson (mppa3@syma.sussex.ac.uk) is a set of functions to facilitate the writing of text at any angle. It is on ftp.x.org as contrib/xvertext.5.0.shar.Z. O'Reilly's X Resource Issue 3 includes information from HP about modifications to the X fonts server which provide for rotated and scaled text. The modifications are on ftp.x.org in contrib/hp_xlfd_enhancements. ---------------------------------------------------------------------- Subject: 169)! Why doesn't my multi-threaded X program work (sic) ? Support in Xlib and Xt for multi-threaded X programs is included in X11R6. See the documentation for XInitThreads, XtToolkitThreadInitialize, section 2.7 of the Xlib specification, section 7.12 of the Xt specification, and the article "Multi-Threaded Xlib," The X Resource, Issue 5, by Stephen Gildea. The following discussion applies only to pre-R6 libraries: You cannot use non-thread aware, non-reentrant libraries with threads. If you must do this, you have only one choice: call the functions from the initial thread only. Why opening windows from other threads causes protocol errors can be explained easily: you are accessing shared resources (the display structure, the connection to the display, static data in the Xlib) from a number of threads at the same time, without using any form of exclusive access control. [Thanks to casper@fwi.uva.nl (Casper H.S. Dik)] ---------------------------------------------------------------------- Subject: 170) What is the X Registry? (How do I reserve names?) There are places in the X Toolkit, in applications, and in the X protocol that define and use string names. The context is such that conflicts are possible if different components use the same name for different things. The X Consortium maintains a registry of names in these domains: orgainization names, selection names, selection targets, resource types, application classes, and class extension record types; and several others. The list as of April 1994 is in the file xc/registry in the R6 distribution. The current Registry is also available by sending "send docs registry" to the xstuff mail server. To register names (first come, first served) or to ask questions send to xregistry@x.org; be sure to include a postal address for confirmation. [11/90; condensed from Asente/Swick Appendix H; 1/94] ---------------------------------------------------------------------- David B. Lewis faq%craft@uunet.uu.net "Just the FAQs, ma'am." -- Joe Friday