--- xterm-229.orig/debian/README +++ xterm-229/debian/README @@ -0,0 +1,96 @@ +$Id$ + +This file attempts to explain some of the oddities of the xterm Debian +source package by describing the files and directories not usually found in +a (debhelperized) source package. + +This package uses quilt to manage patches. A basic description of how to use +this is below. + +Interesting targets supported by the debian/rules file include: + debian/rules setup Unpacks and patches the source. + debian/rules patch-audit Unpacks and patches the source, and + verifies that there are no offsets or + fuzz in the patches. If you are + contributing a patch, please verify that + this target works before submitting it; + it can save the package maintainers a + considerable amount of time. + debian/rules clean Unpatches the source and removes stampdir, + build-tree, and various patch-related items + debian/rules patch Patches the source with all patches + debian/rules unpatch Unpatches the source with all patches + debian/rules prepare Sets up the directory so you can begin + editing patches. VERY IMPORTANT. + +Editing and creating patches: + The first thing you need to do is become familiar with the basics of quilt. + It comes with a pdf tutorial in /usr/share/doc/quilt as well as an excellent + manpage. + + To start, you should be in the top level directory, containing the debian + directory and the xc directory. First, run debian/rules prepare. This will + set up the proper symlinks so that quilt can find the patches it needs to + apply. Once this is done, you will see a symlink named "patches" that will + point to debian/patches. This is because quilt expects the patches directory + to be located at the top level by default. It will set up a ".pc" link as + well, which quilt uses internally to store info (this is why you'll want to + use debian/rules clean to clean up, rather than just rm -rf'ing what you see, + the hidden .pc is easy to forget). It will also create a stampdir that is + used to store stamps so debian/rules knows what its done, as well as logs. + + Now that the directory is set up, you're going to want to do your thing. + Let's start with editing a patch. You'll want to run "quilt push + yourpatchname.diff". You're going to want to make your edits now. If you're + editing a file that wasn't previously included in the patch, be sure to let + quilt know you're doing it by using "quilt add" or "quilt edit". If you're + not sure if you need this, you can run "quilt files" to see if your file is + already in there, or "quilt patches filename" to see if the current patch + edits the specified file. Once you're done editing, run "quilt refresh" to + update your patch. All documentation in the patch header will be retained by + quilt automatically. If you have made a serious edit, you may want to + document it in the header of the patch. + + Alternately, you could be creating a new patch. As above, you'll want to set + up the tree by running debian/rules prepare. You need to decide where your + patch belongs according to the number series specified below. Once you do + this, run "quilt push patch-before-yours" specifying the patch that will be + the last one applied before your new patch. Then run "quilt new patchname" + using the name of the patch (including the appropriate number). Make your + edits to the files. As described above, you'll want to be sure quilt knows + which files you are editing. When you are finished, run "quilt refresh -u -p + 0". This will create a unified diff patch with a strip number of 0. You + should then go in to the patches directory and document your patch. + + You may have a patch that you stole from some other source that you just want + to apply and you don't want to deal with adding files by hand. You can use + "quilt import -n internal-patch-name file-name" where the internal-patch-name + is what you want to call your patch. You'll want to push the patch before + yours, as described above, before doing the import, in order to make sure it + applies in the right sequence. + + Once you're all done with patch work, you'll want to run debian/rules clean + to get rid of the things that had to be set up. + +patches: + Directory containing patches applied in ASCIIbetical order. + numeric prefix indicates disposition of patch + 000 patches FROM upstream + + 001-899 patches that should be sent upstream + + 001-099 general-purpose patches + 100-199 architecture-specific patches + 800-899 OS flavour patches + + 900-999 patches that should not be sent upstream + + 900-998 Debian-specific behavior and enhancements + 999 experimental or debugging patches (should not + generally be present in a production release) + +local: + This contains Debian-specific programs and documentation that we include + in our xterm binary packages; for instance, our UTF-8 wrapper. + +vim:set ai et sw=2 ts=2 tw=80: --- xterm-229.orig/debian/changelog +++ xterm-229/debian/changelog @@ -0,0 +1,775 @@ +xterm (229-1) unstable; urgency=low + + * Fix typo in uxterm(1) (LP: #128136). + * New upstream release + + undo an incorrect fix for a memory leak in patch #209 + (closes: #435858). + * Stop installing the .desktop files and adapt xterm.menu to the new menu + structure. + * Use a separate build dir. + * Build with -Wall. + + -- Julien Cristau Mon, 13 Aug 2007 16:10:01 +0200 + +xterm (228-1) unstable; urgency=low + + [ Julien Cristau ] + * New upstream release + + fix missing assignment for UTF-8 parsing in widget initialization + (closes: #403360). + + correct index expression used to set line-wrapping flag, making + selection from scrollback work consistently (closes: #430121). + * Refresh 901_xterm_manpage.diff. + + [ Brice Goglin ] + * Fix debian/rules to not be confused by ~/.quiltrc or QUILT_PATCHES, + closes: #369920. + + -- Julien Cristau Mon, 23 Jul 2007 03:43:32 +0200 + +xterm (226-1) unstable; urgency=low + + [ Branden Robinson ] + * Remove debian/NEWS; the events it attested to (like the "upcoming 7.0 + modularization" are no longer news, and are in the past. + + [ Julien Cristau ] + * Configure with --with-tty-group=tty, to prevent security problems in case + of buggy build environment (closes: #349142). + * New upstream release. + + fix an infinite loop when showing a 2-column character in a + 1-column screen (closes: #426863). + + add XF86Paste and SunPaste to the default translations + (closes: #422521, patch by Bernhard R Link). + + improve permissions logic when closing pseudo-terminal + (closes: #12261, patch by Nathanael Nerode, analysis by Richard + Braakman). + + add a check in case someone tries to call the popup-menu() action + on a menu which is not initialized (closes: #426364). + + fix error-checking on internal font switching for "Selection" menu + entry (closes: #421523). + + amend select/paste change from patch #225 by limiting it to + non-UTF-8/non-KOI8-R encoding (closes: #420974). + + add workaround for groff ".URL" codes which are not present in + some commonly-used bitmap fonts (closes: #418324). + * Update reference to xlibs-data in xterm's description, refer to xbitmaps + instead. + * Build-depend on desktop-file-utils to install the new desktop files for + xterm and uxterm, and change debian/rules and debian/xterm.install to + install these files and the icons. + + -- Julien Cristau Mon, 18 Jun 2007 14:02:22 +0100 + +xterm (225-1) unstable; urgency=low + + * New upstream release. + + add initialFont resource to xterm widget, like tek-widget + (closes: #299669). + + amend change to boldMode from patch #223 for Debian #347790 which made + xterm no longer match the documented behavior (closes: #412599). + * Update and complete debian/copyright. + + -- Julien Cristau Sun, 25 Mar 2007 19:18:41 +0200 + +xterm (224-1) unstable; urgency=low + + * New upstream release. + + fix build for GNU/KFreeBSD (closes: #404111). + + undo a comparison in handle_translated_exposure which did not work + due to X server optimization. That caused the inner border to be + repainted with unexpected colors when handling a repaint, e.g., + after switching to/from another workspace (closes: #401726). + + allow -cr option to override cursor color when -ah option is used + (closes: #406502). + + add a note in xterm's manpage explaining that the -bw (or -w) + option is only used by the window manager, if at all + (closes: #405043). + * Refresh patch 901_xterm_manpage.diff. + * Change my email address in debian/control. + + -- Julien Cristau Mon, 12 Feb 2007 00:14:06 +0100 + +xterm (223-2) unstable; urgency=low + + * No longer disable allowWindowOps in XTerm.ad, as commands are now + sanitized by xterm (closes: #402917). + + -- Julien Cristau Thu, 14 Dec 2006 17:29:30 +0100 + +xterm (223-1) unstable; urgency=low + + [ Julien Cristau ] + * New upstream release. Includes the following fixes for bugs reported in + the Debian BTS: + + add the Xaw scrollbar translations resource to the xterm manpage, add an + example showing how to change the mouse button assignments + (closes: #382225). + + amend cell-width computation for FreeType from patch #217, which did not + work for VT100 line-drawing characters (closes: #399638). + + revert an optimisation in SGR_Foreground() and SGR_Background from patch + #209 (closes: #347722). + + fixes to make the internalBorder area not change color due to + reverseVideo and/or related exposure events. The latter was a very old + bug exposed in patch #196 (closes: #397624). + * The fix for #347790 is now included upstream. + + -- David Nusinow Mon, 4 Dec 2006 19:27:21 -0500 + +xterm (222-3) unstable; urgency=low + + [ Julien Cristau ] + * Split xterm.doc-base in xterm.doc-base.faq and xterm.doc-base.ctlseqs, to + make the package installable again, thanks to Ryan Murray + (closes: #400375). + + -- David Nusinow Sat, 25 Nov 2006 18:37:22 -0500 + +xterm (222-2) unstable; urgency=low + + [ Julien Cristau ] + * Install all manpages with "1" as extension instead of "1x" + (closes: #346377). + * Use the x-terminal-emulator.1.gz slave alternative, instead of + x-terminal-emulator.1x.gz. We also need to clean up the mess this wrong + path caused, and make sure that the x-terminal-emulator.1.gz link in + /usr/share/man/man1/ is still there. If it disappeared, we add it in + postinst. Thanks to Vincent Lefevre and Joey Hess (closes: #349462). + * Also add the changelog entry for xterm 208-3.1, so that the BTS doesn't + consider bugs reported against that version as "from other Branch". + The changes from this NMU have been obsoleted by 210-2. + * Add patch 903 by Tim Pope to not ignore the + boldmode setting. Thanks to Joey Hess for reporting + this issue and to Thomas Dickey for his comments (closes: #347790). + + [ Branden Robinson ] + * Ship "Xterm Control Sequences" document again, in both GNU Roff and plain + text formats, and register the latter with doc-base. (The former is + easily viewable in a terminal with "groff -Tutf8 ctlseqs.ms | more", so it + seems useful.) (Closes: #301173) + * Update copy of XTerm FAQ to revision 1.90 (dated 2005-11-02). + * Resync koi8rxterm script with recent upstream changes to uxterm, upon + which it is based. + + -- David Nusinow Sat, 25 Nov 2006 12:25:29 -0500 + +xterm (222-1) unstable; urgency=low + + * New upstream release + + Refresh patches. + * Acknowledge NMU (thanks, Christoph!). + * Update KOI8RXTerm app-defaults, thanks to Thomas Dickey (closes: #384925). + * Configure with --enable-luit, again thanks to Thomas (closes: #381591). + * Add an empty binary-indep target in debian/rules, thanks to Aurélien Jarno + (closes: #395764). + * Add myself to Uploaders. + * Bump Standards-Version to 3.7.2. + * Use "make distclean" instead of "make clean" so that configure-generated + files are deleted. + + -- Julien Cristau Sun, 5 Nov 2006 14:49:08 +0100 + +xterm (210-3.1) unstable; urgency=high + + * Non-maintainer upload. + * Apply patch by Samuel Thibault to disable allowWindowOps in XTerm.ad + (Closes: #384593). + + -- Christoph Berg Fri, 15 Sep 2006 16:18:06 +0200 + +xterm (210-3) unstable; urgency=low + + * Depend on xbitmaps rather than xlibs-data. + + -- David Nusinow Thu, 13 Apr 2006 00:20:50 -0400 + +xterm (210-2) unstable; urgency=low + + * Remove useless provides and conflicts with old xutils. Thanks James Troup. + + -- David Nusinow Thu, 16 Mar 2006 20:05:08 -0500 + +xterm (210-1) unstable; urgency=low + + * New upstream release (the following are fixes immediately relevant to + Debian. More are in the upstream changelog) + + allow cursor to have the same color as foreground (text), since it is + rendered as reverse (closes: #350664) + + add TIOCSCTTY ioctl() ifdef'd for __GNU__ to set the controlling + terminal (closes: #348457) + + typo in manpage (closes: #351425) + + revert the XTerm.ad change from patch #208 (closes: #348384) + + add check to ensure that double-clicking to extend selection will not + extend it into the scrollback area. This still allows users to scroll + back and select text (closes: #347415) + * Remove the 01_stolen_from_HEAD patch, as it is now obsolete + * Switch build dependency from libxaw8-dev to libxaw7-dev + * debian/rules clean target now calls make clean instead of distclean + * Use dh_install's --list-missing option + * Merge duplicate Provides fields + + -- David Nusinow Mon, 13 Mar 2006 22:12:41 -0500 + +xterm (208-3.1) unstable; urgency=low + + * Emergency NMU to fix queue/accepted breakage: s/Provides/Replaces/ + + -- Adam Conrad Thu, 19 Jan 2006 04:41:26 +1100 + +xterm (208-3) unstable; urgency=low + + * Install everything in /usr/bin, /etc/X11/app-defaults, and + /usr/share/man/man1. This gives us back the resize program. + (closes: #345477, #348615, #347553) + * Add conflicts and replaces to xutils < 6.9.0.dfsg.1 + + -- David Nusinow Tue, 17 Jan 2006 21:24:01 -0500 + +xterm (208-2) unstable; urgency=low + + * Added 000_stolen_from_HEAD.diff, with last minute changes from Thomas + Dickey: + - fix typo in configure script option --disable-narrowproto. + - Amend CF_X_FREETYPE changes for pkg-config check to ensure that Xft is + known to that tool. + - Add an ifdef to allow ./configure --disable-active-icon to work, broken + by new code for testing memory leaks in #208. + * Added --disable-imake and --enable-narrowproto to configure line in order + to deal with toolbar problems due to the absence of NARROWPROTO definition + (closes: 346398). + + -- David Martínez Moreno Mon, 9 Jan 2006 08:21:41 +0100 + +xterm (208-1) unstable; urgency=low + + * New upstream release (patchlevel #208). Main changes follow: + - Implement logic in termcap query to process multiple parameters as + documented in ctlseqs.ms + - Fix buffer size used for termcap query, which was not long enough for + the terminfo "colors" name. + - Add menu entry (alt-esc) and corresponding action (alt-sends-esc) to + toggle the eightBitInput resource setting. + - Modify computation of rows/columns on resize to avoid extending beyond + the given limits, e.g., if resizing in response to a "maximize" in + Gnome or KDE which do not use the window manager hints for this case + (closes: #289123). + - Improve error-reporting when chown/chmod of the pseudo-terminal fails. + - Several changes in the control sequences. + - Improvements in the configure script. + - Eliminate a retry for a better-matching bold font, to work around + recent font server changes. + - Specify weight for wide font which may be derived from normal + fontname. + - Cache the derived wide- and widebolt- fontnames. + - Modify resource files to make the font-resources a little more specific, + e.g., changing "*VT100*" to "*VT100.", to make the distinction between + VT100.font and VT100.utf8Fonts.font sharper, in case a packager modifies + one of those. + - Expanded comments in UXTerm.ad regarding the font resources (closes: + #319179). + - Add --enable-narrowproto configure option to accommodate Xorg "modular" + build. + - Add scrollBarBorder resource. + - Fix a file-descriptor leak when calling openpty(). + - A hard reset also resets the 132/80 mode. + - Restore window manager hints after XtMakeResizeRequest() calls. + - Scroll-down is allowed to be sent while mouse tracking is enabled. + - Correct size-comparison in HandleInterpret() broken in changes from + patch #201 to allocate input buffer (closes: #334317). + - Upstream merged Debian patches 001 and 002 for typos in xterm. + - Added setuid options. + - add charClass resource to XTerm.ad and UXTerm.ad which simplifies + selecting URLs + - make -iconic option work with toolbar configuration + - fix memory reallocation for the "UTF-8" menu entry when xterm is started + using the +u8 option + * Debian patches 900 and 901 resynced. + * Clean up xterm.dirs a bit + * Explicitly call --with-app-defaults (set to /etc/X11/app-defaults) during + configure + + -- David Nusinow Fri, 6 Jan 2006 00:23:38 -0500 + +xterm (204-0pre1) experimental; urgency=low + + * The xterm package has been splitted from the upstream X.Org tree, in + advance of the upcoming modularization in X.Org 7.0. + * First release to experimental, in order to test if the transition has been + successful. + * Credit is given to X Strike Force for their good work over these years, + keeping a bunch of old entries from current X.Org changelog. + * Most of the corresponding code has been imported from the X.Org packages. + Obviously, debian/rules has been revamped and simplified. + * New upstream release (patchlevel #204). + - The mere existence of independent packages for xterm eases the + identification (i.e. xterm's version). Thus it closes: #324352. Also + added a patch to version.h in the meanwhile to override the "X.Org + 6.8.2" string in the configure script. + - Work around quirk in shell which allowed user to "run" uxterm script + when there was no UTF-8 locale installed by entering "sh -x uxterm". + Also popup an xmessage to show the problem for users who run this via a + GUI (closes: #318513). + - Disallow changes to fonts, toolbar and scrollbar when the vt100 window + is iconified, to simplify management of the active icon. + - Fixes to make -geom option work properly with the toolbar configuration + (Gentoo Bugzilla #90717, #91967). + - Minor improvements to scrollbar layout. + - Improve initialization due to utf8 resource by loading the utf8Fonts + resource in the case where locale resource is false. Also in this case, + do not disable switching UTF-8 mode on/off. + - Minor optimization of TrueType font-loading. Load italic font only + when needed. + - Correct variable used to store temporary result from lookup of bold + font, when initializing the wide-bold-font data and no immediate match + is found by asking for a bold variant of the wide-font. The result was + to use overstriking rather than the actual bold font (this is the fix + for #318162, patch by Eugene Konev). + - Modify initialization of allowSendEvents and allowWindowOps to prevent + modification with the editres protocol. + - Add support for interpreting the underline attribute as an italic font + in Xft mode (patch by Chuck Blake). + - Improve initialization of toolbar. + - Fix logic in find_utmp, which did not reset result in getutid(), + causing an infinite loop in some conditions. + - Set the _NET_WM_PID property. + - Change default values for minBufSize and maxBufSize to 4096 and 32768 + respectively so that the initial read request will match the value from + before changes to use sched_yield(). + - Make paste of UTF-8 faster for Western character sets by checking range + of incoming data. + - Added experimental option to allow applications to get or set the + selection data. + - Fix an off-by-one error parsing -S/nn option (closes: #311438, thanks to + Peter Chubb). + - Fix an initialization bug from patch #201 that broke logging. + - Amend change to command-line processing in patch #201 to avoid conflict + with -e option (closes: #318280). + * debian/control: Removed Conflicts with xbase << 3.3.3.2whatever, and + suidmanager << 0.50. They are not even in Sarge. + * The patch structure is basicly the same as in X.Org. The corresponding + patches from X.Org patch tree have been extracted. Added a change in the + .TH field of the manpage in order to shut up lintian. + * Added --enable-256-color to configure (closes: #305540). + * Moved away things from /usr/X11R6/ to /usr, now that we are free of + imake's shackles. As a bonus, it removes several lintian warnings. Renamed + things in debian/xterm.{postinst,prerm}. + * Added an override file for lintian warning about setgid in xterm. + * The postinst script is now fixed, and it points to correct manpages + (closes: #315195). + + -- David Martínez Moreno Mon, 3 Oct 2005 12:04:44 +0200 + +xorg-x11 (6.8.2.dfsg.1-4) unstable; urgency=low + + Changes by David Nusinow: + + - Remove README.DGA from xserver-xorg.docs.m68k, mips, mipsel, and arm to + fix FTBFS. + - Resolve MANIFEST.mips to fix FTBFS + - Add missing docs to xserver-xorg.docs.mipsel + - Incorporate patch from HEAD to include more radeon PCI ID's. Thanks, + Harald Welte. Closes: #318948. + - Make the build not fail on MANIFEST check. If there are discrepancies, + I'd rather have a mostly complete X package than a failure on some + arches. The failure diff will still be spit out, allowing us to fix the + problems. + + Changes by Eugene Konev: + + - Update 030_libvgahw_gcc4_volatile_fix.diff to include a complete fix. + Closes: #318218. + + Changes by David Martínez Moreno + + - Fix xlibmesa-dri.bug.script to attach correct log files + + -- David Nusinow Mon, 18 Jul 2005 09:34:07 -0400 + +xorg-x11 (6.8.2.dfsg.1-3) unstable; urgency=low + + Changes by David Nusinow: + + - Change reference to xlibglu1-xorg-dbg to libglu1-xorg-dbg in + debian/rules (thanks Steve Langasek) + - Update MANIFEST.in, and missing items to be installed for alpha, arm, + and m68k + - Fix incorrect C++ ABI transition. libglu1-xorg is implemented in C++ + but only exports a C ABI, so transitioning it is unnecessary. The + package now provides both libglu1 and libglu1c2. Thanks to Marcelo + Magallon and Steve Langasek. + - Refer to correct config file in xserver-xorg.bug.script (thanks David + Martínez Moreno) + - Add 030_libvgahw_gcc4_volatile_fix.diff to work around libvgahw.a gcc4 + breakages. Thanks David Martínez Moreno and Paul Hampson. + Closes: #318218, #318231, #318271, #318405, #318430 + - dexconf fix for 3 button mouse emulation. Thanks David Martínez Moreno; + Closes: #318092 + - Turn on SELinux support in xdm. Thanks Manoj Srivastava; Closes: #317024 + - Add libselinux1-dev to Build-Depends + - Update Danish debconf translations. Thanks to Claus Hindsgaul; + Closes: #318227 + - Update Czech debconf translations. Thanks to Miroslav Kure; + Closes: #318323 + - Update Portuguese (Brazilian) debconf translations. Thanks to Andre + Luis Lopes; Closes: #318635 + - Update German debconf translations. Thanks to Alwin Meschede; + Closes: #318721 + + * Changes by Daniel Stone: + - Fix S/390 build by bringing MANIFEST and *.install.s390 files up to + date. + - Let Xdmx build on S/390 as well. Move xdmx.install.* files to + xdmx.install, since they were identical for each architecture. + - Bring MANIFEST.mips{,el}.in up to date. + - Bring xserver-xorg.install.{alpha,mips{,el}} up to date. + - Fix mysterious breakage in the SPARC build by fixing its MANIFEST good + and proper. + - Drop libstdc++6-dev dependency entirely, since build-essential will + bring that in. Also drop libc6-dev dependency. Closes: #318353 + + Changes by Eugene Konev: + + - Add patch 002a_xterm_no_overstrike_bold_fonts.diff to fix xterm bold + fonts ugliness; Closes: #318162 + + -- David Nusinow Tue, 12 Jul 2005 16:52:39 -0400 + +xorg-x11 (6.8.2.dfsg.1-2) unstable; urgency=low + + Changes by David Nusinow: + + - Change x-window-system to depend on xprint + - Change 009 patch to refer to xprint instead of xprt-xprintorg + + - Run debian/rules update-po to update translation templates + + - Drop versioned dependency on libstdc++ + + - Update debian/NEWS with a few things + + - Update xlibs-static-dev package description with libXprint* libs (thanks + Nathanael Nerode) + + - Add 104_sparc_no_mv8_flag.diff to fix a build problem on sparc (thanks + Julien Cristau) + + Changes by Daniel Stone: + + - Fix FTBFS by only forcing BuildXprintLib building when we're not + BuildingServersOnly (i.e. only in the normal build, not in -dbg). + - Change NOT_BUILDING_XFREE86_X_SERVER to _XORG_ in vars.s390 (fixes FTBFS + also). + - Add 000_stolen_from_drm.diff from Ubuntu, with annotations, which fixes + FTBFS when using linux-libc-headers. + + -- David Nusinow Mon, 11 Jul 2005 20:47:31 -0400 + +xorg-x11 (6.8.2.dfsg.1-1) unstable; urgency=low + + Changes by David Nusinow: + + - Add missing comma to Build-Depends in debian/control. Thanks to Eugene + Konev for catching this! + + - Change x-common to x11-common in order to reflect that this package + provides symlinks named x11 + + - Add -f to update-rc.d call in xfree86-common.postinst.in to get rid of + error during configure stage. Thanks to Norbert Tretowski for providing + the fix. + + - Disable acceleration on C&T 69000 by default but allow it to be overrided + by config file. Thanks to Dan Christensen and Nathanael Nerode; + Closes: #315315 + + - Remove svn comments from debian/local xpm pixmaps to unbreak xdm. Thanks + to Eugene Konev. + + - Disable xprt. Thanks to Eugene Konev! + - Change x-window-system to depend on xprt-xprintorg (thanks to Drew + Parsons); Closes: #300974 + + - Change debian/po/POTFILES.in to use x11-common templates, not + xorg-common.templates. Thanks to Eugene Konev + + - Pull the following from Ubuntu Breezy patches to allow gcc4 builds + - 024d_radeon_fix_gcc4_build.diff (to which I incorporated a one-line fix + from the 024a_radeon_benh_fixes.diff patch) + - 991_ubuntu_gcc_flags.diff + + - Package name changes for the C++ ABI transition: (Thanks to Eugene Konev, + Steve Langasek, and Daniel Stone) + - xlibmesa-glu renamed to libglu1-xorg; Provides: changed to + libglu1c2, libglu1c2 added to the Conflicts: and Replaces: + - libglu1-xorg shlibs changed to libglu1-xorg | libglu1c2 + - xlibmesa-glu-dbg renamed to libglu1-xorg-dbg; xlibmesa-glu-dbg + added to Conflicts: and Replaces: + - xlibmesa-glu-dev renamed to libglu1-xorg-dev; depend on + libglu1-xorg instead of xlibmesa-glu, of course, and add + xlibmesa-glu-dev to the Conflicts/Replaces/Provides + - Update x-window-system-core to depend on libglu1-xorg instead of + xlibmesa-glu + - Update x-window-system-dev to depend on libglu1-xorg-{dev,dbg} + instead of xlibmesa-glu-{dev,dbg} + - Drop the xlibmesa3, xlibmesa3-dbg, and xlibmesa-dev transition + packages; these existed for the woody->sarge transition, and they + can't possibly provide a proper transition for anything that + relies on the C++ ABI, so better to get rid of them altogether + - Rename all xlibmesa-glu package files accordingly + + - Remove libglu1-xorg-dev's dependency on "libstdc++5-3.3-dev | + libstdc++-dev": this doesn't actually ensure that the correct C++ + headers are installed, and it's no longer the correct libstdc++ + version anyway. + + - Add patch 915_disable_i915_debugging.diff, to disable non-x86 debug + statements for this chip. Thanks to Aaron M. Ucko + + - Patch Audit + - 0000_backport_from_upstream.diff updated + - Thomas Winischhofer's post-6.8.2 fixes to MiscPassMessage(); + Closes: #285807 + - 000_backport_from_author_xterm.diff ported (Nathanael Nerode) + - Closes: #297430, #296592, #298551 + - 002_xdm_fixes.diff updated (Eugene Konev) + - 003b_xfs_fixes.diff ported (Eugene Konev, Nathanael Nerode) + - 005_rgb.txt_in_etc_X11.diff updated (Nathanael Nerode) + - 008_fix_xgetpw_macro.diff updated (Eugene Konev) + - 011_SECURITY_makedepend_safer.diff (Nathanael Nerode) + - 011a_recognize_glibc_2.3.2_locale_names.diff (Nathanael Nerode) + - 013a_xkb_symbols_euro_support.diff added (Eugene Konev) + - 019_iso8859-15_Compose_fix.diff updated (Eugene Konev) + - 043_ati_r128_update_chip_identification.diff added (Nathanael Nerode) + - 047_mga_manpage_updates.diff updated + - 055_lnx_evdev_keyboard.diff updated + - 067_fix_X11_and_xdm_build_problems.diff ported (Eugene Konev) + - 089_xkb_fix_symbols_pc_lt.diff got ID tags back + - 093_xkb_fix_macintosh_problems.diff got macintosh equal key fix ported + - 099e_xorgconf_manpage_overhaul.diff ported + - 099h_mesa_tdfx_load_right_glide_library.diff patched to use + libglide_h3/5 as used in unstable packages. + - 099q_tdfx_improve_mode_rejection_diagnostics.diff added + - 099q_xkb_tr_fix_eacute.diff removed + - 099r_xlsfonts_do_not_spew_usage_on_connection_error.diff added + - 099s_selinux_support.diff ported + - 099s_xkb_tr_fix_eacute.diff added + - 099t_xkb_remove_hidden_attributes.diff ported + - 099u_mkdirhier_rewrite.diff ported (Eugene Konev, Nathanael Nerode) + - 099v_fontserver_fix_SEGV.diff ported + - 099x_xdm_support_logfile_rotation.diff ported + - 250_m68k_build_scanpci.diff updated + - 304_arm_Xlib.h_kludge_around_ARM_ABI_brain_damage.diff ported + - 910_debian_Xserver_RTFF.diff updated + - 913_debian_remove_code_ref_to_object_code_files.diff ported + - patch to xc/programs/Xserver/hw/xfree86/drivers/rendition/vboard.c + re-added to comply with post-sarge SC + + -- David Nusinow Fri, 24 Jun 2005 10:24:48 -0400 + +xorg-x11 (6.8.2.dfsg.1-0pre1v1) experimental; urgency=low + + Changes by David Nusinow: + + - Updated packaging to be based off Ubuntu hoary packaging + - Merge changelog from Ubuntu hoary package to this changelog + - Change instances of "Ubuntu" to "Debian" in control file + - Add Daniel Stone to list of Debian package authors in copyright for + his work on this package. Update branding in general in this file. + - Update shell-lib.sh to merge changes from current xfree tree + - Change twm manpage to be set to twm.1x rather than twm.1, as in the + xfree packaging + - Re-brand XFree86 to X.Org in README + - Re-add usr/X11R6/lib/X11/fonts/encodings/large/jisx0208.1983-0.enc.gz + to xfonts-base.install + - Merge xfree tree xfree86-common.init in to xorg-common.init + - Comment out lsb stuff for now, since Debian can't guarantee it. + Replace logging with echo's like in xfree script. + - Re-add Branden's copyright to xfs.init + - Merge changes from xfree tree in to xserver-common.config.in + - Merge changes from xfree tree to scripts directory: + - manifest-install-reconcile + - validate-posix-sh + - Merge changes from xfree86 tree to local directory: + - dexconf + - dexconf.1 + - FAQ.xhtml + - Fix a freedesktop.org reference to X.Org + - xterm.faq.html + - xvfb-run + - xdm/Xstartup + - Xsession.d/30xorg-common_xresources + - xdm.init + - xdm.logrotate + - xdm.README.Debian + + - Re-add jisx0208.1983-0.enc.gz to MANIFEST.all's list of font encodings + until I know more about why it was removed. + + - Re-add the following to MANIFEST.[arch] and xdm.install + - etc/X11/xdm/Xreset + + - Re-enable various modules for xlibmesa-dri-dbg.install + - i810 and tdfx for amd64 . Apparently these were supposed to be + re-enabled according to the changelog + - i830 and ffb for i386 + - ffb, i810, and i830 for ia64 + - Re-enable various modules for xlibmesa-dri.install + - i810 for amd64 + - ffb and i830 for i386 + - ffb, i810, and i830 for ia64 + + - Handle xlibs-static package split + - Add libxvmc-dev.install.hurd-i386 file which removes + usr/X11R6/lib/libI810XvMC.a. Removing + xlibs-static-dev.install.hurd-386. + - Add libxxf86vm-dev.install.s390 file which removes manpages. Removing + xlibs-static-dev.install.s390. + - Removing xlibs-static-pic-install.[hurd-i386,netbsd-i386,s390] as the + files which they specifically removed in the past don't appear to be + shipped any more. + + - Merge and edit control file to refer to XSF + + - Fixes in local + - Spelling fix in dexconf.1 + - Spelling fix and merge updates in to FAQ.xhtml + - Merge update to lxterm, uxterm.1, xdm.options.5, XF86Config.7, + xfs.options.5, Xsession.5, Xsession.options.5, Xwrapper.config.5 + - Re-added Xreset script in local/xdm + + - Branding edit and merges to debian/rules + + - Patch Audit + - Edited 0000_backport_from_upstream.diff + - Removed redundant patches that are also in 000_stolen_from_HEAD.diff + - Edited 000_stolen_from_HEAD.diff + - Re-diffed Xpm's create.c fix to get it to apply properly + - Edited 002_xdm_fixes.diff, 003_linux.cf_and_xfree86.cf.diff, and + 068_fix_InstallAppDefFiles_screwage.diff to allow them to apply + properly with no fuzz + + * Update FAQ to refer to X.Org instead of freedesktop.org where appropriate. + (Closes: #309811) + + * Change xorg-common to x-common + + * Update lsb-base version requirement to 3.0-1 + + Changes by Branden Robinson: + + * Initial release, based upon upstream CVS tag XORG-6_8_2. See + debian/copyright for details of material removed due to overlap with + existing Debian packaging or license terms that fail to satisfy the DFSG. + + * Explain build-dependencies and build-conflicts in debian/control comments. + + * Update build-dependencies relative to xfree86 4.3.0.dfsg.1-12: + + List upstream build dependencies on commands first, followed by + upstream build depenencies on library headers, and then Debian packaging + infrastructure dependencies. + + Remove no-longer needed build dependencies on libfontconfig1-dev (header + files not used), libpaperg (superseded by libpaper1, and depended upon + by tetex-bin nowadays), linux-kernel-headers (depended on by + build-essential package libc6-dev), bzip2 and dbs (new organization of + source package will not require these). + + * Backport fixes from upstream CVS trunk: + + Shut up (tons of) Imake warnings on Debian systems by testing for + variable being defined before testing its value. (Presumably the + fallback definition of NothingOutsideProjectRoot in Imake.tmpl was + intended to prevent this, but it apparently is not in effect yet + when linux.cf is parsed.) + + Fix CAN-2005-0605: scan.c in the Xpm library may allow attackers to + execute arbitrary code via a negative bitmap_unit value that leads + to a buffer overflow. (see Debian #298939) + + * Update debian/copyright to correctly document source package name, origin + of .orig.tar.gz file, and credit David Nusinow as a package author. + Restore removal of credits to Stephen Early, Mark Eichin, and ISHIKAWA + Mutsumi as package authors. Alter Debian "fallback" copyright notice to + credit copyright from changes in 1996 to Stephen Early, in 1997 to Mark + Eichin, and for the years since to Branden Robinson. In the U.S., a + written instrument is required to transfer copyright, and to the best of + my knowledge, none of Stephen, Mark, or myself ever signed such an + instrument. Remove anti-publicity clause from Debian fallback copyright + notice as it's not part of the original MIT/X11 license from the 1980s and + has no force under U.S. copyright law (asserting copyright in something, + even Free Software, doesn't waive a person's publicity rights anyway). + Remove duplicate Debian copyright notice for Software in the Public + Interest, Inc. Merge change from Debian xfree86 SVN to stop identifying + the Compugraphic and Adobe fonts from the Xprint server as non-DFSG-free; + the files have been removed from the upstream archive for another reason, + namely the existence of the xprint package. + + * Place Ubuntu package changelog entries in changelog.Ubuntu (as they do not + actually reflect package release history as a Debian user would see it). + Ship this changelog in /usr/share/doc/xorg-common. + + * Add debian/scripts/missing-keyword-sniffer, which identifies plain text + files in the source package that are missing Subversion Id keywords or the + corresponding property. + + * Rework source package to consist of an unpacked source tree, instead of + shipping a .tar.gz inside the .orig.tar.gz. + + Add debian/scripts/up-scripts (called automatically by dbs's "setup" + target), which copies the source tree into build-tree using hardlinks. + + Update debian/setperms to ensure that up-scripts is executable. + + Update debian/vars to stop defining SOURCE_DIR variable. + + Put debian/scripts in PATH and export it from debian/rules, so that dbs + can find up-scripts. + + Update target dependencies in debian/rules from "$(patched)" to "setup", + so that we can be sure up-scripts is run. + + * Make .orig.tar.gz preparation less opaque. + + Add prune-upstream-tree and make-orig-tar-gz phony targets to + debian/rules. (Note that these are not intended for ordinary package + builds, and have to be manually invoked.) + + Remove outdated and now-obsolete file debian/scripts/prune-non-free. + + Add $(SOURCE_NAME) and $(UPSTREAM_VERSION) variables to debian/rules. + + * Update paths to files containg sourceless firmware in debian/copyright. + + * Grab patches from upstream CVS HEAD: + - Add radeon(4x) manpage updates documenting VGAAccess, ReverseDDC, and + LVDSProbePLL options. (Benjamin Herrenschmidt) + . + - Add VGAAccess option to r128 driver, based on Benjamin Herrenscmidts's + radeon patch. r128 should now work on PowerPCs without "UseFBDev". To + use this on PowerPC, make sure you set "UseFBDev" to "false". + (Alex Deucher) + . + + * Document DFSG-non-freeness of PolyglotMan ("rman") in debian/copyright. + + * Update patch #058 to give Xcomposite, Xdamage, Xevie, and Xfixes their own + copies of the config-subst script, instead of hard-coding a within-tree + path to the copy in the Xcursor library. (I don't know what the point of + directing these Imakefiles over to Xcursor's copy was -- there were + already four identical copies of config-subst in X.Org 6.8.2 anyway, so + this decision didn't help matters much. :) ) Update the Imakefiles to look + for config-subst in the current working directory instead of ../Xcursor. + Convert local includes to system includes in the GLU library and X server + so that the RENDER protocol headers can actually be found. Define + RenderDefines if either BuildRender or HaveRenderLibrary is true, not just + BuildRender. Only specify render.h and renderproto.h as targets and + install renderproto.h as part of the SDK if we're building the extension + and *don't* have the extension library in the build environment. Update + MANIFEST.*.in files to reflect the fact that render.h and renderproto.h + are no longer installed. + + * Stop removing the debian/local/xlibmesa-drm-source directory in + debian/rules's clean target, as nothing creates it, and nothing has since + xfree86 4.3.0-0pre1v3. + + * Add build-dependency on render-dev (>> 1:0.9), since several files + directly #include render.h and renderproto.h. Version dependency since + symbols new to renderext 0.9 are used. Document dependency in detail in + debian/control comments. + + * Update patch #908 to stop attempting to install the sourceless microcode + files associated with the rendition driver, which are not part of the + source package (see debian/copyright). Correct + debian/MANIFEST.{alpha,amd64,hurd-i386,i386,ia64,sparc}.in to reflect the + absence of these files. (Other architectures do not build the rendition + driver.) Thanks to Jesus Climent for spotting this problem. + + -- David Nusinow Wed, 22 Jun 2005 11:24:38 -0400 --- xterm-229.orig/debian/compat +++ xterm-229/debian/compat @@ -0,0 +1 @@ +4 --- xterm-229.orig/debian/control +++ xterm-229/debian/control @@ -0,0 +1,115 @@ +Source: xterm +Section: x11 +Priority: optional +Maintainer: Debian X Strike Force +Uploaders: David Martínez Moreno , David Nusinow , Julien Cristau +Standards-Version: 3.7.2 +Build-Depends: libncurses5-dev | libncurses-dev, libxft-dev (>> 2.1.2), libxrender-dev (>> 1:0.9.0), libxaw7-dev, debhelper (>= 4.1.16), quilt, lynx + +# Reasons for Build-Depends: +# +# (An "R" to the left of a file specification indicates a file that was removed +# from the upstream source tree when the Debian source package was prepared and +# an "I" to the left of a file specification indicates a file that is +# irrelevant or unused as part of the package build process; such files +# therefore do not actually cause a build-dependency, but are mentioned here for +# completeness.) +# +# Upstream build dependencies on commands are listed first, followed by +# upstream build depenencies on library headers, and then Debian packaging +# infrastructure dependencies. +# +# libncurses5-dev | libncurses-dev +# Tekproc.c:#include +# I aclocal.m4:#include ],[ +# I aclocal.m4:#include +# I aclocal.m4:#include /* eliminate most BSD hacks */ +# button.c:#include +# charproc.c:#include +# I configure:#include +# I configure:#include +# I configure:#include /* eliminate most BSD hacks */ +# fontutils.c:#include +# main.c:#include +# menu.c:#include +# misc.c:#include +# os2main.c:#include +# print.c:#include +# resize.c:#include +# resize.c:#include +# resize.c:#include +# resize.c:#include /* tgetent() */ +# scrollbar.c:#include +# util.c:#include +# libxft-dev (>> 2.1.2) +# aclocal.m4:#include ],[ +# configure:#include +# ptyx.h:#include +# libxrender-dev (>> 1:0.9.0) +# aclocal.m4:#include +# configure:#include +# libxaw7-dev +# main.c:#include +# main.c:#include +# main.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# menu.c:#include +# os2main.c:#include +# os2main.c:#include +# os2main.c:#include +# scrollbar.c:#include +# scrollbar.c:#include +# scrollbar.c:#include +# Tekproc.c:#include +# Tekproc.c:#include +# Tekproc.c:#include +# debhelper (>= 4.1.16) po-debconf support +# dpkg-dev (>= 1.10.14) (1.10.11) comment support in debian/control; +# (1.10.14) architecture-specific binary +# package dependencies +# quilt patch management system +# lynx generates plain-text version of Debian X FAQ + +Package: xterm +Architecture: any +Depends: xbitmaps, ${shlibs:Depends} +Recommends: xutils +Suggests: xfonts-cyrillic +Provides: x-terminal-emulator +Description: X terminal emulator + xterm is a terminal emulator for the X Window System. It provides DEC VT102 + and Tektronix 4014 compatible terminals for programs that cannot use the + window system directly. This version implements ISO/ANSI colors and most of + the control sequences used by DEC VT220 terminals. + . + This package provides four commands: xterm, which is the traditional + terminal emulator; uxterm, which is a wrapper around xterm that is + intelligent about locale settings (especially those which use the UTF-8 + character encoding), but which requires the luit program from the xutils + package; koi8rxterm, a wrapper similar to uxterm for locales that use the + KOI8-R character set; and lxterm, a simple wrapper that chooses which of the + previous commands to execute based on the user's locale settings. + . + A complete list of control sequences supported by the X terminal emulator + is provided in /usr/share/doc/xterm. + . + The xterm program uses bitmap images provided by the xbitmaps package. + . + Those interested in using koi8rxterm will likely want to install the + xfonts-cyrillic package as well. --- xterm-229.orig/debian/copyright +++ xterm-229/debian/copyright @@ -0,0 +1,129 @@ +This package was debianized by first time by David Martinez Moreno + on Tue, 27 Sep 2005 01:45:34 +0200. + + +Upstream sources: http://invisible-island.net/xterm/xterm.html + +Copyright 1996-2007 by Thomas E. Dickey +Copyright 1998 by Jason Bacon + + All Rights Reserved + +Permission to use, copy, modify, and distribute this software and its +documentation for any purpose and without fee is hereby granted, +provided that the above copyright notice appear in all copies and that +both that copyright notice and this permission notice appear in +supporting documentation, and that the name of the above listed +copyright holder(s) not be used in advertising or publicity pertaining +to distribution of the software without specific, written prior +permission. + +THE ABOVE LISTED COPYRIGHT HOLDER(S) DISCLAIM ALL WARRANTIES WITH REGARD +TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS, IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE +LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +Copyright 1996-2007 by Thomas E. Dickey +Copyright 2001-2004 Branden Robinson +Copyright 2001 by Juliusz Chroboczek + + All Rights Reserved + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name(s) of the above copyright +holders shall not be used in advertising or otherwise to promote the +sale, use or other dealings in this Software without prior written +authorization. + + +Copyright 1984-1994 X Consortium + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name of the X Consortium shall +not be used in advertising or otherwise to promote the sale, use or +other dealings in this Software without prior written authorization +from the X Consortium. + + +Copyright 1987,1988 by Digital Equipment Corporation, Maynard, Massachusetts. + + All Rights Reserved + +Permission to use, copy, modify, and distribute this software and its +documentation for any purpose and without fee is hereby granted, +provided that the above copyright notice appear in all copies and that +both that copyright notice and this permission notice appear in +supporting documentation, and that the name of Digital Equipment +Corporation not be used in advertising or publicity pertaining to +distribution of the software without specific, written prior permission. + +DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING +ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL +DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR +ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS +SOFTWARE. + + +Copyright 1988,1989 The Open Group + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation. + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. + --- xterm-229.orig/debian/local/KOI8RXTerm +++ xterm-229/debian/local/KOI8RXTerm @@ -0,0 +1,20 @@ +! $Id$ + +! This is based on the UXTerm app-defaults file by Thomas Dickey. + +! Use +! xterm -class KOI8RXTerm +! to set resources for KOI8-R mode with corresponding fonts. + +#include "XTerm-color" + +*fontMenu.Label: KOI8-R Fonts +*VT100*allowC1Printable: true + +! Use Cyrillic instead of Latin fonts. +*VT100.font: -misc-fixed-medium-r-semicondensed--13-120-75-75-c-60-koi8-r +*VT100.font2: -misc-fixed-medium-r-normal--8-80-75-75-c-50-koi8-r +*VT100.font3: -misc-fixed-medium-r-normal--14-130-75-75-c-70-koi8-r +*VT100.font4: -misc-fixed-medium-r-normal--13-120-75-75-c-80-koi8-r +*VT100.font5: -misc-fixed-medium-r-normal--18-120-100-100-c-90-koi8-r +*VT100.font6: -misc-fixed-medium-r-normal--20-200-75-75-c-100-koi8-r --- xterm-229.orig/debian/local/koi8rxterm +++ xterm-229/debian/local/koi8rxterm @@ -0,0 +1,85 @@ +#!/bin/sh +# $Id$ +# This is a wrapper script to set up xterm with a KOI8-R locale; based on +# uxterm, by Thomas Dickey. + +: ${XTERM_PROGRAM=xterm} + +# Check if there is a workable locale program. If there is not, we will read +# something via the standard error. Ignore whatever is written to the +# standard output. +locale=`sh -c "LC_ALL=C LC_CTYPE=C LANG=C locale >/dev/null" 2>&1` +found=no + +# Check for -version and -help options, to provide a simple return without +# requiring the program to create a window: +if test $# = 1 +then + case $1 in + -v|-ver*|-h|-he*) + $XTERM_PROGRAM "$@" + exit $? + ;; + esac +fi + +# Check environment variables that xterm does, in the same order: +for name in LC_ALL LC_CTYPE LANG +do + eval 'value=$'$name + if test -n "$value" ; then + case $value in + *.koi8r|*.KOI8R|*.koi8-r|*.KOI8-R) + found=yes + ;; + *.koi8r@*|*.KOI8R@*|*.koi8-r@*|*.KOI8-R*) + found=yes + ;; + C|POSIX) + # The user may not have configured his or her + # locale; try to muddle through anyway. + value=ru_RU.KOI8-R + ;; + esac + break + fi +done + +# If we didn't find a locale that uses KOI8-R, modify the safest one. Not +# everyone has a KOI8-R locale installed (and there appears to be no +# trivial/portable way to determine whether it is, from a shell script). +# We could check if the user's shell does not reset unknown locale +# specifiers, but not all shells do. +if test $found != yes ; then + if test -n "$value" ; then + value=`echo ${value} |sed -e 's/[.@].*//'`.KOI8-R + else + name="LC_CTYPE" + value="ru_RU.KOI8-R" + fi + eval save=\$${name} + eval ${name}=${value} + eval export ${name} + if test -z "$locale" ; then + # The 'locale' program tries to do a sanity check. + check=`sh -c "locale >/dev/null" 2>&1` + if test -n "$check" ; then + eval ${name}=${save} + eval export ${name} + + echo "koi8rxterm tried to use locale $value by setting \$$name" >&2 + xmessage -file - <&2 + exit 1 +} + +if ! which locale >/dev/null 2>&1; then + die "required program \"locale\" not available" +fi + +case "$(locale charmap 2>/dev/null)" in + KOI8-R) + XTERM=koi8rxterm + ;; + UTF-8) + XTERM=uxterm + ;; + *) + XTERM=xterm + ;; +esac + +exec "$XTERM" "$@" + +# vim:set ai et sw=4 ts=4 tw=80: --- xterm-229.orig/debian/local/lxterm.1 +++ xterm-229/debian/local/lxterm.1 @@ -0,0 +1,55 @@ +.\" $Id$ +.\" +.TH lxterm 1 "2004-12-19" "Debian Project" +.SH NAME +lxterm \- locale\-sensitive wrapper for xterm +.SH SYNOPSIS +.B lxterm +[ +.I xterm-options +] +.SH DESCRIPTION +.B lxterm +is a wrapper around the +.BR xterm (1) +program that invokes +.BR xterm , +.BR koi8rxterm (1), +or +.BR uxterm (1) +as appropriate, based on the user's locale setting. +All arguments to +.B lxterm +are passed to +.B xterm +without processing; the +.BR \-class , +.BR \-k8 , +and +.B \-u8 +options should not be specified because they are used by +.B koi8rxterm +and +.BR uxterm . +See the +.B xterm +manual page for more information on +.IR xterm-options . +.PP +The +.BR locale (1) +utility is used to determine the character set used by the current locale. +If the character set is UTF-8, +.B uxterm +is invoked; if the character set is KOI8-R, +.B koi8rxtem +is invoked; otherwise, \(oqplain\(cq +.B xterm +is invoked. +.SH AUTHOR +Branden Robinson +.SH "SEE ALSO" +.BR locale (1), +.BR koi8rxterm (1), +.BR uxterm (1), +.BR xterm (1) --- xterm-229.orig/debian/local/uxterm.1 +++ xterm-229/debian/local/uxterm.1 @@ -0,0 +1,91 @@ +.\" $Id$ +.\" +.\" Copyright 2001, 2004 Branden Robinson +.\" +.\" Permission is hereby granted, free of charge, to any person obtaining a +.\" copy of this software and associated documentation files (the "Software"), +.\" to deal in the Software without restriction, including without limitation +.\" the rights to use, copy, modify, merge, publish, distribute, sublicense, +.\" and/or sell copies of the Software, and to permit persons to whom the +.\" Software is furnished to do so, subject to the following conditions: +.\" +.\" The above copyright notice and this permission notice shall be included in +.\" all copies or substantial portions of the Software. +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +.\" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +.\" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +.\" SOFTWARE IN THE PUBLIC INTEREST, INC. BE LIABLE FOR ANY CLAIM, DAMAGES OR +.\" OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +.\" ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +.\" DEALINGS IN THE SOFTWARE. +.TH uxterm 1 "2004-12-19" "Debian Project" +.SH NAME +uxterm \- X terminal emulator for Unicode (UTF-8) environments +.SH SYNOPSIS +.B uxterm +[ +.I xterm-options +] +.SH DESCRIPTION +.B uxterm +is a wrapper around the +.BR xterm (1) +program that invokes the latter program with the \(oqUXTerm\(cq X resource +class set. +All arguments to +.B uxterm +are passed to +.B xterm +without processing; the +.B \-class +and +.B \-u8 +options should not be specified because they are used by the wrapper. +See the +.B xterm +manual page for more information on +.IR xterm-options . +.PP +The environment's locale settings (see \(lqENVIRONMENT\(rq below) are +used to discern the locale's character set. +If no current locale can be determined, the locale \(oqen_US\(cq (the +English language as used in the territory of the United States) is assumed. +The +.BR locale (1) +utility is used to determine whether the system supports the selected +locale. +If it does not, +.B uxterm +will exit with an error and report the output of +.BR locale . +.PP +.B Note: uxterm +may produce unexpected results if the current locale is set to one in which +the UTF-8 character encoding is not supported, of if fonts using the ISO +10646-1 character set are not available. +In the Debian system, the \(oqxfonts\-base\(cq package provides the fonts +that +.B uxterm +uses by default. +To change the fonts +.B uxterm +uses, edit the +.I /etc/X11/app\-defaults/UXTerm +file. +.PP +A similar wrapper, +.BR koi8rxterm (1), +is available for KOI8-R environments. +.SH ENVIRONMENT +.TP +.B LC_ALL\fR, \fBLC_CTYPE\fR, \fBLANG +The values of these variables are checked, in order, to determine the +character set used by the current locale. +.SH AUTHOR +Thomas Dickey +.SH "SEE ALSO" +.BR locale (1), +.BR locale (7), +.BR koi8rxterm (1), +.BR xterm (1) --- xterm-229.orig/debian/local/xterm.faq.html +++ xterm-229/debian/local/xterm.faq.html @@ -0,0 +1,2461 @@ + + + + +XTERM - Frequently Asked Questions (FAQ) + + + + +
+Copyright 1997-2004,2005 by Thomas E. Dickey +
+

Contents

+ + +
+

What is XTERM?

+From the manual page: +
+The xterm program is a terminal emulator for the X Window System. It provides +DEC VT102 and Tektronix 4014 compatible terminals for programs that can't use +the window system directly. If the underlying operating system supports +terminal resizing capabilities (for example, the SIGWINCH signal in systems +derived from 4.3bsd), xterm will use the facilities to notify programs running +in the window whenever it is resized. +
+ +

Who wrote XTERM?

+I've been working on xterm since early 1996 +(see my changelog for details). +

+But the program is much older than that. +

+A lot of people, cited at the bottom of the manual page wrote +the original xterm program, maintained by the X Consortium +(later part of the Open Group - I'm well aware of the distinction, +but am citing when the work was done, not who the current owner may be). +There is no changelog, and it is not clear who did what. +Email from Jim Gettys provides some background: +

+Cast of thousands... +

+To give a bit of history, xterm predates X! +

+It was originally written as a stand-alone terminal emulator for the +VS100 by Mark Vandevoorde, as my coop student the summer that +X started. +

+Part way through the summer, it became clear that X was more useful +than trying to do a stand alone program, so I had him retarget it to X. +Part of why xterm's internals are so horrifying is that it was originally +intended that a single process be able to drive multiple VS100 displays. +Don't hold this against Mark; it isn't his fault. +

+I then did a lot of hacking on it, and merged several improved versions +from others back in. +

+Notable improvements include the proper ANSI parser, that Bob McNamara +did. +

+The Tek 4010 support came from a guy at Smithsonian Astrophysical Observatory +whose name slips my mind at the moment. +

+Ported to X11 by Loretta Guarino. +

+Then hacked on at the X Consortium by uncounted people. +

+Email from Doug Mink provides more background: +
+I was checking out the newly revised AltaVista search +engine to see what was on the net about xterm, and I +found your pages. I can add to the FAQ in that I was the +"guy at the Smithsonian Astrophysical Observatory" Jim +Gettys refers to. I am listed at the end of the man page +under authors. What happened was that I was hired by SAO +(after leaving the research staff at MIT) in October 1985 +to write analysis software for the Spacelab 2 Infrared +Telescope which was to fly on the Space Shuttle in 1985 +less than six months after I was hired. I came with a tar +tape full of software I had written for Unix and Tektronix +terminals, but I was presented with a VS100 terminal which +had an early version (X6 or so) of xterm, with no graphics +capabilities. SAO is at Harvard, across Cambridge from MIT, +where Jim Gettys was detailed from DEC to the X project, +and Jim had connections with SAO, having worked here after +college (MIT, where we had both worked at the observatory +at various times); he was still sharing an apartment with +an SAO colleague of mine, too. Anyway, everyone decided +that since I knew Tektronix commands pretty well, and our +group desparately needed the graphics capabilities, it +would be a good use of my time to implement a Tektronix +terminal emulator under X. So I set to work learning +more C--I had only written a couple of wrappers to C I/O +routines so I could use them with my Fortran software--and +wrote a Tektronix emulator. The only X documentation at +the time was the code itself. While I was at it, I wrote +an improved Tektronix emulator for our Imagen laser printer +which used the full resolution of that 300 dpi printer instead +of the effective 100 dpi (i.e. jaggy) emultator distributed +with the printer. The original xterm Tek emulator shared a +window with the VT100 emulator, much like on the VT240 terminals +which I had been using at MIT before I came to Harvard. With +a VAX 750 running several VS100's, window creation was sloowww, +so sharing a window was the quickest way to do things, and all +of my software was written for that mode of operation, anyway. +While I wrote the emulator so that my software would work on +it, it was tested by the X group against a BBN graphics package, +the name of which slips my mind right now. +

+Anyway, 15 years later, I am still using xterm and some of the +same mapping software I wrote the emulator for. And I am still +at the Smithsonian Astrophysical Observatory. +

+

+This FAQ is oriented toward the version of xterm distributed with XFree86, +which is based on the X11R6.3 xterm, with the addition of ANSI color and +VT220 controls. + +

What platforms does it run on?

+Xterm runs in all of the implementations of X11. +I've built and run these since I started working on xterm: + +
    +
  • AIX 3.2.5 (cc) +
  • Digital Unix 3.2, 4.0 (cc) +
  • FreeBSD 2.2.6 to 5.1 (gcc 2.8) +
  • HP-UX 9.05 (gcc 2.7.2) +
  • IRIX 5.2, 6.2 (cc, gcc 2.7.2, gcc 2.8) +
  • Linux 2.0.0 to 2.4.22 (gcc 2.7.2 to 3.3) +
  • SCO OpenServer 5 (cc, gcc). +
  • Solaris 2.4, 2.5, 2.5.1, 2.6, 7, 8 (cc, gcc 2.7.2) +
  • SunOS 4.1.1, 4.1.3 (gcc 2.7.2) +
+

+Most of these configurations have X11R5 libraries. Only minor changes +are needed to make xterm work on those systems. However, with X11R6 +you can obtain better locale support, as well as new features such as the +active icon. + +

What is the latest version?

+The most recent (and well supported) version of xterm is the XFree86 version. +I have a copy at +

+Ftp: ftp://invisible-island.net/xterm/xterm.tar.gz + +

What versions are available?

+There are several other versions of xterm, as well as similar programs. +These include + +(I am aware of a few others, such as +xcterm, but have not seen +a working version of these). +

+There were for some time two versions of XFree86 xterm. Starting with my +patch 88, +there were the stable (beta) and unstable (alpha) versions, which currently +are XFree86 3.3.6 and XFree86 4.x, respectively. +I made only critical changes to the stable version since +patch 88; +ongoing development (including all non-critical fixes) +was focused on the "unstable". +

+XFree86 4.0 should have incorporated my +patch 131, +but it was overlooked at the last moment +(though it was listed in the ChangeLog, the patch itself was not applied). +Unfortunately, the patch 130 version which was released +renders colors incorrectly on most platforms, in particular FreeBSD. +Ironically, the change in +patch 129 +which introduced this bug +was designed to work around a bug which I have seen only running with FreeBSD. +To compound the irony, +there was some resistance at the time +(2000/4/5) by that organization to incorporating the fix +because it might be confused with the 4.0 release version. + +

How do I ...

+Not really problems, but frequently asked questions (the point of this, +after all): + + +

How do I change the font size?

+This is in the manpage, in MENUS. +

+X Consortium xterm provides popup menus, by pressing the control key +together with the mouse button. +Control right mouse button pops up the VT FONTS menu, +from which you can select fonts that are specified in xterm's resources. +Usually these are in increasing order of size. +

+XFree86 xterm provides the menu, plus a feature adapted from rxvt: pressing +the shifted keypad plus or minus keys steps through the font menu selections, +in order of their size. + +

How do I print the screen?

+That depends on why you want to print it. +

+If you want a trace of an interactive session, you should use the +script program. It records every character sent to the +screen, recording them in a file typescript. +There are two drawbacks to this approach: +

    +
  • Every character is recorded. +Even cursor movement, if you run an editor. +
  • You must start a new shell to capture the typescript file. +
+Well, what about logging? +Some versions of xterm support logging to a file. +In fact XFree86 xterm does. Logging was dropped from X Consortium xterm +during X11R5 due to security concerns. Those were addressed, but logging +was not reinstated +(in fact there is a related bug in xterm). +Some people prefer this, because it is convenient: +you can start and stop logging a popup menu entry. +However +
    +
  • Every character is recorded. +Even cursor movement, if you run an editor. +
  • Line drawing characters are translated to control characters, +i.e., codes 0-31 +(this may be fixed sometime, +it is a problem inherited from X Consortium xterm). +
+Both script and logging are useful for recording, but they +require interpretation to make sense of the trace. You probably +would not send that trace to a printer (not twice, anyway). +

+If you want to print the contents of the screen, XFree86 xterm +implements, as part of the VT100 emulation, an "attached" printer. +

    +
  • The printer is really a pipe command, to which xterm writes. +
  • You can print the current line, page, or continuously with +the corresponding control sequences. That takes an application +program which knows how to print the screen. +
  • If you do not have an application, xterm has a popup menu +entry to print the window. +
+There are limitations and tradeoffs using the "attached" printer, +because it is an emulation: +
    +
  • The emulation is based on detailed documentation for a VT320. +This states that control sequences are sent in each line to +reset bold, underlining and other printable attributes, and +to set them as needed. +Your printer probably does not understand this sort of input. +Use the xterm resource printAttributes to get +more easily printed output. +
  • The printer may hang. +Not really, but it seems that way. +If you use the "attached" printer from an application designed +for the VT100 terminal, it is written with the assumption that +the printer is a dedicated piece of hardware, +printing onto a continuous form. +Use the printerAutoClose resource to change +xterm's behavior to close the printer pipe whenever the terminal +is told to switch the printer offline. +
+If you use the popup menu to print the screen, this will close the +printer pipe unless it was already opened by the application running in xterm. + +

How do I set up function keys?

+With XFree86 xterm, this is relatively simple. So I'll answer that first. +

+With X Consortium xterm, you have partial support for DEC VTxxx function keys. +Function keys F1 to F12 correspond to DEC's F1 to F12 (sort of). +Actually, DEC's VT220 terminals do not have codes for F1 through F5. +They are reserved for local functions. +And the VT220 (and up) terminals have 20 function keys. +So you cannot do anything with the F13 through F20 (i.e., DO, HELP and SELECT). +Finally, though xterm is reputed to be VT100-compatible, it has no support +for the VT100 keypad (PF1 to PF4, and the "," key). +

+XFree86 xterm changes the X Consortium codes for F1 to F4 to match the +VT100 PF1 to PF4, except when the emulation level is VT220 and up. +In this case, it generates the same F1 to F4 codes as X Consortium xterm. +Moreover, it adds a new resource sunKeyboard, which +tells the program whether it has only 12 function keys (i.e., a Sun or PC +keyboard). +If so (this is selectable from the popup menu), you can use the control key +with F1 to F12 to get F13 to F24, and use the "+" key on the keypad as an +alias for "," (comma). +

+The emulation level for XFree86 xterm is set via the resource +decTerminalID, e.g., to 220 for a VT220. +Once set, applications can set the emulation level up or down within that +limit. DEC's terminals are configured in much the same way by a setup +option. +

+That is the simple way, using a couple of new resources. +The traditional way to get function keys involves translations. +I have seen a few postings on the newsgroups that do this. +Here is one from Bruce Momjian <root@candle.pha.pa.us> +for a VT220: +


+	xterm $XTERMFLAGS +rw +sb +ls $@ -tm 'erase ^? intr ^c' \
+		-name vt220 -title vt220 -tn xterm-220 "$@" &
+
+

+with the corresponding resources: +


+	XTerm*VT100.translations: #override \n\
+		<Key>Home: string(0x1b) string("[3~") \n \
+		<Key>End: string(0x1b) string("[4~") \n
+	vt220*VT100.translations: #override \n\
+	~Shift	<Key>F1: string(0x1b) string("OP") \n \
+	~Shift	<Key>F2: string(0x1b) string("OQ") \n \
+	~Shift	<Key>F3: string(0x1b) string("OR") \n \
+	~Shift	<Key>F4: string(0x1b) string("OS") \n \
+	~Shift	<Key>F5: string(0x1b) string("[16~") \n \
+	~Shift	<Key>F6: string(0x1b) string("[17~") \n \
+	~Shift	<Key>F7: string(0x1b) string("[18~") \n \
+	~Shift	<Key>F8: string(0x1b) string("[19~") \n \
+	~Shift	<Key>F9: string(0x1b) string("[20~") \n \
+	~Shift	<Key>F10: string(0x1b) string("[21~") \n \
+	~Shift	<Key>F11: string(0x1b) string("[28~") \n \
+	~Shift	<Key>F12: string(0x1b) string("[29~") \n \
+	Shift	<Key>F1: string(0x1b) string("[23~") \n \
+	Shift	<Key>F2: string(0x1b) string("[24~") \n \
+	Shift	<Key>F3: string(0x1b) string("[25~") \n \
+	Shift	<Key>F4: string(0x1b) string("[26~") \n \
+	Shift	<Key>F5: string(0x1b) string("[K~") \n \
+	Shift	<Key>F6: string(0x1b) string("[31~") \n \
+	Shift	<Key>F7: string(0x1b) string("[31~") \n \
+	Shift	<Key>F8: string(0x1b) string("[32~") \n \
+	Shift	<Key>F9: string(0x1b) string("[33~") \n \
+	Shift	<Key>F10: string(0x1b) string("[34~") \n \
+	Shift	<Key>F11: string(0x1b) string("[28~") \n \
+	Shift	<Key>F12: string(0x1b) string("[29~") \n \
+		<Key>Print: string(0x1b) string("[32~") \n\
+		<Key>Cancel: string(0x1b) string("[33~") \n\
+		<Key>Pause: string(0x1b) string("[34~") \n\
+		<Key>Insert: string(0x1b) string("[2~") \n\
+		<Key>Delete: string(0x1b) string("[3~") \n\
+		<Key>Home: string(0x1b) string("[1~") \n\
+		<Key>End: string(0x1b) string("[4~") \n\
+		<Key>Prior: string(0x1b) string("[5~") \n\
+		<Key>Next: string(0x1b) string("[6~") \n\
+		<Key>BackSpace: string(0x7f) \n\
+		<Key>Num_Lock: string(0x1b) string("OP") \n\
+		<Key>KP_Divide: string(0x1b) string("Ol") \n\
+		<Key>KP_Multiply: string(0x1b) string("Om") \n\
+		<Key>KP_Subtract: string(0x1b) string("OS") \n\
+		<Key>KP_Add: string(0x1b) string("OM") \n\
+		<Key>KP_Enter: string(0x1b) string("OM") \n\
+		<Key>KP_Decimal: string(0x1b) string("On") \n\
+		<Key>KP_0: string(0x1b) string("Op") \n\
+		<Key>KP_1: string(0x1b) string("Oq") \n\
+		<Key>KP_2: string(0x1b) string("Or") \n\
+		<Key>KP_3: string(0x1b) string("Os") \n\
+		<Key>KP_4: string(0x1b) string("Ot") \n\
+		<Key>KP_5: string(0x1b) string("Ou") \n\
+		<Key>KP_6: string(0x1b) string("Ov") \n\
+		<Key>KP_7: string(0x1b) string("Ow") \n\
+		<Key>KP_8: string(0x1b) string("Ox") \n\
+		<Key>KP_9: string(0x1b) string("Oy") \n
+
+	!	<Key>Up: string(0x1b) string("[A") \n\
+	!	<Key>Down: string(0x1b) string("[B") \n\
+	!	<Key>Right: string(0x1b) string("[C") \n\
+	!	<Key>Left: string(0x1b) string("[D") \n\
+
+	*visualBell:	true
+	*saveLines:    1000
+	*cursesemul:	true
+	*scrollKey: true
+	*scrollBar: true
+
+Note that real VT220 terminals use shifted function keys to mean something +different: the user-programmable keys (i.e., DECUDK). XFree86 xterm +supports this, but the translations do not (they're using shift to select +F13 to F20). +

+Here's another one, from +Robert Ess <ress@spd.dsccc.com>: +


+	#!/bin/sh
+
+	#		vax
+	# 09-17-96	Bob Ess      - initial creation
+	# 09-26-96	Shig Katada  - Additional keybindings
+	#
+	#		Script file to incorporate keybindings and command line
+	#		options for connecting to a VAX node
+
+	# Usage statement
+	Usage(){
+		echo
+		echo " Usage  : vax -options"
+		echo
+		echo " Options: -80   for 80 column terminal"
+		echo "          -132  for 132 column terminal"
+		echo "          -fg colorname"
+		echo "          -bg colorname"
+		echo "          -fn fontname"
+		echo "          -fb bold fontname"
+		echo "          -host [altair] [devel] [leonis] [castor]"
+		echo ""
+		echo " Example: \"vax -80 -fg white -bg black -fn 9x15 -fb 9x15b -host castor\""
+		echo "          Starts a VAX session with an 80 column terminal"
+		echo "          with a black background, white foreground, a normal"
+		echo "          font of 9x15 and a bold font of 9x15b, and connects"
+		echo "          to the node 'castor'"
+		echo
+		echo "          If you need additional help, please call Workstation"
+		echo "          Services at x92396."
+		echo
+		exit 1
+	}
+
+
+	# Default to a black foreground with a white background.
+	# Use the 9x15 and 9x15bold fonts. Connect to castor by default.
+	#
+	FG=black
+	BG=white
+	HOST=castor
+	FONT=9x15
+	BFONT=9x15bold
+	COLS=80
+
+
+	# Parse the command line arguments
+	#
+	while [ $# != 0 ];
+	do
+		case $1 in
+			-80)	COLS=80
+				FONT=spc12x24c
+				BFONT=spc12x24b
+				shift
+				;;
+			-132)	COLS=132
+				FONT=9x15
+				BFONT=9x15b
+				shift
+				;;
+			-fg)	shift
+				FG=$1
+				shift;;
+			-bg)	shift
+				BG=$1
+				shift;;
+			-fn)	shift
+				FONT=$1
+				shift;;
+			-fb)	shift
+				BFONT=$1
+				shift;;
+			-host)	shift
+				HOST=$1
+				shift;;
+			-help)	Usage;;
+			*)	Usage;;
+		esac
+	done
+
+
+	xterm  -title "VAX" -sb -sl 1200 -geo ${COLS}x24 -fg ${FG} -bg ${BG} \
+		-cr red -fn ${FONT} -fb ${BFONT} -xrm \
+		'XTerm*VT100.translations:     #override \n\
+		<Key>Insert:            string(\001) \n\
+		Shift <Key>Up:          scroll-back(1,lines) \n\
+		Shift <Key>Down:        scroll-forw(1,lines) \n\
+		Shift <Key>Right:       string(0x1b) string("f") \n\
+		Shift <Key>Left:        string(0x1b) string("b") \n\
+		Shift <Key>Delete:      string(0x1b) string(0x08) \n\
+		Shift <Key>Tab:         string(0x1b) string("*") \n\
+		<Key>0x1000FF0D:        scroll-back(1,page) \n\
+		<Key>0x1000FF0E:        scroll-forw(1,page) \n\
+		<Key>0x1000FF09:        string(\010) \n\
+		<Key>0x1000FF0A:        string(\005) \n\
+		<Key>BackSpace:         string(0xff) \n\
+		<Key>Select:            select-start() \n\
+		<Key>0x1000FF02:        select-end(PRIMARY,CUT_BUFFER0) \n\
+		Meta <Key>0x1000FF02:   select-end(CLIPBOARD) \n\
+		<Key>0x1000FF04:        insert-selection(PRIMARY,CUT_BUFFER0) \n\
+		Meta <Key>0x1000FF04:   insert-selection(CLIPBOARD) \n\
+		<Key>F1:                string(0x1b) string("OP") \n\
+		<Key>F2:                string(0x1b) string("OQ") \n\
+		<Key>F3:                string(0x1b) string("OR") \n\
+		<Key>F4:                string(0x1b) string("OS") \n\
+		<Key>F5:                string(0x1b) string("OA") \n\
+		<Key>F11:               string(0x1b) string("[23~") \n\
+		<Key>F12:               string(0x1b) string("[24~") \n\
+		<Key>KP_0:              string(0x1b) string("Op") \n\
+		<Key>KP_1:              string(0x1b) string("Oq") \n\
+		<Key>KP_2:              string(0x1b) string("Or") \n\
+		<Key>KP_3:              string(0x1b) string("Os") \n\
+		<Key>KP_4:              string(0x1b) string("Ot") \n\
+		<Key>KP_5:              string(0x1b) string("Ou") \n\
+		<Key>KP_Divide:         string(0x1b) string("OP") \n\
+		<Key>KP_Multiply:       string(0x1b) string("[29~") \n\
+		<Key>KP_Enter:          string(0x1b) string("OM") \n\
+		<Key>KP_Subtract:       string(0x1b) string("Om") \n\
+		<Key>KP_Add:            string(0x1b) string("Ol") \n\
+		<Key>KP_Decimal:        string(0x1b) string("On") \n\
+		<Btn1Down>:             select-start() \n\
+		<Btn1Motion>:           select-extend() \n\
+		<Btn1Up>:               select-end(PRIMARY,CUT_BUFFER0) \n\
+		Button1<Btn2Down>:      select-end(CLIPBOARD) \n\
+		Button1<Btn2Up>:        ignore()' \
+		-e telnet $HOST &
+
+Finally (for the moment) is a further modification of Robert Ess's script +by Erik Ahlefeldt, +<oahlefel@metz.une.edu.au>. +From his readme file, for vmsterm: + +
+ This script is for people who wish to connect from a Linux or Unix computer + to a VMS computer using telnet and get a good VT100 or VT220 emulation. + The key mappings have been specifically designed to emulate the VT terminal + auxiliary numeric keypad, so that you can use VMS EDT and TPU editors, as well + as the many VMS applications use keys PF1 to PF4. The script should work with + any recent version of Xterm using a standard extended IBM PC keyboard or + a Sun keyboard. +

+ About the keymappings. First the auxiliary numeric keypad. + My prime objective with these mappings was to produce a setup that + I could use with the EDT and TPU editors which make extensive use of the + numeric keypad. The top row of keys PC numeric keypad (Num Lock, Divide, + Multiply, Subtract) are where you find PF1, PF2, PF3, PF4 on a VT keyboard, + so I have mapped them to PF1 thru PF4. The PC numeric keypad Add key (+) takes + up the space of two keys which are Minus and Comma on the VT keyboard - I have + mapped it to Comma (Delete Character in the EDT editor). I have then used the + PC Pause key to map to VT key Minus (Delete Word in the EDT editor). The + remaining keys on the auxiliary numeric keypad are the same for PC and VT. +

+ The six keys between the main and numeric keypads on the PC (Insert, Home, + Page Up, Delete End, Page Down) are usually mapped to the VT keys by either + position or by (approximate) function. As I rarely use these keys I have + mapped them by function as follows: PC key Insert to VT Insert Here, + PC Home to VT Find, PC Page Up to VT Prev, PC Delete to VT Remove, PC + End to VT Select, PC Page Down to VT Next. +

+
Function keys. +
There are 12 function keys on the PC keyboard and 20 on the + VT keyboard, so I map PC F1 thru F12 to VT F1 thru F12 (except for F1 thru F5 + as noted below) and PC Shift F1 thru Shift F10 to VT F11 thru F20. +

+ The VT keys F1 thru F5 are local hardware function keys so there is nothing + to emulate, however some PC to VT emulations in the past have mapped PF1 thru + PF4 here, so I have done that too, even though they are already mapped on the + auxiliary numeric keypad. +

Xterm functionality. +
You lose some xterm functions when you remap the + keyboard, however this script implements a scroll back buffer of 1000 lines + which you scroll through using Shift and Up (a.k.a. Up Arrow or Cursor Up key) + or Shift and Down. +
+
+a summary of the keyboard mapping: +
+		PC Key     maps to   VT Key.
+		------               ------
+		F1                   PF1
+		F2                   PF2
+		F3                   PF3
+		F4                   PF4
+		F5                   unused
+		F6                   F6
+		F7                   F7
+		F8                   F8
+		F9                   F9
+		F10                  F10
+		F11                  F11
+		F12                  F12
+		Shift F1             F11
+		Shift F2             F12
+		Shift F3             F13
+		Shift F4             F14
+		Shift F5             F15 (Help)
+		Shift F6             F16 (Do)
+		Shift F7             F17
+		Shift F8             F18
+		Shift F9             F19
+		Shift F10            F20
+		Shift F11            F11
+		Shift F12            F12
+		Print                Help (F15)
+		Cancel               Do   (F16)
+		Pause                Keypad Minus
+
+		Insert               Insert Here
+		Delete               Remove
+		Home                 Find
+		End                  Select
+		Prior                Prev
+		Next                 Next
+		BackSpace            BackSpace (sends DEL - ascii 127)
+
+		Num_Lock             PF1
+		KP_Divide            PF2
+		KP_Multiply          PF3
+		KP_Subtract          PF4
+		KP_Add               Keypad Comma
+		KP_Enter             Enter
+		KP_Decimal           Period
+		KP_0                 Keypad 0
+		KP_1                 Keypad 1
+		KP_2                 Keypad 2
+		KP_3                 Keypad 3
+		KP_4                 Keypad 4
+		KP_5                 Keypad 5
+		KP_6                 Keypad 6
+		KP_7                 Keypad 7
+		KP_8                 Keypad 8
+		KP_9                 Keypad 9
+		Up                   Up
+		Shift Up             Scroll Back
+		Down                 Down
+		Shift Down           Scroll Forward
+		Right                Right
+		Left                 Left
+
+and the script: +

+	#!/bin/sh
+	#               vmsterm
+	#               from an original script by Bob Ess
+	#               key translations by Erik Ahlefeldt
+	#
+	#               Script file using Xterm and telnet to connect to a VMS host
+	#               and give a decent vt220 emulation.
+	#
+	# Usage statement
+	Usage(){
+		echo
+		echo " Usage  : vmsterm -options"
+		echo
+		echo " Options: -80   for 80 column terminal"
+		echo "          -132  for 132 column terminal"
+		echo "          -bg colorname"
+		echo "          -fg colorname"
+		echo "          -fn fontname"
+		echo "          -fb bold fontname"
+		echo "          -host [crusher.saltmine.com] [earth] [192.168.7.7]"
+		echo ""
+		echo " Example: \"vmsterm -80 -fg white -bg black -fn 9x15 -fb 9x15b -host earth\""
+		echo "          Starts a VMS session with an 80 column terminal"
+		echo "          with a black background, white foreground, a normal"
+		echo "          font of 9x15 and a bold font of 9x15b, and connects"
+		echo "          to the node 'earth'"
+		echo ""
+		echo " Example: \"vmsterm -host earth\""
+		echo "          Starts a VMS session with default terminal settings "
+		echo ""
+		echo " Example: \"vmsterm -help\""
+		echo "          Displays vmsterm options "
+		echo
+		exit 1
+	}
+
+	# Default to a black foreground with a white background.
+	# Use the 9x15 and 9x15bold fonts. Connect to 192.168.3.3 by default.
+	#
+	FG=black
+	BG=white
+	HOST=192.168.3.3
+	FONT=9x15
+	BFONT=9x15bold
+	COLS=80
+
+	# Parse the command line arguments
+	#
+	while [ $# != 0 ];
+	do
+		case $1 in
+			-80)    COLS=80
+				FONT=spc12x24c
+				BFONT=spc12x24b
+				shift
+				;;
+			-132)   COLS=132
+				FONT=9x15
+				BFONT=9x15b
+				shift
+				;;
+			-fg)    shift
+				FG=$1
+				shift;;
+			-bg)    shift
+				BG=$1
+				shift;;
+			-fn)    shift
+				FONT=$1
+				shift;;
+			-fb)    shift
+				BFONT=$1
+				shift;;
+			-host)  shift
+				HOST=$1
+				shift;;
+			-help)  Usage;;
+			*)      Usage;;
+		esac
+	done
+
+	xterm	-title "VMSTERM" -sb -sl 1000 -geo ${COLS}x24 -fg ${FG} -bg ${BG} \
+		-cr blue -fn ${FONT} -fb ${BFONT} -xrm \
+		'XTerm*VT100.translations: #override \n \
+		~Shift	<Key>F1:	string(0x1b)	string("OP") \n \
+		~Shift	<Key>F2:	string(0x1b)	string("OQ") \n \
+		~Shift	<Key>F3:	string(0x1b)	string("OR") \n \
+		~Shift	<Key>F4:	string(0x1b)	string("OS") \n \
+		~Shift	<Key>F5:	string("Break") \n \
+		~Shift	<Key>F6:	string(0x1b)	string("[17~") \n \
+		~Shift	<Key>F7:	string(0x1b)	string("[18~") \n \
+		~Shift	<Key>F8:	string(0x1b)	string("[19~") \n \
+		~Shift	<Key>F9:	string(0x1b)	string("[20~") \n \
+		~Shift	<Key>F10:	string(0x1b)	string("[21~") \n \
+		~Shift	<Key>F11:	string(0x1b)	string("[23~") \n \
+		~Shift	<Key>F12:	string(0x1b)	string("[24~") \n \
+		Shift   <Key>F1:	string(0x1b)	string("[23~") \n \
+		Shift   <Key>F2:	string(0x1b)	string("[24~") \n \
+		Shift   <Key>F3:	string(0x1b)	string("[25~") \n \
+		Shift   <Key>F4:	string(0x1b)	string("[26~") \n \
+		Shift   <Key>F5:	string(0x1b)	string("[28~") \n \
+		Shift   <Key>F6:	string(0x1b)	string("[29~") \n \
+		Shift   <Key>F7:	string(0x1b)	string("[31~") \n \
+		Shift   <Key>F8:	string(0x1b)	string("[32~") \n \
+		Shift   <Key>F9:	string(0x1b)	string("[33~") \n \
+		Shift   <Key>F10:	string(0x1b)	string("[34~") \n \
+		Shift   <Key>F11:	string(0x1b)	string("[28~") \n \
+		Shift   <Key>F12:	string(0x1b)	string("[29~") \n \
+			<Key>Print:	string(0x1b)	string("[28~") \n \
+			<Key>Cancel:	string(0x1b)	string("[29~") \n \
+			<Key>Pause:	string(0x1b)	string("Om") \n \
+			<Key>Insert:	string(0x1b)	string("[2~") \n \
+			<Key>Delete:	string(0x1b)	string("[3~") \n \
+			<Key>Home:	string(0x1b)	string("[1~") \n \
+			<Key>End:		string(0x1b)	string("[4~") \n \
+			<Key>Prior:	string(0x1b)	string("[5~") \n \
+			<Key>Next:	string(0x1b)	string("[6~") \n \
+			<Key>BackSpace:	string(0x7f)	\n \
+			<Key>Num_Lock:	string(0x1b)	string("OP") \n \
+			<Key>KP_Divide:	string(0x1b)	string("OQ") \n \
+			<Key>KP_Multiply: string(0x1b)	string("OR") \n \
+			<Key>KP_Subtract: string(0x1b)	string("OS") \n \
+			<Key>KP_Add:	string(0x1b)	string("Ol") \n \
+			<Key>KP_Enter:	string(0x1b)	string("OM") \n \
+			<Key>KP_Decimal: string(0x1b)	string("On") \n \
+			<Key>KP_0:	string(0x1b)	string("Op") \n \
+			<Key>KP_1:	string(0x1b)	string("Oq") \n \
+			<Key>KP_2:	string(0x1b)	string("Or") \n \
+			<Key>KP_3:	string(0x1b)	string("Os") \n \
+			<Key>KP_4:	string(0x1b)	string("Ot") \n \
+			<Key>KP_5:	string(0x1b)	string("Ou") \n \
+			<Key>KP_6:	string(0x1b)	string("Ov") \n \
+			<Key>KP_7:	string(0x1b)	string("Ow") \n \
+			<Key>KP_8:	string(0x1b)	string("Ox") \n \
+			<Key>KP_9:	string(0x1b)	string("Oy") \n \
+		~Shift	<Key>Up:		string(0x1b)	string("[A") \n \
+		Shift	<Key>Up:		scroll-back(1,lines) \n \
+		~Shift	<Key>Down:	string(0x1b)	string("[B") \n \
+		Shift	<Key>Down:	scroll-forw(1,lines) \n \
+			<Key>Right:	string(0x1b)	string("[C") \n \
+			<Key>Left:	string(0x1b)	string("[D")' \
+		-e telnet $HOST
+
+ +

How do I set the title?

+The control sequences are documented in +ctlseqs.ms; +a copy is contained in the xterm.tar.gz file. +

+The usual context for this question is setting the title according to +the current working directory. +People post answers to this periodically on the newsgroups. +Here is one that I have seen, +from Roy Wright <nobody@roystoy.dseg.ti.com>. +In your /etc/profile after: +


+	if [ "$SHELL" = "/bin/pdksh" -o "$SHELL" = "/bin/ksh" ]; then
+		PS1="! $ "
+	elif [ "$SHELL" = "/bin/zsh" ]; then
+		PS1="%m:%~%# "
+	elif [ "$SHELL" = "/bin/ash" ]; then
+		PS1="$ "
+	else
+		PS1='\u@\h:\w\$ '
+	fi
+
+

+add: +


+	if [ "$TERM" = "xterm" ]; then
+		PS1="\033]2;\u@\h:\w\007bash$ "
+	fi
+
+

+The terminator "\007" is a problem area. Xterm historically uses this +character, though it is non-ANSI. The "correct" character should be +a "\233" string terminator, or "\033\\", which is the 7-bit equivalent. +XFree86 xterm recognizes either (the "\007" or string terminator); +waiting for the first of these. +

+You may have resource or environment problems that prevent you from +setting the title at all. Newer xterms (starting somewhere in X11R5) +use the $LANG variable. If your locale is incorrectly installed, you +will be unable to set the xterm's title. +As noted by Mikhail Teterin <mi@rtfm.ziplink.net>: +Make sure that the locale (LANG and/or LOCALE environment variable) +is known to X Window System. +Check ${X11ROOT}/lib/X11/locale.* for it. +If it is not listed in either one of the files, find +the nearest match and add an alias to it. +Restart X if you have made changes. +

+On a related note, some people want to know how to read the title +from an xterm. +This works for XFree86 xterm and dtterm, but not for other variations: +


+	#!/bin/ksh
+	# Echo the current X term title bar to standard output.
+	# Written by Icarus Sparry <icarus@bath.ac.uk> 11 Apr 1997
+	#
+	exec </dev/tty
+	old=$(stty -g)
+	stty raw -echo min 0  time ${1-10}
+	print "\033[21t\c" > /dev/tty
+	IFS='' read -r a
+	stty $old
+	b=${a#???}
+	print -R "${b%??}"
+
+But it is possible to avoid escape sequences altogether (from +Hemant Shah <shah@typhoon.xnet.com>): +

+	$ xprop -id $WINDOWID | grep WM_NAME
+	WM_NAME(STRING) = "this is my title"
+	current_title=$(xprop -id $WINDOWID | grep WM_NAME | cut -d= -f2)
+
+Here's another source of information: +Xterm-Title HowTo + +

How do I make the cursor blink?

+Standard xterm does not implement a blinking cursor. +Some of the variations do: +dtterm, +GNOME Terminal, +and XFree86 xterm +(from mid 1999, patch 107). + +

Frequent problems

+ + +

My terminal doesn't show box characters

+Xterm displays the 7-bit ASCII and VT100 graphic characters (including +box corners) using specially arranged fixed-pitch fonts. The first +32 glyph positions (which would correspond to nonprinting control +characters) are used to hold the VT100 graphic characters. Some +fonts that otherwise look fine (such as courier) do not have glyphs +defined for these positions. So they display as blanks. +Use xfd to display the font. +

+XFree86 xterm can form its own line-drawing characters +(see patch 90, for example). +It does not draw all of the graphic characters, only those that +may be done with straight lines. But those are the most used, +making most of the fixed-pitch fonts useful for xterm. +

+You may also have a problem with the terminfo description. +As distributed, the X11R6 terminfo for xterm does not have the +acsc string defined, so most implementations of curses +do not try to use the alternate character set. +

+Finally, some people confuse the VT100 graphic characters with the VT220 +support for DEC technical character set. +These are distinct (7-bit) character sets. +Xterm currently does not support this. + +

The bold font is ugly

+Xterm lets you directly specify one bold font, which is assumed to +correspond to the default font. +Older versions of xterm make a fake bold font for the other choices +via the fonts menu by drawing the characters offset by one pixel. +I modified xterm to ask the font server for a bold font that corresponds +to each font (other than the default one). +Usually that works well. +However, sometimes the font server gives a poor match. +Xterm checks for differences in the alignment and size, +but the font server may give incorrect information about the font size. +The scaled bitmap font feature gives poor results for the smaller fonts. +In your X server configuration file, that can be fixed by disabling +the feature, e.g., +by appending ":unscaled" to the path: +

+	FontPath	"/usr/lib/X11/fonts/100dpi/:unscaled"
+	FontPath	"/usr/lib/X11/fonts/75dpi/:unscaled"
+	FontPath	"/usr/lib/X11/fonts/misc/:unscaled"
+
+ +

I see little dots on the screen

+Well, I do. +Perhaps you do not. +It depends on the fonts you choose, and how you use them. +

+Standard xterm has a "normal" font for which a bold font can be chosen, +and several alternative fonts, useful for changing the font size. +The alternative fonts do not have corresponding bold fonts. +Xterm simulates bold fonts in this case by overstriking the character +one pixel offset. That can make an bold character extend into the +area that another character occupies. When erasing a bold character from +the screen, xterm does not erase the extra pixel. + +This is corrected in XFree86 xterm, +subject to the available fonts +(from late 1998, patch 85). +For each font, it asks the font server for a corresponding bold font. +Your font server may not have the bold font (or it may incorrectly +report that it does). But it usually works. + +

My terminal doesn't display Cyrillic characters

+Cyrillic encodings typically use characters in the range 128-159. +For a VT220 (or any terminal that follows ISO 6429), those are treated +as control characters. +Still, some people want to use KOI8-R, etc. +I modified xterm in +patch 175 +to add an option (-k8) +and corresponding resource settings to allow them to customize their +environment. +Here is a +sample script and +resource file which +I use for testing this configuration. + +

My terminal doesn't recognize color

+First, ensure that you have set up xterm to render color. +The XFree86 xterm renders color only if you have set resources +to do this; the default behavior is monochrome to maintain compatibility +with older applications. +The manual page describes these resources. +I set them in my .Xdefaults file. +

+Even if you set the resources properly, there may be another application +running which prevents xterm from allocating the colors you have specified. +But you should see a warning message for this. +

+Check the terminal description, to see if it is installed properly, +e.g., for +ncurses, which uses terminfo. +

+Finally, some applications (that do not interface properly with terminfo +or termcap) may need the environment variable +$COLORTERM to be set. + +

Why is my screen size not set?

+Well, it may be set, but not correctly. You may notice these symptoms: +
    +
  • When editing with vi, you cannot see the beginning of the file, or +
  • Running +
    
    +	stty -a
    +
    +shows the rows and/or columns values as 0, or some other value (such as 65) +which has nothing to do with the actual window size. +
+Xterm knows how big the screen is (of course), and tries to tell your +applications (e.g., by invoking ioctl's and sending SIGWINCH). But sometimes +it cannot: +
    +
  • Xterm itself may have been built incorrectly +(the #ifdef's that make the logic work are inactive). +
  • You may be running xterm via a remote connection which refuses to pass +that information. This can happen even on "modern" networks where the connection +crosses domain boundaries. +
  • You may be running su'd to another account. +SIGWINCH is just another signal; signals do not propagate for security reasons. +
+Most full-screen applications such as vi are designed to use the ioctl +calls that return the screen size. When they fail, the applications +use the size defined in the terminal's terminfo or termcap description. +

+You may be able to use the resize program to issue the ioctl's +that will notify your application of the actual screen size. This does not +always work for the reasons just mentioned. +Newer versions of stty let you specify the screen size, though it will not +be updated if you resize the xterm window: +


+	stty rows 24 columns 80
+
+Most full-screen applications also +check if the $LINES and $COLUMNS variables are set, using those values to +override the terminal description: +

+	setenv LINES 24
+	setenv COLUMNS 80
+
+Why 65 lines? The standard xterm terminfo description specifies 65 lines, +perhaps because someone liked it that way. Real VT100's are 24 lines. +I once used (and wrote applications for) a Bitgraph terminal, which +emulated VT100, but displayed 65 lines. + +

Why can't I use the pageup/pagedown keys?

+Some vendors, e.g,. Sun, have added key translations which make the +pageup and pagedown keys talk to the xterm's scrollbar instead of your +application. +They did the same thing for the home and end keys, thereby obscuring +a bug in xterm. +

+You can override this by specifying your own translations in your resource +file. +Use the translations in +


+	/usr/lib/X11/app-defaults/XTerm
+
+as a guide. +The relevant section of the app-default file looks like +

+	*VT100.translations:    #override \
+		@Num_Lock<Key>KP_0: string(0)\n\
+		@Num_Lock<Key>KP_1: string(1)\n\
+		@Num_Lock<Key>KP_2: string(2)\n\
+		@Num_Lock<Key>KP_3: string(3)\n\
+		@Num_Lock<Key>KP_4: string(4)\n\
+		@Num_Lock<Key>KP_5: string(5)\n\
+		@Num_Lock<Key>KP_6: string(6)\n\
+		@Num_Lock<Key>KP_7: string(7)\n\
+		@Num_Lock<Key>KP_8: string(8)\n\
+		@Num_Lock<Key>KP_9: string(9)\n\
+		@Num_Lock<Key>KP_Add: string(+)\n\
+		@Num_Lock<Key>KP_Decimal: string(.)\n\
+		@Num_Lock<Key>KP_Divide: string(/)\n\
+		@Num_Lock<Key>KP_Enter: string(\015)\n\
+		@Num_Lock<Key>KP_Equal: string(=)\n\
+		@Num_Lock<Key>KP_Multiply: string(*)\n\
+		@Num_Lock<Key>KP_Subtract: string(-)\n\
+		<Key>Prior:scroll-back(1,page)\n\
+		<Key>Next:scroll-forw(1,page)\n\
+		<Key>F16: start-extend() select-end(PRIMARY, CUT_BUFFER0, CLIPBOARD) \n\
+		<Key>F18: insert-selection(PRIMARY, CLIPBOARD) \n\
+		<Key>F27: scroll-back(100,page) \n\
+		<Key>R13: scroll-forw(100,page) \n\
+		<Key>Home: scroll-back(100,page) \n\
+		<Key>End: scroll-forw(100,page) \n
+
+For example, a more-specific pattern for the resource name lets you override: +

+	XTerm*VT100.translations:       #override \n\
+		~Shift<Key>Home:  string(\033[1~)\n\
+		~Shift<Key>End:   string(\033[4~)\n\
+		~Shift<Key>Prior: string(\033[5~)\n\
+		~Shift<Key>Next:  string(\033[6~)\n\
+		Shift<Key>Prior:  scroll-back(1,page) \n\
+		Shift<Key>Next:   scroll-forw(1,page) \n\
+		Shift<Key>Home:   scroll-back(100,page) \n\
+		Shift<Key>End:    scroll-forw(100,page) \n
+
+makes the home/end and pageup/pagedown keys usable by your editor, +while leaving their shifted equivalents available for the scrollbar. + +

Why can't I use the home/end keys?

+This is a long story, +unless you are referring to X Consortium xterm. +That program is simply broken in this respect. +

+At the beginning, when the home/end keys were fixed for XFree86 xterm +(in early 1996), there was some discussion regarding what the escape +sequences should be for those keys (for the 6-key editing keypad). +Those were chosen as "PC-style" codes (like SCO "ansi"), i.e., +

+	ESC [ H
+	ESC [ F
+
+for normal mode, and +
+	ESC O H
+	ESC O F
+
+for cursor application mode. +

+That style of coding fit easily into the existing logic of xterm. +It was not my change, and (because xterm should be based upon standards), +I did question this, and asked the opinion of the person who was at that +time developing rxvt. +He had chosen a layout based on DEC's VT220 terminals, +though the key labels on the typical PC keyboard did not +match. +At that point, neither of us knew enough to make a good case for this. +

+Somewhat later I could see that xterm had a number of undocumented +extensions to support the VT220-style (pre-ISO 2022) character sets. +I decided to complete the functionality by making xterm a VT220 emulator. +This would require that it provide the same escape sequences for the +editing and numeric keypads. +I could not simply change the escape sequences from "PC-style" to "VT220-style", +since a number of users "knew" that the keypad "ought to" send home, end, +cursor keys, etc., because they had labels indicating that use. +To retain compatibility (but allow easy reconfiguration to make a VT220 +emulator), I added popup-menu items to switch between the modes. +With minor refinements, this was the approach for about two years, +culminating with the "stable" patch #88, +which is essentially the version distributed with XFree86 3.3.x. +

+
NOTE: +
the terminfo distributed with xterm patch #88 is incorrect: +the escape sequences given for home/end keys are +the VT220-style, rather than the default PC-style. +Too accustomed to switching modes on the fly, I overlooked a line in +my .Xdefaults file: +

+		*sunKeyboard: true
+
+Downstream packagers (when they noticed this) +accommodated the bug by modifying the VT100 translations +resource which is not a good technical solution since it interferes with +the users' ability to modify that resource. +See this for more discussion. +
+ +But xterm continues to evolve past the stable patch #88. +The keyboard support was still unsatisfactory for two reasons: +
    +
  • some users wanted to be able to use applications that detected whether + the control key was pressed (e.g., control/F1). +
  • the compromises made for xkb with X11R6 interfered with + xterm's use of the NumLock key for the numeric keypad. +
+The former could be addressed by expanding the escape sequences sent by the +PC-style function keys, +while the latter was a VT100/VT220 design issue. +I decided to redesign function-key support to separate the two styles of +function keys better, but leaving the choice still controlled by the +sunKeyboard resource. +Partway through that, I was asked to do similar cleanup and redesign of +the backspace and delete key handling, e.g., +the ptyInitialErase resource. +Because it is a redesign, I chose to not make the keyboard differences +between the old and new xterms completely compatible. +If you were to run both on the same system, one or the other would have +some problems with the editing keypad or the backspace/delete keys +which would be addressed by the popup-menu selections. +

+For example, at this time (2001/9/4): +

    +
  • Debian stable is xterm-88c, which should be identical to the XFree86 3.3.6 +version, but is not (there are some label differences in the resource-file, but +nothing interesting relative to home/end keys). +And of course, Debian changes +the terminfo kbs from ^H to ^?. +As noted, the terminfo I wrote for XFree86 3.3.x has an error. +Setting +
    
    +		*sunKeyboard: true
    +
    +in the app-defaults file fixes the problem with xterm-88, which was that I +documented in the terminfo the behavior with that resource set. +Similarly, setting +
    
    +		*backarrowKey: false
    +
    +is one way to address Debian's change to kbs. + +
  • Debian unstable is xterm-149. +Other than omitting the color resources from +the app-defaults file, I see that it sets + *backarrowKeyIsErase: true +which would not affect the home/end keys. +(The color resources are redundant, so that is not a problem either). +
+Here is a resource file +which I tested with xterm-88c, xterm-149 and xterm-158, +using $TERM set to xterm-debian. + +

Why can't I use the cursor keys in (whatever) shell?

+VTxxx (VT100 and up) terminals may send different escape sequences for +the cursor (arrow) keys depending on how they are set up. +The choices are referred to as the normal and application modes. +Initially, the terminal is in normal mode. +

+VTxxx terminals are usually set up so that +full-screen applications will use +the cursor application mode strings. +This is good for full-screen +applications, including legacy applications which may have hard-coded +behavior, but bad for interactive shells (e.g., ksh, tcsh, bash) +which use arrow keys to scroll through a history of command strings. +

+To see the difference between normal/application modes, consider this example: +

    +
  • In normal (non-application) mode, the terminal transmits a down-arrow + as \E[C, which happens to echo as a down-arrow. + +
  • In application mode the terminal transmits \EOC, which echoes as C. + That is because the \EO is the SS3 control, which says to use the + character from the G3 character set for the next cell. +
+Since termcaps and terminfo descriptions are written for +full-screen applications, shells and similar programs often +rely on built-in tables of escape sequences which they use instead. +Defining keys in terms of the termcap/terminfo entry (e.g., by capturing +the string sent by tputs) is apt to confuse the shell. +

+Depending on the terminal type, +the keypad(s) on the keyboard may switch modes along with the +cursor keys, or have their own independent modes. +The control sequences for these are independent of the ones used for +cursor-addressing, but are grouped together, e.g., as the +terminfo smkx and rmkx capabilities. +Terminfo entries are written assuming that the application has initialized +the terminal using the smkx string before it is able to +match the codes given for the cursor or keypad keys. + +

Why can't I cut/paste in xterm?

+When an application sets xterm to any of its mouse tracking modes, it reserves +the unshifted mouse button clicks for the application's use. +Unless you have modified the treatment of the shifted mouse button events +(e.g., with your window manager), you can always do cut/paste by pressing +the shift key while clicking with the mouse. + +

Why does $LD_LIBRARY_PATH get reset?

+If xterm is running setuid (which is needed on some systems which have +no wrappers for opening pty's and updating utmp), newer systems automatically +set or reset environment variables which are considered security problems. +These include $PATH and $LD_LIBRARY_PATH, since +they affect the choice of which programs are run if not specified via a +full pathname. +

+This means, for example, that if you attempt to run +


+	xterm -e foo
+
+where foo is a program that uses shared libraries in +/usr/local/lib, then the command will fail, because +/usr/local/lib is not considered part of root's +environment. +

+Modern Unix systems (such as recent Solaris and HPUX versions) do not require +you to run xterm setuid. Some will result in odd malfunctions if you do this. + +

Why do the -e and -ls options not work together?

+Xterm has two useful options for controlling the shell that is run: +
+
-e +
tells xterm to execute a command using the remaining parameters after +this option. +
-ls +
tells xterm to invoke a login shell, making it read your .login +file, for instance. +
+The two are not compatible. +If you specify both, xterm uses -e, and if that fails for +whatever reason will fall through to the -ls option. +It cannot (in general) combine the two, since some shells permit this +(e.g., bash), and others do not (e.g., tcsh). + +

I need /etc/termcap

+If you have a termcap version of xterm on a system with no termcap libraries, +you may also be missing /etc/termcap. +

+A workaround is to copy /usr/X11R6/lib/X11/etc/xterm.termcap to +/etc/termcap. +

+This is fixed another way starting with XFree86 3.3.1. +If xterm cannot find the terminal description, it will accept that, +though it will print a warning. If xterm does not find the termcap +entry, it will not set the $TERMCAP variable. + +

Xterm does not run (no available pty's)

+Your copy of xterm may not have enough permissions to use existing pty's: +
    +
  • you may have to make xterm run setuid to root +(though newer systems have wrappers that make this unnecessary). +
  • the pty's permissions may be restrictive (that is ok, but you have +to make xterm agree with it). +Usually this is done by making the group ownership of the pty's "tty", +and requiring that xterm run setgid to "tty". +This is done rather than make xterm run setuid to root, since that +presents problems with security. +
  • newer systems (with Unix98 pty's) have a single entry under /dev +which has to have the right permissions. +For example: +
    
    +	# ls -l /dev/ptmx
    +	crw-rw----    1 root     tty        5,   2 Aug 21 20:19 /dev/ptmx
    +
    +
+

+Perhaps your system does not have enough pty's, or (problems +reported with newer Linux kernels supporting Unix98 pty's, +beginning with RedHat 6.0) the major device +numbers of the pty's may have changed during a kernel upgrade. +(This is described in /usr/src/linux/Documentation). +

+See also the MAKEDEV script, which usually exists under /dev. + +

Reverse video is not reset

+When running less or other programs that do highlighting, +you see the highlighting not turned off properly. +

+This may be due to incompatible terminal descriptions for xterm. +With XFree86 3.2, I modified the terminal description for XFree86 +xterm to use the VT220 (aka ISO 6429) controls that allow an application +to turn off highlighting (or bold, underline) without modifying the +other attributes. The X Consortium xterm does not recognize these +controls. +

+If, for example, you are running an older xterm and rlogin to a system +where the newer xterm has been installed, you will have this problem, +because both programs default to $TERM set to xterm. +The solution for mixed systems is to install the newer terminal description as +as a different name (e.g., xterm-color) +and set the termName +resource accordingly in the app-defaults file for the system which has the +newer xterm. +

+However - see below. + +

What $TERM should I use?

+

+The xterm-color value for $TERM +is a bad choice for XFree86 xterm because it is +commonly used for a terminfo entry which happens to not support bce. +Complicating matters, FreeBSD (after dithering for a few years on the matter) +introduced a bastardized version which implies the opposite sense of bce, +(because it uses SGR 39 and 49), but does not set it. +The most recent version +provides the xterm-xfree86 entry which is distributed with +XFree86 xterm (which corresponds to the one distributed with ncurses). +

+The term "bce" stands for "back color erase". +Terminals such as XFree86 xterm +and rxvt implement back color erase, others such as dtterm do not. +(Roughly half of the emulators that I know about implement bce). +When an application clears the screen, a terminal that implements back +color erase will retain the last-set background color. A terminal +that does not implement back color erase will reset the background color +to the default or initial colors. Applications that paint most of the +screen in a single color are more efficient on terminals that support +back color erase. +

+Curses libraries that support color know about bce and do the +right thing - provided that you tell them what the terminal does. +That is the whole point of setting $TERM. +The "xterm-color" description distributed with ncurses does not list +bce, because it was applied originally to a terminal type +which does +not implement back color erase. +It will "work" for XFree86 xterm, +though less efficient. Some other applications such as the slang library +have hardcoded support for terminals that implement back color erase. +Given the "xterm-color" description, those will be efficient - and +fortuitously work. However, slang (through version 1.4.0) does not +work properly for the terminals that xterm-color was designed for. +See this page for an example +of (n)curses and slang running on dtterm. +That bug in slang is reported to be fixed for succeeding versions, though +your application may require changes to use this fix. +(The demo which comes with slang to illustrate the use of bce +does not work properly, for instance). +

+The xterm-color value for $TERM +is also (for the same reason) a bad choice for rxvt, but +"works" due to the large number of hard-coded applications that override +this. +

+Some people recommend using xtermc. +That is installed on Solaris. +However, it does not match any xterm in current use. +(Apparently it was written for an obsolete version on Unixware). +The colors work, true, but the mouse will not, nor will the function keys. + +

FVWM does weird things when I try to resize xterm

+I have an old (3.1.2G) bug report for xterm which may be related to the +second (3.9s) problem: +
    +
  • Steven Lang <tiger@ecis.com> reports a problem with extra resize +events for xterm. +

    +When I change font size often I will get the double-refresh, and when that +happens the text program gets 2 resize events.. Running a quick test, I +got this: Going to a bigger font, it got a 53x20 resize, then a 80x24 +resize. Going to a smaller font, it got a 120x27 resize, then a 80x24 +resize. +

    +Earlier I made a mention of changing font size in rxvt (And xterm does it +to) causing 2 resize events. Well I just happened to do it in fvwm +(Instead of fvwm 95) and found it seems to be a 'feature' of fvwm95, not +XFree86 as I'd initially assumed. +

  • Stephen Marley <stephen@memex.com> reports a problem with the active +icon (from X11R6.3 xterm): +

    +Using the XFree86 xterm-53 with the active icon feature on, I get +some problems resizing where the xterm window shrinks as small +as possible and won't stay at whatever size you set it thereafter. +

    +Comment out the PixmapPath and IconPath from your .fvwmrc file to +disable the fvwm icons and restart the WM. +Start an xterm. +Iconify xterm and maximize it again. +Use resize button or corners to resize the xterm. +

    +The xterm now shrinks to a tiny size and attempts to resize it +result in it shrinking again. +

    +I've tried this with fvwm 1.23 and fvwm 2.0.46 with the same results. +Olvm, olvwm and twm all behave correctly so it may be a fvwm problem. +

+I have not observed the first, but have reproduced the second. + +

Why doesn't the screen clear when running vi?

+Under SunOS 4.x, the termcap description for xterm embeds in the +ti and te capabilities a command to switch to +xterm's alternate screen (e.g., while running vi), and return +to the normal screen on exit. +This has the effect of clearing the screen. +Under Solaris 2.x, the terminfo description does not use the alternate +screen (it is a matter of preference after all), so that the text from +vi remains on the screen after exit. +There are corresponding terminfo symbols for +ti and te: +smcup and rmcup, respectively. +

+This is configurable. +

+For example (from Bjorn Helgaas <helgaas@dhc.net>) +this procedure adds these capabilities to the "xterm" +terminfo definition on HP-UX 10.20: +


+	cp /usr/lib/terminfo/x/xterm /usr/lib/terminfo/x/xterm.orig
+	untic xterm > /tmp/xterm.src
+	echo " smcup=\E7\E[?47h, rmcup=\E[2J\E[?47l\E8," >> /tmp/xterm.src
+	tic /tmp/xterm.src
+
+In this example, the terminfo strings are a series of operations: +
+
smcup +
\E7 saves the cursor's position +
\E[?47h switches to the alternate screen +
rmcup +
\E[2J clears the screen (assumed to be the alternate screen) +
\E[?47l switches back to the normal screen +
\E8 restores the cursor's position. +
+

+However, xterms that are linked with termcap are more flexible in this area +than those linked with terminfo libraries. +The xterm program supports a resource titeInhibit which +manipulates the $TERMCAP variable to accomplish this. It sets the $TERMCAP +variable for the client with the ti and te capabilities +suppressed. +Systems that use terminfo cannot do this. If you are running terminfo +with the alternate screen controls in the terminal description, then +you can suppress the switching to the alternate screen by the +titeInhibit, but not the associated cursor save/restore +and clear-screen operations. +

+XFree86 3.9s xterm implements a different set of controls +(private setmodes 1047, 1048 and 1049) which address +this (in addition to the older set of controls, for compatibility). +The new set of controls implements the entire ti sequence +(save cursor, switch to alternate screen, clear screen) +and te +(switch to normal screen, restore cursor) +as two control sequences that can be disabled by titeInhibit. +

+The 1049 code is a refinement of 1047 and 1048, clearing the alternate +screen before switching to it rather than after switching back to the +normal screen. +This allows you (with a popup menu entry designed to exploit this behavior) to +switch the display back to the alternate screen to select text from it, +to paste into the normal screen. +You can also set or clear the titeInhibit resource using another +popup menu entry (Enable Alternate Screen Switching). + +

Why is the cursor misplaced after running vi?

+Vi and other full-screen applications use the termcap ti/te (terminfo +smcup/rmcup) strings to initiate and end cursor addressing mode. +As mentioned in the discussion of titeInhibit, +full-screen applications can expect the initialization string to save +the cursor's position, and the end-string to restore it. +

+A few applications (reportedly IRIX 5.x and 6.x vi +incorrectly move the cursor before initializing cursor-addressing. +This will cause the end-string to restore the cursor to its position +when it was saved by the initialization string (typically at the +upper left corner of the screen). +

+The usual reason is due to the cursor save/restore controls in +the ti/te strings. If your application runs a subprocess +which in turn runs another full-screen application (or when reinitializing +the screen after the shell process), it will save the +cursor position again, so the position which is restored when finally +exiting your program is the last one saved, not the first. +XFree86 xterm +(from late 1998, patch 90) +changes the behavior of the cursor save/restore +operations so they apply only to the current screen. +That makes it less likely to misplace your cursor. + +

Why doesn't the scrollbar work?

+Originally xterm was built using imake rather than a configure script. +One feature of imake that is not possible to guess within the +configure script is the wide-prototype compile-time definition +NARROWPROTO. When this is not set properly, the Athena widget +scrollbars do not work properly. xterm's configure script has a +fallback case which allows disabling imake. However, this is moot +with the Xorg "modular" build, whose compiler options are unrelated to +imake or older versions of any libraries that it may distribute. In +this case, the configure script needs some help. Use this option to +enable or disable NARROW proto (and disable imake with the +--disable-imake option) to match the whims of Xorg hackers. +

+For instance +


+	configure --disable-imake --disable-narrowproto
+
+ +

Why doesn't my delete key work?

+This seems to be a problem with the older XFree86 release (3.1.2). +I have picked up pieces of the story (xterm and the keyboard work as +designed under XFree86 3.2 and up). +

+The underlying problem is that we've accumulated three things that are +being equated as "Delete": +

+	ASCII backspace (code 8)
+	ASCII delete (code 127)
+	VT220 "remove" aka "delete" (ESC [ 3 ~)
+
+

+You are probably talking about the backarrow key +(on my keyboard, at the upper right of the QWERTY block), +or the key labeled delete which is on the 6-key "editing keypad". +Since xterm is emulating a VT100/VT220, +the backarrow key should generate a 127 (often displayed as ^?). +You would use a control/H to obtain a backspace on a real VT220. +

+Tastes differ on Unix, people expect the backarrow key to generate a backspace +(or not). As I understand it, at one point, XFree86 picked up the sense of the +erase character during initialization, so that xterm would in effect use the +same erase character as the console. The current scheme (X11R6) uses keyboard +mapping tables that are independent of the environment. +

+XFree86 xterm provides a resource toggle backarrowKey +(and an escape sequence from VT320) +that changes this key between the two styles (backspace or delete). +

+With XFree86 xterm +patch 95 +(also in the stable version as "88c"), +you may have an xterm which can +automatically initialize the backarrow key to backspace or delete +depending on the pseudo terminal's sense, or based on the termcap +setting of kbs (backspace key). +This feature is controlled by the resource setting ptyInitialErase. + +

Why did my delete key stop working?

+Well, something changed. +You have to determine what did. +

+This may be because an upgrade introduced different X resource settings, +or because you are using the newer xterm with the +ptyInitialErase resource (or perhaps both). +Use +


+	appres XTerm
+
+to see the X resources that you are using, in particular the +translation (or +Translation) +resource for the vt100 widget. +

+One unexpected scenario came out of hiding when I was implementing the +ptyInitialErase resource. When xterm is (by default) built +to support this, it sets the pty's erase character to match the +termcap entry. Xterm also sets the $TERMCAP environment variable to match. +So everything is consistent, and everything defined. +The stty erase character is either backspace (^H) or delete (^?). +

+The problem arises because there are two things called "delete", +which were not well-defined: ASCII delete (127) and the PC-style +adaptation of VT220 remove assigned to the key Delete. +

+However, the screen program prefers to make the termcap +delete (kD) an <escape>[3~, which corresponds to the VT220 +remove key. +If $TERMCAP is set when starting screen, it will translate stty's +erase character into the <escape>[3~, making most curses and +termcap applications work. +But stty still has the original erase character. +So low-level applications which check stty will not work. +I found that unsetting $TERMCAP before running would work, but this +was not a good solution. +Someone pointed out +(see patch 129), +that the problem really was because termcap kD should delete +the character at the current position. So it cannot be the same +as stty erase. +

+As a matter of fact, stty erase has to be a single character, +so <escape>[3~ would not work anyway. + +

Well, how can I set my delete key?

+When people first started asking this question in 1995-1996, +it appeared in the context of making Netscape work. +Netscape's use of the delete key running in X did not match user's expectations +when compared to that other platform. +They were commonly advised to use xmodmap, e.g., +

+	keysym BackSpace = Delete
+
+or +

+	keycode 22 = 0xff08
+
+Either way is a bad technical solution - it works for some people +but not others (on my keyboard at work, keycode 22 is the numeric +keypad '9'). +

+Alternatively, you can set resources. +This works reasonably well for environments where you have +different versions of xterm, e.g., +


+	XTerm*VT100.translations: #override \n\
+		<Key>Delete: string(0x7f)
+
+I do not do that either, because it is not flexible. +Not all programs use the same sense of +stty erase; +some use termcap or terminfo, +and some are hardcoded. +So I prefer to be able to switch the xterm's keyboard at runtime. +You cannot do that with resources. +(Or not really - xterm has a keymap() action which could +support this if you provided a rather complex resource settings, but +the X library support for that is broken in X11R6). +Instead, I have added to XFree86 a set of resources (and popup menu entries) +to allow simple switching between the different styles of keyboard, +in particular for the backspace/delete issues. +See the manual page for + backarrowKey + backarrowKeyIsErase and + deleteIsDEL +as well as + sunKeyboard. + +

Why doesn't my keypad work?

+A few people have commented that the keypad does not work properly. +Aside from bugs (I have fixed a few), the most common problem seems +to be misconception. +

+Here's a picture of the VT100 numeric keypad: +

+	+-----+-----+-----+-----+
+	| PF1 | PF2 | PF3 | PF4 |
+	+-----+-----+-----+-----+
+	|  7  |  8  |  9  |  -  |
+	+-----+-----+-----+-----+
+	|  4  |  5  |  6  |  ,  |
+	+-----+-----+-----+-----+
+	|  1  |  2  |  3  |     |
+	+-----+-----+-----+ ENT +
+	|     0     |  .  |     |
+	+-----+-----+-----+-----+
+
+and the similar Sun and PC keypads: +
+	+-----+-----+-----+-----+
+	| NUM |  /  |  *  |  -  |
+	+-----+-----+-----+-----+
+	|  7  |  8  |  9  |     |
+	+-----+-----+-----+  +  +
+	|  4  |  5  |  6  |     |
+	+-----+-----+-----+-----+
+	|  1  |  2  |  3  |     |
+	+-----+-----+-----+ ENT +
+	|     0     |  .  |     |
+	+-----+-----+-----+-----+
+
+Working in X11, the NUM (NumLock) key has better uses than an alias +for PF1 (and is sometimes reserved). I use the F1 through F4 on the keyboard +to implement PF1 through PF4, alias the keypad "+" to "," and use the existing +"-" key. +

+VT220 emulation uses the VT100 numeric keypad as well as a 6-key editing +keypad. +Here's a picture of the VT220 numeric keypad: +

+	+--------+--------+--------+
+	| Find   | Insert | Remove |
+	+--------+--------+--------+
+	| Select | Prev   | Next   |
+	+--------+--------+--------+
+
+and the similar Sun and PC keypads: +
+	+--------+--------+--------+
+	| Insert | Home   | PageUp |
+	+--------+--------+--------+
+	| Delete | End    | PageDn |
+	+--------+--------+--------+
+
+

+I chose to use keys that are mnemonic rather than in the "same" positions, +though some emulators (e.g., Tera Term) use the same positions: +

+	+--------+--------+--------+
+	| Insert | Find   | Prev   |
+	+--------+--------+--------+
+	| Remove | Select | Next   |
+	+--------+--------+--------+
+
+

+I test the keyboard (for VT52/VT100/VT220) using +vttest. +If you find (or think that you have found) a problem with the keyboard +handling of xterm, please test it with vttest first. +

+Other arrangements of the keyboard are possible of course. +If you prefer to use the top row of the numeric keypad as PF1 through PF4, +you should do this using xterm's X resources. + +

Why can't I input 8-bit characters?

+You must have the eightBitInput resource set to do this. + +

My .Xdefaults for XTERM

+

+	XTerm*internalBorder:  10
+	XTerm*highlightSelection:  true
+	XTerm*VT100.colorBDMode:  on
+	XTerm*VT100.colorBD:  blue
+	XTerm*VT100.colorULMode:  on
+	XTerm*VT100.colorUL:  magenta
+	XTerm*VT100.eightBitInput:  true
+	XTerm*VT100.eightBitOutput:  true
+	XTerm*scrollBar:  true
+	XTerm*VT100.titeInhibit:  true
+
+	XTerm*VT100.colorMode:  on
+	XTerm*VT100.dynamicColors:  on
+
+	! Uncomment this to use color for underline attribute
+	XTerm*VT100.colorULMode:  on
+	XTerm*VT100.underLine:  off
+
+	! Uncomment this to use color for the bold attribute
+	XTerm*VT100.colorBDMode: on
+
+	XTerm*VT100.color0: black
+	XTerm*VT100.color1: red3
+	XTerm*VT100.color2: green3
+	XTerm*VT100.color3: yellow3
+	XTerm*VT100.color4: blue3
+	XTerm*VT100.color5: magenta3
+	XTerm*VT100.color6: cyan3
+	XTerm*VT100.color7: gray90
+	XTerm*VT100.color8: gray30
+	XTerm*VT100.color9: red
+	XTerm*VT100.color10: green
+	XTerm*VT100.color11: yellow
+	XTerm*VT100.color12: blue
+	XTerm*VT100.color13: magenta
+	XTerm*VT100.color14: cyan
+	XTerm*VT100.color15: white
+	XTerm*VT100.colorUL: yellow
+	XTerm*VT100.colorBD: white
+
+	XTerm*VT100.cursorColor: lime green
+
+
+XFree86 xterm comes with two copies of the resource file, +one with color only (XTerm-col.ad, +which is installed as XTerm-color), +and the regular one (XTerm.ad, +installed as XTerm). +To use the XTerm-color file in conjunction +with a separate XTerm app-defaults +file which does not contain color, +add the following line to your .Xdefaults file: +

+	*customization: -color
+
+ +

Why are the menus tiny?

+Everything seems to work, except that the +xterm menus (VT options, fonts, etc.) do not display +properly; the menus pop up, but only with a tiny display +area in which none of the options are visible (and only +part of the menu title is visible). +

+You have specified the geometry for xterm too high in the hierarchy, and that +24x80 (or whatever the -geometry parameter happens to be) is applying to the +menus in pixels. +This resource makes the geometry apply to the menus as well as the VT100 widget: +


+	XTerm*geometry: 80x24
+
+while this applies only to the VT100 widget +(which is probably what you intended): +

+	XTerm.VT100.geometry: 80x24
+
+or better yet (to allow for the toolbar option, which uses a level of +widget hierarchy): +

+	XTerm*VT100.geometry: 80x24
+
+ +

What is this warning message?

+
+
xterm: Error 11, errno 22: permission denied +
Actually, any message like this denotes a failure which requires +studying the xterm source to determine the exact problem. +

+You have either found a bug in xterm, or there is something wrong +with your computer's configuration, e.g., not enough pty's, +incorrect permissions, etc. +

+The first number is an internal code (defined in error.h in xterm's source), +and the second is the system error number (defined in /usr/include/sys/errno.h). +The system error number is easier to lookup, but the internal error code +tells you where to look in the source. +

input method doesn't support my preedit type +
Ignore this if you do not know what input method is. +Input methods are used to enter composite characters (e.g., umlauts, +other types of punctuated characters, East Asian characters, etc). +Your computer's libraries support this, but are missing configuration +tables, and xterm is warning you. +

+If the message bothers you (e.g., if you aren't starting xterm from +a window manager menu), you can suppress it by setting a resource: +


+		XTerm*openIm:false
+
+ +
Warning: Actions not found: ignore, "xxx" +
The action "xxx" (for example "scroll-back") is specified in a resource +file whose translations match widgets that do not support them. +For example, this +

+		XTerm*translations:     #override\n\
+			<Leave>, ~Ctrl ~Meta <Btn2Up>: ignore()\n\
+			~Shift <Key>KP_8: scroll-back(1,line)\n\
+			~Shift <Key>KP_2: scroll-forw(1,line)\n\
+			Shift <Key>KP_8: scroll-back(1,halfpage)\n\
+			Shift <Key>KP_2: scroll-forw(1,halfpage)
+
+will produce warnings such as +

+		Warning: Actions not found: ignore, scroll-back, scroll-forw
+		Warning: Actions not found: ignore, scroll-back, scroll-forw
+		Warning: Actions not found: ignore, scroll-back, scroll-forw
+
+This is a correct form, assigning the actions to the "VT100" widget. +

+		XTerm*VT100.translations:     #override\n\
+			<Leave>, ~Ctrl ~Meta <Btn2Up>: ignore()\n\
+			~Shift <Key>KP_8: scroll-back(1,line)\n\
+			~Shift <Key>KP_2: scroll-forw(1,line)\n\
+			Shift <Key>KP_8: scroll-back(1,halfpage)\n\
+			Shift <Key>KP_2: scroll-forw(1,halfpage)
+
+ +
Warning: Cannot allocate colormap entry for "xxx" +
This comes from the X library. +XFree86 xterm uses the default color map. +What this means is that if your X server has insufficient space to +store color information for more than one color map, other applications +which could use other color maps may conflict with xterm. +In practice, that is 256 unique colors on the screen at a time -- not enough +for a fancy background or an application such as Netscape. +

+During resource initialization, xterm attempts to allocate an entry from +the color map for each color which it might use. +If there are not enough free slots in the color map, you will see a +"Cannot allocate" message for each color that xterm failed to allocate. +Those colors will be rendered in the foreground color, +making full-screen color applications +such as dialog unreadable. +

+This problem is alleviated with +patch 129, +which modified xterm to delay the most color allocation until +the colors are first needed. If a color is never needed +(xterm allocates 20 colors in this manner), +that reduces the number of slots in the color map that are needed. +Even with this improvement, xterm must still allocate 4 colors during +initialization to determine how to display the cursor. +If none of those colors can be allocated, XFree86 xterm reverts to monochrome. +

+ +

Known Bugs in XTERM

+These are the known bugs (or limitations) in the XFree86 xterm. +They are also present in the other versions based on the X Consortium +sources (color_xterm, ansi_xterm, kterm). +

+Note that of the emulators that support color, most do not support +bce (back color erase). +The bce capability is also called the +"new color model", though it has been implemented in the IBM PC for +quite a while. +Technically, not implementing bce +(or allowing the choice between it and its complement) is not a bug, +since few hardware terminals (with good reason) implemented this feature. +

    +
  • cut/paste does not select tabs; instead spaces are selected. +This is because the selection works from the array of displayed +characters, on which tab/space conversion has already been performed. +
  • does not implement the autorepeat feature of VTxxx terminals. +
+ +

X11R6.3 XTERM

+The X Consortium version of xterm (and versions based on it) has +additional bugs not in XFree86 xterm: +
    +
  • the program must be run with fixed (nonproportional) fonts. +
  • the home and end keys do not generate usable escape sequences, due to +an indexing error. +(Note that it is possible to work around this using the VT100 translations +resource, but usually this is not done). +
  • the Main Options menu is improperly constructed, due to incorrect +indices after removing the logging toggle. +This makes the list of signals off by one. +
  • very large screens (e.g., by using nil2 for a font) cause core dumps +because the program uses a fixed array (200 lines) for adjusting pointers. +
  • certain types of key translations cause a core dump because the program +does not check the event class before attempting to use events. +
+(These bugs are also present in the X11R5 version). +

+Update 2004/04/08: +
+Complicating this discussion is the recently-released "X.Org" xterm. +That is the XFree86 xterm from XFree86 CVS +with all visible "xfree86" strings changed to "X.Org" or "xorg", +depending on the use. +For example the "xterm-xfree86" terminfo entry becomes "xterm-xorg". +The change history for the related CVS for X.Org shows this. +Similarly, the release notes for X11R6.7 include my notes for XFree86 4.4. +It is of course too soon to see the overall impact of this, +so I'll update this FAQ as I find it necessary. + +

COLOR_XTERM +download

+This is based on the X Consortium X11R5 source, with the same bugs. +
    +
  • implements non-bce color model +
  • moving the cursor is reported to leave trails of incorrect color +
  • clearing the screen resets colors (arguably this is a limitation). +
+Not exactly a bug, but it does not build on Linux with X11R6.3 + +

ANSI_XTERM +download

+This is based on the X Consortium source, with the same bugs. +
    +
  • implements non-bce color model +
  • fails +vttest +by not rendering reverse-video screen +
+ +

CXTERM +download

+CXterm stands for "Chinese Xterm". +This is based on the X Consortium source. + +

DTTERM

+This is distributed with CDE. +It implements more of the DEC VT220 than the X Consortium xterm, +and also adds controls to manipulate the window and icon. +
    +
  • implements non-bce color model +
  • fails +vttest +by clearing its background to solid white rather +than preserving its sense in response to ED. +
  • under some circumstances, scrolling margins are not recognized. +For instance, running +vile +which uses scrolling margins, we see text overwriting the status line. +
+ +

EMU 1.3 +download

+This is not based on the X Consortium source. +The authors state that it implements VT220 emulation. +It is in need of maintenance, since it builds with some problems to produce +an executable that (on Linux and SunOS) does not handle the carriage return +and newline translations properly. +So I am unable to run +vttest +on this emulator. + +

ETERM +link

+Eterm was based on rxvt, though the appearance differs. +The terminal emulation capabilities appear similar, though +I am not able to run the full suite of tests in +vttest +with this emulator (the core dump noted for rxvt, as well as hanging while +awaiting response from one or more control sequences). +Oddly, it appears that neither Eterm nor rxvt implement CPR +(cursor position report). +Finally, it reserves F1 (function-key) for a popup menu. +This applies to versions of Eterm through 0.9. + +

GNOME TERMINAL +link

+GNOME Terminal is developed separately from both xterm and rxvt, +and is based on the zvt (zterm) widget. +Like +kvt), +it appears to have been developed imitating other terminal emulators +(Linux console and xterm) rather than strictly emulating a VT102. +The documentation is fragmentary (with a comment suggesting that the +author does not know where to find relevant information), and the +program fares badly with +vttest. +Beginning with late 1999, reports indicate that it +does not properly parse ANSI control +sequences: the vim editor is using XFree86 xterm's vt220-style +"Send Device Attributes" (Secondary DA) control sequence to obtain the +terminal emulator's version. +That is, it sends +

+	\E[>c
+
+expecting a response such as +

+	\E[>0;138;0c
+
+for vt100. +The bug report indicates that the "c" sent by vim is echoed rather than +interpreted by the emulator. +

+But it suffices for vi. +

+Even the most recent GNOME Terminal (version 1.4.0.4, late 2001) +does not implement a complete vt102: it is missing several features +which can be demonstrated in +vttest). +Most of the bugs in the Device Attributes +responses remain, but it works a little better with vim. +However, there are problems with the alternate screen that show up with vim. +Again, these can be demonstrated with vttest (menu 11.6.3 in the 20011130 snapshot). + +

MULTI GNOME TERMINAL (MGT) +link

+Of particular note, MGT 1.4.0 announcement claims that it works properly +for all of vttest)'s tests. +On the positive side, it does do VT52 emulation, but (reading the +source code did not help) it apparently does not really do VT220 +from vttest's perspective. + +

HANTERM +download

+HanTerm stands for "Hangul term" (Korean). +This is based on the XFree86 source. + +

KONSOLE +link

+More than just a rewrite of kvt into C++. +But there are several incompatibilities between konsole 1.0.2 (late 2001) +and xterm: +
    +
  • none of the selections of keyboard mappings match the actual behavior + of xterm (a few come close, but do so by matching the terminfo + descriptions rather than the programs). In particular, the application + keypad does not send vt100-style escapes. +
  • vttest) demonstrates that + konsole does not properly ignore escape sequences + to switch character sets that it does not support. + Also, + the developers of konsole did use an old version of vttest, but + that was to add a bogus Device Attributes response (claimed to + be for "vt220", but not corresponding to any that DEC produced). + They do not use the newer version of vttest (which was available more + than a year before development of konsole began). +
  • konsole implements several features from XFree86 xterm, but some are + done incorrectly. + In particular, the private setmode 1049 + does not save and restore the cursor, + causing the cursor to be in unexpected locations + after exiting a fullscreen application such as vi. +
+ +

KTERM +download

+KTerm stands for "Kanji term" (Japanese). +This is based on the X Consortium source, with the same bugs +(though the list of original authors has been removed; the modifications +that comprise kterm is relatively small). +
    +
  • implements non-bce color model +
  • implements status line, but uses non-DEC escape sequences for this. +
+There is a variation of xvt (ancestor of rxvt) originally known as +kvt +bundled with +KDE +which may be referred to as +"kterm", but I do not find it interesting, +other than to comment that it was a poor choice of name. + +

MLTERM

+Mlterm is not based on xterm or rxvt source, +though it implements many of their features. +It does fairly well with +vttest, +except for some odd misbehavior in +operations that save/restore the cursor position. + +

MTERM

+There are a few variants of this: the xterm bundled with some Motif clients +is more common. +More interesting, however is one (not Motif) +which is not readily available any longer, attributed to "Der Mouse". +
+ (mouse@Lightning.McRCIM.McGill.EDU) + Available: larry.mcrcim.mcgill.edu (132.206.1.1) in + /X/mterm.src/mterm.ball-o-wax. +
+I saw only an incomplete version of this while it was advertised +in the mid-90's. +It is available by email from <mouse@Rodents.Montreal.QC.CA>. +This is not a patched version of xterm, +though it was apparently written, like rxvt, to emulate vt100's. +While it does have some interesting features (such as blinking characters), +overall it does not do as well with +vttest) +as the more widely known emulators. + +

MXTERM

+There are several variants on this: xterm adapted for Motif libraries. +I have seen none that work properly: +
    +
  • MXTERM: +a motif Xterm with character attributes color rendered +I've noticed this one only recently. +It is a reworking of the earlier patches for color_xterm +(credited to Erik Fortune at SGI) +and the Motif widgets +(apparently first done by Ivan M. Hajadi at SGI in 1991, +but credited in this release to Mahesh Neelakanta, for Motif 1.2.4). +
  • ANSI Xterm with Motif Scrollbar +Usually seen as the ansi-xterm-R6-motif-sb patch, I used this as the +starting point for changes to my #82 patch of xterm in August 1998. +

    +The original patch changes only the scrollbars to Motif, leaving the +popup menus in Athena widgets. +That was not what I wanted. +My motivation for using Motif is not for performance or esthetics, of course, +but to make it simpler to build on hosts that have no Athena widgets installed. +

    +I set those changes aside, having found (the hard way) that the Motif library +has hardcoded behavior regarding the control right-mouse button. +According to the O'Reilly book on Motif programming (volume 6), it does +a server grab when processing menus. +Making the menus behave just as in the Athena widgets can cause the +X server to hang. +(I was able to do this with both Lesstif and Motif libraries). +Given that, I decided to restructure the menus entirely, making a toolbar +which could support at compile-time either widget set. +

  • mxterm +This is a different reworking of the Motif widget patch, +using a 1993 version (ignoring the more recent 1994 patches noted above). +However, it appears to have the same technical defect that I noted above. +
+ +

NXTERM

+Distributed with Redhat Linux 5.2, +it is a repackaging of xterm-sb_right-ansi, to use the +Xaw3d widget set. This is based on the X Consortium X11R6 source, with the +same bugs. +
    +
  • implements non-bce color model +
  • does not implement SGR 39 and SGR 49, all attributes are reset when changing colors. +
  • popup menus do not appear to work. +
+Starting with Redhat 6.0, nxterm is the XFree86 3.3.6 xterm. +Unfortunately Redhat neglected to update their termcap for nxterm to match +the program. + +

RXVT +link

+Rxvt's manual page states the following unqualified comment: +
+ rxvt, version 2.6.2, is a colour vt102 terminal emulator + intended as an xterm(1) replacement for users who do not + require features such as Tektronix 4014 emulation and + toolkit-style configurability. As a result, rxvt uses + much less swap space -- a significant advantage on a + machine serving many X sessions. +
+How much is much less? +Perhaps not as much as one would think from reading that. +The Tektronix emulation in xterm +(which has been optional since late 1997) +accounts for about 25kb of the code. +The toolkit-style configurability glibly referenced is the ability to +redefine keys on the keyboard without recompiling the program, +i.e., the translations resource. +The toolkit-style configurability +accounts for about 300kb, which does add up if you happen to be +running 50 xterm processes (i.e., about 10Mb). +Compared with something like GNOME Terminal, which takes 2-3 times, +or KDE konsole, which takes 15-20 times as much memory to run, +xterm and rxvt memory requirements are indistinguishable to the normal user. +

+These comments apply to versions of rxvt through 2.21: +

    +
  • clearing the screen resets colors +
  • does not have a delete key +
  • the implementation of ech (erase characters) does not +follow DEC VT220 (also ISO 6429), causing applications using this function to +misbehave. +
+A new version +(upgraded to an beta as of 2.6.PRE3, however, since it no longer dumps core in +vttest) +is reported to fix the ech bug. +However, it is less VT100-compatible than the earlier versions such as 2.21b +because it does not render reverse video (DECSCNM) properly. +All versions do not update the screen frequently enough, making animation +ineffective. +See vttest, tests 1 and 2. + +

XGTERM +link

+It has some features which are also in color_xterm:(non-bce ANSI color, +colorBD and colorUL resources, cursor warping, etc. +The main feature is its Tektronix graphics emulation, +which is the main reason for this particular program. +Neither program has a change-log, so it is not easy to say which +influenced the other. +

+That is from reading the source code. +However testing under Debian Linux, something is wrong with the resource +processing (neither popup menus nor colors work). + +

XITERM +link

+This appears to be rxvt 2.20, +lightly reformatted, +with a few ifdef's changed. +

+That is, it was. +The name was later appropriated by a different +program, +which also uses the name iterm. +Like gnome-terminal, +iterm aims to be an xterm-emulator +rather than a VT102- or VT220-emulator. +

+An earlier attempt by the same author +(the "CSI-xterm") +incorporates some of the changes I made for XFree86 xterm +via cut and paste +(but does not mention this in its README). +It is said to be the basis for Solaris 10 xterm. +

+Both have similar problems running +vttest. + +

How do I build XTERM?

+Building a copy of xterm is simple, provided that you have a development +configuration for X11: +
    +
  • Header files and libraries. +If you do not have the header files (usually under /usr/include/X11) for +your system, you are better off building the libraries yourself. +Xterm can be built with either X11R5 or X11R6 libraries; however X11R6 +requires much more data to be installed before xterm will run. +Xterm uses the Xaw library for popup menus. +
  • imake and xmkmf. +These utilities produce a Makefile from the Imakefile. +They are not essential, but useful, particularly on systems with +unusual configurations. +
+If you have a working xmkmf script (or correctly configured imake utility), +all you need to do is type +

+	xmkmf
+	make
+
+I have written a simple configure script for xterm which uses imake +(or xmkmf) to generate a Makefile from the Makefile.in. +I plan to restructure xterm to eliminate the hardcoded +#ifdef's, replacing them with definitions that can be derived +with the configuration script. +The configure script is more flexible than xmkmf, since it +allows you to enable or disable a variety of features. +Type +
+	configure --help
+
+to get a list of options. +

+Though I plan to replace the hardcoded ifdef's with +autoconfigured values, it will still continue to build properly with the imake environment, +since that is how large distributions incorporate xterm. + +

How do I report bugs?

+You should report bugs to +me. +I also respond to bug reports in a number of bug-tracking systems, +though some are less open to searches than others. +See also +Analyzing problems with configure scripts + +

Additional Information

+There appears to be no comprehensive source of information on xterm +better than the documentation which comes with the source code. +I have found Richard Shuford's +archive +to be invaluable for notes on the DEC VT220 and related terminals. +Though not available at the time that I was collecting most of my notes, +VT100.net is also a good source of primary +information. +

+The command-line options, X resources and similar configurable options +of xterm are documented in the manual page. +Control sequences, i.e., programming information are in the +ctlseqs.ms file which I bundle with the program source. +(It used to be in the same directory in the X distribution, but was moved +to a difference part of the tree some time ago). Note that you must format +this file with different options than a manpage, e.g., +


+	tbl ctlseqs.ms | nroff -ms >ctlseqs.txt
+	tbl ctlseqs.ms | groff -ms >ctlseqs.ps
+
+As a PostScript file, the individual letters of the control sequences are +all boxed, for emphasis, but I find the text file equally readable. + +

Ongoing/future work

+
    +
  • soft (downloadable) fonts +
  • search scrollback +It would be nice to be able to search the scrollback buffer. +
  • printer interface +

    +Done, except for the corresponding support in the VT52 emulation. +It would be nice to have a dialog to control this. +

  • allow alternate libraries for popup-menus and dialogs +

    +My configure script currently provides tests for the variations of Athena +widgets (Xaw3D, neXtaw). +I intend to make additional changes to support +Motif scrollbars and menus. +Motif requires a different style of interface for the menus: +binding a popup menu to control right mouse may cause the server to hang. +As an intermediate step, I implemented a toolbar for the Athena widgets. +In turn, that works well enough except with XFree86 4.x: +the Xaw library geometry management is broken. +(Other implementations of the Athena widgets work well enough). +

  • popup window that shows hex code for content of a character cell +and hexadecimal keyboard entry for all Unicode characters (ISO 14755) +
  • correct cut&paste of TAB character +
+ + + --- xterm-229.orig/debian/patches/900_debian_xterm.diff +++ xterm-229/debian/patches/900_debian_xterm.diff @@ -0,0 +1,155 @@ +$Id$ + +Make Debian-specific tweaks to xterm: +* Set the default VT widget foreground and background colors to gray90 on + black, which approximates the color scheme of the Linux virtual console + (and approximates actual DEC VT terminals far more closely than + black text on a white background in any case). +* Stop using an Xaw7 gradient for the backgrounds of the xterm menus; it + produces an unappealing effect if the menus are configured to use a + larger font than the stock configuration (also, xterm has added items to + some menus since I last calculated the gradient size and I can't be + bothered to do it again). +* If the X server is capable of color and has more than 8 planes of color + depth available, set the menu colors to gray15 on antique white, and + customize the appearance VT widget's scrollbar. Otherwise, do not eat up + precious entries in the color palette. +* Set the "backarrowKeyIsErase" and "ptyInitialErase" parameters to true by + default. +* Define the "xterm-debian" terminal type in the termcap and terminfo + files; it is based on "xterm-new" with the exception that the backspace + is VT220-conformant, as directed by section 9.8 of the Debian Policy + Manual. + +This patch by Branden Robinson. + +Index: termcap +=================================================================== +--- termcap.orig 2007-06-17 22:24:53.000000000 +0100 ++++ termcap 2007-06-17 22:24:57.000000000 +0100 +@@ -73,6 +73,14 @@ + :so=\E[7m:sr=\EM:st=\EH:te=\E[?1049l:ti=\E[?1049h:\ + :ue=\E[24m:up=\E[A:us=\E[4m:ve=\E[?25h:vi=\E[?25l: + ++# xterm-debian is identical to xterm-new except that it more strictly ++# conforms to DEC VT220 behavior in the case of the backspace key; this is ++# mandated by Section 9.8 of the Debian Policy Manual. Also see ++# . ++xd|xterm-debian|Debian xterm (VT220-conformant backspace):\ ++ :kb=^?:\ ++ :tc=xterm-new: ++ + # The xterm-new description has all of the features, but is not completely + # compatible with vt220. If you are using a Sun or PC keyboard, set the + # sunKeyboard resource to true: +@@ -234,5 +242,6 @@ + # is widely used for a variety of incompatible terminal emulations including + # color_xterm and rxvt. + v0|xterm|X11 terminal emulator:\ +- :tc=xterm-new: ++ :tc=xterm-debian: ++# :tc=xterm-new: + # :tc=xterm-r6: +Index: terminfo +=================================================================== +--- terminfo.orig 2007-06-17 22:24:53.000000000 +0100 ++++ terminfo 2007-06-17 22:24:57.000000000 +0100 +@@ -885,6 +885,13 @@ + u8=\E[?1;2c, + u9=\E[c, + vpa=\E[%i%p1%dd, ++# xterm-debian is identical to xterm-new except that it more strictly ++# conforms to DEC VT220 behavior in the case of the backspace key; this is ++# mandated by the Section 9.8 of the Debian Policy Manual. Also see ++# . ++xterm-debian|Debian xterm (VT220-conformant backspace), ++ kbs=\177, ++ use=xterm-new, + # + # The xterm-new description has all of the features, but is not completely + # compatible with vt220. If you are using a Sun or PC keyboard, set the +@@ -1664,5 +1671,6 @@ + # is widely used for a variety of incompatible terminal emulations including + # color_xterm and rxvt. + xterm|X11 terminal emulator, +- use=xterm-new, ++ use=xterm-debian, ++# use=xterm-new, + # use=xterm-r6, +Index: XTerm.ad +=================================================================== +--- XTerm.ad.orig 2007-06-17 22:24:53.000000000 +0100 ++++ XTerm.ad 2007-06-17 22:24:57.000000000 +0100 +@@ -116,6 +116,10 @@ + *tek4014*font3: 6x13 + *tek4014*fontSmall: 6x10 + ++! Debian package customizations follow. ++*backarrowKeyIsErase: true ++*ptyInitialErase: true ++ + ! If xterm is built with a toolbar, the widget hierarchy looks like this, + ! showing widget name / class names. The complete menu hierarchy is built + ! at startup because it is needed to make the layout work for the menubar: +Index: XTerm-col.ad +=================================================================== +--- XTerm-col.ad.orig 2007-06-17 22:24:53.000000000 +0100 ++++ XTerm-col.ad 2007-06-17 22:24:57.000000000 +0100 +@@ -7,9 +7,9 @@ + *VT100*boldColors: on + *VT100*dynamicColors: on + +-! Uncomment this for "white" text on a dark background. +-!*VT100*foreground: gray90 +-!*VT100*background: black ++! Set the default text foreground and background colors. ++*VT100*foreground: gray90 ++*VT100*background: black + + ! - OR - + ! Uncomment this for black text on a "white" background. +@@ -114,20 +114,32 @@ + *Form.background: AntiqueWhite + *form.background: AntiqueWhite + ++*mainMenu*background: AntiqueWhite ++*mainMenu*foreground: gray15 ++*vtMenu*background: AntiqueWhite ++*vtMenu*foreground: gray15 ++*fontMenu*background: AntiqueWhite ++*fontMenu*foreground: gray15 ++*tekMenu*background: AntiqueWhite ++*tekMenu*foreground: gray15 ++ + ! The following two sections take advantage of new features in version 7 +-! of the Athena widget library. Comment them out if you have a shallow +-! color depth. ++! of the Athena widget library; see Xaw(7x). ++ ++! This section is commented out because Xaw has no way to dynamically size ++! the gradient. The dimension parameter may need to be adjusted depending ++! on the font used in the menu. + !*SimpleMenu*backgroundPixmap: gradient:vertical?dimension=350&start=gray90&end=gray60 + !*SimpleMenu*foreground: gray15 + +-!*VT100.scrollbar.thumb: vlines2 +-!*VT100.scrollbar.width: 14 +-!*VT100.scrollbar.background: gray60 +-!*VT100.scrollbar.foreground: rgb:a/5/5 +-!*VT100.scrollbar.borderWidth: 0 +-!*VT100.scrollbar.displayList:\ +-!foreground gray90;\ +-!lines 1,-1,-1,-1,-1,1;\ +-!foreground gray60;\ +-!lines -1,0,0,0,0,-1 ++*VT100.scrollbar.thumb: vlines2 ++*VT100.scrollbar.width: 14 ++*VT100.scrollbar.background: gray60 ++*VT100.scrollbar.foreground: rgb:a/5/5 ++*VT100.scrollbar.borderWidth: 0 ++*VT100.scrollbar.displayList:\ ++foreground gray90;\ ++lines 1,-1,-1,-1,-1,1;\ ++foreground gray60;\ ++lines -1,0,0,0,0,-1 + #endif --- xterm-229.orig/debian/patches/901_xterm_manpage.diff +++ xterm-229/debian/patches/901_xterm_manpage.diff @@ -0,0 +1,24 @@ +$Id$ + +Make Debian-specific tweaks to xterm manpage: +* Use FHS paths to the utmp and wtmp files in xterm's manpage. + +This patch by Branden Robinson and David Martínez. + +Index: xterm.man +=================================================================== +--- xterm.man.orig 2007-07-23 03:03:23.000000000 +0200 ++++ xterm.man 2007-07-23 03:03:58.000000000 +0200 +@@ -4620,10 +4620,10 @@ + .SH FILES + The actual pathnames given may differ on your system. + .TP 5 +-\fI/etc/utmp\fP ++\fI/var/run/utmp\fP + the system logfile, which records user logins. + .TP 5 +-\fI/etc/wtmp\fP ++\fI/var/log/wtmp\fP + the system logfile, which records user logins and logouts. + .TP 5 + .I __apploaddir__/XTerm --- xterm-229.orig/debian/patches/series +++ xterm-229/debian/patches/series @@ -0,0 +1,2 @@ +900_debian_xterm.diff -p0 +901_xterm_manpage.diff -p0 --- xterm-229.orig/debian/rules +++ xterm-229/debian/rules @@ -0,0 +1,216 @@ +#!/usr/bin/make -f +# $Id$ + +# Debian rules file for xterm source package + +# Copyright 2005 David Martínez Moreno +# +# Licensed under the GNU General Public License, version 2. See the file +# /usr/share/common-licenses/GPL or . + +# debhelper +export DH_OPTIONS + +# force quilt to not use ~/.quiltrc +QUILT = quilt --quiltrc /dev/null +# force QUILT_PATCHES to the default in case it is exported in the environment +QUILT_PATCHES = patches/ + +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) +DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) + +ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE)) + confflags += --build $(DEB_HOST_GNU_TYPE) +else + confflags += --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE) +endif + +CFLAGS = -g -Wall +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif + +# Figure out who's building this package. +BUILDER:=$(shell echo $${DEBEMAIL:-$${EMAIL:-$$(echo $$LOGNAME@$$(cat /etc/mailname 2> /dev/null))}}) + +# Set some Imake variables for the regular and server-debugging builds. +TIMESTAMP:=$(shell env TZ=UTC date +%Y%m%d%H%M%S) + +HTML2TEXT:=lynx -dump -nolist + +STAMP_DIR:=stampdir + +DEBINSTALLTREE:=$(CURDIR)/debian/tmp + +DESKTOP_FLAGS = --vendor debian \ + --dir=$(DEBINSTALLTREE)/usr/share/applications + +# Set up the $(STAMP_DIR) directory. +.PHONY: stampdir +stampdir: $(STAMP_DIR)/stampdir +$(STAMP_DIR)/stampdir: + mkdir $(STAMP_DIR) + >$@ + +# Set up the package build directory as quilt expects to find it. +.PHONY: prepare +prepare: $(STAMP_DIR)/prepare +$(STAMP_DIR)/prepare: $(STAMP_DIR)/stampdir + mkdir $(STAMP_DIR)/patches $(STAMP_DIR)/log + echo 2 >$(STAMP_DIR)/patches/.version + ln -s debian/patches patches + ln -s $(STAMP_DIR)/patches .pc + >$@ + +# Apply all patches to the upstream source. +.PHONY: patch +patch: $(STAMP_DIR)/patch +$(STAMP_DIR)/patch: $(STAMP_DIR)/prepare + @echo -n "Applying patches... " + @if $(QUILT) push -a -v > $(STAMP_DIR)/log/patch 2>&1; then \ + cat $(STAMP_DIR)/log/patch; \ + echo "successful."; \ + else \ + cat $(STAMP_DIR)/log/patch; \ + echo "failed! (Check $(STAMP_DIR)/log/patch for details)"; \ + exit 1; \ + fi; \ + + touch $@ + +# Revert all patches to the upstream source. +.PHONY: unpatch +unpatch: + rm -f $(STAMP_DIR)/patch + @if [ -e $(STAMP_DIR)/patches/applied-patches ]; then \ + echo -n "Unapplying patches... "; \ + if $(QUILT) pop -a -v > $(STAMP_DIR)/log/unpatch 2>&1; then \ + cat $(STAMP_DIR)/log/unpatch; \ + echo " successful."; \ + else \ + cat $(STAMP_DIR)/log/unpatch; \ + echo " failed! (Check $(STAMP_DIR)/log/unpatch for details)"; \ + exit 1; \ + fi; \ + fi + +configure: $(STAMP_DIR)/patch $(STAMP_DIR)/configure +$(STAMP_DIR)/configure: $(STAMP_DIR)/patch + dh_testdir + [ -d obj-$(DEB_BUILD_GNU_TYPE) ] || mkdir obj-$(DEB_BUILD_GNU_TYPE) + cd obj-$(DEB_BUILD_GNU_TYPE) && \ + ../configure --enable-logging --enable-wide-chars --enable-luit \ + --with-tty-group=tty --enable-256-color \ + --prefix=/usr --exec-prefix=/usr --mandir=/usr/share/man \ + --with-app-defaults=/etc/X11/app-defaults \ + --disable-imake --enable-narrowproto --enable-exec-xterm \ + $(confflags) DESKTOP_FLAGS="$(DESKTOP_FLAGS)" CFLAGS="$(CFLAGS)" + touch $@ + + +.PHONY: build +build: $(STAMP_DIR)/build +$(STAMP_DIR)/build: $(STAMP_DIR)/configure debian/local/xterm.faq.gz + dh_testdir + cd obj-$(DEB_BUILD_GNU_TYPE) && $(MAKE) + touch $@ + +.PHONY: clean +clean: unpatch + dh_testdir + dh_testroot + rm -f .pc patches + rm -rf $(STAMP_DIR) + rm -rf obj-$(DEB_BUILD_GNU_TYPE) + dh_clean debian/local/xterm.faq.gz + +.PHONY: install +install: build + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + # General installation + cd obj-$(DEB_BUILD_GNU_TYPE) && \ + $(MAKE) install mandir=/usr/share/man/man1 libdir=/etc DESTDIR=$(DEBINSTALLTREE) + + ## Install lxterm command and manual page. + install -m 755 debian/local/lxterm $(DEBINSTALLTREE)/usr/bin + install -m 755 debian/local/lxterm.1 $(DEBINSTALLTREE)/usr/share/man/man1 + ## Install koi8rxterm command, manual page, and app-defaults file. + install -m 755 debian/local/koi8rxterm $(DEBINSTALLTREE)/usr/bin + install -m 755 debian/local/koi8rxterm.1 $(DEBINSTALLTREE)/usr/share/man/man1 + install -d $(DEBINSTALLTREE)/etc/X11/app-defaults + install -m 644 debian/local/KOI8RXTerm $(DEBINSTALLTREE)/etc/X11/app-defaults + ## Install manual page for uxterm. + install -m 644 debian/local/uxterm.1 $(DEBINSTALLTREE)/usr/share/man/man1 + ## Install terminfo and termcap precompiled definitions. + install -d $(DEBINSTALLTREE)/usr/lib + install -m 644 termcap $(DEBINSTALLTREE)/usr/lib/xterm.termcap + install -m 644 terminfo $(DEBINSTALLTREE)/usr/lib/xterm.terminfo + dh_installdocs + dh_installchangelogs + dh_installmenu + dh_install --sourcedir=debian/tmp --list-missing + # Lintian overrides. + cp debian/xterm.overrides $(CURDIR)/debian/xterm/usr/share/lintian/overrides/xterm + +# Generate plain text XTerm FAQ from HTML. +debian/local/xterm.faq.gz: debian/local/xterm.faq.html + $(HTML2TEXT) $< >debian/local/xterm.faq + # dh_compress doesn't recognize this file extension, so we must + # compress it manually. + gzip -9f debian/local/xterm.faq + +.PHONY: binary +binary: binary-arch + +.PHONY: binary-arch +binary-arch: install + dh_testdir + dh_testroot + dh_strip + dh_compress + dh_fixperms + chown :utmp debian/xterm/usr/bin/xterm + chmod g+s debian/xterm/usr/bin/xterm + dh_installdeb + dh_makeshlibs + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +# this target is required by policy +.PHONY: binary-indep +binary-indep: + +# Note: This rule is for Debian package maintainers' convenience, and is not +# needed for conventional build scenarios. +.PHONY: patch-audit +patch-audit: prepare unpatch + touch stampdir/log/patch; \ + FUZZY=no; \ + while [ -n "`$(QUILT) next`" ]; do \ + RESULT=`$(QUILT) push -v | tee -a stampdir/log/patch | grep ^Hunk | sed 's/^Hunk.*\(succeeded\|FAILED\).*/\1/'`;\ + case "$$RESULT" in \ + succeeded) \ + echo "The patch is fuzzy: `$(QUILT) top`"; \ + echo "The patch is fuzzy: `$(QUILT) top`" > stampdir/log/`$(QUILT) top`; \ + FUZZY=yes; \ + ;; \ + FAILED) \ + echo "The patch is broken: `$(QUILT) next`"; \ + echo "The patch is fuzzy: `$(QUILT) next`" > stampdir/log/`$(QUILT) next`; \ + exit 1; \ + ;; \ + esac; \ + done; \ + if [ $$FUZZY = "yes" ]; then \ + echo "There were fuzzy patches. Please Fix."; \ + exit 1; \ + fi + +# vim:set ai noet sw=8 ts=8 tw=0: --- xterm-229.orig/debian/watch +++ xterm-229/debian/watch @@ -0,0 +1,2 @@ +version=3 +ftp://invisible-island.net/xterm/ xterm-(.*).tgz --- xterm-229.orig/debian/xterm.README.Debian +++ xterm-229/debian/xterm.README.Debian @@ -0,0 +1,50 @@ +Debian README for xterm package +=============================== + +Newcomers to the X Window System should first read the Debian X FAQ +(Frequently Asked Questions list): /usr/share/doc/x11-common/FAQ.gz. +You can view this file with your favorite pager program after decompressing +it. For example: + $ zcat /usr/share/doc/x11-common/FAQ.gz | pager + +As of version 3.3.4-1, xterm logs to the wtmp and lastlog files. If you do +not have a utmp group on your system, xterm will be installed setuid root +instead of setgid utmp. xterm drops its root privileges after it +initializes, so if it is setuid this can result in corrupt wtmp entries. +The best thing to do is make a utmp group in /etc/group, or upgrade to +version 2.0.3.4 or later of the base-passwd package, so that you have a +utmp group. + +The xterm terminal type on a Debian system is an alias for xterm-debian. +This means that "xterm" and "xterm-debian" are interchangeable as values of +the $TERM environment variable in the shell. Since the xterm-debian type +is typically not found on non-Debian systems, xterm is used as the system +default. + +The terminal description for xterm-debian differs from that of +xterm-xorg in exactly two respects: + 1. kbs is defined as ^? (ASCII 127), not ^H (ASCII 8) + 2. kdch1 is defined as the sequence: ^[ [ 3 ~ (no spaces, and ^[ is ASCII + 27, a.k.a ESCAPE) instead of ^? (ASCII 127) +^[[3~ is the DEC VT220 escape sequence for the keypad delete key (not the +numeric keypad, the one with Page Up, Page Down, etc. on a PC keyboard). +DEC VT100's, the text terminal wich xterm was designed to emulate, had no +keypad delete key. ^[[3~ is also what the Linux console terminal type +generates for the keypad delete key. Note that the terminal definitions +that a Debian system uses are in the ncurses-term package, not in the xterm +package itself, though the (pre-compiled) terminfo and termcap files that +Debian uses may be found in the xterm documentation directory, +/usr/share/doc/xterm. People interested in reading further to stock up +ammo for their backspace/delete and terminal type wars should consult Tom +Dickey's (current maintainer of the xterm source code) FAQ, available in +the file /usr/share/doc/xterm/xterm.faq{html,text.gz} and the website +. + +The default keymappings for xterm are different than they are upstream to +comply with the Debian Keyboard Policy and make xterm's behavior more +consistent with the Linux virtual console (and therefore with the behavior +of DEC VT 220 terminals). + +$Id$ + +vim:set ai et sw=4 ts=4 tw=80: --- xterm-229.orig/debian/xterm.dirs +++ xterm-229/debian/xterm.dirs @@ -0,0 +1,4 @@ +usr/bin +usr/share/man/man1 +etc/X11/app-defaults +usr/share/lintian/overrides --- xterm-229.orig/debian/xterm.doc-base.ctlseqs +++ xterm-229/debian/xterm.doc-base.ctlseqs @@ -0,0 +1,9 @@ +Document: xterm-ctlseqs +Title: Xterm Control Sequences +Author: Edward Moy, Stephen Gildea, Thomas Dickey +Abstract: This document describes the terminal control sequences that XTerm + recognizes. +Section: XShells + +Format: text +Files: /usr/share/doc/xterm/ctlseqs.txt.gz --- xterm-229.orig/debian/xterm.doc-base.faq +++ xterm-229/debian/xterm.doc-base.faq @@ -0,0 +1,14 @@ +Document: xterm-faq +Title: XTerm Frequently Asked Questions (FAQ) +Author: Thomas Dickey +Abstract: This document provides answers to frequently asked questions + about the XTerm terminal emulator as it ships with the X.Org distribution + of the X Window System. +Section: XShells + +Format: text +Files: /usr/share/doc/xterm/xterm.faq.gz + +Format: HTML +Index: /usr/share/doc/xterm/xterm.faq.html +Files: /usr/share/doc/xterm/xterm.faq.html --- xterm-229.orig/debian/xterm.docs +++ xterm-229/debian/xterm.docs @@ -0,0 +1,8 @@ +README.i18n +ctlseqs.ms +ctlseqs.txt +xterm.log.html +debian/local/xterm.faq.html +debian/local/xterm.faq.gz +debian/tmp/usr/lib/xterm.termcap +debian/tmp/usr/lib/xterm.terminfo --- xterm-229.orig/debian/xterm.install +++ xterm-229/debian/xterm.install @@ -0,0 +1,4 @@ +etc/X11/app-defaults/* +usr/bin/* +usr/share/man/man1/* +usr/share/pixmaps --- xterm-229.orig/debian/xterm.menu +++ xterm-229/debian/xterm.menu @@ -0,0 +1,16 @@ +# $Id$ + +?package(xterm):\ + needs="x11"\ + section="Applications/Terminal Emulators"\ + longtitle="XTerm: terminal emulator for X"\ + title="XTerm"\ + icon="/usr/share/pixmaps/xterm-color_32x32.xpm"\ + command="xterm" +?package(xterm):\ + needs="x11"\ + section="Applications/Terminal Emulators"\ + longtitle="XTerm: terminal emulator for X with Unicode support"\ + title="XTerm (Unicode)"\ + icon="/usr/share/pixmaps/xterm-color_32x32.xpm"\ + command="uxterm" --- xterm-229.orig/debian/xterm.overrides +++ xterm-229/debian/xterm.overrides @@ -0,0 +1 @@ +xterm: setgid-binary usr/bin/xterm 2755 root/utmp --- xterm-229.orig/debian/xterm.postinst +++ xterm-229/debian/xterm.postinst @@ -0,0 +1,45 @@ +#!/bin/sh +# Debian xterm package post-installation script +# Copyright 1998-2001, 2003, 2004 Branden Robinson. +# Licensed under the GNU General Public License, version 2. See the file +# /usr/share/common-licenses/GPL or . +# Acknowledgements to Stephen Early, Mark Eichin, and Manoj Srivastava. + +# $Id$ + +set -e + +update-alternatives --install /usr/bin/x-terminal-emulator \ + x-terminal-emulator /usr/bin/xterm 20 --slave \ + /usr/share/man/man1/x-terminal-emulator.1.gz x-terminal-emulator.1.gz \ + /usr/share/man/man1/xterm.1.gz + +update-alternatives --install /usr/bin/x-terminal-emulator \ + x-terminal-emulator /usr/bin/uxterm 20 --slave \ + /usr/share/man/man1/x-terminal-emulator.1.gz x-terminal-emulator.1.gz \ + /usr/share/man/man1/uxterm.1.gz + +update-alternatives --install /usr/bin/x-terminal-emulator \ + x-terminal-emulator /usr/bin/koi8rxterm 20 --slave \ + /usr/share/man/man1/x-terminal-emulator.1.gz x-terminal-emulator.1.gz \ + /usr/share/man/man1/koi8rxterm.1.gz + +update-alternatives --install /usr/bin/x-terminal-emulator \ + x-terminal-emulator /usr/bin/lxterm 30 --slave \ + /usr/share/man/man1/x-terminal-emulator.1.gz x-terminal-emulator.1.gz \ + /usr/share/man/man1/lxterm.1.gz + +# in xterm versions from 204-0pre1 to 222-1, the manpage alternative was +# set incorrectly to x-terminal-emulator.1x.gz. In some cases, this can lead +# to the absence of the x-terminal-emulator.1.gz symbolic link after the +# upgrade, so we check for this situation and add it back if necessary. +# This can be removed after the release of etch. +if ! [ -L /usr/share/man/man1/x-terminal-emulator.1.gz ]; then + ln -s /etc/alternatives/x-terminal-emulator.1.gz /usr/share/man/man1 +fi + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=4 ts=4 tw=80: --- xterm-229.orig/debian/xterm.preinst +++ xterm-229/debian/xterm.preinst @@ -0,0 +1,41 @@ +#!/bin/sh +# Debian xterm package pre-installation script +# Copyright 2003, 2004 Branden Robinson. +# Licensed under the GNU General Public License, version 2. See the file +# /usr/share/common-licenses/GPL or . +# Acknowledgements to Stephen Early, Mark Eichin, and Manoj Srivastava. + +# $Id$ + +set -e + +if [ "$1" = "upgrade" ] || [ "$1" = "install" ]; then + if dpkg --compare-versions "$2" lt "4.0.1-1"; then + # Clean up after older alternative that used different path. + if update-alternatives --display x-terminal-emulator | + fgrep -q /usr/bin/X11/xterm; then + update-alternatives --remove x-terminal-emulator /usr/bin/X11/xterm + fi + fi + + if dpkg --compare-versions "$2" lt "204"; then + # Clean up after older alternative that used different path. + if update-alternatives --display x-terminal-emulator | + fgrep -q /usr/X11R6/bin/xterm; then + update-alternatives --remove x-terminal-emulator \ + /usr/X11R6/bin/koi8rxterm + update-alternatives --remove x-terminal-emulator \ + /usr/X11R6/bin/uxterm + update-alternatives --remove x-terminal-emulator \ + /usr/X11R6/bin/xterm + update-alternatives --remove x-terminal-emulator \ + /usr/X11R6/bin/lxterm + fi + fi +fi + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=4 ts=4 tw=80: --- xterm-229.orig/debian/xterm.prerm +++ xterm-229/debian/xterm.prerm @@ -0,0 +1,23 @@ +#!/bin/sh +# Debian xterm package pre-removal script +# Copyright 1998, 1999, 2004 Branden Robinson. +# Licensed under the GNU General Public License, version 2. See the file +# /usr/share/common-licenses/GPL or . +# Acknowledgements to Stephen Early, Mark Eichin, and Manoj Srivastava. + +# $Id$ + +set -e + +if [ "$1" = "remove" ] || [ "$1" = "deconfigure" ]; then + update-alternatives --remove x-terminal-emulator /usr/bin/koi8rxterm + update-alternatives --remove x-terminal-emulator /usr/bin/uxterm + update-alternatives --remove x-terminal-emulator /usr/bin/xterm + update-alternatives --remove x-terminal-emulator /usr/bin/lxterm +fi + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=4 ts=4 tw=80: