diff -Nru xterm-278/INSTALL xterm-297/INSTALL --- xterm-278/INSTALL 2011-12-22 01:59:16.000000000 +0000 +++ xterm-297/INSTALL 2013-08-04 19:33:14.000000000 +0000 @@ -1,6 +1,6 @@ --- $XTermId: INSTALL,v 1.127 2011/12/22 01:59:16 tom Exp $ +-- $XTermId: INSTALL,v 1.149 2013/08/04 19:33:14 tom Exp $ ------------------------------------------------------------------------------- --- Copyright 1997-2010,2011 by Thomas E. Dickey +-- Copyright 1997-2012,2013 by Thomas E. Dickey -- -- All Rights Reserved -- @@ -30,23 +30,12 @@ ------------------------------------------------------------------------------- Xterm was originally built as part of the X Window System source tree, using -imake to generate a Makefile from Imakefile. You can also use the configure -script to generate a Makefile from Makefile.in: +imake to generate a Makefile from Imakefile. - + If you have imake (or xmkmf), then you can use those directly, - or use the configure script, which normally uses those tools - to obtain the special definitions needed to build xterm. - - Ultimately, imake will not be necessary, since it is possible - to add configure tests that derive the information that imake - would supply. - - + You need the Athena widgets (or a clone, such as Xaw3d or - neXtaw), to provide the popup menus. - -Even if you have imake, the configure script is still convenient because -it allows you to build different configurations more easily than with -imake, simply by specifying options to the configure script. +An example Imakefile is provided for legacy use. + +The preferred method uses the configure script to generate a Makefile from +Makefile.in Options: ------- @@ -215,12 +204,21 @@ type. If you do not need input method (and are troubled by the warning messages), it is safe to disable this option. - --disable-leaks test: set to test memory leaks + --disable-leaks test: free permanent memory, analyze leaks Compile-in code which frees memory which might confuse a leak-testing tool. Normally these chunks of memory are retained as long as xterm is running. + --disable-luit disable support for luit filter (Unicode translation) + + Luit is a filter that can be run between an arbitrary application and a + UTF-8 terminal emulator. It will convert application output from the + locale's encoding into UTF-8, and convert terminal input from UTF-8 + into the locale's encoding. + + This is normally enabled, relying upon "--enable-wide-chars". + --disable-maximize disable actions for iconify/deiconify/maximize/restore Do not compile-in code that implements runtime 'actions' for @@ -240,6 +238,12 @@ (The same ifdef controls the metaSendsEscape support). + --disable-openpty disable openpty, prefer other interfaces + + Do not check for, or use openpty(). Instead, use other interfaces such + as posix_openpt(). Modern (sic) BSD systems should have a workable + openpty() interface. Older systems may not. + --disable-paste64 disable support for bracketed paste mode Do not compile-in code to support experimental bracketed paste mode, @@ -335,6 +339,12 @@ A genuine vt100 emulates a vt52. + --disable-wide-chars disable wide-character support + + The wide-character code supports Unicode and UTF-8. + + This is normally enabled. + --disable-ziconbeep disable -ziconbeep option Do not compile-in code that modifies the icon's title and sounds a @@ -355,6 +365,18 @@ Compile-in code that interprets SGR 38 and 48 for 88-colors. + --enable-alt-sends-esc set default altSendsEscape resource (default: no) + + This sets the default resource value, which is shown in the manpage. + + --enable-backarrow-key set default backarrowKey resource (default: true) + + This sets the default resource value, which is shown in the manpage. + + --enable-backarrow-is-erase set default backarrowKeyIsErase resource (default: false) + + This sets the default resource value, which is shown in the manpage. + --enable-broken-osc allow broken Linux OSC-strings], Compile-in code to accommodate scripts that write Linux's malformed @@ -378,6 +400,18 @@ This allows the xterm mouse to be used with applications that use the DEC Locator sequences, such as VAX Tpu, or SMG$ based applications. + --enable-delete-is-del set default deleteIsDEL resource (default: maybe) + + This sets the default resource value, which is shown in the manpage. + + --enable-double-buffer enable double-buffering + + Use experimental double-buffering for display to reduce flicker. + + This option was introduced in patch #282; at that point it needs + further work because colors used for clearing the screen do not + match the expected behavior (see vttest for instance). + --enable-exec-xterm enable "spawn-new-terminal" action If your platform supports the process filesystem "cwd" link, @@ -406,14 +440,9 @@ Logging was disabled in X11R5 xterm because of security problems. They were addressed in X11R6, but the feature was not reinstated. - --enable-luit enable support for luit filter (Unicode translation) + --enable-meta-sends-esc set default metaSendsEscape resource (default: no) - Luit is a filter that can be run between an arbitrary application and a - UTF-8 terminal emulator. It will convert application output from the - locale's encoding into UTF-8, and convert terminal input from UTF-8 - into the locale's encoding. - - This sets "--enable-wide-chars" as a side-effect. + This sets the default resource value, which is shown in the manpage. --enable-mini-luit enable support for poor man's luit filter (Latin-9) @@ -453,6 +482,10 @@ Compile-in code to support SCO-style function keys. + --enable-sixel-graphics enable support for sixel-graphics + + Compile-in code to support experimental sixel-graphics + --enable-sun-fkeys enable support for Sun-style function keys Compile-in code to support Sun-style function keys. @@ -485,11 +518,6 @@ I use this option regularly, and correct all but a few (difficult) problems. - --enable-wide-chars enable wide-character support - - Compile-in code that supports 16-bit characters. Includes support - for UTF-8. - --enable-xmc-glitch test: enable xmc magic-cookie emulation Compile-in code that simulates the terminfo "magic cookie" glitch. @@ -531,16 +559,29 @@ /usr/local, you should use this option to customize the location to match your system configuration. + Use --with-app-defaults=auto to ask the configure script to look in + a list of well-known locations for an existing directory. + Use --without-app-defaults or --with-app-defaults=no to disable the feature. + --with-dmalloc test: use Gray Watson's dmalloc library + + Check for and link with dmalloc. + + --with-dbmalloc test: use Conor Cahill's dbmalloc library + + Check for and link with dbmalloc. + --with-desktop-category=XXX one or more desktop catgories or auto This is a list of names. The configure script maps blanks and commas to semicolons (";") which are used by the desktop utils as a separator. The default value "auto" tells the configure script to look at existing ".desktop" files for xterm and common terminal - emulators, to use those. + emulators, to use those. If none are found, the script uses this + default: + System;TerminalEmulator;Utility; --with-freetype-config configure script to use for FreeType @@ -567,7 +608,31 @@ Override options provided by xft-config or freetype-config. - --with-icondir=DIR directory in which to install icon files (default: EPREFIX/share/pixmaps) + --with-icon-name=NAME override icon name (default: xterm-color) + + xterm comes with a choice of icons: + + xterm-color: depicts a conventional terminal image, and is the default + icon used for icon-themes. + + mini.xterm: a more iconic choice which is readily identifiable at + small sizes. This is used for window decoration, e.g., the + icon at the upper left corner in many window managers. + + --with-icon-symlink=NAME create symbolic links to icon name (default: NONE) + + This is a workaround for certain systems which translate icon names + containing "xterm", e.g., "xterm-color" into the single icon "xterm". + The option should also be harmless on a properly configured system. + + If the option is used, its default value is "xterm". For each icon, + the makefile will strip the suffix (e.g., ".png"), as well as the part + of the filename which denotes the size (e.g., "_32x32" in an xpm file), + and constructs a link with that name to the icon. + + If the option is unused, its default value is "NONE" (no link is made). + + --with-icondir=DIR directory in which to install icon files (default: no) The X libraries may automatically search these locations: @@ -575,10 +640,25 @@ $XDG_DATA_DIRS/icons /usr/share/pixmaps + Alternatively, the last may be actually + /usr/X11R6/share/pixmaps + + Use --with-icondir=auto to tell the configure script to search for + an existing directory from its list of well-known system locations. + See also http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html + http://www.freedesktop.org/software/icon-theme/ + + By default, the option is disabled; it is useful only for the + --with-icon-theme option. - Use --without-icondir or --with-icondir=no to disable the feature. + --with-icon-theme=XXX install icons into desktop theme (hicolor) + + Install png and svg icons into the given desktop theme and customize + the .desktop files to use that theme. If no theme name is given, + the default is "hicolor". If this option is not given, the desktop + file will use the pixmap files. --with-neXtaw link with neXT Athena library @@ -647,6 +727,18 @@ If xterm is not installed setuid'd to root, this option is not needed, since it cannot change the tty device's ownership. + --with-valgrind test: use valgrind + + Activate the --disable-leaks option, and ensure that "-g" is added to + CFLAGS. + + --with-xpm=DIR use Xpm library for colored icon, may specify path + + Use Xpm library to show colored icon in window decoration, e.g., + title area. + + Use --without-xpm to suppress this feature. + --with-xterm-symlink=XXX make symbolic link to installed xterm If any of the configure options to modify the program name i.e., diff -Nru xterm-278/Imakefile xterm-297/Imakefile --- xterm-278/Imakefile 2011-11-29 10:19:20.000000000 +0000 +++ xterm-297/Imakefile 2013-06-23 22:32:37.000000000 +0000 @@ -1,4 +1,4 @@ -XCOMM $XTermId: Imakefile,v 1.105 2011/11/29 10:19:20 Thorsten.Glaser Exp $ +XCOMM $XTermId: Imakefile,v 1.109 2013/06/23 22:32:37 tom Exp $ XCOMM XCOMM Attention xterm porters XCOMM @@ -126,19 +126,6 @@ LOCAL_LDFLAGS = -Wl,-bind_at_load #endif -#ifdef OS2Architecture -/* - * Only used in os2main.c, see ptyx.h for OPT_I18N_SUPPORT - * - */ -#if XtermWithI18N - I18NDEF = -DI18N - FEATURE_DEFINES = -DDEBUG -DALLOWLOGGING $(I18NDEF) -#else - FEATURE_DEFINES = -DDEBUG -DALLOWLOGGING -#endif -#endif - OSMAJORVERSION = OSMajorVersion OSMINORVERSION = OSMinorVersion @@ -178,6 +165,9 @@ #if !HasPutenv PUTENVDEF = -DNOPUTENV #endif +#ifdef SixelXTerm + SIXELDEF = -DOPT_SIXEL_GRAPHICS=1 +#endif #ifdef TraceXTerm TRACEDEF = -DOPT_TRACE=1 #endif @@ -187,15 +177,14 @@ MISC_DEFINES = /* -DALLOWLOGGING -DALLOWLOGFILEEXEC */ XKB_DEFINES = XkbClientDefines PATH_DEFINES = -DPROJECTROOT=$(PROJECTROOT) - DEFINES = $(XKB_DEFINES) $(TERMCAPDEFINES) $(FEATURE_DEFINES) $(SCROLLBAR_RIGHT) $(UTF8_OPTION) $(XRFDEF) $(PATH_DEFINES) $(PUTENVDEF) $(IMAKEDEFINES) $(TRACEDEF) + DEFINES = $(XKB_DEFINES) $(TERMCAPDEFINES) $(FEATURE_DEFINES) $(SCROLLBAR_RIGHT) $(UTF8_OPTION) $(XRFDEF) $(PATH_DEFINES) $(PUTENVDEF) $(IMAKEDEFINES) $(SIXELDEF) $(TRACEDEF) INCLUDES = -I. $(XRFINCLUDES) -#ifdef OS2Architecture - MAINSRC = os2main.c - MAINOBJ = os2main.o -#else MAINSRC = main.c MAINOBJ = main.o +#ifdef SixelXTerm + SIXELSRC = graphics.c + SIXELOBJ = graphics.o #endif #ifdef TraceXTerm TRACESRC = trace.c @@ -204,17 +193,17 @@ SRCS1 = button.c cachedGCs.c charproc.c charsets.c cursor.c \ data.c doublechr.c fontutils.c input.c \ linedata.c menu.c misc.c print.c ptydata.c scrollback.c \ - screen.c scrollbar.c tabs.c util.c xstrings.c xtermcap.c \ - TekPrsTbl.c Tekproc.c VTPrsTbl.c \ - $(MAINSRC) $(EXTRASRC) $(UTF8SRC) $(TRACESRC) + screen.c scrollbar.c tabs.c util.c version.c xstrings.c \ + xtermcap.c TekPrsTbl.c Tekproc.c VTPrsTbl.c \ + $(MAINSRC) $(EXTRASRC) $(UTF8SRC) $(SIXELSRC) $(TRACESRC) OBJS1 = button.o cachedGCs.o charproc.o charsets.o cursor.o \ data.o doublechr.o fontutils.o input.o \ linedata.o menu.o misc.o print.o ptydata.o scrollback.o \ - screen.o scrollbar.o tabs.o util.o xstrings.o xtermcap.o \ - TekPrsTbl.o Tekproc.o VTPrsTbl.o \ - $(MAINOBJ) $(EXTRAOBJ) $(UTF8OBJ) $(TRACEOBJ) - SRCS2 = resize.c xstrings.c - OBJS2 = resize.o xstrings.o + screen.o scrollbar.o tabs.o util.o version.o xstrings.o \ + xtermcap.o TekPrsTbl.o Tekproc.o VTPrsTbl.o \ + $(MAINOBJ) $(EXTRAOBJ) $(UTF8OBJ) $(SIXELOBJ) $(TRACEOBJ) + SRCS2 = resize.c version.c xstrings.c + OBJS2 = resize.o version.o xstrings.o SRCS = $(SRCS1) $(SRCS2) OBJS = $(OBJS1) $(OBJS2) PROGRAMS = ProgramTargetName(resize) ProgramTargetName(xterm) diff -Nru xterm-278/MANIFEST xterm-297/MANIFEST --- xterm-278/MANIFEST 2012-01-12 13:10:09.000000000 +0000 +++ xterm-297/MANIFEST 2013-08-04 12:59:46.000000000 +0000 @@ -1,4 +1,4 @@ -MANIFEST for xterm-278, version xterm-278 +MANIFEST for xterm-297, version xterm-297 -------------------------------------------------------------------------------- MANIFEST this file 256colres.h resource-definitions for 256-color mode @@ -47,6 +47,7 @@ fontutils.c xterm functions for (re)loading fonts fontutils.h interface of fontutils.c gen-pc-fkeys.pl script to generate extended function-key terminfo +graphics.c graphics support functions for 'xterm' input.c VT100 key-symbol and function-key translation install-sh install-script (needed by configure) keysym2ucs.c lookup-table for UTF-8 to keysyms @@ -62,12 +63,10 @@ menu.h interface of menu.c minstall.in script for installing manpages misc.c miscellaneous utility functions for 'xterm' -os2main.c main program for OS/2 EMX port of 'xterm' plink.sh script to prune unneeded libraries from link precompose.c table of precompose sequences precompose.h interface of precompose.c print.c VT100+ print support functions -proto.h macros to simplify function prototypes ptydata.c functions to manipulate data read from pty ptyx.h structure-definitions for 'xterm' resize.c program to compute/modify xterm's window size @@ -87,6 +86,7 @@ uxterm wrapper script to make unicode-xterm uxterm.desktop sample desktop file for uxterm uxterm.man manpage for uxterm, from Debian +version.c xterm package version, used also in resize version.h version of xterm vms.c VMS version of xterm's spawn(), etc. vms.h system headers and definitions for vms.c @@ -108,13 +108,35 @@ xutf8.c JC's cleanup of UTF8 xutf8.h JC's cleanup of UTF8 icons subdirectory -icons/xterm-color_32x32.xcf gimp file for editing 32x32 icon +icons/filled-xterm.png filled-xterm variants +icons/filled-xterm.svg filled-xterm variants +icons/filled-xterm.xpms filled-xterm variants +icons/filled-xterm_16x16.xpm filled-xterm variants +icons/filled-xterm_32x32.xpm filled-xterm variants +icons/filled-xterm_48x48.xpm filled-xterm variants +icons/make-xpms script to make combined xpm-icons +icons/mini.xterm.svg svg format for mini-icon +icons/mini.xterm.xpms collection of mini-icons +icons/mini.xterm_16x16.png mini-icon 16x16 png +icons/mini.xterm_16x16.xpm mini-icon 16x16 pixmap +icons/mini.xterm_256x256.png mini-icon 256x256 png +icons/mini.xterm_32x32.png mini-icon 32x32 png +icons/mini.xterm_32x32.xpm mini-icon 32x32 pixmap +icons/mini.xterm_48x48.png mini-icon 48x48 png +icons/mini.xterm_48x48.xpm mini-icon 48x48 pixmap +icons/terminal_48x48.svg svg-format of "terminal" +icons/terminal_48x48.xpm xpm-format of "terminal" +icons/xterm-color.png xterm-color 48x48, in png-format +icons/xterm-color.svg xterm-color icon +icons/xterm-color.xpms collection of color icons +icons/xterm-color_16x16.xpm 16x16 color icon icons/xterm-color_32x32.xpm 32x32 color icon -icons/xterm-color_48x48.xcf gimp file for editing 48x48 icon icons/xterm-color_48x48.xpm 48x48 color icon -icons/xterm_32x32.xcf gimp file, for editing 32x32 icon +icons/xterm.png xterm 48x48, in png-format +icons/xterm.svg xterm icon +icons/xterm.xpms collection of icons +icons/xterm_16x16.xpm normal icon 16x16 pixmap icons/xterm_32x32.xpm 32x32 monochrome icon -icons/xterm_48x48.xcf gimp file, for editing 48x48 icon icons/xterm_48x48.xpm 48x48 monochrome icon package/debian subdirectory package/debian/changelog build-script @@ -128,7 +150,13 @@ package/debian subdirectory package/debian/watch build-script package/debian/xterm-dev.docs build-script +package/debian/xterm-dev.menu Debian menu-file for xterm-dev package. package/debian/xterm-xres.sed build-script +package/freebsd subdirectory +package/freebsd/Makefile build-script +package/freebsd/pkg-descr build-script +package/freebsd/pkg-message build-script +package/freebsd/pkg-plist build-script package subdirectory package/xterm.spec build-script tektests subdirectory @@ -160,6 +188,7 @@ vttests/dynamic2.sh complete example of dynamic colors vttests/fonts.sh script to demonstrate font-switching sequences vttests/paste64.pl script to test base64-selection option +vttests/query-color.pl demonstrate OSC 4 vttests/query-fonts.pl script to demo/test font-querying vttests/resize.pl translated resize.sh to perl since it is easy to test, and I needed vttests/resize.sh script to demonstrate resizing diff -Nru xterm-278/Makefile.in xterm-297/Makefile.in --- xterm-278/Makefile.in 2011-08-25 09:25:51.000000000 +0000 +++ xterm-297/Makefile.in 2013-06-23 23:40:18.000000000 +0000 @@ -1,8 +1,8 @@ -## $XTermId: Makefile.in,v 1.186 2011/08/25 09:25:51 tom Exp $ +## $XTermId: Makefile.in,v 1.223 2013/06/23 23:40:18 tom Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 1997-2010,2011 by Thomas E. Dickey +# Copyright 1997-2012,2013 by Thomas E. Dickey # # All Rights Reserved # @@ -63,31 +63,39 @@ EXTRA_CPPFLAGS = @EXTRA_CPPFLAGS@ EXTRA_LOADFLAGS = @IMAKE_LOADFLAGS@ -CPPFLAGS = -I. -I$(srcdir) -DHAVE_CONFIG_H @CPPFLAGS@ $(EXTRA_CPPFLAGS) +CPPFLAGS = -I. -I$(srcdir) -DHAVE_CONFIG_H @CPPFLAGS@ -DDEFCLASS=\"@APP_CLASS@\" $(EXTRA_CPPFLAGS) CFLAGS = @CFLAGS@ $(EXTRA_CFLAGS) LDFLAGS = @LDFLAGS@ @EXTRA_LDFLAGS@ LIBS = @LIBS@ prefix = @prefix@ exec_prefix = @exec_prefix@ +datarootdir = @datarootdir@ +datadir = @datadir@ manext = 1 bindir = @bindir@ libdir = @libdir@ mandir = @mandir@/man$(manext) -appsdir = @appsdir@ -icondir = @icondir@ +appsdir = @APPSDIR@ +icondir = @ICONDIR@ +pixmapdir = @PIXMAPDIR@ #### End of system configuration section. #### +ICON_NAME = @ICON_NAME@ +ICON_SYMLINK = @ICON_SYMLINK@ + DESTDIR = BINDIR = $(DESTDIR)$(bindir) LIBDIR = $(DESTDIR)$(libdir) MANDIR = $(DESTDIR)$(mandir) APPSDIR = $(DESTDIR)$(appsdir) -ICONDIR = $(DESTDIR)$(icondir) -INSTALL_DIRS = $(BINDIR) $(APPSDIR) $(ICONDIR) $(MANDIR) +@no_icondir@ICONDIR = $(DESTDIR)$(icondir) +@no_pixmapdir@PIXMAPDIR = $(DESTDIR)$(pixmapdir) + +INSTALL_DIRS = $(BINDIR) $(APPSDIR) $(ICONDIR) $(PIXMAPDIR) $(MANDIR) CLASS = @APP_CLASS@ EXTRAHDR = @EXTRAHDRS@ @@ -98,25 +106,25 @@ data.c doublechr.c fontutils.c input.c \ linedata.c main.c menu.c misc.c \ print.c ptydata.c scrollback.c \ - screen.c scrollbar.c tabs.c util.c xstrings.c xtermcap.c \ - VTPrsTbl.c $(EXTRASRC) + screen.c scrollbar.c tabs.c util.c version.c xstrings.c \ + xtermcap.c VTPrsTbl.c $(EXTRASRC) OBJS1 = button$o cachedGCs$o charproc$o charsets$o cursor$o \ data$o doublechr$o fontutils$o input$o \ linedata$o main$o menu$o misc$o \ print$o ptydata$o scrollback$o \ - screen$o scrollbar$o tabs$o util$o xstrings$o xtermcap$o \ - VTPrsTbl$o $(EXTRAOBJ) - SRCS2 = resize.c xstrings.c - OBJS2 = resize$o xstrings$o + screen$o scrollbar$o tabs$o util$o version$o xstrings$o \ + xtermcap$o VTPrsTbl$o $(EXTRAOBJ) + SRCS2 = resize.c version.c xstrings.c + OBJS2 = resize$o version$o xstrings$o SRCS = $(SRCS1) $(SRCS2) OBJS = $(OBJS1) $(OBJS2) - HDRS = VTparse.h data.h error.h main.h menu.h proto.h \ + HDRS = VTparse.h data.h error.h main.h menu.h \ ptyx.h version.h xstrings.h xterm.h xtermcap.h $(EXTRAHDR) PROGRAMS = xterm$x resize$x all : $(PROGRAMS) ################################################################################ -.SUFFIXES : .i .def .hin .html .$(manext) .ms .man .ps .pdf .txt +.SUFFIXES : .i .def .hin .$(manext) .ms .man .txt @GROFF_NOTE@ .html .ps .pdf .c$o : @RULE_CC@ @@ -130,28 +138,35 @@ grep '^CASE_' $< | $(AWK) '{printf "#define %s %d\n", $$1, n++}' >$@ .man.$(manext) : - $(SHELL) ./minstall "$(INSTALL_DATA)" $< $@ $(appsdir) $(CLASS) - -.$(manext).html : - GROFF_NO_SGR=stupid $(SHELL) -c "tbl $*.$(manext) | groff -Thtml -man" >$@ - -.$(manext).ps : - $(SHELL) -c "tbl $*.$(manext) | groff -man" >$@ - -.$(manext).txt : - GROFF_NO_SGR=stupid $(SHELL) -c "tbl $*.$(manext) | nroff -Tascii -man | col -bx" >$@ + $(SHELL) ./minstall "$(INSTALL_DATA)" $< $@ $(appsdir) $(CLASS) $* $* $(pixmapdir) -.ms.html : - GROFF_NO_SGR=stupid $(SHELL) -c "tbl $< | groff -Thtml -ms" >$@ - -.ms.ps : - $(SHELL) -c "tbl $< | groff -ms" >$@ - -.ms.txt : - GROFF_NO_SGR=stupid $(SHELL) -c "tbl $< | nroff -Tascii -ms | col -bx" >$@ - -.ps.pdf : - ps2pdf $*.ps +@NROFF_NOTE@.$(manext).txt : +@NROFF_NOTE@ $(SHELL) -c "tbl $*.$(manext) | nroff -man | col -bx" >$@ +@NROFF_NOTE@ +@NROFF_NOTE@.ms.txt : +@NROFF_NOTE@ $(SHELL) -c "tbl $*.$(manext) | nroff -ms | col -bx" >$@ +@NROFF_NOTE@ + +@GROFF_NOTE@.$(manext).html : +@GROFF_NOTE@ GROFF_NO_SGR=stupid $(SHELL) -c "tbl $*.$(manext) | groff -P -o0 -I$*_ -Thtml -man" >$@ +@GROFF_NOTE@ +@GROFF_NOTE@.$(manext).ps : +@GROFF_NOTE@ $(SHELL) -c "tbl $*.$(manext) | groff -man" >$@ +@GROFF_NOTE@ +@GROFF_NOTE@.$(manext).txt : +@GROFF_NOTE@ GROFF_NO_SGR=stupid $(SHELL) -c "tbl $*.$(manext) | groff -Tascii -man | col -bx" >$@ +@GROFF_NOTE@ +@GROFF_NOTE@.ms.html : +@GROFF_NOTE@ GROFF_NO_SGR=stupid $(SHELL) -c "tbl $< | groff -P -o0 -I$*_ -Thtml -ms" >$@ +@GROFF_NOTE@ +@GROFF_NOTE@.ms.ps : +@GROFF_NOTE@ $(SHELL) -c "tbl $< | groff -ms" >$@ +@GROFF_NOTE@ +@GROFF_NOTE@.ms.txt : +@GROFF_NOTE@ GROFF_NO_SGR=stupid $(SHELL) -c "tbl $< | groff -Tascii -ms | col -bx" >$@ +@GROFF_NOTE@ +@GROFF_NOTE@.ps.pdf : +@GROFF_NOTE@ ps2pdf $*.ps ################################################################################ main$o : main.h misc$o : version.h @@ -222,10 +237,11 @@ install \ install-man \ install-full :: $(MANDIR) - $(SHELL) ./minstall "$(INSTALL_DATA)" $(srcdir)/xterm.man $(MANDIR)/$(actual_xterm).$(manext) $(appsdir) $(CLASS) - $(SHELL) ./minstall "$(INSTALL_DATA)" $(srcdir)/resize.man $(MANDIR)/$(actual_resize).$(manext) $(appsdir) $(CLASS) - $(SHELL) ./minstall "$(INSTALL_DATA)" $(srcdir)/uxterm.man $(MANDIR)/$(actual_uxterm).$(manext) $(appsdir) $(CLASS) - $(SHELL) ./minstall "$(INSTALL_DATA)" $(srcdir)/koi8rxterm.man $(MANDIR)/$(actual_k8term).$(manext) $(appsdir) $(CLASS) + @-$(SHELL) -c "for app in xterm resize uxterm koi8rxterm ; \ + do \ + actual=\`echo \"\$$app\" | sed '@program_transform_name@'\`; \ + $(SHELL) ./minstall \"$(INSTALL_DATA)\" $(srcdir)/\$$app.man $(MANDIR)/\$$actual.$(manext) $(appsdir) $(CLASS) \$$app \$$actual $(pixmapdir); \ + done" @-$(SHELL) -c "if test @XTERM_SYMLINK@ != NONE ; then cd $(MANDIR) && rm -f @XTERM_SYMLINK@.$(manext) ; fi" @-$(SHELL) -c "if test @XTERM_SYMLINK@ != NONE ; then cd $(MANDIR) && $(LN_S) $(actual_xterm).$(manext) @XTERM_SYMLINK@.$(manext) ; fi" @-$(SHELL) -c "if test @XTERM_SYMLINK@ != NONE ; then cd $(MANDIR) && echo '... created symbolic link:' && ls -l $(actual_xterm).$(manext) @XTERM_SYMLINK@.$(manext) ; fi" @@ -249,15 +265,64 @@ @no_appsdir@ @rm -f XTerm.tmp @no_icondir@ @echo "... installed app-defaults" +@no_icondir@ICON_LIST = @ICON_LIST@ +@no_icondir@ICON_THEME = @ICON_THEME@ @no_icondir@install \ @no_icondir@install-icon \ @no_icondir@install-full :: $(ICONDIR) -@no_icondir@ @$(INSTALL_DATA) $(srcdir)/icons/xterm-color_32x32.xpm $(ICONDIR)/$(actual_xterm)-color_32x32.xpm -@no_icondir@ @$(INSTALL_DATA) $(srcdir)/icons/xterm-color_48x48.xpm $(ICONDIR)/$(actual_xterm)-color_48x48.xpm -@no_icondir@ @$(INSTALL_DATA) $(srcdir)/icons/xterm_32x32.xpm $(ICONDIR)/$(actual_xterm)_32x32.xpm -@no_icondir@ @$(INSTALL_DATA) $(srcdir)/icons/xterm_48x48.xpm $(ICONDIR)/$(actual_xterm)_48x48.xpm +@no_icondir@ ACTUAL_XTERM=$(actual_xterm) \ +@no_icondir@ $(SHELL) -c '\ +@no_icondir@ h=$(ICONDIR)/$(ICON_THEME); \ +@no_icondir@ for n in $(ICON_LIST); \ +@no_icondir@ do \ +@no_icondir@ x=$$ACTUAL_XTERM; \ +@no_icondir@ l=`echo "$$n" | cut -f1 -d:`; \ +@no_icondir@ r=`echo "$$n" | cut -f2 -d: |sed -e s,$(ICON_NAME),$$x-color,`; \ +@no_icondir@ test -z "$$r" && continue; \ +@no_icondir@ d=$$h/`echo "$$r" | sed -e "s,/[^/]*$$,,"`; \ +@no_icondir@ test -d "$$d" || mkdir -p "$$d"; \ +@no_icondir@ echo "installing icon $$h/$$r"; \ +@no_icondir@ $(INSTALL_DATA) $$l $$h/$$r; \ +@no_icondir@ s=`echo "$$r" | sed -e '"'s,^.*\.,.,'"'`; \ +@no_icondir@ t=$(ICON_SYMLINK)$$s; \ +@no_icondir@ b=`basename $$n $$s | sed -e "s,_[1-9][0-9]*x.*,,"`; \ +@no_icondir@ if test "$(ICON_SYMLINK)" != NONE ; then \ +@no_icondir@ if test "$$r" != "$$t" ; then \ +@no_icondir@ if test "x$$b" = "x$(ICON_NAME)" ; then \ +@no_icondir@ echo "linking $$r -> $$t"; \ +@no_icondir@ ( cd $$h; rm -f $$t; $(LN_S) $$r $$t; ) \ +@no_icondir@ fi \ +@no_icondir@ fi \ +@no_icondir@ fi \ +@no_icondir@ done' @no_icondir@ @echo "... installed icons" +@no_pixmapdir@install \ +@no_pixmapdir@install-icon \ +@no_pixmapdir@install-full :: $(PIXMAPDIR) +@no_pixmapdir@ ACTUAL_XTERM=$(actual_xterm) \ +@no_pixmapdir@ $(SHELL) -c '\ +@no_pixmapdir@ h=$(PIXMAPDIR); \ +@no_pixmapdir@ for n in $(srcdir)/icons/*xterm*_32x32.xpm $(srcdir)/icons/*xterm*_48x48.xpm; \ +@no_pixmapdir@ do \ +@no_pixmapdir@ l=`basename $$n`; \ +@no_pixmapdir@ r=`echo "$$l" | sed -e "s,xterm,$$ACTUAL_XTERM,"`; \ +@no_pixmapdir@ echo "installing pixmap $$h/$$r"; \ +@no_pixmapdir@ $(INSTALL_DATA) $(srcdir)/icons/$$l $$h/$$r; \ +@no_pixmapdir@ s=`echo "$$r" | sed -e '"'s,^.*\.,.,'"'`; \ +@no_pixmapdir@ t=$(ICON_SYMLINK)$$s; \ +@no_pixmapdir@ b=`basename $$n $$s | sed -e "s,_[1-9][0-9]*x.*,,"`; \ +@no_pixmapdir@ if test "$(ICON_SYMLINK)" != NONE ; then \ +@no_pixmapdir@ if test "x$$r" != "$$t" ; then \ +@no_pixmapdir@ if test "x$$b" = "x$(ICON_NAME)" ; then \ +@no_pixmapdir@ echo "linking $$r -> $$t"; \ +@no_pixmapdir@ ( cd $$h; rm -f $$t; $(LN_S) $$r $$t; ) \ +@no_pixmapdir@ fi \ +@no_pixmapdir@ fi \ +@no_pixmapdir@ fi \ +@no_pixmapdir@ done' +@no_pixmapdir@ @echo "... installed icons" + install :: @echo 'Completed installation of executables and documentation.' @echo 'Use "make install-ti" to install terminfo description.' @@ -315,17 +380,39 @@ @no_icondir@uninstall \ @no_icondir@uninstall-icon \ @no_icondir@uninstall-full :: -@no_icondir@ -$(RM) $(ICONDIR)/$(actual_xterm)-color_32x32.xpm -@no_icondir@ -$(RM) $(ICONDIR)/$(actual_xterm)_32x32.xpm -@no_icondir@ -$(RM) $(ICONDIR)/$(actual_xterm)-color_48x48.xpm -@no_icondir@ -$(RM) $(ICONDIR)/$(actual_xterm)_48x48.xpm +@no_icondir@ -@$(SHELL) -c 'for n in $(ICON_LIST); \ +@no_icondir@ do \ +@no_icondir@ x=$(actual_xterm); \ +@no_icondir@ r=`echo "$$n" | sed -e s,\^.\*:,, -e s,xterm,$$x,`; \ +@no_icondir@ test -z "$$r" && continue; \ +@no_icondir@ h=$(ICONDIR)/$(ICON_THEME); \ +@no_icondir@ echo removing $$h/$$r; \ +@no_icondir@ $(RM) $$h/$$r; \ +@no_icondir@ done' +@no_icondir@ @echo "... removed icons" + +@no_pixmapdir@uninstall \ +@no_pixmapdir@uninstall-icon \ +@no_pixmapdir@uninstall-full :: +@no_pixmapdir@ ACTUAL_XTERM=$(actual_xterm) \ +@no_pixmapdir@ $(SHELL) -c 'for n in $(srcdir)/icons/*xterm*_32x32.xpm $(srcdir)/icons/*xterm*_48x48.xpm; \ +@no_pixmapdir@ do \ +@no_pixmapdir@ l=`basename $$n`; \ +@no_pixmapdir@ r=`echo "$$l" | sed -e "s,xterm,$$ACTUAL_XTERM,"`; \ +@no_pixmapdir@ echo removing $(PIXMAPDIR)/$$r; \ +@no_pixmapdir@ $(RM) $(PIXMAPDIR)/$$r; \ +@no_pixmapdir@ done' +@no_pixmapdir@ @echo "... removed icons" ################################################################################ # Desktop-utils does not provide an uninstall, and is not uniformly available. +@desktop_utils@DESKTOP_FILES = $(srcdir)/xterm.desktop $(srcdir)/uxterm.desktop @desktop_utils@DESKTOP_FLAGS = @DESKTOP_FLAGS@ @desktop_utils@install-desktop \ @desktop_utils@install-full :: -@desktop_utils@ $(SHELL) df-install $(actual_xterm) $(DESKTOP_FLAGS) $(srcdir)/xterm.desktop -@desktop_utils@ $(SHELL) df-install $(actual_xterm) $(DESKTOP_FLAGS) $(srcdir)/uxterm.desktop +@desktop_utils@ ACTUAL_XTERM=$(actual_xterm) \ +@desktop_utils@ $(SHELL) -c 'for n in $(DESKTOP_FILES); \ +@desktop_utils@ do $(SHELL) df-install $$ACTUAL_XTERM $(DESKTOP_FLAGS) $$n; \ +@desktop_utils@ done' ################################################################################ mostlyclean : -$(RM) *$o *.[is] XtermLog.* .pure core *~ *.bak *.BAK *.out *.tmp @@ -356,50 +443,40 @@ termcap.out : termcap ; tic -a -C -U termcap >$@ ################################################################################ docs-ctlseqs \ -docs :: ctlseqs.html \ - ctlseqs.pdf \ - ctlseqs.ps \ - $(srcdir)/ctlseqs.txt +docs :: \ + $(srcdir)/ctlseqs.txt \ +@GROFF_NOTE@ ctlseqs.html \ +@GROFF_NOTE@ ctlseqs.pdf \ +@GROFF_NOTE@ ctlseqs.ps + ctlseqs.html : $(srcdir)/ctlseqs.ms ctlseqs.pdf : ctlseqs.ps ctlseqs.ps : $(srcdir)/ctlseqs.ms ctlseqs.txt : $(srcdir)/ctlseqs.ms ################################################################################ docs-resize \ -docs :: resize.html \ - resize.pdf \ - resize.ps \ - resize.txt +docs :: resize.txt @GROFF_NOTE@ resize.html resize.pdf resize.ps resize.html : resize.$(manext) resize.pdf : resize.ps resize.ps : resize.$(manext) resize.txt : resize.$(manext) ################################################################################ docs-xterm \ -docs :: xterm.html \ - xterm.pdf \ - xterm.ps \ - xterm.txt +docs :: xterm.txt @GROFF_NOTE@ xterm.html xterm.pdf xterm.ps xterm.html : xterm.$(manext) xterm.pdf : xterm.ps xterm.ps : xterm.$(manext) xterm.txt : xterm.$(manext) ################################################################################ docs-uxterm \ -docs :: uxterm.html \ - uxterm.pdf \ - uxterm.ps \ - uxterm.txt +docs :: uxterm.txt @GROFF_NOTE@ uxterm.html uxterm.pdf uxterm.ps uxterm.html : uxterm.$(manext) uxterm.pdf : uxterm.ps uxterm.ps : uxterm.$(manext) uxterm.txt : uxterm.$(manext) ################################################################################ docs-koi8rxterm \ -docs :: koi8rxterm.html \ - koi8rxterm.pdf \ - koi8rxterm.ps \ - koi8rxterm.txt +docs :: koi8rxterm.txt @GROFF_NOTE@ koi8rxterm.html koi8rxterm.pdf koi8rxterm.ps koi8rxterm.html : koi8rxterm.$(manext) koi8rxterm.pdf : koi8rxterm.ps koi8rxterm.ps : koi8rxterm.$(manext) diff -Nru xterm-278/THANKS xterm-297/THANKS --- xterm-278/THANKS 2011-08-21 00:52:56.000000000 +0000 +++ xterm-297/THANKS 2013-08-08 08:24:07.000000000 +0000 @@ -1,4 +1,4 @@ --- $XTermId: THANKS,v 1.5 2011/08/21 00:52:56 tom Exp $ +-- $XTermId: THANKS,v 1.11 2013/08/08 08:24:07 tom Exp $ -- vile:txtmode fk=8bit There's no AUTHORS file in this distribution; it would be redundant since I (Thomas E. Dickey) have done more than 80% of the work on xterm since 1996. @@ -12,6 +12,7 @@ Adam M Costello Adam Sulmicki +Ailin Nemui Alan Coopersmith Alex Hornung Alexander Pohoyda @@ -19,12 +20,16 @@ Andrea Odetti Andreas Jaeger Andreas Schwab +Andres Perera Andrew Sumner Andrew Tipton +Andries E Brouwer Anton Kovalenko +Balazs Kezes Ben Yoshino Bernhard R Link Bernhard Rosenkraenzer +Bertram Felgenhauer Bill Nottingham Bob Maynard Bradd W Szonye @@ -39,6 +44,7 @@ Chuck Blake D Roland Walker Daniel Colascione +Daniel Drake Daniel Jacobowitz Dave Simmons David Dawes @@ -46,6 +52,7 @@ David Madore David Martínez Moreno David Mathog +David Wolfskill David Wood David Yeo Denis Zaitsev @@ -57,6 +64,7 @@ Eddy De Greef Edward S Arthur Egbert Eich +Egmont Koblinger Emanuele Giaquinta Eugene Konev Fabrice Bellard @@ -73,6 +81,7 @@ Hasso Tepper Holger Veit Ilya Zakharevich +Iwamoto Kouichi James Armstrong Jason Bacon Jason Vas Dias @@ -96,6 +105,7 @@ Keith Packard Ken Martin Kevin Buhr +Kevin Ryde Kevin Schoedel Kiyokazu Suto Larry Riedel @@ -126,21 +136,26 @@ Németh Márton Nicolas George Ovidiu Gheorghioiu +Paul Bolle Paul Gilmartin Paul Giordano Paul Lampert +Paul Maier Paul Vojta Paul Williams Pavel Roskin +Peder Stray Per Hedeland Peter Berg Larsen Pierre Lombard Richard Braakman Richard Griswold +Richard Tollerton Rob Braun Robert Brady Robert Earl Robin Cutshaw +Ross Combs Ross Paterson Ryan Johnson Scott Sewall @@ -152,6 +167,7 @@ Steve Wall Stuart Lissaman Sven Verdoolaege +Taketo Kabe Taneli Huuskonen Ted Phelps Thierry Reding @@ -159,6 +175,7 @@ Tim Adye Tim Pope Tobias Stoeckmann +Todd Eigenschink Todd Larason Todd Miller Tomas Vanhala diff -Nru xterm-278/Tekproc.c xterm-297/Tekproc.c --- xterm-278/Tekproc.c 2011-12-27 10:19:51.000000000 +0000 +++ xterm-297/Tekproc.c 2012-09-07 09:08:44.000000000 +0000 @@ -1,4 +1,4 @@ -/* $XTermId: Tekproc.c,v 1.191 2011/12/27 10:19:51 tom Exp $ */ +/* $XTermId: Tekproc.c,v 1.193 2012/09/07 09:08:44 tom Exp $ */ /* * Copyright 2001-2010,2011 by Thomas E. Dickey @@ -889,6 +889,9 @@ { TekScreen *tekscr = TekScreenOf(tw); + TRACE(("TekClear\n")); + nplot = 0; + line_pt = Tline; if (TWindow(tekscr)) XClearWindow(XtDisplay(tw), TWindow(tekscr)); } @@ -905,6 +908,7 @@ int border = 2 * screen->border; double d; + TRACE(("TekConfigure\n")); TekClear(tw); TWidth(tekscr) = w->core.width - border; THeight(tekscr) = w->core.height - border; @@ -993,6 +997,7 @@ TekScreen *tekscr = TekScreenOf(tw); TekLink *tek; + TRACE(("TekPage\n")); TekClear(tw); tekscr->cur_X = 0; tekscr->cur_Y = TEKHOME; diff -Nru xterm-278/VTPrsTbl.c xterm-297/VTPrsTbl.c --- xterm-278/VTPrsTbl.c 2011-12-04 19:46:52.000000000 +0000 +++ xterm-297/VTPrsTbl.c 2013-08-21 23:50:44.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: VTPrsTbl.c,v 1.63 2011/12/04 19:46:52 tom Exp $ */ +/* $XTermId: VTPrsTbl.c,v 1.72 2013/08/21 23:50:44 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2011,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -99,7 +99,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -423,7 +423,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -481,7 +481,7 @@ /* 8 9 : ; */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* < = > ? */ CASE_CSI_IGNORE, @@ -530,12 +530,12 @@ CASE_GROUND_STATE, /* ` a b c */ CASE_HPA, -CASE_GROUND_STATE, +CASE_HPR, CASE_REP, CASE_DA1, /* d e f g */ CASE_VPA, -CASE_GROUND_STATE, +CASE_VPR, CASE_CUP, CASE_TBC, /* h i j k */ @@ -552,10 +552,10 @@ CASE_GROUND_STATE, CASE_DECLL, CASE_DECSTBM, -CASE_DECSC, +CASE_ANSI_SC, /* t u v w */ CASE_XTERM_WINOPS, -CASE_DECRC, +CASE_ANSI_RC, CASE_GROUND_STATE, CASE_GROUND_STATE, /* x y z { */ @@ -641,7 +641,7 @@ /* cedilla onesuperior masculine guillemotright */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* onequarter onehalf threequarters questiondown */ CASE_CSI_IGNORE, @@ -690,12 +690,12 @@ CASE_GROUND_STATE, /* agrave aacute acircumflex atilde */ CASE_HPA, -CASE_GROUND_STATE, +CASE_HPR, CASE_REP, CASE_DA1, /* adiaeresis aring ae ccedilla */ CASE_VPA, -CASE_GROUND_STATE, +CASE_VPR, CASE_CUP, CASE_TBC, /* egrave eacute ecircumflex ediaeresis */ @@ -712,10 +712,10 @@ CASE_GROUND_STATE, CASE_DECLL, CASE_DECSTBM, -CASE_DECSC, +CASE_ANSI_SC, /* ocircumflex otilde odiaeresis division */ CASE_XTERM_WINOPS, -CASE_DECRC, +CASE_ANSI_RC, CASE_GROUND_STATE, CASE_GROUND_STATE, /* oslash ugrave uacute ucircumflex */ @@ -747,7 +747,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -805,7 +805,7 @@ /* 8 9 : ; */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* < = > ? */ CASE_CSI_IGNORE, @@ -854,12 +854,12 @@ CASE_GROUND_STATE, /* ` a b c */ CASE_HPA, -CASE_GROUND_STATE, +CASE_HPR, CASE_REP, CASE_DA1, /* d e f g */ CASE_VPA, -CASE_GROUND_STATE, +CASE_VPR, CASE_CUP, CASE_TBC, /* h i j k */ @@ -876,10 +876,10 @@ CASE_GROUND_STATE, CASE_DECLL, CASE_DECSTBM, -CASE_DECSC, +CASE_ANSI_SC, /* t u v w */ CASE_XTERM_WINOPS, -CASE_DECRC, +CASE_ANSI_RC, CASE_GROUND_STATE, CASE_GROUND_STATE, /* x y z { */ @@ -965,7 +965,7 @@ /* cedilla onesuperior masculine guillemotright */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* onequarter onehalf threequarters questiondown */ CASE_CSI_IGNORE, @@ -1014,12 +1014,12 @@ CASE_GROUND_STATE, /* agrave aacute acircumflex atilde */ CASE_HPA, -CASE_GROUND_STATE, +CASE_HPR, CASE_REP, CASE_DA1, /* adiaeresis aring ae ccedilla */ CASE_VPA, -CASE_GROUND_STATE, +CASE_VPR, CASE_CUP, CASE_TBC, /* egrave eacute ecircumflex ediaeresis */ @@ -1036,10 +1036,10 @@ CASE_GROUND_STATE, CASE_DECLL, CASE_DECSTBM, -CASE_DECSC, +CASE_ANSI_SC, /* ocircumflex otilde odiaeresis division */ CASE_XTERM_WINOPS, -CASE_DECRC, +CASE_ANSI_RC, CASE_GROUND_STATE, CASE_GROUND_STATE, /* oslash ugrave uacute ucircumflex */ @@ -1071,7 +1071,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -1395,7 +1395,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -1720,7 +1720,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -2046,7 +2046,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -2372,7 +2372,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -2696,7 +2696,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -2833,7 +2833,7 @@ CASE_GROUND_STATE, /* x y z { */ CASE_DECSACE, -CASE_GROUND_STATE, +CASE_DECRQCRA, CASE_GROUND_STATE, CASE_GROUND_STATE, /* | } ~ DEL */ @@ -2993,7 +2993,7 @@ CASE_GROUND_STATE, /* oslash ugrave uacute ucircumflex */ CASE_DECSACE, -CASE_GROUND_STATE, +CASE_DECRQCRA, CASE_GROUND_STATE, CASE_GROUND_STATE, /* udiaeresis yacute thorn ydiaeresis */ @@ -3021,7 +3021,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -3079,7 +3079,7 @@ /* 8 9 : ; */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* < = > ? */ CASE_CSI_IGNORE, @@ -3239,7 +3239,7 @@ /* cedilla onesuperior masculine guillemotright */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* onequarter onehalf threequarters questiondown */ CASE_CSI_IGNORE, @@ -3346,7 +3346,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -3671,7 +3671,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -3729,7 +3729,7 @@ /* 8 9 : ; */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* < = > ? */ CASE_CSI_IGNORE, @@ -3889,7 +3889,7 @@ /* cedilla onesuperior masculine guillemotright */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* onequarter onehalf threequarters questiondown */ CASE_CSI_IGNORE, @@ -3995,7 +3995,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -4053,7 +4053,7 @@ /* 8 9 : ; */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* < = > ? */ CASE_CSI_IGNORE, @@ -4213,7 +4213,7 @@ /* cedilla onesuperior masculine guillemotright */ CASE_ESC_DIGIT, CASE_ESC_DIGIT, -CASE_CSI_IGNORE, +CASE_ESC_COLON, CASE_ESC_SEMI, /* onequarter onehalf threequarters questiondown */ CASE_CSI_IGNORE, @@ -4319,7 +4319,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -4643,7 +4643,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -4967,7 +4967,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -5291,7 +5291,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -5615,7 +5615,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -5939,7 +5939,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -5971,7 +5971,7 @@ CASE_ESC_IGNORE, /* $ % & ' */ CASE_ESC_IGNORE, -CASE_ESC_IGNORE, +CASE_SCS_PERCENT, CASE_ESC_IGNORE, CASE_ESC_IGNORE, /* ( ) * + */ @@ -6000,9 +6000,9 @@ CASE_GROUND_STATE, CASE_GROUND_STATE, /* < = > ? */ -CASE_GROUND_STATE, CASE_GSETS, -CASE_GROUND_STATE, +CASE_GSETS, +CASE_GSETS, CASE_GROUND_STATE, /* @ A B C */ CASE_GROUND_STATE, @@ -6045,7 +6045,7 @@ CASE_GROUND_STATE, CASE_GROUND_STATE, /* ` a b c */ -CASE_GROUND_STATE, +CASE_GSETS, CASE_GROUND_STATE, CASE_GROUND_STATE, CASE_GROUND_STATE, @@ -6131,7 +6131,7 @@ CASE_ESC_IGNORE, /* currency yen brokenbar section */ CASE_ESC_IGNORE, -CASE_ESC_IGNORE, +CASE_SCS_PERCENT, CASE_ESC_IGNORE, CASE_ESC_IGNORE, /* diaeresis copyright ordfeminine guillemotleft */ @@ -6160,9 +6160,9 @@ CASE_GROUND_STATE, CASE_GROUND_STATE, /* onequarter onehalf threequarters questiondown */ -CASE_GROUND_STATE, CASE_GSETS, -CASE_GROUND_STATE, +CASE_GSETS, +CASE_GSETS, CASE_GROUND_STATE, /* Agrave Aacute Acircumflex Atilde */ CASE_GROUND_STATE, @@ -6205,7 +6205,7 @@ CASE_GROUND_STATE, CASE_GROUND_STATE, /* agrave aacute acircumflex atilde */ -CASE_GROUND_STATE, +CASE_GSETS, CASE_GROUND_STATE, CASE_GROUND_STATE, CASE_GROUND_STATE, @@ -6263,7 +6263,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -6591,7 +6591,7 @@ CASE_IGNORE, CASE_IGNORE, CASE_IGNORE, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_IGNORE, CASE_IGNORE, CASE_IGNORE, @@ -6916,7 +6916,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_SO, @@ -7222,6 +7222,330 @@ CASE_GROUND_STATE, CASE_IGNORE, }; + +Const PARSE_T scs_pct_table[] = /* SCS % */ +{ +/* NUL SOH STX ETX */ +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +/* EOT ENQ ACK BEL */ +CASE_IGNORE, +CASE_ENQ, +CASE_IGNORE, +CASE_BELL, +/* BS HT NL VT */ +CASE_BS, +CASE_TAB, +CASE_VMOT, +CASE_VMOT, +/* FF CR SO SI */ +CASE_VMOT, +CASE_CR, +CASE_SO, +CASE_SI, +/* DLE DC1 DC2 DC3 */ +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +/* DC4 NAK SYN ETB */ +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +/* CAN EM SUB ESC */ +CASE_GROUND_STATE, +CASE_IGNORE, +CASE_GROUND_STATE, +CASE_ESC, +/* FS GS RS US */ +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +CASE_IGNORE, +/* SP ! " # */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* $ % & ' */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* ( ) * + */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* , - . / */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* 0 1 2 3 */ +CASE_GSETS_PERCENT, +CASE_GROUND_STATE, +CASE_GSETS_PERCENT, +CASE_GSETS_PERCENT, +/* 4 5 6 7 */ +CASE_GROUND_STATE, +CASE_GSETS_PERCENT, +CASE_GSETS_PERCENT, +CASE_GROUND_STATE, +/* 8 9 : ; */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* < = > ? */ +CASE_GROUND_STATE, +CASE_GSETS_PERCENT, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* @ A B C */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* D E F G */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* H I J K */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* L M N O */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* P Q R S */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* T U V W */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* X Y Z [ */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* \ ] ^ _ */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* ` a b c */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* d e f g */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* h i j k */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* l m n o */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* p q r s */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* t u v w */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* x y z { */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* | } ~ DEL */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_IGNORE, +/* 0x80 0x81 0x82 0x83 */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* 0x84 0x85 0x86 0x87 */ +CASE_IND, +CASE_NEL, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* 0x88 0x89 0x8a 0x8b */ +CASE_HTS, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* 0x8c 0x8d 0x8e 0x8f */ +CASE_GROUND_STATE, +CASE_RI, +CASE_SS2, +CASE_SS3, +/* 0x90 0x91 0x92 0x93 */ +CASE_DCS, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* 0x94 0x95 0x96 0x97 */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_SPA, +CASE_EPA, +/* 0x98 0x99 0x9a 0x9b */ +CASE_SOS, +CASE_GROUND_STATE, +CASE_DECID, +CASE_CSI_STATE, +/* 0x9c 0x9d 0x9e 0x9f */ +CASE_ST, +CASE_OSC, +CASE_PM, +CASE_APC, +/* nobreakspace exclamdown cent sterling */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* currency yen brokenbar section */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* diaeresis copyright ordfeminine guillemotleft */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* notsign hyphen registered macron */ +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +CASE_ESC_IGNORE, +/* degree plusminus twosuperior threesuperior */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* acute mu paragraph periodcentered */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* cedilla onesuperior masculine guillemotright */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* onequarter onehalf threequarters questiondown */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* Agrave Aacute Acircumflex Atilde */ +CASE_GSETS_PERCENT, +CASE_GROUND_STATE, +CASE_GSETS_PERCENT, +CASE_GROUND_STATE, +/* Adiaeresis Aring AE Ccedilla */ +CASE_GROUND_STATE, +CASE_GSETS_PERCENT, +CASE_GSETS_PERCENT, +CASE_GROUND_STATE, +/* Egrave Eacute Ecircumflex Ediaeresis */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* Igrave Iacute Icircumflex Idiaeresis */ +CASE_GROUND_STATE, +CASE_GSETS_PERCENT, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* Eth Ntilde Ograve Oacute */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* Ocircumflex Otilde Odiaeresis multiply */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* Ooblique Ugrave Uacute Ucircumflex */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* Udiaeresis Yacute Thorn ssharp */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* agrave aacute acircumflex atilde */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* adiaeresis aring ae ccedilla */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* egrave eacute ecircumflex ediaeresis */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* igrave iacute icircumflex idiaeresis */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* eth ntilde ograve oacute */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* ocircumflex otilde odiaeresis division */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* oslash ugrave uacute ucircumflex */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +/* udiaeresis yacute thorn ydiaeresis */ +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_GROUND_STATE, +CASE_IGNORE, +}; #endif /* OPT_WIDE_CHARS */ #if OPT_VT52_MODE @@ -7242,7 +7566,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_IGNORE, @@ -7566,7 +7890,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_IGNORE, @@ -7890,7 +8214,7 @@ CASE_TAB, CASE_VMOT, CASE_VMOT, -/* NP CR SO SI */ +/* FF CR SO SI */ CASE_VMOT, CASE_CR, CASE_IGNORE, diff -Nru xterm-278/VTparse.def xterm-297/VTparse.def --- xterm-278/VTparse.def 2011-12-04 18:29:33.000000000 +0000 +++ xterm-297/VTparse.def 2013-08-19 00:39:14.000000000 +0000 @@ -1,10 +1,10 @@ -# $XTermId: VTparse.def,v 1.42 2011/12/04 18:29:33 tom Exp $ +# $XTermId: VTparse.def,v 1.47 2013/08/19 00:39:14 tom Exp $ # # vile:confmode rs=lf # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 1996-2010,2011 by Thomas E. Dickey +# Copyright 1996-2012,2013 by Thomas E. Dickey # # All Rights Reserved # @@ -191,3 +191,11 @@ CASE_DECIC CASE_DECBI CASE_DECFI +CASE_DECRQCRA +CASE_HPR +CASE_VPR +CASE_ANSI_SC +CASE_ANSI_RC +CASE_ESC_COLON +CASE_SCS_PERCENT +CASE_GSETS_PERCENT diff -Nru xterm-278/VTparse.h xterm-297/VTparse.h --- xterm-278/VTparse.h 2011-12-04 18:30:20.000000000 +0000 +++ xterm-297/VTparse.h 2013-08-19 00:39:54.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: VTparse.h,v 1.55 2011/12/04 18:30:20 tom Exp $ */ +/* $XTermId: VTparse.h,v 1.62 2013/08/19 00:39:54 tom Exp $ */ /* - * Copyright 2002-2010,2011 by Thomas E. Dickey + * Copyright 2002-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -61,7 +61,7 @@ # if defined(__STDC__) && !defined(__cplusplus) # define Const const # else -# define Const /**/ +# define Const /**/ # endif #endif @@ -91,12 +91,12 @@ #if OPT_DEC_LOCATOR extern Const PARSE_T csi_tick_table[]; -#endif /* OPT_DEC_LOCATOR */ +#endif /* OPT_DEC_LOCATOR */ #if OPT_DEC_RECTOPS extern Const PARSE_T csi_dollar_table[]; extern Const PARSE_T csi_star_table[]; -#endif /* OPT_DEC_LOCATOR */ +#endif /* OPT_DEC_LOCATOR */ #if OPT_VT52_MODE extern Const PARSE_T vt52_table[]; @@ -106,6 +106,7 @@ #if OPT_WIDE_CHARS extern Const PARSE_T esc_pct_table[]; +extern Const PARSE_T scs_pct_table[]; #endif /* @@ -272,5 +273,13 @@ #define CASE_DECIC 150 #define CASE_DECBI 151 #define CASE_DECFI 152 +#define CASE_DECRQCRA 153 +#define CASE_HPR 154 +#define CASE_VPR 155 +#define CASE_ANSI_SC 156 +#define CASE_ANSI_RC 157 +#define CASE_ESC_COLON 158 +#define CASE_SCS_PERCENT 159 +#define CASE_GSETS_PERCENT 160 #endif /* included_VTparse_h */ diff -Nru xterm-278/XTerm.ad xterm-297/XTerm.ad --- xterm-278/XTerm.ad 2011-07-11 10:52:16.000000000 +0000 +++ xterm-297/XTerm.ad 2013-06-23 08:57:13.000000000 +0000 @@ -1,4 +1,4 @@ -! $XTermId: XTerm.ad,v 1.97 2011/07/11 10:52:16 tom Exp $ +! $XTermId: XTerm.ad,v 1.99 2013/06/23 08:57:13 Ross.Combs Exp $ ! ----------------------------------------------------------------------------- ! this file is part of xterm ! @@ -100,6 +100,8 @@ *vtMenu*tekmode*Label: Switch to Tek Mode *vtMenu*vthide*Label: Hide VT Window *vtMenu*altscreen*Label: Show Alternate Screen +*vtMenu*sixelScrolling*Label: Sixel Scrolling +*vtMenu*privateColorRegisters*Label: Private Color Registers *fontMenu.Label: VT Fonts *fontMenu*fontdefault*Label: Default diff -Nru xterm-278/aclocal.m4 xterm-297/aclocal.m4 --- xterm-278/aclocal.m4 2012-01-12 13:09:35.000000000 +0000 +++ xterm-297/aclocal.m4 2013-07-10 01:29:34.000000000 +0000 @@ -1,8 +1,8 @@ -dnl $XTermId: aclocal.m4,v 1.321 2012/01/12 13:09:35 tom Exp $ +dnl $XTermId: aclocal.m4,v 1.369 2013/07/10 01:29:34 tom Exp $ dnl dnl --------------------------------------------------------------------------- dnl -dnl Copyright 1997-2010,2011 by Thomas E. Dickey +dnl Copyright 1997-2012,2013 by Thomas E. Dickey dnl dnl All Rights Reserved dnl @@ -13,10 +13,10 @@ dnl distribute, sublicense, and/or sell copies of the Software, and to dnl permit persons to whom the Software is furnished to do so, subject to dnl the following conditions: -dnl +dnl dnl The above copyright notice and this permission notice shall be included dnl in all copies or substantial portions of the Software. -dnl +dnl dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. @@ -24,7 +24,7 @@ dnl CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, dnl TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE dnl SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -dnl +dnl dnl Except as contained in this notice, the name(s) of the above copyright dnl holders shall not be used in advertising or otherwise to promote the dnl sale, use or other dealings in this Software without prior written @@ -58,27 +58,28 @@ fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_ACVERSION_CHECK version: 2 updated: 2011/05/08 11:22:03 +dnl CF_ACVERSION_CHECK version: 4 updated: 2013/03/04 19:52:56 dnl ------------------ dnl Conditionally generate script according to whether we're using a given autoconf. dnl dnl $1 = version to compare against dnl $2 = code to use if AC_ACVERSION is at least as high as $1. dnl $3 = code to use if AC_ACVERSION is older than $1. -define(CF_ACVERSION_CHECK, +define([CF_ACVERSION_CHECK], [ +ifdef([AC_ACVERSION], ,[m4_copy([m4_PACKAGE_VERSION],[AC_ACVERSION])])dnl ifdef([m4_version_compare], [m4_if(m4_version_compare(m4_defn([AC_ACVERSION]), [$1]), -1, [$3], [$2])], [CF_ACVERSION_COMPARE( AC_PREREQ_CANON(AC_PREREQ_SPLIT([$1])), AC_PREREQ_CANON(AC_PREREQ_SPLIT(AC_ACVERSION)), AC_ACVERSION, [$2], [$3])])])dnl dnl --------------------------------------------------------------------------- -dnl CF_ACVERSION_COMPARE version: 2 updated: 2011/04/14 20:56:50 +dnl CF_ACVERSION_COMPARE version: 3 updated: 2012/10/03 18:39:53 dnl -------------------- dnl CF_ACVERSION_COMPARE(MAJOR1, MINOR1, TERNARY1, dnl MAJOR2, MINOR2, TERNARY2, dnl PRINTABLE2, not FOUND, FOUND) -define(CF_ACVERSION_COMPARE, +define([CF_ACVERSION_COMPARE], [ifelse(builtin([eval], [$2 < $5]), 1, [ifelse([$8], , ,[$8])], [ifelse([$9], , ,[$9])])])dnl @@ -187,7 +188,7 @@ dnl $2 = variable to update (default $LIBS) AC_DEFUN([CF_ADD_LIBS],[ifelse($2,,LIBS,[$2])="$1 [$]ifelse($2,,LIBS,[$2])"])dnl dnl --------------------------------------------------------------------------- -dnl CF_ADD_LIB_AFTER version: 2 updated: 2010/11/08 20:33:46 +dnl CF_ADD_LIB_AFTER version: 3 updated: 2013/07/09 21:27:22 dnl ---------------- dnl Add a given library after another, e.g., following the one it satisfies a dnl dependency for. @@ -196,83 +197,10 @@ dnl $2 = its dependency AC_DEFUN([CF_ADD_LIB_AFTER],[ CF_VERBOSE(...before $LIBS) -LIBS=`echo "$LIBS" | sed -e "s/[[ ]][[ ]]*/ /g" -e "s,$1 ,$1 $2 ," -e 's/ / /g'` +LIBS=`echo "$LIBS" | sed -e "s/[[ ]][[ ]]*/ /g" -e "s%$1 %$1 $2 %" -e 's% % %g'` CF_VERBOSE(...after $LIBS) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_ANSI_CC_CHECK version: 11 updated: 2011/07/01 19:47:45 -dnl ---------------- -dnl This was originally adapted from the macros 'fp_PROG_CC_STDC' and -dnl 'fp_C_PROTOTYPES' in the sharutils 4.2 distribution. -AC_DEFUN([CF_ANSI_CC_CHECK], -[ -# This should have been defined by AC_PROG_CC -: ${CC:=cc} - -# Check for user's environment-breakage by stuffing CFLAGS/CPPFLAGS content -# into CC. This will not help with broken scripts that wrap the compiler with -# options, but eliminates a more common category of user confusion. -AC_MSG_CHECKING(\$CC variable) -case "$CC" in #(vi -*[[\ \ ]]-[[IUD]]*) - AC_MSG_RESULT(broken) - AC_MSG_WARN(your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options) - # humor him... - cf_flags=`echo "$CC" | sed -e 's/^[[^ ]]*[[ ]]//'` - CC=`echo "$CC" | sed -e 's/[[ ]].*//'` - CF_ADD_CFLAGS($cf_flags) - ;; -*) - AC_MSG_RESULT(ok) - ;; -esac - -AC_CACHE_CHECK(for ${CC:-cc} option to accept ANSI C, cf_cv_ansi_cc,[ -cf_cv_ansi_cc=no -cf_save_CFLAGS="$CFLAGS" -cf_save_CPPFLAGS="$CPPFLAGS" -# Don't try gcc -ansi; that turns off useful extensions and -# breaks some systems' header files. -# AIX -qlanglvl=ansi -# Ultrix and OSF/1 -std1 -# HP-UX -Aa -D_HPUX_SOURCE -# SVR4 -Xc -# UnixWare 1.2 (cannot use -Xc, since ANSI/POSIX clashes) -for cf_arg in "-DCC_HAS_PROTOS" \ - "" \ - -qlanglvl=ansi \ - -std1 \ - -Ae \ - "-Aa -D_HPUX_SOURCE" \ - -Xc -do - CF_ADD_CFLAGS($cf_arg) - AC_TRY_COMPILE( -[ -#ifndef CC_HAS_PROTOS -#if !defined(__STDC__) || (__STDC__ != 1) -choke me -#endif -#endif -],[ - int test (int i, double x); - struct s1 {int (*f) (int a);}; - struct s2 {int (*f) (double a);};], - [cf_cv_ansi_cc="$cf_arg"; break]) -done -CFLAGS="$cf_save_CFLAGS" -CPPFLAGS="$cf_save_CPPFLAGS" -]) - -if test "$cf_cv_ansi_cc" != "no"; then -if test ".$cf_cv_ansi_cc" != ".-DCC_HAS_PROTOS"; then - CF_ADD_CFLAGS($cf_cv_ansi_cc) -else - AC_DEFINE(CC_HAS_PROTOS) -fi -fi -])dnl -dnl --------------------------------------------------------------------------- dnl CF_ARG_DISABLE version: 3 updated: 1999/03/30 17:24:31 dnl -------------- dnl Allow user to disable a normally-on option. @@ -308,7 +236,33 @@ ])dnl ])])dnl dnl --------------------------------------------------------------------------- -dnl CF_CHECK_CACHE version: 11 updated: 2008/03/23 14:45:59 +dnl CF_CC_ENV_FLAGS version: 1 updated: 2012/10/03 05:25:49 +dnl --------------- +dnl Check for user's environment-breakage by stuffing CFLAGS/CPPFLAGS content +dnl into CC. This will not help with broken scripts that wrap the compiler with +dnl options, but eliminates a more common category of user confusion. +AC_DEFUN([CF_CC_ENV_FLAGS], +[ +# This should have been defined by AC_PROG_CC +: ${CC:=cc} + +AC_MSG_CHECKING(\$CC variable) +case "$CC" in #(vi +*[[\ \ ]]-[[IUD]]*) + AC_MSG_RESULT(broken) + AC_MSG_WARN(your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options) + # humor him... + cf_flags=`echo "$CC" | sed -e 's/^[[^ ]]*[[ ]]//'` + CC=`echo "$CC" | sed -e 's/[[ ]].*//'` + CF_ADD_CFLAGS($cf_flags) + ;; +*) + AC_MSG_RESULT(ok) + ;; +esac +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_CHECK_CACHE version: 12 updated: 2012/10/02 20:55:03 dnl -------------- dnl Check if we're accidentally using a cache from a different machine. dnl Derive the system name, as a check for reusing the autoconf cache. @@ -331,7 +285,7 @@ system_name="`(hostname) 2>/dev/null`" fi fi -test -n "$system_name" && AC_DEFINE_UNQUOTED(SYSTEM_NAME,"$system_name") +test -n "$system_name" && AC_DEFINE_UNQUOTED(SYSTEM_NAME,"$system_name",[Define to the system name.]) AC_CACHE_VAL(cf_cv_system_name,[cf_cv_system_name="$system_name"]) test -z "$system_name" && system_name="$cf_cv_system_name" @@ -422,6 +376,39 @@ ])dnl dnl --------------------------------------------------------------------------- +dnl CF_CLANG_COMPILER version: 1 updated: 2012/06/16 14:55:39 +dnl ----------------- +dnl Check if the given compiler is really clang. clang's C driver defines +dnl __GNUC__ (fooling the configure script into setting $GCC to yes) but does +dnl not ignore some gcc options. +dnl +dnl This macro should be run "soon" after AC_PROG_CC or AC_PROG_CPLUSPLUS, to +dnl ensure that it is not mistaken for gcc/g++. It is normally invoked from +dnl the wrappers for gcc and g++ warnings. +dnl +dnl $1 = GCC (default) or GXX +dnl $2 = INTEL_COMPILER (default) or INTEL_CPLUSPLUS +dnl $3 = CFLAGS (default) or CXXFLAGS +AC_DEFUN([CF_CLANG_COMPILER],[ +ifelse([$2],,CLANG_COMPILER,[$2])=no + +if test "$ifelse([$1],,[$1],GCC)" = yes ; then + AC_MSG_CHECKING(if this is really Clang ifelse([$1],GXX,C++,C) compiler) + cf_save_CFLAGS="$ifelse([$3],,CFLAGS,[$3])" + ifelse([$3],,CFLAGS,[$3])="$ifelse([$3],,CFLAGS,[$3]) -Qunused-arguments" + AC_TRY_COMPILE([],[ +#ifdef __clang__ +#else +make an error +#endif +],[ifelse([$2],,CLANG_COMPILER,[$2])=yes +cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments" +],[]) + ifelse([$3],,CFLAGS,[$3])="$cf_save_CFLAGS" + AC_MSG_RESULT($ifelse([$2],,CLANG_COMPILER,[$2])) +fi +]) +dnl --------------------------------------------------------------------------- dnl CF_DISABLE_DESKTOP version: 2 updated: 2011/04/22 05:17:37 dnl ------------------ dnl Handle a configure option "--disable-desktop", which sets a shell @@ -452,7 +439,7 @@ AC_SUBST(DESKTOP_FLAGS) ]) dnl --------------------------------------------------------------------------- -dnl CF_DISABLE_ECHO version: 11 updated: 2009/12/13 13:16:57 +dnl CF_DISABLE_ECHO version: 12 updated: 2012/10/06 16:30:28 dnl --------------- dnl You can always use "make -n" to see the actual options, but it's hard to dnl pick out/analyze warning messages when the compile-line is long. @@ -467,7 +454,7 @@ AC_DEFUN([CF_DISABLE_ECHO],[ AC_MSG_CHECKING(if you want to see long compiling messages) CF_ARG_DISABLE(echo, - [ --disable-echo display "compiling" commands], + [ --disable-echo do not display "compiling" commands], [ ECHO_LT='--silent' ECHO_LD='@echo linking [$]@;' @@ -489,6 +476,29 @@ AC_SUBST(ECHO_CC) ])dnl dnl --------------------------------------------------------------------------- +dnl CF_DISABLE_LEAKS version: 7 updated: 2012/10/02 20:55:03 +dnl ---------------- +dnl Combine no-leak checks with the libraries or tools that are used for the +dnl checks. +AC_DEFUN([CF_DISABLE_LEAKS],[ + +AC_REQUIRE([CF_WITH_DMALLOC]) +AC_REQUIRE([CF_WITH_DBMALLOC]) +AC_REQUIRE([CF_WITH_VALGRIND]) + +AC_MSG_CHECKING(if you want to perform memory-leak testing) +AC_ARG_ENABLE(leaks, + [ --disable-leaks test: free permanent memory, analyze leaks], + [if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi], + : ${with_no_leaks:=no}) +AC_MSG_RESULT($with_no_leaks) + +if test "$with_no_leaks" = yes ; then + AC_DEFINE(NO_LEAKS,1,[Define to 1 if you want to perform memory-leak testing.]) + AC_DEFINE(YY_NO_LEAKS,1,[Define to 1 if you want to perform memory-leak testing.]) +fi +])dnl +dnl --------------------------------------------------------------------------- dnl CF_DISABLE_RPATH_HACK version: 2 updated: 2011/02/13 13:31:33 dnl --------------------- dnl The rpath-hack makes it simpler to build programs, particularly with the @@ -543,12 +553,16 @@ CF_CHECK_ERRNO(errno) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_FUNC_GRANTPT version: 3 updated: 2012/01/12 08:07:51 +dnl CF_FUNC_GRANTPT version: 10 updated: 2013/04/17 05:31:24 dnl --------------- dnl Check for grantpt versus openpty, as well as functions that "should" be dnl available if grantpt is available. AC_DEFUN([CF_FUNC_GRANTPT],[ +AC_CHECK_HEADERS( \ +stropts.h \ +) + cf_func_grantpt="grantpt ptsname" case $host_os in #(vi darwin[[0-9]].*) #(vi @@ -560,52 +574,134 @@ AC_CHECK_FUNCS($cf_func_grantpt) -if test "x$ac_cv_func_grantpt" != "xyes" ; then +cf_grantpt_opts= +if test "x$ac_cv_func_grantpt" = "xyes" ; then + AC_MSG_CHECKING(if grantpt really works) + AC_TRY_LINK(CF__GRANTPT_HEAD,CF__GRANTPT_BODY,[ + AC_TRY_RUN(CF__GRANTPT_HEAD +int main(void) +{ +CF__GRANTPT_BODY +} +, +,ac_cv_func_grantpt=no +,ac_cv_func_grantpt=maybe) + ],ac_cv_func_grantpt=no) + AC_MSG_RESULT($ac_cv_func_grantpt) + + if test "x$ac_cv_func_grantpt" != "xno" ; then + + if test "x$ac_cv_func_grantpt" = "xyes" ; then + AC_MSG_CHECKING(for pty features) +dnl if we have no stropts.h, skip the checks for streams modules + if test "x$ac_cv_header_stropts_h" = xyes + then + cf_pty_this=0 + else + cf_pty_this=3 + fi + + cf_pty_defines= + while test $cf_pty_this != 6 + do + + cf_pty_feature= + cf_pty_next=`expr $cf_pty_this + 1` + CF_MSG_LOG(pty feature test $cf_pty_next:5) + AC_TRY_RUN(#define CONFTEST $cf_pty_this +$cf_pty_defines +CF__GRANTPT_HEAD +int main(void) +{ +CF__GRANTPT_BODY +} +, +[ + case $cf_pty_next in #(vi + 1) #(vi - streams + cf_pty_feature=ptem + ;; + 2) #(vi - streams + cf_pty_feature=ldterm + ;; + 3) #(vi - streams + cf_pty_feature=ttcompat + ;; + 4) #(vi + cf_pty_feature=pty_isatty + ;; + 5) #(vi + cf_pty_feature=pty_tcsetattr + ;; + 6) #(vi + cf_pty_feature=tty_tcsetattr + ;; + esac +],[ + case $cf_pty_next in #(vi + 1|2|3) + CF_MSG_LOG(skipping remaining streams features $cf_pty_this..2) + cf_pty_next=3 + ;; + esac +]) + if test -n "$cf_pty_feature" + then + cf_pty_defines="$cf_pty_defines +#define CONFTEST_$cf_pty_feature 1 +" + cf_grantpt_opts="$cf_grantpt_opts $cf_pty_feature" + fi + + cf_pty_this=$cf_pty_next + done + AC_MSG_RESULT($cf_grantpt_opts) + cf_grantpt_opts=`echo "$cf_grantpt_opts" | sed -e 's/ isatty//'` + fi + fi +fi + +dnl If we found grantpt, but no features, e.g., for streams or if we are not +dnl able to use tcsetattr, then give openpty a try. In particular, Darwin 10.7 +dnl has a more functional openpty than posix_openpt. +dnl +dnl There is no configure run-test for openpty, since older implementations do +dnl not always run properly as a non-root user. For that reason, we also allow +dnl the configure script to suppress this check entirely with $disable_openpty. +if test "x$disable_openpty" != "xyes" || test -z "$cf_grantpt_opts" ; then AC_CHECK_LIB(util, openpty, [cf_have_openpty=yes],[cf_have_openpty=no]) if test "$cf_have_openpty" = yes ; then + ac_cv_func_grantpt=no LIBS="-lutil $LIBS" - AC_DEFINE(HAVE_OPENPTY) - AC_CHECK_HEADERS( \ + AC_DEFINE(HAVE_OPENPTY,1,[Define to 1 if you have the openpty function]) + AC_CHECK_HEADERS( \ util.h \ libutil.h \ pty.h \ ) fi fi + +dnl If we did not settle on using openpty, fill in the definitions for grantpt. +if test "x$ac_cv_func_grantpt" != xno +then + CF_VERBOSE(will rely upon grantpt) + AC_DEFINE(HAVE_WORKING_GRANTPT,1,[Define to 1 if the grantpt function seems to work]) + for cf_feature in $cf_grantpt_opts + do + cf_feature=`echo "$cf_feature" | sed -e 's/ //g'` + CF_UPPER(cf_FEATURE,$cf_feature) + AC_DEFINE_UNQUOTED(HAVE_GRANTPT_$cf_FEATURE) + done +elif test "x$cf_have_openpty" = xno +then + CF_VERBOSE(will rely upon BSD-pseudoterminals) +else + CF_VERBOSE(will rely upon openpty) +fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_FUNC_MEMMOVE version: 7 updated: 2006/12/16 12:33:30 -dnl --------------- -dnl Check for memmove, or a bcopy that can handle overlapping copy. If neither -dnl is found, add our own version of memmove to the list of objects. -AC_DEFUN([CF_FUNC_MEMMOVE], -[ -AC_CHECK_FUNC(memmove,,[ -AC_CHECK_FUNC(bcopy,[ - AC_CACHE_CHECK(if bcopy does overlapping moves,cf_cv_good_bcopy,[ - AC_TRY_RUN([ -int main() { - static char data[] = "abcdefghijklmnopqrstuwwxyz"; - char temp[40]; - bcopy(data, temp, sizeof(data)); - bcopy(temp+10, temp, 15); - bcopy(temp+5, temp+15, 10); - ${cf_cv_main_return:-return} (strcmp(temp, "klmnopqrstuwwxypqrstuwwxyz")); -} - ], - [cf_cv_good_bcopy=yes], - [cf_cv_good_bcopy=no], - [cf_cv_good_bcopy=unknown]) - ]) - ],[cf_cv_good_bcopy=no]) - if test "$cf_cv_good_bcopy" = yes ; then - AC_DEFINE(USE_OK_BCOPY) - else - AC_DEFINE(USE_MY_MEMMOVE) - fi -])])dnl -dnl --------------------------------------------------------------------------- -dnl CF_FUNC_TGETENT version: 18 updated: 2011/08/09 21:06:37 +dnl CF_FUNC_TGETENT version: 19 updated: 2012/10/04 20:12:20 dnl --------------- dnl Check for tgetent function in termcap library. If we cannot find this, dnl we'll use the $LINES and $COLUMNS environment variables to pass screen @@ -691,7 +787,7 @@ # they are not executed when a cached value exists.) if test "x$cf_cv_lib_tgetent" != xno ; then test "x$cf_cv_lib_tgetent" != xyes && CF_ADD_LIBS($cf_cv_lib_tgetent) - AC_DEFINE(USE_TERMCAP) + AC_DEFINE(USE_TERMCAP,1,[Define 1 to indicate that working tgetent is found]) if test "$cf_full_tgetent" = no ; then AC_TRY_COMPILE([ #include ],[ @@ -725,12 +821,12 @@ # If this is linking against ncurses, we'll trigger the # ifdef in resize.c that turns the termcap stuff back off. - AC_DEFINE(USE_TERMINFO) + AC_DEFINE(USE_TERMINFO,1,[Define to 1 to indicate that terminfo provides the tgetent interface]) fi fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_GCC_ATTRIBUTES version: 14 updated: 2010/10/23 15:52:32 +dnl CF_GCC_ATTRIBUTES version: 16 updated: 2012/10/02 20:55:03 dnl ----------------- dnl Test for availability of useful gcc __attribute__ directives to quiet dnl compiler warnings. Though useful, not all are supported -- and contrary @@ -808,27 +904,27 @@ test -n "$verbose" && AC_MSG_RESULT(... $cf_attribute) cat conftest.h >>confdefs.h case $cf_attribute in #(vi + noreturn) #(vi + AC_DEFINE_UNQUOTED(GCC_NORETURN,$cf_directive,[Define to noreturn-attribute for gcc]) + ;; printf) #(vi - if test "$cf_printf_attribute" = no ; then - cat >>confdefs.h <>confdefs.h <>confdefs.h <>confdefs.h < conftest.$ac_ext <&AC_FD_CC ])dnl dnl --------------------------------------------------------------------------- -dnl CF_PATHSEP version: 5 updated: 2010/05/26 05:38:42 +dnl CF_NO_LEAKS_OPTION version: 5 updated: 2012/10/02 20:55:03 +dnl ------------------ +dnl see CF_WITH_NO_LEAKS +AC_DEFUN([CF_NO_LEAKS_OPTION],[ +AC_MSG_CHECKING(if you want to use $1 for testing) +AC_ARG_WITH($1, + [$2], + [AC_DEFINE_UNQUOTED($3,1,"Define to 1 if you want to use $1 for testing.")ifelse([$4],,[ + $4 +]) + : ${with_cflags:=-g} + : ${with_no_leaks:=yes} + with_$1=yes], + [with_$1=]) +AC_MSG_RESULT(${with_$1:-no}) + +case .$with_cflags in #(vi +.*-g*) + case .$CFLAGS in #(vi + .*-g*) #(vi + ;; + *) + CF_ADD_CFLAGS([-g]) + ;; + esac + ;; +esac +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_PATHSEP version: 6 updated: 2012/09/29 18:38:12 dnl ---------- -dnl Provide a value for the $PATH and similar separator +dnl Provide a value for the $PATH and similar separator (or amend the value +dnl as provided in autoconf 2.5x). AC_DEFUN([CF_PATHSEP], [ + AC_MSG_CHECKING(for PATH separator) case $cf_cv_system_name in os2*) PATH_SEPARATOR=';' ;; - *) PATH_SEPARATOR=':' ;; + *) ${PATH_SEPARATOR:=':'} ;; esac ifelse([$1],,,[$1=$PATH_SEPARATOR]) AC_SUBST(PATH_SEPARATOR) + AC_MSG_RESULT($PATH_SEPARATOR) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_PATH_PROG version: 8 updated: 2010/10/23 16:12:25 +dnl CF_PATH_PROG version: 9 updated: 2012/10/04 20:12:20 dnl ------------ dnl Check for a given program, defining corresponding symbol. dnl $1 = environment variable, which is suffixed by "_PATH" in the #define. @@ -1431,12 +1568,12 @@ if test -n "$cf_path_prog" ; then CF_MSG_LOG(defining path for ${cf_path_prog}) - AC_DEFINE_UNQUOTED($1_PATH,"$cf_path_prog") - test -n "$cf_path_args" && AC_DEFINE_UNQUOTED($1_ARGS,"$cf_path_args") + AC_DEFINE_UNQUOTED($1_PATH,"$cf_path_prog",Define to pathname $1) + test -n "$cf_path_args" && AC_DEFINE_UNQUOTED($1_ARGS,"$cf_path_args",Define to provide args for $1) fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_PATH_SYNTAX version: 13 updated: 2010/05/26 05:38:42 +dnl CF_PATH_SYNTAX version: 14 updated: 2012/06/19 20:58:54 dnl -------------- dnl Check the argument to see that it looks like a pathname. Rewrite it if it dnl begins with one of the prefix/exec_prefix variables, and then again if the @@ -1456,7 +1593,7 @@ ;; .[[a-zA-Z]]:[[\\/]]*) #(vi OS/2 EMX ;; -.\[$]{*prefix}*) #(vi +.\[$]{*prefix}*|.\[$]{*dir}*) #(vi eval $1="[$]$1" case ".[$]$1" in #(vi .NONE/*) @@ -1580,7 +1717,7 @@ ])dnl dnl --------------------------------------------------------------------------- -dnl CF_POSIX_SAVED_IDS version: 7 updated: 2007/03/14 16:43:53 +dnl CF_POSIX_SAVED_IDS version: 8 updated: 2012/10/04 20:12:20 dnl ------------------ dnl dnl Check first if saved-ids are always supported. Some systems @@ -1628,10 +1765,10 @@ ]) ]) -test "$cf_cv_posix_saved_ids" = yes && AC_DEFINE(HAVE_POSIX_SAVED_IDS) +test "$cf_cv_posix_saved_ids" = yes && AC_DEFINE(HAVE_POSIX_SAVED_IDS,1,[Define to 1 if POSIX saved-ids are supported]) ]) dnl --------------------------------------------------------------------------- -dnl CF_POSIX_WAIT version: 2 updated: 2000/05/29 16:16:04 +dnl CF_POSIX_WAIT version: 3 updated: 2012/10/04 20:12:20 dnl ------------- dnl Check for POSIX wait support AC_DEFUN([CF_POSIX_WAIT], @@ -1653,7 +1790,7 @@ [cf_cv_posix_wait=yes], [cf_cv_posix_wait=no]) ]) -test "$cf_cv_posix_wait" = yes && AC_DEFINE(USE_POSIX_WAIT) +test "$cf_cv_posix_wait" = yes && AC_DEFINE(USE_POSIX_WAIT,1,[Define to 1 if we have POSIX wait functions]) ])dnl dnl --------------------------------------------------------------------------- dnl CF_PROCFS_CWD version: 2 updated: 2007/03/12 20:39:04 @@ -1676,57 +1813,39 @@ ]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_PROG_CC_U_D version: 1 updated: 2005/07/14 16:59:30 -dnl -------------- -dnl Check if C (preprocessor) -U and -D options are processed in the order -dnl given rather than by type of option. Some compilers insist on apply all -dnl of the -U options after all of the -D options. Others allow mixing them, -dnl and may predefine symbols that conflict with those we define. -AC_DEFUN([CF_PROG_CC_U_D], -[ -AC_CACHE_CHECK(if $CC -U and -D options work together,cf_cv_cc_u_d_options,[ - cf_save_CPPFLAGS="$CPPFLAGS" - CPPFLAGS="-UU_D_OPTIONS -DU_D_OPTIONS -DD_U_OPTIONS -UD_U_OPTIONS" - AC_TRY_COMPILE([],[ -#ifndef U_D_OPTIONS -make an undefined-error -#endif -#ifdef D_U_OPTIONS -make a defined-error -#endif - ],[ - cf_cv_cc_u_d_options=yes],[ - cf_cv_cc_u_d_options=no]) - CPPFLAGS="$cf_save_CPPFLAGS" -]) +dnl CF_PROG_CC version: 3 updated: 2012/10/06 15:31:55 +dnl ---------- +dnl standard check for CC, plus followup sanity checks +dnl $1 = optional parameter to pass to AC_PROG_CC to specify compiler name +AC_DEFUN([CF_PROG_CC],[ +ifelse($1,,[AC_PROG_CC],[AC_PROG_CC($1)]) +CF_GCC_VERSION +CF_ACVERSION_CHECK(2.52, + [AC_PROG_CC_STDC], + [CF_ANSI_CC_REQD]) +CF_CC_ENV_FLAGS ])dnl dnl --------------------------------------------------------------------------- -dnl CF_PROG_EXT version: 10 updated: 2004/01/03 19:28:18 -dnl ----------- -dnl Compute $PROG_EXT, used for non-Unix ports, such as OS/2 EMX. -AC_DEFUN([CF_PROG_EXT], -[ -AC_REQUIRE([CF_CHECK_CACHE]) -case $cf_cv_system_name in -os2*) - CFLAGS="$CFLAGS -Zmt" - CPPFLAGS="$CPPFLAGS -D__ST_MT_ERRNO__" - CXXFLAGS="$CXXFLAGS -Zmt" - # autoconf's macro sets -Zexe and suffix both, which conflict:w - LDFLAGS="$LDFLAGS -Zmt -Zcrtdll" - ac_cv_exeext=.exe - ;; -esac - -AC_EXEEXT -AC_OBJEXT - -PROG_EXT="$EXEEXT" -AC_SUBST(PROG_EXT) -test -n "$PROG_EXT" && AC_DEFINE_UNQUOTED(PROG_EXT,"$PROG_EXT") +dnl CF_PROG_GROFF version: 1 updated: 2013/01/02 20:37:18 +dnl ------------- +dnl Check if groff is available, for cases (such as html output) where nroff +dnl is not enough. +AC_DEFUN([CF_PROG_GROFF],[ +AC_PATH_PROG(GROFF_PATH,groff,no) +if test "x$GROFF_PATH" = xno +then + NROFF_NOTE= + GROFF_NOTE="#" +else + NROFF_NOTE="#" + GROFF_NOTE= +fi +AC_SUBST(GROFF_PATH) +AC_SUBST(GROFF_NOTE) +AC_SUBST(NROFF_NOTE) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_REGEX version: 8 updated: 2010/08/07 14:09:44 +dnl CF_REGEX version: 10 updated: 2012/10/04 20:12:20 dnl -------- dnl Attempt to determine if we've got one of the flavors of regular-expression dnl code that we can support. @@ -1738,7 +1857,7 @@ cf_regex_libs="regex re" case $host_os in #(vi mingw*) - cf_regex_libs="regex.dll $cf_regex_libs" + cf_regex_libs="gnurx $cf_regex_libs" ;; esac @@ -1800,9 +1919,9 @@ case $cf_cv_regex_hdrs in #(vi no) AC_MSG_WARN(no regular expression header found) ;; #(vi - regex.h) AC_DEFINE(HAVE_REGEX_H_FUNCS) ;; #(vi - regexp.h) AC_DEFINE(HAVE_REGEXP_H_FUNCS) ;; #(vi - regexpr.h) AC_DEFINE(HAVE_REGEXPR_H_FUNCS) ;; + regex.h) AC_DEFINE(HAVE_REGEX_H_FUNCS,1,[Define to 1 to include regex.h for regular expressions]) ;; #(vi + regexp.h) AC_DEFINE(HAVE_REGEXP_H_FUNCS,1,[Define to 1 to include regexp.h for regular expressions]) ;; #(vi + regexpr.h) AC_DEFINE(HAVE_REGEXPR_H_FUNCS,1,[Define to 1 to include regexpr.h for regular expressions]) ;; esac ])dnl dnl --------------------------------------------------------------------------- @@ -1997,7 +2116,7 @@ fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_SIG_ATOMIC_T version: 2 updated: 2005/09/18 17:27:12 +dnl CF_SIG_ATOMIC_T version: 3 updated: 2012/10/04 20:12:20 dnl --------------- dnl signal handler, but there are some gcc depedencies in that recommendation. dnl Try anyway. @@ -2029,32 +2148,10 @@ done ]) AC_MSG_RESULT($cf_cv_sig_atomic_t) -test "$cf_cv_sig_atomic_t" != no && AC_DEFINE_UNQUOTED(SIG_ATOMIC_T, $cf_cv_sig_atomic_t) -])dnl -dnl --------------------------------------------------------------------------- -dnl CF_SIZE_T version: 4 updated: 2000/01/22 00:19:54 -dnl --------- -dnl On both Ultrix and CLIX, I find size_t defined in -AC_DEFUN([CF_SIZE_T], -[ -AC_MSG_CHECKING(for size_t in or ) -AC_CACHE_VAL(cf_cv_type_size_t,[ - AC_TRY_COMPILE([ -#include -#ifdef STDC_HEADERS -#include -#include -#endif -#include ], - [size_t x], - [cf_cv_type_size_t=yes], - [cf_cv_type_size_t=no]) - ]) -AC_MSG_RESULT($cf_cv_type_size_t) -test $cf_cv_type_size_t = no && AC_DEFINE(size_t, unsigned) +test "$cf_cv_sig_atomic_t" != no && AC_DEFINE_UNQUOTED(SIG_ATOMIC_T, $cf_cv_sig_atomic_t,[Define to signal global datatype]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_STRUCT_LASTLOG version: 1 updated: 2006/03/12 17:46:43 +dnl CF_STRUCT_LASTLOG version: 2 updated: 2012/10/04 20:12:20 dnl ----------------- dnl Check for header defining struct lastlog, ensure that its .ll_time member dnl is compatible with time(). @@ -2076,10 +2173,10 @@ cf_cv_struct_lastlog=no],[ cf_cv_struct_lastlog=unknown])]) -test $cf_cv_struct_lastlog != no && AC_DEFINE(USE_STRUCT_LASTLOG) +test $cf_cv_struct_lastlog != no && AC_DEFINE(USE_STRUCT_LASTLOG,1,[Define to 1 if we have struct lastlog]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_SVR4 version: 4 updated: 2011/09/04 17:17:53 +dnl CF_SVR4 version: 5 updated: 2012/10/04 05:24:07 dnl ------- dnl Check if this is an SVR4 system. We need the definition for xterm AC_DEFUN([CF_SVR4], @@ -2108,10 +2205,10 @@ [cf_cv_svr4=no]) ]) ]) -test "$cf_cv_svr4" = yes && AC_DEFINE(SVR4) +test "$cf_cv_svr4" = yes && AC_DEFINE(SVR4,1,[Define to 1 if this is an SVR4 system]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_SYSV version: 13 updated: 2006/08/20 14:55:37 +dnl CF_SYSV version: 15 updated: 2012/10/04 05:24:07 dnl ------- dnl Check if this is a SYSV platform, e.g., as used in , and whether dnl defining it will be helpful. The following features are used to check: @@ -2144,12 +2241,12 @@ #ifdef HAVE_X11_INTRINSIC_H #include /* Intrinsic.h has other traps... */ #endif -#ifdef HAVE_TERMIOS_H /* needed for HPUX 10.20 */ -#include -#define STRUCT_TERMIOS struct termios -#else -#define STRUCT_TERMIOS struct termio -#endif +#ifdef HAVE_TERMIOS_H /* needed for HPUX 10.20 */ +#include +#define STRUCT_TERMIOS struct termios +#else +#define STRUCT_TERMIOS struct termio +#endif #include #include /* eliminate most BSD hacks */ #include /* declare sys_errlist on older systems */ @@ -2171,10 +2268,10 @@ [cf_cv_sysv=yes], [cf_cv_sysv=no]) ]) -test "$cf_cv_sysv" = yes && AC_DEFINE(SYSV) +test "$cf_cv_sysv" = yes && AC_DEFINE(SYSV,1,[Define to 1 if this is an SYSV system]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_SYSV_UTMP version: 5 updated: 2001/12/27 12:55:07 +dnl CF_SYSV_UTMP version: 6 updated: 2012/10/04 20:12:20 dnl ------------ dnl Check if this is a SYSV flavor of UTMP AC_DEFUN([CF_SYSV_UTMP], @@ -2192,7 +2289,7 @@ [cf_cv_sysv_utmp=yes], [cf_cv_sysv_utmp=no]) ]) -test $cf_cv_sysv_utmp = yes && AC_DEFINE(USE_SYSV_UTMP) +test $cf_cv_sysv_utmp = yes && AC_DEFINE(USE_SYSV_UTMP,1,[Define to 1 if utmp is SYSV flavor]) ])dnl dnl --------------------------------------------------------------------------- dnl CF_SYS_ERRLIST version: 6 updated: 2001/12/30 13:03:23 @@ -2206,7 +2303,7 @@ CF_CHECK_ERRNO(sys_errlist) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_TERMIO_C_ISPEED version: 2 updated: 2000/05/29 16:16:04 +dnl CF_TERMIO_C_ISPEED version: 3 updated: 2012/10/04 20:12:20 dnl ------------------ dnl Check for SGI's broken redefinition of baud rates introduced in IRIX 6.5 dnl (there doesn't appear to be a useful predefined symbol). @@ -2222,10 +2319,26 @@ ],[cf_cv_termio_c_ispeed=yes ],[cf_cv_termio_c_ispeed=no]) ]) -test "$cf_cv_termio_c_ispeed" = yes && AC_DEFINE(HAVE_TERMIO_C_ISPEED) +test "$cf_cv_termio_c_ispeed" = yes && AC_DEFINE(HAVE_TERMIO_C_ISPEED,1,[define 1 if we have IRIX 6.5 baud-rate redefinitions]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_TRY_PKG_CONFIG version: 4 updated: 2010/06/14 17:42:30 +dnl CF_TRIM_X_LIBS version: 2 updated: 2013/07/09 21:27:22 +dnl -------------- +dnl Trim extra base X libraries added as a workaround for inconsistent library +dnl dependencies returned by "new" pkg-config files. +AC_DEFUN([CF_TRIM_X_LIBS],[ + for cf_trim_lib in Xmu Xt X11 + do + case "$LIBS" in + *-l$cf_trim_lib\ *-l$cf_trim_lib*) + LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'` + CF_VERBOSE(..trimmed $LIBS) + ;; + esac + done +]) +dnl --------------------------------------------------------------------------- +dnl CF_TRY_PKG_CONFIG version: 5 updated: 2013/07/06 21:27:06 dnl ----------------- dnl This is a simple wrapper to use for pkg-config, for libraries which may be dnl available in that form. @@ -2246,6 +2359,8 @@ CF_ADD_LIBS($cf_pkgconfig_libs) ifelse([$2],,:,[$2]) else + cf_pkgconfig_incs= + cf_pkgconfig_libs= ifelse([$3],,:,[$3]) fi ]) @@ -2289,7 +2404,7 @@ fi ]) dnl --------------------------------------------------------------------------- -dnl CF_TTY_GROUP version: 7 updated: 2007/03/14 16:43:59 +dnl CF_TTY_GROUP version: 8 updated: 2012/10/04 20:12:20 dnl ------------ dnl Check if the system has a tty-group defined. This is used in xterm when dnl setting pty ownership. @@ -2356,10 +2471,10 @@ cf_tty_group="$cf_cv_tty_group_name" else # if configure option, always do this - AC_DEFINE(USE_TTY_GROUP) + AC_DEFINE(USE_TTY_GROUP,1,[Define to 1 if we have a tty groupname]) fi -AC_DEFINE_UNQUOTED(TTY_GROUP_NAME,"$cf_tty_group") +AC_DEFINE_UNQUOTED(TTY_GROUP_NAME,"$cf_tty_group",[Define to the name use for tty group]) # This is only a double-check that the group-name we obtained above really # does apply to the device. We cannot perform this test if we are in batch @@ -2408,7 +2523,7 @@ fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_TYPE_CC_T version: 1 updated: 2011/12/12 20:54:48 +dnl CF_TYPE_CC_T version: 2 updated: 2012/10/04 20:12:20 dnl ------------ dnl Check for cc_t type, used in termio. AC_DEFUN([CF_TYPE_CC_T], @@ -2429,10 +2544,10 @@ [cf_cv_type_cc_t=no]) ]) AC_MSG_RESULT($cf_cv_type_cc_t) -test $cf_cv_type_cc_t = no && AC_DEFINE(cc_t, unsigned char) +test $cf_cv_type_cc_t = no && AC_DEFINE(cc_t, unsigned char,[Define to cc_t type used in termio]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_TYPE_FD_MASK version: 2 updated: 2008/03/25 20:59:57 +dnl CF_TYPE_FD_MASK version: 3 updated: 2012/10/04 06:57:36 dnl --------------- dnl Check for the declaration of fd_mask, which is like fd_set, associated dnl with select(). The check for fd_set should have pulled in this as well, @@ -2457,11 +2572,11 @@ fi ]) if test x$cf_cv_type_fd_mask = xCSRG_BASED ; then - AC_DEFINE(CSRG_BASED) + AC_DEFINE(CSRG_BASED,1,[Define to 1 if needed for declaring fd_mask()]) fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_TYPE_FD_SET version: 4 updated: 2008/03/25 20:56:03 +dnl CF_TYPE_FD_SET version: 5 updated: 2012/10/04 20:12:20 dnl -------------- dnl Check for the declaration of fd_set. Some platforms declare it in dnl , and some in , which requires . @@ -2492,7 +2607,7 @@ [cf_cv_type_fd_set=sys/select.h], [cf_cv_type_fd_set=unknown])])])]) if test $cf_cv_type_fd_set = sys/select.h ; then - AC_DEFINE(USE_SYS_SELECT_H) + AC_DEFINE(USE_SYS_SELECT_H,1,[Define to 1 to include sys/select.h to declare fd_set]) fi ]) dnl --------------------------------------------------------------------------- @@ -2518,7 +2633,7 @@ $1=`echo "$2" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTEMPTER version: 3 updated: 2010/06/02 05:03:05 +dnl CF_UTEMPTER version: 4 updated: 2012/10/04 20:12:20 dnl ----------- dnl Try to link with utempter library AC_DEFUN([CF_UTEMPTER], @@ -2537,12 +2652,12 @@ LIBS="$cf_save_LIBS" ]) if test "$cf_cv_have_utempter" = yes ; then - AC_DEFINE(USE_UTEMPTER) + AC_DEFINE(USE_UTEMPTER,1,[Define to 1 if we can/should link with utempter]) CF_ADD_LIB(utempter) fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTMP version: 9 updated: 2008/01/25 17:18:00 +dnl CF_UTMP version: 10 updated: 2012/10/04 20:12:20 dnl ------- dnl Check for UTMP/UTMPX headers AC_DEFUN([CF_UTMP], @@ -2578,8 +2693,8 @@ ]) if test $cf_cv_have_utmp != no ; then - AC_DEFINE(HAVE_UTMP) - test $cf_cv_have_utmp = utmpx && AC_DEFINE(UTMPX_FOR_UTMP) + AC_DEFINE(HAVE_UTMP,1,[Define to 1 if the utmp interface is available]) + test $cf_cv_have_utmp = utmpx && AC_DEFINE(UTMPX_FOR_UTMP,1,[Define if we have utmpx interface]) CF_UTMP_UT_HOST CF_UTMP_UT_SYSLEN CF_UTMP_UT_NAME @@ -2638,7 +2753,7 @@ fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTMP_UT_HOST version: 7 updated: 2007/03/13 19:17:11 +dnl CF_UTMP_UT_HOST version: 8 updated: 2012/10/04 20:12:20 dnl --------------- dnl Check if UTMP/UTMPX struct defines ut_host member AC_DEFUN([CF_UTMP_UT_HOST], @@ -2654,11 +2769,11 @@ [cf_cv_have_utmp_ut_host=no]) ]) AC_MSG_RESULT($cf_cv_have_utmp_ut_host) -test $cf_cv_have_utmp_ut_host != no && AC_DEFINE(HAVE_UTMP_UT_HOST) +test $cf_cv_have_utmp_ut_host != no && AC_DEFINE(HAVE_UTMP_UT_HOST,1,[Define to 1 if UTMP/UTMPX struct defines ut_host member]) fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTMP_UT_NAME version: 4 updated: 2007/03/13 19:17:11 +dnl CF_UTMP_UT_NAME version: 5 updated: 2012/10/04 20:12:20 dnl --------------- dnl Check if UTMP/UTMPX struct defines ut_name member AC_DEFUN([CF_UTMP_UT_NAME], @@ -2689,13 +2804,13 @@ AC_MSG_ERROR(Cannot find declaration for ut.ut_name) ;; ut_user) - AC_DEFINE(ut_name,ut_user) + AC_DEFINE(ut_name,ut_user,[Define to rename UTMP/UTMPX struct ut_name member]) ;; esac fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTMP_UT_SESSION version: 5 updated: 2007/03/13 19:17:11 +dnl CF_UTMP_UT_SESSION version: 6 updated: 2012/10/04 20:12:20 dnl ------------------ dnl Check if UTMP/UTMPX struct defines ut_session member AC_DEFUN([CF_UTMP_UT_SESSION], @@ -2710,12 +2825,12 @@ [cf_cv_have_utmp_ut_session=no]) ]) if test $cf_cv_have_utmp_ut_session != no ; then - AC_DEFINE(HAVE_UTMP_UT_SESSION) + AC_DEFINE(HAVE_UTMP_UT_SESSION,1,[Define to 1 if UTMP/UTMPX struct defines ut_session member]) fi fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTMP_UT_SYSLEN version: 1 updated: 2008/01/25 17:18:00 +dnl CF_UTMP_UT_SYSLEN version: 2 updated: 2012/10/04 20:12:20 dnl ----------------- dnl Check if UTMP/UTMPX struct defines ut_syslen member AC_DEFUN([CF_UTMP_UT_SYSLEN], @@ -2731,11 +2846,11 @@ [cf_cv_have_utmp_ut_syslen=no]) ]) AC_MSG_RESULT($cf_cv_have_utmp_ut_syslen) -test $cf_cv_have_utmp_ut_syslen != no && AC_DEFINE(HAVE_UTMP_UT_SYSLEN) +test $cf_cv_have_utmp_ut_syslen != no && AC_DEFINE(HAVE_UTMP_UT_SYSLEN,1,[Define to 1 if UTMP/UTMPX struct defines ut_syslen member]) fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTMP_UT_XSTATUS version: 3 updated: 2001/12/27 12:55:07 +dnl CF_UTMP_UT_XSTATUS version: 4 updated: 2012/10/04 20:12:20 dnl ------------------ dnl Check for known variants on the UTMP/UTMPX struct's exit-status as reported dnl by various people: @@ -2767,13 +2882,13 @@ done ]) if test $cf_cv_have_utmp_ut_xstatus != no ; then - AC_DEFINE(HAVE_UTMP_UT_XSTATUS) - AC_DEFINE_UNQUOTED(ut_xstatus,$cf_cv_have_utmp_ut_xstatus) + AC_DEFINE(HAVE_UTMP_UT_XSTATUS,1,[Define to 1 if UTMP/UTMPX has exit-status member]) + AC_DEFINE_UNQUOTED(ut_xstatus,$cf_cv_have_utmp_ut_xstatus,[Define if needed to rename member ut_xstatus of UTMP/UTMPX]) fi fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTMP_UT_XTIME version: 7 updated: 2007/03/13 19:17:11 +dnl CF_UTMP_UT_XTIME version: 9 updated: 2012/10/04 20:12:20 dnl ---------------- dnl Check if UTMP/UTMPX struct defines ut_xtime member AC_DEFUN([CF_UTMP_UT_XTIME], @@ -2794,9 +2909,9 @@ ]) ]) if test $cf_cv_have_utmp_ut_xtime != no ; then - AC_DEFINE(HAVE_UTMP_UT_XTIME) + AC_DEFINE(HAVE_UTMP_UT_XTIME,1,[Define to 1 if UTMP/UTMPX struct defines ut_xtime member]) if test $cf_cv_have_utmp_ut_xtime = define ; then - AC_DEFINE(ut_xtime,ut_tv.tv_sec) + AC_DEFINE(ut_xtime,ut_tv.tv_sec,[Define if needed to alternate name for utmpx.ut_xtime member]) fi fi fi @@ -2810,13 +2925,13 @@ CF_MSG_LOG([$1]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_APP_CLASS version: 1 updated: 2011/07/08 04:54:40 +dnl CF_WITH_APP_CLASS version: 2 updated: 2012/10/04 04:29:52 dnl ----------------- dnl Handle configure option "--with-app-class", setting the $APP_CLASS dnl variable, used for X resources. dnl dnl $1 = default value. -AC_DEFUN(CF_WITH_APP_CLASS,[ +AC_DEFUN([CF_WITH_APP_CLASS],[ AC_MSG_CHECKING(for X applications class) AC_ARG_WITH(app-class, [ --with-app-class=XXX override X applications class (default $1)], @@ -2841,27 +2956,104 @@ AC_SUBST(APP_CLASS) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_APP_DEFAULTS version: 1 updated: 2011/04/21 18:12:37 +dnl CF_WITH_APP_DEFAULTS version: 5 updated: 2012/10/04 04:29:52 dnl -------------------- dnl Handle configure option "--with-app-defaults", setting these shell dnl variables: -dnl $appsdir is the option value, used for installing app-defaults files. +dnl +dnl $APPSDIR is the option value, used for installing app-defaults files. dnl $no_appsdir is a "#" (comment) if "--without-app-defaults" is given. -AC_DEFUN(CF_WITH_APP_DEFAULTS,[ +dnl +dnl Most Linux's use this: +dnl /usr/share/X11/app-defaults +dnl Debian uses this: +dnl /etc/X11/app-defaults +dnl DragonFlyBSD ports uses this: +dnl /usr/pkg/lib/X11/app-defaults +dnl FreeBSD ports use these: +dnl /usr/local/lib/X11/app-defaults +dnl /usr/local/share/X11/app-defaults +dnl Mandriva has these: +dnl /usr/lib/X11/app-defaults +dnl /usr/lib64/X11/app-defaults +dnl NetBSD has these +dnl /usr/X11R7/lib/X11/app-defaults +dnl OpenSolaris uses +dnl 32-bit: +dnl /usr/X11/etc/X11/app-defaults +dnl /usr/X11/share/X11/app-defaults +dnl /usr/X11/lib/X11/app-defaults +dnl 64-bit: +dnl /usr/X11/etc/X11/app-defaults +dnl /usr/X11/share/X11/app-defaults (I mkdir'd this) +dnl /usr/X11/lib/amd64/X11/app-defaults +dnl Solaris10 uses (in this order): +dnl /usr/openwin/lib/X11/app-defaults +dnl /usr/X11/lib/X11/app-defaults +AC_DEFUN([CF_WITH_APP_DEFAULTS],[ AC_MSG_CHECKING(for directory to install resource files) -CF_WITH_PATH(app-defaults, - [ --with-app-defaults=DIR directory in which to install resource files], - [appsdir],[EPREFIX/lib/X11/app-defaults], - ['\$(exec_prefix)/lib/X11/app-defaults']) -AC_MSG_RESULT($appsdir) -AC_SUBST(appsdir) +AC_ARG_WITH(app-defaults, + [ --with-app-defaults=DIR directory in which to install resource files (EPREFIX/lib/X11/app-defaults)], + [APPSDIR=$withval], + [APPSDIR='${exec_prefix}/lib/X11/app-defaults']) + +if test "x[$]APPSDIR" = xauto +then + APPSDIR='${exec_prefix}/lib/X11/app-defaults' + for cf_path in \ + /usr/share/X11/app-defaults \ + /usr/X11/share/X11/app-defaults \ + /usr/X11/lib/X11/app-defaults \ + /usr/lib/X11/app-defaults \ + /etc/X11/app-defaults \ + /usr/pkg/lib/X11/app-defaults \ + /usr/X11R7/lib/X11/app-defaults \ + /usr/X11R6/lib/X11/app-defaults \ + /usr/X11R5/lib/X11/app-defaults \ + /usr/X11R4/lib/X11/app-defaults \ + /usr/local/lib/X11/app-defaults \ + /usr/local/share/X11/app-defaults \ + /usr/lib64/X11/app-defaults + do + if test -d "$cf_path" ; then + APPSDIR="$cf_path" + break + fi + done +else + cf_path=$APPSDIR + CF_PATH_SYNTAX(cf_path) +fi + +AC_MSG_RESULT($APPSDIR) +AC_SUBST(APPSDIR) no_appsdir= -test "$appsdir" = no && no_appsdir="#" +if test "$APPSDIR" = no +then + no_appsdir="#" +else + EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(APPSDIR)" +fi AC_SUBST(no_appsdir) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_DESKTOP_CATEGORY version: 2 updated: 2011/07/02 10:22:07 +dnl CF_WITH_DBMALLOC version: 7 updated: 2010/06/21 17:26:47 +dnl ---------------- +dnl Configure-option for dbmalloc. The optional parameter is used to override +dnl the updating of $LIBS, e.g., to avoid conflict with subsequent tests. +AC_DEFUN([CF_WITH_DBMALLOC],[ +CF_NO_LEAKS_OPTION(dbmalloc, + [ --with-dbmalloc test: use Conor Cahill's dbmalloc library], + [USE_DBMALLOC]) + +if test "$with_dbmalloc" = yes ; then + AC_CHECK_HEADER(dbmalloc.h, + [AC_CHECK_LIB(dbmalloc,[debug_malloc]ifelse([$1],,[],[,$1]))]) +fi +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_WITH_DESKTOP_CATEGORY version: 4 updated: 2013/01/01 10:50:14 dnl ------------------------ dnl Taking into account the absence of standardization of desktop categories dnl take a look to see whether other applications on the current system are @@ -2871,7 +3063,9 @@ dnl $2 = case-pattern to match comparable desktop files to obtain category dnl This pattern may contain wildcards. dnl $3 = suggested categories, also a case-pattern but without wildcards, -dnl since it doubles as a default value. +dnl since it doubles as a default value for a shell case-statement. +dnl $4 = categories to use if no match is found on the build-machine for the +dnl --with-desktop-category "auto" setting. dnl dnl The macro tells the configure script to substitute the $DESKTOP_CATEGORY dnl value. @@ -2933,33 +3127,292 @@ done cf_desktop_want=`cat conftest.2 | tr '\n' ';'` fi + if test -n "$cf_desktop_want" + then + if test "$cf_desktop_want" = auto + then + cf_desktop_want= + else + # do a sanity check on the semicolon-separated list, ignore on failure + cf_desktop_test=`echo "$cf_desktop_want" | sed -e 's/[[^;]]//g'` + test -z "$cf_desktop_test" && cf_desktop_want= + cf_desktop_test=`echo "$cf_desktop_want" | sed -e 's/^.*;$/./g'` + test -z "$cf_desktop_test" && cf_desktop_want= + fi + fi + if test -z "$cf_desktop_want" + then + cf_desktop_want="ifelse([$4],,ifelse([$3],,[Application;],[`echo "$3" | sed -e 's/\*//g' -e 's/|/;/g' -e 's/[[;]]*$/;/g'`]),[$4])" + CF_VERBOSE(no usable value found for desktop category, using $cf_desktop_want) + fi fi DESKTOP_CATEGORY=`echo "$cf_desktop_want" | sed -e 's/[[ ,]]/;/g'` - CF_VERBOSE(resulting category=$DESKTOP_CATEGORY) + CF_VERBOSE(will use Categories=$DESKTOP_CATEGORY) AC_SUBST(DESKTOP_CATEGORY) fi ]) dnl --------------------------------------------------------------------------- -dnl CF_WITH_ICONDIR version: 1 updated: 2011/04/21 18:12:37 +dnl CF_WITH_DMALLOC version: 7 updated: 2010/06/21 17:26:47 dnl --------------- -dnl Handle configure option "--with-icondir", setting these shell -dnl variables: -dnl $icondir is the option value, used for installing icon/pixmap files. +dnl Configure-option for dmalloc. The optional parameter is used to override +dnl the updating of $LIBS, e.g., to avoid conflict with subsequent tests. +AC_DEFUN([CF_WITH_DMALLOC],[ +CF_NO_LEAKS_OPTION(dmalloc, + [ --with-dmalloc test: use Gray Watson's dmalloc library], + [USE_DMALLOC]) + +if test "$with_dmalloc" = yes ; then + AC_CHECK_HEADER(dmalloc.h, + [AC_CHECK_LIB(dmalloc,[dmalloc_debug]ifelse([$1],,[],[,$1]))]) +fi +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_WITH_ICONDIR version: 5 updated: 2012/07/22 09:18:02 +dnl --------------- +dnl Handle configure option "--with-icondir", setting these shell variables: +dnl +dnl $ICONDIR is the option value, used for installing icon files. dnl $no_icondir is a "#" (comment) if "--without-icondir" is given. AC_DEFUN([CF_WITH_ICONDIR],[ AC_MSG_CHECKING(for directory to install icons) -CF_WITH_PATH(icondir, - [ --with-icondir=DIR directory in which to install icons], - [icondir],[EPREFIX/share/pixmaps], - ['\$(exec_prefix)/share/pixmaps']) -AC_MSG_RESULT($icondir) -AC_SUBST(icondir) +AC_ARG_WITH(icondir, + [ --with-icondir=DIR directory in which to install icons for desktop], + [ICONDIR=$withval], + [test -z "$ICONDIR" && ICONDIR=no]) + +if test "x[$]ICONDIR" = xauto +then + ICONDIR='${datadir}/icons' + for cf_path in \ + /usr/share/icons \ + /usr/X11R6/share/icons + do + if test -d "$cf_path" ; then + ICONDIR="$cf_path" + break + fi + done +else + cf_path=$ICONDIR + CF_PATH_SYNTAX(cf_path) +fi +AC_MSG_RESULT($ICONDIR) +AC_SUBST(ICONDIR) no_icondir= -test "$icondir" = no && no_icondir="#" +if test "$ICONDIR" = no +then + no_icondir="#" +else + EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(ICONDIR)" +fi AC_SUBST(no_icondir) ])dnl dnl --------------------------------------------------------------------------- +dnl CF_WITH_ICON_NAME version: 2 updated: 2013/05/27 18:34:42 +dnl ----------------- +dnl Allow a default icon-name to be overridden. +dnl $1 = default icon name +AC_DEFUN([CF_WITH_ICON_NAME],[ +AC_MSG_CHECKING(for the icon name) +AC_ARG_WITH(icon-name, + [ --with-icon-name=XXXX override icon name (default: $1)], + [ICON_NAME="$withval"], + [ICON_NAME=$1]) +case "x$ICON_NAME" in +xyes|xno|x) + ICON_NAME=$1 + ;; +esac +AC_SUBST(ICON_NAME) +AC_MSG_RESULT($ICON_NAME) +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_WITH_ICON_SYMLINK version: 1 updated: 2013/05/27 18:34:42 +dnl -------------------- +dnl Workaround for systems which are (mis)configured to map all icon references +dnl for xterm into "xterm" name. For instance, recent (2013) KDE ignores both +dnl the name given in the .desktop file (xterm-color) and the application name +dnl (xterm-dev). +dnl +dnl $1 = default icon name to use if symlink is wanted +AC_DEFUN([CF_WITH_ICON_SYMLINK],[ +AC_MSG_CHECKING(for icon symlink to use) +AC_ARG_WITH(icon-symlink, + [ --with-icon-symlink=XXX make symbolic link for icon name (default: $1)], + [ICON_SYMLINK="$withval"], + [ICON_SYMLINK=NONE]) +case "x$ICON_SYMLINK" in +xyes) + ICON_SYMLINK=$1 + ;; +xno|x) + ICON_SYMLINK=NONE + ;; +esac +AC_SUBST(ICON_SYMLINK) +AC_MSG_RESULT($ICON_SYMLINK) +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_WITH_ICON_THEME version: 9 updated: 2013/04/17 05:31:24 +dnl ------------------ +dnl If asked, check for prerequisites and setup symbols to permit installing +dnl one or more application icons in the Red Hat icon-theme directory +dnl hierarchy. +dnl +dnl If the prerequisites are missing, give a warning and revert to the long- +dnl standing pixmaps directory. +dnl +dnl Parameters: +dnl +dnl $1 = application icon. This can be a list, and is not optional. +dnl $2 = default theme (defaults to hicolor) +dnl $3 = formats (defaults to list [.svg .png .xpm]) +dnl $4 = alternate icon if no theme is used (defaults to $1). +dnl +dnl Result: +dnl ICON_NAME = basename of first item in $1 +dnl ICON_LIST = reprocessed $1 +dnl ICON_THEME = reprocessed $2 +dnl ICON_FORMAT = reprocessed $3 +AC_DEFUN([CF_WITH_ICON_THEME], +[ +ifelse([$1],,[ + AC_MSG_ERROR([macro [CF_WITH_ICON_THEME] requires application-icon name]) +],[ + +CF_WITH_PIXMAPDIR +CF_WITH_ICONDIR + +AC_MSG_CHECKING(if icon theme should be used) +AC_ARG_WITH(icon-theme, + [ --with-icon-theme=XXX install icons into desktop theme (hicolor)], + [ICON_THEME=$withval], + [ICON_THEME=no]) + +case "x$ICON_THEME" in #(vi +xno) #(vi + ;; +x|xyes) + ICON_THEME=ifelse([$2],,hicolor,$2) + ;; +esac +AC_MSG_RESULT($ICON_THEME) + +if test "x$ICON_THEME" = xno +then + if test "x$ICONDIR" != xno + then + CF_VERBOSE(ignoring icondir without theme) + no_icondir="#" + fi +else + if test "x$ICONDIR" = xno + then + AC_MSG_ERROR(icondir must be set for icon theme) + fi +fi + +: ${ICON_FORMAT:=ifelse([$3],,[".svg .png .xpm"],[$3])} + +# ICON_NAME= +ICON_LIST= + +ifelse([$4],,[cf_icon_list=$1],[ +if test "x$ICON_THEME" != xno +then + cf_icon_list="$1" +else + cf_icon_list="$4" +fi +]) + +AC_MSG_CHECKING([for icon(s) to install]) +for cf_name in $cf_icon_list +do + CF_VERBOSE(using $ICON_FORMAT) + for cf_suffix in $ICON_FORMAT + do + cf_icon="${cf_name}${cf_suffix}" + cf_left=`echo "$cf_icon" | sed -e 's/:.*//'` + if test ! -f "${cf_left}" + then + if test "x$srcdir" != "x." + then + cf_icon="${srcdir}/${cf_left}" + cf_left=`echo "$cf_icon" | sed -e 's/:.*//'` + if test ! -f "${cf_left}" + then + continue + fi + else + continue + fi + fi + if test "x$ICON_THEME" != xno + then + cf_base=`basename $cf_left` + cf_trim=`echo "$cf_base" | sed -e 's/_[[0-9]][[0-9]]x[[0-9]][[0-9]]\././'` + case "x${cf_base}" in #(vi + *:*) #(vi + cf_next=$cf_base + # user-defined mapping + ;; + *.png) #(vi + cf_size=`file "$cf_left"|sed -e 's/^[[^:]]*://' -e 's/^.*[[^0-9]]\([[0-9]][[0-9]]* x [[0-9]][[0-9]]*\)[[^0-9]].*$/\1/' -e 's/ //g'` + if test -z "$cf_size" + then + AC_MSG_WARN(cannot determine size of $cf_left) + continue + fi + cf_next="$cf_size/apps/$cf_trim" + ;; + *.svg) #(vi + cf_next="scalable/apps/$cf_trim" + ;; + *.xpm) + CF_VERBOSE(ignored XPM file in icon theme) + continue + ;; + *_[[0-9]][[0-9]]*x[[0-9]][[0-9]]*.*) #(vi + cf_size=`echo "$cf_left"|sed -e 's/^.*_\([[0-9]][[0-9]]*x[[0-9]][[0-9]]*\)\..*$/\1/'` + cf_left=`echo "$cf_left"|sed -e 's/^\(.*\)_\([[0-9]][[0-9]]*x[[0-9]][[0-9]]*\)\(\..*\)$/\1\3/'` + cf_next="$cf_size/apps/$cf_base" + ;; + esac + CF_VERBOSE(adding $cf_next) + cf_icon="${cf_icon}:${cf_next}" + fi + test -n "$ICON_LIST" && ICON_LIST="$ICON_LIST " + ICON_LIST="$ICON_LIST${cf_icon}" + if test -z "$ICON_NAME" + then + ICON_NAME=`basename $cf_icon | sed -e 's/[[.:]].*//'` + fi + done +done + +if test -n "$verbose" +then + AC_MSG_CHECKING(result) +fi +AC_MSG_RESULT($ICON_LIST) + +if test -z "$ICON_LIST" +then + AC_MSG_ERROR(no icons found) +fi +]) + +AC_MSG_CHECKING(for icon name) +AC_MSG_RESULT($ICON_NAME) + +AC_SUBST(ICON_FORMAT) +AC_SUBST(ICON_THEME) +AC_SUBST(ICON_LIST) +AC_SUBST(ICON_NAME) +])dnl +dnl --------------------------------------------------------------------------- dnl CF_WITH_IMAKE_CFLAGS version: 9 updated: 2010/05/26 05:38:42 dnl -------------------- dnl xterm and similar programs build more readily when propped up with imake's @@ -3036,28 +3489,7 @@ fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_PATH version: 10 updated: 2010/10/23 15:44:18 -dnl ------------ -dnl Wrapper for AC_ARG_WITH to ensure that user supplies a pathname, not just -dnl defaulting to yes/no. -dnl -dnl $1 = option name -dnl $2 = help-text -dnl $3 = environment variable to set -dnl $4 = default value, shown in the help-message, must be a constant -dnl $5 = default value, if it's an expression & cannot be in the help-message -dnl -AC_DEFUN([CF_WITH_PATH], -[AC_ARG_WITH($1,[$2 ](default: ifelse([$4],,empty,[$4])),, -ifelse([$4],,[withval="${$3}"],[withval="${$3:-ifelse([$5],,[$4],[$5])}"]))dnl -if ifelse([$5],,true,[test -n "$5"]) ; then -CF_PATH_SYNTAX(withval) -fi -$3="$withval" -AC_SUBST($3)dnl -])dnl -dnl --------------------------------------------------------------------------- -dnl CF_WITH_PCRE version: 8 updated: 2010/06/05 11:30:21 +dnl CF_WITH_PCRE version: 10 updated: 2012/10/04 20:12:20 dnl ------------ dnl Add PCRE (Perl-compatible regular expressions) to the build if it is dnl available and the user requests it. Assume the application will otherwise @@ -3079,17 +3511,17 @@ AC_CHECK_LIB(pcre,pcre_compile,, AC_MSG_ERROR(Cannot find PCRE library))]) - AC_DEFINE(HAVE_LIB_PCRE) + AC_DEFINE(HAVE_LIB_PCRE,1,[Define to 1 if we can/should compile with the PCRE library]) case $LIBS in #(vi *pcreposix*) #(vi ;; *) AC_CHECK_LIB(pcreposix,pcreposix_regcomp, - [AC_DEFINE(HAVE_PCREPOSIX_H) + [AC_DEFINE(HAVE_PCREPOSIX_H,1,[Define to 1 if we should include pcreposix.h]) CF_ADD_LIB(pcreposix)], [AC_CHECK_LIB(pcreposix,regcomp,[ - AC_DEFINE(HAVE_PCREPOSIX_H) + AC_DEFINE(HAVE_PCREPOSIX_H,1,[Define to 1 if we should include pcreposix.h]) CF_ADD_LIB(pcreposix)], AC_MSG_ERROR(Cannot find PCRE POSIX library)])) ;; @@ -3097,7 +3529,122 @@ fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_XKB_BELL_EXT version: 3 updated: 2009/02/13 16:00:39 +dnl CF_WITH_PIXMAPDIR version: 3 updated: 2012/07/22 09:18:02 +dnl ----------------- +dnl Handle configure option "--with-pixmapdir", setting these shell variables: +dnl +dnl $PIXMAPDIR is the option value, used for installing pixmap files. +dnl $no_pixmapdir is a "#" (comment) if "--without-pixmapdir" is given. +AC_DEFUN([CF_WITH_PIXMAPDIR],[ +AC_MSG_CHECKING(for directory to install pixmaps) +AC_ARG_WITH(pixmapdir, + [ --with-pixmapdir=DIR directory in which to install pixmaps (DATADIR/pixmaps)], + [PIXMAPDIR=$withval], + [test -z "$PIXMAPDIR" && PIXMAPDIR='${datadir}/pixmaps']) + +if test "x[$]PIXMAPDIR" = xauto +then + PIXMAPDIR='${datadir}/pixmaps' + for cf_path in \ + /usr/share/pixmaps \ + /usr/X11R6/share/pixmaps + do + if test -d "$cf_path" ; then + PIXMAPDIR="$cf_path" + break + fi + done +else + cf_path=$PIXMAPDIR + CF_PATH_SYNTAX(cf_path) +fi +AC_MSG_RESULT($PIXMAPDIR) +AC_SUBST(PIXMAPDIR) + +no_pixmapdir= +if test "$PIXMAPDIR" = no +then + no_pixmapdir="#" +else + EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(PIXMAPDIR)" +fi +AC_SUBST(no_pixmapdir) +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_WITH_VALGRIND version: 1 updated: 2006/12/14 18:00:21 +dnl ---------------- +AC_DEFUN([CF_WITH_VALGRIND],[ +CF_NO_LEAKS_OPTION(valgrind, + [ --with-valgrind test: use valgrind], + [USE_VALGRIND]) +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_WITH_XPM version: 3 updated: 2012/10/04 06:57:36 +dnl ----------- +dnl Test for Xpm library, update compiler/loader flags if it is wanted and +dnl found. +dnl +dnl Also sets ICON_SUFFIX +AC_DEFUN([CF_WITH_XPM], +[ +ICON_SUFFIX=.xbm + +cf_save_cppflags="${CPPFLAGS}" +cf_save_ldflags="${LDFLAGS}" + +AC_MSG_CHECKING(if you want to use the Xpm library for colored icon) +AC_ARG_WITH(xpm, +[ --with-xpm=DIR use Xpm library for colored icon, may specify path], + [cf_Xpm_library="$withval"], + [cf_Xpm_library=yes]) +AC_MSG_RESULT($cf_Xpm_library) + +if test "$cf_Xpm_library" != no ; then + if test "$cf_Xpm_library" != yes ; then + CPPFLAGS="$CPPFLAGS -I$withval/include" + LDFLAGS="$LDFLAGS -L$withval/lib" + fi + AC_CHECK_HEADER(X11/xpm.h,[ + AC_CHECK_LIB(Xpm, XpmCreatePixmapFromData,[ + AC_DEFINE(HAVE_LIBXPM,1,[Define to 1 if we should use Xpm library]) + ICON_SUFFIX=.xpm + LIBS="-lXpm $LIBS"], + [CPPFLAGS="${cf_save_cppflags}" LDFLAGS="${cf_save_ldflags}"], + [-lX11 $X_LIBS])], + [CPPFLAGS="${cf_save_cppflags}" LDFLAGS="${cf_save_ldflags}"]) +fi + +AC_SUBST(ICON_SUFFIX) +])dnl +dnl --------------------------------------------------------------------------- +dnl CF_XBOOL_RESULT version: 2 updated: 2012/10/04 06:57:36 +dnl --------------- +dnl Translate an autoconf boolean yes/no into X11's booleans, e.g., True/False. +dnl Allow for more than two values, e.g., "maybe", still using the same leading +dnl capital convention. +dnl +dnl $1 = symbol to define +dnl $2 = symbol holding value +dnl $3 = description +define([CF_XBOOL_RESULT],[ +AC_MSG_RESULT([$]$2) +case [$]$2 in #(vi +yes) #(vi + $2=true + ;; +no) #(vi + $2=false + ;; +esac +cf_xbool1=`echo "[$]$2"|sed -e 's/^\(.\).*/\1/'` +CF_UPPER(cf_xbool1,$cf_xbool1) +cf_xbool2=`echo "[$]$2"|sed -e 's/^.//'` +$2=${cf_xbool1}${cf_xbool2} +AC_DEFINE_UNQUOTED($1,[$]$2,$3) +AC_SUBST($2) +]) +dnl --------------------------------------------------------------------------- +dnl CF_XKB_BELL_EXT version: 4 updated: 2012/10/04 20:12:20 dnl --------------- dnl Check for XKB bell extension AC_DEFUN([CF_XKB_BELL_EXT],[ @@ -3112,10 +3659,69 @@ XkbBell((Display *)0, (Widget)0, 0, y); ],[cf_cv_xkb_bell_ext=yes],[cf_cv_xkb_bell_ext=no]) ]) -test "$cf_cv_xkb_bell_ext" = yes && AC_DEFINE(HAVE_XKB_BELL_EXT) +test "$cf_cv_xkb_bell_ext" = yes && AC_DEFINE(HAVE_XKB_BELL_EXT,1,[Define 1 if we have XKB Bell extension]) +]) +dnl --------------------------------------------------------------------------- +dnl CF_XKB_KEYCODE_TO_KEYSYM version: 2 updated: 2012/09/28 20:23:33 +dnl ------------------------ +dnl Some older vendor-unix systems made a practice of delivering fragments of +dnl Xkb, requiring test-compiles. +AC_DEFUN([CF_XKB_KEYCODE_TO_KEYSYM],[ +AC_CACHE_CHECK(if we can use XkbKeycodeToKeysym, cf_cv_xkb_keycode_to_keysym,[ +AC_TRY_COMPILE([ +#include +#include +],[ + KeySym keysym = XkbKeycodeToKeysym((Display *)0, 0, 0, 0); +],[ +cf_cv_xkb_keycode_to_keysym=yes +],[ +cf_cv_xkb_keycode_to_keysym=no +]) +]) + +if test $cf_cv_xkb_keycode_to_keysym = yes +then + AC_CHECK_FUNCS(XkbKeycodeToKeysym) +fi ]) dnl --------------------------------------------------------------------------- -dnl CF_XOPEN_SOURCE version: 42 updated: 2012/01/07 08:26:49 +dnl CF_XKB_QUERY_EXTENSION version: 2 updated: 2012/09/28 20:23:46 +dnl ---------------------- +dnl see ifdef in scrollbar.c - iron out here +AC_DEFUN([CF_XKB_QUERY_EXTENSION],[ +AC_CACHE_CHECK(if we can use XkbQueryExtension, cf_cv_xkb_query_extension,[ +AC_TRY_COMPILE([ +#include +#include +#include +],[ + int xkbmajor = XkbMajorVersion; + int xkbminor = XkbMinorVersion; + int xkbopcode, xkbevent, xkberror; + + if (XkbLibraryVersion(&xkbmajor, &xkbminor) + && XkbQueryExtension((Display *)0, + &xkbopcode, + &xkbevent, + &xkberror, + &xkbmajor, + &xkbminor)) + return 0; +],[ +cf_cv_xkb_query_extension=yes +],[ +cf_cv_xkb_query_extension=no +]) +]) + +if test $cf_cv_xkb_query_extension = yes +then + AC_CHECK_FUNCS(XkbQueryExtension) +fi +]) +dnl --------------------------------------------------------------------------- +dnl CF_XOPEN_SOURCE version: 43 updated: 2013/02/10 10:41:05 dnl --------------- dnl Try to get _XOPEN_SOURCE defined properly that we can use POSIX functions, dnl or adapt to the vendor's definitions to get equivalent functionality, @@ -3125,6 +3731,7 @@ dnl $1 is the nominal value for _XOPEN_SOURCE dnl $2 is the nominal value for _POSIX_C_SOURCE AC_DEFUN([CF_XOPEN_SOURCE],[ +AC_REQUIRE([AC_CANONICAL_HOST]) cf_XOPEN_SOURCE=ifelse([$1],,500,[$1]) cf_POSIX_C_SOURCE=ifelse([$2],,199506L,[$2]) @@ -3233,7 +3840,7 @@ fi ]) dnl --------------------------------------------------------------------------- -dnl CF_X_ATHENA version: 20 updated: 2010/11/09 05:18:02 +dnl CF_X_ATHENA version: 21 updated: 2013/07/06 21:27:06 dnl ----------- dnl Check for Xaw (Athena) libraries dnl @@ -3292,6 +3899,8 @@ CF_UPPER(cf_x_athena_LIBS,HAVE_LIB_$cf_x_athena) AC_DEFINE_UNQUOTED($cf_x_athena_LIBS) + CF_TRIM_X_LIBS + AC_CACHE_CHECK(for usable $cf_x_athena/Xmu package,cf_cv_xaw_compat,[ AC_TRY_LINK([ #include @@ -3307,7 +3916,15 @@ ;; *) CF_VERBOSE(work around broken package) - CF_TRY_PKG_CONFIG(xmu,,[CF_ADD_LIB_AFTER(-lXt,-lXmu)]) + cf_save_xmu="$LIBS" + cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^[ ][ ]*//' -e 's/ .*//'` + CF_TRY_PKG_CONFIG(xmu,[ + LIBS="$cf_save_xmu" + CF_ADD_LIB_AFTER($cf_first_lib,$cf_pkgconfig_libs) + ],[ + CF_ADD_LIB_AFTER($cf_first_lib,-lXmu) + ]) + CF_TRIM_X_LIBS ;; esac fi @@ -3442,7 +4059,7 @@ [CF_ADD_LIB(Xext)])]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_X_FONTCONFIG version: 4 updated: 2011/07/04 10:01:31 +dnl CF_X_FONTCONFIG version: 5 updated: 2013/07/06 21:27:06 dnl --------------- dnl Check for fontconfig library, a dependency of the X FreeType library. AC_DEFUN([CF_X_FONTCONFIG], @@ -3469,14 +4086,21 @@ ;; *) CF_VERBOSE(work around broken package) - CF_TRY_PKG_CONFIG(fontconfig,,[CF_ADD_LIB_AFTER(-lXft,-lfontconfig)]) + cf_save_fontconfig="$LIBS" + CF_TRY_PKG_CONFIG(fontconfig,[ + CF_ADD_CFLAGS($cf_pkgconfig_incs) + LIBS="$cf_save_fontconfig" + CF_ADD_LIB_AFTER(-lXft,$cf_pkgconfig_libs) + ],[ + CF_ADD_LIB_AFTER(-lXft,-lfontconfig) + ]) ;; esac fi fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_X_FREETYPE version: 24 updated: 2011/08/29 05:46:02 +dnl CF_X_FREETYPE version: 26 updated: 2012/10/04 20:12:20 dnl ------------- dnl Check for X FreeType headers and libraries (XFree86 4.x, etc). dnl @@ -3543,7 +4167,7 @@ ;; pkg*) #(vi if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xft; then - FREETYPE_CONFIG=$cf_cv_x_freetype_cfgs + FREETYPE_CONFIG=$cf_cv_x_freetype_cfgs FREETYPE_PARAMS=xft else AC_MSG_WARN(cannot find pkg-config for Xft) @@ -3607,7 +4231,7 @@ if test "$cf_cv_found_freetype" = yes ; then CF_ADD_LIBS($cf_cv_x_freetype_libs) CF_ADD_CFLAGS($cf_cv_x_freetype_incs) - AC_DEFINE(XRENDERFONT) + AC_DEFINE(XRENDERFONT,1,[Define to 1 if we can/should link with FreeType libraries]) AC_CHECK_FUNCS( \ XftDrawCharSpec \ @@ -3625,7 +4249,7 @@ AC_SUBST(HAVE_TYPE_XFTCHARSPEC) ]) dnl --------------------------------------------------------------------------- -dnl CF_X_TOOLKIT version: 20 updated: 2010/11/19 05:43:04 +dnl CF_X_TOOLKIT version: 21 updated: 2012/10/04 06:57:36 dnl ------------ dnl Check for X Toolkit libraries dnl @@ -3699,7 +4323,7 @@ AC_CHECK_FUNC(XtAppInitialize,,[ AC_CHECK_LIB(Xt, XtAppInitialize, - [AC_DEFINE(HAVE_LIBXT) + [AC_DEFINE(HAVE_LIBXT,1,[Define to 1 if we can compile with the Xt library]) cf_have_X_LIBS=Xt LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"],, [$X_PRE_LIBS $LIBS $X_EXTRA_LIBS])]) @@ -3712,3 +4336,99 @@ to makefile.]) fi ])dnl +dnl --------------------------------------------------------------------------- +dnl CF__GRANTPT_BODY version: 4 updated: 2012/05/07 19:39:45 +dnl ---------------- +dnl Body for workability check of grantpt. +define([CF__GRANTPT_BODY],[ + int code = 0; + int rc; + int pty; + int tty; + char *slave; + struct termios tio; + + signal(SIGALRM, my_timeout); + + if (alarm(2) == 9) + failed(9); + else if ((pty = posix_openpt(O_RDWR)) < 0) + failed(1); + else if ((rc = grantpt(pty)) < 0) + failed(2); + else if ((rc = unlockpt(pty)) < 0) + failed(3); + else if ((slave = ptsname(pty)) == 0) + failed(4); +#if (CONFTEST == 3) || defined(CONFTEST_isatty) + else if (!isatty(pty)) + failed(4); +#endif +#if CONFTEST >= 4 + else if ((rc = tcgetattr(pty, &tio)) < 0) + failed(20); + else if ((rc = tcsetattr(pty, TCSAFLUSH, &tio)) < 0) + failed(21); +#endif + /* BSD posix_openpt does not treat pty as a terminal until slave is opened. + * Linux does treat it that way. + */ + else if ((tty = open(slave, O_RDWR)) < 0) + failed(5); +#ifdef CONFTEST +#ifdef I_PUSH +#if (CONFTEST == 0) || defined(CONFTEST_ptem) + else if ((rc = ioctl(tty, I_PUSH, "ptem")) < 0) + failed(10); +#endif +#if (CONFTEST == 1) || defined(CONFTEST_ldterm) + else if ((rc = ioctl(tty, I_PUSH, "ldterm")) < 0) + failed(11); +#endif +#if (CONFTEST == 2) || defined(CONFTEST_ttcompat) + else if ((rc = ioctl(tty, I_PUSH, "ttcompat")) < 0) + failed(12); +#endif +#endif /* I_PUSH */ +#if CONFTEST >= 5 + else if ((rc = tcgetattr(tty, &tio)) < 0) + failed(30); + else if ((rc = tcsetattr(tty, TCSAFLUSH, &tio)) < 0) + failed(31); +#endif +#endif /* CONFTEST */ + + ${cf_cv_main_return:-return}(code); +]) +dnl --------------------------------------------------------------------------- +dnl CF__GRANTPT_HEAD version: 3 updated: 2012/01/29 17:13:14 +dnl ---------------- +dnl Headers for workability check of grantpt. +define([CF__GRANTPT_HEAD],[ +#include +#include +#include +#include +#include +#include + +#ifndef HAVE_POSIX_OPENPT +#undef posix_openpt +#define posix_openpt(mode) open("/dev/ptmx", mode) +#endif + +#ifdef HAVE_STROPTS_H +#include +#endif + +static void failed(int code) +{ + perror("conftest"); + exit(code); +} + +static void my_timeout(int sig) +{ + exit(99); +} +]) diff -Nru xterm-278/button.c xterm-297/button.c --- xterm-278/button.c 2012-01-07 02:00:35.000000000 +0000 +++ xterm-297/button.c 2013-09-10 17:27:38.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: button.c,v 1.430 2012/01/07 02:00:35 tom Exp $ */ +/* $XTermId: button.c,v 1.464 2013/09/10 17:27:38 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -75,7 +75,6 @@ #include #include #include -#include #include #include @@ -148,24 +147,24 @@ static CELL lastButton3; /* At the release time */ #endif /* OPT_READLINE */ -static Char *SaveText(TScreen * screen, int row, int scol, int ecol, - Char * lp, int *eol); -static int Length(TScreen * screen, int row, int scol, int ecol); -static void ComputeSelect(XtermWidget xw, CELL * startc, CELL * endc, Bool extend); +static Char *SaveText(TScreen *screen, int row, int scol, int ecol, + Char *lp, int *eol); +static int Length(TScreen *screen, int row, int scol, int ecol); +static void ComputeSelect(XtermWidget xw, CELL *startc, CELL *endc, Bool extend); static void EditorButton(XtermWidget xw, XButtonEvent * event); -static void EndExtend(XtermWidget w, XEvent * event, String * params, Cardinal +static void EndExtend(XtermWidget w, XEvent * event, String *params, Cardinal num_params, Bool use_cursor_loc); -static void ExtendExtend(XtermWidget xw, const CELL * cell); -static void PointToCELL(TScreen * screen, int y, int x, CELL * cell); -static void ReHiliteText(XtermWidget xw, CELL * first, CELL * last); -static void SaltTextAway(XtermWidget xw, CELL * cellc, CELL * cell); -static void SelectSet(XtermWidget xw, XEvent * event, String * params, Cardinal num_params); +static void ExtendExtend(XtermWidget xw, const CELL *cell); +static void PointToCELL(TScreen *screen, int y, int x, CELL *cell); +static void ReHiliteText(XtermWidget xw, CELL *first, CELL *last); +static void SaltTextAway(XtermWidget xw, CELL *cellc, CELL *cell); +static void SelectSet(XtermWidget xw, XEvent * event, String *params, Cardinal num_params); static void SelectionReceived PROTO_XT_SEL_CB_ARGS; -static void StartSelect(XtermWidget xw, const CELL * cell); +static void StartSelect(XtermWidget xw, const CELL *cell); static void TrackDown(XtermWidget xw, XButtonEvent * event); -static void TrackText(XtermWidget xw, const CELL * first, const CELL * last); -static void _OwnSelection(XtermWidget xw, String * selections, Cardinal count); -static void do_select_end(XtermWidget xw, XEvent * event, String * params, +static void TrackText(XtermWidget xw, const CELL *first, const CELL *last); +static void _OwnSelection(XtermWidget xw, String *selections, Cardinal count); +static void do_select_end(XtermWidget xw, XEvent * event, String *params, Cardinal *num_params, Bool use_cursor_loc); #define MOUSE_LIMIT (255 - 32) @@ -175,7 +174,7 @@ #define EXT_MOUSE_START (127 - 32) static int -MouseLimit(TScreen * screen) +MouseLimit(TScreen *screen) { int mouse_limit; @@ -195,7 +194,7 @@ } static unsigned -EmitMousePosition(TScreen * screen, Char line[], unsigned count, int value) +EmitMousePosition(TScreen *screen, Char line[], unsigned count, int value) { int mouse_limit = MouseLimit(screen); @@ -238,7 +237,7 @@ } static unsigned -EmitMousePositionSeparator(TScreen * screen, Char line[], unsigned count) +EmitMousePositionSeparator(TScreen *screen, Char line[], unsigned count) { switch (screen->extend_coords) { case SET_SGR_EXT_MODE_MOUSE: @@ -727,7 +726,7 @@ #if OPT_READLINE static int -isClick1_clean(TScreen * screen, XButtonEvent * event) +isClick1_clean(TScreen *screen, XButtonEvent * event) { int delta; @@ -756,7 +755,7 @@ } static int -isDoubleClick3(TScreen * screen, XButtonEvent * event) +isDoubleClick3(TScreen *screen, XButtonEvent * event) { int delta; @@ -795,7 +794,7 @@ } static int -CheckSecondPress3(TScreen * screen, XEvent * event) +CheckSecondPress3(TScreen *screen, XEvent * event) { int delta; @@ -834,7 +833,7 @@ } static int -rowOnCurrentLine(TScreen * screen, +rowOnCurrentLine(TScreen *screen, int line, int *deltap) /* must be XButtonEvent */ { @@ -864,13 +863,13 @@ } static int -eventRow(TScreen * screen, XEvent * event) /* must be XButtonEvent */ +eventRow(TScreen *screen, XEvent * event) /* must be XButtonEvent */ { return (event->xbutton.y - screen->border) / FontHeight(screen); } static int -eventColBetween(TScreen * screen, XEvent * event) /* must be XButtonEvent */ +eventColBetween(TScreen *screen, XEvent * event) /* must be XButtonEvent */ { /* Correct by half a width - we are acting on a boundary, not on a cell. */ return ((event->xbutton.x - OriginX(screen) + (FontWidth(screen) - 1) / 2) @@ -878,7 +877,7 @@ } static int -ReadLineMovePoint(TScreen * screen, int col, int ldelta) +ReadLineMovePoint(TScreen *screen, int col, int ldelta) { Char line[6]; unsigned count = 0; @@ -901,7 +900,7 @@ } static int -ReadLineDelete(TScreen * screen, CELL * cell1, CELL * cell2) +ReadLineDelete(TScreen *screen, CELL *cell1, CELL *cell2) { int del; @@ -914,7 +913,7 @@ } static void -readlineExtend(TScreen * screen, XEvent * event) +readlineExtend(TScreen *screen, XEvent * event) { int ldelta1, ldelta2; @@ -941,7 +940,7 @@ void DiredButton(Widget w, XEvent * event, /* must be XButtonEvent */ - String * params GCC_UNUSED, /* selections */ + String *params GCC_UNUSED, /* selections */ Cardinal *num_params GCC_UNUSED) { XtermWidget xw; @@ -972,7 +971,7 @@ void ReadLineButton(Widget w, XEvent * event, /* must be XButtonEvent */ - String * params GCC_UNUSED, /* selections */ + String *params GCC_UNUSED, /* selections */ Cardinal *num_params GCC_UNUSED) { XtermWidget xw; @@ -1029,7 +1028,7 @@ void ViButton(Widget w, XEvent * event, /* must be XButtonEvent */ - String * params GCC_UNUSED, /* selections */ + String *params GCC_UNUSED, /* selections */ Cardinal *num_params GCC_UNUSED) { XtermWidget xw; @@ -1068,7 +1067,7 @@ void HandleSelectExtend(Widget w, XEvent * event, /* must be XMotionEvent */ - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *num_params GCC_UNUSED) { XtermWidget xw; @@ -1077,7 +1076,7 @@ TScreen *screen = TScreenOf(xw); CELL cell; - TRACE(("HandleSelectExtend\n")); + TRACE(("HandleSelectExtend @%ld\n", event->xmotion.time)); screen->selection_time = event->xmotion.time; switch (screen->eventMode) { @@ -1104,7 +1103,7 @@ void HandleKeyboardSelectExtend(Widget w, XEvent * event GCC_UNUSED, /* must be XButtonEvent */ - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *num_params GCC_UNUSED) { XtermWidget xw; @@ -1120,13 +1119,14 @@ static void do_select_end(XtermWidget xw, XEvent * event, /* must be XButtonEvent */ - String * params, /* selections */ + String *params, /* selections */ Cardinal *num_params, Bool use_cursor_loc) { TScreen *screen = TScreenOf(xw); screen->selection_time = event->xbutton.time; + TRACE(("do_select_end @%ld\n", screen->selection_time)); switch (screen->eventMode) { case NORMAL: (void) SendMousePosition(xw, event); @@ -1144,7 +1144,7 @@ void HandleSelectEnd(Widget w, XEvent * event, /* must be XButtonEvent */ - String * params, /* selections */ + String *params, /* selections */ Cardinal *num_params) { XtermWidget xw; @@ -1158,7 +1158,7 @@ void HandleKeyboardSelectEnd(Widget w, XEvent * event, /* must be XButtonEvent */ - String * params, /* selections */ + String *params, /* selections */ Cardinal *num_params) { XtermWidget xw; @@ -1175,7 +1175,7 @@ void HandleCopySelection(Widget w, XEvent * event, - String * params, /* list of targets */ + String *params, /* list of targets */ Cardinal *num_params) { XtermWidget xw; @@ -1205,7 +1205,7 @@ #if OPT_WIDE_CHARS static Cardinal -addXtermChar(Char ** buffer, Cardinal *used, Cardinal offset, unsigned value) +addXtermChar(Char **buffer, Cardinal *used, Cardinal offset, unsigned value) { if (offset + 1 >= *used) { *used = 1 + (2 * (offset + 1)); @@ -1222,7 +1222,7 @@ * or ASCII/Latin-1 equivalents for special cases. */ static Char * -UTF8toLatin1(TScreen * screen, Char * s, unsigned long len, unsigned long *result) +UTF8toLatin1(TScreen *screen, Char *s, unsigned long len, unsigned long *result) { static Char *buffer; static Cardinal used; @@ -1320,10 +1320,11 @@ for (i = 0; i < (*text_list_count); ++i) { data = (Char *) (*text_list)[i]; size = strlen((*text_list)[i]) + 1; - data = UTF8toLatin1(screen, data, size, &size); - memcpy(tmp, data, size + 1); - new_text_list[i] = tmp; - tmp += size + 1; + if ((data = UTF8toLatin1(screen, data, size, &size)) != 0) { + memcpy(tmp, data, size + 1); + new_text_list[i] = tmp; + tmp += size + 1; + } } XFreeStringList((*text_list)); *text_list = new_text_list; @@ -1345,7 +1346,6 @@ } *nextc = *nextp; *nextp = '\0'; - x_strtrim(value); return nextp; } @@ -1404,30 +1404,32 @@ count = 0; do { char *nextp = parseItem(listp, &nextc); - size_t len = strlen(listp); + char *item = x_strtrim(listp); + size_t len = (item ? strlen(item) : 0); if (len == 0) { /* EMPTY */ ; } #if OPT_WIDE_CHARS - else if (sameItem(listp, "UTF8")) { + else if (sameItem(item, "UTF8")) { result[count++] = XA_UTF8_STRING(XtDisplay(w)); } #endif - else if (sameItem(listp, "I18N")) { + else if (sameItem(item, "I18N")) { if (screen->i18nSelections) { result[count++] = XA_TEXT(XtDisplay(w)); result[count++] = XA_COMPOUND_TEXT(XtDisplay(w)); } - } else if (sameItem(listp, "TEXT")) { + } else if (sameItem(item, "TEXT")) { result[count++] = XA_TEXT(XtDisplay(w)); - } else if (sameItem(listp, "COMPOUND_TEXT")) { + } else if (sameItem(item, "COMPOUND_TEXT")) { result[count++] = XA_COMPOUND_TEXT(XtDisplay(w)); - } else if (sameItem(listp, "STRING")) { + } else if (sameItem(item, "STRING")) { result[count++] = XA_STRING; } *nextp++ = nextc; listp = nextp; + free(item); } while (nextc != '\0'); if (count) { result[count] = None; @@ -1437,6 +1439,7 @@ XtFree((char *) result); } } + free(copied); } else { TRACE(("Couldn't allocate copy of selection types\n")); } @@ -1447,7 +1450,7 @@ #if OPT_WIDE_CHARS static Atom * -allocUtf8Targets(Widget w, TScreen * screen) +allocUtf8Targets(Widget w, TScreen *screen) { Atom **resultp = &(screen->selection_targets_utf8); @@ -1483,7 +1486,7 @@ #endif static Atom * -alloc8bitTargets(Widget w, TScreen * screen) +alloc8bitTargets(Widget w, TScreen *screen) { Atom **resultp = &(screen->selection_targets_8bit); @@ -1567,7 +1570,7 @@ * call to XmuInternStrings(). */ static String * -MapSelections(XtermWidget xw, String * params, Cardinal num_params) +MapSelections(XtermWidget xw, String *params, Cardinal num_params) { String *result = params; @@ -1597,6 +1600,10 @@ : params[j])); if (result[j] == 0) { UnmapSelections(xw); + while (j != 0) { + free((void *) result[--j]); + } + free(result); result = 0; break; } @@ -1645,6 +1652,7 @@ cutbuffer = -1; break; } + TRACE(("CutBuffer(%d) = %d\n", (int) code, cutbuffer)); return cutbuffer; } @@ -1669,7 +1677,7 @@ void xtermGetSelection(Widget w, Time ev_time, - String * params, /* selections in precedence order */ + String *params, /* selections in precedence order */ Cardinal num_params, Atom * targets) { @@ -1684,7 +1692,7 @@ if ((xw = getXtermWidget(w)) == 0) return; - TRACE(("xtermGetSelection num_params %d\n", num_params)); + TRACE(("xtermGetSelection num_params %d @%ld\n", num_params, ev_time)); params = MapSelections(xw, params, num_params); XmuInternStrings(XtDisplay(w), params, (Cardinal) 1, &selection); @@ -1706,10 +1714,10 @@ line = XFetchBuffer(XtDisplay(w), &inbytes, cutbuffer); nbytes = (unsigned long) inbytes; - if (nbytes > 0) + if (nbytes > 0) { SelectionReceived(w, NULL, &selection, &type, (XtPointer) line, &nbytes, &fmt8); - else if (num_params > 1) { + } else if (num_params > 1) { xtermGetSelection(w, ev_time, params + 1, num_params - 1, NULL); } #if OPT_PASTE64 @@ -1717,7 +1725,6 @@ FinishPaste64(xw); } #endif - return; } else { struct _SelectionList *list; @@ -1759,7 +1766,7 @@ #if OPT_TRACE && OPT_WIDE_CHARS static void -GettingSelection(Display * dpy, Atom type, Char * line, unsigned long len) +GettingSelection(Display *dpy, Atom type, Char *line, unsigned long len) { Char *cp; char *name; @@ -1793,7 +1800,7 @@ abcdefghijklmnopqrstuvwxyz\ 0123456789+/"; static void -base64_flush(TScreen * screen) +base64_flush(TScreen *screen) { Char x; switch (screen->base64_count) { @@ -1818,15 +1825,90 @@ } #endif /* OPT_PASTE64 */ +/* + * Translate ISO-8859-1 or UTF-8 data to NRCS. + */ +static void +ToNational(TScreen *screen, Char *buffer, unsigned *length) +{ + int gsetL = screen->gsets[screen->curgl]; + int gsetR = screen->gsets[screen->curgr]; + unsigned chr, out, gl, gr; + Char *p; + +#if OPT_WIDE_CHARS + if ((screen->utf8_nrc_mode | screen->utf8_mode) != uFalse) { + PtyData *data = TypeXtMallocX(PtyData, *length); + + memset(data, 0, sizeof(*data)); + data->next = data->buffer; + data->last = data->buffer + *length; + memcpy(data->buffer, buffer, (size_t) *length); + p = buffer; + while (data->next < data->last) { + if (!decodeUtf8(data)) { + data->utf_size = 1; + data->utf_data = data->next[0]; + } + data->next += data->utf_size; + chr = data->utf_data; + out = chr; + if ((gl = xtermCharSetIn(screen, chr, gsetL)) != chr) { + out = gl; + } else if ((gr = xtermCharSetIn(screen, chr, gsetR)) != chr) { + out = gr; + } + *p++ = (Char) ((out < 256) ? out : ' '); + } + *length = (unsigned) (p - buffer); + free(data); + } else +#endif + { + for (p = buffer; (p - buffer) < *length; ++p) { + chr = *p; + out = chr; + if ((gl = xtermCharSetIn(screen, chr, gsetL)) != chr) { + out = gl; + } else if ((gr = xtermCharSetIn(screen, chr, gsetR)) != chr) { + out = gr; + } + *p = (Char) out; + } + } +} + static void -_qWriteSelectionData(TScreen * screen, Char * lag, unsigned length) +_qWriteSelectionData(XtermWidget xw, Char *lag, unsigned length) { + TScreen *screen = TScreenOf(xw); + + /* + * If we are pasting into a window which is using NRCS, we want to map + * the text from the normal encoding (ISO-8859-1 or UTF-8) into the coding + * that an application would use to write characters with NRCS. + * + * TODO: handle conversion from UTF-8, and adjust length. This can be done + * in the same buffer because the target is always 8-bit. + */ + if ((xw->flags & NATIONAL) && (length != 0)) { + ToNational(screen, lag, &length); + } #if OPT_PASTE64 if (screen->base64_paste) { /* Send data as base64 */ Char *p = lag; Char buf[64]; unsigned x = 0; + + /* + * Handle the case where the selection is from _this_ xterm, which + * puts part of the reply in the buffer before the selection callback + * happens. + */ + if (screen->base64_paste && screen->unparse_len) { + unparse_end(xw); + } while (length--) { switch (screen->base64_count) { case 0: @@ -1876,12 +1958,13 @@ } static void -_WriteSelectionData(TScreen * screen, Char * line, size_t length) +_WriteSelectionData(XtermWidget xw, Char *line, size_t length) { /* Write data to pty a line at a time. */ /* Doing this one line at a time may no longer be necessary because v_write has been re-written. */ + TScreen *screen = TScreenOf(xw); Char *lag, *end; /* in the VMS version, if tt_pasting isn't set to True then qio @@ -1897,7 +1980,7 @@ #if OPT_PASTE64 if (screen->base64_paste) { - _qWriteSelectionData(screen, lag, (unsigned) (end - lag)); + _qWriteSelectionData(xw, lag, (unsigned) (end - lag)); base64_flush(screen); } else #endif @@ -1907,14 +1990,14 @@ for (cp = line; cp != end; cp++) { if (*cp == '\n') { *cp = '\r'; - _qWriteSelectionData(screen, lag, (unsigned) (cp - lag + 1)); + _qWriteSelectionData(xw, lag, (unsigned) (cp - lag + 1)); lag = cp + 1; } } } if (lag != end) { - _qWriteSelectionData(screen, lag, (unsigned) (end - lag)); + _qWriteSelectionData(xw, lag, (unsigned) (end - lag)); } } #ifdef VMS @@ -1925,7 +2008,7 @@ #if OPT_READLINE static void -_WriteKey(TScreen * screen, const Char * in) +_WriteKey(TScreen *screen, const Char *in) { Char line[16]; unsigned count = 0; @@ -1944,6 +2027,50 @@ } #endif /* OPT_READLINE */ +/* + * Unless enabled by the user, strip control characters other than formatting. + */ +static size_t +removeControls(XtermWidget xw, char *value) +{ + TScreen *screen = TScreenOf(xw); + size_t dst = 0; + size_t src = 0; + + if (screen->allowPasteControls) { + dst = strlen(value); + } else { + while ((value[dst] = value[src]) != '\0') { + int ch = CharOf(value[src++]); + if (ch < 32) { + switch (ch) { + case '\b': + case '\t': + case '\n': + case '\r': + ++dst; + break; + default: + continue; + } + } +#if OPT_WIDE_CHARS + else if (screen->utf8_inparse || screen->utf8_nrc_mode) + ++dst; +#endif +#if OPT_C1_PRINT || OPT_WIDE_CHARS + else if (screen->c1_printable) + ++dst; +#endif + else if (ch >= 128 && ch < 160) + continue; + else + ++dst; + } + } + return dst; +} + /* SelectionReceived: stuff received selection text into pty */ /* ARGSUSED */ @@ -2049,7 +2176,7 @@ } #endif for (i = 0; i < text_list_count; i++) { - size_t len = strlen(text_list[i]); + size_t len = removeControls(xw, text_list[i]); if (screen->selectToBuffer) { size_t have = (screen->internal_select ? strlen(screen->internal_select) @@ -2061,7 +2188,7 @@ screen->internal_select = buffer; } } else { - _WriteSelectionData(screen, (Char *) text_list[i], len); + _WriteSelectionData(xw, (Char *) text_list[i], len); } } #if OPT_PASTE64 @@ -2102,7 +2229,7 @@ void HandleInsertSelection(Widget w, XEvent * event, /* assumed to be XButtonEvent* */ - String * params, /* selections in precedence order */ + String *params, /* selections in precedence order */ Cardinal *num_params) { XtermWidget xw; @@ -2164,7 +2291,7 @@ static void do_select_start(XtermWidget xw, XEvent * event, /* must be XButtonEvent* */ - CELL * cell) + CELL *cell) { TScreen *screen = TScreenOf(xw); @@ -2187,7 +2314,7 @@ void HandleSelectStart(Widget w, XEvent * event, /* must be XButtonEvent* */ - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *num_params GCC_UNUSED) { XtermWidget xw; @@ -2213,7 +2340,7 @@ void HandleKeyboardSelectStart(Widget w, XEvent * event, /* must be XButtonEvent* */ - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *num_params GCC_UNUSED) { XtermWidget xw; @@ -2254,7 +2381,7 @@ void TrackMouse(XtermWidget xw, int func, - CELL * start, + CELL *start, int firstrow, int lastrow) { @@ -2278,7 +2405,7 @@ } static void -StartSelect(XtermWidget xw, const CELL * cell) +StartSelect(XtermWidget xw, const CELL *cell) { TScreen *screen = TScreenOf(xw); @@ -2305,7 +2432,7 @@ static void EndExtend(XtermWidget xw, XEvent * event, /* must be XButtonEvent */ - String * params, /* selections */ + String *params, /* selections */ Cardinal num_params, Bool use_cursor_loc) { @@ -2398,7 +2525,7 @@ void HandleSelectSet(Widget w, XEvent * event, - String * params, + String *params, Cardinal *num_params) { XtermWidget xw; @@ -2413,7 +2540,7 @@ static void SelectSet(XtermWidget xw, XEvent * event GCC_UNUSED, - String * params, + String *params, Cardinal num_params) { TScreen *screen = TScreenOf(xw); @@ -2434,7 +2561,7 @@ static void do_start_extend(XtermWidget xw, XEvent * event, /* must be XButtonEvent* */ - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *num_params GCC_UNUSED, Bool use_cursor_loc) { @@ -2501,7 +2628,7 @@ } static void -ExtendExtend(XtermWidget xw, const CELL * cell) +ExtendExtend(XtermWidget xw, const CELL *cell) { TScreen *screen = TScreenOf(xw); int coord = Coordinate(screen, cell); @@ -2535,7 +2662,7 @@ void HandleStartExtend(Widget w, XEvent * event, /* must be XButtonEvent* */ - String * params, /* unused */ + String *params, /* unused */ Cardinal *num_params) /* unused */ { XtermWidget xw; @@ -2549,7 +2676,7 @@ void HandleKeyboardStartExtend(Widget w, XEvent * event, /* must be XButtonEvent* */ - String * params, /* unused */ + String *params, /* unused */ Cardinal *num_params) /* unused */ { XtermWidget xw; @@ -2561,7 +2688,7 @@ } void -ScrollSelection(TScreen * screen, int amount, Bool always) +ScrollSelection(TScreen *screen, int amount, Bool always) { int minrow = INX2ROW(screen, -screen->savedlines); int maxrow = INX2ROW(screen, screen->max_row); @@ -2597,14 +2724,14 @@ adjust = ROW2INX(screen, screen->startH.row); if (always - || !ScrnHaveLineMargins(screen) - || ScrnIsLineInMargins(screen, adjust)) { + || !ScrnHaveRowMargins(screen) + || ScrnIsRowInMargins(screen, adjust)) { scroll_update_one(&screen->startH); } adjust = ROW2INX(screen, screen->endH.row); if (always - || !ScrnHaveLineMargins(screen) - || ScrnIsLineInMargins(screen, adjust)) { + || !ScrnHaveRowMargins(screen) + || ScrnIsRowInMargins(screen, adjust)) { scroll_update_one(&screen->endH); } } @@ -2615,7 +2742,7 @@ /*ARGSUSED*/ void -ResizeSelection(TScreen * screen GCC_UNUSED, int rows, int cols) +ResizeSelection(TScreen *screen GCC_UNUSED, int rows, int cols) { rows--; /* decr to get 0-max */ cols--; @@ -2654,10 +2781,10 @@ #endif static void -PointToCELL(TScreen * screen, +PointToCELL(TScreen *screen, int y, int x, - CELL * cell) + CELL *cell) /* Convert pixel coordinates to character coordinates. Rows are clipped between firstValidRow and lastValidRow. Columns are clipped between to be 0 or greater, but are not clipped to some @@ -2691,7 +2818,7 @@ * Find the last column at which text was drawn on the given row. */ static int -LastTextCol(TScreen * screen, LineData * ld, int row) +LastTextCol(TScreen *screen, LineData *ld, int row) { int i = -1; Char *ch; @@ -2730,7 +2857,7 @@ { /* NUL SOH STX ETX EOT ENQ ACK BEL */ 32, 1, 1, 1, 1, 1, 1, 1, -/* BS HT NL VT NP CR SO SI */ +/* BS HT NL VT FF CR SO SI */ 1, 32, 1, 1, 1, 1, 1, 1, /* DLE DC1 DC2 DC3 DC4 NAK SYN ETB */ 1, 1, 1, 1, 1, 1, 1, 1, @@ -2811,18 +2938,19 @@ #endif static int -class_of(LineData * ld, CELL * cell) +class_of(LineData *ld, CELL *cell) { CELL temp = *cell; + int result = 0; #if OPT_DEC_CHRSET if (CSET_DOUBLE(GetLineDblCS(ld))) { temp.col /= 2; } #endif - - assert(temp.col < (int) ld->lineSize); - return CharacterClass((int) (ld->charData[temp.col])); + if (temp.col < (int) ld->lineSize) + result = CharacterClass((int) (ld->charData[temp.col])); + return result; } #if OPT_WIDE_CHARS @@ -2841,9 +2969,9 @@ * beginning of the next line. */ static Boolean -okPosition(TScreen * screen, - LineData ** ld, - CELL * cell) +okPosition(TScreen *screen, + LineData **ld, + CELL *cell) { Boolean result = True; @@ -2860,9 +2988,9 @@ } static void -trimLastLine(TScreen * screen, - LineData ** ld, - CELL * last) +trimLastLine(TScreen *screen, + LineData **ld, + CELL *last) { if (screen->cutNewline && last->row < screen->max_row) { last->col = 0; @@ -2877,7 +3005,7 @@ * Returns the first row of a wrapped line. */ static int -firstRowOfLine(TScreen * screen, int row, Bool visible) +firstRowOfLine(TScreen *screen, int row, Bool visible) { LineData *ld = 0; int limit = visible ? 0 : -screen->savedlines; @@ -2894,7 +3022,7 @@ * Returns the last row of a wrapped line. */ static int -lastRowOfLine(TScreen * screen, int row) +lastRowOfLine(TScreen *screen, int row) { LineData *ld; @@ -2910,7 +3038,7 @@ * Returns the number of cells on the range of rows. */ static unsigned -lengthOfLines(TScreen * screen, int firstRow, int lastRow) +lengthOfLines(TScreen *screen, int firstRow, int lastRow) { unsigned length = 0; int n; @@ -2930,7 +3058,7 @@ * the line. */ static char * -make_indexed_text(TScreen * screen, int row, unsigned length, int *indexed) +make_indexed_text(TScreen *screen, int row, unsigned length, int *indexed) { Char *result = 0; size_t need = (length + 1); @@ -3016,7 +3144,7 @@ * set the cell to the actual row/column values. */ static void -columnToCell(TScreen * screen, int row, int col, CELL * cell) +columnToCell(TScreen *screen, int row, int col, CELL *cell) { while (row < screen->max_row) { LineData *ld = GET_LINEDATA(screen, row); @@ -3047,7 +3175,7 @@ * Given a cell, find the corresponding column offset. */ static int -cellToColumn(TScreen * screen, CELL * cell) +cellToColumn(TScreen *screen, CELL *cell) { LineData *ld = 0; int col = cell->col; @@ -3066,7 +3194,7 @@ } static void -do_select_regex(TScreen * screen, CELL * startc, CELL * endc) +do_select_regex(TScreen *screen, CELL *startc, CELL *endc) { LineData *ld = GET_LINEDATA(screen, startc->row); int inx = ((screen->numberOfClicks - 1) % screen->maxClicks); @@ -3179,8 +3307,8 @@ */ static void ComputeSelect(XtermWidget xw, - CELL * startc, - CELL * endc, + CELL *startc, + CELL *endc, Bool extend) { TScreen *screen = TScreenOf(xw); @@ -3381,8 +3509,8 @@ /* Guaranteed (first.row, first.col) <= (last.row, last.col) */ static void TrackText(XtermWidget xw, - const CELL * firstp, - const CELL * lastp) + const CELL *firstp, + const CELL *lastp) { TScreen *screen = TScreenOf(xw); int from, to; @@ -3434,8 +3562,8 @@ /* Guaranteed that (first->row, first->col) <= (last->row, last->col) */ static void ReHiliteText(XtermWidget xw, - CELL * firstp, - CELL * lastp) + CELL *firstp, + CELL *lastp) { TScreen *screen = TScreenOf(xw); int i; @@ -3480,8 +3608,8 @@ */ static void SaltTextAway(XtermWidget xw, - CELL * cellc, - CELL * cell) + CELL *cellc, + CELL *cell) { TScreen *screen = TScreenOf(xw); int i, j = 0; @@ -3556,14 +3684,14 @@ #if OPT_PASTE64 void -ClearSelectionBuffer(TScreen * screen) +ClearSelectionBuffer(TScreen *screen) { screen->selection_length = 0; screen->base64_count = 0; } static void -AppendStrToSelectionBuffer(TScreen * screen, Char * text, size_t len) +AppendStrToSelectionBuffer(TScreen *screen, Char *text, size_t len) { if (len != 0) { int j = (int) (screen->selection_length + len); /* New length */ @@ -3595,7 +3723,7 @@ } void -AppendToSelectionBuffer(TScreen * screen, unsigned c) +AppendToSelectionBuffer(TScreen *screen, unsigned c) { unsigned six; Char ch; @@ -3644,7 +3772,7 @@ } void -CompleteSelection(XtermWidget xw, String * args, Cardinal len) +CompleteSelection(XtermWidget xw, String *args, Cardinal len) { TScreen *screen = TScreenOf(xw); @@ -3759,8 +3887,10 @@ *value = (XtPointer) targetP; - while (*my_targets != None) { - *targetP++ = *my_targets++; + if (my_targets != 0) { + while (*my_targets != None) { + *targetP++ = *my_targets++; + } } *targetP++ = XA_LENGTH(dpy); *targetP++ = XA_LIST_LENGTH(dpy); @@ -3921,7 +4051,7 @@ static void _OwnSelection(XtermWidget xw, - String * selections, + String *selections, Cardinal count) { TScreen *screen = TScreenOf(xw); @@ -3985,7 +4115,7 @@ } static void -ResetSelectionState(TScreen * screen) +ResetSelectionState(TScreen *screen) { screen->selection_count = 0; screen->startH = zeroCELL; @@ -4048,7 +4178,7 @@ /* returns number of chars in line from scol to ecol out */ /* ARGSUSED */ static int -Length(TScreen * screen, +Length(TScreen *screen, int row, int scol, int ecol) @@ -4063,11 +4193,11 @@ /* copies text into line, preallocated */ static Char * -SaveText(TScreen * screen, +SaveText(TScreen *screen, int row, int scol, int ecol, - Char * lp, /* pointer to where to put the text */ + Char *lp, /* pointer to where to put the text */ int *eol) { LineData *ld; @@ -4100,7 +4230,7 @@ /* Combining characters attached to double-width characters are in memory attached to the HIDDEN_CHAR */ if_OPT_WIDE_CHARS(screen, { - if (screen->utf8_mode != uFalse) { + if ((screen->utf8_nrc_mode | screen->utf8_mode) != uFalse) { unsigned ch; size_t off; for_each_combData(off, ld) { @@ -4114,7 +4244,7 @@ continue; } previous = c; - if (screen->utf8_mode != uFalse) { + if ((screen->utf8_nrc_mode | screen->utf8_mode) != uFalse) { lp = convertToUTF8(lp, (c != 0) ? c : ' '); if_OPT_WIDE_CHARS(screen, { unsigned ch; @@ -4168,21 +4298,27 @@ { int result = (int) (32 + (KeyState(event->state) << 2)); + if (event->type == MotionNotify) + result += 32; + if (button < 0 || button > 5) { result += 3; } else { if (button > 3) result += (64 - 4); - if (event->type == MotionNotify) - result += 32; result += button; } + TRACE(("BtnCode button %d, %s state " FMT_MODIFIER_NAMES " ->%#x\n", + button, + visibleEventType(event->type), + ARG_MODIFIER_NAMES(event->state), + result)); return result; } static unsigned -EmitButtonCode(TScreen * screen, - Char * line, +EmitButtonCode(TScreen *screen, + Char *line, unsigned count, XButtonEvent * event, int button) @@ -4217,6 +4353,22 @@ return count; } +static int +FirstBitN(int bits) +{ + int result = -1; + if (bits > 0) { + result = 0; + while (!(bits & 1)) { + bits /= 2; + ++result; + } + } + return result; +} + +#define ButtonBit(button) ((button >= 0) ? (1 << (button)) : 0) + #define EMIT_BUTTON(button) EmitButtonCode(screen, line, count, event, button) static void @@ -4293,7 +4445,7 @@ /* Button-Motion events */ switch (event->type) { case ButtonPress: - screen->mouse_button = button; + screen->mouse_button |= ButtonBit(button); count = EMIT_BUTTON(button); break; case ButtonRelease: @@ -4303,6 +4455,7 @@ * release for buttons 1..3 to a -1, which will be later mapped * into a "0" (some button was released). */ + screen->mouse_button &= ~ButtonBit(button); if (button < 3) { switch (screen->extend_coords) { case SET_SGR_EXT_MODE_MOUSE: @@ -4313,7 +4466,6 @@ break; } } - screen->mouse_button = button; count = EMIT_BUTTON(button); break; case MotionNotify: @@ -4324,7 +4476,7 @@ && (col == screen->mouse_col)) { changed = False; } else { - count = EMIT_BUTTON(screen->mouse_button); + count = EMIT_BUTTON(FirstBitN(screen->mouse_button)); } break; default: @@ -4407,9 +4559,9 @@ getSelectionString(XtermWidget xw, Widget w, XEvent * event, - String * params, + String *params, Cardinal *num_params, - CELL * start, CELL * finish) + CELL *start, CELL *finish) { TScreen *screen = TScreenOf(xw); #if OPT_PASTE64 @@ -4454,7 +4606,7 @@ /* obtain data from the screen, passing the endpoints to caller's parameters */ static char * -getDataFromScreen(XtermWidget xw, String method, CELL * start, CELL * finish) +getDataFromScreen(XtermWidget xw, String method, CELL *start, CELL *finish) { TScreen *screen = TScreenOf(xw); @@ -4490,6 +4642,7 @@ lookupSelectUnit(xw, 0, method); screen->selectUnit = screen->selectMap[0]; + memset(start, 0, sizeof(*start)); start->row = screen->cur_row; start->col = screen->cur_col; *finish = *start; @@ -4605,6 +4758,7 @@ if (!pass) { result = TypeCallocN(char *, argc + 1); if (result == 0) { + free(blob); break; } } @@ -4623,7 +4777,7 @@ } static void -formatVideoAttrs(XtermWidget xw, char *buffer, CELL * cell) +formatVideoAttrs(XtermWidget xw, char *buffer, CELL *cell) { TScreen *screen = TScreenOf(xw); LineData *ld = GET_LINEDATA(screen, cell->row); @@ -4673,8 +4827,7 @@ buffer += sprintf(buffer, "%s48;5", delim); delim = ";"; } - buffer += sprintf(buffer, "%s%u", delim, bg); - delim = ";"; + (void) sprintf(buffer, "%s%u", delim, bg); } #endif } @@ -4685,8 +4838,8 @@ expandFormat(XtermWidget xw, const char *format, char *data, - CELL * start, - CELL * finish) + CELL *start, + CELL *finish) { char *result = 0; if (!IsEmpty(format)) { @@ -4794,9 +4947,11 @@ static void executeCommand(char **argv) { - if (fork() == 0) { - execvp(argv[0], argv); - exit(EXIT_FAILURE); + if (argv != 0 && argv[0] != 0) { + if (fork() == 0) { + execvp(argv[0], argv); + exit(EXIT_FAILURE); + } } } @@ -4818,7 +4973,7 @@ void HandleExecFormatted(Widget w, XEvent * event GCC_UNUSED, - String * params, /* selections */ + String *params, /* selections */ Cardinal *num_params) { XtermWidget xw; @@ -4835,13 +4990,14 @@ data = getSelectionString(xw, w, event, params, num_params, &start, &finish); - argv = tokenizeFormat(params[0]); - blob = argv[0]; - for (argc = 0; argv[argc] != 0; ++argc) { - argv[argc] = expandFormat(xw, argv[argc], data, &start, &finish); + if ((argv = tokenizeFormat(params[0])) != 0) { + blob = argv[0]; + for (argc = 0; argv[argc] != 0; ++argc) { + argv[argc] = expandFormat(xw, argv[argc], data, &start, &finish); + } + executeCommand(argv); + freeArgv(blob, argv); } - executeCommand(argv); - freeArgv(blob, argv); } } } @@ -4849,7 +5005,7 @@ void HandleExecSelectable(Widget w, XEvent * event GCC_UNUSED, - String * params, /* selections */ + String *params, /* selections */ Cardinal *num_params) { XtermWidget xw; @@ -4865,14 +5021,18 @@ int argc; data = getDataFromScreen(xw, params[1], &start, &finish); - argv = tokenizeFormat(params[0]); - blob = argv[0]; - for (argc = 0; argv[argc] != 0; ++argc) { - argv[argc] = expandFormat(xw, argv[argc], data, &start, &finish); + if (data != 0) { + if ((argv = tokenizeFormat(params[0])) != 0) { + blob = argv[0]; + for (argc = 0; argv[argc] != 0; ++argc) { + argv[argc] = expandFormat(xw, argv[argc], data, + &start, &finish); + } + executeCommand(argv); + freeArgv(blob, argv); + free(data); + } } - executeCommand(argv); - freeArgv(blob, argv); - free(data); } } } @@ -4880,7 +5040,7 @@ void HandleInsertFormatted(Widget w, XEvent * event GCC_UNUSED, - String * params, /* selections */ + String *params, /* selections */ Cardinal *num_params) { XtermWidget xw; @@ -4892,11 +5052,14 @@ CELL start, finish; char *data; char *temp = x_strdup(params[0]); + char *exps; data = getSelectionString(xw, w, event, params, num_params, &start, &finish); - temp = expandFormat(xw, temp, data, &start, &finish); - unparseputs(xw, temp); + if ((exps = expandFormat(xw, temp, data, &start, &finish)) != 0) { + unparseputs(xw, exps); + free(exps); + } free(data); free(temp); } @@ -4906,7 +5069,7 @@ void HandleInsertSelectable(Widget w, XEvent * event GCC_UNUSED, - String * params, /* selections */ + String *params, /* selections */ Cardinal *num_params) { XtermWidget xw; @@ -4918,11 +5081,17 @@ CELL start, finish; char *data; char *temp = x_strdup(params[0]); + char *exps; data = getDataFromScreen(xw, params[1], &start, &finish); - temp = expandFormat(xw, temp, data, &start, &finish); - unparseputs(xw, temp); - free(data); + if (data != 0) { + exps = expandFormat(xw, temp, data, &start, &finish); + if (exps != 0) { + unparseputs(xw, exps); + free(exps); + } + free(data); + } free(temp); } } diff -Nru xterm-278/charproc.c xterm-297/charproc.c --- xterm-278/charproc.c 2012-01-19 00:22:08.000000000 +0000 +++ xterm-297/charproc.c 2013-09-10 17:27:51.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: charproc.c,v 1.1161 2012/01/19 00:22:08 tom Exp $ */ +/* $XTermId: charproc.c,v 1.1315 2013/09/10 17:27:51 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -102,7 +102,12 @@ #endif +#if OPT_DOUBLE_BUFFER +#include +#endif + #if OPT_WIDE_CHARS +#include #include #include #ifdef HAVE_LANGINFO_CODESET @@ -128,12 +133,12 @@ #include #include #include -#include #include #include +#include -typedef void (*BitFunc) (unsigned * /* p */ , - unsigned /* mask */ ); +typedef int (*BitFunc) (unsigned * /* p */ , + unsigned /* mask */ ); static IChar doinput(void); static int set_character_class(char * /*s */ ); @@ -146,13 +151,15 @@ int /* cols */ , Bool /* text */ ); static void SwitchBufs(XtermWidget /* xw */ , - int /* toBuf */ ); -static void ToAlternate(XtermWidget /* xw */ ); + int /* toBuf */ , + Bool /* clearFirst */ ); +static void ToAlternate(XtermWidget /* xw */ , + Bool /* clearFirst */ ); static void ansi_modes(XtermWidget termw, BitFunc /* func */ ); -static void bitclr(unsigned *p, unsigned mask); -static void bitcpy(unsigned *p, unsigned q, unsigned mask); -static void bitset(unsigned *p, unsigned mask); +static int bitclr(unsigned *p, unsigned mask); +static int bitcpy(unsigned *p, unsigned q, unsigned mask); +static int bitset(unsigned *p, unsigned mask); static void dpmodes(XtermWidget /* xw */ , BitFunc /* func */ ); static void restoremodes(XtermWidget /* xw */ ); @@ -162,6 +169,7 @@ #define DoStartBlinking(s) ((s)->cursor_blink ^ (s)->cursor_blink_esc) #if OPT_BLINK_CURS || OPT_BLINK_TEXT +#define UpdateCursorBlink(screen) SetCursorBlink(screen, screen->cursor_blink) static void SetCursorBlink(TScreen * /* screen */ , Bool /* enable */ ); static void HandleBlinking(XtPointer /* closure */ , @@ -180,9 +188,16 @@ #define DEFAULT -1 #define BELLSUPPRESSMSEC 200 -static int nparam; static ANSI reply; -static int param[NPARAM]; +static PARAMS parms; + +#define nparam parms.count + +#define InitParams() parms.count = parms.is_sub[0] = parms.has_subparams = 0 +#define GetParam(n) parms.params[(n)] +#define SetParam(n,v) parms.params[(n)] = v +#define ParamPair(n) nparam - (n), parms.params + (n) +#define ParamsDone() InitParams() static jmp_buf vtjmpbuf; @@ -351,6 +366,10 @@ { "larger-vt-font", HandleLargerFont }, { "smaller-vt-font", HandleSmallerFont }, #endif +#if OPT_SIXEL_GRAPHICS + { "set-private-colors", HandleSetPrivateColorRegisters }, + { "set-sixel-scrolling", HandleSixelScrolling }, +#endif #if OPT_SUN_FUNC_KEYS { "set-sun-function-keys", HandleSunFunctionKeys }, #endif @@ -377,6 +396,8 @@ static XtResource xterm_resources[] = { + Bres(XtNallowPasteControls, XtCAllowPasteControls, + screen.allowPasteControls, False), Bres(XtNallowSendEvents, XtCAllowSendEvents, screen.allowSendEvent0, False), Bres(XtNallowColorOps, XtCAllowColorOps, screen.allowColorOp0, DEF_ALLOW_COLOR), Bres(XtNallowFontOps, XtCAllowFontOps, screen.allowFontOp0, DEF_ALLOW_FONT), @@ -384,21 +405,23 @@ Bres(XtNallowTitleOps, XtCAllowTitleOps, screen.allowTitleOp0, DEF_ALLOW_TITLE), Bres(XtNallowWindowOps, XtCAllowWindowOps, screen.allowWindowOp0, DEF_ALLOW_WINDOW), Bres(XtNaltIsNotMeta, XtCAltIsNotMeta, screen.alt_is_not_meta, False), - Bres(XtNaltSendsEscape, XtCAltSendsEscape, screen.alt_sends_esc, False), + Bres(XtNaltSendsEscape, XtCAltSendsEscape, screen.alt_sends_esc, DEF_ALT_SENDS_ESC), Bres(XtNallowBoldFonts, XtCAllowBoldFonts, screen.allowBoldFonts, True), Bres(XtNalwaysBoldMode, XtCAlwaysBoldMode, screen.always_bold_mode, False), Bres(XtNalwaysHighlight, XtCAlwaysHighlight, screen.always_highlight, False), Bres(XtNappcursorDefault, XtCAppcursorDefault, misc.appcursorDefault, False), Bres(XtNappkeypadDefault, XtCAppkeypadDefault, misc.appkeypadDefault, False), + Bres(XtNalternateScroll, XtCScrollCond, screen.alternateScroll, False), Bres(XtNautoWrap, XtCAutoWrap, misc.autoWrap, True), Bres(XtNawaitInput, XtCAwaitInput, screen.awaitInput, False), Bres(XtNfreeBoldBox, XtCFreeBoldBox, screen.free_bold_box, False), - Bres(XtNbackarrowKey, XtCBackarrowKey, screen.backarrow_key, True), + Bres(XtNbackarrowKey, XtCBackarrowKey, screen.backarrow_key, DEF_BACKARO_BS), Bres(XtNbellIsUrgent, XtCBellIsUrgent, screen.bellIsUrgent, False), Bres(XtNbellOnReset, XtCBellOnReset, screen.bellOnReset, True), Bres(XtNboldMode, XtCBoldMode, screen.bold_mode, True), Bres(XtNbrokenSelections, XtCBrokenSelections, screen.brokenSelections, False), Bres(XtNc132, XtCC132, screen.c132, False), + Bres(XtNcdXtraScroll, XtCCdXtraScroll, misc.cdXtraScroll, False), Bres(XtNcurses, XtCCurses, screen.curses, False), Bres(XtNcutNewline, XtCCutNewline, screen.cutNewline, True), Bres(XtNcutToBeginningOfLine, XtCCutToBeginningOfLine, @@ -418,7 +441,7 @@ Bres(XtNkeepSelection, XtCKeepSelection, screen.keepSelection, True), Bres(XtNloginShell, XtCLoginShell, misc.login_shell, False), Bres(XtNmarginBell, XtCMarginBell, screen.marginbell, False), - Bres(XtNmetaSendsEscape, XtCMetaSendsEscape, screen.meta_sends_esc, False), + Bres(XtNmetaSendsEscape, XtCMetaSendsEscape, screen.meta_sends_esc, DEF_META_SENDS_ESC), Bres(XtNmultiScroll, XtCMultiScroll, screen.multiscroll, False), Bres(XtNoldXtermFKeys, XtCOldXtermFKeys, screen.old_fkeys, False), Bres(XtNpopOnBell, XtCPopOnBell, screen.poponbell, False), @@ -510,7 +533,7 @@ #endif #ifndef NO_ACTIVE_ICON - Bres("activeIcon", "ActiveIcon", misc.active_icon, False), + Sres("activeIcon", "ActiveIcon", misc.active_icon_s, "default"), Ires("iconBorderWidth", XtCBorderWidth, misc.icon_border_width, 2), Sres("iconFont", "IconFont", screen.icon_fontname, "nil2"), Cres("iconBorderColor", XtCBorderColor, misc.icon_border_pixel, XtDefaultBackground), @@ -534,6 +557,7 @@ Bres(XtNforceBoxChars, XtCForceBoxChars, screen.force_box_chars, False), Bres(XtNforcePackedFont, XtCForcePackedFont, screen.force_packed, True), Bres(XtNshowMissingGlyphs, XtCShowMissingGlyphs, screen.force_all_chars, False), + Bres(XtNassumeAllChars, XtCAssumeAllChars, screen.assume_all_chars, False), #endif #if OPT_BROKEN_OSC @@ -621,6 +645,8 @@ CLICK_RES("5", screen.onClick[4], 0), #if OPT_MOD_FKEYS + Ires(XtNmodifyKeyboard, XtCModifyKeyboard, + keyboard.modify_1st.allow_keys, 0), Ires(XtNmodifyCursorKeys, XtCModifyCursorKeys, keyboard.modify_1st.cursor_keys, 2), Ires(XtNmodifyFunctionKeys, XtCModifyFunctionKeys, @@ -648,6 +674,12 @@ Bres(XtNshiftFonts, XtCShiftFonts, misc.shift_fonts, True), #endif +#if OPT_SIXEL_GRAPHICS + Bres(XtNprivateColorRegisters, XtCPrivateColorRegisters, + screen.privatecolorregisters, True), + Bres(XtNsixelScrolling, XtCSixelScrolling, screen.sixel_scrolling, False), +#endif + #if OPT_SUNPC_KBD Ires(XtNctrlFKeys, XtCCtrlFKeys, misc.ctrl_fkeys, 10), #endif @@ -666,6 +698,7 @@ #if OPT_WIDE_CHARS Bres(XtNcjkWidth, XtCCjkWidth, misc.cjk_width, False), Bres(XtNmkWidth, XtCMkWidth, misc.mk_width, False), + Bres(XtNprecompose, XtCPrecompose, screen.normalized_c, True), Bres(XtNutf8Latin1, XtCUtf8Latin1, screen.utf8_latin1, False), Bres(XtNutf8Title, XtCUtf8Title, screen.utf8_title, False), Bres(XtNvt100Graphics, XtCVT100Graphics, screen.vt100_graphics, True), @@ -853,7 +886,7 @@ #if OPT_ISO_COLORS #ifdef EXP_BOGUS_FG static Bool -CheckBogusForeground(TScreen * screen, const char *tag) +CheckBogusForeground(TScreen *screen, const char *tag) { int row = -1, col = -1, pass; Bool isClear = True; @@ -1038,14 +1071,14 @@ #endif /* OPT_ISO_COLORS */ void -resetCharsets(TScreen * screen) +resetCharsets(TScreen *screen) { TRACE(("resetCharsets\n")); - screen->gsets[0] = 'B'; /* ASCII_G */ - screen->gsets[1] = 'B'; /* ASCII_G */ - screen->gsets[2] = 'B'; /* ASCII_G */ - screen->gsets[3] = 'B'; /* ASCII_G */ + screen->gsets[0] = nrc_ASCII; + screen->gsets[1] = nrc_ASCII; + screen->gsets[2] = nrc_ASCII; + screen->gsets[3] = nrc_ASCII; screen->curgl = 0; /* G0 => GL. */ screen->curgr = 2; /* G2 => GR. */ @@ -1057,16 +1090,32 @@ #endif } +static void +modified_DECNRCM(XtermWidget xw) +{ +#if OPT_WIDE_CHARS + TScreen *screen = TScreenOf(xw); + if (screen->wide_chars && (screen->utf8_mode || screen->utf8_nrc_mode)) { + int enabled = ((xw->flags & NATIONAL) != 0); + int modefix; + EXCHANGE(screen->utf8_nrc_mode, screen->utf8_mode, modefix); + switchPtyData(screen, !enabled); + TRACE(("UTF8 mode temporarily %s\n", BtoS(!enabled))); + } +#endif +} + /* * VT300 and up support three ANSI conformance levels, defined according to * the dpANSI X3.134.1 standard. DEC's manuals equate levels 1 and 2, and * are unclear. This code is written based on the manuals. */ static void -set_ansi_conformance(TScreen * screen, int level) +set_ansi_conformance(TScreen *screen, int level) { - TRACE(("set_ansi_conformance(%d) terminal_id %d, ansi_level %d\n", + TRACE(("set_ansi_conformance(%d) dec_level %d:%d, ansi_level %d\n", level, + screen->vtXX_level * 100, screen->terminal_id, screen->ansi_level)); if (screen->vtXX_level >= 3) { @@ -1074,13 +1123,13 @@ case 1: /* FALLTHRU */ case 2: - screen->gsets[0] = 'B'; /* G0 is ASCII */ - screen->gsets[1] = 'B'; /* G1 is ISO Latin-1 */ + screen->gsets[0] = nrc_ASCII; /* G0 is ASCII */ + screen->gsets[1] = nrc_ASCII; /* G1 is ISO Latin-1 */ screen->curgl = 0; screen->curgr = 1; break; case 3: - screen->gsets[0] = 'B'; /* G0 is ASCII */ + screen->gsets[0] = nrc_ASCII; /* G0 is ASCII */ screen->curgl = 0; break; } @@ -1092,7 +1141,7 @@ * different, so we have at least two lines in the scrolling region. */ void -set_tb_margins(TScreen * screen, int top, int bottom) +set_tb_margins(TScreen *screen, int top, int bottom) { TRACE(("set_tb_margins %d..%d, prior %d..%d\n", top, bottom, @@ -1109,7 +1158,34 @@ } void -set_max_col(TScreen * screen, int cols) +set_lr_margins(TScreen *screen, int left, int right) +{ + TRACE(("set_lr_margins %d..%d, prior %d..%d\n", + left, right, + screen->lft_marg, + screen->rgt_marg)); + if (right > left) { + screen->lft_marg = left; + screen->rgt_marg = right; + } + if (screen->lft_marg > screen->max_col) + screen->lft_marg = screen->max_col; + if (screen->rgt_marg > screen->max_col) + screen->rgt_marg = screen->max_col; +} + +#define reset_tb_margins(screen) set_tb_margins(screen, 0, screen->max_row) +#define reset_lr_margins(screen) set_lr_margins(screen, 0, screen->max_col) + +static void +reset_margins(TScreen *screen) +{ + reset_tb_margins(screen); + reset_lr_margins(screen); +} + +void +set_max_col(TScreen *screen, int cols) { TRACE(("set_max_col %d, prior %d\n", cols, screen->max_col)); if (cols < 0) @@ -1118,7 +1194,7 @@ } void -set_max_row(TScreen * screen, int rows) +set_max_row(TScreen *screen, int rows) { TRACE(("set_max_row %d, prior %d\n", rows, screen->max_row)); if (rows < 0) @@ -1138,6 +1214,9 @@ xw->keyboard.modify_now.field)); switch (which) { + case 0: + SET_MOD_FKEYS(allow_keys); + break; case 1: SET_MOD_FKEYS(cursor_keys); break; @@ -1193,6 +1272,7 @@ #endif #if OPT_WIDE_CHARS else WHICH_TABLE (esc_pct_table); + else WHICH_TABLE (scs_pct_table); #endif #if OPT_VT52_MODE else WHICH_TABLE (vt52_table); @@ -1205,6 +1285,24 @@ } #endif +#if OPT_TRACE > 0 +static void +dump_params(void) +{ + int n; + int arg; + TRACE(("params %d (%d)\n", nparam, parms.has_subparams)); + for (arg = 1, n = 0; n < nparam; ++n) { + TRACE(("%3d.%d %d\n", arg, parms.is_sub[n], parms.params[n])); + if (!parms.is_sub[n]) + ++arg; + } +} +#define DumpParams() dump_params() +#else +#define DumpParams() /* nothing */ +#endif + /* allocate larger buffer if needed/possible */ #define SafeAlloc(type, area, used, size) \ type *new_string = area; \ @@ -1269,7 +1367,7 @@ static struct ParseState myState; static void -init_groundtable(TScreen * screen, struct ParseState *sp) +init_groundtable(TScreen *screen, struct ParseState *sp) { (void) screen; @@ -1286,7 +1384,7 @@ static void select_charset(struct ParseState *sp, int type, int size) { - TRACE(("select_charset %#x %d\n", type, size)); + TRACE(("select_charset %d %d\n", type, size)); sp->scstype = type; sp->scssize = size; if (size == 94) { @@ -1296,10 +1394,306 @@ } } +static void +decode_scs(XtermWidget xw, int which, int prefix, int suffix) +{ + /* *INDENT-OFF* */ + static struct { + DECNRCM_codes result; + int prefix; + int suffix; + int min_level; + int max_level; + int need_nrc; + } table[] = { + { nrc_ASCII, 0, 'B', 1, 9, 0 }, + { nrc_British, 0, 'A', 1, 9, 0 }, + { nrc_DEC_Spec_Graphic, 0, '0', 1, 9, 0 }, + { nrc_DEC_Alt_Chars, 0, '1', 1, 1, 0 }, + { nrc_DEC_Alt_Graphics, 0, '2', 1, 1, 0 }, + /* VT2xx */ + { nrc_DEC_Supp, 0, '<', 2, 9, 0 }, + { nrc_Dutch, 0, '4', 2, 9, 1 }, + { nrc_Finnish, 0, '5', 2, 9, 1 }, + { nrc_Finnish2, 0, 'C', 2, 9, 1 }, + { nrc_French, 0, 'R', 2, 9, 1 }, + { nrc_French2, 0, 'f', 2, 9, 1 }, + { nrc_French_Canadian, 0, 'Q', 2, 9, 1 }, + { nrc_German, 0, 'K', 2, 9, 1 }, + { nrc_Italian, 0, 'Y', 2, 9, 1 }, + { nrc_Norwegian_Danish2, 0, 'E', 2, 9, 1 }, + { nrc_Norwegian_Danish3, 0, '6', 2, 9, 1 }, + { nrc_Spanish, 0, 'Z', 2, 9, 1 }, + { nrc_Swedish, 0, '7', 2, 9, 1 }, + { nrc_Swedish2, 0, 'H', 2, 9, 1 }, + { nrc_Swiss, 0, '=', 2, 9, 1 }, + /* VT3xx */ + { nrc_British_Latin_1, 0, 'A', 3, 9, 1 }, + { nrc_DEC_Supp_Graphic, '%', '5', 3, 9, 0 }, + { nrc_DEC_Technical, 0, '>', 3, 9, 0 }, + { nrc_French_Canadian2, 0, '9', 3, 9, 1 }, + { nrc_Norwegian_Danish, 0, '`', 3, 9, 1 }, + { nrc_Portugese, '%', '6', 3, 9, 1 }, +#if 0 + /* VT5xx (not implemented) */ + { nrc_Cyrillic, '&', '4', 5, 9, 0 }, + { nrc_Greek, '"', '?', 5, 9, 0 }, + { nrc_Greek_Supp, 0, 'F', 5, 9, 0 }, + { nrc_Hebrew, '"', '4', 5, 9, 0 }, + { nrc_Hebrew2, '%', '=', 5, 9, 1 }, + { nrc_Hebrew_Supp, 0, 'H', 5, 9, 0 }, + { nrc_Latin_5_Supp, 0, 'M', 5, 9, 0 }, + { nrc_Latin_Cyrillic, 0, 'L', 5, 9, 0 }, + { nrc_Russian, '&', '5', 5, 9, 1 }, + { nrc_SCS_NRCS, '%', '3', 5, 9, 0 }, + { nrc_Turkish, '%', '0', 5, 9, 0 }, + { nrc_Turkish2, '%', '2', 5, 9, 1 }, +#endif + }; + /* *INDENT-ON* */ + + TScreen *screen = TScreenOf(xw); + Cardinal n; + DECNRCM_codes result = nrc_Unknown; + + suffix &= 0x7f; + for (n = 0; n < XtNumber(table); ++n) { + if (prefix == table[n].prefix + && suffix == table[n].suffix + && screen->vtXX_level >= table[n].min_level + && screen->vtXX_level <= table[n].max_level + && (table[n].need_nrc == 0 || (xw->flags & NATIONAL) != 0)) { + result = table[n].result; + break; + } + } + if (result != nrc_Unknown) { + screen->gsets[which] = result; + TRACE(("setting G%d to %s\n", which, visibleScsCode(result))); + } else { + TRACE(("...unknown GSET\n")); + } +} + +/* + * Given a parameter number, and subparameter (starting in each case from zero) + * return the corresponding index into the parameter array. If the combination + * is not found, return -1. + */ +static int +subparam_index(int p, int s) +{ + int result = -1; + int j, p2, s2; + + for (j = p2 = 0; j < nparam; ++j, ++p2) { + if (parms.is_sub[j]) { + s2 = 0; + + do { + if ((p == p2) && (s == s2)) { + result = j; + break; + } + ++s2; + } while ((++j < nparam) && (parms.is_sub[j - 1] < parms.is_sub[j])); + + if (result >= 0) + break; + + --j; /* undo the last "while" */ + } else if (p == p2) { + if (s == 0) { + result = j; + } + break; + } + } + TRACE2(("...subparam_index %d.%d = %d\n", p + 1, s + 1, result)); + return result; +} + +/* + * Given an index into the parameter array, return the corresponding parameter + * number (starting from zero). + */ +static int +param_number(int item) +{ + int result = -1; + int j, p; + + for (j = p = 0; j < nparam; ++j, ++p) { + if (p >= item) { + result = j; + break; + } + if (parms.is_sub[j]) { + while ((++j < nparam) && (parms.is_sub[j - 1] < parms.is_sub[j])) { + /* EMPTY */ + } + --j; + } + } + + TRACE2(("...param_number(%d) = %d\n", item, result)); + return result; +} + +static int +get_subparam(int p, int s) +{ + int item = subparam_index(p, s); + int result = (item >= 0) ? parms.params[item] : DEFAULT; + TRACE(("...get_subparam[%d] = %d\n", item, result)); + return result; +} + +/* + * Check if the given item in the parameter array has subparameters. + * If so, return the number of subparameters to use as a loop limit, etc. + */ +static int +param_has_subparams(int item) +{ + int result = 0; + if (parms.has_subparams) { + int n = subparam_index(item, 0); + if (n >= 0 && parms.is_sub[n]) { + while (n++ < nparam && parms.is_sub[n - 1] < parms.is_sub[n]) { + result++; + } + } + } + TRACE(("...param_has_subparams(%d) ->%d\n", item, result)); + return result; +} + +#if OPT_256_COLORS || OPT_88_COLORS || OPT_ISO_COLORS +/* + * Some background - + * + * Todd Larason provided the initial changes to support 256-colors in July 1999. + * I pointed out that the description of SGR 38/48 in ECMA-48 was vague, and + * was unsure if there would be some standard using those codes. His response + * was that this was documented (it turns out, in equally vague terms) in ITU + * T.416 + * + * Discussing this with Todd Larason in mid-1999, my point was that given the + * high cost of obtaining ITU T.416 (ISO-8613-6), the standard was not going + * to be effective (more than $100 then, more than $200 in 2012) + * + * We overlooked the detail about ":" as a subparameter delimiter (documented + * in 5.4.t2 in ECMA-48). Some discussion in KDE in mid-2006 led Lars Doelle + * to discuss the issue with me. Lars' initial concern dealt with the fact + * that a sequence such as + * CSI 38 ; 5 ; 1 m + * violated the principle that SGR parameters could be used in any order. + * Further discussion (see KDE #107487) resolved that the standard expected + * that the sequence would look like + * CSI 38 ; 5 : 1 m + * which still violates that principle, since the "5:1" parameter has to + * follow the "38" to be useful. + * + * This function accepts either format (per request by Paul Leonerd Evans). + * It also accepts + * CSI 38 : 5 : 1 m + * according to Lars' original assumption. + * + * By the way - all of the parameters are decimal integers. + */ +#define extended_colors_limit(n) ((n) == 5 ? 1 : ((n) == 2 ? 3 : 0)) +static Boolean +parse_extended_colors(XtermWidget xw, int *colorp, int *itemp) +{ + Boolean result = False; + int item = *itemp; + int next = item; + int base = param_number(item); + int code = -1; + int values[3]; /* maximum number of subparameters */ + int need = 0; /* number of subparameters needed */ + int have; + int n; + + /* + * On entry, 'item' points to the 38/48 code in the parameter array. + * If that has subparameters, we will expect all of the values to + * be subparameters of that item. + */ + if ((have = param_has_subparams(item)) != 0) { + /* accept CSI 38 : 5 : 1 m */ + /* accept CSI 38 : 2 : 1 : 2 : 3 m */ + code = get_subparam(base, 1); + need = extended_colors_limit(code); + next = item + have; + for (n = 0; n < need && n < 3; ++n) { + values[n] = get_subparam(base, 2 + n); + } + } else if (++item < nparam) { + ++base; + if ((have = param_has_subparams(item)) != 0) { + /* accept CSI 38 ; 5 : 1 m */ + /* accept CSI 38 ; 2 : 1 : 2 : 3 m */ + code = get_subparam(base, 0); + need = extended_colors_limit(code); + next = base + have; + for (n = 0; n < need && n < 3; ++n) { + values[n] = get_subparam(base, 1 + n); + } + } else { + /* accept CSI 38 ; 5 ; 1 m */ + /* accept CSI 38 ; 2 ; 1 ; 2 ; 3 m */ + code = GetParam(item); + need = extended_colors_limit(code); + next = item + need; + for (n = 0; n < need && n < 3; ++n) { + values[n] = GetParam(item + 1 + n); + } + } + } + item = next; + + switch (code) { + case 2: + /* direct color in rgb space */ + if ((values[0] >= 0 && values[0] < 256) && + (values[1] >= 0 && values[1] < 256) && + (values[2] >= 0 && values[2] < 256)) { + *colorp = xtermClosestColor(xw, values[0], values[1], values[2]); + } else { + *colorp = -1; + } + break; + case 5: + /* indexed color */ + *colorp = values[0]; + break; + default: + *colorp = -1; + break; + } + + result = (*colorp >= 0 && *colorp < NUM_ANSI_COLORS); + TRACE(("...resulting color %d/%d %s\n", + *colorp, NUM_ANSI_COLORS, + result ? "OK" : "ERR")); + + *itemp = item; + return result; +} +#endif /* ...extended_colors */ + +static int +optional_param(int which) +{ + return (nparam > which) ? GetParam(which) : DEFAULT; +} + static int zero_if_default(int which) { - int result = (nparam > which) ? param[which] : 0; + int result = (nparam > which) ? GetParam(which) : 0; if (result <= 0) result = 0; return result; @@ -1308,19 +1702,60 @@ static int one_if_default(int which) { - int result = (nparam > which) ? param[which] : 0; + int result = (nparam > which) ? GetParam(which) : 0; if (result <= 0) result = 1; return result; } +/* + * Color palette changes using the OSC controls require a repaint of the + * screen - but not immediately. Do the repaint as soon as we detect a + * state which will not lead to another color palette change. + */ +static void +repaintWhenPaletteChanged(XtermWidget xw, struct ParseState *sp) +{ + Boolean ignore = False; + + switch (sp->nextstate) { + case CASE_ESC: + ignore = ((sp->parsestate == ansi_table) || + (sp->parsestate == sos_table)); + break; + case CASE_OSC: + ignore = ((sp->parsestate == ansi_table) || + (sp->parsestate == esc_table)); + break; + case CASE_IGNORE: + ignore = (sp->parsestate == sos_table); + break; + case CASE_ST: + ignore = ((sp->parsestate == esc_table) || + (sp->parsestate == sos_table)); + break; + case CASE_ESC_DIGIT: + ignore = (sp->parsestate == csi_table); + break; + case CASE_ESC_SEMI: + ignore = (sp->parsestate == csi2_table); + break; + } + + if (!ignore) { + TRACE(("repaintWhenPaletteChanged\n")); + xw->misc.palette_changed = False; + xtermRepaint(xw); + } +} + #if OPT_C1_PRINT || OPT_WIDE_CHARS #define ParseSOS(screen) ((screen)->c1_printable == 0) #else #define ParseSOS(screen) 0 #endif -#define ResetState(sp) (sp)->parsestate = (sp)->groundtable +#define ResetState(sp) ParamsDone(), (sp)->parsestate = (sp)->groundtable static void illegal_parse(XtermWidget xw, unsigned c, struct ParseState *sp) @@ -1344,15 +1779,20 @@ ResetState(sp); } +static void +init_reply(unsigned type) +{ + memset(&reply, 0, sizeof(reply)); + reply.a_type = (Char) type; +} + static Boolean doparsing(XtermWidget xw, unsigned c, struct ParseState *sp) { TScreen *screen = TScreenOf(xw); - int row; - int col; - int top; - int bot; + int item; int count; + int value; int laststate; int thischar = -1; XTermRect myRect; @@ -1367,39 +1807,63 @@ * character sets do not use this feature. There are some unassigned * codes at 0x242, but no zero-width characters until past 0x300. */ - if (c >= 0x300 && screen->wide_chars - && my_wcwidth((int) c) == 0 + if (c >= 0x300 + && screen->wide_chars + && my_wcwidth((wchar_t) c) == 0 && !isWideControl(c)) { - int prev, precomposed; + int prev, test; + Boolean used = True; + int use_row; + int use_col; WriteNow(); + use_row = (screen->char_was_written + ? screen->last_written_row + : screen->cur_row); + use_col = (screen->char_was_written + ? screen->last_written_col + : screen->cur_col); - prev = (int) XTERM_CELL(screen->last_written_row, - screen->last_written_col); - precomposed = do_precomposition(prev, (int) c); - TRACE(("do_precomposition (U+%04X [%d], U+%04X [%d]) -> U+%04X [%d]\n", - prev, my_wcwidth(prev), - (int) c, my_wcwidth((int) c), - precomposed, my_wcwidth(precomposed))); + /* + * Check if the latest data can be added to the base character. + * If there is already a combining character stored for the cell, + * we cannot, since that would change the order. + */ + if (screen->normalized_c + && !IsCellCombined(screen, use_row, use_col)) { + prev = (int) XTERM_CELL(use_row, use_col); + test = do_precomposition(prev, (int) c); + TRACE(("do_precomposition (U+%04X [%d], U+%04X [%d]) -> U+%04X [%d]\n", + prev, my_wcwidth((wchar_t) prev), + (int) c, my_wcwidth((wchar_t) c), + test, my_wcwidth((wchar_t) test))); + } else { + prev = -1; + test = -1; + } /* substitute combined character with precomposed character * only if it does not change the width of the base character */ - if (precomposed != -1 && my_wcwidth(precomposed) == my_wcwidth(prev)) { - putXtermCell(screen, - screen->last_written_row, - screen->last_written_col, precomposed); + if (test != -1 + && my_wcwidth((wchar_t) test) == my_wcwidth((wchar_t) prev)) { + putXtermCell(screen, use_row, use_col, test); + } else if (screen->char_was_written + || getXtermCell(screen, use_row, use_col) > ' ') { + addXtermCombining(screen, use_row, use_col, c); } else { - addXtermCombining(screen, - screen->last_written_row, - screen->last_written_col, c); + /* + * none of the above... we will add the combining character as + * a base character. + */ + used = False; } - if (!screen->scroll_amt) - ScrnUpdate(xw, - screen->last_written_row, - screen->last_written_col, 1, 1, 1); - continue; + if (used) { + if (!screen->scroll_amt) + ScrnUpdate(xw, use_row, use_col, 1, 1, 1); + continue; + } } #endif @@ -1416,19 +1880,17 @@ */ #if OPT_VT52_MODE if (sp->vt52_cup) { - if (nparam < NPARAM) - param[nparam++] = (int) (c & 0x7f) - 32; + if (nparam < NPARAM - 1) { + SetParam(nparam++, (int) (c & 0x7f) - 32); + parms.is_sub[nparam] = 0; + } if (nparam < 2) continue; sp->vt52_cup = False; - if ((row = param[0]) < 0) - row = 0; - if ((col = param[1]) < 0) - col = 0; - CursorSet(screen, row, col, xw->flags); + CursorSet(screen, zero_if_default(0), zero_if_default(1), xw->flags); sp->parsestate = vt52_table; - param[0] = 0; - param[1] = 0; + SetParam(0, 0); + SetParam(1, 0); continue; } #endif @@ -1630,7 +2092,61 @@ sp->string_used = 0; } - TRACE(("parse %04X -> %d %s\n", c, sp->nextstate, which_table(sp->parsestate))); + DumpParams(); + TRACE(("parse %04X -> %d %s (used=%lu)\n", + c, sp->nextstate, + which_table(sp->parsestate), + (unsigned long) sp->string_used)); + + /* + * If the parameter list has subparameters (tokens separated by ":") + * reject any controls that do not accept subparameters. + */ + if (parms.has_subparams) { + switch (sp->nextstate) { + case CASE_GROUND_STATE: + case CASE_CSI_IGNORE: + /* FALLTHRU */ + + case CASE_ESC_DIGIT: + case CASE_ESC_SEMI: + case CASE_ESC_COLON: + /* these states are required to parse parameter lists */ + break; + + case CASE_SGR: + TRACE(("...possible subparam usage\n")); + break; + + case CASE_CSI_DEC_DOLLAR_STATE: + case CASE_CSI_DOLLAR_STATE: + case CASE_CSI_EX_STATE: + case CASE_CSI_QUOTE_STATE: + case CASE_CSI_SPACE_STATE: + case CASE_CSI_STAR_STATE: + case CASE_CSI_TICK_STATE: + case CASE_DEC2_STATE: + case CASE_DEC3_STATE: + case CASE_DEC_STATE: + /* use this branch when we do not yet have the final character */ + TRACE(("...unexpected subparam usage\n")); + ParamsDone(); + sp->nextstate = CASE_CSI_IGNORE; + break; + + default: + /* use this branch for cases where we have the final character + * in the table that processed the parameter list. + */ + TRACE(("...unexpected subparam usage\n")); + ResetState(sp); + continue; + } + } + + if (xw->misc.palette_changed) { + repaintWhenPaletteChanged(xw, sp); + } switch (sp->nextstate) { case CASE_PRINT: @@ -1672,8 +2188,8 @@ break; case CASE_CR: - /* CR */ - CarriageReturn(screen); + TRACE(("CASE_CR\n")); + CarriageReturn(xw); break; case CASE_ESC: @@ -1688,7 +2204,7 @@ case CASE_VT52_CUP: TRACE(("CASE_VT52_CUP - VT52 cursor addressing\n")); sp->vt52_cup = True; - nparam = 0; + InitParams(); break; case CASE_VT52_IGNORE: @@ -1698,30 +2214,31 @@ #endif case CASE_VMOT: + TRACE(("CASE_VMOT\n")); /* * form feed, line feed, vertical tab */ xtermAutoPrint(xw, c); xtermIndex(xw, 1); if (xw->flags & LINEFEED) - CarriageReturn(screen); + CarriageReturn(xw); else do_xevents(); break; case CASE_CBT: + TRACE(("CASE_CBT\n")); /* cursor backward tabulation */ - if ((count = param[0]) == DEFAULT) - count = 1; + count = one_if_default(0); while ((count-- > 0) && (TabToPrevStop(xw))) ; ResetState(sp); break; case CASE_CHT: + TRACE(("CASE_CHT\n")); /* cursor forward tabulation */ - if ((count = param[0]) == DEFAULT) - count = 1; + count = one_if_default(0); while ((count-- > 0) && (TabToNextStop(xw))) ; ResetState(sp); @@ -1809,11 +2326,10 @@ case CASE_ESC_DIGIT: /* digit in csi or dec mode */ if (nparam > 0) { - if ((row = param[nparam - 1]) == DEFAULT) - row = 0; - param[nparam - 1] = (10 * row) + ((int) c - '0'); - if (param[nparam - 1] > 65535) - param[nparam - 1] = 65535; + value = zero_if_default(nparam - 1); + SetParam(nparam - 1, (10 * value) + ((int) c - '0')); + if (GetParam(nparam - 1) > 65535) + SetParam(nparam - 1, 65535); if (sp->parsestate == csi_table) sp->parsestate = csi2_table; } @@ -1821,12 +2337,38 @@ case CASE_ESC_SEMI: /* semicolon in csi or dec mode */ - if (nparam < NPARAM) - param[nparam++] = DEFAULT; + if (nparam < NPARAM) { + parms.is_sub[nparam] = 0; + SetParam(nparam++, DEFAULT); + } if (sp->parsestate == csi_table) sp->parsestate = csi2_table; break; + /* + * A _few_ commands accept colon-separated subparameters. + * Mark the parameter list so that we can exclude (most) bogus + * commands with simple/fast checks. + */ + case CASE_ESC_COLON: + if (nparam < NPARAM) { + parms.has_subparams = 1; + if (nparam == 0) { + parms.is_sub[nparam] = 1; + SetParam(nparam++, DEFAULT); + } else if (parms.is_sub[nparam - 1] == 0) { + parms.is_sub[nparam - 1] = 1; + parms.is_sub[nparam] = 2; + parms.params[nparam] = 0; + ++nparam; + } else { + parms.is_sub[nparam] = 1 + parms.is_sub[nparam - 1]; + parms.params[nparam] = 0; + ++nparam; + } + } + break; + case CASE_DEC_STATE: /* enter dec mode */ sp->parsestate = dec_table; @@ -1844,41 +2386,31 @@ case CASE_ICH: TRACE(("CASE_ICH - insert char\n")); - if ((row = param[0]) < 1) - row = 1; - InsertChar(xw, (unsigned) row); + InsertChar(xw, (unsigned) one_if_default(0)); ResetState(sp); break; case CASE_CUU: TRACE(("CASE_CUU - cursor up\n")); - if ((row = param[0]) < 1) - row = 1; - CursorUp(screen, row); + CursorUp(screen, one_if_default(0)); ResetState(sp); break; case CASE_CUD: TRACE(("CASE_CUD - cursor down\n")); - if ((row = param[0]) < 1) - row = 1; - CursorDown(screen, row); + CursorDown(screen, one_if_default(0)); ResetState(sp); break; case CASE_CUF: TRACE(("CASE_CUF - cursor forward\n")); - if ((col = param[0]) < 1) - col = 1; - CursorForward(screen, col); + CursorForward(xw, one_if_default(0)); ResetState(sp); break; case CASE_CUB: TRACE(("CASE_CUB - cursor backward\n")); - if ((col = param[0]) < 1) - col = 1; - CursorBack(xw, col); + CursorBack(xw, one_if_default(0)); ResetState(sp); break; @@ -1887,27 +2419,37 @@ if_OPT_XMC_GLITCH(screen, { Jump_XMC(xw); }); - if ((row = param[0]) < 1) - row = 1; - if (nparam < 2 || (col = param[1]) < 1) - col = 1; - CursorSet(screen, row - 1, col - 1, xw->flags); + CursorSet(screen, one_if_default(0) - 1, one_if_default(1) - 1, xw->flags); ResetState(sp); break; case CASE_VPA: - TRACE(("CASE_VPA - vertical position\n")); - if ((row = param[0]) < 1) - row = 1; - CursorSet(screen, row - 1, screen->cur_col, xw->flags); + TRACE(("CASE_VPA - vertical position absolute\n")); + CursorSet(screen, one_if_default(0) - 1, CursorCol(xw), xw->flags); ResetState(sp); break; case CASE_HPA: - TRACE(("CASE_HPA - horizontal position\n")); - if ((col = param[0]) < 1) - col = 1; - CursorSet(screen, screen->cur_row, col - 1, xw->flags); + TRACE(("CASE_HPA - horizontal position absolute\n")); + CursorSet(screen, CursorRow(xw), one_if_default(0) - 1, xw->flags); + ResetState(sp); + break; + + case CASE_VPR: + TRACE(("CASE_VPR - vertical position relative\n")); + CursorSet(screen, + CursorRow(xw) + one_if_default(0), + CursorCol(xw), + xw->flags); + ResetState(sp); + break; + + case CASE_HPR: + TRACE(("CASE_HPR - horizontal position relative\n")); + CursorSet(screen, + CursorRow(xw), + CursorCol(xw) + one_if_default(0), + xw->flags); ResetState(sp); break; @@ -1923,44 +2465,41 @@ case CASE_ED: TRACE(("CASE_ED - erase display\n")); - do_erase_display(xw, param[0], OFF_PROTECT); + do_cd_xtra_scroll(xw); + do_erase_display(xw, zero_if_default(0), OFF_PROTECT); ResetState(sp); break; case CASE_EL: TRACE(("CASE_EL - erase line\n")); - do_erase_line(xw, param[0], OFF_PROTECT); + do_erase_line(xw, zero_if_default(0), OFF_PROTECT); ResetState(sp); break; case CASE_ECH: TRACE(("CASE_ECH - erase char\n")); /* ECH */ - ClearRight(xw, param[0] < 1 ? 1 : param[0]); + ClearRight(xw, one_if_default(0)); ResetState(sp); break; case CASE_IL: TRACE(("CASE_IL - insert line\n")); - if ((row = param[0]) < 1) - row = 1; - InsertLine(xw, row); + set_cur_col(screen, ScrnLeftMargin(xw)); + InsertLine(xw, one_if_default(0)); ResetState(sp); break; case CASE_DL: TRACE(("CASE_DL - delete line\n")); - if ((row = param[0]) < 1) - row = 1; - DeleteLine(xw, row); + set_cur_col(screen, ScrnLeftMargin(xw)); + DeleteLine(xw, one_if_default(0)); ResetState(sp); break; case CASE_DCH: TRACE(("CASE_DCH - delete char\n")); - if ((row = param[0]) < 1) - row = 1; - DeleteChar(xw, (unsigned) row); + DeleteChar(xw, (unsigned) one_if_default(0)); ResetState(sp); break; @@ -1970,7 +2509,7 @@ * A zero-parameter is used to reset the mouse mode, and is * not useful for scrolling anyway. */ - if (nparam > 1 || param[0] == 0) { + if (nparam > 1 || GetParam(0) == 0) { CELL start; TRACE(("CASE_TRACK_MOUSE\n")); @@ -1978,17 +2517,15 @@ * specified rows */ start.row = one_if_default(2) - 1; - start.col = param[1] - 1; + start.col = GetParam(1) - 1; TrackMouse(xw, - param[0], + GetParam(0), &start, - param[3] - 1, param[4] - 2); + GetParam(3) - 1, GetParam(4) - 2); } else { TRACE(("CASE_SD - scroll down\n")); /* SD */ - if ((count = param[0]) < 1) - count = 1; - RevScroll(xw, count); + RevScroll(xw, one_if_default(0)); do_xevents(); } ResetState(sp); @@ -2004,24 +2541,30 @@ ResetState(sp); break; }); - param[0] = DEFAULT; /* Default ID parameter */ + SetParam(0, DEFAULT); /* Default ID parameter */ /* FALLTHRU */ case CASE_DA1: TRACE(("CASE_DA1\n")); - if (param[0] <= 0) { /* less than means DEFAULT */ + if (GetParam(0) <= 0) { /* less than means DEFAULT */ count = 0; - reply.a_type = ANSI_CSI; + init_reply(ANSI_CSI); reply.a_pintro = '?'; - /* The first param corresponds to the highest - * operating level (i.e., service level) of the - * emulation. A DEC terminal can be setup to - * respond with a different DA response, but - * there's no control sequence that modifies this. - * We set it via a resource. + /* + * The first parameter corresponds to the highest operating + * level (i.e., service level) of the emulation. A DEC + * terminal can be setup to respond with a different DA + * response, but there's no control sequence that modifies + * this. We set it via a resource. */ if (screen->terminal_id < 200) { switch (screen->terminal_id) { + case 125: + reply.a_param[count++] = 12; /* VT125 */ + reply.a_param[count++] = 0 | 2 | 0; /* no STP, AVO, no GPO (ReGIS) */ + reply.a_param[count++] = 0; /* no printer */ + reply.a_param[count++] = XTERM_PATCH; /* ROM version */ + break; case 102: reply.a_param[count++] = 6; /* VT102 */ break; @@ -2031,7 +2574,7 @@ break; default: /* VT100 */ reply.a_param[count++] = 1; /* VT100 */ - reply.a_param[count++] = 2; /* AVO */ + reply.a_param[count++] = 0 | 2 | 0; /* no STP, AVO, no GPO (ReGIS) */ break; } } else { @@ -2040,6 +2583,15 @@ / 100); reply.a_param[count++] = 1; /* 132-columns */ reply.a_param[count++] = 2; /* printer */ +#if OPT_SIXEL_GRAPHICS + if (screen->terminal_id == 240 || + screen->terminal_id == 241 || + screen->terminal_id == 330 || + screen->terminal_id == 340) { + reply.a_param[count++] = 3; /* ReGIS graphics */ + reply.a_param[count++] = 4; /* sixel graphics */ + } +#endif reply.a_param[count++] = 6; /* selective-erase */ #if OPT_SUNPC_KBD if (xw->keyboard.type == keyboardIsVT220) @@ -2047,6 +2599,10 @@ reply.a_param[count++] = 8; /* user-defined-keys */ reply.a_param[count++] = 9; /* national replacement charsets */ reply.a_param[count++] = 15; /* technical characters */ + if (screen->terminal_id >= 400) { + reply.a_param[count++] = 18; /* windowing capability */ + reply.a_param[count++] = 21; /* horizontal scrolling */ + } if_OPT_ISO_COLORS(screen, { reply.a_param[count++] = 22; /* ANSI color, VT525 */ }); @@ -2064,15 +2620,48 @@ case CASE_DA2: TRACE(("CASE_DA2\n")); - if (param[0] <= 0) { /* less than means DEFAULT */ + if (GetParam(0) <= 0) { /* less than means DEFAULT */ count = 0; - reply.a_type = ANSI_CSI; + init_reply(ANSI_CSI); reply.a_pintro = '>'; - if (screen->terminal_id >= 200) - reply.a_param[count++] = 1; /* VT220 */ - else + if (screen->terminal_id >= 200) { + switch (screen->terminal_id) { + case 220: + default: + reply.a_param[count++] = 1; /* VT220 */ + break; + case 240: + /* http://www.decuslib.com/DECUS/vax87a/gendyn/vt200_kind.lis */ + reply.a_param[count++] = 2; /* VT240 */ + break; + case 320: + /* http://www.vt100.net/docs/vt320-uu/appendixe.html */ + reply.a_param[count++] = 24; /* VT320 */ + break; + case 330: + reply.a_param[count++] = 18; /* VT330 */ + break; + case 340: + reply.a_param[count++] = 19; /* VT340 */ + break; + case 420: + reply.a_param[count++] = 41; /* VT420 */ + break; + case 510: + /* http://www.vt100.net/docs/vt510-rm/DA2 */ + reply.a_param[count++] = 61; /* VT510 */ + break; + case 520: + reply.a_param[count++] = 64; /* VT520 */ + break; + case 525: + reply.a_param[count++] = 65; /* VT525 */ + break; + } + } else { reply.a_param[count++] = 0; /* VT100 (nonstandard) */ + } reply.a_param[count++] = XTERM_PATCH; /* Version */ reply.a_param[count++] = 0; /* options (none) */ reply.a_nparam = (ParmType) count; @@ -2085,8 +2674,8 @@ case CASE_DECRPTUI: TRACE(("CASE_DECRPTUI\n")); - if ((screen->terminal_id >= 400) - && (param[0] <= 0)) { /* less than means DEFAULT */ + if ((screen->vtXX_level >= 4) + && (GetParam(0) <= 0)) { /* less than means DEFAULT */ unparseputc1(xw, ANSI_DCS); unparseputc(xw, '!'); unparseputc(xw, '|'); @@ -2099,9 +2688,9 @@ case CASE_TBC: TRACE(("CASE_TBC - tab clear\n")); - if ((row = param[0]) <= 0) /* less than means default */ + if ((value = GetParam(0)) <= 0) /* less than means default */ TabClear(xw->tabs, screen->cur_col); - else if (row == 3) + else if (value == 3) TabZonk(xw->tabs); ResetState(sp); break; @@ -2119,12 +2708,34 @@ break; case CASE_SGR: - for (row = 0; row < nparam; ++row) { + for (item = 0; item < nparam; ++item) { + int op = GetParam(item); + if_OPT_XMC_GLITCH(screen, { - Mark_XMC(xw, param[row]); + Mark_XMC(xw, op); }); - TRACE(("CASE_SGR %d\n", param[row])); - switch (param[row]) { + TRACE(("CASE_SGR %d\n", op)); + + /* + * Only SGR 38/48 accept subparameters, and in those cases + * the values will not be seen at this point. + */ + if (param_has_subparams(item)) { + switch (op) { + case 38: + case 48: + if_OPT_ISO_COLORS(screen, { + break; + }); + default: + TRACE(("...unexpected subparameter in SGR\n")); + op = 9999; + ResetState(sp); + break; + } + } + + switch (op) { case DEFAULT: case 0: UIntClr(xw->flags, @@ -2197,33 +2808,20 @@ case 36: case 37: if_OPT_ISO_COLORS(screen, { - xw->sgr_foreground = (param[row] - 30); + xw->sgr_foreground = (op - 30); xw->sgr_extended = False; setExtendedFG(xw); }); break; case 38: - /* This is more complicated than I'd - like, but it should properly eat all - the parameters for unsupported modes + /* This is more complicated than I'd like, but it should + * properly eat all the parameters for unsupported modes. */ if_OPT_ISO_COLORS(screen, { - row++; - if (row < nparam) { - switch (param[row]) { - case 5: - row++; - if (row < nparam && - param[row] < NUM_ANSI_COLORS) { - xw->sgr_foreground = param[row]; - xw->sgr_extended = True; - setExtendedFG(xw); - } - break; - default: - row += 7; - break; - } + if (parse_extended_colors(xw, &value, &item)) { + xw->sgr_foreground = value; + xw->sgr_extended = True; + setExtendedFG(xw); } }); break; @@ -2241,27 +2839,15 @@ case 46: case 47: if_OPT_ISO_COLORS(screen, { - xw->sgr_background = (param[row] - 40); + xw->sgr_background = (op - 40); setExtendedBG(xw); }); break; case 48: if_OPT_ISO_COLORS(screen, { - row++; - if (row < nparam) { - switch (param[row]) { - case 5: - row++; - if (row < nparam && - param[row] < NUM_ANSI_COLORS) { - xw->sgr_background = param[row]; - setExtendedBG(xw); - } - break; - default: - row += 7; - break; - } + if (parse_extended_colors(xw, &value, &item)) { + xw->sgr_background = value; + setExtendedBG(xw); } }); break; @@ -2279,7 +2865,7 @@ case 96: case 97: if_OPT_AIX_COLORS(screen, { - xw->sgr_foreground = (param[row] - 90 + 8); + xw->sgr_foreground = (op - 90 + 8); xw->sgr_extended = False; setExtendedFG(xw); }); @@ -2300,7 +2886,7 @@ case 106: case 107: if_OPT_AIX_COLORS(screen, { - xw->sgr_background = (param[row] - 100 + 8); + xw->sgr_background = (op - 100 + 8); setExtendedBG(xw); }); break; @@ -2315,51 +2901,75 @@ /* FALLTHRU */ case CASE_CPR: - TRACE(("CASE_CPR - cursor position\n")); + TRACE(("CASE_DSR - device status report\n")); count = 0; - reply.a_type = ANSI_CSI; + init_reply(ANSI_CSI); reply.a_pintro = CharOf(sp->private_function ? '?' : 0); reply.a_inters = 0; reply.a_final = 'n'; - switch (param[0]) { + switch (GetParam(0)) { case 5: + TRACE(("...request operating status\n")); /* operating status */ reply.a_param[count++] = 0; /* (no malfunction ;-) */ break; case 6: + TRACE(("...request %s\n", + (sp->private_function + ? "DECXCPR" + : "CPR"))); /* CPR */ - /* DECXCPR (with page=0) */ - reply.a_param[count++] = (ParmType) (screen->cur_row + 1); - reply.a_param[count++] = (ParmType) (screen->cur_col + 1); + /* DECXCPR (with page=1) */ + value = (screen->cur_row + 1); + if ((xw->flags & ORIGIN) != 0) { + value -= screen->top_marg; + } + reply.a_param[count++] = (ParmType) value; + + value = (screen->cur_col + 1); + if ((xw->flags & ORIGIN) != 0) { + value -= screen->lft_marg; + } + reply.a_param[count++] = (ParmType) value; + + if (sp->private_function + && screen->vtXX_level >= 4) { /* VT420 */ + reply.a_param[count++] = 1; + } reply.a_final = 'R'; break; case 15: - /* printer status */ - if (screen->terminal_id >= 200) { /* VT220 */ - reply.a_param[count++] = 13; /* implement printer */ + TRACE(("...request printer status\n")); + if (sp->private_function + && screen->vtXX_level >= 2) { /* VT220 */ + reply.a_param[count++] = 13; /* no printer detected */ } break; case 25: - /* UDK status */ - if (screen->terminal_id >= 200) { /* VT220 */ + TRACE(("...request UDK status\n")); + if (sp->private_function + && screen->vtXX_level >= 2) { /* VT220 */ reply.a_param[count++] = 20; /* UDK always unlocked */ } break; case 26: - /* keyboard status */ - if (screen->terminal_id >= 200) { /* VT220 */ + TRACE(("...request keyboard status\n")); + if (sp->private_function + && screen->vtXX_level >= 2) { /* VT220 */ reply.a_param[count++] = 27; reply.a_param[count++] = 1; /* North American */ - if (screen->terminal_id >= 400) { + if (screen->vtXX_level >= 4) { /* VT420 */ reply.a_param[count++] = 0; /* ready */ reply.a_param[count++] = 0; /* LK201 */ } } break; - case 53: - /* Locator status */ - if (screen->terminal_id >= 200) { /* VT220 */ + case 53: /* according to existing xterm handling */ + case 55: /* according to the VT330/VT340 Text Programming Manual */ + TRACE(("...request locator status\n")); + if (sp->private_function + && screen->vtXX_level >= 2) { /* VT220 */ #if OPT_DEC_LOCATOR reply.a_param[count++] = 50; /* locator ready */ #else @@ -2367,6 +2977,55 @@ #endif } break; + case 56: + TRACE(("...request locator type\n")); + if (sp->private_function + && screen->vtXX_level >= 3) { /* VT330 (FIXME: what about VT220?) */ + reply.a_param[count++] = 57; +#if OPT_DEC_LOCATOR + reply.a_param[count++] = 1; /* mouse */ +#else + reply.a_param[count++] = 0; /* unknown */ +#endif + } + break; + case 62: + TRACE(("...request DECMSR - macro space\n")); + if (sp->private_function + && screen->vtXX_level >= 4) { /* VT420 */ + reply.a_pintro = 0; + reply.a_radix[count] = 16; /* no data */ + reply.a_param[count++] = 0; /* no space for macros */ + reply.a_inters = '*'; + reply.a_final = '{'; + } + break; + case 63: + TRACE(("...request DECCKSR - memory checksum\n")); + /* DECCKSR - Memory checksum */ + if (sp->private_function + && screen->vtXX_level >= 4) { /* VT420 */ + init_reply(ANSI_DCS); + reply.a_param[count++] = (ParmType) GetParam(1); /* PID */ + reply.a_delim = "!~"; /* delimiter */ + reply.a_radix[count] = 16; /* use hex */ + reply.a_param[count++] = 0; /* no data */ + } + break; + case 75: + TRACE(("...request data integrity\n")); + if (sp->private_function + && screen->vtXX_level >= 4) { /* VT420 */ + reply.a_param[count++] = 70; /* no errors */ + } + break; + case 85: + TRACE(("...request multi-session configuration\n")); + if (sp->private_function + && screen->vtXX_level >= 4) { /* VT420 */ + reply.a_param[count++] = 83; /* not configured */ + } + break; default: break; } @@ -2380,13 +3039,13 @@ case CASE_MC: TRACE(("CASE_MC - media control\n")); - xtermMediaControl(xw, param[0], False); + xtermMediaControl(xw, GetParam(0), False); ResetState(sp); break; case CASE_DEC_MC: TRACE(("CASE_DEC_MC - DEC media control\n")); - xtermMediaControl(xw, param[0], True); + xtermMediaControl(xw, GetParam(0), True); ResetState(sp); break; @@ -2406,31 +3065,33 @@ case CASE_DECSTBM: TRACE(("CASE_DECSTBM - set scrolling region\n")); - if ((top = param[0]) < 1) - top = 1; - if (nparam < 2 || (bot = param[1]) == DEFAULT - || bot > MaxRows(screen) - || bot == 0) - bot = MaxRows(screen); - if (bot > top) { - if (screen->scroll_amt) - FlushScroll(xw); - set_tb_margins(screen, top - 1, bot - 1); - CursorSet(screen, 0, 0, xw->flags); + { + int top; + int bot; + top = one_if_default(0); + if (nparam < 2 || (bot = GetParam(1)) == DEFAULT + || bot > MaxRows(screen) + || bot == 0) + bot = MaxRows(screen); + if (bot > top) { + if (screen->scroll_amt) + FlushScroll(xw); + set_tb_margins(screen, top - 1, bot - 1); + CursorSet(screen, 0, 0, xw->flags); + } + ResetState(sp); } - ResetState(sp); break; case CASE_DECREQTPARM: TRACE(("CASE_DECREQTPARM\n")); if (screen->terminal_id < 200) { /* VT102 */ - if ((row = param[0]) == DEFAULT) - row = 0; - if (row == 0 || row == 1) { - reply.a_type = ANSI_CSI; + value = zero_if_default(0); + if (value == 0 || value == 1) { + init_reply(ANSI_CSI); reply.a_pintro = 0; reply.a_nparam = 7; - reply.a_param[0] = (ParmType) (row + 2); + reply.a_param[0] = (ParmType) (value + 2); reply.a_param[1] = 1; /* no parity */ reply.a_param[2] = 1; /* eight bits */ reply.a_param[3] = 128; /* transmit 38.4k baud */ @@ -2469,7 +3130,7 @@ TRACE(("CASE_DECALN - alignment test\n")); if (screen->cursor_state) HideCursor(); - set_tb_margins(screen, 0, screen->max_row); + reset_margins(screen); CursorSet(screen, 0, 0, xw->flags); xtermParseRect(xw, 0, 0, &myRect); ScrnFillRectangle(xw, &myRect, 'E', 0, False); @@ -2478,8 +3139,29 @@ case CASE_GSETS: TRACE(("CASE_GSETS(%d) = '%c'\n", sp->scstype, c)); - if (screen->vtXX_level != 0) - screen->gsets[sp->scstype] = CharOf(c); + decode_scs(xw, sp->scstype, 0, (int) c); + ResetState(sp); + break; + + case CASE_ANSI_SC: + if (IsLeftRightMode(xw)) { + int left; + int right; + + TRACE(("CASE_DECSLRM - set left and right margin\n")); + left = one_if_default(0); + if (nparam < 2 || (right = GetParam(1)) == DEFAULT + || right > MaxCols(screen) + || right == 0) + right = MaxCols(screen); + if (right > left) { + set_lr_margins(screen, left - 1, right - 1); + CursorSet(screen, 0, 0, xw->flags); + } + } else { + TRACE(("CASE_ANSI_SC - save cursor\n")); + CursorSave(xw); + } ResetState(sp); break; @@ -2489,8 +3171,10 @@ ResetState(sp); break; + case CASE_ANSI_RC: case CASE_DECRC: - TRACE(("CASE_DECRC - restore cursor\n")); + TRACE(("CASE_%sRC - restore cursor\n", + (sp->nextstate == CASE_DECRC) ? "DEC" : "ANSI_")); CursorRestore(xw); if_OPT_ISO_COLORS(screen, { setExtendedFG(xw); @@ -2525,32 +3209,36 @@ TRACE(("CASE_DECSCUSR\n")); { Boolean change = True; - Boolean blinks = screen->cursor_blink; + Boolean blinks = screen->cursor_blink_esc; HideCursor(); - switch (param[0]) { - case 0: - case 1: + switch (GetParam(0)) { case DEFAULT: - /* blinking block */ - screen->cursor_underline = False; + case DEFAULT_STYLE: + case BLINK_BLOCK: blinks = True; + screen->cursor_shape = CURSOR_BLOCK; break; - case 2: - /* steady block */ - screen->cursor_underline = False; + case STEADY_BLOCK: blinks = False; + screen->cursor_shape = CURSOR_BLOCK; break; - case 3: - /* blinking underline */ - screen->cursor_underline = True; + case BLINK_UNDERLINE: blinks = True; + screen->cursor_shape = CURSOR_UNDERLINE; break; - case 4: - /* steady underline */ - screen->cursor_underline = True; + case STEADY_UNDERLINE: + blinks = False; + screen->cursor_shape = CURSOR_UNDERLINE; + break; + case BLINK_BAR: + blinks = True; + screen->cursor_shape = CURSOR_BAR; + break; + case STEADY_BAR: blinks = False; + screen->cursor_shape = CURSOR_BAR; break; default: change = False; @@ -2559,7 +3247,8 @@ if (change) { xtermSetCursorBox(screen); - SetCursorBlink(screen, blinks); + screen->cursor_blink_esc = blinks; + UpdateCursorBlink(screen); } } ResetState(sp); @@ -2571,7 +3260,8 @@ TRACE(("CASE_DECLL\n")); if (nparam > 0) { for (count = 0; count < nparam; ++count) { - switch (param[count]) { + int op = zero_if_default(count); + switch (op) { case 0: case DEFAULT: xtermClearLEDs(screen); @@ -2579,12 +3269,16 @@ case 1: case 2: case 3: - xtermShowLED(screen, (Cardinal) param[count], True); + xtermShowLED(screen, + (Cardinal) op, + True); break; case 21: case 22: case 23: - xtermShowLED(screen, (Cardinal) (param[count] - 20), True); + xtermShowLED(screen, + (Cardinal) (op - 20), + True); break; } } @@ -2604,7 +3298,11 @@ && screen->vtXX_level == 0) { sp->groundtable = sp->parsestate = ansi_table; - screen->vtXX_level = screen->vt52_save_level; + /* + * On restore, the terminal does not recognize DECRQSS for + * DECSCL (per vttest). + */ + screen->vtXX_level = 1; screen->curgl = screen->vt52_save_curgl; screen->curgr = screen->vt52_save_curgr; screen->curss = screen->vt52_save_curss; @@ -2632,25 +3330,37 @@ break; case CASE_DECSCL: - TRACE(("CASE_DECSCL(%d,%d)\n", param[0], param[1])); - if (param[0] >= 61 && param[0] <= 65) { + TRACE(("CASE_DECSCL(%d,%d)\n", GetParam(0), GetParam(1))); + /* + * This changes the emulation level, and is not recognized by + * VT100s. + */ + if (screen->terminal_id >= 200) { /* - * VT300, VT420, VT520 manuals claim that DECSCL does a hard - * reset (RIS). VT220 manual states that it is a soft reset. - * Perhaps both are right (unlikely). Kermit says it's soft. + * Disallow unrecognized parameters, as well as attempts to set + * the operating level higher than the given terminal-id. */ - ReallyReset(xw, False, False); - init_parser(xw, sp); - screen->vtXX_level = param[0] - 60; - if (param[0] > 61) { - switch (zero_if_default(1)) { - case 1: - show_8bit_control(False); - break; - case 0: - case 2: - show_8bit_control(True); - break; + if (GetParam(0) >= 61 + && GetParam(0) <= 60 + (screen->terminal_id / 100)) { + /* + * VT300, VT420, VT520 manuals claim that DECSCL does a + * hard reset (RIS). VT220 manual states that it is a soft + * reset. Perhaps both are right (unlikely). Kermit says + * it's soft. + */ + ReallyReset(xw, False, False); + init_parser(xw, sp); + screen->vtXX_level = GetParam(0) - 60; + if (GetParam(0) > 61) { + switch (zero_if_default(1)) { + case 1: + show_8bit_control(False); + break; + case 0: + case 2: + show_8bit_control(True); + break; + } } } } @@ -2660,27 +3370,32 @@ case CASE_DECSCA: TRACE(("CASE_DECSCA\n")); screen->protected_mode = DEC_PROTECT; - if (param[0] <= 0 || param[0] == 2) + if (GetParam(0) <= 0 || GetParam(0) == 2) { UIntClr(xw->flags, PROTECTED); - else if (param[0] == 1) + TRACE(("...clear PROTECTED\n")); + } else if (GetParam(0) == 1) { xw->flags |= PROTECTED; + TRACE(("...set PROTECTED\n")); + } ResetState(sp); break; case CASE_DECSED: TRACE(("CASE_DECSED\n")); - do_erase_display(xw, param[0], DEC_PROTECT); + do_erase_display(xw, zero_if_default(0), DEC_PROTECT); ResetState(sp); break; case CASE_DECSEL: TRACE(("CASE_DECSEL\n")); - do_erase_line(xw, param[0], DEC_PROTECT); + do_erase_line(xw, zero_if_default(0), DEC_PROTECT); ResetState(sp); break; case CASE_ST: - TRACE(("CASE_ST: End of String (%lu bytes)\n", (unsigned long) sp->string_used)); + TRACE(("CASE_ST: End of String (%lu bytes) (mode=%d)\n", + (unsigned long) sp->string_used, + sp->string_mode)); ResetState(sp); if (!sp->string_used) break; @@ -2701,6 +3416,9 @@ case ANSI_SOS: /* ignored */ break; + default: + TRACE(("unknown mode\n")); + break; } break; @@ -2755,51 +3473,43 @@ case CASE_SU: TRACE(("CASE_SU - scroll up\n")); - if ((count = param[0]) < 1) - count = 1; - xtermScroll(xw, count); + xtermScroll(xw, one_if_default(0)); ResetState(sp); break; case CASE_SL: /* ISO 6429, non-DEC */ TRACE(("CASE_SL - scroll left\n")); - if ((count = param[0]) < 1) - count = 1; - xtermScrollLR(xw, count, True); + xtermScrollLR(xw, one_if_default(0), True); ResetState(sp); break; case CASE_SR: /* ISO 6429, non-DEC */ TRACE(("CASE_SR - scroll right\n")); - if ((count = param[0]) < 1) - count = 1; - xtermScrollLR(xw, count, False); + xtermScrollLR(xw, one_if_default(0), False); ResetState(sp); break; case CASE_DECDC: TRACE(("CASE_DC - delete column\n")); - if (screen->terminal_id >= 400) { - if ((count = param[0]) < 1) - count = 1; - xtermColScroll(xw, count, True, screen->cur_col); + if (screen->vtXX_level >= 4 + && IsLeftRightMode(xw)) { + xtermColScroll(xw, one_if_default(0), True, screen->cur_col); } ResetState(sp); break; case CASE_DECIC: TRACE(("CASE_IC - insert column\n")); - if (screen->terminal_id >= 400) { - if ((count = param[0]) < 1) - count = 1; - xtermColScroll(xw, count, False, screen->cur_col); + if (screen->vtXX_level >= 4 + && IsLeftRightMode(xw)) { + xtermColScroll(xw, one_if_default(0), False, screen->cur_col); } ResetState(sp); break; case CASE_DECBI: TRACE(("CASE_BI - back index\n")); - if (screen->terminal_id >= 400) { + if (screen->vtXX_level >= 4) { xtermColIndex(xw, True); } ResetState(sp); @@ -2807,7 +3517,7 @@ case CASE_DECFI: TRACE(("CASE_FI - forward index\n")); - if (screen->terminal_id >= 400) { + if (screen->vtXX_level >= 4) { xtermColIndex(xw, False); } ResetState(sp); @@ -2822,20 +3532,20 @@ case CASE_CPL: TRACE(("CASE_CPL - cursor prev line\n")); - CursorPrevLine(screen, param[0]); + CursorPrevLine(xw, one_if_default(0)); ResetState(sp); break; case CASE_CNL: TRACE(("CASE_CNL - cursor next line\n")); - CursorNextLine(screen, param[0]); + CursorNextLine(xw, one_if_default(0)); ResetState(sp); break; case CASE_NEL: TRACE(("CASE_NEL\n")); xtermIndex(xw, 1); - CarriageReturn(screen); + CarriageReturn(xw); ResetState(sp); break; @@ -2865,8 +3575,8 @@ case CASE_CSI_STATE: /* enter csi state */ - nparam = 1; - param[0] = DEFAULT; + InitParams(); + SetParam(nparam++, DEFAULT); sp->parsestate = csi_table; break; @@ -2890,13 +3600,16 @@ TRACE(("CASE_DECEFR - Enable Filter Rectangle\n")); if (screen->send_mouse_pos == DEC_LOCATOR) { MotionOff(screen, xw); - if ((screen->loc_filter_top = param[0]) < 1) + if ((screen->loc_filter_top = GetParam(0)) < 1) screen->loc_filter_top = LOC_FILTER_POS; - if (nparam < 2 || (screen->loc_filter_left = param[1]) < 1) + if (nparam < 2 + || (screen->loc_filter_left = GetParam(1)) < 1) screen->loc_filter_left = LOC_FILTER_POS; - if (nparam < 3 || (screen->loc_filter_bottom = param[2]) < 1) + if (nparam < 3 + || (screen->loc_filter_bottom = GetParam(2)) < 1) screen->loc_filter_bottom = LOC_FILTER_POS; - if (nparam < 4 || (screen->loc_filter_right = param[3]) < 1) + if (nparam < 4 + || (screen->loc_filter_right = GetParam(3)) < 1) screen->loc_filter_right = LOC_FILTER_POS; InitLocatorFilter(xw); } @@ -2905,19 +3618,19 @@ case CASE_DECELR: MotionOff(screen, xw); - if (param[0] <= 0 || param[0] > 2) { + if (GetParam(0) <= 0 || GetParam(0) > 2) { screen->send_mouse_pos = MOUSE_OFF; TRACE(("DECELR - Disable Locator Reports\n")); } else { TRACE(("DECELR - Enable Locator Reports\n")); screen->send_mouse_pos = DEC_LOCATOR; xtermShowPointer(xw, True); - if (param[0] == 2) { + if (GetParam(0) == 2) { screen->locator_reset = True; } else { screen->locator_reset = False; } - if (nparam < 2 || param[1] != 1) { + if (nparam < 2 || GetParam(1) != 1) { screen->locator_pixels = False; } else { screen->locator_pixels = True; @@ -2930,8 +3643,7 @@ case CASE_DECSLE: TRACE(("DECSLE - Select Locator Events\n")); for (count = 0; count < nparam; ++count) { - switch (param[count]) { - case DEFAULT: + switch (zero_if_default(count)) { case 0: MotionOff(screen, xw); screen->loc_filter = False; @@ -2956,7 +3668,7 @@ case CASE_DECRQLP: TRACE(("DECRQLP - Request Locator Position\n")); - if (param[0] < 2) { + if (GetParam(0) < 2) { /* Issue DECLRP Locator Position Report */ GetLocatorPosition(xw); } @@ -2983,11 +3695,29 @@ sp->parsestate = eigtable; break; + case CASE_DECRQCRA: + if (screen->vtXX_level >= 4) { + int checksum; + + TRACE(("CASE_DECRQCRA - Request checksum of rectangular area\n")); + xtermCheckRect(xw, ParamPair(0), &checksum); + init_reply(ANSI_DCS); + count = 0; + reply.a_param[count++] = (ParmType) GetParam(1); /* PID */ + reply.a_delim = "!~"; /* delimiter */ + reply.a_radix[count] = 16; + reply.a_param[count++] = (ParmType) checksum; + reply.a_nparam = (ParmType) count; + unparseseq(xw, &reply); + } + ResetState(sp); + break; + case CASE_DECCRA: if (screen->vtXX_level >= 4) { TRACE(("CASE_DECCRA - Copy rectangular area\n")); - xtermParseRect(xw, nparam, param, &myRect); - ScrnCopyRectangle(xw, &myRect, nparam - 5, param + 5); + xtermParseRect(xw, ParamPair(0), &myRect); + ScrnCopyRectangle(xw, &myRect, ParamPair(5)); } ResetState(sp); break; @@ -2995,7 +3725,7 @@ case CASE_DECERA: if (screen->vtXX_level >= 4) { TRACE(("CASE_DECERA - Erase rectangular area\n")); - xtermParseRect(xw, nparam, param, &myRect); + xtermParseRect(xw, ParamPair(0), &myRect); ScrnFillRectangle(xw, &myRect, ' ', 0, True); } ResetState(sp); @@ -3003,12 +3733,14 @@ case CASE_DECFRA: if (screen->vtXX_level >= 4) { + value = zero_if_default(0); + TRACE(("CASE_DECFRA - Fill rectangular area\n")); if (nparam > 0 - && ((param[0] >= 32 && param[0] <= 126) - || (param[0] >= 160 && param[0] <= 255))) { - xtermParseRect(xw, nparam - 1, param + 1, &myRect); - ScrnFillRectangle(xw, &myRect, param[0], xw->flags, True); + && ((value >= 32 && value <= 126) + || (value >= 160 && value <= 255))) { + xtermParseRect(xw, ParamPair(1), &myRect); + ScrnFillRectangle(xw, &myRect, value, xw->flags, True); } } ResetState(sp); @@ -3017,7 +3749,7 @@ case CASE_DECSERA: if (screen->vtXX_level >= 4) { TRACE(("CASE_DECSERA - Selective erase rectangular area\n")); - xtermParseRect(xw, nparam > 4 ? 4 : nparam, param, &myRect); + xtermParseRect(xw, ParamPair(0), &myRect); ScrnWipeRectangle(xw, &myRect); } ResetState(sp); @@ -3025,15 +3757,15 @@ case CASE_DECSACE: TRACE(("CASE_DECSACE - Select attribute change extent\n")); - screen->cur_decsace = param[0]; + screen->cur_decsace = zero_if_default(0); ResetState(sp); break; case CASE_DECCARA: if (screen->vtXX_level >= 4) { TRACE(("CASE_DECCARA - Change attributes in rectangular area\n")); - xtermParseRect(xw, nparam > 4 ? 4 : nparam, param, &myRect); - ScrnMarkRectangle(xw, &myRect, False, nparam - 4, param + 4); + xtermParseRect(xw, ParamPair(0), &myRect); + ScrnMarkRectangle(xw, &myRect, False, ParamPair(4)); } ResetState(sp); break; @@ -3041,21 +3773,21 @@ case CASE_DECRARA: if (screen->vtXX_level >= 4) { TRACE(("CASE_DECRARA - Reverse attributes in rectangular area\n")); - xtermParseRect(xw, nparam > 4 ? 4 : nparam, param, &myRect); - ScrnMarkRectangle(xw, &myRect, True, nparam - 4, param + 4); + xtermParseRect(xw, ParamPair(0), &myRect); + ScrnMarkRectangle(xw, &myRect, True, ParamPair(4)); } ResetState(sp); break; case CASE_RQM: TRACE(("CASE_RQM\n")); - do_rpm(xw, nparam, param); + do_rpm(xw, ParamPair(0)); ResetState(sp); break; case CASE_DECRQM: TRACE(("CASE_DECRQM\n")); - do_decrpm(xw, nparam, param); + do_decrpm(xw, ParamPair(0)); ResetState(sp); break; @@ -3083,18 +3815,22 @@ case CASE_S7C1T: TRACE(("CASE_S7C1T\n")); - show_8bit_control(False); - ResetState(sp); + if (screen->vtXX_level >= 2) { + show_8bit_control(False); + ResetState(sp); + } break; case CASE_S8C1T: TRACE(("CASE_S8C1T\n")); + if (screen->vtXX_level >= 2) { #if OPT_VT52_MODE - if (screen->vtXX_level <= 1) - break; + if (screen->vtXX_level <= 1) + break; #endif - show_8bit_control(True); - ResetState(sp); + show_8bit_control(True); + ResetState(sp); + } break; case CASE_OSC: @@ -3121,7 +3857,7 @@ sp->lastchar < 256 && sp->groundtable[E2A(sp->lastchar)] == CASE_PRINT) { IChar repeated[2]; - count = (param[0] < 1) ? 1 : param[0]; + count = one_if_default(0); repeated[0] = (IChar) sp->lastchar; while (count-- > 0) { dotext(xw, @@ -3179,6 +3915,7 @@ break; #if OPT_WIDE_CHARS case CASE_ESC_PERCENT: + TRACE(("CASE_ESC_PERCENT\n")); sp->parsestate = esc_pct_table; break; @@ -3205,21 +3942,37 @@ } ResetState(sp); break; + + case CASE_SCS_PERCENT: + TRACE(("CASE_SCS_PERCENT\n")); + sp->parsestate = scs_pct_table; + break; + + case CASE_GSETS_PERCENT: + TRACE(("CASE_GSETS_PERCENT(%d) = '%c'\n", sp->scstype, c)); + decode_scs(xw, sp->scstype, '%', (int) c); + ResetState(sp); + break; #endif #if OPT_MOD_FKEYS case CASE_SET_MOD_FKEYS: TRACE(("CASE_SET_MOD_FKEYS\n")); if (nparam >= 1) { - set_mod_fkeys(xw, param[0], nparam > 1 ? param[1] : DEFAULT, True); + set_mod_fkeys(xw, + GetParam(0), + ((nparam > 1) + ? GetParam(1) + : DEFAULT), + True); } else { - for (row = 1; row <= 5; ++row) - set_mod_fkeys(xw, row, DEFAULT, True); + for (value = 1; value <= 5; ++value) + set_mod_fkeys(xw, value, DEFAULT, True); } break; case CASE_SET_MOD_FKEYS0: TRACE(("CASE_SET_MOD_FKEYS0\n")); - if (nparam >= 1 && param[0] != DEFAULT) { - set_mod_fkeys(xw, param[0], -1, False); + if (nparam >= 1 && GetParam(0) != DEFAULT) { + set_mod_fkeys(xw, GetParam(0), -1, False); } else { xw->keyboard.modify_now.function_keys = -1; } @@ -3227,8 +3980,8 @@ #endif case CASE_HIDE_POINTER: TRACE(("CASE_HIDE_POINTER\n")); - if (nparam >= 1 && param[0] != DEFAULT) { - screen->pointer_mode = param[0]; + if (nparam >= 1 && GetParam(0) != DEFAULT) { + screen->pointer_mode = GetParam(0); } else { screen->pointer_mode = DEF_POINTER_MODE; } @@ -3239,8 +3992,8 @@ if (nparam >= 1) { int n; for (n = 0; n < nparam; ++n) { - if (param[n] != DEFAULT) - screen->title_modes |= (1 << param[n]); + if (GetParam(n) != DEFAULT) + screen->title_modes |= (1 << GetParam(n)); } } else { screen->title_modes = DEF_TITLE_MODES; @@ -3253,8 +4006,8 @@ if (nparam >= 1) { int n; for (n = 0; n < nparam; ++n) { - if (param[n] != DEFAULT) - screen->title_modes &= ~(1 << param[n]); + if (GetParam(n) != DEFAULT) + screen->title_modes &= ~(1 << GetParam(n)); } } else { screen->title_modes = DEF_TITLE_MODES; @@ -3268,7 +4021,7 @@ case CASE_DECSWBV: TRACE(("CASE_DECSWBV\n")); - switch ((nparam >= 1) ? param[0] : DEFAULT) { + switch (zero_if_default(0)) { case 2: case 3: case 4: @@ -3290,14 +4043,13 @@ case CASE_DECSMBV: TRACE(("CASE_DECSMBV\n")); - switch ((nparam >= 1) ? param[0] : DEFAULT) { + switch (zero_if_default(0)) { case 2: case 3: case 4: screen->marginVolume = bvLow; break; case 0: - case DEFAULT: case 5: case 6: case 7: @@ -3344,26 +4096,29 @@ or generated by us in response to a query ESC sequence. */ void -v_write(int f, const Char * data, unsigned len) +v_write(int f, const Char *data, unsigned len) { int riten; TRACE2(("v_write(%d:%s)\n", len, visibleChars(data, len))); - if (v_bufstr == NULL && len > 0) { - v_buffer = (Char *) XtMalloc((Cardinal) len); - v_bufstr = v_buffer; - v_bufptr = v_buffer; - v_bufend = v_buffer + len; - } -#ifdef DEBUG - if (debug) { - fprintf(stderr, "v_write called with %d bytes (%d left over)", - len, v_bufptr - v_bufstr); + if (v_bufstr == NULL) { + if (len > 0) { + v_buffer = (Char *) XtMalloc((Cardinal) len); + v_bufstr = v_buffer; + v_bufptr = v_buffer; + v_bufend = v_buffer + len; + } + if (v_bufstr == NULL) { + return; + } + } + if_DEBUG({ + fprintf(stderr, "v_write called with %d bytes (%ld left over)", + len, (long) (v_bufptr - v_bufstr)); if (len > 1 && len < 10) fprintf(stderr, " \"%.*s\"", len, (const char *) data); fprintf(stderr, "\n"); - } -#endif + }); #ifdef VMS if ((1 << f) != pty_mask) { @@ -3394,11 +4149,10 @@ if (v_bufstr != v_buffer) { /* there is unused space, move everything down */ /* possibly overlapping memmove here */ -#ifdef DEBUG - if (debug) - fprintf(stderr, "moving data down %d\n", - v_bufstr - v_buffer); -#endif + if_DEBUG({ + fprintf(stderr, "moving data down %ld\n", + (long) (v_bufstr - v_buffer)); + }); memmove(v_buffer, v_bufstr, (size_t) (v_bufptr - v_bufstr)); v_bufptr -= v_bufstr - v_buffer; v_bufstr = v_buffer; @@ -3409,11 +4163,10 @@ unsigned size = (unsigned) (v_bufptr - v_buffer); v_buffer = TypeRealloc(Char, size + len, v_buffer); if (v_buffer) { -#ifdef DEBUG - if (debug) + if_DEBUG({ fprintf(stderr, "expanded buffer to %d\n", size + len); -#endif + }); v_bufstr = v_buffer; v_bufptr = v_buffer + size; v_bufend = v_bufptr + len; @@ -3464,19 +4217,18 @@ if (riten < 0) #endif /* VMS */ { -#ifdef DEBUG - if (debug) + if_DEBUG({ perror("write"); -#endif + }); riten = 0; } -#ifdef DEBUG - if (debug) - fprintf(stderr, "write called with %d, wrote %d\n", - v_bufptr - v_bufstr <= MAX_PTY_WRITE ? - v_bufptr - v_bufstr : MAX_PTY_WRITE, + if_DEBUG({ + fprintf(stderr, "write called with %ld, wrote %d\n", + ((long) ((v_bufptr - v_bufstr) <= MAX_PTY_WRITE) + ? (long) (v_bufptr - v_bufstr) + : MAX_PTY_WRITE), riten); -#endif + }); v_bufstr += riten; if (v_bufstr >= v_bufptr) /* we wrote it all */ v_bufstr = v_bufptr = v_buffer; @@ -3496,10 +4248,9 @@ v_bufstr = v_buffer + start; v_bufptr = v_buffer + size; v_bufend = v_buffer + allocsize; -#ifdef DEBUG - if (debug) + if_DEBUG({ fprintf(stderr, "shrunk buffer to %d\n", allocsize); -#endif + }); } else { /* should we print a warning if couldn't return memory? */ v_buffer = v_bufstr - start; /* restore clobbered pointer */ @@ -3508,7 +4259,7 @@ } static void -updateCursor(TScreen * screen) +updateCursor(TScreen *screen) { if (screen->cursor_set != screen->cursor_state) { if (screen->cursor_set) @@ -3520,7 +4271,7 @@ #if OPT_BLINK_CURS || OPT_BLINK_TEXT static void -reallyStopBlinking(TScreen * screen) +reallyStopBlinking(TScreen *screen) { if (screen->cursor_state == BLINKED_OFF) { /* force cursor to display if it is enabled */ @@ -3630,6 +4381,9 @@ int i, time_select; int size; int update = VTbuffer->update; +#if OPT_DOUBLE_BUFFER + int should_wait = 1; +#endif static struct timeval select_timeout; @@ -3661,7 +4415,21 @@ FD_CLR(screen->respond, &select_mask); break; } -#if defined(HAVE_SCHED_YIELD) +#if OPT_DOUBLE_BUFFER + if (should_wait) { + /* wait 25 msec for potential extra data (avoids some bogus flickering) */ + /* that's only 40 FPS but hey, it's still lower than the input lag on some consoles! :) */ + usleep(25000); + should_wait = 0; + } + select_timeout.tv_sec = 0; + i = Select(max_plus1, &select_mask, &write_mask, 0, + &select_timeout); + if (i > 0 && FD_ISSET(screen->respond, &select_mask)) + continue; + else + break; +#elif defined(HAVE_SCHED_YIELD) /* * If we've read a full (small/fragment) buffer, let the operating * system have a turn, and we'll resume reading until we've either @@ -3673,7 +4441,7 @@ select_timeout.tv_sec = 0; i = Select(max_plus1, &select_mask, &write_mask, 0, &select_timeout); - if (i > 0) { + if (i > 0 && FD_ISSET(screen->respond, &select_mask)) { sched_yield(); } else break; @@ -3747,7 +4515,17 @@ #endif } if (need_cleanup) - Cleanup(0); + NormalExit(); +#if OPT_DOUBLE_BUFFER + if (screen->needSwap) { + XdbeSwapInfo swap; + swap.swap_window = VWindow(screen); + swap.swap_action = XdbeCopied; + XdbeSwapBuffers(XtDisplay(term), &swap, 1); + XFlush(XtDisplay(xw)); + screen->needSwap = 0; + } +#endif i = Select(max_plus1, &select_mask, &write_mask, 0, (time_select ? &select_timeout : 0)); if (i < 0) { @@ -3797,7 +4575,7 @@ XPoint spot; XVaNestedList list; - if (input->xic + if (input && input->xic && (ld = getLineData(screen, screen->cur_row)) != 0) { spot.x = (short) LineCursorX(screen, ld, screen->cur_col); spot.y = (short) (CursorY(screen, screen->cur_row) + xw->misc.xim_fs_ascent); @@ -3826,7 +4604,7 @@ } xtermAutoPrint(xw, '\n'); xtermIndex(xw, 1); - set_cur_col(screen, 0); + set_cur_col(screen, ScrnLeftMargin(xw)); } } @@ -3837,7 +4615,7 @@ void dotext(XtermWidget xw, int charset, - IChar * buf, /* start of characters to process */ + IChar *buf, /* start of characters to process */ Cardinal len) /* end */ { TScreen *screen = TScreenOf(xw); @@ -3848,13 +4626,17 @@ int next_col, last_col, this_col; /* must be signed */ #endif Cardinal offset; + int right = ScrnRightMargin(xw); -#if OPT_WIDE_CHARS - /* don't translate if we use UTF-8, and are not handling legacy support - * for line-drawing characters. + /* + * It is possible to use CUP, etc., to move outside margins. In that + * case, the right-margin is ineffective. */ - if ((screen->utf8_mode == uFalse) - || (screen->vt100_graphics)) + if (screen->cur_col > right) { + right = screen->max_col; + } +#if OPT_WIDE_CHARS + if (screen->vt100_graphics) #endif if (!xtermCharSetOut(xw, buf, buf + len, charset)) return; @@ -3873,59 +4655,85 @@ for (offset = 0; offset < len && (chars_chomped > 0 || screen->do_wrap); offset += chars_chomped) { - int width_available = MaxCols(screen) - screen->cur_col; + int width_available = right + 1 - screen->cur_col; int width_here = 0; - Boolean need_wrap = False; + Boolean force_wrap; + Boolean need_wrap; + Boolean did_wrap; int last_chomp = 0; chars_chomped = 0; - if (screen->do_wrap) { - screen->do_wrap = False; - if ((xw->flags & WRAPAROUND)) { - WrapLine(xw); - width_available = MaxCols(screen) - screen->cur_col; - next_col = screen->cur_col; + do { + force_wrap = False; + need_wrap = False; + did_wrap = False; + + if (screen->do_wrap) { + screen->do_wrap = False; + if ((xw->flags & WRAPAROUND)) { + WrapLine(xw); + width_available = right + 1 - screen->cur_col; + next_col = screen->cur_col; + did_wrap = True; + } } - } - while (width_here <= width_available && chars_chomped < (len - offset)) { - if (!screen->utf8_mode - || (screen->vt100_graphics && charset == '0')) - last_chomp = 1; - else - last_chomp = my_wcwidth((int) buf[chars_chomped + offset]); - width_here += last_chomp; - chars_chomped++; - } + /* + * This can happen with left/right margins... + */ + if (width_available <= 0) { + break; + } + + while (width_here <= width_available + && chars_chomped < (len - offset)) { + if (!screen->utf8_mode + || (screen->vt100_graphics && charset == '0')) { + last_chomp = 1; + } else { + last_chomp = my_wcwidth((wchar_t) buf[chars_chomped + offset]); + } + width_here += last_chomp; + chars_chomped++; + } - if (width_here > width_available) { - if (last_chomp > MaxCols(screen)) - break; /* give up - it is too big */ - chars_chomped--; - width_here -= last_chomp; - if (chars_chomped > 0) { + if (width_here > width_available) { + if (last_chomp > right + 1) { + break; /* give up - it is too big */ + } else if (chars_chomped-- == 0) { + /* This can happen with left/right margins... */ + break; + } + width_here -= last_chomp; + if (chars_chomped > 0) { + need_wrap = True; + } + } else if (width_here == width_available) { + need_wrap = True; + } else if (chars_chomped != (len - offset)) { need_wrap = True; } - } else if (width_here == width_available) { - need_wrap = True; - } else if (chars_chomped != (len - offset)) { - need_wrap = True; - } - /* - * Split the wide characters back into separate arrays of 8-bit - * characters so we can use the existing interface. - * - * FIXME: If we rewrote this interface, it would involve - * rewriting all of the memory-management for the screen - * buffers (perhaps this is simpler). - */ - if (chars_chomped != 0 && next_col <= screen->max_col) { - WriteText(xw, buf + offset, chars_chomped); - } - next_col += width_here; - screen->do_wrap = need_wrap; + if (chars_chomped != 0 && next_col <= screen->max_col) { + WriteText(xw, buf + offset, chars_chomped); + } else if (!did_wrap + && (xw->flags & WRAPAROUND) + && screen->cur_col > ScrnLeftMargin(xw)) { + force_wrap = True; + need_wrap = True; + } + next_col += width_here; + screen->do_wrap = need_wrap; + } while (force_wrap); } + + /* + * Remember that we wrote something to the screen, for use as a base of + * combining characters. The logic above may have called cursor-forward + * or carriage-return operations which resets this flag, so we set it at + * the very end. + */ + screen->char_was_written = True; #else /* ! OPT_WIDE_CHARS */ for (offset = 0; offset < len; offset += (Cardinal) this_col) { @@ -3934,6 +4742,8 @@ #endif last_col = LineMaxCol(screen, ld); + if (last_col > (right + 1)) + last_col = right + 1; this_col = last_col - screen->cur_col + 1; if (this_col <= 1) { if (screen->do_wrap) { @@ -3964,7 +4774,7 @@ #if OPT_WIDE_CHARS unsigned -visual_width(IChar * str, Cardinal len) +visual_width(IChar *str, Cardinal len) { /* returns the visual width of a string (doublewide characters count as 2, normalwide characters count as 1) */ @@ -3988,36 +4798,14 @@ HandleStructNotify(Widget w GCC_UNUSED, XtPointer closure GCC_UNUSED, XEvent * event, - Boolean * cont GCC_UNUSED) + Boolean *cont GCC_UNUSED) { - static char *icon_name; - static Arg args[] = - { - {XtNiconName, (XtArgVal) & icon_name} - }; XtermWidget xw = term; - TScreen *screen = TScreenOf(xw); switch (event->type) { case MapNotify: TRACE(("HandleStructNotify(MapNotify)\n")); -#if OPT_ZICONBEEP - if (screen->zIconBeep_flagged) { - screen->zIconBeep_flagged = False; - icon_name = NULL; - XtGetValues(toplevel, args, XtNumber(args)); - if (icon_name != NULL) { - char *buf = CastMallocN(char, strlen(icon_name)); - if (buf == NULL) { - screen->zIconBeep_flagged = True; - return; - } - strcpy(buf, icon_name + 4); - ChangeIconName(xw, buf); - free(buf); - } - } -#endif /* OPT_ZICONBEEP */ + resetZIconBeep(xw); mapstate = !IsUnmapped; break; case UnmapNotify: @@ -4062,14 +4850,14 @@ save.menu_border)); /* - * Window manager still may be using the old values. + * Window manager still may be using the old values. * Try to fool it. */ REQ_RESIZE((Widget) xw, - screen->fullVwin.fullwidth, + TScreenOf(xw)->fullVwin.fullwidth, (Dimension) (info->menu_height - save.menu_height - + screen->fullVwin.fullheight), + + TScreenOf(xw)->fullVwin.fullheight), NULL, NULL); repairSizeHints(); } @@ -4094,7 +4882,7 @@ #if OPT_BLINK_CURS static void -SetCursorBlink(TScreen * screen, Bool enable) +SetCursorBlink(TScreen *screen, Bool enable) { screen->cursor_blink = (Boolean) enable; if (DoStartBlinking(screen)) { @@ -4111,7 +4899,7 @@ } void -ToggleCursorBlink(TScreen * screen) +ToggleCursorBlink(TScreen *screen) { SetCursorBlink(screen, (Bool) (!(screen->cursor_blink))); } @@ -4126,7 +4914,7 @@ int i; for (i = 0; i < nparam; ++i) { - switch (param[i]) { + switch (GetParam(i)) { case 2: /* KAM (if set, keyboard locked */ (*func) (&xw->keyboard.flags, MODE_KAM); break; @@ -4181,14 +4969,17 @@ int i, j; unsigned myflags; + TRACE(("changing %d DEC private modes\n", nparam)); for (i = 0; i < nparam; ++i) { - TRACE(("%s %d\n", IsSM()? "DECSET" : "DECRST", param[i])); - switch (param[i]) { - case 1: /* DECCKM */ + int code = GetParam(i); + + TRACE(("%s %d\n", IsSM()? "DECSET" : "DECRST", code)); + switch ((DECSET_codes) code) { + case srm_DECCKM: (*func) (&xw->keyboard.flags, MODE_DECCKM); update_appcursor(); break; - case 2: /* DECANM - ANSI/VT52 mode */ + case srm_DECANM: /* ANSI/VT52 mode */ if (IsSM()) { /* ANSI (VT100) */ /* * Setting DECANM should have no effect, since this function @@ -4201,29 +4992,33 @@ TRACE(("DECANM terminal_id %d, vtXX_level %d\n", screen->terminal_id, screen->vtXX_level)); - screen->vt52_save_level = screen->vtXX_level; screen->vtXX_level = 0; screen->vt52_save_curgl = screen->curgl; screen->vt52_save_curgr = screen->curgr; screen->vt52_save_curss = screen->curss; memmove(screen->vt52_save_gsets, screen->gsets, sizeof(screen->gsets)); resetCharsets(screen); - nparam = 0; /* ignore the remaining params, if any */ + InitParams(); /* ignore the remaining params, if any */ } #endif break; - case 3: /* DECCOLM */ + case srm_DECCOLM: if (screen->c132) { - ClearScreen(xw); + if (!(xw->flags & NOCLEAR_COLM)) + ClearScreen(xw); CursorSet(screen, 0, 0, xw->flags); if ((j = IsSM()? 132 : 80) != ((xw->flags & IN132COLUMNS) ? 132 : 80) || j != MaxCols(screen)) RequestResize(xw, -1, j, True); (*func) (&xw->flags, IN132COLUMNS); + if (xw->flags & IN132COLUMNS) { + UIntClr(xw->flags, LEFT_RIGHT); + reset_lr_margins(screen); + } } break; - case 4: /* DECSCLM (slow scroll) */ + case srm_DECSCLM: /* (slow scroll) */ if (IsSM()) { screen->jumpscroll = 0; if (screen->scroll_amt) @@ -4233,7 +5028,7 @@ (*func) (&xw->flags, SMOOTHSCROLL); update_jumpscroll(); break; - case 5: /* DECSCNM */ + case srm_DECSCNM: myflags = xw->flags; (*func) (&xw->flags, REVERSE_VIDEO); if ((xw->flags ^ myflags) & REVERSE_VIDEO) @@ -4241,87 +5036,92 @@ /* update_reversevideo done in RevVid */ break; - case 6: /* DECOM */ + case srm_DECOM: (*func) (&xw->flags, ORIGIN); CursorSet(screen, 0, 0, xw->flags); break; - case 7: /* DECAWM */ + case srm_DECAWM: (*func) (&xw->flags, WRAPAROUND); update_autowrap(); break; - case 8: /* DECARM */ + case srm_DECARM: /* ignore autorepeat * XAutoRepeatOn() and XAutoRepeatOff() can do this, but only * for the whole display - not limited to a given window. */ break; - case SET_X10_MOUSE: /* MIT bogus sequence */ + case srm_X10_MOUSE: /* MIT bogus sequence */ MotionOff(screen, xw); set_mousemode(X10_MOUSE); break; #if OPT_TOOLBAR - case 10: /* rxvt */ + case srm_RXVT_TOOLBAR: ShowToolbar(IsSM()); break; #endif #if OPT_BLINK_CURS - case 12: /* att610: Start/stop blinking cursor */ + case srm_ATT610_BLINK: /* att610: Start/stop blinking cursor */ if (screen->cursor_blink_res) { set_bool_mode(screen->cursor_blink_esc); - SetCursorBlink(screen, screen->cursor_blink); + UpdateCursorBlink(screen); } break; #endif - case 18: /* DECPFF: print form feed */ + case srm_DECPFF: /* print form feed */ set_bool_mode(PrinterOf(screen).printer_formfeed); break; - case 19: /* DECPEX: print extent */ + case srm_DECPEX: /* print extent */ set_bool_mode(PrinterOf(screen).printer_extent); break; - case 25: /* DECTCEM: Show/hide cursor (VT200) */ + case srm_DECTCEM: /* Show/hide cursor (VT200) */ set_bool_mode(screen->cursor_set); break; - case 30: /* rxvt */ + case srm_RXVT_SCROLLBAR: if (screen->fullVwin.sb_info.width != (IsSM()? ON : OFF)) ToggleScrollBar(xw); break; #if OPT_SHIFT_FONTS - case 35: /* rxvt */ + case srm_RXVT_FONTSIZE: set_bool_mode(xw->misc.shift_fonts); break; #endif - case 38: /* DECTEK */ #if OPT_TEK4014 + case srm_DECTEK: if (IsSM() && !(screen->inhibit & I_TEK)) { FlushLog(xw); TEK4014_ACTIVE(xw) = True; + update_vttekmode(); } -#endif break; - case 40: /* 132 column mode */ +#endif + case srm_132COLS: /* 132 column mode */ set_bool_mode(screen->c132); update_allow132(); break; - case 41: /* curses hack */ + case srm_CURSES_HACK: set_bool_mode(screen->curses); update_cursesemul(); break; - case 42: /* DECNRCM national charset (VT220) */ - (*func) (&xw->flags, NATIONAL); + case srm_DECNRCM: /* national charset (VT220) */ + if (screen->vtXX_level >= 2) { + if ((*func) (&xw->flags, NATIONAL)) { + modified_DECNRCM(xw); + } + } break; - case 44: /* margin bell */ + case srm_MARGIN_BELL: /* margin bell */ set_bool_mode(screen->marginbell); if (!screen->marginbell) screen->bellArmed = -1; update_marginbell(); break; - case 45: /* reverse wraparound */ + case srm_REVERSEWRAP: /* reverse wraparound */ (*func) (&xw->flags, REVERSEWRAP); update_reversewrap(); break; #ifdef ALLOWLOGGING - case 46: /* logging */ + case srm_ALLOWLOGGING: /* logging */ #ifdef ALLOWLOGFILEONOFF /* * if this feature is enabled, logging may be @@ -4337,64 +5137,89 @@ #endif /* ALLOWLOGFILEONOFF */ break; #endif - case 1049: /* alternate buffer & cursor */ + case srm_OPT_ALTBUF_CURSOR: /* alternate buffer & cursor */ if (!xw->misc.titeInhibit) { if (IsSM()) { CursorSave(xw); - ToAlternate(xw); + ToAlternate(xw, True); ClearScreen(xw); } else { FromAlternate(xw); CursorRestore(xw); } - } else if (xw->misc.tiXtraScroll) { - if (IsSM()) { - xtermScroll(xw, screen->max_row); - } + } else if (IsSM()) { + do_ti_xtra_scroll(xw); } break; - case 1047: + case srm_OPT_ALTBUF: /* FALLTHRU */ - case 47: /* alternate buffer */ + case srm_ALTBUF: /* alternate buffer */ if (!xw->misc.titeInhibit) { if (IsSM()) { - ToAlternate(xw); + ToAlternate(xw, False); } else { if (screen->whichBuf - && (param[i] == 1047)) + && (code == 1047)) ClearScreen(xw); FromAlternate(xw); } - } else if (xw->misc.tiXtraScroll) { - if (IsSM()) { - xtermScroll(xw, screen->max_row); - } + } else if (IsSM()) { + do_ti_xtra_scroll(xw); } break; - case 66: /* DECNKM */ + case srm_DECNKM: (*func) (&xw->keyboard.flags, MODE_DECKPAM); update_appkeypad(); break; - case 67: /* DECBKM */ + case srm_DECBKM: /* back-arrow mapped to backspace or delete(D) */ (*func) (&xw->keyboard.flags, MODE_DECBKM); TRACE(("DECSET DECBKM %s\n", BtoS(xw->keyboard.flags & MODE_DECBKM))); update_decbkm(); break; - case SET_VT200_MOUSE: /* xterm bogus sequence */ + case srm_DECLRMM: + if (screen->vtXX_level >= 4) { /* VT420 */ + (*func) (&xw->flags, LEFT_RIGHT); + if (IsLeftRightMode(xw)) { + xterm_ResetDouble(xw); + } else { + reset_lr_margins(screen); + } + } + break; +#if OPT_SIXEL_GRAPHICS + case srm_DECSDM: /* sixel scrolling */ + if (screen->terminal_id == 240 || + screen->terminal_id == 241 || + screen->terminal_id == 330 || + screen->terminal_id == 340) { + (*func) (&xw->keyboard.flags, MODE_DECSDM); + TRACE(("DECSET/DECRST DECSDM %s (resource default is %d)\n", + BtoS(xw->keyboard.flags & MODE_DECSDM), + TScreenOf(xw)->sixel_scrolling)); + update_decsdm(); + } + break; +#endif + case srm_DECNCSM: + if (screen->vtXX_level >= 5) { /* VT510 */ + (*func) (&xw->flags, NOCLEAR_COLM); + } + break; + case srm_VT200_MOUSE: /* xterm bogus sequence */ MotionOff(screen, xw); set_mousemode(VT200_MOUSE); break; - case SET_VT200_HIGHLIGHT_MOUSE: /* xterm sequence w/hilite tracking */ + case srm_VT200_HIGHLIGHT_MOUSE: /* xterm sequence w/hilite tracking */ MotionOff(screen, xw); set_mousemode(VT200_HIGHLIGHT_MOUSE); break; - case SET_BTN_EVENT_MOUSE: + case srm_BTN_EVENT_MOUSE: MotionOff(screen, xw); set_mousemode(BTN_EVENT_MOUSE); break; - case SET_ANY_EVENT_MOUSE: + case srm_ANY_EVENT_MOUSE: set_mousemode(ANY_EVENT_MOUSE); if (screen->send_mouse_pos == MOUSE_OFF) { MotionOff(screen, xw); @@ -4403,76 +5228,79 @@ } break; #if OPT_FOCUS_EVENT - case SET_FOCUS_EVENT_MOUSE: + case srm_FOCUS_EVENT_MOUSE: set_bool_mode(screen->send_focus_pos); break; #endif - case SET_EXT_MODE_MOUSE: + case srm_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_SGR_EXT_MODE_MOUSE: + case srm_SGR_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_URXVT_EXT_MODE_MOUSE: + case srm_URXVT_EXT_MODE_MOUSE: /* * Rather than choose an arbitrary precedence among the coordinate * modes, they are mutually exclusive. For consistency, a reset is * only effective against the matching mode. */ if (IsSM()) { - screen->extend_coords = param[i]; - } else if (screen->extend_coords == param[i]) { + screen->extend_coords = code; + } else if (screen->extend_coords == code) { screen->extend_coords = 0; } break; - case 1010: /* rxvt */ + case srm_ALTERNATE_SCROLL: + set_bool_mode(screen->alternateScroll); + break; + case srm_RXVT_SCROLL_TTY_OUTPUT: set_bool_mode(screen->scrollttyoutput); update_scrollttyoutput(); break; - case 1011: /* rxvt */ + case srm_RXVT_SCROLL_TTY_KEYPRESS: set_bool_mode(screen->scrollkey); update_scrollkey(); break; - case 1034: + case srm_EIGHT_BIT_META: if (screen->eight_bit_meta != ebNever) { set_bool_mode(screen->eight_bit_meta); } break; #if OPT_NUM_LOCK - case 1035: + case srm_REAL_NUMLOCK: set_bool_mode(xw->misc.real_NumLock); update_num_lock(); break; - case 1036: + case srm_META_SENDS_ESC: set_bool_mode(screen->meta_sends_esc); update_meta_esc(); break; #endif - case 1037: + case srm_DELETE_IS_DEL: set_bool_mode(screen->delete_is_del); update_delete_del(); break; #if OPT_NUM_LOCK - case 1039: + case srm_ALT_SENDS_ESC: set_bool_mode(screen->alt_sends_esc); update_alt_esc(); break; #endif - case 1040: + case srm_KEEP_SELECTION: set_bool_mode(screen->keepSelection); update_keepSelection(); break; - case 1041: + case srm_SELECT_TO_CLIPBOARD: set_bool_mode(screen->selectToClipboard); update_selectToClipboard(); break; - case 1042: + case srm_BELL_IS_URGENT: set_bool_mode(screen->bellIsUrgent); update_bellIsUrgent(); break; - case 1043: + case srm_POP_ON_BELL: set_bool_mode(screen->poponbell); update_poponbell(); break; - case 1048: + case srm_TITE_INHIBIT: if (!xw->misc.titeInhibit) { if (IsSM()) CursorSave(xw); @@ -4481,53 +5309,64 @@ } break; #if OPT_TCAP_FKEYS - case 1050: + case srm_TCAP_FKEYS: set_keyboard_type(xw, keyboardIsTermcap, IsSM()); break; #endif #if OPT_SUN_FUNC_KEYS - case 1051: + case srm_SUN_FKEYS: set_keyboard_type(xw, keyboardIsSun, IsSM()); break; #endif #if OPT_HP_FUNC_KEYS - case 1052: + case srm_HP_FKEYS: set_keyboard_type(xw, keyboardIsHP, IsSM()); break; #endif #if OPT_SCO_FUNC_KEYS - case 1053: + case srm_SCO_FKEYS: set_keyboard_type(xw, keyboardIsSCO, IsSM()); break; #endif - case 1060: + case srm_LEGACY_FKEYS: set_keyboard_type(xw, keyboardIsLegacy, IsSM()); break; #if OPT_SUNPC_KBD - case 1061: + case srm_VT220_FKEYS: set_keyboard_type(xw, keyboardIsVT220, IsSM()); break; #endif #if OPT_READLINE - case SET_BUTTON1_MOVE_POINT: + case srm_BUTTON1_MOVE_POINT: set_mouseflag(click1_moves); break; - case SET_BUTTON2_MOVE_POINT: + case srm_BUTTON2_MOVE_POINT: set_mouseflag(paste_moves); break; - case SET_DBUTTON3_DELETE: + case srm_DBUTTON3_DELETE: set_mouseflag(dclick3_deletes); break; - case SET_PASTE_IN_BRACKET: + case srm_PASTE_IN_BRACKET: set_mouseflag(paste_brackets); break; - case SET_PASTE_QUOTE: + case srm_PASTE_QUOTE: set_mouseflag(paste_quotes); break; - case SET_PASTE_LITERAL_NL: + case srm_PASTE_LITERAL_NL: set_mouseflag(paste_literal_nl); break; #endif /* OPT_READLINE */ +#if OPT_SIXEL_GRAPHICS + case srm_PRIVATE_COLOR_REGISTERS: /* private color registers for each graphic */ + TRACE(("DECSET/DECRST PRIVATE_COLOR_REGISTERS %s\n", + BtoS(screen->privatecolorregisters))); + set_bool_mode(screen->privatecolorregisters); + update_privatecolorregisters(); + break; +#endif + default: + TRACE(("DATA_ERROR: unknown private code %d\n", code)); + break; } } } @@ -4542,122 +5381,233 @@ int i; for (i = 0; i < nparam; i++) { - TRACE(("savemodes %d\n", param[i])); - switch (param[i]) { - case 1: /* DECCKM */ + int code = GetParam(i); + + TRACE(("savemodes %d\n", code)); + switch ((DECSET_codes) code) { + case srm_DECCKM: DoSM(DP_DECCKM, xw->keyboard.flags & MODE_DECCKM); break; - case 3: /* DECCOLM */ + case srm_DECANM: /* ANSI/VT52 mode */ + /* no effect */ + break; + case srm_DECCOLM: if (screen->c132) DoSM(DP_DECCOLM, xw->flags & IN132COLUMNS); break; - case 4: /* DECSCLM (slow scroll) */ + case srm_DECSCLM: /* (slow scroll) */ DoSM(DP_DECSCLM, xw->flags & SMOOTHSCROLL); break; - case 5: /* DECSCNM */ + case srm_DECSCNM: DoSM(DP_DECSCNM, xw->flags & REVERSE_VIDEO); break; - case 6: /* DECOM */ + case srm_DECOM: DoSM(DP_DECOM, xw->flags & ORIGIN); break; - case 7: /* DECAWM */ + case srm_DECAWM: DoSM(DP_DECAWM, xw->flags & WRAPAROUND); break; - case 8: /* DECARM */ + case srm_DECARM: /* ignore autorepeat */ break; - case SET_X10_MOUSE: /* mouse bogus sequence */ + case srm_X10_MOUSE: /* mouse bogus sequence */ DoSM(DP_X_X10MSE, screen->send_mouse_pos); break; #if OPT_TOOLBAR - case 10: /* rxvt */ + case srm_RXVT_TOOLBAR: DoSM(DP_TOOLBAR, resource.toolBar); break; #endif #if OPT_BLINK_CURS - case 12: /* att610: Start/stop blinking cursor */ + case srm_ATT610_BLINK: /* att610: Start/stop blinking cursor */ if (screen->cursor_blink_res) { DoSM(DP_CRS_BLINK, screen->cursor_blink_esc); } break; #endif - case 18: /* DECPFF: print form feed */ + case srm_DECPFF: /* print form feed */ DoSM(DP_PRN_FORMFEED, PrinterOf(screen).printer_formfeed); break; - case 19: /* DECPEX: print extent */ - DoSM(DP_PRN_EXTENT, PrinterOf(screen).printer_extent); + case srm_DECPEX: /* print extent */ + DoSM(DP_PRN_EXTENT, PrinterOf(screen).printer_extent); + break; + case srm_DECTCEM: /* Show/hide cursor (VT200) */ + DoSM(DP_CRS_VISIBLE, screen->cursor_set); + break; + case srm_RXVT_SCROLLBAR: + DoSM(DP_RXVT_SCROLLBAR, (screen->fullVwin.sb_info.width != 0)); + break; +#if OPT_SHIFT_FONTS + case srm_RXVT_FONTSIZE: + DoSM(DP_RXVT_FONTSIZE, xw->misc.shift_fonts); break; - case 25: /* DECTCEM: Show/hide cursor (VT200) */ - DoSM(DP_CRS_VISIBLE, screen->cursor_set); +#endif +#if OPT_TEK4014 + case srm_DECTEK: + DoSM(DP_DECTEK, TEK4014_ACTIVE(xw)); break; - case 40: /* 132 column mode */ +#endif + case srm_132COLS: /* 132 column mode */ DoSM(DP_X_DECCOLM, screen->c132); break; - case 41: /* curses hack */ + case srm_CURSES_HACK: /* curses hack */ DoSM(DP_X_MORE, screen->curses); break; - case 42: /* DECNRCM national charset (VT220) */ - /* do nothing */ + case srm_DECNRCM: /* national charset (VT220) */ + if (screen->vtXX_level >= 2) { + DoSM(DP_DECNRCM, xw->flags & NATIONAL); + } break; - case 44: /* margin bell */ + case srm_MARGIN_BELL: /* margin bell */ DoSM(DP_X_MARGIN, screen->marginbell); break; - case 45: /* reverse wraparound */ + case srm_REVERSEWRAP: /* reverse wraparound */ DoSM(DP_X_REVWRAP, xw->flags & REVERSEWRAP); break; #ifdef ALLOWLOGGING - case 46: /* logging */ + case srm_ALLOWLOGGING: /* logging */ DoSM(DP_X_LOGGING, screen->logging); break; #endif - case 1047: /* alternate buffer */ + case srm_OPT_ALTBUF_CURSOR: + /* FALLTHRU */ + case srm_OPT_ALTBUF: /* FALLTHRU */ - case 47: /* alternate buffer */ + case srm_ALTBUF: /* alternate buffer */ DoSM(DP_X_ALTSCRN, screen->whichBuf); break; - case SET_VT200_MOUSE: /* mouse bogus sequence */ - case SET_VT200_HIGHLIGHT_MOUSE: - case SET_BTN_EVENT_MOUSE: - case SET_ANY_EVENT_MOUSE: + case srm_DECNKM: + DoSM(DP_DECKPAM, xw->keyboard.flags & MODE_DECKPAM); + break; + case srm_DECBKM: /* backarrow mapping */ + DoSM(DP_DECBKM, xw->keyboard.flags & MODE_DECBKM); + break; + case srm_DECLRMM: /* left-right */ + DoSM(DP_X_LRMM, LEFT_RIGHT); + break; +#if OPT_SIXEL_GRAPHICS + case srm_DECSDM: /* sixel scrolling */ + DoSM(DP_DECSDM, xw->keyboard.flags & MODE_DECSDM); + update_decsdm(); + break; +#endif + case srm_DECNCSM: /* noclear */ + DoSM(DP_X_NCSM, NOCLEAR_COLM); + break; + case srm_VT200_MOUSE: /* mouse bogus sequence */ + case srm_VT200_HIGHLIGHT_MOUSE: + case srm_BTN_EVENT_MOUSE: + case srm_ANY_EVENT_MOUSE: DoSM(DP_X_MOUSE, screen->send_mouse_pos); break; #if OPT_FOCUS_EVENT - case SET_FOCUS_EVENT_MOUSE: + case srm_FOCUS_EVENT_MOUSE: DoSM(DP_X_FOCUS, screen->send_focus_pos); break; #endif - case SET_EXT_MODE_MOUSE: + case srm_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_SGR_EXT_MODE_MOUSE: + case srm_SGR_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_URXVT_EXT_MODE_MOUSE: + case srm_URXVT_EXT_MODE_MOUSE: DoSM(DP_X_EXT_MOUSE, screen->extend_coords); break; - case 1048: + case srm_ALTERNATE_SCROLL: + DoSM(DP_ALTERNATE_SCROLL, screen->alternateScroll); + break; + case srm_RXVT_SCROLL_TTY_OUTPUT: + DoSM(DP_RXVT_SCROLL_TTY_OUTPUT, screen->scrollttyoutput); + break; + case srm_RXVT_SCROLL_TTY_KEYPRESS: + DoSM(DP_RXVT_SCROLL_TTY_KEYPRESS, screen->scrollkey); + break; + case srm_EIGHT_BIT_META: + DoSM(DP_EIGHT_BIT_META, screen->eight_bit_meta); + break; +#if OPT_NUM_LOCK + case srm_REAL_NUMLOCK: + DoSM(DP_REAL_NUMLOCK, xw->misc.real_NumLock); + break; + case srm_META_SENDS_ESC: + DoSM(DP_META_SENDS_ESC, screen->meta_sends_esc); + break; +#endif + case srm_DELETE_IS_DEL: + DoSM(DP_DELETE_IS_DEL, screen->delete_is_del); + break; +#if OPT_NUM_LOCK + case srm_ALT_SENDS_ESC: + DoSM(DP_ALT_SENDS_ESC, screen->alt_sends_esc); + break; +#endif + case srm_KEEP_SELECTION: + DoSM(DP_KEEP_SELECTION, screen->keepSelection); + break; + case srm_SELECT_TO_CLIPBOARD: + DoSM(DP_SELECT_TO_CLIPBOARD, screen->selectToClipboard); + break; + case srm_BELL_IS_URGENT: + DoSM(DP_BELL_IS_URGENT, screen->bellIsUrgent); + break; + case srm_POP_ON_BELL: + DoSM(DP_POP_ON_BELL, screen->poponbell); + break; +#if OPT_TCAP_FKEYS + case srm_TCAP_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_SUN_FUNC_KEYS + case srm_SUN_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_HP_FUNC_KEYS + case srm_HP_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_SCO_FUNC_KEYS + case srm_SCO_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_SUNPC_KBD + case srm_VT220_FKEYS: + /* FALLTHRU */ +#endif + case srm_LEGACY_FKEYS: + DoSM(DP_KEYBOARD_TYPE, xw->keyboard.type); + break; + case srm_TITE_INHIBIT: if (!xw->misc.titeInhibit) { CursorSave(xw); } break; #if OPT_READLINE - case SET_BUTTON1_MOVE_POINT: + case srm_BUTTON1_MOVE_POINT: SCREEN_FLAG_save(screen, click1_moves); break; - case SET_BUTTON2_MOVE_POINT: + case srm_BUTTON2_MOVE_POINT: SCREEN_FLAG_save(screen, paste_moves); break; - case SET_DBUTTON3_DELETE: + case srm_DBUTTON3_DELETE: SCREEN_FLAG_save(screen, dclick3_deletes); break; - case SET_PASTE_IN_BRACKET: + case srm_PASTE_IN_BRACKET: SCREEN_FLAG_save(screen, paste_brackets); break; - case SET_PASTE_QUOTE: + case srm_PASTE_QUOTE: SCREEN_FLAG_save(screen, paste_quotes); break; - case SET_PASTE_LITERAL_NL: + case srm_PASTE_LITERAL_NL: SCREEN_FLAG_save(screen, paste_literal_nl); break; #endif /* OPT_READLINE */ +#if OPT_SIXEL_GRAPHICS + case srm_PRIVATE_COLOR_REGISTERS: /* private color registers for each graphic */ + TRACE(("save PRIVATE_COLOR_REGISTERS %s\n", + BtoS(screen->privatecolorregisters))); + DoSM(DP_X_PRIVATE_COLOR_REGISTERS, screen->privatecolorregisters); + update_privatecolorregisters(); + break; +#endif } } } @@ -4672,16 +5622,22 @@ int i, j; for (i = 0; i < nparam; i++) { - TRACE(("restoremodes %d\n", param[i])); - switch (param[i]) { - case 1: /* DECCKM */ + int code = GetParam(i); + + TRACE(("restoremodes %d\n", code)); + switch ((DECSET_codes) code) { + case srm_DECCKM: bitcpy(&xw->keyboard.flags, screen->save_modes[DP_DECCKM], MODE_DECCKM); update_appcursor(); break; - case 3: /* DECCOLM */ + case srm_DECANM: /* ANSI/VT52 mode */ + /* no effect */ + break; + case srm_DECCOLM: if (screen->c132) { - ClearScreen(xw); + if (!(xw->flags & NOCLEAR_COLM)) + ClearScreen(xw); CursorSet(screen, 0, 0, xw->flags); if ((j = (screen->save_modes[DP_DECCOLM] & IN132COLUMNS) ? 132 : 80) != ((xw->flags & IN132COLUMNS) @@ -4692,7 +5648,7 @@ IN132COLUMNS); } break; - case 4: /* DECSCLM (slow scroll) */ + case srm_DECSCLM: /* (slow scroll) */ if (screen->save_modes[DP_DECSCLM] & SMOOTHSCROLL) { screen->jumpscroll = 0; if (screen->scroll_amt) @@ -4702,70 +5658,100 @@ bitcpy(&xw->flags, screen->save_modes[DP_DECSCLM], SMOOTHSCROLL); update_jumpscroll(); break; - case 5: /* DECSCNM */ + case srm_DECSCNM: if ((screen->save_modes[DP_DECSCNM] ^ xw->flags) & REVERSE_VIDEO) { bitcpy(&xw->flags, screen->save_modes[DP_DECSCNM], REVERSE_VIDEO); ReverseVideo(xw); /* update_reversevideo done in RevVid */ } break; - case 6: /* DECOM */ + case srm_DECOM: bitcpy(&xw->flags, screen->save_modes[DP_DECOM], ORIGIN); CursorSet(screen, 0, 0, xw->flags); break; - case 7: /* DECAWM */ + case srm_DECAWM: bitcpy(&xw->flags, screen->save_modes[DP_DECAWM], WRAPAROUND); update_autowrap(); break; - case 8: /* DECARM */ + case srm_DECARM: /* ignore autorepeat */ break; - case SET_X10_MOUSE: /* MIT bogus sequence */ + case srm_X10_MOUSE: /* MIT bogus sequence */ DoRM0(DP_X_X10MSE, screen->send_mouse_pos); + really_set_mousemode(xw, + screen->send_mouse_pos != MOUSE_OFF, + (XtermMouseModes) screen->send_mouse_pos); break; #if OPT_TOOLBAR - case 10: /* rxvt */ + case srm_RXVT_TOOLBAR: DoRM(DP_TOOLBAR, resource.toolBar); ShowToolbar(resource.toolBar); break; #endif #if OPT_BLINK_CURS - case 12: /* att610: Start/stop blinking cursor */ + case srm_ATT610_BLINK: /* Start/stop blinking cursor */ if (screen->cursor_blink_res) { DoRM(DP_CRS_BLINK, screen->cursor_blink_esc); - SetCursorBlink(screen, screen->cursor_blink); + UpdateCursorBlink(screen); } break; #endif - case 18: /* DECPFF: print form feed */ + case srm_DECPFF: /* print form feed */ DoRM(DP_PRN_FORMFEED, PrinterOf(screen).printer_formfeed); break; - case 19: /* DECPEX: print extent */ + case srm_DECPEX: /* print extent */ DoRM(DP_PRN_EXTENT, PrinterOf(screen).printer_extent); break; - case 25: /* DECTCEM: Show/hide cursor (VT200) */ + case srm_DECTCEM: /* Show/hide cursor (VT200) */ DoRM(DP_CRS_VISIBLE, screen->cursor_set); break; - case 40: /* 132 column mode */ + case srm_RXVT_SCROLLBAR: + if ((screen->fullVwin.sb_info.width != 0) != + screen->save_modes[DP_RXVT_SCROLLBAR]) { + ToggleScrollBar(xw); + } + break; +#if OPT_SHIFT_FONTS + case srm_RXVT_FONTSIZE: + DoRM(DP_RXVT_FONTSIZE, xw->misc.shift_fonts); + break; +#endif +#if OPT_TEK4014 + case srm_DECTEK: + if (!(screen->inhibit & I_TEK) && + (TEK4014_ACTIVE(xw) != (Boolean) screen->save_modes[DP_DECTEK])) { + FlushLog(xw); + TEK4014_ACTIVE(xw) = (Boolean) screen->save_modes[DP_DECTEK]; + update_vttekmode(); + } + break; +#endif + case srm_132COLS: /* 132 column mode */ DoRM(DP_X_DECCOLM, screen->c132); update_allow132(); break; - case 41: /* curses hack */ + case srm_CURSES_HACK: /* curses hack */ DoRM(DP_X_MORE, screen->curses); update_cursesemul(); break; - case 44: /* margin bell */ + case srm_DECNRCM: /* national charset (VT220) */ + if (screen->vtXX_level >= 2) { + if (bitcpy(&xw->flags, screen->save_modes[DP_DECNRCM], NATIONAL)) + modified_DECNRCM(xw); + } + break; + case srm_MARGIN_BELL: /* margin bell */ if ((DoRM(DP_X_MARGIN, screen->marginbell)) == 0) screen->bellArmed = -1; update_marginbell(); break; - case 45: /* reverse wraparound */ + case srm_REVERSEWRAP: /* reverse wraparound */ bitcpy(&xw->flags, screen->save_modes[DP_X_REVWRAP], REVERSEWRAP); update_reversewrap(); break; #ifdef ALLOWLOGGING - case 46: /* logging */ + case srm_ALLOWLOGGING: /* logging */ #ifdef ALLOWLOGFILEONOFF if (screen->save_modes[DP_X_LOGGING]) StartLog(xw); @@ -4775,64 +5761,173 @@ /* update_logging done by StartLog and CloseLog */ break; #endif - case 1047: /* alternate buffer */ + case srm_OPT_ALTBUF_CURSOR: /* alternate buffer & cursor */ /* FALLTHRU */ - case 47: /* alternate buffer */ + case srm_OPT_ALTBUF: + /* FALLTHRU */ + case srm_ALTBUF: /* alternate buffer */ if (!xw->misc.titeInhibit) { if (screen->save_modes[DP_X_ALTSCRN]) - ToAlternate(xw); + ToAlternate(xw, False); else FromAlternate(xw); /* update_altscreen done by ToAlt and FromAlt */ - } else if (xw->misc.tiXtraScroll) { - if (screen->save_modes[DP_X_ALTSCRN]) { - xtermScroll(xw, screen->max_row); - } + } else if (screen->save_modes[DP_X_ALTSCRN]) { + do_ti_xtra_scroll(xw); + } + break; + case srm_DECNKM: + bitcpy(&xw->flags, screen->save_modes[DP_DECKPAM], MODE_DECKPAM); + update_appkeypad(); + break; + case srm_DECBKM: /* backarrow mapping */ + bitcpy(&xw->flags, screen->save_modes[DP_DECBKM], MODE_DECBKM); + update_decbkm(); + break; + case srm_DECLRMM: /* left-right */ + bitcpy(&xw->flags, screen->save_modes[DP_X_LRMM], LEFT_RIGHT); + if (IsLeftRightMode(xw)) { + xterm_ResetDouble(xw); + } else { + reset_lr_margins(screen); } break; - case SET_VT200_MOUSE: /* mouse bogus sequence */ - case SET_VT200_HIGHLIGHT_MOUSE: - case SET_BTN_EVENT_MOUSE: - case SET_ANY_EVENT_MOUSE: +#if OPT_SIXEL_GRAPHICS + case srm_DECSDM: /* sixel scrolling */ + bitcpy(&xw->keyboard.flags, screen->save_modes[DP_DECSDM], MODE_DECSDM); + update_decsdm(); + break; +#endif + case srm_DECNCSM: /* noclear */ + bitcpy(&xw->flags, screen->save_modes[DP_X_NCSM], NOCLEAR_COLM); + break; + case srm_VT200_MOUSE: /* mouse bogus sequence */ + case srm_VT200_HIGHLIGHT_MOUSE: + case srm_BTN_EVENT_MOUSE: + case srm_ANY_EVENT_MOUSE: DoRM0(DP_X_MOUSE, screen->send_mouse_pos); + really_set_mousemode(xw, + screen->send_mouse_pos != MOUSE_OFF, + (XtermMouseModes) screen->send_mouse_pos); break; #if OPT_FOCUS_EVENT - case SET_FOCUS_EVENT_MOUSE: + case srm_FOCUS_EVENT_MOUSE: DoRM(DP_X_FOCUS, screen->send_focus_pos); break; #endif - case SET_EXT_MODE_MOUSE: + case srm_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_SGR_EXT_MODE_MOUSE: + case srm_SGR_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_URXVT_EXT_MODE_MOUSE: + case srm_URXVT_EXT_MODE_MOUSE: DoRM(DP_X_EXT_MOUSE, screen->extend_coords); break; - case 1048: + case srm_TITE_INHIBIT: if (!xw->misc.titeInhibit) { CursorRestore(xw); } break; + case srm_ALTERNATE_SCROLL: + DoRM(DP_ALTERNATE_SCROLL, screen->alternateScroll); + break; + case srm_RXVT_SCROLL_TTY_OUTPUT: + DoRM(DP_RXVT_SCROLL_TTY_OUTPUT, screen->scrollttyoutput); + update_scrollttyoutput(); + break; + case srm_RXVT_SCROLL_TTY_KEYPRESS: + DoRM(DP_RXVT_SCROLL_TTY_KEYPRESS, screen->scrollkey); + update_scrollkey(); + break; + case srm_EIGHT_BIT_META: + DoRM(DP_EIGHT_BIT_META, screen->eight_bit_meta); + break; +#if OPT_NUM_LOCK + case srm_REAL_NUMLOCK: + DoRM(DP_REAL_NUMLOCK, xw->misc.real_NumLock); + update_num_lock(); + break; + case srm_META_SENDS_ESC: + DoRM(DP_META_SENDS_ESC, screen->meta_sends_esc); + update_meta_esc(); + break; +#endif + case srm_DELETE_IS_DEL: + DoRM(DP_DELETE_IS_DEL, screen->delete_is_del); + update_delete_del(); + break; +#if OPT_NUM_LOCK + case srm_ALT_SENDS_ESC: + DoRM(DP_ALT_SENDS_ESC, screen->alt_sends_esc); + update_alt_esc(); + break; +#endif + case srm_KEEP_SELECTION: + DoRM(DP_KEEP_SELECTION, screen->keepSelection); + update_keepSelection(); + break; + case srm_SELECT_TO_CLIPBOARD: + DoRM(DP_SELECT_TO_CLIPBOARD, screen->selectToClipboard); + update_selectToClipboard(); + break; + case srm_BELL_IS_URGENT: + DoRM(DP_BELL_IS_URGENT, screen->bellIsUrgent); + update_bellIsUrgent(); + break; + case srm_POP_ON_BELL: + DoRM(DP_POP_ON_BELL, screen->poponbell); + update_poponbell(); + break; +#if OPT_TCAP_FKEYS + case srm_TCAP_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_SUN_FUNC_KEYS + case srm_SUN_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_HP_FUNC_KEYS + case srm_HP_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_SCO_FUNC_KEYS + case srm_SCO_FKEYS: + /* FALLTHRU */ +#endif +#if OPT_SUNPC_KBD + case srm_VT220_FKEYS: + /* FALLTHRU */ +#endif + case srm_LEGACY_FKEYS: + xw->keyboard.type = (xtermKeyboardType) screen->save_modes[DP_KEYBOARD_TYPE]; + break; #if OPT_READLINE - case SET_BUTTON1_MOVE_POINT: + case srm_BUTTON1_MOVE_POINT: SCREEN_FLAG_restore(screen, click1_moves); break; - case SET_BUTTON2_MOVE_POINT: + case srm_BUTTON2_MOVE_POINT: SCREEN_FLAG_restore(screen, paste_moves); break; - case SET_DBUTTON3_DELETE: + case srm_DBUTTON3_DELETE: SCREEN_FLAG_restore(screen, dclick3_deletes); break; - case SET_PASTE_IN_BRACKET: + case srm_PASTE_IN_BRACKET: SCREEN_FLAG_restore(screen, paste_brackets); break; - case SET_PASTE_QUOTE: + case srm_PASTE_QUOTE: SCREEN_FLAG_restore(screen, paste_quotes); break; - case SET_PASTE_LITERAL_NL: + case srm_PASTE_LITERAL_NL: SCREEN_FLAG_restore(screen, paste_literal_nl); break; #endif /* OPT_READLINE */ +#if OPT_SIXEL_GRAPHICS + case srm_PRIVATE_COLOR_REGISTERS: /* private color registers for each graphic */ + TRACE(("restore PRIVATE_COLOR_REGISTERS %s\n", + BtoS(screen->privatecolorregisters))); + DoRM(DP_X_PRIVATE_COLOR_REGISTERS, screen->privatecolorregisters); + update_privatecolorregisters(); + break; +#endif } } } @@ -4933,7 +6028,6 @@ int code, char *text) { - reply.a_type = ANSI_ESC; unparseputc(xw, ANSI_ESC); unparseputc(xw, ']'); unparseputc(xw, code); @@ -4969,9 +6063,11 @@ unsigned root_width; unsigned root_height; #endif + int code = zero_if_default(0); + char *label; - TRACE(("window_ops %d\n", param[0])); - switch (param[0]) { + TRACE(("window_ops %d\n", code)); + switch (code) { case ewRestoreWin: /* Restore (de-iconify) window */ if (AllowWindowOps(xw, ewRestoreWin)) { TRACE(("...de-iconify window\n")); @@ -5005,7 +6101,7 @@ case ewSetWinSizePixels: /* Resize the window to given size in pixels */ if (AllowWindowOps(xw, ewSetWinSizePixels)) { - RequestResize(xw, param[1], param[2], False); + RequestResize(xw, optional_param(1), optional_param(2), False); } break; @@ -5032,7 +6128,7 @@ case ewSetWinSizeChars: /* Resize the text-area, in characters */ if (AllowWindowOps(xw, ewSetWinSizeChars)) { - RequestResize(xw, param[1], param[2], True); + RequestResize(xw, optional_param(1), optional_param(2), True); } break; @@ -5052,10 +6148,10 @@ case ewGetWinState: /* Report the window's state */ if (AllowWindowOps(xw, ewGetWinState)) { TRACE(("...get window attributes\n")); - XGetWindowAttributes(screen->display, - VWindow(screen), - &win_attrs); - reply.a_type = ANSI_CSI; + xtermGetWinAttrs(screen->display, + VWindow(screen), + &win_attrs); + init_reply(ANSI_CSI); reply.a_pintro = 0; reply.a_nparam = 1; reply.a_param[0] = (ParmType) ((win_attrs.map_state == IsViewable) @@ -5070,10 +6166,10 @@ case ewGetWinPosition: /* Report the window's position */ if (AllowWindowOps(xw, ewGetWinPosition)) { TRACE(("...get window position\n")); - XGetWindowAttributes(screen->display, - WMFrameWindow(xw), - &win_attrs); - reply.a_type = ANSI_CSI; + xtermGetWinAttrs(screen->display, + WMFrameWindow(xw), + &win_attrs); + init_reply(ANSI_CSI); reply.a_pintro = 0; reply.a_nparam = 3; reply.a_param[0] = 3; @@ -5088,17 +6184,10 @@ case ewGetWinSizePixels: /* Report the window's size in pixels */ if (AllowWindowOps(xw, ewGetWinSizePixels)) { TRACE(("...get window size in pixels\n")); - XGetWindowAttributes(screen->display, - VWindow(screen), - &win_attrs); - reply.a_type = ANSI_CSI; + init_reply(ANSI_CSI); reply.a_pintro = 0; reply.a_nparam = 3; reply.a_param[0] = 4; - /*FIXME: find if dtterm uses - * win_attrs.height or Height - * win_attrs.width or Width - */ reply.a_param[1] = (ParmType) Height(screen); reply.a_param[2] = (ParmType) Width(screen); reply.a_inters = 0; @@ -5110,7 +6199,7 @@ case ewGetWinSizeChars: /* Report the text's size in characters */ if (AllowWindowOps(xw, ewGetWinSizeChars)) { TRACE(("...get window size in characters\n")); - reply.a_type = ANSI_CSI; + init_reply(ANSI_CSI); reply.a_pintro = 0; reply.a_nparam = 3; reply.a_param[0] = 8; @@ -5126,11 +6215,8 @@ case ewGetScreenSizeChars: /* Report the screen's size, in characters */ if (AllowWindowOps(xw, ewGetScreenSizeChars)) { TRACE(("...get screen size in characters\n")); - if (!QueryMaximize(xw, &root_height, &root_width)) { - root_height = 0; - root_width = 0; - } - reply.a_type = ANSI_CSI; + (void) QueryMaximize(xw, &root_height, &root_width); + init_reply(ANSI_CSI); reply.a_pintro = 0; reply.a_nparam = 3; reply.a_param[0] = 9; @@ -5148,14 +6234,16 @@ case ewGetIconTitle: /* Report the icon's label */ if (AllowWindowOps(xw, ewGetIconTitle)) { TRACE(("...get icon's label\n")); - report_win_label(xw, 'L', get_icon_label(xw)); + report_win_label(xw, 'L', label = get_icon_label(xw)); + free(label); } break; case ewGetWinTitle: /* Report the window's title */ if (AllowWindowOps(xw, ewGetWinTitle)) { TRACE(("...get window's label\n")); - report_win_label(xw, 'l', get_window_label(xw)); + report_win_label(xw, 'l', label = get_window_label(xw)); + free(label); } break; @@ -5222,8 +6310,8 @@ default: /* DECSLPP (24, 25, 36, 48, 72, 144) */ if (AllowWindowOps(xw, ewSetWinLines)) { - if (param[0] >= 24) - RequestResize(xw, param[0], -1, True); + if (code >= 24) + RequestResize(xw, code, -1, True); } break; } @@ -5232,29 +6320,35 @@ /* * set a bit in a word given a pointer to the word and a mask. */ -static void +static int bitset(unsigned *p, unsigned mask) { + unsigned before = *p; *p |= mask; + return (before != *p); } /* * clear a bit in a word given a pointer to the word and a mask. */ -static void +static int bitclr(unsigned *p, unsigned mask) { + unsigned before = *p; *p &= ~mask; + return (before != *p); } /* * Copy bits from one word to another, given a mask */ -static void +static int bitcpy(unsigned *p, unsigned q, unsigned mask) { + unsigned before = *p; bitclr(p, mask); bitset(p, q & mask); + return (before != *p); } void @@ -5270,7 +6364,7 @@ } void -unparseseq(XtermWidget xw, ANSI * ap) +unparseseq(XtermWidget xw, ANSI *ap) { int c; int i; @@ -5287,9 +6381,20 @@ if (ap->a_pintro != 0) unparseputc(xw, ap->a_pintro); for (i = 0; i < ap->a_nparam; ++i) { - if (i != 0) - unparseputc(xw, ';'); - unparseputn(xw, (unsigned int) ap->a_param[i]); + if (i != 0) { + if (ap->a_delim) { + unparseputs(xw, ap->a_delim); + } else { + unparseputc(xw, ';'); + } + } + if (ap->a_radix[i]) { + char temp[8]; + sprintf(temp, "%04X", ap->a_param[i] & 0xffff); + unparseputs(xw, temp); + } else { + unparseputn(xw, (unsigned int) ap->a_param[i]); + } } if ((inters = ap->a_inters) != 0) { for (i = 3; i >= 0; --i) { @@ -5298,7 +6403,17 @@ unparseputc(xw, c); } } - unparseputc(xw, (char) ap->a_final); + switch (ap->a_type) { + case ANSI_DCS: + case ANSI_OSC: + case ANSI_PM: + case ANSI_APC: + unparseputc1(xw, ANSI_ST); + break; + default: + unparseputc(xw, (char) ap->a_final); + break; + } } unparse_end(xw); } @@ -5330,8 +6445,8 @@ IChar *buf = screen->unparse_bfr; unsigned len; - if ((screen->unparse_len + 2) >= sizeof(screen->unparse_bfr)) - unparse_end(xw); + if ((screen->unparse_len + 2) >= sizeof(screen->unparse_bfr) / sizeof(IChar)) + unparse_end(xw); len = screen->unparse_len; @@ -5382,11 +6497,11 @@ if (TScreenOf(xw)->whichBuf) FromAlternate(xw); else - ToAlternate(xw); + ToAlternate(xw, False); } static void -ToAlternate(XtermWidget xw) +ToAlternate(XtermWidget xw, Bool clearFirst) { TScreen *screen = TScreenOf(xw); @@ -5397,7 +6512,7 @@ (unsigned) MaxRows(screen), (unsigned) MaxCols(screen), &screen->editBuf_data[1]); - SwitchBufs(xw, 1); + SwitchBufs(xw, 1, clearFirst); screen->whichBuf = 1; #if OPT_SAVE_LINES screen->visbuf = screen->editBuf_index[screen->whichBuf]; @@ -5416,7 +6531,7 @@ if (screen->scroll_amt) FlushScroll(xw); screen->whichBuf = 0; - SwitchBufs(xw, 0); + SwitchBufs(xw, 0, False); #if OPT_SAVE_LINES screen->visbuf = screen->editBuf_index[screen->whichBuf]; #endif @@ -5425,7 +6540,7 @@ } static void -SwitchBufs(XtermWidget xw, int toBuf) +SwitchBufs(XtermWidget xw, int toBuf, Bool clearFirst) { TScreen *screen = TScreenOf(xw); int rows, top; @@ -5440,6 +6555,15 @@ if (screen->scroll_amt) { FlushScroll(xw); } +#if OPT_DOUBLE_BUFFER + XFillRectangle(screen->display, + VDrawable(screen), + ReverseGC(xw, screen), + (int) OriginX(screen), + (int) top * FontHeight(screen) + screen->border, + (unsigned) Width(screen), + (unsigned) ((rows - top) * FontHeight(screen))); +#else XClearArea(screen->display, VWindow(screen), (int) OriginX(screen), @@ -5447,12 +6571,16 @@ (unsigned) Width(screen), (unsigned) ((rows - top) * FontHeight(screen)), False); +#endif + if (clearFirst) { + ClearBufRows(xw, top, rows); + } } ScrnUpdate(xw, 0, 0, rows, MaxCols(screen), False); } Bool -CheckBufPtrs(TScreen * screen) +CheckBufPtrs(TScreen *screen) { return (screen->visbuf != 0 #if OPT_SAVE_LINES @@ -5465,7 +6593,7 @@ * Swap buffer line pointers between alternate and regular screens. */ void -SwitchBufPtrs(TScreen * screen, int toBuf GCC_UNUSED) +SwitchBufPtrs(TScreen *screen, int toBuf GCC_UNUSED) { if (CheckBufPtrs(screen)) { #if OPT_SAVE_LINES @@ -5532,10 +6660,7 @@ XEvent * event, Region region GCC_UNUSED) { -#ifdef DEBUG - if (debug) - fputs("Expose\n", stderr); -#endif /* DEBUG */ + DEBUG_MSG("Expose\n"); if (event->type == Expose) HandleExposure(term, event); } @@ -5568,7 +6693,7 @@ VTNonMaskableEvent(Widget w GCC_UNUSED, XtPointer closure GCC_UNUSED, XEvent * event, - Boolean * cont GCC_UNUSED) + Boolean *cont GCC_UNUSED) { switch (event->type) { case GraphicsExpose: @@ -5609,8 +6734,8 @@ if (askedHeight == 0 || askedWidth == 0 || xw->misc.limit_resize > 0) { - XGetWindowAttributes(XtDisplay(xw), - RootWindowOfScreen(XtScreen(xw)), &attrs); + xtermGetWinAttrs(XtDisplay(xw), + RootWindowOfScreen(XtScreen(xw)), &attrs); } if (text) { @@ -5739,38 +6864,66 @@ { char *name; ScrnColors temp; + TScreen *src = TScreenOf(source); + TScreen *dst = TScreenOf(target); - TScreenOf(target)->Tcolors[offset] = TScreenOf(source)->Tcolors[offset]; - TScreenOf(target)->Tcolors[offset].mode = False; + dst->Tcolors[offset] = src->Tcolors[offset]; + dst->Tcolors[offset].mode = False; - if ((name = x_strtrim(TScreenOf(target)->Tcolors[offset].resource)) != 0) - TScreenOf(target)->Tcolors[offset].resource = name; + if ((name = x_strtrim(dst->Tcolors[offset].resource)) != 0) + dst->Tcolors[offset].resource = name; if (name == 0) { - TScreenOf(target)->Tcolors[offset].value = target->dft_foreground; + dst->Tcolors[offset].value = target->dft_foreground; } else if (isDefaultForeground(name)) { - TScreenOf(target)->Tcolors[offset].value = - ((offset == TEXT_FG || offset == TEXT_BG) - ? target->dft_foreground - : TScreenOf(target)->Tcolors[TEXT_FG].value); + dst->Tcolors[offset].value = ((offset == TEXT_FG || offset == TEXT_BG) + ? target->dft_foreground + : dst->Tcolors[TEXT_FG].value); } else if (isDefaultBackground(name)) { - TScreenOf(target)->Tcolors[offset].value = - ((offset == TEXT_FG || offset == TEXT_BG) - ? target->dft_background - : TScreenOf(target)->Tcolors[TEXT_BG].value); + dst->Tcolors[offset].value = ((offset == TEXT_FG || offset == TEXT_BG) + ? target->dft_background + : dst->Tcolors[TEXT_BG].value); } else { memset(&temp, 0, sizeof(temp)); if (AllocateTermColor(target, &temp, offset, name, True)) { if (COLOR_DEFINED(&(temp), offset)) free(temp.names[offset]); - TScreenOf(target)->Tcolors[offset].value = temp.colors[offset]; + dst->Tcolors[offset].value = temp.colors[offset]; + } else if (offset == TEXT_FG || offset == TEXT_BG) { + free(name); + dst->Tcolors[offset].resource = 0; + } + } + return dst->Tcolors[offset].value; +} + +/* + * If one or both of the foreground/background colors cannot be allocated, + * e.g., due to gross misconfiguration, recover by setting both to the + * display's default values. + */ +static void +repairColors(XtermWidget target) +{ + TScreen *screen = TScreenOf(target); + + if (screen->Tcolors[TEXT_FG].resource == 0 || + screen->Tcolors[TEXT_BG].resource == 0) { + xtermWarning("unable to allocate fg/bg colors\n"); + screen->Tcolors[TEXT_FG].resource = x_strdup(XtDefaultForeground); + screen->Tcolors[TEXT_BG].resource = x_strdup(XtDefaultBackground); + if (screen->Tcolors[TEXT_FG].resource == 0 || + screen->Tcolors[TEXT_BG].resource == 0) { + Exit(1); } + screen->Tcolors[TEXT_FG].value = target->dft_foreground; + screen->Tcolors[TEXT_BG].value = target->dft_background; } - return TScreenOf(target)->Tcolors[offset].value; } #else #define fill_Tres(target, source, offset) \ TScreenOf(target)->Tcolors[offset] = TScreenOf(source)->Tcolors[offset] +#define repairColors(target) /* nothing */ #endif #if OPT_WIDE_CHARS @@ -6004,7 +7157,7 @@ Cardinal n; int value = -1; - while (*source != '\0') { + while (!IsEmpty(source)) { char *next = ParseList(&source); Boolean found = False; @@ -6044,6 +7197,44 @@ } } +#if OPT_RENDERFONT +static void +trimSizeFromFace(char *face_name, float *face_size) +{ + char *first = strstr(face_name, ":size="); + if (first == 0) { + first = face_name; + } else { + first++; + } + if (!strncmp(first, "size=", (size_t) 5)) { + char *last = strchr(first, ':'); + char mark; + float value; + char extra; + if (last == 0) + last = first + strlen(first); + mark = *last; + *last = '\0'; + if (sscanf(first, "size=%g%c", &value, &extra) == 1) { + TRACE(("...trimmed size from font: %g\n", value)); + if (face_size != 0) + *face_size = value; + } + if (mark) { + while ((*first++ = *++last) != '\0') { + ; + } + } else { + if (first != face_name) + --first; + *first = '\0'; + } + TRACE(("...after trimming, font = \"%s\"\n", face_name)); + } +} +#endif + /* ARGSUSED */ static void VTInitialize(Widget wrequest, @@ -6134,6 +7325,15 @@ #undef DATA #endif +#ifndef NO_ACTIVE_ICON +#define DATA(name) { #name, ei##name } + static FlagList tblAIconOps[] = + { + DATA(Default) + }; +#undef DATA +#endif + #define DATA(name) { #name, eb##name } static FlagList tbl8BitMeta[] = { @@ -6178,6 +7378,11 @@ */ memset(&wnew->keyboard, 0, sizeof(wnew->keyboard)); + /* + * The workspace has no resources - clear it. + */ + memset(&wnew->work, 0, sizeof(wnew->work)); + /* dummy values so that we don't try to Realize the parent shell with height * or width of 0, which is illegal in X. The real size is computed in the * xtermWidget's Realize proc, but the shell's Realize proc is called first, @@ -6209,6 +7414,7 @@ init_Tres(TEXT_FG); init_Tres(TEXT_BG); + repairColors(wnew); wnew->old_foreground = T_COLOR(TScreenOf(wnew), TEXT_FG); wnew->old_background = T_COLOR(TScreenOf(wnew), TEXT_BG); @@ -6221,7 +7427,7 @@ TRACE((" Actual foreground 0x%06lx\n", wnew->old_foreground)); TRACE((" Actual background 0x%06lx\n", wnew->old_background)); - TScreenOf(wnew)->mouse_button = -1; + TScreenOf(wnew)->mouse_button = 0; TScreenOf(wnew)->mouse_row = -1; TScreenOf(wnew)->mouse_col = -1; @@ -6229,6 +7435,7 @@ init_Bres(screen.force_box_chars); init_Bres(screen.force_packed); init_Bres(screen.force_all_chars); + init_Bres(screen.assume_all_chars); #endif init_Bres(screen.free_bold_box); init_Bres(screen.allowBoldFonts); @@ -6248,7 +7455,10 @@ init_Ires(screen.blink_off); TScreenOf(wnew)->cursor_blink_res = TScreenOf(wnew)->cursor_blink; #endif - init_Bres(screen.cursor_underline); + /* resources allow for underline or block, not (yet) bar */ + TScreenOf(wnew)->cursor_shape = request->screen.cursor_underline + ? CURSOR_UNDERLINE + : CURSOR_BLOCK; #if OPT_BLINK_TEXT init_Ires(screen.blink_as_bold); #endif @@ -6273,6 +7483,7 @@ init_Ires(screen.savelines); init_Ires(screen.scrollBarBorder); init_Ires(screen.scrolllines); + init_Bres(screen.alternateScroll); init_Bres(screen.scrollttyoutput); init_Bres(screen.scrollkey); @@ -6315,10 +7526,6 @@ #if OPT_NUM_LOCK init_Bres(misc.real_NumLock); init_Bres(misc.alwaysUseMods); - wnew->misc.num_lock = 0; - wnew->misc.alt_mods = 0; - wnew->misc.meta_mods = 0; - wnew->misc.other_mods = 0; #endif #if OPT_INPUT_METHOD @@ -6366,6 +7573,7 @@ init_Sres(screen.answer_back); + wnew->SPS.printer_checked = False; init_Sres(SPS.printer_command); init_Bres(SPS.printer_autoclose); init_Bres(SPS.printer_extent); @@ -6386,6 +7594,7 @@ init_Bres(screen.alt_sends_esc); init_Bres(screen.meta_sends_esc); + init_Bres(screen.allowPasteControls); init_Bres(screen.allowSendEvent0); init_Bres(screen.allowColorOp0); init_Bres(screen.allowFontOp0); @@ -6452,7 +7661,10 @@ TRACE(("iconFont '%s' %sloaded successfully\n", TScreenOf(wnew)->icon_fontname, TScreenOf(wnew)->fnt_icon.fs ? "" : "NOT ")); - init_Bres(misc.active_icon); + init_Sres(misc.active_icon_s); + wnew->work.active_icon = + (Boolean) extendedBoolean(wnew->misc.active_icon_s, + tblAIconOps, eiLAST); init_Ires(misc.icon_border_width); wnew->misc.icon_border_pixel = request->misc.icon_border_pixel; #endif /* NO_ACTIVE_ICON */ @@ -6460,6 +7672,7 @@ init_Bres(misc.signalInhibit); init_Bres(misc.titeInhibit); init_Bres(misc.tiXtraScroll); + init_Bres(misc.cdXtraScroll); init_Bres(misc.dynamicColors); for (i = fontMenu_font1; i <= fontMenu_lastBuiltin; i++) { init_Sres2(screen.MenuFontName, i); @@ -6583,21 +7796,9 @@ * specific. */ if (color_ok) { - Display *display = TScreenOf(wnew)->display; - XVisualInfo myTemplate, *visInfoPtr; - int numFound; - - myTemplate.visualid = XVisualIDFromVisual(DefaultVisual(display, - XDefaultScreen(display))); - visInfoPtr = XGetVisualInfo(display, (long) VisualIDMask, - &myTemplate, &numFound); - if (visInfoPtr == 0 - || numFound == 0 - || visInfoPtr->depth <= 1) { + if (getVisualDepth(wnew) <= 1) { TRACE(("disabling color since screen is monochrome\n")); color_ok = False; - } else { - XFree(visInfoPtr); } } @@ -6691,24 +7892,27 @@ } init_Sres(misc.face_name); init_Sres(misc.face_wide_name); + trimSizeFromFace(wnew->misc.face_wide_name, (float *) 0); + trimSizeFromFace(wnew->misc.face_name, &(wnew->misc.face_size[0])); init_Sres(misc.render_font_s); - wnew->misc.render_font = + wnew->work.render_font = (Boolean) extendedBoolean(wnew->misc.render_font_s, tblRenderFont, erLast); - if (wnew->misc.render_font == erDefault) { + if (wnew->work.render_font == erDefault) { if (IsEmpty(wnew->misc.face_name)) { + free(wnew->misc.face_name); wnew->misc.face_name = x_strdup(DEFFACENAME_AUTO); TRACE(("will allow runtime switch to render_font using \"%s\"\n", wnew->misc.face_name)); } else { - wnew->misc.render_font = erTrue; + wnew->work.render_font = erTrue; TRACE(("initially using TrueType font\n")); } } /* minor tweak to make debug traces consistent: */ - if (wnew->misc.render_font) { + if (wnew->work.render_font) { if (IsEmpty(wnew->misc.face_name)) { - wnew->misc.render_font = False; + wnew->work.render_font = False; TRACE(("reset render_font since there is no face_name\n")); } } @@ -6722,6 +7926,7 @@ extendedBoolean(request->screen.utf8_fonts_s, tblUtf8Mode, uLast); VTInitialize_locale(request); + init_Bres(screen.normalized_c); init_Bres(screen.utf8_latin1); init_Bres(screen.utf8_title); @@ -6815,6 +8020,19 @@ TRACE(("initialized DECBKM %s\n", BtoS(wnew->keyboard.flags & MODE_DECBKM))); +#if OPT_SIXEL_GRAPHICS + init_Bres(screen.sixel_scrolling); + if (TScreenOf(wnew)->sixel_scrolling) /* FIXME: should this be off unconditionally here? */ + wnew->keyboard.flags |= MODE_DECSDM; + TRACE(("initialized DECSDM %s (resource default is %d)\n", + BtoS(wnew->keyboard.flags & MODE_DECSDM), + TScreenOf(wnew)->sixel_scrolling)); + + init_Bres(screen.privatecolorregisters); /* FIXME: should this be off unconditionally here? */ + TRACE(("initialized PRIVATE_COLOR_REGISTERS to resource default %s\n", + BtoS(TScreenOf(wnew)->privatecolorregisters))); +#endif + /* look for focus related events on the shell, because we need * to care about the shell's border being part of our focus. */ @@ -6890,6 +8108,7 @@ wnew->initflags = wnew->flags; #if OPT_MOD_FKEYS + init_Ires(keyboard.modify_1st.allow_keys); init_Ires(keyboard.modify_1st.cursor_keys); init_Ires(keyboard.modify_1st.function_keys); init_Ires(keyboard.modify_1st.keypad_keys); @@ -6935,9 +8154,9 @@ #define TRACE_FREE_LEAK(name) \ if (name) { \ + TRACE(("freed " #name ": %p\n", (const void *) name)); \ free((void *) name); \ name = 0; \ - TRACE(("freed " #name "\n")); \ } #define FREE_LEAK(name) \ @@ -6952,7 +8171,7 @@ { TInput *input = lookupTInput(xw, (Widget) xw); - if (input->xim) { + if (input && input->xim) { XCloseIM(input->xim); input->xim = 0; TRACE(("freed screen->xim\n")); @@ -6975,8 +8194,8 @@ XtDestroyWidget(screen->scrollWidget); } #if OPT_FIFO_LINES - while (screen->saved_fifo-- > 0) { - deleteScrollback(screen, 0); + while (screen->saved_fifo > 0) { + deleteScrollback(screen); } #endif while (screen->save_title != 0) { @@ -6992,6 +8211,21 @@ TRACE_FREE_LEAK(screen->Acolors[n].resource); } #endif +#if OPT_COLOR_RES + for (n = 0; n < NCOLORS; n++) { + switch (n) { +#if OPT_TEK4014 + case TEK_BG: + case TEK_FG: + case TEK_CURSOR: + break; +#endif + default: + TRACE_FREE_LEAK(screen->Tcolors[n].resource); + break; + } + } +#endif TRACE_FREE_LEAK(screen->save_ptr); TRACE_FREE_LEAK(screen->saveBuf_data); TRACE_FREE_LEAK(screen->saveBuf_index); @@ -7012,6 +8246,9 @@ TRACE_FREE_LEAK(xw->screen.term_id); #if OPT_INPUT_METHOD cleanupInputMethod(xw); + TRACE_FREE_LEAK(xw->misc.f_x); + TRACE_FREE_LEAK(xw->misc.input_method); + TRACE_FREE_LEAK(xw->misc.preedit_type); #endif releaseCursorGCs(xw); releaseWindowGCs(xw, &(screen->fullVwin)); @@ -7053,9 +8290,13 @@ #endif /* free things allocated via init_Sres or Init_Sres2 */ +#ifndef NO_ACTIVE_ICON + TRACE_FREE_LEAK(screen->icon_fontname); +#endif #ifdef ALLOWLOGGING TRACE_FREE_LEAK(screen->logfile); #endif + TRACE_FREE_LEAK(screen->eight_bit_meta_s); TRACE_FREE_LEAK(screen->term_id); TRACE_FREE_LEAK(screen->charClass); TRACE_FREE_LEAK(screen->answer_back); @@ -7097,6 +8338,7 @@ XtFree((char *) (screen->selection_data)); + TRACE_FREE_LEAK(xtermClassRec.core_class.tm_table); TRACE_FREE_LEAK(xw->keyboard.extra_translations); TRACE_FREE_LEAK(xw->keyboard.shell_translations); TRACE_FREE_LEAK(xw->keyboard.xterm_translations); @@ -7120,6 +8362,121 @@ #endif /* defined(NO_LEAKS) */ } +static void * +getProperty(Display *dpy, + Window w, + Atom req_type, + const char *prop_name) +{ + Atom property; + Atom actual_return_type; + int actual_format_return = 0; + unsigned long nitems_return = 0; + unsigned long bytes_after_return = 0; + unsigned char *prop_return = 0; + long long_length = 1024; + size_t limit; + char *result = 0; + + TRACE(("getProperty %s(%s)\n", prop_name, + req_type ? XGetAtomName(dpy, req_type) : "?")); + property = XInternAtom(dpy, prop_name, False); + + if (!xtermGetWinProp(dpy, + w, + property, + 0L, + long_length, + req_type, + &actual_return_type, + &actual_format_return, + &nitems_return, + &bytes_after_return, + &prop_return)) { + TRACE((".. Cannot get %s property.\n", prop_name)); + } else if (prop_return != 0) { + + if (nitems_return != 0 && + actual_format_return != 0 && + actual_return_type == req_type) { + /* + * Null-terminate the result to make string handling easier. + * The format==8 corresponds to strings, and the number of items + * is the number of characters. + */ + if (actual_format_return == 8) { + limit = nitems_return; + } else { + /* manpage is misleading - X really uses 'long', not 32-bits */ + limit = sizeof(long) * nitems_return; + } + if ((result = malloc(limit + 1)) != 0) { + memcpy(result, prop_return, limit); + result[limit] = '\0'; + } + TRACE(("... result %s\n", result ? ("ok") : "null")); + } + XFree(prop_return); + } else { + TRACE((".. no property returned\n")); + } + return (void *) result; +} + +/* + * Active icons are supported by fvwm. This feature is not supported by + * metacity (gnome) or kwin (kde). Both metacity and kwin support (in + * incompatible ways, e.g., one uses the icon theme as a fallback for window + * decorations but the other does not, etc, ...) an icon as part of the window + * decoration (usually on the upper-left of the window). + * + * In either case, xterm's icon will only be shown in the window decorations if + * xterm does not use the active icon feature. + * + * This function (tries to) determine the window manager's name, so that we can + * provide a useful automatic default for active icons. It is based on reading + * wmctrl, which covers most of EWMH and ICCM. + */ +static char * +getWindowManagerName(XtermWidget xw) +{ + TScreen *screen = TScreenOf(xw); + Display *dpy = screen->display; + Window *sup_window = NULL; + char *result = 0; + + TRACE(("getWindowManagerName\n")); +#define getWinProp(type, name) \ + (Window *)getProperty(dpy, DefaultRootWindow(dpy), type, name) + if ((sup_window = getWinProp(XA_WINDOW, "_NET_SUPPORTING_WM_CHECK")) == 0) { + sup_window = getWinProp(XA_CARDINAL, "_WIN_SUPPORTING_WM_CHECK"); + } + + /* + * If we found the supporting window, get the property containing the + * window manager's name. EWMH defines _NET_WM_NAME, while ICCM defines + * WM_CLASS. There is no standard for the names stored there; + * conventionally it is mixed case. In practice, the former is more often + * set; the latter is not given (or is a lowercased version of the former). + */ + if (sup_window != 0) { +#define getStringProp(type,name) \ + (char *)getProperty(dpy, *sup_window, type, name) + if ((result = getStringProp(XA_UTF8_STRING(dpy), "_NET_WM_NAME")) == 0 + && (result = getStringProp(XA_STRING, "_NET_WM_NAME")) == 0 + && (result = getStringProp(XA_STRING, "WM_CLASS")) == 0) { + TRACE(("... window manager does not tell its name\n")); + } + free(sup_window); + } else { + TRACE(("... Cannot get window manager info properties\n")); + } + if (result == 0) + result = x_strdup("unknown"); + TRACE(("... window manager name is %s\n", result)); + return result; +} + /*ARGSUSED*/ static void VTRealize(Widget w, @@ -7137,6 +8494,26 @@ TRACE(("VTRealize\n")); +#if OPT_TOOLBAR + /* + * Layout for the toolbar confuses the Shell widget. Remind it that we + * would like to be iconified if the corresponding resource was set. + */ + if (XtIsRealized(toplevel)) { + Boolean iconic = 0; + + XtVaGetValues(toplevel, + XtNiconic, &iconic, + (XtPointer) 0); + + if (iconic) { + XIconifyWindow(XtDisplay(toplevel), + XtWindow(toplevel), + DefaultScreen(XtDisplay(toplevel))); + } + } +#endif + TabReset(xw->tabs); if (screen->menu_font_number == fontMenu_default) { @@ -7239,7 +8616,7 @@ xw->hints.y = ypos; #if OPT_MAXIMIZE /* assure single-increment resize for fullscreen */ - if (term->screen.fullscreen) { + if (term->work.ewmh[0].mode) { xw->hints.width_inc = 1; xw->hints.height_inc = 1; } @@ -7320,6 +8697,26 @@ (int) xw->core.depth, InputOutput, CopyFromParent, *valuemask | CWBitGravity, values); +#if OPT_DOUBLE_BUFFER + screen->fullVwin.drawable = screen->fullVwin.window; + + { + Window win = screen->fullVwin.window; + Drawable d; + int major, minor; + if (!XdbeQueryExtension(XtDisplay(xw), &major, &minor)) { + fprintf(stderr, "XdbeQueryExtension returned zero!\n"); + exit(3); + } + d = XdbeAllocateBackBufferName(XtDisplay(xw), win, XdbeCopied); + if (d == None) { + fprintf(stderr, "Couldn't allocate a back buffer!\n"); + exit(3); + } + screen->fullVwin.drawable = d; + screen->needSwap = 1; + } +#endif /* OPT_DOUBLE_BUFFER */ screen->event_mask = values->event_mask; #ifndef NO_ACTIVE_ICON @@ -7352,7 +8749,14 @@ TRACE(("using TrueType font as iconFont\n")); } #endif - if (xw->misc.active_icon && screen->fnt_icon.fs) { + if ((xw->work.active_icon == eiDefault) && screen->fnt_icon.fs) { + char *wm_name = getWindowManagerName(xw); + if (x_strncasecmp(wm_name, "fvwm", 4) && + x_strncasecmp(wm_name, "window maker", 12)) + xw->work.active_icon = eiFalse; + free(wm_name); + } + if (xw->work.active_icon && screen->fnt_icon.fs) { int iconX = 0, iconY = 0; Widget shell = SHELL_OF(xw); VTwin *win = &(screen->iconVwin); @@ -7384,6 +8788,9 @@ InputOutput, CopyFromParent, *valuemask | CWBitGravity | CWBorderPixel, values); +#if OPT_DOUBLE_BUFFER + screen->iconVwin.drawable = screen->iconVwin.window; +#endif XtVaSetValues(shell, XtNiconWindow, screen->iconVwin.window, (XtPointer) 0); @@ -7411,7 +8818,7 @@ #endif } else { TRACE(("Disabled active-icon\n")); - xw->misc.active_icon = False; + xw->work.active_icon = eiFalse; } #endif /* NO_ACTIVE_ICON */ @@ -7440,7 +8847,7 @@ set_cur_row(screen, 0); set_max_col(screen, Width(screen) / screen->fullVwin.f_width - 1); set_max_row(screen, Height(screen) / screen->fullVwin.f_height - 1); - set_tb_margins(screen, 0, screen->max_row); + reset_margins(screen); memset(screen->sc, 0, sizeof(screen->sc)); @@ -7456,7 +8863,7 @@ screen->saveBuf_index = NULL; } - screen->do_wrap = False; + ResetWrap(screen); screen->scrolls = screen->incopy = 0; xtermSetCursorBox(screen); @@ -7467,6 +8874,11 @@ CursorSave(xw); } +#ifndef NO_ACTIVE_ICON + if (!xw->work.active_icon) +#endif + xtermLoadIcon(xw); + /* * Do this last, since it may change the layout via a resize. */ @@ -7485,7 +8897,7 @@ #define USE_XIM_INSTANTIATE_CB static void -xim_instantiate_cb(Display * display, +xim_instantiate_cb(Display *display, XPointer client_data GCC_UNUSED, XPointer call_data GCC_UNUSED) { @@ -7506,8 +8918,8 @@ TRACE(("xim_destroy_cb im=%lx, client=%p, call=%p\n", (long) im, client_data, call_data)); - - input->xic = NULL; + if (input) + input->xic = NULL; XRegisterIMInstantiateCallback(XtDisplay(xw), NULL, NULL, NULL, xim_instantiate_cb, NULL); } @@ -7552,7 +8964,7 @@ xw->misc.xim_fs_ascent = (*fonts)->ascent; } } - return (Boolean) ! (xw->misc.cannot_im); + return (Boolean) !(xw->misc.cannot_im); } static void @@ -8007,7 +9419,7 @@ * If the cursor happens to be on blanks, and the foreground color is set * but not the background, do not treat it as a colored cell. */ - if ((flags & TERM_COLOR_FLAGS(xw)) == BG_COLOR + if ((flags & TERM_COLOR_FLAGS(xw)) == FG_COLOR && base == ' ') { flags &= ~TERM_COLOR_FLAGS(xw); } @@ -8025,6 +9437,24 @@ fg_pix = getXtermForeground(xw, flags, extract_fg(xw, fg_bg, flags)); bg_pix = getXtermBackground(xw, flags, extract_bg(xw, fg_bg, flags)); + /* + * If we happen to have the same foreground/background colors, choose + * a workable foreground color from which we can obtain a visible cursor. + */ + if (fg_pix == bg_pix) { + long bg_diff = (long) (bg_pix - T_COLOR(TScreenOf(xw), TEXT_BG)); + long fg_diff = (long) (bg_pix - T_COLOR(TScreenOf(xw), TEXT_FG)); + if (bg_diff < 0) + bg_diff = -bg_diff; + if (fg_diff < 0) + fg_diff = -fg_diff; + if (bg_diff < fg_diff) { + fg_pix = T_COLOR(TScreenOf(xw), TEXT_FG); + } else { + fg_pix = T_COLOR(TScreenOf(xw), TEXT_BG); + } + } + if (OutsideSelection(screen, screen->cur_row, screen->cur_col)) in_selection = False; else @@ -8036,7 +9466,7 @@ * whether the window has focus, since in that case we want just an * outline for the cursor. */ - filled = (screen->select || screen->always_highlight) && !screen->cursor_underline; + filled = (screen->select || screen->always_highlight) && isCursorBlock(screen); #if OPT_HIGHLIGHT_COLOR use_selbg = isNotForeground(xw, fg_pix, bg_pix, selbg_pix); use_selfg = isNotBackground(xw, fg_pix, bg_pix, selfg_pix); @@ -8130,19 +9560,20 @@ TRACE(("ShowCursor calling drawXtermText cur(%d,%d) %s-%s, set_at %d\n", screen->cur_row, screen->cur_col, (filled ? "filled" : "outline"), - (screen->cursor_underline ? "underline" : "box"), + (isCursorBlock(screen) ? "box" : + isCursorUnderline(screen) ? "underline" : "bar"), set_at)); currentGC = getCgsGC(xw, currentWin, currentCgs); x = LineCursorX(screen, ld, cursor_col); y = CursorY(screen, screen->cur_row); - if (screen->cursor_underline) { + if (!isCursorBlock(screen)) { /* * Overriding the combination of filled, reversed, in_selection is - * too complicated since the underline and the text-cell use + * too complicated since the underline or bar and the text-cell use * different rules. Just redraw the text-cell, and draw the - * underline on top of it. + * underline or bar on top of it. */ HideCursor(); @@ -8175,13 +9606,22 @@ if (outlineGC == 0) outlineGC = currentGC; - if (screen->cursor_underline) { + if (isCursorUnderline(screen)) { /* * Finally, draw the underline. */ screen->box->x = (short) x; screen->box->y = (short) (y + FontHeight(screen) - 2); + XDrawLines(screen->display, VDrawable(screen), outlineGC, + screen->box, NBOX, CoordModePrevious); + } else if (isCursorBar(screen)) { + + /* + * Or draw the bar. + */ + screen->box->x = (short) x; + screen->box->y = (short) y; XDrawLines(screen->display, VWindow(screen), outlineGC, screen->box, NBOX, CoordModePrevious); } else { @@ -8208,7 +9648,7 @@ if (!filled) { screen->box->x = (short) x; screen->box->y = (short) y; - XDrawLines(screen->display, VWindow(screen), outlineGC, + XDrawLines(screen->display, VDrawable(screen), outlineGC, screen->box, NBOX, CoordModePrevious); } } @@ -8341,12 +9781,17 @@ screen->cursor_state = OFF; resetXtermGC(xw, flags, in_selection); + refresh_displayed_graphics(screen, + screen->cursorp.col, + screen->cursorp.row, + 1, 1); + return; } #if OPT_BLINK_CURS || OPT_BLINK_TEXT static void -StartBlinking(TScreen * screen) +StartBlinking(TScreen *screen) { if (screen->blink_timer == 0) { unsigned long interval = (unsigned long) ((screen->cursor_state == ON) @@ -8362,7 +9807,7 @@ } static void -StopBlinking(TScreen * screen) +StopBlinking(TScreen *screen) { if (screen->blink_timer) { XtRemoveTimeOut(screen->blink_timer); @@ -8374,8 +9819,8 @@ } #if OPT_BLINK_TEXT -static Bool -LineHasBlinking(TScreen * screen, LineData * ld) +Bool +LineHasBlinking(TScreen *screen, LineData *ld) { int col; Bool result = False; @@ -8472,7 +9917,7 @@ #endif /* OPT_BLINK_CURS || OPT_BLINK_TEXT */ void -RestartBlinking(TScreen * screen GCC_UNUSED) +RestartBlinking(TScreen *screen GCC_UNUSED) { #if OPT_BLINK_CURS || OPT_BLINK_TEXT if (screen->blink_timer == 0) { @@ -8536,7 +9981,7 @@ screen->cursor_set = ON; /* reset scrolling region */ - set_tb_margins(screen, 0, screen->max_row); + reset_margins(screen); bitclr(&xw->flags, ORIGIN); @@ -8558,6 +10003,8 @@ bitclr(&xw->flags, PROTECTED); screen->protected_mode = OFF_PROTECT; + reset_displayed_graphics(screen); + if (full) { /* RIS */ if (screen->bellOnReset) Bell(xw, XkbBI_TerminalBell, 0); @@ -8582,9 +10029,17 @@ xw->keyboard.flags |= MODE_DECBKM; TRACE(("full reset DECBKM %s\n", BtoS(xw->keyboard.flags & MODE_DECBKM))); +#if OPT_SIXEL_GRAPHICS + if (TScreenOf(xw)->sixel_scrolling) /* FIXME: should this be off unconditionally here? */ + xw->keyboard.flags |= MODE_DECSDM; + TRACE(("full reset DECSDM %s (resource default is %d)\n", + BtoS(xw->keyboard.flags & MODE_DECSDM), + TScreenOf(xw)->sixel_scrolling)); +#endif update_appcursor(); update_appkeypad(); update_decbkm(); + update_decsdm(); show_8bit_control(False); reset_decudk(); @@ -8764,7 +10219,7 @@ static void HandleKeymapChange(Widget w, XEvent * event GCC_UNUSED, - String * params, + String *params, Cardinal *param_count) { static XtTranslations keymap, original; @@ -8817,7 +10272,7 @@ static void HandleBell(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params, /* [0] = volume */ + String *params, /* [0] = volume */ Cardinal *param_count) /* 0 or 1 */ { int percent = (*param_count) ? atoi(params[0]) : 0; @@ -8829,7 +10284,7 @@ static void HandleVisualBell(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *param_count GCC_UNUSED) { VisualBell(); @@ -8839,7 +10294,7 @@ static void HandleIgnore(Widget w, XEvent * event, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *param_count GCC_UNUSED) { XtermWidget xw; @@ -8864,7 +10319,9 @@ { XtermWidget xw = getXtermWidget(w); - if ((xw == 0) || *type != XA_STRING || *format != 8) { + if (xw == 0) { + xtermWarning("unexpected widget in DoSetSelectedFont\n"); + } else if (*type != XA_STRING || *format != 8) { Bell(xw, XkbBI_MinorError, 0); } else { Boolean failed = False; @@ -8896,6 +10353,7 @@ XLFD allows up to 255 characters and no control characters; we are a little more liberal here. */ if (len < 1000 + && used != 0 && !strchr(used, '\n') && (test = x_strdup(used)) != 0) { TScreenOf(xw)->MenuFontName(fontMenu_fontsel) = test; @@ -8928,7 +10386,7 @@ { TScreen *screen = TScreenOf(xw); static AtomPtr *atoms; - unsigned int atomCount = 0; + static unsigned int atomCount = 0; AtomPtr *pAtom; unsigned a; Atom target; @@ -8940,12 +10398,16 @@ TRACE(("FindFontSelection(%s)\n", atom_name)); for (pAtom = atoms, a = atomCount; a; a--, pAtom++) { - if (strcmp(atom_name, XmuNameOfAtom(*pAtom)) == 0) + if (strcmp(atom_name, XmuNameOfAtom(*pAtom)) == 0) { + TRACE(("...found atom %d:%s\n", a + 1, atom_name)); break; + } } if (!a) { atoms = TypeXtReallocN(AtomPtr, atoms, atomCount + 1); *(pAtom = &atoms[atomCount]) = XmuMakeAtom(atom_name); + ++atomCount; + TRACE(("...added atom %d:%s\n", atomCount, atom_name)); } target = XmuInternAtom(XtDisplay(xw), *pAtom); diff -Nru xterm-278/charsets.c xterm-297/charsets.c --- xterm-278/charsets.c 2011-09-11 14:40:17.000000000 +0000 +++ xterm-297/charsets.c 2013-09-09 00:15:55.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: charsets.c,v 1.42 2011/09/11 14:40:17 tom Exp $ */ +/* $XTermId: charsets.c,v 1.65 2013/09/09 00:15:55 tom Exp $ */ /* - * Copyright 1998-2009,2011 by Thomas E. Dickey + * Copyright 1998-2011,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -55,188 +55,443 @@ * The latter reference, though easier to read, has a few errors and omissions. */ -/* - * Translate an input keysym to the corresponding NRC keysym. - */ -unsigned -xtermCharSetIn(unsigned code, int charset) -{ -#define MAP(to, from) case from: code = to; break +#define map_NRCS_Dutch(code) \ + switch (code) { \ + MAP(0x23, XK_sterling); \ + MAP(0x40, XK_threequarters); \ + UNI(0x5b, 0x0133); /* ij ligature */ \ + MAP(0x5c, XK_onehalf); \ + MAP(0x5d, XK_bar); \ + MAP(0x7b, XK_diaeresis); \ + UNI(0x7c, 0x0192); /* florin */ \ + MAP(0x7d, XK_onequarter); \ + MAP(0x7e, XK_acute); \ + } - if (code >= 128 && code < 256) { - switch (charset) { - case 'A': /* United Kingdom set (or Latin 1) */ - if (code == XK_sterling) - code = 0x23; - code &= 0x7f; - break; +#define map_NRCS_Finnish(code) \ + switch (code) { \ + MAP(0x5b, XK_Adiaeresis); \ + MAP(0x5c, XK_Odiaeresis); \ + MAP(0x5d, XK_Aring); \ + MAP(0x5e, XK_Udiaeresis); \ + MAP(0x60, XK_eacute); \ + MAP(0x7b, XK_adiaeresis); \ + MAP(0x7c, XK_odiaeresis); \ + MAP(0x7d, XK_aring); \ + MAP(0x7e, XK_udiaeresis); \ + } -#if OPT_XMC_GLITCH - case '?': -#endif - case '1': /* Alternate Character ROM standard characters */ - case '2': /* Alternate Character ROM special graphics */ - case 'B': /* ASCII set */ - break; - - case '0': /* special graphics (line drawing) */ - break; - - case '4': /* Dutch */ - switch (code) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_threequarters); - MAP(0x5b, XK_ydiaeresis); - MAP(0x5c, XK_onehalf); - MAP(0x5d, XK_bar); /* glyph is not ISO-8859-1 */ - MAP(0x7b, XK_diaeresis); - MAP(0x7c, XK_f); /* glyph is not ISO-8859-1 */ - MAP(0x7d, XK_onequarter); - MAP(0x7e, XK_acute); - } - break; +#define map_NRCS_French(code) \ + switch (code) { \ + MAP(0x23, XK_sterling); \ + MAP(0x40, XK_agrave); \ + MAP(0x5b, XK_degree); \ + MAP(0x5c, XK_ccedilla); \ + MAP(0x5d, XK_section); \ + MAP(0x7b, XK_eacute); \ + MAP(0x7c, XK_ugrave); \ + MAP(0x7d, XK_egrave); \ + MAP(0x7e, XK_diaeresis); \ + } - case 'C': - case '5': /* Finnish */ - switch (code) { - MAP(0x5b, XK_Adiaeresis); - MAP(0x5c, XK_Odiaeresis); - MAP(0x5d, XK_Aring); - MAP(0x5e, XK_Udiaeresis); - MAP(0x60, XK_eacute); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_aring); - MAP(0x7e, XK_udiaeresis); - } - break; +#define map_NRCS_French_Canadian(code) \ + switch (code) { \ + MAP(0x40, XK_agrave); \ + MAP(0x5b, XK_acircumflex); \ + MAP(0x5c, XK_ccedilla); \ + MAP(0x5d, XK_ecircumflex); \ + MAP(0x5e, XK_icircumflex); \ + MAP(0x60, XK_ocircumflex); \ + MAP(0x7b, XK_eacute); \ + MAP(0x7c, XK_ugrave); \ + MAP(0x7d, XK_egrave); \ + MAP(0x7e, XK_ucircumflex); \ + } - case 'R': /* French */ - switch (code) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_agrave); - MAP(0x5b, XK_degree); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_section); - MAP(0x7b, XK_eacute); - MAP(0x7c, XK_ugrave); - MAP(0x7d, XK_egrave); - MAP(0x7e, XK_diaeresis); - } - break; +#define map_NRCS_German(code) \ + switch (code) { \ + MAP(0x40, XK_section); \ + MAP(0x5b, XK_Adiaeresis); \ + MAP(0x5c, XK_Odiaeresis); \ + MAP(0x5d, XK_Udiaeresis); \ + MAP(0x7b, XK_adiaeresis); \ + MAP(0x7c, XK_odiaeresis); \ + MAP(0x7d, XK_udiaeresis); \ + MAP(0x7e, XK_ssharp); \ + } - case 'Q': /* French Canadian */ - switch (code) { - MAP(0x40, XK_agrave); - MAP(0x5b, XK_acircumflex); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_ecircumflex); - MAP(0x5e, XK_icircumflex); - MAP(0x60, XK_ocircumflex); - MAP(0x7b, XK_eacute); - MAP(0x7c, XK_ugrave); - MAP(0x7d, XK_egrave); - MAP(0x7e, XK_ucircumflex); - } - break; +#define map_NRCS_Italian(code) \ + switch (code) { \ + MAP(0x23, XK_sterling); \ + MAP(0x40, XK_section); \ + MAP(0x5b, XK_degree); \ + MAP(0x5c, XK_ccedilla); \ + MAP(0x5d, XK_eacute); \ + MAP(0x60, XK_ugrave); \ + MAP(0x7b, XK_agrave); \ + MAP(0x7c, XK_ograve); \ + MAP(0x7d, XK_egrave); \ + MAP(0x7e, XK_igrave); \ + } - case 'K': /* German */ - switch (code) { - MAP(0x40, XK_section); - MAP(0x5b, XK_Adiaeresis); - MAP(0x5c, XK_Odiaeresis); - MAP(0x5d, XK_Udiaeresis); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_udiaeresis); - MAP(0x7e, XK_ssharp); - } - break; +#define map_NRCS_Norwegian_Danish(code) \ + switch (code) { \ + MAP(0x40, XK_Adiaeresis); \ + MAP(0x5b, XK_AE); \ + MAP(0x5c, XK_Ooblique); \ + MAP(0x5d, XK_Aring); \ + MAP(0x5e, XK_Udiaeresis); \ + MAP(0x60, XK_adiaeresis); \ + MAP(0x7b, XK_ae); \ + MAP(0x7c, XK_oslash); \ + MAP(0x7d, XK_aring); \ + MAP(0x7e, XK_udiaeresis); \ + } - case 'Y': /* Italian */ - switch (code) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_section); - MAP(0x5b, XK_degree); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_eacute); - MAP(0x60, XK_ugrave); - MAP(0x7b, XK_agrave); - MAP(0x7c, XK_ograve); - MAP(0x7d, XK_egrave); - MAP(0x7e, XK_igrave); - } - break; +#define map_NRCS_Portuguese(code) \ + switch (code) { \ + MAP(0x5b, XK_Atilde); \ + MAP(0x5c, XK_Ccedilla); \ + MAP(0x5d, XK_Otilde); \ + MAP(0x7b, XK_atilde); \ + MAP(0x7c, XK_ccedilla); \ + MAP(0x7d, XK_otilde); \ + } - case 'E': - case '6': /* Norwegian/Danish */ - switch (code) { - MAP(0x40, XK_Adiaeresis); - MAP(0x5b, XK_AE); - MAP(0x5c, XK_Ooblique); - MAP(0x5d, XK_Aring); - MAP(0x5e, XK_Udiaeresis); - MAP(0x60, XK_adiaeresis); - MAP(0x7b, XK_ae); - MAP(0x7c, XK_oslash); - MAP(0x7d, XK_aring); - MAP(0x7e, XK_udiaeresis); - } - break; +#define map_NRCS_Spanish(code) \ + switch (code) { \ + MAP(0x23, XK_sterling); \ + MAP(0x40, XK_section); \ + MAP(0x5b, XK_exclamdown); \ + MAP(0x5c, XK_Ntilde); \ + MAP(0x5d, XK_questiondown); \ + MAP(0x7b, XK_degree); \ + MAP(0x7c, XK_ntilde); \ + MAP(0x7d, XK_ccedilla); \ + } - case 'Z': /* Spanish */ - switch (code) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_section); - MAP(0x5b, XK_exclamdown); - MAP(0x5c, XK_Ntilde); - MAP(0x5d, XK_questiondown); - MAP(0x7b, XK_degree); - MAP(0x7c, XK_ntilde); - MAP(0x7d, XK_ccedilla); - } - break; +#define map_NRCS_Swedish(code) \ + switch (code) { \ + MAP(0x40, XK_Eacute); \ + MAP(0x5b, XK_Adiaeresis); \ + MAP(0x5c, XK_Odiaeresis); \ + MAP(0x5d, XK_Aring); \ + MAP(0x5e, XK_Udiaeresis); \ + MAP(0x60, XK_eacute); \ + MAP(0x7b, XK_adiaeresis); \ + MAP(0x7c, XK_odiaeresis); \ + MAP(0x7d, XK_aring); \ + MAP(0x7e, XK_udiaeresis); \ + } - case 'H': - case '7': /* Swedish */ - switch (code) { - MAP(0x40, XK_Eacute); - MAP(0x5b, XK_Adiaeresis); - MAP(0x5c, XK_Odiaeresis); - MAP(0x5d, XK_Aring); - MAP(0x5e, XK_Udiaeresis); - MAP(0x60, XK_eacute); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_aring); - MAP(0x7e, XK_udiaeresis); - } - break; +#define map_NRCS_Swiss(code) \ + switch (code) { \ + MAP(0x23, XK_ugrave); \ + MAP(0x40, XK_agrave); \ + MAP(0x5b, XK_eacute); \ + MAP(0x5c, XK_ccedilla); \ + MAP(0x5d, XK_ecircumflex); \ + MAP(0x5e, XK_icircumflex); \ + MAP(0x5f, XK_egrave); \ + MAP(0x60, XK_ocircumflex); \ + MAP(0x7b, XK_adiaeresis); \ + MAP(0x7c, XK_odiaeresis); \ + MAP(0x7d, XK_udiaeresis); \ + MAP(0x7e, XK_ucircumflex); \ + } - case '=': /* Swiss */ - switch (code) { - MAP(0x23, XK_ugrave); - MAP(0x40, XK_agrave); - MAP(0x5b, XK_eacute); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_ecircumflex); - MAP(0x5e, XK_icircumflex); - MAP(0x5f, XK_egrave); - MAP(0x60, XK_ocircumflex); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_udiaeresis); - MAP(0x7e, XK_ucircumflex); - } - break; +/* + * Unlike NRCS, which splices a few characters onto ASCII, the supplementary + * character sets are complete, normally mapped to GR. Most of these mappings + * rely upon glyphs not found in ISO-8859-1. We can display most of those + * using Unicode, thereby supporting specialized applications that use SCS + * with luit, subject to the limitation that select/paste will give meaningless + * results in terms of the application which uses these mappings. + * + * Since the VT320, etc, use only 8-bit encodings, there is no plausible + * argument to be made that these mappings "use" UTF-8, even though there is + * a hidden step in the terminal emulator which relies upon UTF-8. + */ +#define map_SCS_DEC_Supp(code,dft) \ + switch (code) { \ + XXX(0x24, 0x2e2e); \ + XXX(0x26, 0x2e2e); \ + XXX(0x2c, 0x2e2e); \ + XXX(0x2d, 0x2e2e); \ + XXX(0x2e, 0x2e2e); \ + XXX(0x2f, 0x2e2e); \ + XXX(0x34, 0x2e2e); \ + XXX(0x38, 0x2e2e); \ + XXX(0x3e, 0x2e2e); \ + UNI(0x47, 0x2426); \ + MAP(0x48, 0xc7); \ + MAP(0x49, 0xc8); \ + MAP(0x4a, 0xc9); \ + MAP(0x4b, 0xca); \ + MAP(0x4c, 0xcb); \ + MAP(0x4d, 0xcc); \ + MAP(0x4e, 0xcd); \ + MAP(0x4f, 0xce); \ + XXX(0x50, 0x2e2e); \ + UNI(0x57, 0x0152); \ + XXX(0x5e, 0x2e2e); \ + XXX(0x70, 0x2e2e); \ + UNI(0x77, 0x0153); \ + MAP(0x7d, 0xff); \ + XXX(0x7e, 0x2e2e); \ + default: dft; break; \ + } - default: /* any character sets we don't recognize */ - break; +#define map_SCS_DEC_Supp_Graphic(code,dft) \ + switch (code) { \ + XXX(0x24, 0x2e2e); \ + XXX(0x26, 0x2e2e); \ + XXX(0x2c, 0x2e2e); \ + XXX(0x2d, 0x2e2e); \ + XXX(0x2e, 0x2e2e); \ + XXX(0x2f, 0x2e2e); \ + XXX(0x34, 0x2e2e); \ + XXX(0x38, 0x2e2e); \ + XXX(0x3e, 0x2e2e); \ + XXX(0x50, 0x2e2e); \ + UNI(0x57, 0x0152); \ + XXX(0x5e, 0x2e2e); \ + XXX(0x70, 0x2e2e); \ + UNI(0x77, 0x0153); \ + MAP(0x7d, 0xff); \ + XXX(0x7e, 0x2e2e); \ + XXX(0x7f, 0x2e2e); \ + default: dft; break; \ + } + + /* derived from http://www.vt100.net/charsets/technical.html */ +#if OPT_WIDE_CHARS +#define map_SCS_DEC_Technical(code) \ + switch (code) { \ + UNI(0x21, 0x23b7); /* RADICAL SYMBOL BOTTOM Centred left to right, so that it joins up with 02/02 */ \ + UNI(0x22, 0x250c); /* BOX DRAWINGS LIGHT DOWN AND RIGHT */ \ + UNI(0x23, 0x2500); /* BOX DRAWINGS LIGHT HORIZONTAL */ \ + UNI(0x24, 0x2320); /* TOP HALF INTEGRAL with the proviso that the stem is vertical, to join with 02/06 */ \ + UNI(0x25, 0x2321); /* BOTTOM HALF INTEGRAL with the proviso above. */ \ + UNI(0x26, 0x2502); /* BOX DRAWINGS LIGHT VERTICAL */ \ + UNI(0x27, 0x23a1); /* LEFT SQUARE BRACKET UPPER CORNER Joins vertically to 02/06, 02/08. Doesn't join to its right. */ \ + UNI(0x28, 0x23a3); /* LEFT SQUARE BRACKET LOWER CORNER Joins vertically to 02/06, 02/07. Doesn't join to its right. */ \ + UNI(0x29, 0x23a4); /* RIGHT SQUARE BRACKET UPPER CORNER Joins vertically to 026, 02a. Doesn't join to its left. */ \ + UNI(0x2a, 0x23a6); /* RIGHT SQUARE BRACKET LOWER CORNER Joins vertically to 026, 029. Doesn't join to its left. */ \ + UNI(0x2b, 0x239b); /* LEFT PARENTHESIS UPPER HOOK Joins vertically to 026, 02c, 02/15. Doesn't join to its right. */ \ + UNI(0x2c, 0x239d); /* LEFT PARENTHESIS LOWER HOOK Joins vertically to 026, 02b, 02/15. Doesn't join to its right. */ \ + UNI(0x2d, 0x239e); /* RIGHT PARENTHESIS UPPER HOOK Joins vertically to 026, 02e, 03/00. Doesn't join to its left. */ \ + UNI(0x2e, 0x23a0); /* RIGHT PARENTHESIS LOWER HOOK Joins vertically to 026, 02d, 03/00. Doesn't join to its left. */ \ + UNI(0x2f, 0x23a8); /* LEFT CURLY BRACKET MIDDLE PIECE Joins vertically to 026, 02b, 02c. */ \ + UNI(0x30, 0x23ac); /* RIGHT CURLY BRACKET MIDDLE PIECE Joins vertically to 02/06, 02d, 02e. */ \ + XXX(0x31, 0x2426); /* Top Left Sigma. Joins to right with 02/03, 03/05. Joins diagonally below right with 03/03, 03/07. */ \ + XXX(0x32, 0x2426); /* Bottom Left Sigma. Joins to right with 02/03, 03/06. Joins diagonally above right with 03/04, 03/07. */ \ + XXX(0x33, 0x2426); /* Top Diagonal Sigma. Line for joining 03/01 to 03/04 or 03/07. */ \ + XXX(0x34, 0x2426); /* Bottom Diagonal Sigma. Line for joining 03/02 to 03/03 or 03/07. */ \ + XXX(0x35, 0x2426); /* Top Right Sigma. Joins to left with 02/03, 03/01. */ \ + XXX(0x36, 0x2426); /* Bottom Right Sigma. Joins to left with 02/03, 03/02. */ \ + XXX(0x37, 0x2426); /* Middle Sigma. Joins diagonally with 03/01, 03/02, 03/03, 03/04. */ \ + XXX(0x38, 0x2426); /* undefined */ \ + XXX(0x39, 0x2426); /* undefined */ \ + XXX(0x3a, 0x2426); /* undefined */ \ + XXX(0x3b, 0x2426); /* undefined */ \ + UNI(0x3c, 0x2264); /* LESS-THAN OR EQUAL TO */ \ + UNI(0x3d, 0x2260); /* NOT EQUAL TO */ \ + UNI(0x3e, 0x2265); /* GREATER-THAN OR EQUAL TO */ \ + UNI(0x3f, 0x222B); /* INTEGRAL */ \ + UNI(0x40, 0x2234); /* THEREFORE */ \ + UNI(0x41, 0x221d); /* PROPORTIONAL TO */ \ + UNI(0x42, 0x221e); /* INFINITY */ \ + UNI(0x43, 0x00f7); /* DIVISION SIGN */ \ + UNI(0x44, 0x039a); /* GREEK CAPITAL DELTA */ \ + UNI(0x45, 0x2207); /* NABLA */ \ + UNI(0x46, 0x03a6); /* GREEK CAPITAL LETTER PHI */ \ + UNI(0x47, 0x0393); /* GREEK CAPITAL LETTER GAMMA */ \ + UNI(0x48, 0x223c); /* TILDE OPERATOR */ \ + UNI(0x49, 0x2243); /* ASYMPTOTICALLY EQUAL TO */ \ + UNI(0x4a, 0x0398); /* GREEK CAPITAL LETTER THETA */ \ + UNI(0x4b, 0x00d7); /* MULTIPLICATION SIGN */ \ + UNI(0x4c, 0x039b); /* GREEK CAPITAL LETTER LAMDA */ \ + UNI(0x4d, 0x21d4); /* LEFT RIGHT DOUBLE ARROW */ \ + UNI(0x4e, 0x21d2); /* RIGHTWARDS DOUBLE ARROW */ \ + UNI(0x4f, 0x2261); /* IDENTICAL TO */ \ + UNI(0x50, 0x03a0); /* GREEK CAPITAL LETTER PI */ \ + UNI(0x51, 0x03a8); /* GREEK CAPITAL LETTER PSI */ \ + UNI(0x52, 0x2426); /* undefined */ \ + UNI(0x53, 0x03a3); /* GREEK CAPITAL LETTER SIGMA */ \ + XXX(0x54, 0x2426); /* undefined */ \ + XXX(0x55, 0x2426); /* undefined */ \ + UNI(0x56, 0x221a); /* SQUARE ROOT */ \ + UNI(0x57, 0x03a9); /* GREEK CAPITAL LETTER OMEGA */ \ + UNI(0x58, 0x039e); /* GREEK CAPITAL LETTER XI */ \ + UNI(0x59, 0x03a5); /* GREEK CAPITAL LETTER UPSILON */ \ + UNI(0x5a, 0x2282); /* SUBSET OF */ \ + UNI(0x5b, 0x2283); /* SUPERSET OF */ \ + UNI(0x5c, 0x2229); /* INTERSECTION */ \ + UNI(0x5d, 0x222a); /* UNION */ \ + UNI(0x5e, 0x2227); /* LOGICAL AND */ \ + UNI(0x5f, 0x2228); /* LOGICAL OR */ \ + UNI(0x60, 0x00ac); /* NOT SIGN */ \ + UNI(0x61, 0x03b1); /* GREEK SMALL LETTER ALPHA */ \ + UNI(0x62, 0x03b2); /* GREEK SMALL LETTER BETA */ \ + UNI(0x63, 0x03c7); /* GREEK SMALL LETTER CHI */ \ + UNI(0x64, 0x03b4); /* GREEK SMALL LETTER DELTA */ \ + UNI(0x65, 0x03b5); /* GREEK SMALL LETTER EPSILON */ \ + UNI(0x66, 0x03c6); /* GREEK SMALL LETTER PHI */ \ + UNI(0x67, 0x03b3); /* GREEK SMALL LETTER GAMMA */ \ + UNI(0x68, 0x03b7); /* GREEK SMALL LETTER ETA */ \ + UNI(0x69, 0x03b9); /* GREEK SMALL LETTER IOTA */ \ + UNI(0x6a, 0x03b8); /* GREEK SMALL LETTER THETA */ \ + UNI(0x6b, 0x03ba); /* GREEK SMALL LETTER KAPPA */ \ + UNI(0x6c, 0x03bb); /* GREEK SMALL LETTER LAMDA */ \ + XXX(0x6d, 0x2426); /* undefined */ \ + UNI(0x6e, 0x03bd); /* GREEK SMALL LETTER NU */ \ + UNI(0x6f, 0x2202); /* PARTIAL DIFFERENTIAL */ \ + UNI(0x70, 0x03c0); /* GREEK SMALL LETTER PI */ \ + UNI(0x71, 0x03c8); /* GREEK SMALL LETTER PSI */ \ + UNI(0x72, 0x03c1); /* GREEK SMALL LETTER RHO */ \ + UNI(0x73, 0x03c3); /* GREEK SMALL LETTER SIGMA */ \ + UNI(0x74, 0x03c4); /* GREEK SMALL LETTER TAU */ \ + XXX(0x75, 0x2426); /* undefined */ \ + UNI(0x76, 0x0192); /* LATIN SMALL LETTER F WITH HOOK Probably chosen for its meaning of "function" */ \ + UNI(0x77, 0x03c9); /* GREEK SMALL LETTER OMEGA */ \ + UNI(0x78, 0x03bE); /* GREEK SMALL LETTER XI */ \ + UNI(0x79, 0x03c5); /* GREEK SMALL LETTER UPSILON */ \ + UNI(0x7a, 0x03b6); /* GREEK SMALL LETTER ZETA */ \ + UNI(0x7b, 0x2190); /* LEFTWARDS ARROW */ \ + UNI(0x7c, 0x2191); /* UPWARDS ARROW */ \ + UNI(0x7d, 0x2192); /* RIGHTWARDS ARROW */ \ + UNI(0x7e, 0x2193); /* DOWNWARDS ARROW */ \ } - code &= 0x7f; /* NRC in any case is 7-bit */ +#else +#define map_SCS_DEC_Technical(code) /* nothing */ +#endif /* OPT_WIDE_CHARS */ + +/* + * Translate an input keysym to the corresponding NRC keysym. + */ +unsigned +xtermCharSetIn(TScreen *screen, unsigned code, int charset) +{ +#define MAP(to, from) case from: code = to; break + +#if OPT_WIDE_CHARS +#define UNI(to, from) case from: if (screen->utf8_nrc_mode) code = to; break +#else +#define UNI(to, from) case from: break +#endif + +#define XXX(to, from) /* no defined mapping to 0..255 */ + + TRACE(("CHARSET-IN GL=%s(G%d) GR=%s(G%d) SS%d\n\t%s\n", + visibleScsCode(screen->gsets[screen->curgl]), screen->curgl, + visibleScsCode(screen->gsets[screen->curgr]), screen->curgr, + screen->curss, + visibleUChar(code))); + + switch (charset) { + case nrc_British: /* United Kingdom set (or Latin 1) */ + if (code == XK_sterling) + code = 0x23; + code &= 0x7f; + break; + +#if OPT_XMC_GLITCH + case nrc_Unknown: +#endif + case nrc_DEC_Alt_Chars: + case nrc_DEC_Alt_Graphics: + case nrc_ASCII: + break; + + case nrc_DEC_Spec_Graphic: + break; + + case nrc_DEC_Supp: + map_SCS_DEC_Supp(code, code &= 0x7f); + break; + + case nrc_DEC_Supp_Graphic: + map_SCS_DEC_Supp_Graphic(code, code |= 0x80); + break; + + case nrc_DEC_Technical: + map_SCS_DEC_Technical(code); + break; + + case nrc_Dutch: + map_NRCS_Dutch(code); + break; + + case nrc_Finnish: + case nrc_Finnish2: + map_NRCS_Finnish(code); + break; + + case nrc_French: + case nrc_French2: + map_NRCS_French(code); + break; + + case nrc_French_Canadian: + map_NRCS_French_Canadian(code); + break; + + case nrc_German: + map_NRCS_German(code); + break; + + case nrc_Hebrew: + case nrc_Hebrew2: + /* FIXME */ + break; + + case nrc_Italian: + map_NRCS_Italian(code); + break; + + case nrc_Norwegian_Danish: + case nrc_Norwegian_Danish2: + case nrc_Norwegian_Danish3: + map_NRCS_Norwegian_Danish(code); + break; + + case nrc_Portugese: + map_NRCS_Portuguese(code); + break; + + case nrc_SCS_NRCS: /* vt5xx - probably Serbo/Croatian */ + /* FIXME */ + break; + + case nrc_Spanish: + map_NRCS_Spanish(code); + break; + + case nrc_Swedish2: + case nrc_Swedish: + map_NRCS_Swedish(code); + break; + + case nrc_Swiss: + map_NRCS_Swiss(code); + break; + + case nrc_Turkish: + case nrc_Turkish2: + /* FIXME */ + break; + + default: /* any character sets we don't recognize */ + break; } + code &= 0x7f; /* NRC in any case is 7-bit */ + TRACE(("->\t%s\n", + visibleUChar(code))); return code; #undef MAP +#undef UNI +#undef XXX } /* @@ -244,7 +499,7 @@ * DEC graphic characters in cells 0-31, and otherwise is ISO-8859-1. */ int -xtermCharSetOut(XtermWidget xw, IChar * buf, IChar * ptr, int leftset) +xtermCharSetOut(XtermWidget xw, IChar *buf, IChar *ptr, int leftset) { IChar *s; TScreen *screen = TScreenOf(xw); @@ -253,11 +508,19 @@ #define MAP(from, to) case from: chr = to; break - TRACE(("CHARSET GL=%c(G%d) GR=%c(G%d) SS%d\n\t%s\n", - leftset, screen->curgl, - rightset, screen->curgr, +#if OPT_WIDE_CHARS +#define UNI(from, to) case from: if (screen->utf8_nrc_mode) chr = to; break +#define XXX(from, to) UNI(from, to) +#else +#define UNI(old, new) chr = old; break +#define XXX(from, to) /* nothing */ +#endif + + TRACE(("CHARSET-OUT GL=%s(G%d) GR=%s(G%d) SS%d\n\t%s\n", + visibleScsCode(leftset), screen->curgl, + visibleScsCode(rightset), screen->curgr, screen->curss, - visibleIChar(buf, (unsigned) (ptr - buf)))); + visibleIChars(buf, (unsigned) (ptr - buf)))); for (s = buf; s < ptr; ++s) { int eight = CharOf(E2A(*s)); @@ -272,22 +535,26 @@ * the replacement character and other non-8bit codes into bogus * 8bit codes. */ - if (screen->utf8_mode) { + if (screen->utf8_mode || screen->utf8_nrc_mode) { if (*s > 255) continue; } #endif + if (*s < 32) + continue; + switch (cs) { - case 'A': /* United Kingdom set (or Latin 1) */ + case nrc_British_Latin_1: + /* FALLTHRU */ + case nrc_British: /* United Kingdom set (or Latin 1) */ if ((xw->flags & NATIONAL) || (screen->vtXX_level <= 1)) { if (chr == 0x23) { -#if OPT_WIDE_CHARS - chr = (screen->utf8_mode - ? 0xa3 - : XTERM_POUND); -#else chr = XTERM_POUND; +#if OPT_WIDE_CHARS + if (screen->utf8_nrc_mode) { + chr = 0xa3; + } #endif } } else { @@ -296,17 +563,17 @@ break; #if OPT_XMC_GLITCH - case '?': + case nrc_Unknown: #endif - case '1': /* Alternate Character ROM standard characters */ - case '2': /* Alternate Character ROM special graphics */ - case 'B': /* ASCII set */ + case nrc_DEC_Alt_Chars: + case nrc_DEC_Alt_Graphics: + case nrc_ASCII: break; - case '0': /* special graphics (line drawing) */ + case nrc_DEC_Spec_Graphic: if (seven > 0x5f && seven <= 0x7e) { #if OPT_WIDE_CHARS - if (screen->utf8_mode) + if (screen->utf8_nrc_mode) chr = (int) dec2ucs((unsigned) (seven - 0x5f)); else #endif @@ -316,152 +583,80 @@ } break; - case '4': /* Dutch */ - switch (chr = seven) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_threequarters); - MAP(0x5b, XK_ydiaeresis); - MAP(0x5c, XK_onehalf); - MAP(0x5d, XK_bar); - MAP(0x7b, XK_diaeresis); - MAP(0x7c, XK_f); - MAP(0x7d, XK_onequarter); - MAP(0x7e, XK_acute); - } + case nrc_DEC_Supp: + map_SCS_DEC_Supp(chr = seven, chr |= 0x80); break; - case 'C': - case '5': /* Finnish */ - switch (chr = seven) { - MAP(0x5b, XK_Adiaeresis); - MAP(0x5c, XK_Odiaeresis); - MAP(0x5d, XK_Aring); - MAP(0x5e, XK_Udiaeresis); - MAP(0x60, XK_eacute); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_aring); - MAP(0x7e, XK_udiaeresis); - } + case nrc_DEC_Supp_Graphic: + map_SCS_DEC_Supp_Graphic(chr = seven, chr |= 0x80); break; - case 'R': /* French */ - switch (chr = seven) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_agrave); - MAP(0x5b, XK_degree); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_section); - MAP(0x7b, XK_eacute); - MAP(0x7c, XK_ugrave); - MAP(0x7d, XK_egrave); - MAP(0x7e, XK_diaeresis); - } + case nrc_DEC_Technical: + map_SCS_DEC_Technical(chr = seven); break; - case 'Q': /* French Canadian */ - switch (chr = seven) { - MAP(0x40, XK_agrave); - MAP(0x5b, XK_acircumflex); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_ecircumflex); - MAP(0x5e, XK_icircumflex); - MAP(0x60, XK_ocircumflex); - MAP(0x7b, XK_eacute); - MAP(0x7c, XK_ugrave); - MAP(0x7d, XK_egrave); - MAP(0x7e, XK_ucircumflex); - } + case nrc_Dutch: + map_NRCS_Dutch(chr = seven); break; - case 'K': /* German */ - switch (chr = seven) { - MAP(0x40, XK_section); - MAP(0x5b, XK_Adiaeresis); - MAP(0x5c, XK_Odiaeresis); - MAP(0x5d, XK_Udiaeresis); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_udiaeresis); - MAP(0x7e, XK_ssharp); - } + case nrc_Finnish: + case nrc_Finnish2: + map_NRCS_Finnish(chr = seven); break; - case 'Y': /* Italian */ - switch (chr = seven) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_section); - MAP(0x5b, XK_degree); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_eacute); - MAP(0x60, XK_ugrave); - MAP(0x7b, XK_agrave); - MAP(0x7c, XK_ograve); - MAP(0x7d, XK_egrave); - MAP(0x7e, XK_igrave); - } + case nrc_French: + case nrc_French2: + map_NRCS_French(chr = seven); break; - case 'E': - case '6': /* Norwegian/Danish */ - switch (chr = seven) { - MAP(0x40, XK_Adiaeresis); - MAP(0x5b, XK_AE); - MAP(0x5c, XK_Ooblique); - MAP(0x5d, XK_Aring); - MAP(0x5e, XK_Udiaeresis); - MAP(0x60, XK_adiaeresis); - MAP(0x7b, XK_ae); - MAP(0x7c, XK_oslash); - MAP(0x7d, XK_aring); - MAP(0x7e, XK_udiaeresis); - } + case nrc_French_Canadian: + case nrc_French_Canadian2: + map_NRCS_French_Canadian(chr = seven); break; - case 'Z': /* Spanish */ - switch (chr = seven) { - MAP(0x23, XK_sterling); - MAP(0x40, XK_section); - MAP(0x5b, XK_exclamdown); - MAP(0x5c, XK_Ntilde); - MAP(0x5d, XK_questiondown); - MAP(0x7b, XK_degree); - MAP(0x7c, XK_ntilde); - MAP(0x7d, XK_ccedilla); - } + case nrc_German: + map_NRCS_German(chr = seven); break; - case 'H': - case '7': /* Swedish */ - switch (chr = seven) { - MAP(0x40, XK_Eacute); - MAP(0x5b, XK_Adiaeresis); - MAP(0x5c, XK_Odiaeresis); - MAP(0x5d, XK_Aring); - MAP(0x5e, XK_Udiaeresis); - MAP(0x60, XK_eacute); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_aring); - MAP(0x7e, XK_udiaeresis); - } + case nrc_Hebrew: + case nrc_Hebrew2: + /* FIXME */ break; - case '=': /* Swiss */ - switch (chr = seven) { - MAP(0x23, XK_ugrave); - MAP(0x40, XK_agrave); - MAP(0x5b, XK_eacute); - MAP(0x5c, XK_ccedilla); - MAP(0x5d, XK_ecircumflex); - MAP(0x5e, XK_icircumflex); - MAP(0x5f, XK_egrave); - MAP(0x60, XK_ocircumflex); - MAP(0x7b, XK_adiaeresis); - MAP(0x7c, XK_odiaeresis); - MAP(0x7d, XK_udiaeresis); - MAP(0x7e, XK_ucircumflex); - } + case nrc_Italian: + map_NRCS_Italian(chr = seven); + break; + + case nrc_Norwegian_Danish: + case nrc_Norwegian_Danish2: + case nrc_Norwegian_Danish3: + map_NRCS_Norwegian_Danish(chr = seven); + break; + + case nrc_Portugese: + map_NRCS_Portuguese(chr = seven); + break; + + case nrc_SCS_NRCS: /* vt5xx - probably Serbo/Croatian */ + /* FIXME */ + break; + + case nrc_Spanish: + map_NRCS_Spanish(chr = seven); + break; + + case nrc_Swedish2: + case nrc_Swedish: + map_NRCS_Swedish(chr = seven); + break; + + case nrc_Swiss: + map_NRCS_Swiss(chr = seven); + break; + + case nrc_Turkish: + case nrc_Turkish2: + /* FIXME */ break; default: /* any character sets we don't recognize */ @@ -479,7 +674,9 @@ } TRACE(("%d\t%s\n", count, - visibleIChar(buf, (unsigned) (ptr - buf)))); + visibleIChars(buf, (unsigned) (ptr - buf)))); return count; #undef MAP +#undef UNI +#undef XXX } diff -Nru xterm-278/config.guess xterm-297/config.guess --- xterm-278/config.guess 2011-02-02 23:25:58.000000000 +0000 +++ xterm-297/config.guess 2012-10-06 11:54:45.000000000 +0000 @@ -2,9 +2,9 @@ # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, -# 2911 Free Software Foundation, Inc. +# 2011, 2012 Free Software Foundation, Inc. -timestamp='2011-01-01' +timestamp='2012-09-25' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -17,9 +17,7 @@ # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA -# 02110-1301, USA. +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -57,7 +55,7 @@ Originally written by Per Bothner. Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, -2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO @@ -145,7 +143,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or - # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, + # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward @@ -202,6 +200,10 @@ # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit ;; + *:Bitrig:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` + echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} + exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} @@ -220,10 +222,10 @@ exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in - *4.0) + *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; - *5.*) + *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac @@ -304,7 +306,7 @@ arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit ;; - arm:riscos:*:*|arm:RISCOS:*:*) + arm*:riscos:*:*|arm*:RISCOS:*:*) echo arm-unknown-riscos exit ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) @@ -600,50 +602,50 @@ sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case "${sc_cpu_version}" in - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in - 32) HP_ARCH="hppa2.0n" ;; - 64) HP_ARCH="hppa2.0w" ;; + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 + 532) # CPU_PA_RISC2_0 + case "${sc_kernel_bits}" in + 32) HP_ARCH="hppa2.0n" ;; + 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 - esac ;; - esac + esac ;; + esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + sed 's/^ //' << EOF >$dummy.c + + #define _HPUX_SOURCE + #include + #include + + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); - #define _HPUX_SOURCE - #include - #include - - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); - - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa @@ -792,21 +794,26 @@ echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) - case ${UNAME_MACHINE} in - pc98) - echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + UNAME_PROCESSOR=`/usr/bin/uname -p` + case ${UNAME_PROCESSOR} in amd64) echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; *) - echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; + *:MINGW64*:*) + echo ${UNAME_MACHINE}-pc-mingw64 + exit ;; *:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; + i*:MSYS*:*) + echo ${UNAME_MACHINE}-pc-msys + exit ;; i*:windows32*:*) # uname -m includes "-pc" on this system. echo ${UNAME_MACHINE}-mingw32 @@ -861,15 +868,22 @@ i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; + aarch64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + aarch64_be:Linux:*:*) + UNAME_MACHINE=aarch64_be + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; + EV5) UNAME_MACHINE=alphaev5 ;; + EV56) UNAME_MACHINE=alphaev56 ;; + PCA56) UNAME_MACHINE=alphapca56 ;; + PCA57) UNAME_MACHINE=alphapca56 ;; + EV6) UNAME_MACHINE=alphaev6 ;; + EV67) UNAME_MACHINE=alphaev67 ;; + EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi @@ -877,30 +891,39 @@ exit ;; arm*:Linux:*:*) eval $set_cc_for_build - if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null | \ - grep -q __ARM_EABI__ + if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_EABI__ then echo ${UNAME_MACHINE}-unknown-linux-gnu else - echo ${UNAME_MACHINE}-unknown-linux-gnueabi + if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_PCS_VFP + then + echo ${UNAME_MACHINE}-unknown-linux-gnueabi + else + echo ${UNAME_MACHINE}-unknown-linux-gnueabihf + fi fi exit ;; avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) - echo cris-axis-linux-gnu + echo ${UNAME_MACHINE}-axis-linux-gnu exit ;; crisv32:Linux:*:*) - echo crisv32-axis-linux-gnu + echo ${UNAME_MACHINE}-axis-linux-gnu exit ;; frv:Linux:*:*) - echo frv-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + hexagon:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; i*86:Linux:*:*) LIBC=gnu eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + sed 's/^ //' << EOF >$dummy.c #ifdef __dietlibc__ LIBC=dietlibc #endif @@ -937,7 +960,7 @@ test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; or32:Linux:*:*) - echo or32-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; padre:Linux:*:*) echo sparc-unknown-linux-gnu @@ -972,13 +995,13 @@ echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; tile*:Linux:*:*) - echo ${UNAME_MACHINE}-tilera-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; vax:Linux:*:*) echo ${UNAME_MACHINE}-dec-linux-gnu exit ;; x86_64:Linux:*:*) - echo x86_64-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; xtensa*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -1096,7 +1119,7 @@ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; + && { echo i486-ncr-sysv4; exit; } ;; NCR*:*:4.2:* | MPRAS*:*:4.2:*) OS_REL='.3' test -r /etc/.relid \ @@ -1139,8 +1162,8 @@ echo ns32k-sni-sysv fi exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says echo i586-unisys-sysv4 exit ;; *:UNIX_System_V:4*:FTX*) @@ -1168,9 +1191,9 @@ exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} + echo mips-nec-sysv${UNAME_RELEASE} else - echo mips-unknown-sysv${UNAME_RELEASE} + echo mips-unknown-sysv${UNAME_RELEASE} fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. @@ -1185,6 +1208,9 @@ BePC:Haiku:*:*) # Haiku running on Intel PC compatible. echo i586-pc-haiku exit ;; + x86_64:Haiku:*:*) + echo x86_64-unknown-haiku + exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; @@ -1215,12 +1241,12 @@ i386) eval $set_cc_for_build if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - UNAME_PROCESSOR="x86_64" - fi + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + UNAME_PROCESSOR="x86_64" + fi fi ;; unknown) UNAME_PROCESSOR=powerpc ;; esac @@ -1229,8 +1255,8 @@ *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = "x86"; then - UNAME_PROCESSOR=i386 - UNAME_MACHINE=pc + UNAME_PROCESSOR=i386 + UNAME_MACHINE=pc fi echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} exit ;; @@ -1240,7 +1266,7 @@ NEO-?:NONSTOP_KERNEL:*:*) echo neo-tandem-nsk${UNAME_RELEASE} exit ;; - NSE-?:NONSTOP_KERNEL:*:*) + NSE-*:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; NSR-?:NONSTOP_KERNEL:*:*) @@ -1309,11 +1335,11 @@ i*86:AROS:*:*) echo ${UNAME_MACHINE}-pc-aros exit ;; + x86_64:VMkernel:*:*) + echo ${UNAME_MACHINE}-unknown-esx + exit ;; esac -#echo '(No uname command or uname output not recognized.)' 1>&2 -#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 - eval $set_cc_for_build cat >$dummy.c < printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 - "4" + "4" #else - "" + "" #endif - ); exit (0); + ); exit (0); #endif #endif diff -Nru xterm-278/config.sub xterm-297/config.sub --- xterm-278/config.sub 2011-04-01 17:34:53.000000000 +0000 +++ xterm-297/config.sub 2012-10-06 11:54:54.000000000 +0000 @@ -1,10 +1,10 @@ #! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 -# 2011 Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011, 2012 Free Software Foundation, Inc. -timestamp='2011-04-01' +timestamp='2012-08-18' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -21,9 +21,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA -# 02110-1301, USA. +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -76,7 +74,7 @@ GNU config.sub ($timestamp) Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, -2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO @@ -125,13 +123,17 @@ maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ - linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ + linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ knetbsd*-gnu* | netbsd*-gnu* | \ kopensolaris*-gnu* | \ storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; + android-linux) + os=-linux-android + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown + ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] @@ -223,6 +225,12 @@ -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; + -lynx*178) + os=-lynxos178 + ;; + -lynx*5) + os=-lynxos5 + ;; -lynx*) os=-lynxos ;; @@ -247,17 +255,22 @@ # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ + | aarch64 | aarch64_be \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ + | be32 | be64 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ + | epiphany \ | fido | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | hexagon \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ + | le32 | le64 \ | lm32 \ | m32c | m32r | m32rle | m68000 | m68k | m88k \ | maxq | mb | microblaze | mcore | mep | metag \ @@ -291,7 +304,7 @@ | pdp10 | pdp11 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle \ | pyramid \ - | rx \ + | rl78 | rx \ | score \ | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ @@ -300,7 +313,7 @@ | spu \ | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ | ubicom32 \ - | v850 | v850e \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ | we32k \ | x86 | xc16x | xstormy16 | xtensa \ | z8k | z80) @@ -315,8 +328,7 @@ c6x) basic_machine=tic6x-unknown ;; - m6811 | m68hc11 | m6812 | m68hc12 | picochip) - # Motorola 68HC11/12. + m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip) basic_machine=$basic_machine-unknown os=-none ;; @@ -325,21 +337,28 @@ ms1) basic_machine=mt-unknown ;; + strongarm | thumb | xscale) basic_machine=arm-unknown ;; + xgate) + basic_machine=$basic_machine-unknown + os=-none + ;; xscaleeb) basic_machine=armeb-unknown ;; + xscaleel) basic_machine=armel-unknown ;; + # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) - basic_machine=$basic_machine-pc - ;; + basic_machine=$basic_machine-pc + ;; # Object if more than one company name word. *-*-*) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 @@ -348,11 +367,13 @@ # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ + | aarch64-* | aarch64_be-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* | avr32-* \ + | be32-* | be64-* \ | bfin-* | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* \ | clipper-* | craynv-* | cydra-* \ @@ -361,8 +382,10 @@ | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | hexagon-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ + | le32-* | le64-* \ | lm32-* \ | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ @@ -396,7 +419,7 @@ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ | pyramid-* \ - | romp-* | rs6000-* | rx-* \ + | rl78-* | romp-* | rs6000-* | rx-* \ | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ @@ -404,10 +427,11 @@ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ | tahoe-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ - | tile-* | tilegx-* \ + | tile*-* \ | tron-* \ | ubicom32-* \ - | v850-* | v850e-* | vax-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* \ | xstormy16-* | xtensa*-* \ @@ -707,7 +731,6 @@ i370-ibm* | ibm*) basic_machine=i370-ibm ;; -# I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 @@ -768,6 +791,10 @@ microblaze) basic_machine=microblaze-xilinx ;; + mingw64) + basic_machine=x86_64-pc + os=-mingw64 + ;; mingw32) basic_machine=i386-pc os=-mingw32 @@ -804,10 +831,18 @@ ms1-*) basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` ;; + msys) + basic_machine=i386-pc + os=-msys + ;; mvs) basic_machine=i370-ibm os=-mvs ;; + nacl) + basic_machine=le32-unknown + os=-nacl + ;; ncr3000) basic_machine=i486-ncr os=-sysv4 @@ -836,10 +871,10 @@ basic_machine=v70-nec os=-sysv ;; - next | m*-next) + next | m*-next ) basic_machine=m68k-next case $os in - -nextstep*) + -nextstep* ) ;; -ns2*) os=-nextstep2 @@ -958,11 +993,9 @@ pn) basic_machine=pn-gould ;; - power) - basic_machine=power-ibm + power) basic_machine=power-ibm ;; - ppc | ppcbe) - basic_machine=powerpc-unknown + ppc | ppcbe) basic_machine=powerpc-unknown ;; ppc-* | ppcbe-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` @@ -973,11 +1006,9 @@ ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` ;; - ppc64) - basic_machine=powerpc64-unknown + ppc64) basic_machine=powerpc64-unknown ;; - ppc64-*) - basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` + ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little | ppc64-le | powerpc64-little) basic_machine=powerpc64le-unknown @@ -1120,13 +1151,8 @@ basic_machine=t90-cray os=-unicos ;; - # This must be matched before tile*. - tilegx*) - basic_machine=tilegx-unknown - os=-linux-gnu - ;; tile*) - basic_machine=tile-unknown + basic_machine=$basic_machine-unknown os=-linux-gnu ;; tx39) @@ -1330,15 +1356,15 @@ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ - | -openbsd* | -solidbsd* \ + | -bitrig* | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* | -cegcc* \ - | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -linux-android* \ - | -linux-newlib* | -linux-uclibc* \ + | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ + | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-musl* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ @@ -1421,7 +1447,7 @@ -nova*) os=-rtmk-nova ;; - -ns2) + -ns2 ) os=-nextstep2 ;; -nsk*) @@ -1521,6 +1547,9 @@ c4x-* | tic4x-*) os=-coff ;; + hexagon-*) + os=-elf + ;; tic54x-*) os=-coff ;; @@ -1548,9 +1577,6 @@ ;; m68000-sun) os=-sunos3 - # This also exists in the configure program, but was not the - # default. - # os=-sunos4 ;; m68*-cisco) os=-aout @@ -1618,7 +1644,7 @@ m88k-omron*) os=-luna ;; - *-next) + *-next ) os=-nextstep ;; *-sequent) diff -Nru xterm-278/configure xterm-297/configure --- xterm-278/configure 2012-01-12 13:04:24.000000000 +0000 +++ xterm-297/configure 2013-08-04 19:49:46.000000000 +0000 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by Autoconf 2.52.20101002. +# Generated by Autoconf 2.52.20121002. # # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 # Free Software Foundation, Inc. @@ -170,15 +170,16 @@ bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' -datadir='${prefix}/share' +datarootdir='${prefix}/share' +datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' libdir='${exec_prefix}/lib' includedir='${prefix}/include' oldincludedir='/usr/include' -infodir='${prefix}/info' -mandir='${prefix}/man' +infodir='${datarootdir}/info' +mandir='${datarootdir}/man' # Identity of this package. PACKAGE_NAME= @@ -229,6 +230,13 @@ | --da=*) datadir=$ac_optarg ;; + -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ + | --dataroo | --dataro | --datar) + ac_prev=datarootdir ;; + -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ + | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) + datarootdir=$ac_optarg ;; + -disable-* | --disable-*) ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. @@ -504,7 +512,7 @@ done # Be sure to have absolute paths. -for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \ +for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \ localstatedir libdir includedir oldincludedir infodir mandir do eval ac_val=$`echo $ac_var` @@ -641,15 +649,16 @@ --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] - --datadir=DIR read-only architecture-independent data [PREFIX/share] + --datarootdir=DIR read-only architecture-independent data [PREFIX/share] + --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] - --infodir=DIR info documentation [PREFIX/info] - --mandir=DIR man documentation [PREFIX/man] + --infodir=DIR info documentation [DATAROOTDIR/info] + --mandir=DIR man documentation [DATAROOTDIR/man] EOF cat <<\EOF @@ -684,12 +693,17 @@ Compile/Install Options: --disable-full-tgetent disable check for full tgetent function --with-app-class=XXX override X applications class (default XTerm) - --with-app-defaults=DIR directory in which to install resource files (default: EPREFIX/lib/X11/app-defaults) - --with-icondir=DIR directory in which to install icons (default: EPREFIX/share/pixmaps) + --with-app-defaults=DIR directory in which to install resource files (EPREFIX/lib/X11/app-defaults) + --with-icon-name=XXXX override icon name (default: xterm-color) + --with-icon-symlink=XXX make symbolic link for icon name (default: xterm) + --with-pixmapdir=DIR directory in which to install pixmaps (DATADIR/pixmaps) + --with-icondir=DIR directory in which to install icons for desktop + --with-icon-theme=XXX install icons into desktop theme (hicolor) --disable-desktop disable install of xterm desktop files --with-desktop-category=XXX one or more desktop catgories or auto --with-reference=XXX program to use as permissions-reference --with-xterm-symlink=XXX make symbolic link to installed xterm + --disable-openpty disable openpty, prefer other interfaces --disable-setuid disable setuid in xterm, do not install setuid/setgid --disable-setgid disable setgid in xterm, do not install setuid/setgid --with-setuid=XXX use the given setuid user @@ -698,14 +712,20 @@ --with-tty-group=XXX use XXX for the tty-group --with-x use the X Window System --with-pkg-config{=path} enable/disable use of pkg-config + --with-xpm=DIR use Xpm library for colored icon, may specify path --with-Xaw3d link with Xaw 3d library --with-neXtaw link with neXT Athena library --with-XawPlus link with Athena-Plus library --enable-narrowproto enable narrow prototypes for X libraries --disable-imake disable use of imake for definitions Terminal Configuration: - --with-terminal-id=V set default decTerminalID (default: vt100) + --with-terminal-id=V set default decTerminalID (default: vt420) --with-terminal-type=T set default $TERM (default: xterm) + --enable-backarrow-key set default backarrowKey resource (default: true) + --enable-backarrow-is-erase set default backarrowKeyIsErase resource (default: false) + --enable-delete-is-del set default deleteIsDEL resource (default: maybe) + --enable-alt-sends-esc set default altSendsEscape resource (default: no) + --enable-meta-sends-esc set default metaSendsEscape resource (default: no) --with-own-terminfo=P set default $TERMINFO (default: from environment) Optional Features: --disable-active-icon disable X11R6.3 active-icon feature @@ -724,6 +744,7 @@ --disable-doublechars disable support for double-size chars --disable-boxchars disable fallback-support for box chars --enable-exec-xterm enable "spawn-new-terminal" action + --enable-double-buffer enable double-buffering --disable-freetype disable freetype library-support --with-freetype-config configure script to use for FreeType --with-freetype-cflags -D/-I options for compiling with FreeType @@ -754,18 +775,22 @@ --disable-tek4014 disable tek4014 emulation --enable-toolbar compile-in toolbar for pulldown menus --disable-vt52 disable VT52 emulation - --enable-mini-luit enable mini-luit (built-in Latin9 support) - --enable-luit enable luit filter (Unicode translation) - --enable-wide-chars enable wide-character support + --disable-wide-chars disable wide-character support --enable-16bit-chars enable 16-bit character support + --enable-mini-luit enable mini-luit (built-in Latin9 support) + --disable-luit enable luit filter (Unicode translation) --enable-dabbrev enable dynamic-abbreviation support --enable-dec-locator enable DECterm Locator support + --enable-sixel-graphics enable sixel graphics support --disable-rectangles disable VT420 rectangle support --disable-ziconbeep disable -ziconbeep option Testing/development Options: --enable-trace test: set to enable debugging traces - --disable-leaks test: set to test memory leaks - --disable-echo display "compiling" commands + --with-dmalloc test: use Gray Watson's dmalloc library + --with-dbmalloc test: use Conor Cahill's dbmalloc library + --with-valgrind test: use valgrind + --disable-leaks test: free permanent memory, analyze leaks + --disable-echo do not display "compiling" commands --enable-xmc-glitch test: enable xmc magic-cookie emulation --enable-warnings test: turn on GCC compiler warnings --disable-rpath-hack don't add rpath options for additional libraries @@ -838,7 +863,7 @@ running configure, to aid debugging if configure makes a mistake. It was created by $as_me, which was -generated by GNU Autoconf 2.52.20101002. Invocation command line was +generated by GNU Autoconf 2.52.20121002. Invocation command line was $ $0 $@ @@ -962,7 +987,7 @@ fi for ac_site_file in $CONFIG_SITE; do if test -r "$ac_site_file"; then - { echo "$as_me:965: loading site script $ac_site_file" >&5 + { echo "$as_me:990: loading site script $ac_site_file" >&5 echo "$as_me: loading site script $ac_site_file" >&6;} cat "$ac_site_file" >&5 . "$ac_site_file" @@ -973,7 +998,7 @@ # Some versions of bash will fail to source /dev/null (special # files actually), so we avoid doing that. if test -f "$cache_file"; then - { echo "$as_me:976: loading cache $cache_file" >&5 + { echo "$as_me:1001: loading cache $cache_file" >&5 echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . $cache_file;; @@ -981,7 +1006,7 @@ esac fi else - { echo "$as_me:984: creating cache $cache_file" >&5 + { echo "$as_me:1009: creating cache $cache_file" >&5 echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi @@ -997,21 +1022,21 @@ eval ac_new_val="\$ac_env_${ac_var}_value" case $ac_old_set,$ac_new_set in set,) - { echo "$as_me:1000: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 + { echo "$as_me:1025: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) - { echo "$as_me:1004: error: \`$ac_var' was not set in the previous run" >&5 + { echo "$as_me:1029: error: \`$ac_var' was not set in the previous run" >&5 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then - { echo "$as_me:1010: error: \`$ac_var' has changed since the previous run:" >&5 + { echo "$as_me:1035: error: \`$ac_var' has changed since the previous run:" >&5 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - { echo "$as_me:1012: former value: $ac_old_val" >&5 + { echo "$as_me:1037: former value: $ac_old_val" >&5 echo "$as_me: former value: $ac_old_val" >&2;} - { echo "$as_me:1014: current value: $ac_new_val" >&5 + { echo "$as_me:1039: current value: $ac_new_val" >&5 echo "$as_me: current value: $ac_new_val" >&2;} ac_cache_corrupted=: fi;; @@ -1030,9 +1055,9 @@ fi done if $ac_cache_corrupted; then - { echo "$as_me:1033: error: changes in the environment can compromise the build" >&5 + { echo "$as_me:1058: error: changes in the environment can compromise the build" >&5 echo "$as_me: error: changes in the environment can compromise the build" >&2;} - { { echo "$as_me:1035: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 + { { echo "$as_me:1060: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} { (exit 1); exit 1; }; } fi @@ -1053,10 +1078,10 @@ echo "#! $SHELL" >conftest.sh echo "exit 0" >>conftest.sh chmod +x conftest.sh -if { (echo "$as_me:1056: PATH=\".;.\"; conftest.sh") >&5 +if { (echo "$as_me:1081: PATH=\".;.\"; conftest.sh") >&5 (PATH=".;."; conftest.sh) 2>&5 ac_status=$? - echo "$as_me:1059: \$? = $ac_status" >&5 + echo "$as_me:1084: \$? = $ac_status" >&5 (exit $ac_status); }; then ac_path_separator=';' else @@ -1084,7 +1109,7 @@ fi done if test -z "$ac_aux_dir"; then - { { echo "$as_me:1087: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5 + { { echo "$as_me:1112: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;} { (exit 1); exit 1; }; } fi @@ -1094,11 +1119,11 @@ # Make sure we can run config.sub. $ac_config_sub sun4 >/dev/null 2>&1 || - { { echo "$as_me:1097: error: cannot run $ac_config_sub" >&5 + { { echo "$as_me:1122: error: cannot run $ac_config_sub" >&5 echo "$as_me: error: cannot run $ac_config_sub" >&2;} { (exit 1); exit 1; }; } -echo "$as_me:1101: checking build system type" >&5 +echo "$as_me:1126: checking build system type" >&5 echo $ECHO_N "checking build system type... $ECHO_C" >&6 if test "${ac_cv_build+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1107,16 +1132,16 @@ test -z "$ac_cv_build_alias" && ac_cv_build_alias=`$ac_config_guess` test -z "$ac_cv_build_alias" && - { { echo "$as_me:1110: error: cannot guess build type; you must specify one" >&5 + { { echo "$as_me:1135: error: cannot guess build type; you must specify one" >&5 echo "$as_me: error: cannot guess build type; you must specify one" >&2;} { (exit 1); exit 1; }; } ac_cv_build=`$ac_config_sub $ac_cv_build_alias` || - { { echo "$as_me:1114: error: $ac_config_sub $ac_cv_build_alias failed." >&5 + { { echo "$as_me:1139: error: $ac_config_sub $ac_cv_build_alias failed." >&5 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;} { (exit 1); exit 1; }; } fi -echo "$as_me:1119: result: $ac_cv_build" >&5 +echo "$as_me:1144: result: $ac_cv_build" >&5 echo "${ECHO_T}$ac_cv_build" >&6 build=$ac_cv_build build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` @@ -1124,7 +1149,7 @@ build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then - echo "$as_me:1127: checking host system type" >&5 + echo "$as_me:1152: checking host system type" >&5 echo $ECHO_N "checking host system type... $ECHO_C" >&6 if test "${ac_cv_host+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1133,12 +1158,12 @@ test -z "$ac_cv_host_alias" && ac_cv_host_alias=$ac_cv_build_alias ac_cv_host=`$ac_config_sub $ac_cv_host_alias` || - { { echo "$as_me:1136: error: $ac_config_sub $ac_cv_host_alias failed" >&5 + { { echo "$as_me:1161: error: $ac_config_sub $ac_cv_host_alias failed" >&5 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;} { (exit 1); exit 1; }; } fi -echo "$as_me:1141: result: $ac_cv_host" >&5 +echo "$as_me:1166: result: $ac_cv_host" >&5 echo "${ECHO_T}$ac_cv_host" >&6 host=$ac_cv_host host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` @@ -1152,7 +1177,8 @@ system_name="`(hostname) 2>/dev/null`" fi fi -test -n "$system_name" && cat >>confdefs.h <>confdefs.h <&5 +test -n "$cf_cv_system_name" && echo "$as_me:1192: result: Configuring for $cf_cv_system_name" >&5 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6 if test ".$system_name" != ".$cf_cv_system_name" ; then - echo "$as_me:1170: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5 + echo "$as_me:1196: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6 - { { echo "$as_me:1172: error: \"Please remove config.cache and try again.\"" >&5 + { { echo "$as_me:1198: error: \"Please remove config.cache and try again.\"" >&5 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;} { (exit 1); exit 1; }; } fi @@ -1194,7 +1220,7 @@ if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 -echo "$as_me:1197: checking for $ac_word" >&5 +echo "$as_me:1223: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1209,7 +1235,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_CC="${ac_tool_prefix}gcc" -echo "$as_me:1212: found $ac_dir/$ac_word" >&5 +echo "$as_me:1238: found $ac_dir/$ac_word" >&5 break done @@ -1217,10 +1243,10 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - echo "$as_me:1220: result: $CC" >&5 + echo "$as_me:1246: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else - echo "$as_me:1223: result: no" >&5 + echo "$as_me:1249: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -1229,7 +1255,7 @@ ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 -echo "$as_me:1232: checking for $ac_word" >&5 +echo "$as_me:1258: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1244,7 +1270,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_ac_ct_CC="gcc" -echo "$as_me:1247: found $ac_dir/$ac_word" >&5 +echo "$as_me:1273: found $ac_dir/$ac_word" >&5 break done @@ -1252,10 +1278,10 @@ fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then - echo "$as_me:1255: result: $ac_ct_CC" >&5 + echo "$as_me:1281: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6 else - echo "$as_me:1258: result: no" >&5 + echo "$as_me:1284: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -1268,7 +1294,7 @@ if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 -echo "$as_me:1271: checking for $ac_word" >&5 +echo "$as_me:1297: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1283,7 +1309,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_CC="${ac_tool_prefix}cc" -echo "$as_me:1286: found $ac_dir/$ac_word" >&5 +echo "$as_me:1312: found $ac_dir/$ac_word" >&5 break done @@ -1291,10 +1317,10 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - echo "$as_me:1294: result: $CC" >&5 + echo "$as_me:1320: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else - echo "$as_me:1297: result: no" >&5 + echo "$as_me:1323: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -1303,7 +1329,7 @@ ac_ct_CC=$CC # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 -echo "$as_me:1306: checking for $ac_word" >&5 +echo "$as_me:1332: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1318,7 +1344,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_ac_ct_CC="cc" -echo "$as_me:1321: found $ac_dir/$ac_word" >&5 +echo "$as_me:1347: found $ac_dir/$ac_word" >&5 break done @@ -1326,10 +1352,10 @@ fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then - echo "$as_me:1329: result: $ac_ct_CC" >&5 + echo "$as_me:1355: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6 else - echo "$as_me:1332: result: no" >&5 + echo "$as_me:1358: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -1342,7 +1368,7 @@ if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 -echo "$as_me:1345: checking for $ac_word" >&5 +echo "$as_me:1371: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1362,7 +1388,7 @@ continue fi ac_cv_prog_CC="cc" -echo "$as_me:1365: found $ac_dir/$ac_word" >&5 +echo "$as_me:1391: found $ac_dir/$ac_word" >&5 break done @@ -1384,10 +1410,10 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - echo "$as_me:1387: result: $CC" >&5 + echo "$as_me:1413: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else - echo "$as_me:1390: result: no" >&5 + echo "$as_me:1416: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -1398,7 +1424,7 @@ do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -echo "$as_me:1401: checking for $ac_word" >&5 +echo "$as_me:1427: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1413,7 +1439,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_CC="$ac_tool_prefix$ac_prog" -echo "$as_me:1416: found $ac_dir/$ac_word" >&5 +echo "$as_me:1442: found $ac_dir/$ac_word" >&5 break done @@ -1421,10 +1447,10 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - echo "$as_me:1424: result: $CC" >&5 + echo "$as_me:1450: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else - echo "$as_me:1427: result: no" >&5 + echo "$as_me:1453: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -1437,7 +1463,7 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:1440: checking for $ac_word" >&5 +echo "$as_me:1466: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -1452,7 +1478,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_ac_ct_CC="$ac_prog" -echo "$as_me:1455: found $ac_dir/$ac_word" >&5 +echo "$as_me:1481: found $ac_dir/$ac_word" >&5 break done @@ -1460,10 +1486,10 @@ fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then - echo "$as_me:1463: result: $ac_ct_CC" >&5 + echo "$as_me:1489: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6 else - echo "$as_me:1466: result: no" >&5 + echo "$as_me:1492: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -1475,32 +1501,32 @@ fi -test -z "$CC" && { { echo "$as_me:1478: error: no acceptable cc found in \$PATH" >&5 +test -z "$CC" && { { echo "$as_me:1504: error: no acceptable cc found in \$PATH" >&5 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;} { (exit 1); exit 1; }; } # Provide some information about the compiler. -echo "$as_me:1483:" \ +echo "$as_me:1509:" \ "checking for C compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` -{ (eval echo "$as_me:1486: \"$ac_compiler --version &5\"") >&5 +{ (eval echo "$as_me:1512: \"$ac_compiler --version &5\"") >&5 (eval $ac_compiler --version &5) 2>&5 ac_status=$? - echo "$as_me:1489: \$? = $ac_status" >&5 + echo "$as_me:1515: \$? = $ac_status" >&5 (exit $ac_status); } -{ (eval echo "$as_me:1491: \"$ac_compiler -v &5\"") >&5 +{ (eval echo "$as_me:1517: \"$ac_compiler -v &5\"") >&5 (eval $ac_compiler -v &5) 2>&5 ac_status=$? - echo "$as_me:1494: \$? = $ac_status" >&5 + echo "$as_me:1520: \$? = $ac_status" >&5 (exit $ac_status); } -{ (eval echo "$as_me:1496: \"$ac_compiler -V &5\"") >&5 +{ (eval echo "$as_me:1522: \"$ac_compiler -V &5\"") >&5 (eval $ac_compiler -V &5) 2>&5 ac_status=$? - echo "$as_me:1499: \$? = $ac_status" >&5 + echo "$as_me:1525: \$? = $ac_status" >&5 (exit $ac_status); } cat >conftest.$ac_ext <<_ACEOF -#line 1503 "configure" +#line 1529 "configure" #include "confdefs.h" int @@ -1516,13 +1542,13 @@ # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. -echo "$as_me:1519: checking for C compiler default output" >&5 +echo "$as_me:1545: checking for C compiler default output" >&5 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` -if { (eval echo "$as_me:1522: \"$ac_link_default\"") >&5 +if { (eval echo "$as_me:1548: \"$ac_link_default\"") >&5 (eval $ac_link_default) 2>&5 ac_status=$? - echo "$as_me:1525: \$? = $ac_status" >&5 + echo "$as_me:1551: \$? = $ac_status" >&5 (exit $ac_status); }; then # Find the output, starting from the most likely. This scheme is # not robust to junk in `.', hence go to wildcards (a.*) only as a last @@ -1545,34 +1571,34 @@ else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -{ { echo "$as_me:1548: error: C compiler cannot create executables" >&5 +{ { echo "$as_me:1574: error: C compiler cannot create executables" >&5 echo "$as_me: error: C compiler cannot create executables" >&2;} { (exit 77); exit 77; }; } fi ac_exeext=$ac_cv_exeext -echo "$as_me:1554: result: $ac_file" >&5 +echo "$as_me:1580: result: $ac_file" >&5 echo "${ECHO_T}$ac_file" >&6 # Check the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. -echo "$as_me:1559: checking whether the C compiler works" >&5 +echo "$as_me:1585: checking whether the C compiler works" >&5 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then if { ac_try='./$ac_file' - { (eval echo "$as_me:1565: \"$ac_try\"") >&5 + { (eval echo "$as_me:1591: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:1568: \$? = $ac_status" >&5 + echo "$as_me:1594: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else - { { echo "$as_me:1575: error: cannot run C compiled programs. + { { echo "$as_me:1601: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'." >&5 echo "$as_me: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'." >&2;} @@ -1580,24 +1606,24 @@ fi fi fi -echo "$as_me:1583: result: yes" >&5 +echo "$as_me:1609: result: yes" >&5 echo "${ECHO_T}yes" >&6 rm -f a.out a.exe conftest$ac_cv_exeext ac_clean_files=$ac_clean_files_save # Check the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. -echo "$as_me:1590: checking whether we are cross compiling" >&5 +echo "$as_me:1616: checking whether we are cross compiling" >&5 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6 -echo "$as_me:1592: result: $cross_compiling" >&5 +echo "$as_me:1618: result: $cross_compiling" >&5 echo "${ECHO_T}$cross_compiling" >&6 -echo "$as_me:1595: checking for executable suffix" >&5 +echo "$as_me:1621: checking for executable suffix" >&5 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6 -if { (eval echo "$as_me:1597: \"$ac_link\"") >&5 +if { (eval echo "$as_me:1623: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:1600: \$? = $ac_status" >&5 + echo "$as_me:1626: \$? = $ac_status" >&5 (exit $ac_status); }; then # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will @@ -1613,25 +1639,25 @@ esac done else - { { echo "$as_me:1616: error: cannot compute EXEEXT: cannot compile and link" >&5 + { { echo "$as_me:1642: error: cannot compute EXEEXT: cannot compile and link" >&5 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;} { (exit 1); exit 1; }; } fi rm -f conftest$ac_cv_exeext -echo "$as_me:1622: result: $ac_cv_exeext" >&5 +echo "$as_me:1648: result: $ac_cv_exeext" >&5 echo "${ECHO_T}$ac_cv_exeext" >&6 rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT -echo "$as_me:1628: checking for object suffix" >&5 +echo "$as_me:1654: checking for object suffix" >&5 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6 if test "${ac_cv_objext+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 1634 "configure" +#line 1660 "configure" #include "confdefs.h" int @@ -1643,10 +1669,10 @@ } _ACEOF rm -f conftest.o conftest.obj -if { (eval echo "$as_me:1646: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:1672: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:1649: \$? = $ac_status" >&5 + echo "$as_me:1675: \$? = $ac_status" >&5 (exit $ac_status); }; then for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do case $ac_file in @@ -1658,24 +1684,24 @@ else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -{ { echo "$as_me:1661: error: cannot compute OBJEXT: cannot compile" >&5 +{ { echo "$as_me:1687: error: cannot compute OBJEXT: cannot compile" >&5 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;} { (exit 1); exit 1; }; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi -echo "$as_me:1668: result: $ac_cv_objext" >&5 +echo "$as_me:1694: result: $ac_cv_objext" >&5 echo "${ECHO_T}$ac_cv_objext" >&6 OBJEXT=$ac_cv_objext ac_objext=$OBJEXT -echo "$as_me:1672: checking whether we are using the GNU C compiler" >&5 +echo "$as_me:1698: checking whether we are using the GNU C compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6 if test "${ac_cv_c_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 1678 "configure" +#line 1704 "configure" #include "confdefs.h" int @@ -1690,16 +1716,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:1693: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:1719: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:1696: \$? = $ac_status" >&5 + echo "$as_me:1722: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:1699: \"$ac_try\"") >&5 + { (eval echo "$as_me:1725: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:1702: \$? = $ac_status" >&5 + echo "$as_me:1728: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_compiler_gnu=yes else @@ -1711,19 +1737,19 @@ ac_cv_c_compiler_gnu=$ac_compiler_gnu fi -echo "$as_me:1714: result: $ac_cv_c_compiler_gnu" >&5 +echo "$as_me:1740: result: $ac_cv_c_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6 GCC=`test $ac_compiler_gnu = yes && echo yes` ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS CFLAGS="-g" -echo "$as_me:1720: checking whether $CC accepts -g" >&5 +echo "$as_me:1746: checking whether $CC accepts -g" >&5 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6 if test "${ac_cv_prog_cc_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 1726 "configure" +#line 1752 "configure" #include "confdefs.h" int @@ -1735,16 +1761,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:1738: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:1764: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:1741: \$? = $ac_status" >&5 + echo "$as_me:1767: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:1744: \"$ac_try\"") >&5 + { (eval echo "$as_me:1770: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:1747: \$? = $ac_status" >&5 + echo "$as_me:1773: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_prog_cc_g=yes else @@ -1754,7 +1780,7 @@ fi rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:1757: result: $ac_cv_prog_cc_g" >&5 +echo "$as_me:1783: result: $ac_cv_prog_cc_g" >&5 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6 if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS @@ -1781,16 +1807,16 @@ #endif _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:1784: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:1810: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:1787: \$? = $ac_status" >&5 + echo "$as_me:1813: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:1790: \"$ac_try\"") >&5 + { (eval echo "$as_me:1816: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:1793: \$? = $ac_status" >&5 + echo "$as_me:1819: \$? = $ac_status" >&5 (exit $ac_status); }; }; then for ac_declaration in \ ''\ @@ -1802,7 +1828,7 @@ 'void exit (int);' do cat >conftest.$ac_ext <<_ACEOF -#line 1805 "configure" +#line 1831 "configure" #include "confdefs.h" #include $ac_declaration @@ -1815,16 +1841,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:1818: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:1844: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:1821: \$? = $ac_status" >&5 + echo "$as_me:1847: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:1824: \"$ac_try\"") >&5 + { (eval echo "$as_me:1850: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:1827: \$? = $ac_status" >&5 + echo "$as_me:1853: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else @@ -1834,7 +1860,7 @@ fi rm -f conftest.$ac_objext conftest.$ac_ext cat >conftest.$ac_ext <<_ACEOF -#line 1837 "configure" +#line 1863 "configure" #include "confdefs.h" $ac_declaration int @@ -1846,16 +1872,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:1849: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:1875: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:1852: \$? = $ac_status" >&5 + echo "$as_me:1878: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:1855: \"$ac_try\"") >&5 + { (eval echo "$as_me:1881: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:1858: \$? = $ac_status" >&5 + echo "$as_me:1884: \$? = $ac_status" >&5 (exit $ac_status); }; }; then break else @@ -1883,13 +1909,214 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_main_return=return +GCC_VERSION=none +if test "$GCC" = yes ; then + echo "$as_me:1914: checking version of $CC" >&5 +echo $ECHO_N "checking version of $CC... $ECHO_C" >&6 + GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`" + test -z "$GCC_VERSION" && GCC_VERSION=unknown + echo "$as_me:1918: result: $GCC_VERSION" >&5 +echo "${ECHO_T}$GCC_VERSION" >&6 +fi + +echo "$as_me:1922: checking for $CC option to accept ANSI C" >&5 +echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6 +if test "${ac_cv_prog_cc_stdc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_cv_prog_cc_stdc=no +ac_save_CC=$CC +cat >conftest.$ac_ext <<_ACEOF +#line 1930 "configure" +#include "confdefs.h" +#include +#include +#include +#include +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +# Don't try gcc -ansi; that turns off useful extensions and +# breaks some systems' header files. +# AIX -qlanglvl=ansi +# Ultrix and OSF/1 -std1 +# HP-UX 10.20 and later -Ae +# HP-UX older versions -Aa -D_HPUX_SOURCE +# SVR4 -Xc -D__EXTENSIONS__ +for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +do + CC="$ac_save_CC $ac_arg" + rm -f conftest.$ac_objext +if { (eval echo "$as_me:1979: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:1982: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:1985: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:1988: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_prog_cc_stdc=$ac_arg +break +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +fi +rm -f conftest.$ac_objext +done +rm -f conftest.$ac_ext conftest.$ac_objext +CC=$ac_save_CC + +fi + +case "x$ac_cv_prog_cc_stdc" in + x|xno) + echo "$as_me:2005: result: none needed" >&5 +echo "${ECHO_T}none needed" >&6 ;; + *) + echo "$as_me:2008: result: $ac_cv_prog_cc_stdc" >&5 +echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6 + CC="$CC $ac_cv_prog_cc_stdc" ;; +esac + +# This should have been defined by AC_PROG_CC +: ${CC:=cc} + +echo "$as_me:2016: checking \$CC variable" >&5 +echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6 +case "$CC" in #(vi +*[\ \ ]-[IUD]*) + echo "$as_me:2020: result: broken" >&5 +echo "${ECHO_T}broken" >&6 + { echo "$as_me:2022: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5 +echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;} + # humor him... + cf_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'` + CC=`echo "$CC" | sed -e 's/[ ].*//'` + +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= +cf_new_extra_cppflags= + +for cf_add_cflags in $cf_flags +do +case $cf_fix_cppflags in +no) + case $cf_add_cflags in #(vi + -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi + case $cf_add_cflags in + -D*) + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=yes + + if test $cf_fix_cppflags = yes ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + elif test "${cf_tst_cflags}" = "\"'" ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + fi + ;; + esac + case "$CPPFLAGS" in + *$cf_add_cflags) #(vi + ;; + *) #(vi + case $cf_add_cflags in #(vi + -D*) + cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` + +CPPFLAGS=`echo "$CPPFLAGS" | \ + sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` + + ;; + esac + cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" + ;; + esac + ;; + *) + cf_new_cflags="$cf_new_cflags $cf_add_cflags" + ;; + esac + ;; +yes) + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; +esac +done + +if test -n "$cf_new_cflags" ; then + + CFLAGS="$CFLAGS $cf_new_cflags" +fi + +if test -n "$cf_new_cppflags" ; then + + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" +fi + +if test -n "$cf_new_extra_cppflags" ; then + + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" +fi + + ;; +*) + echo "$as_me:2108: result: ok" >&5 +echo "${ECHO_T}ok" >&6 + ;; +esac + ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_main_return=return -echo "$as_me:1892: checking how to run the C preprocessor" >&5 +echo "$as_me:2119: checking how to run the C preprocessor" >&5 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then @@ -1910,18 +2137,18 @@ # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF -#line 1913 "configure" +#line 2140 "configure" #include "confdefs.h" #include Syntax error _ACEOF -if { (eval echo "$as_me:1918: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:2145: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:1924: \$? = $ac_status" >&5 + echo "$as_me:2151: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -1944,17 +2171,17 @@ # OK, works on sane cases. Now check whether non-existent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF -#line 1947 "configure" +#line 2174 "configure" #include "confdefs.h" #include _ACEOF -if { (eval echo "$as_me:1951: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:2178: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:1957: \$? = $ac_status" >&5 + echo "$as_me:2184: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -1991,7 +2218,7 @@ else ac_cv_prog_CPP=$CPP fi -echo "$as_me:1994: result: $CPP" >&5 +echo "$as_me:2221: result: $CPP" >&5 echo "${ECHO_T}$CPP" >&6 ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes @@ -2001,18 +2228,18 @@ # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF -#line 2004 "configure" +#line 2231 "configure" #include "confdefs.h" #include Syntax error _ACEOF -if { (eval echo "$as_me:2009: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:2236: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:2015: \$? = $ac_status" >&5 + echo "$as_me:2242: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -2035,17 +2262,17 @@ # OK, works on sane cases. Now check whether non-existent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF -#line 2038 "configure" +#line 2265 "configure" #include "confdefs.h" #include _ACEOF -if { (eval echo "$as_me:2042: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:2269: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:2048: \$? = $ac_status" >&5 + echo "$as_me:2275: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -2073,7 +2300,7 @@ if $ac_preproc_ok; then : else - { { echo "$as_me:2076: error: C preprocessor \"$CPP\" fails sanity check" >&5 + { { echo "$as_me:2303: error: C preprocessor \"$CPP\" fails sanity check" >&5 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;} { (exit 1); exit 1; }; } fi @@ -2085,54 +2312,11 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_main_return=return -if test $ac_cv_c_compiler_gnu = yes; then - echo "$as_me:2089: checking whether $CC needs -traditional" >&5 -echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6 -if test "${ac_cv_prog_gcc_traditional+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_pattern="Autoconf.*'x'" - cat >conftest.$ac_ext <<_ACEOF -#line 2096 "configure" -#include "confdefs.h" -#include -int Autoconf = TIOCGETP; -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "$ac_pattern" >/dev/null 2>&1; then - ac_cv_prog_gcc_traditional=yes -else - ac_cv_prog_gcc_traditional=no -fi -rm -rf conftest* - - if test $ac_cv_prog_gcc_traditional = no; then - cat >conftest.$ac_ext <<_ACEOF -#line 2111 "configure" -#include "confdefs.h" -#include -int Autoconf = TCGETA; -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "$ac_pattern" >/dev/null 2>&1; then - ac_cv_prog_gcc_traditional=yes -fi -rm -rf conftest* - - fi -fi -echo "$as_me:2124: result: $ac_cv_prog_gcc_traditional" >&5 -echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6 - if test $ac_cv_prog_gcc_traditional = yes; then - CC="$CC -traditional" - fi -fi - for ac_prog in mawk gawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:2135: checking for $ac_word" >&5 +echo "$as_me:2319: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_AWK+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -2147,7 +2331,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_AWK="$ac_prog" -echo "$as_me:2150: found $ac_dir/$ac_word" >&5 +echo "$as_me:2334: found $ac_dir/$ac_word" >&5 break done @@ -2155,16 +2339,63 @@ fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then - echo "$as_me:2158: result: $AWK" >&5 + echo "$as_me:2342: result: $AWK" >&5 echo "${ECHO_T}$AWK" >&6 else - echo "$as_me:2161: result: no" >&5 + echo "$as_me:2345: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$AWK" && break done +# Extract the first word of "groff", so it can be a program name with args. +set dummy groff; ac_word=$2 +echo "$as_me:2354: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_path_GROFF_PATH+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + case $GROFF_PATH in + [\\/]* | ?:[\\/]*) + ac_cv_path_GROFF_PATH="$GROFF_PATH" # Let the user override the test with a path. + ;; + *) + ac_save_IFS=$IFS; IFS=$ac_path_separator +ac_dummy="$PATH" +for ac_dir in $ac_dummy; do + IFS=$ac_save_IFS + test -z "$ac_dir" && ac_dir=. + if $as_executable_p "$ac_dir/$ac_word"; then + ac_cv_path_GROFF_PATH="$ac_dir/$ac_word" + echo "$as_me:2371: found $ac_dir/$ac_word" >&5 + break +fi +done + + test -z "$ac_cv_path_GROFF_PATH" && ac_cv_path_GROFF_PATH="no" + ;; +esac +fi +GROFF_PATH=$ac_cv_path_GROFF_PATH + +if test -n "$GROFF_PATH"; then + echo "$as_me:2383: result: $GROFF_PATH" >&5 +echo "${ECHO_T}$GROFF_PATH" >&6 +else + echo "$as_me:2386: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + +if test "x$GROFF_PATH" = xno +then + NROFF_NOTE= + GROFF_NOTE="#" +else + NROFF_NOTE="#" + GROFF_NOTE= +fi + # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: @@ -2177,7 +2408,7 @@ # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # ./install, which can be erroneously created by make from ./install.sh. -echo "$as_me:2180: checking for a BSD compatible install" >&5 +echo "$as_me:2411: checking for a BSD compatible install" >&5 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6 if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then @@ -2226,7 +2457,7 @@ INSTALL=$ac_install_sh fi fi -echo "$as_me:2229: result: $INSTALL" >&5 +echo "$as_me:2460: result: $INSTALL" >&5 echo "${ECHO_T}$INSTALL" >&6 # Use test -z because SunOS4 sh mishandles braces in ${var-val}. @@ -2237,14 +2468,14 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' -echo "$as_me:2240: checking whether ln -s works" >&5 +echo "$as_me:2471: checking whether ln -s works" >&5 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6 LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then - echo "$as_me:2244: result: yes" >&5 + echo "$as_me:2475: result: yes" >&5 echo "${ECHO_T}yes" >&6 else - echo "$as_me:2247: result: no, using $LN_S" >&5 + echo "$as_me:2478: result: no, using $LN_S" >&5 echo "${ECHO_T}no, using $LN_S" >&6 fi @@ -2265,7 +2496,7 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:2268: checking for $ac_word" >&5 +echo "$as_me:2499: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_LINT+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -2280,7 +2511,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_LINT="$ac_prog" -echo "$as_me:2283: found $ac_dir/$ac_word" >&5 +echo "$as_me:2514: found $ac_dir/$ac_word" >&5 break done @@ -2288,330 +2519,307 @@ fi LINT=$ac_cv_prog_LINT if test -n "$LINT"; then - echo "$as_me:2291: result: $LINT" >&5 + echo "$as_me:2522: result: $LINT" >&5 echo "${ECHO_T}$LINT" >&6 else - echo "$as_me:2294: result: no" >&5 + echo "$as_me:2525: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$LINT" && break done -### checks for UNIX variants that set C preprocessor variables - -echo "$as_me:2303: checking for AIX" >&5 -echo $ECHO_N "checking for AIX... $ECHO_C" >&6 -cat >conftest.$ac_ext <<_ACEOF -#line 2306 "configure" -#include "confdefs.h" -#ifdef _AIX - yes -#endif +### checks for compiler characteristics -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "yes" >/dev/null 2>&1; then - echo "$as_me:2315: result: yes" >&5 -echo "${ECHO_T}yes" >&6 -cat >>confdefs.h <<\EOF -#define _ALL_SOURCE 1 -EOF +cf_XOPEN_SOURCE=500 +cf_POSIX_C_SOURCE=199506L +cf_xopen_source= -else - echo "$as_me:2322: result: no" >&5 -echo "${ECHO_T}no" >&6 -fi -rm -rf conftest* - -echo "$as_me:2327: checking for POSIXized ISC" >&5 -echo $ECHO_N "checking for POSIXized ISC... $ECHO_C" >&6 -if test -d /etc/conf/kconfig.d && - grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 -then - echo "$as_me:2332: result: yes" >&5 -echo "${ECHO_T}yes" >&6 - ISC=yes # If later tests want to check for ISC. - -cat >>confdefs.h <<\EOF -#define _POSIX_SOURCE 1 -EOF - - if test "$GCC" = yes; then - CC="$CC -posix" - else - CC="$CC -Xp" - fi -else - echo "$as_me:2346: result: no" >&5 -echo "${ECHO_T}no" >&6 - ISC= -fi - -### checks for compiler characteristics - -# This should have been defined by AC_PROG_CC -: ${CC:=cc} - -# Check for user's environment-breakage by stuffing CFLAGS/CPPFLAGS content -# into CC. This will not help with broken scripts that wrap the compiler with -# options, but eliminates a more common category of user confusion. -echo "$as_me:2359: checking \$CC variable" >&5 -echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6 -case "$CC" in #(vi -*[\ \ ]-[IUD]*) - echo "$as_me:2363: result: broken" >&5 -echo "${ECHO_T}broken" >&6 - { echo "$as_me:2365: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5 -echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;} - # humor him... - cf_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'` - CC=`echo "$CC" | sed -e 's/[ ].*//'` - -cf_fix_cppflags=no -cf_new_cflags= -cf_new_cppflags= -cf_new_extra_cppflags= - -for cf_add_cflags in $cf_flags -do -case $cf_fix_cppflags in -no) - case $cf_add_cflags in #(vi - -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi - case $cf_add_cflags in - -D*) - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=yes - - if test $cf_fix_cppflags = yes ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - elif test "${cf_tst_cflags}" = "\"'" ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - fi - ;; - esac - case "$CPPFLAGS" in - *$cf_add_cflags) #(vi - ;; - *) #(vi - case $cf_add_cflags in #(vi - -D*) - cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` - -CPPFLAGS=`echo "$CPPFLAGS" | \ - sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` - - ;; - esac - cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" - ;; - esac - ;; - *) - cf_new_cflags="$cf_new_cflags $cf_add_cflags" - ;; - esac +case $host_os in #(vi +aix[4-7]*) #(vi + cf_xopen_source="-D_ALL_SOURCE" ;; -yes) - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=no +cygwin) #(vi + cf_XOPEN_SOURCE=600 ;; -esac -done - -if test -n "$cf_new_cflags" ; then - - CFLAGS="$CFLAGS $cf_new_cflags" -fi - -if test -n "$cf_new_cppflags" ; then - - CPPFLAGS="$CPPFLAGS $cf_new_cppflags" -fi - -if test -n "$cf_new_extra_cppflags" ; then - - EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" -fi - +darwin[0-8].*) #(vi + cf_xopen_source="-D_APPLE_C_SOURCE" ;; -*) - echo "$as_me:2451: result: ok" >&5 -echo "${ECHO_T}ok" >&6 +darwin*) #(vi + cf_xopen_source="-D_DARWIN_C_SOURCE" + cf_XOPEN_SOURCE= ;; -esac - -echo "$as_me:2456: checking for ${CC:-cc} option to accept ANSI C" >&5 -echo $ECHO_N "checking for ${CC:-cc} option to accept ANSI C... $ECHO_C" >&6 -if test "${cf_cv_ansi_cc+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - -cf_cv_ansi_cc=no -cf_save_CFLAGS="$CFLAGS" -cf_save_CPPFLAGS="$CPPFLAGS" -# Don't try gcc -ansi; that turns off useful extensions and -# breaks some systems' header files. -# AIX -qlanglvl=ansi -# Ultrix and OSF/1 -std1 -# HP-UX -Aa -D_HPUX_SOURCE -# SVR4 -Xc -# UnixWare 1.2 (cannot use -Xc, since ANSI/POSIX clashes) -for cf_arg in "-DCC_HAS_PROTOS" \ - "" \ - -qlanglvl=ansi \ - -std1 \ - -Ae \ - "-Aa -D_HPUX_SOURCE" \ - -Xc -do - -cf_fix_cppflags=no -cf_new_cflags= -cf_new_cppflags= -cf_new_extra_cppflags= - -for cf_add_cflags in $cf_arg -do -case $cf_fix_cppflags in -no) - case $cf_add_cflags in #(vi - -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi - case $cf_add_cflags in - -D*) - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=yes - - if test $cf_fix_cppflags = yes ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - elif test "${cf_tst_cflags}" = "\"'" ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - fi - ;; - esac - case "$CPPFLAGS" in - *$cf_add_cflags) #(vi - ;; - *) #(vi - case $cf_add_cflags in #(vi - -D*) - cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` - -CPPFLAGS=`echo "$CPPFLAGS" | \ - sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` - - ;; - esac - cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" - ;; - esac - ;; - *) - cf_new_cflags="$cf_new_cflags $cf_add_cflags" - ;; - esac +freebsd*|dragonfly*) #(vi + # 5.x headers associate + # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L + # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L + cf_POSIX_C_SOURCE=200112L + cf_XOPEN_SOURCE=600 + cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" ;; -yes) - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=no +hpux11*) #(vi + cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500" ;; -esac -done - -if test -n "$cf_new_cflags" ; then - - CFLAGS="$CFLAGS $cf_new_cflags" -fi - -if test -n "$cf_new_cppflags" ; then - - CPPFLAGS="$CPPFLAGS $cf_new_cppflags" -fi - -if test -n "$cf_new_extra_cppflags" ; then +hpux*) #(vi + cf_xopen_source="-D_HPUX_SOURCE" + ;; +irix[56].*) #(vi + cf_xopen_source="-D_SGI_SOURCE" + cf_XOPEN_SOURCE= + ;; +linux*|gnu*|mint*|k*bsd*-gnu) #(vi - EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" -fi +echo "$as_me:2572: checking if we must define _GNU_SOURCE" >&5 +echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6 +if test "${cf_cv_gnu_source+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else - cat >conftest.$ac_ext <<_ACEOF -#line 2560 "configure" +cat >conftest.$ac_ext <<_ACEOF +#line 2579 "configure" #include "confdefs.h" - -#ifndef CC_HAS_PROTOS -#if !defined(__STDC__) || (__STDC__ != 1) -choke me -#endif -#endif - +#include int main () { - int test (int i, double x); - struct s1 {int (*f) (int a);}; - struct s2 {int (*f) (double a);}; +#ifndef _XOPEN_SOURCE +make an error +#endif ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:2581: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:2594: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:2584: \$? = $ac_status" >&5 + echo "$as_me:2597: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:2587: \"$ac_try\"") >&5 + { (eval echo "$as_me:2600: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:2590: \$? = $ac_status" >&5 + echo "$as_me:2603: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_ansi_cc="$cf_arg"; break + cf_cv_gnu_source=no else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -fi -rm -f conftest.$ac_objext conftest.$ac_ext -done -CFLAGS="$cf_save_CFLAGS" -CPPFLAGS="$cf_save_CPPFLAGS" - -fi -echo "$as_me:2603: result: $cf_cv_ansi_cc" >&5 -echo "${ECHO_T}$cf_cv_ansi_cc" >&6 - -if test "$cf_cv_ansi_cc" != "no"; then -if test ".$cf_cv_ansi_cc" != ".-DCC_HAS_PROTOS"; then +cf_save="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" + cat >conftest.$ac_ext <<_ACEOF +#line 2612 "configure" +#include "confdefs.h" +#include +int +main () +{ -cf_fix_cppflags=no -cf_new_cflags= -cf_new_cppflags= +#ifdef _XOPEN_SOURCE +make an error +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:2627: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:2630: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:2633: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:2636: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cf_cv_gnu_source=no +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +cf_cv_gnu_source=yes +fi +rm -f conftest.$ac_objext conftest.$ac_ext + CPPFLAGS="$cf_save" + +fi +rm -f conftest.$ac_objext conftest.$ac_ext + +fi +echo "$as_me:2651: result: $cf_cv_gnu_source" >&5 +echo "${ECHO_T}$cf_cv_gnu_source" >&6 +test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" + + ;; +mirbsd*) #(vi + # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks and other headers which use u_int / u_short types + cf_XOPEN_SOURCE= + +cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE + +cf_save_CFLAGS="$CFLAGS" +cf_save_CPPFLAGS="$CPPFLAGS" + +cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \ + sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` + +cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \ + sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` + +echo "$as_me:2673: checking if we should define _POSIX_C_SOURCE" >&5 +echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6 +if test "${cf_cv_posix_c_source+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + +echo "${as_me:-configure}:2679: testing if the symbol is already defined go no further ..." 1>&5 + + cat >conftest.$ac_ext <<_ACEOF +#line 2682 "configure" +#include "confdefs.h" +#include +int +main () +{ + +#ifndef _POSIX_C_SOURCE +make an error +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:2697: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:2700: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:2703: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:2706: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cf_cv_posix_c_source=no +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +cf_want_posix_source=no + case .$cf_POSIX_C_SOURCE in #(vi + .[12]??*) #(vi + cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" + ;; + .2) #(vi + cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" + cf_want_posix_source=yes + ;; + .*) + cf_want_posix_source=yes + ;; + esac + if test "$cf_want_posix_source" = yes ; then + cat >conftest.$ac_ext <<_ACEOF +#line 2727 "configure" +#include "confdefs.h" +#include +int +main () +{ + +#ifdef _POSIX_SOURCE +make an error +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:2742: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:2745: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:2748: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:2751: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + : +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE" +fi +rm -f conftest.$ac_objext conftest.$ac_ext + fi + +echo "${as_me:-configure}:2762: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 + + CFLAGS="$cf_trim_CFLAGS" + CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source" + +echo "${as_me:-configure}:2767: testing if the second compile does not leave our definition intact error ..." 1>&5 + + cat >conftest.$ac_ext <<_ACEOF +#line 2770 "configure" +#include "confdefs.h" +#include +int +main () +{ + +#ifndef _POSIX_C_SOURCE +make an error +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:2785: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:2788: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:2791: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:2794: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + : +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +cf_cv_posix_c_source=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext + CFLAGS="$cf_save_CFLAGS" + CPPFLAGS="$cf_save_CPPFLAGS" + +fi +rm -f conftest.$ac_objext conftest.$ac_ext + +fi +echo "$as_me:2810: result: $cf_cv_posix_c_source" >&5 +echo "${ECHO_T}$cf_cv_posix_c_source" >&6 + +if test "$cf_cv_posix_c_source" != no ; then + CFLAGS="$cf_trim_CFLAGS" + CPPFLAGS="$cf_trim_CPPFLAGS" + +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= cf_new_extra_cppflags= -for cf_add_cflags in $cf_cv_ansi_cc +for cf_add_cflags in $cf_cv_posix_c_source do case $cf_fix_cppflags in no) @@ -2684,340 +2892,215 @@ EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" fi -else - cat >>confdefs.h <<\EOF -#define CC_HAS_PROTOS 1 -EOF - -fi fi -echo "$as_me:2695: checking for $CC option to accept ANSI C" >&5 -echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6 -if test "${ac_cv_prog_cc_stdc+set}" = set; then + ;; +netbsd*) #(vi + cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw + ;; +openbsd[4-9]*) #(vi + # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw + cf_xopen_source="-D_BSD_SOURCE" + cf_XOPEN_SOURCE=600 + ;; +openbsd*) #(vi + # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw + ;; +osf[45]*) #(vi + cf_xopen_source="-D_OSF_SOURCE" + ;; +nto-qnx*) #(vi + cf_xopen_source="-D_QNX_SOURCE" + ;; +sco*) #(vi + # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer + ;; +solaris2.*) #(vi + cf_xopen_source="-D__EXTENSIONS__" + ;; +*) + +echo "$as_me:2923: checking if we should define _XOPEN_SOURCE" >&5 +echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6 +if test "${cf_cv_xopen_source+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - ac_cv_prog_cc_stdc=no -ac_save_CC=$CC -cat >conftest.$ac_ext <<_ACEOF -#line 2703 "configure" + + cat >conftest.$ac_ext <<_ACEOF +#line 2930 "configure" #include "confdefs.h" -#include -#include + +#include +#include #include -#include -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; + int main () { -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + +#ifndef _XOPEN_SOURCE +make an error +#endif ; return 0; } _ACEOF -# Don't try gcc -ansi; that turns off useful extensions and -# breaks some systems' header files. -# AIX -qlanglvl=ansi -# Ultrix and OSF/1 -std1 -# HP-UX 10.20 and later -Ae -# HP-UX older versions -Aa -D_HPUX_SOURCE -# SVR4 -Xc -D__EXTENSIONS__ -for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - rm -f conftest.$ac_objext -if { (eval echo "$as_me:2752: \"$ac_compile\"") >&5 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:2949: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:2755: \$? = $ac_status" >&5 + echo "$as_me:2952: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:2758: \"$ac_try\"") >&5 + { (eval echo "$as_me:2955: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:2761: \$? = $ac_status" >&5 + echo "$as_me:2958: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_prog_cc_stdc=$ac_arg -break + cf_cv_xopen_source=no else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -fi -rm -f conftest.$ac_objext -done -rm -f conftest.$ac_ext conftest.$ac_objext -CC=$ac_save_CC - -fi - -case "x$ac_cv_prog_cc_stdc" in - x|xno) - echo "$as_me:2778: result: none needed" >&5 -echo "${ECHO_T}none needed" >&6 ;; - *) - echo "$as_me:2781: result: $ac_cv_prog_cc_stdc" >&5 -echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6 - CC="$CC $ac_cv_prog_cc_stdc" ;; -esac - -echo "$as_me:2786: checking for an ANSI C-conforming const" >&5 -echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6 -if test "${ac_cv_c_const+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 2792 "configure" +cf_save="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" + cat >conftest.$ac_ext <<_ACEOF +#line 2967 "configure" #include "confdefs.h" +#include +#include +#include + int main () { -/* FIXME: Include the comments suggested by Paul. */ -#ifndef __cplusplus - /* Ultrix mips cc rejects this. */ - typedef int charset[2]; - const charset x; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *ccp; - char **p; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - ccp = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++ccp; - p = (char**) ccp; - ccp = (char const *const *) p; - { /* SCO 3.2v4 cc rejects this. */ - char *t; - char const *s = 0 ? (char *) 0 : (char const *) 0; - - *t++ = 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; }; - struct s *b; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - } -#endif +#ifdef _XOPEN_SOURCE +make an error +#endif ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:2850: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:2986: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:2853: \$? = $ac_status" >&5 + echo "$as_me:2989: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:2856: \"$ac_try\"") >&5 + { (eval echo "$as_me:2992: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:2859: \$? = $ac_status" >&5 + echo "$as_me:2995: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_c_const=yes + cf_cv_xopen_source=no else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_c_const=no +cf_cv_xopen_source=$cf_XOPEN_SOURCE fi rm -f conftest.$ac_objext conftest.$ac_ext -fi -echo "$as_me:2869: result: $ac_cv_c_const" >&5 -echo "${ECHO_T}$ac_cv_c_const" >&6 -if test $ac_cv_c_const = no; then + CPPFLAGS="$cf_save" -cat >>confdefs.h <<\EOF -#define const -EOF +fi +rm -f conftest.$ac_objext conftest.$ac_ext fi +echo "$as_me:3010: result: $cf_cv_xopen_source" >&5 +echo "${ECHO_T}$cf_cv_xopen_source" >&6 -case $cf_cv_system_name in -os2*) - CFLAGS="$CFLAGS -Zmt" - CPPFLAGS="$CPPFLAGS -D__ST_MT_ERRNO__" - CXXFLAGS="$CXXFLAGS -Zmt" - # autoconf's macro sets -Zexe and suffix both, which conflict:w - LDFLAGS="$LDFLAGS -Zmt -Zcrtdll" - ac_cv_exeext=.exe - ;; -esac +if test "$cf_cv_xopen_source" != no ; then -PROG_EXT="$EXEEXT" +CFLAGS=`echo "$CFLAGS" | \ + sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` -test -n "$PROG_EXT" && cat >>confdefs.h <&5 -echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6 -if test "${cf_cv_gnu_source+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` -cat >conftest.$ac_ext <<_ACEOF -#line 2941 "configure" -#include "confdefs.h" -#include -int -main () -{ + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; +esac +done -#ifndef _XOPEN_SOURCE -make an error -#endif - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:2956: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:2959: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:2962: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:2965: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_gnu_source=no -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cf_save="$CPPFLAGS" - CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" - cat >conftest.$ac_ext <<_ACEOF -#line 2974 "configure" -#include "confdefs.h" -#include -int -main () -{ +if test -n "$cf_new_cflags" ; then -#ifdef _XOPEN_SOURCE -make an error -#endif - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:2989: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:2992: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:2995: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:2998: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_gnu_source=no -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cf_cv_gnu_source=yes + CFLAGS="$CFLAGS $cf_new_cflags" fi -rm -f conftest.$ac_objext conftest.$ac_ext - CPPFLAGS="$cf_save" +if test -n "$cf_new_cppflags" ; then + + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" fi -rm -f conftest.$ac_objext conftest.$ac_ext +if test -n "$cf_new_extra_cppflags" ; then + + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" fi -echo "$as_me:3013: result: $cf_cv_gnu_source" >&5 -echo "${ECHO_T}$cf_cv_gnu_source" >&6 -test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" - ;; -mirbsd*) #(vi - # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks and other headers which use u_int / u_short types - cf_XOPEN_SOURCE= +fi cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE @@ -3032,16 +3115,16 @@ sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` -echo "$as_me:3035: checking if we should define _POSIX_C_SOURCE" >&5 +echo "$as_me:3118: checking if we should define _POSIX_C_SOURCE" >&5 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6 if test "${cf_cv_posix_c_source+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else -echo "${as_me:-configure}:3041: testing if the symbol is already defined go no further ..." 1>&5 +echo "${as_me:-configure}:3124: testing if the symbol is already defined go no further ..." 1>&5 cat >conftest.$ac_ext <<_ACEOF -#line 3044 "configure" +#line 3127 "configure" #include "confdefs.h" #include int @@ -3056,16 +3139,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3059: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3142: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3062: \$? = $ac_status" >&5 + echo "$as_me:3145: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3065: \"$ac_try\"") >&5 + { (eval echo "$as_me:3148: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3068: \$? = $ac_status" >&5 + echo "$as_me:3151: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_posix_c_source=no else @@ -3086,7 +3169,7 @@ esac if test "$cf_want_posix_source" = yes ; then cat >conftest.$ac_ext <<_ACEOF -#line 3089 "configure" +#line 3172 "configure" #include "confdefs.h" #include int @@ -3101,16 +3184,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3104: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3187: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3107: \$? = $ac_status" >&5 + echo "$as_me:3190: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3110: \"$ac_try\"") >&5 + { (eval echo "$as_me:3193: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3113: \$? = $ac_status" >&5 + echo "$as_me:3196: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else @@ -3121,15 +3204,15 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "${as_me:-configure}:3124: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 +echo "${as_me:-configure}:3207: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 CFLAGS="$cf_trim_CFLAGS" CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source" -echo "${as_me:-configure}:3129: testing if the second compile does not leave our definition intact error ..." 1>&5 +echo "${as_me:-configure}:3212: testing if the second compile does not leave our definition intact error ..." 1>&5 cat >conftest.$ac_ext <<_ACEOF -#line 3132 "configure" +#line 3215 "configure" #include "confdefs.h" #include int @@ -3144,16 +3227,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3147: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3230: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3150: \$? = $ac_status" >&5 + echo "$as_me:3233: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3153: \"$ac_try\"") >&5 + { (eval echo "$as_me:3236: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3156: \$? = $ac_status" >&5 + echo "$as_me:3239: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else @@ -3169,7 +3252,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:3172: result: $cf_cv_posix_c_source" >&5 +echo "$as_me:3255: result: $cf_cv_posix_c_source" >&5 echo "${ECHO_T}$cf_cv_posix_c_source" >&6 if test "$cf_cv_posix_c_source" != no ; then @@ -3257,39 +3340,180 @@ fi ;; -netbsd*) #(vi - cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw - ;; -openbsd[4-9]*) #(vi - # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw - cf_xopen_source="-D_BSD_SOURCE" - cf_XOPEN_SOURCE=600 - ;; -openbsd*) #(vi - # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw - ;; -osf[45]*) #(vi - cf_xopen_source="-D_OSF_SOURCE" - ;; -nto-qnx*) #(vi - cf_xopen_source="-D_QNX_SOURCE" - ;; -sco*) #(vi - # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer - ;; -solaris2.*) #(vi - cf_xopen_source="-D__EXTENSIONS__" - ;; -*) +esac + +if test -n "$cf_xopen_source" ; then + +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= +cf_new_extra_cppflags= + +for cf_add_cflags in $cf_xopen_source +do +case $cf_fix_cppflags in +no) + case $cf_add_cflags in #(vi + -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi + case $cf_add_cflags in + -D*) + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=yes + + if test $cf_fix_cppflags = yes ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + elif test "${cf_tst_cflags}" = "\"'" ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + fi + ;; + esac + case "$CPPFLAGS" in + *$cf_add_cflags) #(vi + ;; + *) #(vi + case $cf_add_cflags in #(vi + -D*) + cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` + +CPPFLAGS=`echo "$CPPFLAGS" | \ + sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` + + ;; + esac + cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" + ;; + esac + ;; + *) + cf_new_cflags="$cf_new_cflags $cf_add_cflags" + ;; + esac + ;; +yes) + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; +esac +done + +if test -n "$cf_new_cflags" ; then + + CFLAGS="$CFLAGS $cf_new_cflags" +fi + +if test -n "$cf_new_cppflags" ; then + + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" +fi + +if test -n "$cf_new_extra_cppflags" ; then + + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" +fi + +fi + +if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then + echo "$as_me:3428: checking if _XOPEN_SOURCE really is set" >&5 +echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6 + cat >conftest.$ac_ext <<_ACEOF +#line 3431 "configure" +#include "confdefs.h" +#include +int +main () +{ + +#ifndef _XOPEN_SOURCE +make an error +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:3446: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:3449: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:3452: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:3455: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cf_XOPEN_SOURCE_set=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +cf_XOPEN_SOURCE_set=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext + echo "$as_me:3464: result: $cf_XOPEN_SOURCE_set" >&5 +echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6 + if test $cf_XOPEN_SOURCE_set = yes + then + cat >conftest.$ac_ext <<_ACEOF +#line 3469 "configure" +#include "confdefs.h" +#include +int +main () +{ + +#if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE +make an error +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:3484: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:3487: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:3490: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:3493: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cf_XOPEN_SOURCE_set_ok=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +cf_XOPEN_SOURCE_set_ok=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext + if test $cf_XOPEN_SOURCE_set_ok = no + then + { echo "$as_me:3504: WARNING: _XOPEN_SOURCE is lower than requested" >&5 +echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;} + fi + else -echo "$as_me:3285: checking if we should define _XOPEN_SOURCE" >&5 +echo "$as_me:3509: checking if we should define _XOPEN_SOURCE" >&5 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6 if test "${cf_cv_xopen_source+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 3292 "configure" +#line 3516 "configure" #include "confdefs.h" #include @@ -3308,16 +3532,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3311: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3535: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3314: \$? = $ac_status" >&5 + echo "$as_me:3538: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3317: \"$ac_try\"") >&5 + { (eval echo "$as_me:3541: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3320: \$? = $ac_status" >&5 + echo "$as_me:3544: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xopen_source=no else @@ -3326,7 +3550,7 @@ cf_save="$CPPFLAGS" CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" cat >conftest.$ac_ext <<_ACEOF -#line 3329 "configure" +#line 3553 "configure" #include "confdefs.h" #include @@ -3345,16 +3569,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3348: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3572: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3351: \$? = $ac_status" >&5 + echo "$as_me:3575: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3354: \"$ac_try\"") >&5 + { (eval echo "$as_me:3578: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3357: \$? = $ac_status" >&5 + echo "$as_me:3581: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xopen_source=no else @@ -3369,7 +3593,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:3372: result: $cf_cv_xopen_source" >&5 +echo "$as_me:3596: result: $cf_cv_xopen_source" >&5 echo "${ECHO_T}$cf_cv_xopen_source" >&6 if test "$cf_cv_xopen_source" != no ; then @@ -3464,1792 +3688,1720 @@ fi -cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE - -cf_save_CFLAGS="$CFLAGS" -cf_save_CPPFLAGS="$CPPFLAGS" - -cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \ - sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` - -cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \ - sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` + fi +fi -echo "$as_me:3480: checking if we should define _POSIX_C_SOURCE" >&5 -echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6 -if test "${cf_cv_posix_c_source+set}" = set; then +echo "$as_me:3694: checking if SIGWINCH is defined" >&5 +echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6 +if test "${cf_cv_define_sigwinch+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else -echo "${as_me:-configure}:3486: testing if the symbol is already defined go no further ..." 1>&5 - cat >conftest.$ac_ext <<_ACEOF -#line 3489 "configure" +#line 3701 "configure" #include "confdefs.h" + #include +#include + int main () { - -#ifndef _POSIX_C_SOURCE -make an error -#endif +int x = SIGWINCH ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3504: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3716: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3507: \$? = $ac_status" >&5 + echo "$as_me:3719: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3510: \"$ac_try\"") >&5 + { (eval echo "$as_me:3722: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3513: \$? = $ac_status" >&5 + echo "$as_me:3725: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_posix_c_source=no + cf_cv_define_sigwinch=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_want_posix_source=no - case .$cf_POSIX_C_SOURCE in #(vi - .[12]??*) #(vi - cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" - ;; - .2) #(vi - cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" - cf_want_posix_source=yes - ;; - .*) - cf_want_posix_source=yes - ;; - esac - if test "$cf_want_posix_source" = yes ; then - cat >conftest.$ac_ext <<_ACEOF -#line 3534 "configure" +cat >conftest.$ac_ext <<_ACEOF +#line 3732 "configure" #include "confdefs.h" + +#undef _XOPEN_SOURCE +#undef _POSIX_SOURCE +#undef _POSIX_C_SOURCE #include +#include + int main () { - -#ifdef _POSIX_SOURCE -make an error -#endif +int x = SIGWINCH ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3549: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3750: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3552: \$? = $ac_status" >&5 + echo "$as_me:3753: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3555: \"$ac_try\"") >&5 + { (eval echo "$as_me:3756: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3558: \$? = $ac_status" >&5 + echo "$as_me:3759: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - : + cf_cv_define_sigwinch=maybe else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE" +cf_cv_define_sigwinch=no fi rm -f conftest.$ac_objext conftest.$ac_ext - fi -echo "${as_me:-configure}:3569: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 +fi +rm -f conftest.$ac_objext conftest.$ac_ext - CFLAGS="$cf_trim_CFLAGS" - CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source" +fi +echo "$as_me:3773: result: $cf_cv_define_sigwinch" >&5 +echo "${ECHO_T}$cf_cv_define_sigwinch" >&6 -echo "${as_me:-configure}:3574: testing if the second compile does not leave our definition intact error ..." 1>&5 +if test "$cf_cv_define_sigwinch" = maybe ; then +echo "$as_me:3777: checking for actual SIGWINCH definition" >&5 +echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6 +if test "${cf_cv_fixup_sigwinch+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else - cat >conftest.$ac_ext <<_ACEOF -#line 3577 "configure" +cf_cv_fixup_sigwinch=unknown +cf_sigwinch=32 +while test $cf_sigwinch != 1 +do + cat >conftest.$ac_ext <<_ACEOF +#line 3788 "configure" #include "confdefs.h" + +#undef _XOPEN_SOURCE +#undef _POSIX_SOURCE +#undef _POSIX_C_SOURCE #include +#include + int main () { -#ifndef _POSIX_C_SOURCE +#if SIGWINCH != $cf_sigwinch make an error #endif +int x = SIGWINCH ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3592: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3810: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3595: \$? = $ac_status" >&5 + echo "$as_me:3813: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3598: \"$ac_try\"") >&5 + { (eval echo "$as_me:3816: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3601: \$? = $ac_status" >&5 + echo "$as_me:3819: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - : + cf_cv_fixup_sigwinch=$cf_sigwinch + break else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_posix_c_source=no fi rm -f conftest.$ac_objext conftest.$ac_ext - CFLAGS="$cf_save_CFLAGS" - CPPFLAGS="$cf_save_CPPFLAGS" + +cf_sigwinch=`expr $cf_sigwinch - 1` +done fi -rm -f conftest.$ac_objext conftest.$ac_ext +echo "$as_me:3833: result: $cf_cv_fixup_sigwinch" >&5 +echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6 + if test "$cf_cv_fixup_sigwinch" != unknown ; then + CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch" + fi fi -echo "$as_me:3617: result: $cf_cv_posix_c_source" >&5 -echo "${ECHO_T}$cf_cv_posix_c_source" >&6 -if test "$cf_cv_posix_c_source" != no ; then - CFLAGS="$cf_trim_CFLAGS" - CPPFLAGS="$cf_trim_CPPFLAGS" +### checks for header files -cf_fix_cppflags=no -cf_new_cflags= -cf_new_cppflags= -cf_new_extra_cppflags= +for ac_header in \ +ncurses/curses.h \ +ncurses/term.h \ +stdlib.h \ +sys/ptem.h sys/ttydefaults.h \ +term.h \ +termios.h \ +unistd.h \ +wchar.h \ -for cf_add_cflags in $cf_cv_posix_c_source do -case $cf_fix_cppflags in -no) - case $cf_add_cflags in #(vi - -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi - case $cf_add_cflags in - -D*) - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=yes - - if test $cf_fix_cppflags = yes ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - elif test "${cf_tst_cflags}" = "\"'" ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - fi - ;; - esac - case "$CPPFLAGS" in - *$cf_add_cflags) #(vi - ;; - *) #(vi - case $cf_add_cflags in #(vi - -D*) - cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` - -CPPFLAGS=`echo "$CPPFLAGS" | \ - sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` - - ;; - esac - cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" - ;; - esac - ;; - *) - cf_new_cflags="$cf_new_cflags $cf_add_cflags" - ;; - esac - ;; -yes) - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=no - ;; -esac -done - -if test -n "$cf_new_cflags" ; then - - CFLAGS="$CFLAGS $cf_new_cflags" +as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +echo "$as_me:3855: checking for $ac_header" >&5 +echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 3861 "configure" +#include "confdefs.h" +#include <$ac_header> +_ACEOF +if { (eval echo "$as_me:3865: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:3871: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes fi - -if test -n "$cf_new_cppflags" ; then - - CPPFLAGS="$CPPFLAGS $cf_new_cppflags" +if test -z "$ac_cpp_err"; then + eval "$as_ac_Header=yes" +else + echo "$as_me: failed program was:" >&5 + cat conftest.$ac_ext >&5 + eval "$as_ac_Header=no" fi - -if test -n "$cf_new_extra_cppflags" ; then - - EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" +rm -f conftest.err conftest.$ac_ext fi +echo "$as_me:3890: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +if test `eval echo '${'$as_ac_Header'}'` = yes; then + cat >>confdefs.h <&5 -echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6 - cat >conftest.$ac_ext <<_ACEOF -#line 3793 "configure" +echo "$as_me:3900: checking whether time.h and sys/time.h may both be included" >&5 +echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6 +if test "${ac_cv_header_time+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 3906 "configure" #include "confdefs.h" -#include +#include +#include +#include + int main () { - -#ifndef _XOPEN_SOURCE -make an error -#endif +if ((struct tm *) 0) +return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3808: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:3922: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3811: \$? = $ac_status" >&5 + echo "$as_me:3925: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3814: \"$ac_try\"") >&5 + { (eval echo "$as_me:3928: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3817: \$? = $ac_status" >&5 + echo "$as_me:3931: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_XOPEN_SOURCE_set=yes + ac_cv_header_time=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_XOPEN_SOURCE_set=no +ac_cv_header_time=no fi rm -f conftest.$ac_objext conftest.$ac_ext - echo "$as_me:3826: result: $cf_XOPEN_SOURCE_set" >&5 -echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6 - if test $cf_XOPEN_SOURCE_set = yes - then - cat >conftest.$ac_ext <<_ACEOF -#line 3831 "configure" +fi +echo "$as_me:3941: result: $ac_cv_header_time" >&5 +echo "${ECHO_T}$ac_cv_header_time" >&6 +if test $ac_cv_header_time = yes; then + +cat >>confdefs.h <<\EOF +#define TIME_WITH_SYS_TIME 1 +EOF + +fi + + echo "$as_me:3951: checking for nl_langinfo and CODESET" >&5 +echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6 +if test "${am_cv_langinfo_codeset+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 3957 "configure" #include "confdefs.h" -#include +#include int main () { - -#if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE -make an error -#endif +char* cs = nl_langinfo(CODESET); ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:3846: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:3969: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:3849: \$? = $ac_status" >&5 + echo "$as_me:3972: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3852: \"$ac_try\"") >&5 + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:3975: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3855: \$? = $ac_status" >&5 + echo "$as_me:3978: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_XOPEN_SOURCE_set_ok=yes + am_cv_langinfo_codeset=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_XOPEN_SOURCE_set_ok=no +am_cv_langinfo_codeset=no fi -rm -f conftest.$ac_objext conftest.$ac_ext - if test $cf_XOPEN_SOURCE_set_ok = no - then - { echo "$as_me:3866: WARNING: _XOPEN_SOURCE is lower than requested" >&5 -echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;} - fi - else +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -echo "$as_me:3871: checking if we should define _XOPEN_SOURCE" >&5 -echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6 -if test "${cf_cv_xopen_source+set}" = set; then +fi +echo "$as_me:3989: result: $am_cv_langinfo_codeset" >&5 +echo "${ECHO_T}$am_cv_langinfo_codeset" >&6 + if test $am_cv_langinfo_codeset = yes; then + +cat >>confdefs.h <<\EOF +#define HAVE_LANGINFO_CODESET 1 +EOF + + fi + +### checks for typedefs + +echo "$as_me:4001: checking for signal global datatype" >&5 +echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6 +if test "${cf_cv_sig_atomic_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else + for cf_type in \ + "volatile sig_atomic_t" \ + "sig_atomic_t" \ + "int" + do cat >conftest.$ac_ext <<_ACEOF -#line 3878 "configure" +#line 4013 "configure" #include "confdefs.h" -#include -#include #include +#include +#include +extern $cf_type x; +$cf_type x; +static void handler(int sig) +{ + x = 5; +} int main () { - -#ifndef _XOPEN_SOURCE -make an error -#endif +signal(SIGINT, handler); + x = 1 ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3897: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4036: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3900: \$? = $ac_status" >&5 + echo "$as_me:4039: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3903: \"$ac_try\"") >&5 + { (eval echo "$as_me:4042: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3906: \$? = $ac_status" >&5 + echo "$as_me:4045: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_xopen_source=no + cf_cv_sig_atomic_t=$cf_type else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_save="$CPPFLAGS" - CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" - cat >conftest.$ac_ext <<_ACEOF -#line 3915 "configure" -#include "confdefs.h" +cf_cv_sig_atomic_t=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext + test "$cf_cv_sig_atomic_t" != no && break + done + +fi + +echo "$as_me:4059: result: $cf_cv_sig_atomic_t" >&5 +echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6 +test "$cf_cv_sig_atomic_t" != no && +cat >>confdefs.h <&5 +echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6 +if test "${ac_cv_header_stdc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 4072 "configure" +#include "confdefs.h" #include +#include #include -#include +#include + +_ACEOF +if { (eval echo "$as_me:4080: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:4086: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + ac_cv_header_stdc=yes +else + echo "$as_me: failed program was:" >&5 + cat conftest.$ac_ext >&5 + ac_cv_header_stdc=no +fi +rm -f conftest.err conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat >conftest.$ac_ext <<_ACEOF +#line 4108 "configure" +#include "confdefs.h" +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "memchr" >/dev/null 2>&1; then + : +else + ac_cv_header_stdc=no +fi +rm -rf conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat >conftest.$ac_ext <<_ACEOF +#line 4126 "configure" +#include "confdefs.h" +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "free" >/dev/null 2>&1; then + : +else + ac_cv_header_stdc=no +fi +rm -rf conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then + : +else + cat >conftest.$ac_ext <<_ACEOF +#line 4147 "configure" +#include "confdefs.h" +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + $ac_main_return(2); + $ac_main_return (0); +} +_ACEOF +rm -f conftest$ac_exeext +if { (eval echo "$as_me:4173: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:4176: \$? = $ac_status" >&5 + (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:4178: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:4181: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + : +else + echo "$as_me: program exited with status $ac_status" >&5 +echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_header_stdc=no +fi +rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +fi +fi +fi +echo "$as_me:4194: result: $ac_cv_header_stdc" >&5 +echo "${ECHO_T}$ac_cv_header_stdc" >&6 +if test $ac_cv_header_stdc = yes; then -#ifdef _XOPEN_SOURCE -make an error -#endif +cat >>confdefs.h <<\EOF +#define STDC_HEADERS 1 +EOF + +fi + +# On IRIX 5.3, sys/types and inttypes.h are conflicting. + +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do +as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +echo "$as_me:4210: checking for $ac_header" >&5 +echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 4216 "configure" +#include "confdefs.h" +$ac_includes_default +#include <$ac_header> +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:4222: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:4225: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:4228: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:4231: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + eval "$as_ac_Header=yes" +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +eval "$as_ac_Header=no" +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi +echo "$as_me:4241: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +if test `eval echo '${'$as_ac_Header'}'` = yes; then + cat >>confdefs.h <&5 +echo $ECHO_N "checking for time_t... $ECHO_C" >&6 +if test "${ac_cv_type_time_t+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 4257 "configure" +#include "confdefs.h" +$ac_includes_default +int +main () +{ +if ((time_t *) 0) + return 0; +if (sizeof (time_t)) + return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:3934: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4272: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:3937: \$? = $ac_status" >&5 + echo "$as_me:4275: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:3940: \"$ac_try\"") >&5 + { (eval echo "$as_me:4278: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:3943: \$? = $ac_status" >&5 + echo "$as_me:4281: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_xopen_source=no + ac_cv_type_time_t=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_xopen_source=$cf_XOPEN_SOURCE +ac_cv_type_time_t=no fi rm -f conftest.$ac_objext conftest.$ac_ext - CPPFLAGS="$cf_save" - fi -rm -f conftest.$ac_objext conftest.$ac_ext +echo "$as_me:4291: result: $ac_cv_type_time_t" >&5 +echo "${ECHO_T}$ac_cv_type_time_t" >&6 +if test $ac_cv_type_time_t = yes; then + : +else -fi -echo "$as_me:3958: result: $cf_cv_xopen_source" >&5 -echo "${ECHO_T}$cf_cv_xopen_source" >&6 - -if test "$cf_cv_xopen_source" != no ; then - -CFLAGS=`echo "$CFLAGS" | \ - sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` - -CPPFLAGS=`echo "$CPPFLAGS" | \ - sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` - - cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source" - -cf_fix_cppflags=no -cf_new_cflags= -cf_new_cppflags= -cf_new_extra_cppflags= - -for cf_add_cflags in $cf_temp_xopen_source -do -case $cf_fix_cppflags in -no) - case $cf_add_cflags in #(vi - -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi - case $cf_add_cflags in - -D*) - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=yes - - if test $cf_fix_cppflags = yes ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - elif test "${cf_tst_cflags}" = "\"'" ; then - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - continue - fi - ;; - esac - case "$CPPFLAGS" in - *$cf_add_cflags) #(vi - ;; - *) #(vi - case $cf_add_cflags in #(vi - -D*) - cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` - -CPPFLAGS=`echo "$CPPFLAGS" | \ - sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ - -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` - - ;; - esac - cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" - ;; - esac - ;; - *) - cf_new_cflags="$cf_new_cflags $cf_add_cflags" - ;; - esac - ;; -yes) - cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" - - cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` - - test "${cf_add_cflags}" != "${cf_tst_cflags}" \ - && test -z "${cf_tst_cflags}" \ - && cf_fix_cppflags=no - ;; -esac -done - -if test -n "$cf_new_cflags" ; then - - CFLAGS="$CFLAGS $cf_new_cflags" -fi - -if test -n "$cf_new_cppflags" ; then - - CPPFLAGS="$CPPFLAGS $cf_new_cppflags" -fi - -if test -n "$cf_new_extra_cppflags" ; then - - EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" -fi - -fi +cat >>confdefs.h <&5 -echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6 -if test "${cf_cv_define_sigwinch+set}" = set; then +echo "$as_me:4303: checking for cc_t in or " >&5 +echo $ECHO_N "checking for cc_t in or ... $ECHO_C" >&6 +if test "${cf_cv_type_cc_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 4063 "configure" +#line 4310 "configure" #include "confdefs.h" #include -#include +#if defined(HAVE_TERMIOS_H) +#include +#else +#include +#include +#endif int main () { -int x = SIGWINCH +cc_t x ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4078: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4330: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4081: \$? = $ac_status" >&5 + echo "$as_me:4333: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4084: \"$ac_try\"") >&5 + { (eval echo "$as_me:4336: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4087: \$? = $ac_status" >&5 + echo "$as_me:4339: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_define_sigwinch=yes + cf_cv_type_cc_t=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cat >conftest.$ac_ext <<_ACEOF -#line 4094 "configure" -#include "confdefs.h" +cf_cv_type_cc_t=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext -#undef _XOPEN_SOURCE -#undef _POSIX_SOURCE -#undef _POSIX_C_SOURCE -#include -#include +fi + +echo "$as_me:4351: result: $cf_cv_type_cc_t" >&5 +echo "${ECHO_T}$cf_cv_type_cc_t" >&6 +test $cf_cv_type_cc_t = no && +cat >>confdefs.h <<\EOF +#define cc_t unsigned char +EOF +echo "$as_me:4358: checking for mode_t" >&5 +echo $ECHO_N "checking for mode_t... $ECHO_C" >&6 +if test "${ac_cv_type_mode_t+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 4364 "configure" +#include "confdefs.h" +$ac_includes_default int main () { -int x = SIGWINCH +if ((mode_t *) 0) + return 0; +if (sizeof (mode_t)) + return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4112: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4379: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4115: \$? = $ac_status" >&5 + echo "$as_me:4382: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4118: \"$ac_try\"") >&5 + { (eval echo "$as_me:4385: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4121: \$? = $ac_status" >&5 + echo "$as_me:4388: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_define_sigwinch=maybe + ac_cv_type_mode_t=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_define_sigwinch=no +ac_cv_type_mode_t=no fi rm -f conftest.$ac_objext conftest.$ac_ext - fi -rm -f conftest.$ac_objext conftest.$ac_ext +echo "$as_me:4398: result: $ac_cv_type_mode_t" >&5 +echo "${ECHO_T}$ac_cv_type_mode_t" >&6 +if test $ac_cv_type_mode_t = yes; then + : +else + +cat >>confdefs.h <&5 -echo "${ECHO_T}$cf_cv_define_sigwinch" >&6 -if test "$cf_cv_define_sigwinch" = maybe ; then -echo "$as_me:4139: checking for actual SIGWINCH definition" >&5 -echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6 -if test "${cf_cv_fixup_sigwinch+set}" = set; then +echo "$as_me:4410: checking for pid_t" >&5 +echo $ECHO_N "checking for pid_t... $ECHO_C" >&6 +if test "${ac_cv_type_pid_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - -cf_cv_fixup_sigwinch=unknown -cf_sigwinch=32 -while test $cf_sigwinch != 1 -do - cat >conftest.$ac_ext <<_ACEOF -#line 4150 "configure" + cat >conftest.$ac_ext <<_ACEOF +#line 4416 "configure" #include "confdefs.h" - -#undef _XOPEN_SOURCE -#undef _POSIX_SOURCE -#undef _POSIX_C_SOURCE -#include -#include - +$ac_includes_default int main () { - -#if SIGWINCH != $cf_sigwinch -make an error -#endif -int x = SIGWINCH +if ((pid_t *) 0) + return 0; +if (sizeof (pid_t)) + return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4172: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4431: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4175: \$? = $ac_status" >&5 + echo "$as_me:4434: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4178: \"$ac_try\"") >&5 + { (eval echo "$as_me:4437: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4181: \$? = $ac_status" >&5 + echo "$as_me:4440: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_fixup_sigwinch=$cf_sigwinch - break + ac_cv_type_pid_t=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 +ac_cv_type_pid_t=no fi rm -f conftest.$ac_objext conftest.$ac_ext - -cf_sigwinch=`expr $cf_sigwinch - 1` -done - -fi -echo "$as_me:4195: result: $cf_cv_fixup_sigwinch" >&5 -echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6 - - if test "$cf_cv_fixup_sigwinch" != unknown ; then - CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch" - fi fi +echo "$as_me:4450: result: $ac_cv_type_pid_t" >&5 +echo "${ECHO_T}$ac_cv_type_pid_t" >&6 +if test $ac_cv_type_pid_t = yes; then + : +else -### checks for header files +cat >>confdefs.h <&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 -if eval "test \"\${$as_ac_Header+set}\" = set"; then +echo "$as_me:4462: checking for uid_t in sys/types.h" >&5 +echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6 +if test "${ac_cv_type_uid_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 4223 "configure" +#line 4468 "configure" #include "confdefs.h" -#include <$ac_header> +#include + _ACEOF -if { (eval echo "$as_me:4227: \"$ac_cpp conftest.$ac_ext\"") >&5 - (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 - ac_status=$? - egrep -v '^ *\+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:4233: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null; then - if test -s conftest.err; then - ac_cpp_err=$ac_c_preproc_warn_flag - else - ac_cpp_err= - fi -else - ac_cpp_err=yes -fi -if test -z "$ac_cpp_err"; then - eval "$as_ac_Header=yes" +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "uid_t" >/dev/null 2>&1; then + ac_cv_type_uid_t=yes else - echo "$as_me: failed program was:" >&5 - cat conftest.$ac_ext >&5 - eval "$as_ac_Header=no" + ac_cv_type_uid_t=no fi -rm -f conftest.err conftest.$ac_ext +rm -rf conftest* + fi -echo "$as_me:4252: result: `eval echo '${'$as_ac_Header'}'`" >&5 -echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <&5 +echo "${ECHO_T}$ac_cv_type_uid_t" >&6 +if test $ac_cv_type_uid_t = no; then + +cat >>confdefs.h <<\EOF +#define uid_t int +EOF + +cat >>confdefs.h <<\EOF +#define gid_t int EOF fi -done -echo "$as_me:4262: checking whether time.h and sys/time.h may both be included" >&5 -echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6 -if test "${ac_cv_header_time+set}" = set; then +echo "$as_me:4496: checking for off_t" >&5 +echo $ECHO_N "checking for off_t... $ECHO_C" >&6 +if test "${ac_cv_type_off_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 4268 "configure" +#line 4502 "configure" #include "confdefs.h" -#include -#include -#include - +$ac_includes_default int main () { -if ((struct tm *) 0) -return 0; +if ((off_t *) 0) + return 0; +if (sizeof (off_t)) + return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4284: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4517: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4287: \$? = $ac_status" >&5 + echo "$as_me:4520: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4290: \"$ac_try\"") >&5 + { (eval echo "$as_me:4523: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4293: \$? = $ac_status" >&5 + echo "$as_me:4526: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_header_time=yes + ac_cv_type_off_t=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_header_time=no +ac_cv_type_off_t=no fi rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:4303: result: $ac_cv_header_time" >&5 -echo "${ECHO_T}$ac_cv_header_time" >&6 -if test $ac_cv_header_time = yes; then +echo "$as_me:4536: result: $ac_cv_type_off_t" >&5 +echo "${ECHO_T}$ac_cv_type_off_t" >&6 +if test $ac_cv_type_off_t = yes; then + : +else -cat >>confdefs.h <<\EOF -#define TIME_WITH_SYS_TIME 1 +cat >>confdefs.h <&5 -echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6 -if test "${am_cv_langinfo_codeset+set}" = set; then +### checks for library functions + +for ac_func in \ + gethostname \ + getlogin \ + putenv \ + unsetenv \ + sched_yield \ + setpgid \ + strftime \ + tcgetattr \ + waitpid \ + wcswidth \ + wcwidth +do +as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +echo "$as_me:4564: checking for $ac_func" >&5 +echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 4319 "configure" +#line 4570 "configure" #include "confdefs.h" -#include +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func (); below. */ +#include +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func (); +char (*f) (); + int main () { -char* cs = nl_langinfo(CODESET); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; +#endif + ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:4331: \"$ac_link\"") >&5 +if { (eval echo "$as_me:4601: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:4334: \$? = $ac_status" >&5 + echo "$as_me:4604: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:4337: \"$ac_try\"") >&5 + { (eval echo "$as_me:4607: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4340: \$? = $ac_status" >&5 + echo "$as_me:4610: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - am_cv_langinfo_codeset=yes + eval "$as_ac_var=yes" else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -am_cv_langinfo_codeset=no +eval "$as_ac_var=no" fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext - fi -echo "$as_me:4351: result: $am_cv_langinfo_codeset" >&5 -echo "${ECHO_T}$am_cv_langinfo_codeset" >&6 - if test $am_cv_langinfo_codeset = yes; then - -cat >>confdefs.h <<\EOF -#define HAVE_LANGINFO_CODESET 1 +echo "$as_me:4620: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +if test `eval echo '${'$as_ac_var'}'` = yes; then + cat >>confdefs.h <&5 +echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 4639 "configure" +#include "confdefs.h" +#include <$ac_header> +_ACEOF +if { (eval echo "$as_me:4643: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:4649: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= fi +else + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + eval "$as_ac_Header=yes" +else + echo "$as_me: failed program was:" >&5 + cat conftest.$ac_ext >&5 + eval "$as_ac_Header=no" +fi +rm -f conftest.err conftest.$ac_ext +fi +echo "$as_me:4668: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +if test `eval echo '${'$as_ac_Header'}'` = yes; then + cat >>confdefs.h <&5 -echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6 -if test "${cf_cv_sig_atomic_t+set}" = set; then +echo "$as_me:4678: checking for lastlog path" >&5 +echo $ECHO_N "checking for lastlog path... $ECHO_C" >&6 +if test "${cf_cv_path_lastlog+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - for cf_type in \ - "volatile sig_atomic_t" \ - "sig_atomic_t" \ - "int" - do - cat >conftest.$ac_ext <<_ACEOF -#line 4375 "configure" +cat >conftest.$ac_ext <<_ACEOF +#line 4685 "configure" #include "confdefs.h" #include -#include -#include - -extern $cf_type x; -$cf_type x; -static void handler(int sig) -{ - x = 5; -} +#ifdef HAVE_LASTLOG_H +#include +#else +#ifdef HAVE_PATHS_H +#include +#endif +#endif int main () { -signal(SIGINT, handler); - x = 1 +char *path = _PATH_LASTLOG ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4398: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4705: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4401: \$? = $ac_status" >&5 + echo "$as_me:4708: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4404: \"$ac_try\"") >&5 + { (eval echo "$as_me:4711: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4407: \$? = $ac_status" >&5 + echo "$as_me:4714: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_sig_atomic_t=$cf_type + cf_cv_path_lastlog="_PATH_LASTLOG" else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_sig_atomic_t=no +if test -f /usr/adm/lastlog ; then + cf_cv_path_lastlog=/usr/adm/lastlog + else + cf_cv_path_lastlog=no + fi fi rm -f conftest.$ac_objext conftest.$ac_ext - test "$cf_cv_sig_atomic_t" != no && break - done fi - -echo "$as_me:4421: result: $cf_cv_sig_atomic_t" >&5 -echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6 -test "$cf_cv_sig_atomic_t" != no && cat >>confdefs.h <&5 +echo "${ECHO_T}$cf_cv_path_lastlog" >&6 +test $cf_cv_path_lastlog != no && +cat >>confdefs.h <<\EOF +#define USE_LASTLOG 1 EOF -echo "$as_me:4427: checking for size_t in or " >&5 -echo $ECHO_N "checking for size_t in or ... $ECHO_C" >&6 -if test "${cf_cv_type_size_t+set}" = set; then +echo "$as_me:4736: checking for utmp implementation" >&5 +echo $ECHO_N "checking for utmp implementation... $ECHO_C" >&6 +if test "${cf_cv_have_utmp+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else + cf_cv_have_utmp=no +for cf_header in utmpx utmp ; do +cf_utmp_includes=" +#include +#include <${cf_header}.h> +#define getutent getutxent +#ifdef USE_LASTLOG +#include /* may conflict with utmpx.h on Linux */ +#endif +" cat >conftest.$ac_ext <<_ACEOF -#line 4434 "configure" +#line 4753 "configure" #include "confdefs.h" +$cf_utmp_includes +int +main () +{ +struct $cf_header x; + char *name = x.ut_name; /* utmp.h and compatible definitions */ -#include -#ifdef STDC_HEADERS -#include -#include -#endif -#include + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:4767: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:4770: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:4773: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:4776: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cf_cv_have_utmp=$cf_header + break +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 + + cat >conftest.$ac_ext <<_ACEOF +#line 4785 "configure" +#include "confdefs.h" +$cf_utmp_includes int main () { -size_t x +struct $cf_header x; + char *name = x.ut_user; /* utmpx.h must declare this */ + ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4452: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4799: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4455: \$? = $ac_status" >&5 + echo "$as_me:4802: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4458: \"$ac_try\"") >&5 + { (eval echo "$as_me:4805: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4461: \$? = $ac_status" >&5 + echo "$as_me:4808: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_type_size_t=yes + cf_cv_have_utmp=$cf_header + break + else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_type_size_t=no fi rm -f conftest.$ac_objext conftest.$ac_ext +fi +rm -f conftest.$ac_objext conftest.$ac_ext +done fi +echo "$as_me:4823: result: $cf_cv_have_utmp" >&5 +echo "${ECHO_T}$cf_cv_have_utmp" >&6 -echo "$as_me:4473: result: $cf_cv_type_size_t" >&5 -echo "${ECHO_T}$cf_cv_type_size_t" >&6 -test $cf_cv_type_size_t = no && cat >>confdefs.h <<\EOF -#define size_t unsigned +if test $cf_cv_have_utmp != no ; then + +cat >>confdefs.h <<\EOF +#define HAVE_UTMP 1 EOF -echo "$as_me:4479: checking for ANSI C header files" >&5 -echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6 -if test "${ac_cv_header_stdc+set}" = set; then + test $cf_cv_have_utmp = utmpx && +cat >>confdefs.h <<\EOF +#define UTMPX_FOR_UTMP 1 +EOF + +if test $cf_cv_have_utmp != no ; then +echo "$as_me:4838: checking if ${cf_cv_have_utmp}.ut_host is declared" >&5 +echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_host is declared... $ECHO_C" >&6 +if test "${cf_cv_have_utmp_ut_host+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF -#line 4485 "configure" + + cat >conftest.$ac_ext <<_ACEOF +#line 4845 "configure" #include "confdefs.h" -#include -#include -#include -#include +#include +#include <${cf_cv_have_utmp}.h> +int +main () +{ +struct $cf_cv_have_utmp x; char *y = &x.ut_host[0] + ; + return 0; +} _ACEOF -if { (eval echo "$as_me:4493: \"$ac_cpp conftest.$ac_ext\"") >&5 - (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:4859: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? - egrep -v '^ *\+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:4499: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null; then - if test -s conftest.err; then - ac_cpp_err=$ac_c_preproc_warn_flag - else - ac_cpp_err= - fi -else - ac_cpp_err=yes -fi -if test -z "$ac_cpp_err"; then - ac_cv_header_stdc=yes + echo "$as_me:4862: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:4865: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:4868: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cf_cv_have_utmp_ut_host=yes else echo "$as_me: failed program was:" >&5 - cat conftest.$ac_ext >&5 - ac_cv_header_stdc=no -fi -rm -f conftest.err conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -#line 4521 "configure" -#include "confdefs.h" -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "memchr" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no +cat conftest.$ac_ext >&5 +cf_cv_have_utmp_ut_host=no fi -rm -rf conftest* +rm -f conftest.$ac_objext conftest.$ac_ext fi -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -#line 4539 "configure" -#include "confdefs.h" -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "free" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no -fi -rm -rf conftest* +echo "$as_me:4880: result: $cf_cv_have_utmp_ut_host" >&5 +echo "${ECHO_T}$cf_cv_have_utmp_ut_host" >&6 +test $cf_cv_have_utmp_ut_host != no && +cat >>confdefs.h <<\EOF +#define HAVE_UTMP_UT_HOST 1 +EOF fi -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then - : +if test $cf_cv_have_utmp != no ; then +echo "$as_me:4890: checking if ${cf_cv_have_utmp}.ut_syslen is declared" >&5 +echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_syslen is declared... $ECHO_C" >&6 +if test "${cf_cv_have_utmp_ut_syslen+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF -#line 4560 "configure" + + cat >conftest.$ac_ext <<_ACEOF +#line 4897 "configure" #include "confdefs.h" -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +#include +#include <${cf_cv_have_utmp}.h> int main () { - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - $ac_main_return(2); - $ac_main_return (0); +struct $cf_cv_have_utmp x; int y = x.ut_syslen + ; + return 0; } _ACEOF -rm -f conftest$ac_exeext -if { (eval echo "$as_me:4586: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:4911: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4589: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (eval echo "$as_me:4591: \"$ac_try\"") >&5 + echo "$as_me:4914: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:4917: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4594: \$? = $ac_status" >&5 + echo "$as_me:4920: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - : + cf_cv_have_utmp_ut_syslen=yes else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 + echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_header_stdc=no -fi -rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi +cf_cv_have_utmp_ut_syslen=no fi +rm -f conftest.$ac_objext conftest.$ac_ext + fi -echo "$as_me:4607: result: $ac_cv_header_stdc" >&5 -echo "${ECHO_T}$ac_cv_header_stdc" >&6 -if test $ac_cv_header_stdc = yes; then +echo "$as_me:4932: result: $cf_cv_have_utmp_ut_syslen" >&5 +echo "${ECHO_T}$cf_cv_have_utmp_ut_syslen" >&6 +test $cf_cv_have_utmp_ut_syslen != no && cat >>confdefs.h <<\EOF -#define STDC_HEADERS 1 +#define HAVE_UTMP_UT_SYSLEN 1 EOF fi -# On IRIX 5.3, sys/types and inttypes.h are conflicting. - -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do -as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:4623: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 -if eval "test \"\${$as_ac_Header+set}\" = set"; then +if test $cf_cv_have_utmp != no ; then +echo "$as_me:4942: checking if ${cf_cv_have_utmp}.ut_name is declared" >&5 +echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_name is declared... $ECHO_C" >&6 +if test "${cf_cv_have_utmp_ut_name+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF -#line 4629 "configure" + + cf_cv_have_utmp_ut_name=no +cf_utmp_includes=" +#include +#include <${cf_cv_have_utmp}.h> +#define getutent getutxent +#ifdef USE_LASTLOG +#include /* may conflict with utmpx.h on Linux */ +#endif +" +for cf_header in ut_name ut_user ; do + cat >conftest.$ac_ext <<_ACEOF +#line 4959 "configure" #include "confdefs.h" -$ac_includes_default -#include <$ac_header> +$cf_utmp_includes +int +main () +{ +struct $cf_cv_have_utmp x; + char *name = x.$cf_header; + + ; + return 0; +} _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4635: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:4973: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4638: \$? = $ac_status" >&5 + echo "$as_me:4976: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4641: \"$ac_try\"") >&5 + { (eval echo "$as_me:4979: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4644: \$? = $ac_status" >&5 + echo "$as_me:4982: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - eval "$as_ac_Header=yes" + cf_cv_have_utmp_ut_name=$cf_header + break else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -eval "$as_ac_Header=no" fi rm -f conftest.$ac_objext conftest.$ac_ext +done + fi -echo "$as_me:4654: result: `eval echo '${'$as_ac_Header'}'`" >&5 -echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <&5 +echo "${ECHO_T}$cf_cv_have_utmp_ut_name" >&6 + +case $cf_cv_have_utmp_ut_name in #(vi +no) #(vi + { { echo "$as_me:4999: error: Cannot find declaration for ut.ut_name" >&5 +echo "$as_me: error: Cannot find declaration for ut.ut_name" >&2;} + { (exit 1); exit 1; }; } + ;; +ut_user) + +cat >>confdefs.h <<\EOF +#define ut_name ut_user EOF + ;; +esac fi -done -echo "$as_me:4664: checking for time_t" >&5 -echo $ECHO_N "checking for time_t... $ECHO_C" >&6 -if test "${ac_cv_type_time_t+set}" = set; then +if test $cf_cv_have_utmp != no ; then +echo "$as_me:5014: checking for exit-status in $cf_cv_have_utmp" >&5 +echo $ECHO_N "checking for exit-status in $cf_cv_have_utmp... $ECHO_C" >&6 +if test "${cf_cv_have_utmp_ut_xstatus+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF -#line 4670 "configure" + +for cf_result in \ + ut_exit.__e_exit \ + ut_exit.e_exit \ + ut_exit.ut_e_exit \ + ut_exit.ut_exit +do +cat >conftest.$ac_ext <<_ACEOF +#line 5027 "configure" #include "confdefs.h" -$ac_includes_default + +#include +#include <${cf_cv_have_utmp}.h> int main () { -if ((time_t *) 0) - return 0; -if (sizeof (time_t)) - return 0; +struct $cf_cv_have_utmp x; long y = x.$cf_result = 0 ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4685: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:5041: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4688: \$? = $ac_status" >&5 + echo "$as_me:5044: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4691: \"$ac_try\"") >&5 + { (eval echo "$as_me:5047: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4694: \$? = $ac_status" >&5 + echo "$as_me:5050: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_type_time_t=yes + cf_cv_have_utmp_ut_xstatus=$cf_result + break else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_type_time_t=no +cf_cv_have_utmp_ut_xstatus=no fi rm -f conftest.$ac_objext conftest.$ac_ext +done + fi -echo "$as_me:4704: result: $ac_cv_type_time_t" >&5 -echo "${ECHO_T}$ac_cv_type_time_t" >&6 -if test $ac_cv_type_time_t = yes; then - : -else +echo "$as_me:5063: result: $cf_cv_have_utmp_ut_xstatus" >&5 +echo "${ECHO_T}$cf_cv_have_utmp_ut_xstatus" >&6 +if test $cf_cv_have_utmp_ut_xstatus != no ; then + +cat >>confdefs.h <<\EOF +#define HAVE_UTMP_UT_XSTATUS 1 +EOF cat >>confdefs.h < or " >&5 -echo $ECHO_N "checking for cc_t in or ... $ECHO_C" >&6 -if test "${cf_cv_type_cc_t+set}" = set; then +if test $cf_cv_have_utmp != no ; then +echo "$as_me:5079: checking if ${cf_cv_have_utmp}.ut_xtime is declared" >&5 +echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_xtime is declared... $ECHO_C" >&6 +if test "${cf_cv_have_utmp_ut_xtime+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 4723 "configure" +#line 5086 "configure" #include "confdefs.h" #include -#if defined(HAVE_TERMIOS_H) -#include -#else -#include -#include -#endif - +#include <${cf_cv_have_utmp}.h> int main () { -cc_t x +struct $cf_cv_have_utmp x; long y = x.ut_xtime = 0 ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4743: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:5100: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4746: \$? = $ac_status" >&5 + echo "$as_me:5103: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4749: \"$ac_try\"") >&5 + { (eval echo "$as_me:5106: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4752: \$? = $ac_status" >&5 + echo "$as_me:5109: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_type_cc_t=yes + cf_cv_have_utmp_ut_xtime=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_type_cc_t=no -fi -rm -f conftest.$ac_objext conftest.$ac_ext - -fi - -echo "$as_me:4764: result: $cf_cv_type_cc_t" >&5 -echo "${ECHO_T}$cf_cv_type_cc_t" >&6 -test $cf_cv_type_cc_t = no && cat >>confdefs.h <<\EOF -#define cc_t unsigned char -EOF - -echo "$as_me:4770: checking for mode_t" >&5 -echo $ECHO_N "checking for mode_t... $ECHO_C" >&6 -if test "${ac_cv_type_mode_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 4776 "configure" +cat >conftest.$ac_ext <<_ACEOF +#line 5116 "configure" #include "confdefs.h" -$ac_includes_default + +#include +#include <${cf_cv_have_utmp}.h> int main () { -if ((mode_t *) 0) - return 0; -if (sizeof (mode_t)) - return 0; +struct $cf_cv_have_utmp x; long y = x.ut_tv.tv_sec ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4791: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:5130: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4794: \$? = $ac_status" >&5 + echo "$as_me:5133: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4797: \"$ac_try\"") >&5 + { (eval echo "$as_me:5136: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4800: \$? = $ac_status" >&5 + echo "$as_me:5139: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_type_mode_t=yes + cf_cv_have_utmp_ut_xtime=define else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_type_mode_t=no +cf_cv_have_utmp_ut_xtime=no fi rm -f conftest.$ac_objext conftest.$ac_ext + fi -echo "$as_me:4810: result: $ac_cv_type_mode_t" >&5 -echo "${ECHO_T}$ac_cv_type_mode_t" >&6 -if test $ac_cv_type_mode_t = yes; then - : -else +rm -f conftest.$ac_objext conftest.$ac_ext -cat >>confdefs.h <&5 +echo "${ECHO_T}$cf_cv_have_utmp_ut_xtime" >&6 +if test $cf_cv_have_utmp_ut_xtime != no ; then + +cat >>confdefs.h <<\EOF +#define HAVE_UTMP_UT_XTIME 1 +EOF + + if test $cf_cv_have_utmp_ut_xtime = define ; then + +cat >>confdefs.h <<\EOF +#define ut_xtime ut_tv.tv_sec EOF + fi +fi fi -echo "$as_me:4822: checking for pid_t" >&5 -echo $ECHO_N "checking for pid_t... $ECHO_C" >&6 -if test "${ac_cv_type_pid_t+set}" = set; then +if test $cf_cv_have_utmp != no ; then +echo "$as_me:5172: checking if ${cf_cv_have_utmp}.ut_session is declared" >&5 +echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_session is declared... $ECHO_C" >&6 +if test "${cf_cv_have_utmp_ut_session+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF -#line 4828 "configure" + + cat >conftest.$ac_ext <<_ACEOF +#line 5179 "configure" #include "confdefs.h" -$ac_includes_default + +#include +#include <${cf_cv_have_utmp}.h> int main () { -if ((pid_t *) 0) - return 0; -if (sizeof (pid_t)) - return 0; +struct $cf_cv_have_utmp x; long y = x.ut_session ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:4843: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:5193: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:4846: \$? = $ac_status" >&5 + echo "$as_me:5196: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4849: \"$ac_try\"") >&5 + { (eval echo "$as_me:5199: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4852: \$? = $ac_status" >&5 + echo "$as_me:5202: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_type_pid_t=yes + cf_cv_have_utmp_ut_session=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_type_pid_t=no +cf_cv_have_utmp_ut_session=no fi rm -f conftest.$ac_objext conftest.$ac_ext -fi -echo "$as_me:4862: result: $ac_cv_type_pid_t" >&5 -echo "${ECHO_T}$ac_cv_type_pid_t" >&6 -if test $ac_cv_type_pid_t = yes; then - : -else - -cat >>confdefs.h <&5 -echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6 -if test "${ac_cv_type_uid_t+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 4880 "configure" -#include "confdefs.h" -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - egrep "uid_t" >/dev/null 2>&1; then - ac_cv_type_uid_t=yes -else - ac_cv_type_uid_t=no -fi -rm -rf conftest* fi -echo "$as_me:4894: result: $ac_cv_type_uid_t" >&5 -echo "${ECHO_T}$ac_cv_type_uid_t" >&6 -if test $ac_cv_type_uid_t = no; then - -cat >>confdefs.h <<\EOF -#define uid_t int -EOF +echo "$as_me:5213: result: $cf_cv_have_utmp_ut_session" >&5 +echo "${ECHO_T}$cf_cv_have_utmp_ut_session" >&6 +if test $cf_cv_have_utmp_ut_session != no ; then cat >>confdefs.h <<\EOF -#define gid_t int +#define HAVE_UTMP_UT_SESSION 1 EOF fi +fi -echo "$as_me:4908: checking for off_t" >&5 -echo $ECHO_N "checking for off_t... $ECHO_C" >&6 -if test "${ac_cv_type_off_t+set}" = set; then +echo "$as_me:5224: checking if $cf_cv_have_utmp is SYSV flavor" >&5 +echo $ECHO_N "checking if $cf_cv_have_utmp is SYSV flavor... $ECHO_C" >&6 +if test "${cf_cv_sysv_utmp+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF -#line 4914 "configure" + +test "$cf_cv_have_utmp" = "utmp" && cf_prefix="ut" || cf_prefix="utx" +cat >conftest.$ac_ext <<_ACEOF +#line 5232 "configure" #include "confdefs.h" -$ac_includes_default + +#include +#include <${cf_cv_have_utmp}.h> int main () { -if ((off_t *) 0) - return 0; -if (sizeof (off_t)) - return 0; + +struct $cf_cv_have_utmp x; + set${cf_prefix}ent (); + get${cf_prefix}id(&x); + put${cf_prefix}line(&x); + end${cf_prefix}ent(); ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:4929: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:5251: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:4932: \$? = $ac_status" >&5 + echo "$as_me:5254: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:4935: \"$ac_try\"") >&5 + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:5257: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:4938: \$? = $ac_status" >&5 + echo "$as_me:5260: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_type_off_t=yes + cf_cv_sysv_utmp=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_type_off_t=no -fi -rm -f conftest.$ac_objext conftest.$ac_ext +cf_cv_sysv_utmp=no fi -echo "$as_me:4948: result: $ac_cv_type_off_t" >&5 -echo "${ECHO_T}$ac_cv_type_off_t" >&6 -if test $ac_cv_type_off_t = yes; then - : -else +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -cat >>confdefs.h <&5 +echo "${ECHO_T}$cf_cv_sysv_utmp" >&6 +test $cf_cv_sysv_utmp = yes && +cat >>confdefs.h <<\EOF +#define USE_SYSV_UTMP 1 EOF fi -### checks for library functions - -for ac_func in \ - bcopy \ - gethostname \ - getlogin \ - memmove \ - putenv \ - unsetenv \ - sched_yield \ - setpgid \ - strerror \ - strftime \ - tcgetattr \ - waitpid \ - wcswidth \ - wcwidth +for ac_header in lastlog.h do -as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -echo "$as_me:4979: checking for $ac_func" >&5 -echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 -if eval "test \"\${$as_ac_var+set}\" = set"; then +as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +echo "$as_me:5283: checking for $ac_header" >&5 +echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 4985 "configure" +#line 5289 "configure" #include "confdefs.h" -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. */ -#include -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char $ac_func (); -char (*f) (); - -int -main () -{ -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_$ac_func) || defined (__stub___$ac_func) -choke me -#else -f = $ac_func; -#endif - - ; - return 0; -} +#include <$ac_header> _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:5016: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:5019: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:5022: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 +if { (eval echo "$as_me:5293: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? - echo "$as_me:5025: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - eval "$as_ac_var=yes" + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:5299: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -eval "$as_ac_var=no" + cat conftest.$ac_ext >&5 + eval "$as_ac_Header=no" fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +rm -f conftest.err conftest.$ac_ext fi -echo "$as_me:5035: result: `eval echo '${'$as_ac_var'}'`" >&5 -echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 -if test `eval echo '${'$as_ac_var'}'` = yes; then +echo "$as_me:5318: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <&5 -echo $ECHO_N "checking for memmove... $ECHO_C" >&6 -if test "${ac_cv_func_memmove+set}" = set; then +echo "$as_me:5328: checking for struct lastlog" >&5 +echo $ECHO_N "checking for struct lastlog... $ECHO_C" >&6 +if test "${cf_cv_struct_lastlog+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else + +if test "$cross_compiling" = yes; then + +cf_cv_struct_lastlog=unknown +else cat >conftest.$ac_ext <<_ACEOF -#line 5051 "configure" +#line 5339 "configure" #include "confdefs.h" -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char memmove (); below. */ -#include -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char memmove (); -char (*f) (); -int -main () -{ -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_memmove) || defined (__stub___memmove) -choke me -#else -f = memmove; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:5082: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:5085: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:5088: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5091: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_func_memmove=yes -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -ac_cv_func_memmove=no -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -fi -echo "$as_me:5101: result: $ac_cv_func_memmove" >&5 -echo "${ECHO_T}$ac_cv_func_memmove" >&6 -if test $ac_cv_func_memmove = yes; then - : -else - -echo "$as_me:5107: checking for bcopy" >&5 -echo $ECHO_N "checking for bcopy... $ECHO_C" >&6 -if test "${ac_cv_func_bcopy+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 5113 "configure" -#include "confdefs.h" -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char bcopy (); below. */ -#include -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char bcopy (); -char (*f) (); +#include +#include +#include -int -main () +int main() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_bcopy) || defined (__stub___bcopy) -choke me -#else -f = bcopy; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:5144: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:5147: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:5150: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5153: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_func_bcopy=yes -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -ac_cv_func_bcopy=no -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -fi -echo "$as_me:5163: result: $ac_cv_func_bcopy" >&5 -echo "${ECHO_T}$ac_cv_func_bcopy" >&6 -if test $ac_cv_func_bcopy = yes; then - - echo "$as_me:5167: checking if bcopy does overlapping moves" >&5 -echo $ECHO_N "checking if bcopy does overlapping moves... $ECHO_C" >&6 -if test "${cf_cv_good_bcopy+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - - if test "$cross_compiling" = yes; then - cf_cv_good_bcopy=unknown -else - cat >conftest.$ac_ext <<_ACEOF -#line 5177 "configure" -#include "confdefs.h" - -int main() { - static char data[] = "abcdefghijklmnopqrstuwwxyz"; - char temp[40]; - bcopy(data, temp, sizeof(data)); - bcopy(temp+10, temp, 15); - bcopy(temp+5, temp+15, 10); - ${cf_cv_main_return:-return} (strcmp(temp, "klmnopqrstuwwxypqrstuwwxyz")); + struct lastlog data; + return (sizeof(data.ll_time) != sizeof(time_t)); } - _ACEOF rm -f conftest$ac_exeext -if { (eval echo "$as_me:5191: \"$ac_link\"") >&5 +if { (eval echo "$as_me:5353: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:5194: \$? = $ac_status" >&5 + echo "$as_me:5356: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (eval echo "$as_me:5196: \"$ac_try\"") >&5 + { (eval echo "$as_me:5358: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:5199: \$? = $ac_status" >&5 + echo "$as_me:5361: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_good_bcopy=yes + +cf_cv_struct_lastlog=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_good_bcopy=no + +cf_cv_struct_lastlog=no fi rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi - -fi -echo "$as_me:5212: result: $cf_cv_good_bcopy" >&5 -echo "${ECHO_T}$cf_cv_good_bcopy" >&6 - -else - cf_cv_good_bcopy=no fi +echo "$as_me:5375: result: $cf_cv_struct_lastlog" >&5 +echo "${ECHO_T}$cf_cv_struct_lastlog" >&6 - if test "$cf_cv_good_bcopy" = yes ; then - cat >>confdefs.h <<\EOF -#define USE_OK_BCOPY 1 -EOF - - else - cat >>confdefs.h <<\EOF -#define USE_MY_MEMMOVE 1 +test $cf_cv_struct_lastlog != no && +cat >>confdefs.h <<\EOF +#define USE_STRUCT_LASTLOG 1 EOF - fi - -fi +for ac_header in \ +sys/param.h \ -for ac_header in lastlog.h paths.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:5236: checking for $ac_header" >&5 +echo "$as_me:5388: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 5242 "configure" +#line 5394 "configure" #include "confdefs.h" #include <$ac_header> _ACEOF -if { (eval echo "$as_me:5246: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:5398: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:5252: \$? = $ac_status" >&5 + echo "$as_me:5404: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -5268,7 +5420,7 @@ fi rm -f conftest.err conftest.$ac_ext fi -echo "$as_me:5271: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "$as_me:5423: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <&5 -echo $ECHO_N "checking for lastlog path... $ECHO_C" >&6 -if test "${cf_cv_path_lastlog+set}" = set; then +echo "$as_me:5433: checking if POSIX saved-ids are supported" >&5 +echo $ECHO_N "checking if POSIX saved-ids are supported... $ECHO_C" >&6 +if test "${cf_cv_posix_saved_ids+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 5288 "configure" +#line 5440 "configure" #include "confdefs.h" -#include -#ifdef HAVE_LASTLOG_H -#include -#else -#ifdef HAVE_PATHS_H -#include -#endif +#include +#ifdef HAVE_SYS_PARAM_H +#include /* this may define "BSD" */ #endif + int main () { -char *path = _PATH_LASTLOG - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5308: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:5311: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5314: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5317: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_path_lastlog="_PATH_LASTLOG" -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -if test -f /usr/adm/lastlog ; then - cf_cv_path_lastlog=/usr/adm/lastlog - else - cf_cv_path_lastlog=no - fi -fi -rm -f conftest.$ac_objext conftest.$ac_ext - -fi -echo "$as_me:5332: result: $cf_cv_path_lastlog" >&5 -echo "${ECHO_T}$cf_cv_path_lastlog" >&6 -test $cf_cv_path_lastlog != no && cat >>confdefs.h <<\EOF -#define USE_LASTLOG 1 -EOF - -echo "$as_me:5338: checking for utmp implementation" >&5 -echo $ECHO_N "checking for utmp implementation... $ECHO_C" >&6 -if test "${cf_cv_have_utmp+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cf_cv_have_utmp=no -for cf_header in utmpx utmp ; do -cf_utmp_includes=" -#include -#include <${cf_header}.h> -#define getutent getutxent -#ifdef USE_LASTLOG -#include /* may conflict with utmpx.h on Linux */ +#if defined(_POSIX_SAVED_IDS) && (_POSIX_SAVED_IDS > 0) + void *p = (void *) seteuid; + int x = seteuid(geteuid()); +#elif defined(BSD) && (BSD >= 199103) +/* The BSD's may implement the runtime check - and it fails. + * However, saved-ids work almost like POSIX (close enough for most uses). + */ +#else +make an error #endif -" - cat >conftest.$ac_ext <<_ACEOF -#line 5355 "configure" -#include "confdefs.h" -$cf_utmp_includes -int -main () -{ -struct $cf_header x; - char *name = x.ut_name; /* utmp.h and compatible definitions */ ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5369: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:5468: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:5372: \$? = $ac_status" >&5 + echo "$as_me:5471: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5375: \"$ac_try\"") >&5 + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:5474: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:5378: \$? = $ac_status" >&5 + echo "$as_me:5477: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_have_utmp=$cf_header - break + cf_cv_posix_saved_ids=yes + else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -#line 5387 "configure" +if test "$cross_compiling" = yes; then + cf_cv_posix_saved_ids=unknown +else + cat >conftest.$ac_ext <<_ACEOF +#line 5489 "configure" #include "confdefs.h" -$cf_utmp_includes -int -main () -{ -struct $cf_header x; - char *name = x.ut_user; /* utmpx.h must declare this */ - ; - return 0; +#ifdef HAVE_STDLIB_H +#include +#endif +#include +int main() +{ + void *p = (void *) seteuid; + long code = sysconf(_SC_SAVED_IDS); + ${cf_cv_main_return:-return} ((code > 0) ? 0 : 1); } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5401: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest$ac_exeext +if { (eval echo "$as_me:5504: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:5404: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5407: \"$ac_try\"") >&5 + echo "$as_me:5507: \$? = $ac_status" >&5 + (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:5509: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:5410: \$? = $ac_status" >&5 + echo "$as_me:5512: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_have_utmp=$cf_header - break - + cf_cv_posix_saved_ids=yes else - echo "$as_me: failed program was:" >&5 + echo "$as_me: program exited with status $ac_status" >&5 +echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 +cf_cv_posix_saved_ids=no fi -rm -f conftest.$ac_objext conftest.$ac_ext +rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi -rm -f conftest.$ac_objext conftest.$ac_ext -done fi -echo "$as_me:5425: result: $cf_cv_have_utmp" >&5 -echo "${ECHO_T}$cf_cv_have_utmp" >&6 +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -if test $cf_cv_have_utmp != no ; then - cat >>confdefs.h <<\EOF -#define HAVE_UTMP 1 -EOF +fi +echo "$as_me:5528: result: $cf_cv_posix_saved_ids" >&5 +echo "${ECHO_T}$cf_cv_posix_saved_ids" >&6 - test $cf_cv_have_utmp = utmpx && cat >>confdefs.h <<\EOF -#define UTMPX_FOR_UTMP 1 +test "$cf_cv_posix_saved_ids" = yes && +cat >>confdefs.h <<\EOF +#define HAVE_POSIX_SAVED_IDS 1 EOF -if test $cf_cv_have_utmp != no ; then -echo "$as_me:5438: checking if ${cf_cv_have_utmp}.ut_host is declared" >&5 -echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_host is declared... $ECHO_C" >&6 -if test "${cf_cv_have_utmp_ut_host+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - - cat >conftest.$ac_ext <<_ACEOF -#line 5445 "configure" -#include "confdefs.h" - -#include -#include <${cf_cv_have_utmp}.h> -int -main () -{ -struct $cf_cv_have_utmp x; char *y = &x.ut_host[0] - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5459: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:5462: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5465: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5468: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_have_utmp_ut_host=yes -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cf_cv_have_utmp_ut_host=no +# compute a reasonable value for $TERM to give tgetent(), since we may be +# running in 'screen', which sets $TERMCAP to a specific entry that is not +# necessarily in /etc/termcap - unsetenv is not portable, so we cannot simply +# discard $TERMCAP. +cf_TERMVAR=vt100 +if test -n "$TERMCAP" +then + cf_TERMCAP=`echo "$TERMCAP" | tr '\n' ' ' | sed -e 's/^..|//' -e 's/|.*//'` + case "$cf_TERMCAP" in #(vi + screen*.*) #(vi + ;; + *) + cf_TERMVAR="$cf_TERMCAP" + ;; + esac fi -rm -f conftest.$ac_objext conftest.$ac_ext +test -z "$cf_TERMVAR" && cf_TERMVAR=vt100 -fi +echo "$as_me:5554: checking if we want full tgetent function" >&5 +echo $ECHO_N "checking if we want full tgetent function... $ECHO_C" >&6 -echo "$as_me:5480: result: $cf_cv_have_utmp_ut_host" >&5 -echo "${ECHO_T}$cf_cv_have_utmp_ut_host" >&6 -test $cf_cv_have_utmp_ut_host != no && cat >>confdefs.h <<\EOF -#define HAVE_UTMP_UT_HOST 1 -EOF +# Check whether --enable-full-tgetent or --disable-full-tgetent was given. +if test "${enable_full_tgetent+set}" = set; then + enableval="$enable_full_tgetent" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + cf_full_tgetent=no + else + cf_full_tgetent=yes + fi +else + enableval=yes + cf_full_tgetent=yes + +fi; +echo "$as_me:5571: result: $cf_full_tgetent" >&5 +echo "${ECHO_T}$cf_full_tgetent" >&6 +if test "$cf_full_tgetent" = yes ; then + cf_test_message="full tgetent" +else + cf_test_message="tgetent" fi -if test $cf_cv_have_utmp != no ; then -echo "$as_me:5489: checking if ${cf_cv_have_utmp}.ut_syslen is declared" >&5 -echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_syslen is declared... $ECHO_C" >&6 -if test "${cf_cv_have_utmp_ut_syslen+set}" = set; then +echo "$as_me:5580: checking for $cf_test_message function" >&5 +echo $ECHO_N "checking for $cf_test_message function... $ECHO_C" >&6 +if test "${cf_cv_lib_tgetent+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - cat >conftest.$ac_ext <<_ACEOF -#line 5496 "configure" +cf_save_LIBS="$LIBS" +cf_cv_lib_tgetent=no +if test "$cf_full_tgetent" = yes ; then + cf_TERMLIB="otermcap termcap termlib ncurses curses" + cf_TERMTST="buffer[0] == 0" +else + cf_TERMLIB="termlib ncurses curses" + cf_TERMTST="0" +fi +for cf_termlib in '' $cf_TERMLIB ; do + LIBS="$cf_save_LIBS" + test -n "$cf_termlib" && LIBS="-l$cf_termlib $LIBS" + if test "$cross_compiling" = yes; then + echo "cross-compiling, cannot verify if a termcap/tgetent is present in $cf_termlib" 1>&5 +else + cat >conftest.$ac_ext <<_ACEOF +#line 5602 "configure" #include "confdefs.h" -#include -#include <${cf_cv_have_utmp}.h> -int -main () +/* terminfo implementations ignore the buffer argument, making it useless for + * the xterm application, which uses this information to make a new TERMCAP + * environment variable. + */ +int main() { -struct $cf_cv_have_utmp x; int y = x.ut_syslen - ; - return 0; -} + char buffer[1024]; + buffer[0] = 0; + tgetent(buffer, "$cf_TERMVAR"); + ${cf_cv_main_return:-return} ($cf_TERMTST); } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5510: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest$ac_exeext +if { (eval echo "$as_me:5617: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:5513: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5516: \"$ac_try\"") >&5 + echo "$as_me:5620: \$? = $ac_status" >&5 + (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:5622: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:5519: \$? = $ac_status" >&5 + echo "$as_me:5625: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_have_utmp_ut_syslen=yes + echo "yes, there is a termcap/tgetent in $cf_termlib" 1>&5 + if test -n "$cf_termlib" ; then + cf_cv_lib_tgetent="-l$cf_termlib" + else + cf_cv_lib_tgetent=yes + fi + break else - echo "$as_me: failed program was:" >&5 + echo "$as_me: program exited with status $ac_status" >&5 +echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_have_utmp_ut_syslen=no +echo "no, there is no termcap/tgetent in $cf_termlib" 1>&5 fi -rm -f conftest.$ac_objext conftest.$ac_ext - +rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi - -echo "$as_me:5531: result: $cf_cv_have_utmp_ut_syslen" >&5 -echo "${ECHO_T}$cf_cv_have_utmp_ut_syslen" >&6 -test $cf_cv_have_utmp_ut_syslen != no && cat >>confdefs.h <<\EOF -#define HAVE_UTMP_UT_SYSLEN 1 -EOF +done +LIBS="$cf_save_LIBS" fi +echo "$as_me:5646: result: $cf_cv_lib_tgetent" >&5 +echo "${ECHO_T}$cf_cv_lib_tgetent" >&6 -if test $cf_cv_have_utmp != no ; then -echo "$as_me:5540: checking if ${cf_cv_have_utmp}.ut_name is declared" >&5 -echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_name is declared... $ECHO_C" >&6 -if test "${cf_cv_have_utmp_ut_name+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else +# If we found a working tgetent(), set LIBS and check for termcap.h. +# (LIBS cannot be set inside AC_CACHE_CHECK; the commands there should +# not have side effects other than setting the cache variable, because +# they are not executed when a cached value exists.) +if test "x$cf_cv_lib_tgetent" != xno ; then + test "x$cf_cv_lib_tgetent" != xyes && LIBS="$cf_cv_lib_tgetent $LIBS" - cf_cv_have_utmp_ut_name=no -cf_utmp_includes=" -#include -#include <${cf_cv_have_utmp}.h> -#define getutent getutxent -#ifdef USE_LASTLOG -#include /* may conflict with utmpx.h on Linux */ -#endif -" -for cf_header in ut_name ut_user ; do - cat >conftest.$ac_ext <<_ACEOF -#line 5557 "configure" +cat >>confdefs.h <<\EOF +#define USE_TERMCAP 1 +EOF + + if test "$cf_full_tgetent" = no ; then + cat >conftest.$ac_ext <<_ACEOF +#line 5662 "configure" #include "confdefs.h" -$cf_utmp_includes + +#include int main () { -struct $cf_cv_have_utmp x; - char *name = x.$cf_header; +#ifdef NCURSES_VERSION +make an error +#endif ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:5571: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:5678: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:5574: \$? = $ac_status" >&5 + echo "$as_me:5681: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5577: \"$ac_try\"") >&5 + { (eval echo "$as_me:5684: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:5580: \$? = $ac_status" >&5 + echo "$as_me:5687: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_have_utmp_ut_name=$cf_header - break + cat >>confdefs.h <<\EOF +#define HAVE_TERMCAP_H 1 +EOF + else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -f conftest.$ac_objext conftest.$ac_ext -done + else +for ac_header in termcap.h +do +as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +echo "$as_me:5703: checking for $ac_header" >&5 +echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 5709 "configure" +#include "confdefs.h" +#include <$ac_header> +_ACEOF +if { (eval echo "$as_me:5713: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:5719: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes fi -echo "$as_me:5592: result: $cf_cv_have_utmp_ut_name" >&5 -echo "${ECHO_T}$cf_cv_have_utmp_ut_name" >&6 - -case $cf_cv_have_utmp_ut_name in #(vi -no) #(vi - { { echo "$as_me:5597: error: Cannot find declaration for ut.ut_name" >&5 -echo "$as_me: error: Cannot find declaration for ut.ut_name" >&2;} - { (exit 1); exit 1; }; } - ;; -ut_user) - cat >>confdefs.h <<\EOF -#define ut_name ut_user +if test -z "$ac_cpp_err"; then + eval "$as_ac_Header=yes" +else + echo "$as_me: failed program was:" >&5 + cat conftest.$ac_ext >&5 + eval "$as_ac_Header=no" +fi +rm -f conftest.err conftest.$ac_ext +fi +echo "$as_me:5738: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +if test `eval echo '${'$as_ac_Header'}'` = yes; then + cat >>confdefs.h <&5 -echo $ECHO_N "checking for exit-status in $cf_cv_have_utmp... $ECHO_C" >&6 -if test "${cf_cv_have_utmp_ut_xstatus+set}" = set; then + fi +else + # If we didn't find a tgetent() that supports the buffer + # argument, look again to see whether we can find even + # a crippled one. A crippled tgetent() is still useful to + # validate values for the TERM environment variable given to + # child processes. + echo "$as_me:5755: checking for partial tgetent function" >&5 +echo $ECHO_N "checking for partial tgetent function... $ECHO_C" >&6 +if test "${cf_cv_lib_part_tgetent+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else -for cf_result in \ - ut_exit.__e_exit \ - ut_exit.e_exit \ - ut_exit.ut_e_exit \ - ut_exit.ut_exit -do -cat >conftest.$ac_ext <<_ACEOF -#line 5624 "configure" + cf_cv_lib_part_tgetent=no + for cf_termlib in $cf_TERMLIB ; do + LIBS="$cf_save_LIBS -l$cf_termlib" + cat >conftest.$ac_ext <<_ACEOF +#line 5765 "configure" #include "confdefs.h" -#include -#include <${cf_cv_have_utmp}.h> int main () { -struct $cf_cv_have_utmp x; long y = x.$cf_result = 0 +tgetent(0, "$cf_TERMVAR") ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5638: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:5777: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:5641: \$? = $ac_status" >&5 + echo "$as_me:5780: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5644: \"$ac_try\"") >&5 + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:5783: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:5647: \$? = $ac_status" >&5 + echo "$as_me:5786: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_have_utmp_ut_xstatus=$cf_result - break -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cf_cv_have_utmp_ut_xstatus=no -fi -rm -f conftest.$ac_objext conftest.$ac_ext -done - -fi -echo "$as_me:5660: result: $cf_cv_have_utmp_ut_xstatus" >&5 -echo "${ECHO_T}$cf_cv_have_utmp_ut_xstatus" >&6 -if test $cf_cv_have_utmp_ut_xstatus != no ; then - cat >>confdefs.h <<\EOF -#define HAVE_UTMP_UT_XSTATUS 1 -EOF - - cat >>confdefs.h <&5 -echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_xtime is declared... $ECHO_C" >&6 -if test "${cf_cv_have_utmp_ut_xtime+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - - cat >conftest.$ac_ext <<_ACEOF -#line 5682 "configure" -#include "confdefs.h" - -#include -#include <${cf_cv_have_utmp}.h> -int -main () -{ -struct $cf_cv_have_utmp x; long y = x.ut_xtime = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5696: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:5699: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5702: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5705: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_have_utmp_ut_xtime=yes -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cat >conftest.$ac_ext <<_ACEOF -#line 5712 "configure" -#include "confdefs.h" - -#include -#include <${cf_cv_have_utmp}.h> -int -main () -{ -struct $cf_cv_have_utmp x; long y = x.ut_tv.tv_sec - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5726: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:5729: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5732: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5735: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_have_utmp_ut_xtime=define -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cf_cv_have_utmp_ut_xtime=no -fi -rm -f conftest.$ac_objext conftest.$ac_ext - -fi -rm -f conftest.$ac_objext conftest.$ac_ext - -fi -echo "$as_me:5749: result: $cf_cv_have_utmp_ut_xtime" >&5 -echo "${ECHO_T}$cf_cv_have_utmp_ut_xtime" >&6 -if test $cf_cv_have_utmp_ut_xtime != no ; then - cat >>confdefs.h <<\EOF -#define HAVE_UTMP_UT_XTIME 1 -EOF - - if test $cf_cv_have_utmp_ut_xtime = define ; then - cat >>confdefs.h <<\EOF -#define ut_xtime ut_tv.tv_sec -EOF - - fi -fi -fi - -if test $cf_cv_have_utmp != no ; then -echo "$as_me:5766: checking if ${cf_cv_have_utmp}.ut_session is declared" >&5 -echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_session is declared... $ECHO_C" >&6 -if test "${cf_cv_have_utmp_ut_session+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - - cat >conftest.$ac_ext <<_ACEOF -#line 5773 "configure" -#include "confdefs.h" - -#include -#include <${cf_cv_have_utmp}.h> -int -main () -{ -struct $cf_cv_have_utmp x; long y = x.ut_session - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:5787: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:5790: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:5793: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5796: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_have_utmp_ut_session=yes -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cf_cv_have_utmp_ut_session=no -fi -rm -f conftest.$ac_objext conftest.$ac_ext - -fi -echo "$as_me:5807: result: $cf_cv_have_utmp_ut_session" >&5 -echo "${ECHO_T}$cf_cv_have_utmp_ut_session" >&6 -if test $cf_cv_have_utmp_ut_session != no ; then - cat >>confdefs.h <<\EOF -#define HAVE_UTMP_UT_SESSION 1 -EOF - -fi -fi - -echo "$as_me:5817: checking if $cf_cv_have_utmp is SYSV flavor" >&5 -echo $ECHO_N "checking if $cf_cv_have_utmp is SYSV flavor... $ECHO_C" >&6 -if test "${cf_cv_sysv_utmp+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - -test "$cf_cv_have_utmp" = "utmp" && cf_prefix="ut" || cf_prefix="utx" -cat >conftest.$ac_ext <<_ACEOF -#line 5825 "configure" -#include "confdefs.h" - -#include -#include <${cf_cv_have_utmp}.h> -int -main () -{ - -struct $cf_cv_have_utmp x; - set${cf_prefix}ent (); - get${cf_prefix}id(&x); - put${cf_prefix}line(&x); - end${cf_prefix}ent(); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:5844: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:5847: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:5850: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5853: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_sysv_utmp=yes + echo "there is a terminfo/tgetent in $cf_termlib" 1>&5 + cf_cv_lib_part_tgetent="-l$cf_termlib" + break else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_sysv_utmp=no fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext + done + LIBS="$cf_save_LIBS" fi -echo "$as_me:5864: result: $cf_cv_sysv_utmp" >&5 -echo "${ECHO_T}$cf_cv_sysv_utmp" >&6 -test $cf_cv_sysv_utmp = yes && cat >>confdefs.h <<\EOF -#define USE_SYSV_UTMP 1 -EOF +echo "$as_me:5800: result: $cf_cv_lib_part_tgetent" >&5 +echo "${ECHO_T}$cf_cv_lib_part_tgetent" >&6 -fi + if test "$cf_cv_lib_part_tgetent" != no ; then + LIBS="$cf_cv_lib_part_tgetent $LIBS" -for ac_header in lastlog.h +for ac_header in termcap.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:5875: checking for $ac_header" >&5 +echo "$as_me:5809: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 5881 "configure" +#line 5815 "configure" #include "confdefs.h" #include <$ac_header> _ACEOF -if { (eval echo "$as_me:5885: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:5819: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:5891: \$? = $ac_status" >&5 + echo "$as_me:5825: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -5907,7 +5841,7 @@ fi rm -f conftest.err conftest.$ac_ext fi -echo "$as_me:5910: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "$as_me:5844: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <&5 -echo $ECHO_N "checking for struct lastlog... $ECHO_C" >&6 -if test "${cf_cv_struct_lastlog+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - -if test "$cross_compiling" = yes; then + # If this is linking against ncurses, we'll trigger the + # ifdef in resize.c that turns the termcap stuff back off. -cf_cv_struct_lastlog=unknown -else - cat >conftest.$ac_ext <<_ACEOF -#line 5931 "configure" -#include "confdefs.h" +cat >>confdefs.h <<\EOF +#define USE_TERMINFO 1 +EOF -#include -#include -#include + fi +fi -int main() -{ - struct lastlog data; - return (sizeof(data.ll_time) != sizeof(time_t)); -} -_ACEOF -rm -f conftest$ac_exeext -if { (eval echo "$as_me:5945: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:5948: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (eval echo "$as_me:5950: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:5953: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then +echo "$as_me:5864: checking for X applications class" >&5 +echo $ECHO_N "checking for X applications class... $ECHO_C" >&6 -cf_cv_struct_lastlog=yes +# Check whether --with-app-class or --without-app-class was given. +if test "${with_app_class+set}" = set; then + withval="$with_app_class" + APP_CLASS=$withval else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 + APP_CLASS=XTerm +fi; -cf_cv_struct_lastlog=no -fi -rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -fi -echo "$as_me:5967: result: $cf_cv_struct_lastlog" >&5 -echo "${ECHO_T}$cf_cv_struct_lastlog" >&6 +case x$APP_CLASS in #(vi +*[/@,%]*) #(vi + { echo "$as_me:5877: WARNING: X applications class cannot contain punctuation" >&5 +echo "$as_me: WARNING: X applications class cannot contain punctuation" >&2;} + APP_CLASS=XTerm + ;; +x[A-Z]*) #(vi + ;; +*) + { echo "$as_me:5884: WARNING: X applications class must start with capital, ignoring $APP_CLASS" >&5 +echo "$as_me: WARNING: X applications class must start with capital, ignoring $APP_CLASS" >&2;} + APP_CLASS=XTerm + ;; +esac -test $cf_cv_struct_lastlog != no && cat >>confdefs.h <<\EOF -#define USE_STRUCT_LASTLOG 1 -EOF +echo "$as_me:5890: result: $APP_CLASS" >&5 +echo "${ECHO_T}$APP_CLASS" >&6 -for ac_header in \ -sys/param.h \ +echo "$as_me:5893: checking for directory to install resource files" >&5 +echo $ECHO_N "checking for directory to install resource files... $ECHO_C" >&6 -do -as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:5979: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 -if eval "test \"\${$as_ac_Header+set}\" = set"; then - echo $ECHO_N "(cached) $ECHO_C" >&6 +# Check whether --with-app-defaults or --without-app-defaults was given. +if test "${with_app_defaults+set}" = set; then + withval="$with_app_defaults" + APPSDIR=$withval else - cat >conftest.$ac_ext <<_ACEOF -#line 5985 "configure" -#include "confdefs.h" -#include <$ac_header> -_ACEOF -if { (eval echo "$as_me:5989: \"$ac_cpp conftest.$ac_ext\"") >&5 - (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 - ac_status=$? - egrep -v '^ *\+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:5995: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null; then - if test -s conftest.err; then - ac_cpp_err=$ac_c_preproc_warn_flag - else - ac_cpp_err= - fi + APPSDIR='${exec_prefix}/lib/X11/app-defaults' +fi; + +if test "x$APPSDIR" = xauto +then + APPSDIR='${exec_prefix}/lib/X11/app-defaults' + for cf_path in \ + /usr/share/X11/app-defaults \ + /usr/X11/share/X11/app-defaults \ + /usr/X11/lib/X11/app-defaults \ + /usr/lib/X11/app-defaults \ + /etc/X11/app-defaults \ + /usr/pkg/lib/X11/app-defaults \ + /usr/X11R7/lib/X11/app-defaults \ + /usr/X11R6/lib/X11/app-defaults \ + /usr/X11R5/lib/X11/app-defaults \ + /usr/X11R4/lib/X11/app-defaults \ + /usr/local/lib/X11/app-defaults \ + /usr/local/share/X11/app-defaults \ + /usr/lib64/X11/app-defaults + do + if test -d "$cf_path" ; then + APPSDIR="$cf_path" + break + fi + done else - ac_cpp_err=yes -fi -if test -z "$ac_cpp_err"; then - eval "$as_ac_Header=yes" + cf_path=$APPSDIR + +if test "x$prefix" != xNONE; then + cf_path_syntax="$prefix" else - echo "$as_me: failed program was:" >&5 - cat conftest.$ac_ext >&5 - eval "$as_ac_Header=no" + cf_path_syntax="$ac_default_prefix" fi -rm -f conftest.err conftest.$ac_ext + +case ".$cf_path" in #(vi +.\$\(*\)*|.\'*\'*) #(vi + ;; +..|./*|.\\*) #(vi + ;; +.[a-zA-Z]:[\\/]*) #(vi OS/2 EMX + ;; +.\${*prefix}*|.\${*dir}*) #(vi + eval cf_path="$cf_path" + case ".$cf_path" in #(vi + .NONE/*) + cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%` + ;; + esac + ;; #(vi +.no|.NONE/*) + cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%` + ;; +*) + { { echo "$as_me:5955: error: expected a pathname, not \"$cf_path\"" >&5 +echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;} + { (exit 1); exit 1; }; } + ;; +esac + fi -echo "$as_me:6014: result: `eval echo '${'$as_ac_Header'}'`" >&5 -echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <&5 +echo "${ECHO_T}$APPSDIR" >&6 + +no_appsdir= +if test "$APPSDIR" = no +then + no_appsdir="#" +else + EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(APPSDIR)" fi -done -echo "$as_me:6024: checking if POSIX saved-ids are supported" >&5 -echo $ECHO_N "checking if POSIX saved-ids are supported... $ECHO_C" >&6 -if test "${cf_cv_posix_saved_ids+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 +echo "$as_me:5974: checking for the icon name" >&5 +echo $ECHO_N "checking for the icon name... $ECHO_C" >&6 + +# Check whether --with-icon-name or --without-icon-name was given. +if test "${with_icon_name+set}" = set; then + withval="$with_icon_name" + ICON_NAME="$withval" else + ICON_NAME=xterm-color +fi; +case "x$ICON_NAME" in +xyes|xno|x) + ICON_NAME=xterm-color + ;; +esac -cat >conftest.$ac_ext <<_ACEOF -#line 6031 "configure" -#include "confdefs.h" +echo "$as_me:5990: result: $ICON_NAME" >&5 +echo "${ECHO_T}$ICON_NAME" >&6 -#include -#ifdef HAVE_SYS_PARAM_H -#include /* this may define "BSD" */ -#endif +echo "$as_me:5993: checking for icon symlink to use" >&5 +echo $ECHO_N "checking for icon symlink to use... $ECHO_C" >&6 -int -main () -{ +# Check whether --with-icon-symlink or --without-icon-symlink was given. +if test "${with_icon_symlink+set}" = set; then + withval="$with_icon_symlink" + ICON_SYMLINK="$withval" +else + ICON_SYMLINK=NONE +fi; +case "x$ICON_SYMLINK" in +xyes) + ICON_SYMLINK=xterm + ;; +xno|x) + ICON_SYMLINK=NONE + ;; +esac -#if defined(_POSIX_SAVED_IDS) && (_POSIX_SAVED_IDS > 0) - void *p = (void *) seteuid; - int x = seteuid(geteuid()); -#elif defined(BSD) && (BSD >= 199103) -/* The BSD's may implement the runtime check - and it fails. - * However, saved-ids work almost like POSIX (close enough for most uses). - */ -#else -make an error -#endif +echo "$as_me:6012: result: $ICON_SYMLINK" >&5 +echo "${ECHO_T}$ICON_SYMLINK" >&6 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:6059: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:6062: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:6065: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:6068: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_posix_saved_ids=yes +echo "$as_me:6015: checking for directory to install pixmaps" >&5 +echo $ECHO_N "checking for directory to install pixmaps... $ECHO_C" >&6 +# Check whether --with-pixmapdir or --without-pixmapdir was given. +if test "${with_pixmapdir+set}" = set; then + withval="$with_pixmapdir" + PIXMAPDIR=$withval else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 + test -z "$PIXMAPDIR" && PIXMAPDIR='${datadir}/pixmaps' +fi; -if test "$cross_compiling" = yes; then - cf_cv_posix_saved_ids=unknown +if test "x$PIXMAPDIR" = xauto +then + PIXMAPDIR='${datadir}/pixmaps' + for cf_path in \ + /usr/share/pixmaps \ + /usr/X11R6/share/pixmaps + do + if test -d "$cf_path" ; then + PIXMAPDIR="$cf_path" + break + fi + done else - cat >conftest.$ac_ext <<_ACEOF -#line 6080 "configure" -#include "confdefs.h" + cf_path=$PIXMAPDIR -#ifdef HAVE_STDLIB_H -#include -#endif -#include -int main() -{ - void *p = (void *) seteuid; - long code = sysconf(_SC_SAVED_IDS); - ${cf_cv_main_return:-return} ((code > 0) ? 0 : 1); -} -_ACEOF -rm -f conftest$ac_exeext -if { (eval echo "$as_me:6095: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:6098: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (eval echo "$as_me:6100: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:6103: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_posix_saved_ids=yes +if test "x$prefix" != xNONE; then + cf_path_syntax="$prefix" else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -cf_cv_posix_saved_ids=no -fi -rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + cf_path_syntax="$ac_default_prefix" fi -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +case ".$cf_path" in #(vi +.\$\(*\)*|.\'*\'*) #(vi + ;; +..|./*|.\\*) #(vi + ;; +.[a-zA-Z]:[\\/]*) #(vi OS/2 EMX + ;; +.\${*prefix}*|.\${*dir}*) #(vi + eval cf_path="$cf_path" + case ".$cf_path" in #(vi + .NONE/*) + cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%` + ;; + esac + ;; #(vi +.no|.NONE/*) + cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%` + ;; +*) + { { echo "$as_me:6066: error: expected a pathname, not \"$cf_path\"" >&5 +echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;} + { (exit 1); exit 1; }; } + ;; +esac fi -echo "$as_me:6119: result: $cf_cv_posix_saved_ids" >&5 -echo "${ECHO_T}$cf_cv_posix_saved_ids" >&6 +echo "$as_me:6073: result: $PIXMAPDIR" >&5 +echo "${ECHO_T}$PIXMAPDIR" >&6 -test "$cf_cv_posix_saved_ids" = yes && cat >>confdefs.h <<\EOF -#define HAVE_POSIX_SAVED_IDS 1 -EOF - -# compute a reasonable value for $TERM to give tgetent(), since we may be -# running in 'screen', which sets $TERMCAP to a specific entry that is not -# necessarily in /etc/termcap - unsetenv is not portable, so we cannot simply -# discard $TERMCAP. -cf_TERMVAR=vt100 -if test -n "$TERMCAP" +no_pixmapdir= +if test "$PIXMAPDIR" = no then - cf_TERMCAP=`echo "$TERMCAP" | tr '\n' ' ' | sed -e 's/^..|//' -e 's/|.*//'` - case "$cf_TERMCAP" in #(vi - screen*.*) #(vi - ;; - *) - cf_TERMVAR="$cf_TERMCAP" - ;; - esac + no_pixmapdir="#" +else + EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(PIXMAPDIR)" fi -test -z "$cf_TERMVAR" && cf_TERMVAR=vt100 -echo "$as_me:6144: checking if we want full tgetent function" >&5 -echo $ECHO_N "checking if we want full tgetent function... $ECHO_C" >&6 +echo "$as_me:6084: checking for directory to install icons" >&5 +echo $ECHO_N "checking for directory to install icons... $ECHO_C" >&6 -# Check whether --enable-full-tgetent or --disable-full-tgetent was given. -if test "${enable_full_tgetent+set}" = set; then - enableval="$enable_full_tgetent" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - cf_full_tgetent=no - else - cf_full_tgetent=yes - fi +# Check whether --with-icondir or --without-icondir was given. +if test "${with_icondir+set}" = set; then + withval="$with_icondir" + ICONDIR=$withval else - enableval=yes - cf_full_tgetent=yes - + test -z "$ICONDIR" && ICONDIR=no fi; -echo "$as_me:6161: result: $cf_full_tgetent" >&5 -echo "${ECHO_T}$cf_full_tgetent" >&6 - -if test "$cf_full_tgetent" = yes ; then - cf_test_message="full tgetent" -else - cf_test_message="tgetent" -fi -echo "$as_me:6170: checking for $cf_test_message function" >&5 -echo $ECHO_N "checking for $cf_test_message function... $ECHO_C" >&6 -if test "${cf_cv_lib_tgetent+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 +if test "x$ICONDIR" = xauto +then + ICONDIR='${datadir}/icons' + for cf_path in \ + /usr/share/icons \ + /usr/X11R6/share/icons + do + if test -d "$cf_path" ; then + ICONDIR="$cf_path" + break + fi + done else + cf_path=$ICONDIR -cf_save_LIBS="$LIBS" -cf_cv_lib_tgetent=no -if test "$cf_full_tgetent" = yes ; then - cf_TERMLIB="otermcap termcap termlib ncurses curses" - cf_TERMTST="buffer[0] == 0" +if test "x$prefix" != xNONE; then + cf_path_syntax="$prefix" else - cf_TERMLIB="termlib ncurses curses" - cf_TERMTST="0" + cf_path_syntax="$ac_default_prefix" fi -for cf_termlib in '' $cf_TERMLIB ; do - LIBS="$cf_save_LIBS" - test -n "$cf_termlib" && LIBS="-l$cf_termlib $LIBS" - if test "$cross_compiling" = yes; then - echo "cross-compiling, cannot verify if a termcap/tgetent is present in $cf_termlib" 1>&5 -else - cat >conftest.$ac_ext <<_ACEOF -#line 6192 "configure" -#include "confdefs.h" -/* terminfo implementations ignore the buffer argument, making it useless for - * the xterm application, which uses this information to make a new TERMCAP - * environment variable. - */ -int main() -{ - char buffer[1024]; - buffer[0] = 0; - tgetent(buffer, "$cf_TERMVAR"); - ${cf_cv_main_return:-return} ($cf_TERMTST); } -_ACEOF -rm -f conftest$ac_exeext -if { (eval echo "$as_me:6207: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:6210: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (eval echo "$as_me:6212: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:6215: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - echo "yes, there is a termcap/tgetent in $cf_termlib" 1>&5 - if test -n "$cf_termlib" ; then - cf_cv_lib_tgetent="-l$cf_termlib" - else - cf_cv_lib_tgetent=yes - fi - break -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -echo "no, there is no termcap/tgetent in $cf_termlib" 1>&5 -fi -rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +case ".$cf_path" in #(vi +.\$\(*\)*|.\'*\'*) #(vi + ;; +..|./*|.\\*) #(vi + ;; +.[a-zA-Z]:[\\/]*) #(vi OS/2 EMX + ;; +.\${*prefix}*|.\${*dir}*) #(vi + eval cf_path="$cf_path" + case ".$cf_path" in #(vi + .NONE/*) + cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%` + ;; + esac + ;; #(vi +.no|.NONE/*) + cf_path=`echo $cf_path | sed -e s%NONE%$cf_path_syntax%` + ;; +*) + { { echo "$as_me:6135: error: expected a pathname, not \"$cf_path\"" >&5 +echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;} + { (exit 1); exit 1; }; } + ;; +esac + fi -done -LIBS="$cf_save_LIBS" +echo "$as_me:6142: result: $ICONDIR" >&5 +echo "${ECHO_T}$ICONDIR" >&6 +no_icondir= +if test "$ICONDIR" = no +then + no_icondir="#" +else + EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(ICONDIR)" fi -echo "$as_me:6236: result: $cf_cv_lib_tgetent" >&5 -echo "${ECHO_T}$cf_cv_lib_tgetent" >&6 -# If we found a working tgetent(), set LIBS and check for termcap.h. -# (LIBS cannot be set inside AC_CACHE_CHECK; the commands there should -# not have side effects other than setting the cache variable, because -# they are not executed when a cached value exists.) -if test "x$cf_cv_lib_tgetent" != xno ; then - test "x$cf_cv_lib_tgetent" != xyes && LIBS="$cf_cv_lib_tgetent $LIBS" - cat >>confdefs.h <<\EOF -#define USE_TERMCAP 1 -EOF +echo "$as_me:6153: checking if icon theme should be used" >&5 +echo $ECHO_N "checking if icon theme should be used... $ECHO_C" >&6 - if test "$cf_full_tgetent" = no ; then - cat >conftest.$ac_ext <<_ACEOF -#line 6251 "configure" -#include "confdefs.h" +# Check whether --with-icon-theme or --without-icon-theme was given. +if test "${with_icon_theme+set}" = set; then + withval="$with_icon_theme" + ICON_THEME=$withval +else + ICON_THEME=no +fi; -#include -int -main () -{ +case "x$ICON_THEME" in #(vi +xno) #(vi + ;; +x|xyes) + ICON_THEME=hicolor + ;; +esac +echo "$as_me:6171: result: $ICON_THEME" >&5 +echo "${ECHO_T}$ICON_THEME" >&6 -#ifdef NCURSES_VERSION -make an error -#endif - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:6267: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:6270: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:6273: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:6276: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cat >>confdefs.h <<\EOF -#define HAVE_TERMCAP_H 1 -EOF +if test "x$ICON_THEME" = xno +then + if test "x$ICONDIR" != xno + then + test -n "$verbose" && echo " ignoring icondir without theme" 1>&6 -else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -fi -rm -f conftest.$ac_objext conftest.$ac_ext - else +echo "${as_me:-configure}:6180: testing ignoring icondir without theme ..." 1>&5 -for ac_header in termcap.h -do -as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:6292: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 -if eval "test \"\${$as_ac_Header+set}\" = set"; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 6298 "configure" -#include "confdefs.h" -#include <$ac_header> -_ACEOF -if { (eval echo "$as_me:6302: \"$ac_cpp conftest.$ac_ext\"") >&5 - (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 - ac_status=$? - egrep -v '^ *\+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:6308: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null; then - if test -s conftest.err; then - ac_cpp_err=$ac_c_preproc_warn_flag - else - ac_cpp_err= - fi + no_icondir="#" + fi else - ac_cpp_err=yes + if test "x$ICONDIR" = xno + then + { { echo "$as_me:6187: error: icondir must be set for icon theme" >&5 +echo "$as_me: error: icondir must be set for icon theme" >&2;} + { (exit 1); exit 1; }; } + fi fi -if test -z "$ac_cpp_err"; then - eval "$as_ac_Header=yes" + +: ${ICON_FORMAT:=".svg .png .xpm"} + +# ICON_NAME= +ICON_LIST= + +if test "x$ICON_THEME" != xno +then + cf_icon_list="icons/$ICON_NAME icons/${ICON_NAME}_48x48" else - echo "$as_me: failed program was:" >&5 - cat conftest.$ac_ext >&5 - eval "$as_ac_Header=no" + cf_icon_list="icons/${ICON_NAME}_48x48" fi -rm -f conftest.err conftest.$ac_ext + +echo "$as_me:6205: checking for icon(s) to install" >&5 +echo $ECHO_N "checking for icon(s) to install... $ECHO_C" >&6 +for cf_name in $cf_icon_list +do + test -n "$verbose" && echo " using $ICON_FORMAT" 1>&6 + +echo "${as_me:-configure}:6211: testing using $ICON_FORMAT ..." 1>&5 + + for cf_suffix in $ICON_FORMAT + do + cf_icon="${cf_name}${cf_suffix}" + cf_left=`echo "$cf_icon" | sed -e 's/:.*//'` + if test ! -f "${cf_left}" + then + if test "x$srcdir" != "x." + then + cf_icon="${srcdir}/${cf_left}" + cf_left=`echo "$cf_icon" | sed -e 's/:.*//'` + if test ! -f "${cf_left}" + then + continue + fi + else + continue + fi + fi + if test "x$ICON_THEME" != xno + then + cf_base=`basename $cf_left` + cf_trim=`echo "$cf_base" | sed -e 's/_[0-9][0-9]x[0-9][0-9]\././'` + case "x${cf_base}" in #(vi + *:*) #(vi + cf_next=$cf_base + # user-defined mapping + ;; + *.png) #(vi + cf_size=`file "$cf_left"|sed -e 's/^[^:]*://' -e 's/^.*[^0-9]\([0-9][0-9]* x [0-9][0-9]*\)[^0-9].*$/\1/' -e 's/ //g'` + if test -z "$cf_size" + then + { echo "$as_me:6244: WARNING: cannot determine size of $cf_left" >&5 +echo "$as_me: WARNING: cannot determine size of $cf_left" >&2;} + continue + fi + cf_next="$cf_size/apps/$cf_trim" + ;; + *.svg) #(vi + cf_next="scalable/apps/$cf_trim" + ;; + *.xpm) + test -n "$verbose" && echo " ignored XPM file in icon theme" 1>&6 + +echo "${as_me:-configure}:6256: testing ignored XPM file in icon theme ..." 1>&5 + + continue + ;; + *_[0-9][0-9]*x[0-9][0-9]*.*) #(vi + cf_size=`echo "$cf_left"|sed -e 's/^.*_\([0-9][0-9]*x[0-9][0-9]*\)\..*$/\1/'` + cf_left=`echo "$cf_left"|sed -e 's/^\(.*\)_\([0-9][0-9]*x[0-9][0-9]*\)\(\..*\)$/\1\3/'` + cf_next="$cf_size/apps/$cf_base" + ;; + esac + test -n "$verbose" && echo " adding $cf_next" 1>&6 + +echo "${as_me:-configure}:6268: testing adding $cf_next ..." 1>&5 + + cf_icon="${cf_icon}:${cf_next}" + fi + test -n "$ICON_LIST" && ICON_LIST="$ICON_LIST " + ICON_LIST="$ICON_LIST${cf_icon}" + if test -z "$ICON_NAME" + then + ICON_NAME=`basename $cf_icon | sed -e 's/[.:].*//'` + fi + done +done + +if test -n "$verbose" +then + echo "$as_me:6283: checking result" >&5 +echo $ECHO_N "checking result... $ECHO_C" >&6 fi -echo "$as_me:6327: result: `eval echo '${'$as_ac_Header'}'`" >&5 -echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <&5 +echo "${ECHO_T}$ICON_LIST" >&6 +if test -z "$ICON_LIST" +then + { { echo "$as_me:6291: error: no icons found" >&5 +echo "$as_me: error: no icons found" >&2;} + { (exit 1); exit 1; }; } fi -done - fi +echo "$as_me:6296: checking for icon name" >&5 +echo $ECHO_N "checking for icon name... $ECHO_C" >&6 +echo "$as_me:6298: result: $ICON_NAME" >&5 +echo "${ECHO_T}$ICON_NAME" >&6 + +# Comment-out the install-desktop rule if the desktop-utils are not found. +echo "$as_me:6302: checking if you want to install desktop files" >&5 +echo $ECHO_N "checking if you want to install desktop files... $ECHO_C" >&6 + +# Check whether --enable-desktop or --disable-desktop was given. +if test "${enable_desktop+set}" = set; then + enableval="$enable_desktop" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_desktop=$enableval + else + enable_desktop=$enableval + fi else - # If we didn't find a tgetent() that supports the buffer - # argument, look again to see whether we can find even - # a crippled one. A crippled tgetent() is still useful to - # validate values for the TERM environment variable given to - # child processes. - echo "$as_me:6344: checking for partial tgetent function" >&5 -echo $ECHO_N "checking for partial tgetent function... $ECHO_C" >&6 -if test "${cf_cv_lib_part_tgetent+set}" = set; then + enableval=yes + enable_desktop=$enableval + +fi; +echo "$as_me:6319: result: $enable_desktop" >&5 +echo "${ECHO_T}$enable_desktop" >&6 + +desktop_utils= +if test "$enable_desktop" = yes ; then +# Extract the first word of "desktop-file-install", so it can be a program name with args. +set dummy desktop-file-install; ac_word=$2 +echo "$as_me:6326: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_desktop_utils+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else + if test -n "$desktop_utils"; then + ac_cv_prog_desktop_utils="$desktop_utils" # Let the user override the test. +else + ac_save_IFS=$IFS; IFS=$ac_path_separator +ac_dummy="$PATH" +for ac_dir in $ac_dummy; do + IFS=$ac_save_IFS + test -z "$ac_dir" && ac_dir=. + $as_executable_p "$ac_dir/$ac_word" || continue +ac_cv_prog_desktop_utils="yes" +echo "$as_me:6341: found $ac_dir/$ac_word" >&5 +break +done - cf_cv_lib_part_tgetent=no - for cf_termlib in $cf_TERMLIB ; do - LIBS="$cf_save_LIBS -l$cf_termlib" - cat >conftest.$ac_ext <<_ACEOF -#line 6354 "configure" -#include "confdefs.h" - -int -main () -{ -tgetent(0, "$cf_TERMVAR") - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:6366: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:6369: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:6372: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:6375: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - echo "there is a terminfo/tgetent in $cf_termlib" 1>&5 - cf_cv_lib_part_tgetent="-l$cf_termlib" - break + test -z "$ac_cv_prog_desktop_utils" && ac_cv_prog_desktop_utils="no" +fi +fi +desktop_utils=$ac_cv_prog_desktop_utils +if test -n "$desktop_utils"; then + echo "$as_me:6350: result: $desktop_utils" >&5 +echo "${ECHO_T}$desktop_utils" >&6 else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 + echo "$as_me:6353: result: no" >&5 +echo "${ECHO_T}no" >&6 fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext - done - LIBS="$cf_save_LIBS" fi -echo "$as_me:6389: result: $cf_cv_lib_part_tgetent" >&5 -echo "${ECHO_T}$cf_cv_lib_part_tgetent" >&6 - if test "$cf_cv_lib_part_tgetent" != no ; then - LIBS="$cf_cv_lib_part_tgetent $LIBS" - -for ac_header in termcap.h -do -as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:6398: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 -if eval "test \"\${$as_ac_Header+set}\" = set"; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 6404 "configure" -#include "confdefs.h" -#include <$ac_header> -_ACEOF -if { (eval echo "$as_me:6408: \"$ac_cpp conftest.$ac_ext\"") >&5 - (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 - ac_status=$? - egrep -v '^ *\+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:6414: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null; then - if test -s conftest.err; then - ac_cpp_err=$ac_c_preproc_warn_flag - else - ac_cpp_err= - fi -else - ac_cpp_err=yes -fi -if test -z "$ac_cpp_err"; then - eval "$as_ac_Header=yes" -else - echo "$as_me: failed program was:" >&5 - cat conftest.$ac_ext >&5 - eval "$as_ac_Header=no" -fi -rm -f conftest.err conftest.$ac_ext -fi -echo "$as_me:6433: result: `eval echo '${'$as_ac_Header'}'`" >&5 -echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <>confdefs.h <<\EOF -#define USE_TERMINFO 1 -EOF - - fi -fi - -echo "$as_me:6452: checking for X applications class" >&5 -echo $ECHO_N "checking for X applications class... $ECHO_C" >&6 - -# Check whether --with-app-class or --without-app-class was given. -if test "${with_app_class+set}" = set; then - withval="$with_app_class" - APP_CLASS=$withval -else - APP_CLASS=XTerm -fi; - -case x$APP_CLASS in #(vi -*[/@,%]*) #(vi - { echo "$as_me:6465: WARNING: X applications class cannot contain punctuation" >&5 -echo "$as_me: WARNING: X applications class cannot contain punctuation" >&2;} - APP_CLASS=XTerm - ;; -x[A-Z]*) #(vi - ;; -*) - { echo "$as_me:6472: WARNING: X applications class must start with capital, ignoring $APP_CLASS" >&5 -echo "$as_me: WARNING: X applications class must start with capital, ignoring $APP_CLASS" >&2;} - APP_CLASS=XTerm - ;; -esac - -echo "$as_me:6478: result: $APP_CLASS" >&5 -echo "${ECHO_T}$APP_CLASS" >&6 - -echo "$as_me:6481: checking for directory to install resource files" >&5 -echo $ECHO_N "checking for directory to install resource files... $ECHO_C" >&6 - -# Check whether --with-app-defaults or --without-app-defaults was given. -if test "${with_app_defaults+set}" = set; then - withval="$with_app_defaults" - -else - withval="${appsdir:-'\$(exec_prefix)/lib/X11/app-defaults'}" -fi; if test -n "'\$(exec_prefix)/lib/X11/app-defaults'" ; then - -if test "x$prefix" != xNONE; then - cf_path_syntax="$prefix" -else - cf_path_syntax="$ac_default_prefix" -fi - -case ".$withval" in #(vi -.\$\(*\)*|.\'*\'*) #(vi - ;; -..|./*|.\\*) #(vi - ;; -.[a-zA-Z]:[\\/]*) #(vi OS/2 EMX - ;; -.\${*prefix}*) #(vi - eval withval="$withval" - case ".$withval" in #(vi - .NONE/*) - withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` - ;; - esac - ;; #(vi -.no|.NONE/*) - withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` - ;; -*) - { { echo "$as_me:6517: error: expected a pathname, not \"$withval\"" >&5 -echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;} - { (exit 1); exit 1; }; } - ;; -esac - -fi -appsdir="$withval" - -echo "$as_me:6526: result: $appsdir" >&5 -echo "${ECHO_T}$appsdir" >&6 - -no_appsdir= -test "$appsdir" = no && no_appsdir="#" - -echo "$as_me:6532: checking for directory to install icons" >&5 -echo $ECHO_N "checking for directory to install icons... $ECHO_C" >&6 - -# Check whether --with-icondir or --without-icondir was given. -if test "${with_icondir+set}" = set; then - withval="$with_icondir" - -else - withval="${icondir:-'\$(exec_prefix)/share/pixmaps'}" -fi; if test -n "'\$(exec_prefix)/share/pixmaps'" ; then - -if test "x$prefix" != xNONE; then - cf_path_syntax="$prefix" -else - cf_path_syntax="$ac_default_prefix" -fi - -case ".$withval" in #(vi -.\$\(*\)*|.\'*\'*) #(vi - ;; -..|./*|.\\*) #(vi - ;; -.[a-zA-Z]:[\\/]*) #(vi OS/2 EMX - ;; -.\${*prefix}*) #(vi - eval withval="$withval" - case ".$withval" in #(vi - .NONE/*) - withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` - ;; - esac - ;; #(vi -.no|.NONE/*) - withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` - ;; -*) - { { echo "$as_me:6568: error: expected a pathname, not \"$withval\"" >&5 -echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;} - { (exit 1); exit 1; }; } - ;; -esac - -fi -icondir="$withval" - -echo "$as_me:6577: result: $icondir" >&5 -echo "${ECHO_T}$icondir" >&6 - -no_icondir= -test "$icondir" = no && no_icondir="#" - -# Comment-out the install-desktop rule if the desktop-utils are not found. -echo "$as_me:6584: checking if you want to install desktop files" >&5 -echo $ECHO_N "checking if you want to install desktop files... $ECHO_C" >&6 - -# Check whether --enable-desktop or --disable-desktop was given. -if test "${enable_desktop+set}" = set; then - enableval="$enable_desktop" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - enable_desktop=$enableval - else - enable_desktop=$enableval - fi -else - enableval=yes - enable_desktop=$enableval - -fi; -echo "$as_me:6601: result: $enable_desktop" >&5 -echo "${ECHO_T}$enable_desktop" >&6 - -desktop_utils= -if test "$enable_desktop" = yes ; then -# Extract the first word of "desktop-file-install", so it can be a program name with args. -set dummy desktop-file-install; ac_word=$2 -echo "$as_me:6608: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 -if test "${ac_cv_prog_desktop_utils+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test -n "$desktop_utils"; then - ac_cv_prog_desktop_utils="$desktop_utils" # Let the user override the test. -else - ac_save_IFS=$IFS; IFS=$ac_path_separator -ac_dummy="$PATH" -for ac_dir in $ac_dummy; do - IFS=$ac_save_IFS - test -z "$ac_dir" && ac_dir=. - $as_executable_p "$ac_dir/$ac_word" || continue -ac_cv_prog_desktop_utils="yes" -echo "$as_me:6623: found $ac_dir/$ac_word" >&5 -break -done - - test -z "$ac_cv_prog_desktop_utils" && ac_cv_prog_desktop_utils="no" -fi -fi -desktop_utils=$ac_cv_prog_desktop_utils -if test -n "$desktop_utils"; then - echo "$as_me:6632: result: $desktop_utils" >&5 -echo "${ECHO_T}$desktop_utils" >&6 -else - echo "$as_me:6635: result: no" >&5 -echo "${ECHO_T}no" >&6 -fi - -fi - -test "$desktop_utils" = yes && desktop_utils= || desktop_utils="#" +test "$desktop_utils" = yes && desktop_utils= || desktop_utils="#" if test -z "$desktop_utils" then - echo "$as_me:6645: checking for requested desktop-category" >&5 + echo "$as_me:6363: checking for requested desktop-category" >&5 echo $ECHO_N "checking for requested desktop-category... $ECHO_C" >&6 # Check whether --with-desktop-category or --without-desktop-category was given. @@ -6652,7 +6370,7 @@ else cf_desktop_want=auto fi; - echo "$as_me:6655: result: $cf_desktop_want" >&5 + echo "$as_me:6373: result: $cf_desktop_want" >&5 echo "${ECHO_T}$cf_desktop_want" >&6 if test "$cf_desktop_want" = auto @@ -6675,7 +6393,7 @@ xterm|*-xterm|*rxvt*|konsole|*-terminal) test -n "$verbose" && echo " inspect $cf_desktop_path" 1>&6 -echo "${as_me:-configure}:6678: testing inspect $cf_desktop_path ..." 1>&5 +echo "${as_me:-configure}:6396: testing inspect $cf_desktop_path ..." 1>&5 egrep '^Categories=' $cf_desktop_path | \ tr ';' '\n' | \ @@ -6704,15 +6422,36 @@ done cf_desktop_want=`cat conftest.2 | tr '\n' ';'` fi + if test -n "$cf_desktop_want" + then + if test "$cf_desktop_want" = auto + then + cf_desktop_want= + else + # do a sanity check on the semicolon-separated list, ignore on failure + cf_desktop_test=`echo "$cf_desktop_want" | sed -e 's/[^;]//g'` + test -z "$cf_desktop_test" && cf_desktop_want= + cf_desktop_test=`echo "$cf_desktop_want" | sed -e 's/^.*;$/./g'` + test -z "$cf_desktop_test" && cf_desktop_want= + fi + fi + if test -z "$cf_desktop_want" + then + cf_desktop_want="`echo "System|TerminalEmulator|Utility|*" | sed -e 's/\*//g' -e 's/|/;/g' -e 's/;*$/;/g'`" + test -n "$verbose" && echo " no usable value found for desktop category" 1>&6 + +echo "${as_me:-configure}:6443: testing no usable value found for desktop category ..." 1>&5 + + fi fi DESKTOP_CATEGORY=`echo "$cf_desktop_want" | sed -e 's/[ ,]/;/g'` - test -n "$verbose" && echo " resulting category=$DESKTOP_CATEGORY" 1>&6 + test -n "$verbose" && echo " will use Categories=$DESKTOP_CATEGORY" 1>&6 -echo "${as_me:-configure}:6711: testing resulting category=$DESKTOP_CATEGORY ..." 1>&5 +echo "${as_me:-configure}:6450: testing will use Categories=$DESKTOP_CATEGORY ..." 1>&5 fi -echo "$as_me:6715: checking for install-permissions reference" >&5 +echo "$as_me:6454: checking for install-permissions reference" >&5 echo $ECHO_N "checking for install-permissions reference... $ECHO_C" >&6 # Check whether --with-reference or --without-reference was given. @@ -6722,22 +6461,27 @@ else with_reference=xterm fi; -echo "$as_me:6725: result: $with_reference" >&5 +echo "$as_me:6464: result: $with_reference" >&5 echo "${ECHO_T}$with_reference" >&6 with_full_paths=yes + echo "$as_me:6469: checking for PATH separator" >&5 +echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6 case $cf_cv_system_name in os2*) PATH_SEPARATOR=';' ;; - *) PATH_SEPARATOR=':' ;; + *) ${PATH_SEPARATOR:=':'} ;; esac + echo "$as_me:6476: result: $PATH_SEPARATOR" >&5 +echo "${ECHO_T}$PATH_SEPARATOR" >&6 + test -z "$XTERM_PATH" && XTERM_PATH=$with_reference for ac_prog in $XTERM_PATH $with_reference do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:6740: checking for $ac_word" >&5 +echo "$as_me:6484: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_path_XTERM_PATH+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -6754,7 +6498,7 @@ test -z "$ac_dir" && ac_dir=. if $as_executable_p "$ac_dir/$ac_word"; then ac_cv_path_XTERM_PATH="$ac_dir/$ac_word" - echo "$as_me:6757: found $ac_dir/$ac_word" >&5 + echo "$as_me:6501: found $ac_dir/$ac_word" >&5 break fi done @@ -6765,10 +6509,10 @@ XTERM_PATH=$ac_cv_path_XTERM_PATH if test -n "$XTERM_PATH"; then - echo "$as_me:6768: result: $XTERM_PATH" >&5 + echo "$as_me:6512: result: $XTERM_PATH" >&5 echo "${ECHO_T}$XTERM_PATH" >&6 else - echo "$as_me:6771: result: no" >&5 + echo "$as_me:6515: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -6797,7 +6541,7 @@ ;; .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX ;; -.\${*prefix}*) #(vi +.\${*prefix}*|.\${*dir}*) #(vi eval cf_temp="$cf_temp" case ".$cf_temp" in #(vi .NONE/*) @@ -6827,13 +6571,14 @@ if test -n "$cf_path_prog" ; then -echo "${as_me:-configure}:6830: testing defining path for ${cf_path_prog} ..." 1>&5 +echo "${as_me:-configure}:6574: testing defining path for ${cf_path_prog} ..." 1>&5 - cat >>confdefs.h <>confdefs.h <>confdefs.h <>confdefs.h <&5 +echo "$as_me:6595: checking for symbolic link to create to $cf_name" >&5 echo $ECHO_N "checking for symbolic link to create to $cf_name... $ECHO_C" >&6 # Check whether --with-xterm-symlink or --without-xterm-symlink was given. @@ -6857,7 +6602,7 @@ else with_symlink=xterm fi; -echo "$as_me:6860: result: $with_symlink" >&5 +echo "$as_me:6605: result: $with_symlink" >&5 echo "${ECHO_T}$with_symlink" >&6 test "$with_symlink" = yes && with_symlink=xterm test -n "$with_symlink" && \ @@ -6866,7 +6611,27 @@ XTERM_SYMLINK="$with_symlink" fi -echo "$as_me:6869: checking if you want to disable setuid" >&5 +echo "$as_me:6614: checking if you want to disable openpty" >&5 +echo $ECHO_N "checking if you want to disable openpty... $ECHO_C" >&6 + +# Check whether --enable-openpty or --disable-openpty was given. +if test "${enable_openpty+set}" = set; then + enableval="$enable_openpty" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + disable_openpty=yes + else + disable_openpty=no + fi +else + enableval=yes + disable_openpty=no + +fi; +echo "$as_me:6631: result: $disable_openpty" >&5 +echo "${ECHO_T}$disable_openpty" >&6 + +echo "$as_me:6634: checking if you want to disable setuid" >&5 echo $ECHO_N "checking if you want to disable setuid... $ECHO_C" >&6 # Check whether --enable-setuid or --disable-setuid was given. @@ -6883,10 +6648,10 @@ disable_setuid=no fi; -echo "$as_me:6886: result: $disable_setuid" >&5 +echo "$as_me:6651: result: $disable_setuid" >&5 echo "${ECHO_T}$disable_setuid" >&6 -echo "$as_me:6889: checking if you want to disable setgid" >&5 +echo "$as_me:6654: checking if you want to disable setgid" >&5 echo $ECHO_N "checking if you want to disable setgid... $ECHO_C" >&6 # Check whether --enable-setgid or --disable-setgid was given. @@ -6903,10 +6668,10 @@ disable_setgid=no fi; -echo "$as_me:6906: result: $disable_setgid" >&5 +echo "$as_me:6671: result: $disable_setgid" >&5 echo "${ECHO_T}$disable_setgid" >&6 -echo "$as_me:6909: checking if you want to run xterm setuid to a given user" >&5 +echo "$as_me:6674: checking if you want to run xterm setuid to a given user" >&5 echo $ECHO_N "checking if you want to run xterm setuid to a given user... $ECHO_C" >&6 # Check whether --with-setuid or --without-setuid was given. @@ -6916,7 +6681,7 @@ else use_given_setuid=no fi; -echo "$as_me:6919: result: $use_given_setuid" >&5 +echo "$as_me:6684: result: $use_given_setuid" >&5 echo "${ECHO_T}$use_given_setuid" >&6 if test "$use_given_setuid" != no ; then @@ -6929,7 +6694,7 @@ SINSTALL_OPTS="$SINSTALL_OPTS u+s -u $cf_cv_given_setuid" fi -echo "$as_me:6932: checking if you want to run xterm setgid to match utmp/utmpx file" >&5 +echo "$as_me:6697: checking if you want to run xterm setgid to match utmp/utmpx file" >&5 echo $ECHO_N "checking if you want to run xterm setgid to match utmp/utmpx file... $ECHO_C" >&6 # Check whether --with-utmp-setgid or --without-utmp-setgid was given. @@ -6939,14 +6704,14 @@ else use_utmp_setgid=no fi; -echo "$as_me:6942: result: $use_utmp_setgid" >&5 +echo "$as_me:6707: result: $use_utmp_setgid" >&5 echo "${ECHO_T}$use_utmp_setgid" >&6 if test "$use_utmp_setgid" != no ; then if test "$use_utmp_setgid" = yes ; then if test $cf_cv_have_utmp != no ; then -echo "$as_me:6949: checking for utmp/utmpx group" >&5 +echo "$as_me:6714: checking for utmp/utmpx group" >&5 echo $ECHO_N "checking for utmp/utmpx group... $ECHO_C" >&6 if test "${cf_cv_utmp_group+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -6988,10 +6753,10 @@ done fi -echo "$as_me:6991: result: $cf_cv_utmp_group" >&5 +echo "$as_me:6756: result: $cf_cv_utmp_group" >&5 echo "${ECHO_T}$cf_cv_utmp_group" >&6 else - { { echo "$as_me:6994: error: cannot find utmp group" >&5 + { { echo "$as_me:6759: error: cannot find utmp group" >&5 echo "$as_me: error: cannot find utmp group" >&2;} { (exit 1); exit 1; }; } fi @@ -7000,18 +6765,19 @@ cf_cv_utmp_group=$use_utmp_setgid fi if test "$cf_cv_posix_saved_ids" != yes ; then - { { echo "$as_me:7003: error: Your system does not support POSIX saved-ids" >&5 + { { echo "$as_me:6768: error: Your system does not support POSIX saved-ids" >&5 echo "$as_me: error: Your system does not support POSIX saved-ids" >&2;} { (exit 1); exit 1; }; } fi - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define USE_UTMP_SETGID 1 EOF SINSTALL_OPTS="$SINSTALL_OPTS g+s -g $cf_cv_utmp_group" fi -echo "$as_me:7014: checking if you want to link with utempter" >&5 +echo "$as_me:6780: checking if you want to link with utempter" >&5 echo $ECHO_N "checking if you want to link with utempter... $ECHO_C" >&6 # Check whether --with-utempter or --without-utempter was given. @@ -7021,12 +6787,12 @@ else use_utempter=no fi; -echo "$as_me:7024: result: $use_utempter" >&5 +echo "$as_me:6790: result: $use_utempter" >&5 echo "${ECHO_T}$use_utempter" >&6 if test "$use_utempter" = yes ; then -echo "$as_me:7029: checking if we can link with utempter library" >&5 +echo "$as_me:6795: checking if we can link with utempter library" >&5 echo $ECHO_N "checking if we can link with utempter library... $ECHO_C" >&6 if test "${cf_cv_have_utempter+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -7035,7 +6801,7 @@ cf_save_LIBS="$LIBS" LIBS="-lutempter $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 7038 "configure" +#line 6804 "configure" #include "confdefs.h" #include @@ -7052,16 +6818,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:7055: \"$ac_link\"") >&5 +if { (eval echo "$as_me:6821: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:7058: \$? = $ac_status" >&5 + echo "$as_me:6824: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:7061: \"$ac_try\"") >&5 + { (eval echo "$as_me:6827: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7064: \$? = $ac_status" >&5 + echo "$as_me:6830: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_have_utempter=yes @@ -7075,10 +6841,11 @@ LIBS="$cf_save_LIBS" fi -echo "$as_me:7078: result: $cf_cv_have_utempter" >&5 +echo "$as_me:6844: result: $cf_cv_have_utempter" >&5 echo "${ECHO_T}$cf_cv_have_utempter" >&6 if test "$cf_cv_have_utempter" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define USE_UTEMPTER 1 EOF @@ -7097,21 +6864,21 @@ disable_setuid=yes test -n "$verbose" && echo " No --disable-setuid option given, force to yes" 1>&6 -echo "${as_me:-configure}:7100: testing No --disable-setuid option given, force to yes ..." 1>&5 +echo "${as_me:-configure}:6867: testing No --disable-setuid option given, force to yes ..." 1>&5 fi fi ### checks for external data -echo "$as_me:7107: checking if external errno is declared" >&5 +echo "$as_me:6874: checking if external errno is declared" >&5 echo $ECHO_N "checking if external errno is declared... $ECHO_C" >&6 if test "${cf_cv_dcl_errno+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7114 "configure" +#line 6881 "configure" #include "confdefs.h" #ifdef HAVE_STDLIB_H @@ -7129,16 +6896,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:7132: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:6899: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:7135: \$? = $ac_status" >&5 + echo "$as_me:6902: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:7138: \"$ac_try\"") >&5 + { (eval echo "$as_me:6905: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7141: \$? = $ac_status" >&5 + echo "$as_me:6908: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_dcl_errno=yes else @@ -7149,7 +6916,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:7152: result: $cf_cv_dcl_errno" >&5 +echo "$as_me:6919: result: $cf_cv_dcl_errno" >&5 echo "${ECHO_T}$cf_cv_dcl_errno" >&6 if test "$cf_cv_dcl_errno" = no ; then @@ -7164,14 +6931,14 @@ # It's possible (for near-UNIX clones) that the data doesn't exist -echo "$as_me:7167: checking if external errno exists" >&5 +echo "$as_me:6934: checking if external errno exists" >&5 echo $ECHO_N "checking if external errno exists... $ECHO_C" >&6 if test "${cf_cv_have_errno+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7174 "configure" +#line 6941 "configure" #include "confdefs.h" #undef errno @@ -7186,16 +6953,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:7189: \"$ac_link\"") >&5 +if { (eval echo "$as_me:6956: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:7192: \$? = $ac_status" >&5 + echo "$as_me:6959: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:7195: \"$ac_try\"") >&5 + { (eval echo "$as_me:6962: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7198: \$? = $ac_status" >&5 + echo "$as_me:6965: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_have_errno=yes else @@ -7206,7 +6973,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:7209: result: $cf_cv_have_errno" >&5 +echo "$as_me:6976: result: $cf_cv_have_errno" >&5 echo "${ECHO_T}$cf_cv_have_errno" >&6 if test "$cf_cv_have_errno" = yes ; then @@ -7219,7 +6986,7 @@ fi -echo "$as_me:7222: checking for explicit tty group name" >&5 +echo "$as_me:6989: checking for explicit tty group name" >&5 echo $ECHO_N "checking for explicit tty group name... $ECHO_C" >&6 # Check whether --with-tty-group or --without-tty-group was given. @@ -7231,11 +6998,11 @@ fi; test -z "$cf_tty_group" && cf_tty_group=auto... test "$cf_tty_group" = yes && cf_tty_group=auto... -echo "$as_me:7234: result: $cf_tty_group" >&5 +echo "$as_me:7001: result: $cf_tty_group" >&5 echo "${ECHO_T}$cf_tty_group" >&6 if test "$cf_tty_group" = "auto..." ; then -echo "$as_me:7238: checking for tty group name" >&5 +echo "$as_me:7005: checking for tty group name" >&5 echo $ECHO_N "checking for tty group name... $ECHO_C" >&6 if test "${cf_cv_tty_group_name+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -7288,12 +7055,13 @@ fi fi -echo "$as_me:7291: result: $cf_cv_tty_group_name" >&5 +echo "$as_me:7058: result: $cf_cv_tty_group_name" >&5 echo "${ECHO_T}$cf_cv_tty_group_name" >&6 cf_tty_group="$cf_cv_tty_group_name" else # if configure option, always do this - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define USE_TTY_GROUP 1 EOF @@ -7307,7 +7075,7 @@ # does apply to the device. We cannot perform this test if we are in batch # mode, or if we are cross-compiling. -echo "$as_me:7310: checking if we may use the $cf_tty_group group" >&5 +echo "$as_me:7078: checking if we may use the $cf_tty_group group" >&5 echo $ECHO_N "checking if we may use the $cf_tty_group group... $ECHO_C" >&6 if test "${cf_cv_tty_group+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -7320,7 +7088,7 @@ cf_cv_tty_group=unknown else cat >conftest.$ac_ext <<_ACEOF -#line 7323 "configure" +#line 7091 "configure" #include "confdefs.h" #include @@ -7346,15 +7114,15 @@ _ACEOF rm -f conftest$ac_exeext -if { (eval echo "$as_me:7349: \"$ac_link\"") >&5 +if { (eval echo "$as_me:7117: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:7352: \$? = $ac_status" >&5 + echo "$as_me:7120: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (eval echo "$as_me:7354: \"$ac_try\"") >&5 + { (eval echo "$as_me:7122: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7357: \$? = $ac_status" >&5 + echo "$as_me:7125: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_tty_group=yes else @@ -7372,11 +7140,11 @@ fi fi -echo "$as_me:7375: result: $cf_cv_tty_group" >&5 +echo "$as_me:7143: result: $cf_cv_tty_group" >&5 echo "${ECHO_T}$cf_cv_tty_group" >&6 if test $cf_cv_tty_group = no ; then - { echo "$as_me:7379: WARNING: Cannot use $cf_tty_group group" >&5 + { echo "$as_me:7147: WARNING: Cannot use $cf_tty_group group" >&5 echo "$as_me: WARNING: Cannot use $cf_tty_group group" >&2;} else cat >>confdefs.h <<\EOF @@ -7387,13 +7155,13 @@ ### checks for system services and user specified options -echo "$as_me:7390: checking for sys/wait.h that is POSIX.1 compatible" >&5 +echo "$as_me:7158: checking for sys/wait.h that is POSIX.1 compatible" >&5 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6 if test "${ac_cv_header_sys_wait_h+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7396 "configure" +#line 7164 "configure" #include "confdefs.h" #include #include @@ -7415,16 +7183,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:7418: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:7186: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:7421: \$? = $ac_status" >&5 + echo "$as_me:7189: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:7424: \"$ac_try\"") >&5 + { (eval echo "$as_me:7192: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7427: \$? = $ac_status" >&5 + echo "$as_me:7195: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_header_sys_wait_h=yes else @@ -7434,7 +7202,7 @@ fi rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:7437: result: $ac_cv_header_sys_wait_h" >&5 +echo "$as_me:7205: result: $ac_cv_header_sys_wait_h" >&5 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6 if test $ac_cv_header_sys_wait_h = yes; then @@ -7444,14 +7212,14 @@ fi -echo "$as_me:7447: checking for POSIX wait functions" >&5 +echo "$as_me:7215: checking for POSIX wait functions" >&5 echo $ECHO_N "checking for POSIX wait functions... $ECHO_C" >&6 if test "${cf_cv_posix_wait+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7454 "configure" +#line 7222 "configure" #include "confdefs.h" #include @@ -7474,16 +7242,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:7477: \"$ac_link\"") >&5 +if { (eval echo "$as_me:7245: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:7480: \$? = $ac_status" >&5 + echo "$as_me:7248: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:7483: \"$ac_try\"") >&5 + { (eval echo "$as_me:7251: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7486: \$? = $ac_status" >&5 + echo "$as_me:7254: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_posix_wait=yes else @@ -7494,20 +7262,21 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:7497: result: $cf_cv_posix_wait" >&5 +echo "$as_me:7265: result: $cf_cv_posix_wait" >&5 echo "${ECHO_T}$cf_cv_posix_wait" >&6 -test "$cf_cv_posix_wait" = yes && cat >>confdefs.h <<\EOF +test "$cf_cv_posix_wait" = yes && +cat >>confdefs.h <<\EOF #define USE_POSIX_WAIT 1 EOF -echo "$as_me:7503: checking if external sys_nerr is declared" >&5 +echo "$as_me:7272: checking if external sys_nerr is declared" >&5 echo $ECHO_N "checking if external sys_nerr is declared... $ECHO_C" >&6 if test "${cf_cv_dcl_sys_nerr+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7510 "configure" +#line 7279 "configure" #include "confdefs.h" #ifdef HAVE_STDLIB_H @@ -7525,16 +7294,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:7528: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:7297: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:7531: \$? = $ac_status" >&5 + echo "$as_me:7300: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:7534: \"$ac_try\"") >&5 + { (eval echo "$as_me:7303: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7537: \$? = $ac_status" >&5 + echo "$as_me:7306: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_dcl_sys_nerr=yes else @@ -7545,7 +7314,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:7548: result: $cf_cv_dcl_sys_nerr" >&5 +echo "$as_me:7317: result: $cf_cv_dcl_sys_nerr" >&5 echo "${ECHO_T}$cf_cv_dcl_sys_nerr" >&6 if test "$cf_cv_dcl_sys_nerr" = no ; then @@ -7560,14 +7329,14 @@ # It's possible (for near-UNIX clones) that the data doesn't exist -echo "$as_me:7563: checking if external sys_nerr exists" >&5 +echo "$as_me:7332: checking if external sys_nerr exists" >&5 echo $ECHO_N "checking if external sys_nerr exists... $ECHO_C" >&6 if test "${cf_cv_have_sys_nerr+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7570 "configure" +#line 7339 "configure" #include "confdefs.h" #undef sys_nerr @@ -7582,16 +7351,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:7585: \"$ac_link\"") >&5 +if { (eval echo "$as_me:7354: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:7588: \$? = $ac_status" >&5 + echo "$as_me:7357: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:7591: \"$ac_try\"") >&5 + { (eval echo "$as_me:7360: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7594: \$? = $ac_status" >&5 + echo "$as_me:7363: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_have_sys_nerr=yes else @@ -7602,7 +7371,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:7605: result: $cf_cv_have_sys_nerr" >&5 +echo "$as_me:7374: result: $cf_cv_have_sys_nerr" >&5 echo "${ECHO_T}$cf_cv_have_sys_nerr" >&6 if test "$cf_cv_have_sys_nerr" = yes ; then @@ -7615,14 +7384,14 @@ fi -echo "$as_me:7618: checking if external sys_errlist is declared" >&5 +echo "$as_me:7387: checking if external sys_errlist is declared" >&5 echo $ECHO_N "checking if external sys_errlist is declared... $ECHO_C" >&6 if test "${cf_cv_dcl_sys_errlist+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7625 "configure" +#line 7394 "configure" #include "confdefs.h" #ifdef HAVE_STDLIB_H @@ -7640,16 +7409,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:7643: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:7412: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:7646: \$? = $ac_status" >&5 + echo "$as_me:7415: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:7649: \"$ac_try\"") >&5 + { (eval echo "$as_me:7418: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7652: \$? = $ac_status" >&5 + echo "$as_me:7421: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_dcl_sys_errlist=yes else @@ -7660,7 +7429,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:7663: result: $cf_cv_dcl_sys_errlist" >&5 +echo "$as_me:7432: result: $cf_cv_dcl_sys_errlist" >&5 echo "${ECHO_T}$cf_cv_dcl_sys_errlist" >&6 if test "$cf_cv_dcl_sys_errlist" = no ; then @@ -7675,14 +7444,14 @@ # It's possible (for near-UNIX clones) that the data doesn't exist -echo "$as_me:7678: checking if external sys_errlist exists" >&5 +echo "$as_me:7447: checking if external sys_errlist exists" >&5 echo $ECHO_N "checking if external sys_errlist exists... $ECHO_C" >&6 if test "${cf_cv_have_sys_errlist+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7685 "configure" +#line 7454 "configure" #include "confdefs.h" #undef sys_errlist @@ -7697,16 +7466,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:7700: \"$ac_link\"") >&5 +if { (eval echo "$as_me:7469: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:7703: \$? = $ac_status" >&5 + echo "$as_me:7472: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:7706: \"$ac_try\"") >&5 + { (eval echo "$as_me:7475: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7709: \$? = $ac_status" >&5 + echo "$as_me:7478: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_have_sys_errlist=yes else @@ -7717,7 +7486,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:7720: result: $cf_cv_have_sys_errlist" >&5 +echo "$as_me:7489: result: $cf_cv_have_sys_errlist" >&5 echo "${ECHO_T}$cf_cv_have_sys_errlist" >&6 if test "$cf_cv_have_sys_errlist" = yes ; then @@ -7737,23 +7506,23 @@ do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:7740: checking for $ac_header" >&5 +echo "$as_me:7509: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7746 "configure" +#line 7515 "configure" #include "confdefs.h" #include <$ac_header> _ACEOF -if { (eval echo "$as_me:7750: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:7519: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:7756: \$? = $ac_status" >&5 + echo "$as_me:7525: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -7772,7 +7541,7 @@ fi rm -f conftest.err conftest.$ac_ext fi -echo "$as_me:7775: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "$as_me:7544: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <&5 +echo "$as_me:7554: checking if we should define SYSV" >&5 echo $ECHO_N "checking if we should define SYSV... $ECHO_C" >&6 if test "${cf_cv_sysv+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7792 "configure" +#line 7561 "configure" #include "confdefs.h" #undef SYSV @@ -7833,16 +7602,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:7836: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:7605: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:7839: \$? = $ac_status" >&5 + echo "$as_me:7608: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:7842: \"$ac_try\"") >&5 + { (eval echo "$as_me:7611: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7845: \$? = $ac_status" >&5 + echo "$as_me:7614: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_sysv=yes else @@ -7853,13 +7622,14 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:7856: result: $cf_cv_sysv" >&5 +echo "$as_me:7625: result: $cf_cv_sysv" >&5 echo "${ECHO_T}$cf_cv_sysv" >&6 -test "$cf_cv_sysv" = yes && cat >>confdefs.h <<\EOF +test "$cf_cv_sysv" = yes && +cat >>confdefs.h <<\EOF #define SYSV 1 EOF -echo "$as_me:7862: checking for elf_begin in -lelf" >&5 +echo "$as_me:7632: checking for elf_begin in -lelf" >&5 echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -7867,7 +7637,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lelf $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 7870 "configure" +#line 7640 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -7886,16 +7656,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:7889: \"$ac_link\"") >&5 +if { (eval echo "$as_me:7659: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:7892: \$? = $ac_status" >&5 + echo "$as_me:7662: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:7895: \"$ac_try\"") >&5 + { (eval echo "$as_me:7665: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7898: \$? = $ac_status" >&5 + echo "$as_me:7668: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_elf_elf_begin=yes else @@ -7906,18 +7676,18 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:7909: result: $ac_cv_lib_elf_elf_begin" >&5 +echo "$as_me:7679: result: $ac_cv_lib_elf_elf_begin" >&5 echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6 if test $ac_cv_lib_elf_elf_begin = yes; then -echo "$as_me:7913: checking if this is an SVR4 system" >&5 +echo "$as_me:7683: checking if this is an SVR4 system" >&5 echo $ECHO_N "checking if this is an SVR4 system... $ECHO_C" >&6 if test "${cf_cv_svr4+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 7920 "configure" +#line 7690 "configure" #include "confdefs.h" #if defined(__CYGWIN__) @@ -7946,16 +7716,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:7949: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:7719: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:7952: \$? = $ac_status" >&5 + echo "$as_me:7722: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:7955: \"$ac_try\"") >&5 + { (eval echo "$as_me:7725: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:7958: \$? = $ac_status" >&5 + echo "$as_me:7728: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_svr4=yes else @@ -7966,16 +7736,17 @@ rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:7969: result: $cf_cv_svr4" >&5 +echo "$as_me:7739: result: $cf_cv_svr4" >&5 echo "${ECHO_T}$cf_cv_svr4" >&6 fi -test "$cf_cv_svr4" = yes && cat >>confdefs.h <<\EOF +test "$cf_cv_svr4" = yes && +cat >>confdefs.h <<\EOF #define SVR4 1 EOF -echo "$as_me:7978: checking for X" >&5 +echo "$as_me:7749: checking for X" >&5 echo $ECHO_N "checking for X... $ECHO_C" >&6 # Check whether --with-x or --without-x was given. @@ -8072,17 +7843,17 @@ # Guess where to find include files, by looking for Intrinsic.h. # First, try using that file with no special directory specified. cat >conftest.$ac_ext <<_ACEOF -#line 8075 "configure" +#line 7846 "configure" #include "confdefs.h" #include _ACEOF -if { (eval echo "$as_me:8079: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:7850: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:8085: \$? = $ac_status" >&5 + echo "$as_me:7856: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -8115,7 +7886,7 @@ ac_save_LIBS=$LIBS LIBS="-lXt $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8118 "configure" +#line 7889 "configure" #include "confdefs.h" #include int @@ -8127,16 +7898,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8130: \"$ac_link\"") >&5 +if { (eval echo "$as_me:7901: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8133: \$? = $ac_status" >&5 + echo "$as_me:7904: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8136: \"$ac_try\"") >&5 + { (eval echo "$as_me:7907: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8139: \$? = $ac_status" >&5 + echo "$as_me:7910: \$? = $ac_status" >&5 (exit $ac_status); }; }; then LIBS=$ac_save_LIBS # We can link X programs with no special library path. @@ -8174,7 +7945,7 @@ fi # $with_x != no if test "$have_x" != yes; then - echo "$as_me:8177: result: $have_x" >&5 + echo "$as_me:7948: result: $have_x" >&5 echo "${ECHO_T}$have_x" >&6 no_x=yes else @@ -8184,7 +7955,7 @@ # Update the cache value to reflect the command line values. ac_cv_have_x="have_x=yes \ ac_x_includes=$x_includes ac_x_libraries=$x_libraries" - echo "$as_me:8187: result: libraries $x_libraries, headers $x_includes" >&5 + echo "$as_me:7958: result: libraries $x_libraries, headers $x_includes" >&5 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6 fi @@ -8208,11 +7979,11 @@ # others require no space. Words are not sufficient . . . . case `(uname -sr) 2>/dev/null` in "SunOS 5"*) - echo "$as_me:8211: checking whether -R must be followed by a space" >&5 + echo "$as_me:7982: checking whether -R must be followed by a space" >&5 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" cat >conftest.$ac_ext <<_ACEOF -#line 8215 "configure" +#line 7986 "configure" #include "confdefs.h" int @@ -8224,16 +7995,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8227: \"$ac_link\"") >&5 +if { (eval echo "$as_me:7998: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8230: \$? = $ac_status" >&5 + echo "$as_me:8001: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8233: \"$ac_try\"") >&5 + { (eval echo "$as_me:8004: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8236: \$? = $ac_status" >&5 + echo "$as_me:8007: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_R_nospace=yes else @@ -8243,13 +8014,13 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext if test $ac_R_nospace = yes; then - echo "$as_me:8246: result: no" >&5 + echo "$as_me:8017: result: no" >&5 echo "${ECHO_T}no" >&6 X_LIBS="$X_LIBS -R$x_libraries" else LIBS="$ac_xsave_LIBS -R $x_libraries" cat >conftest.$ac_ext <<_ACEOF -#line 8252 "configure" +#line 8023 "configure" #include "confdefs.h" int @@ -8261,16 +8032,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8264: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8035: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8267: \$? = $ac_status" >&5 + echo "$as_me:8038: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8270: \"$ac_try\"") >&5 + { (eval echo "$as_me:8041: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8273: \$? = $ac_status" >&5 + echo "$as_me:8044: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_R_space=yes else @@ -8280,11 +8051,11 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext if test $ac_R_space = yes; then - echo "$as_me:8283: result: yes" >&5 + echo "$as_me:8054: result: yes" >&5 echo "${ECHO_T}yes" >&6 X_LIBS="$X_LIBS -R $x_libraries" else - echo "$as_me:8287: result: neither works" >&5 + echo "$as_me:8058: result: neither works" >&5 echo "${ECHO_T}neither works" >&6 fi fi @@ -8304,7 +8075,7 @@ # the Alpha needs dnet_stub (dnet does not exist). ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" cat >conftest.$ac_ext <<_ACEOF -#line 8307 "configure" +#line 8078 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8323,22 +8094,22 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8326: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8097: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8329: \$? = $ac_status" >&5 + echo "$as_me:8100: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8332: \"$ac_try\"") >&5 + { (eval echo "$as_me:8103: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8335: \$? = $ac_status" >&5 + echo "$as_me:8106: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -echo "$as_me:8341: checking for dnet_ntoa in -ldnet" >&5 +echo "$as_me:8112: checking for dnet_ntoa in -ldnet" >&5 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -8346,7 +8117,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-ldnet $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8349 "configure" +#line 8120 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8365,16 +8136,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8368: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8139: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8371: \$? = $ac_status" >&5 + echo "$as_me:8142: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8374: \"$ac_try\"") >&5 + { (eval echo "$as_me:8145: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8377: \$? = $ac_status" >&5 + echo "$as_me:8148: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dnet_dnet_ntoa=yes else @@ -8385,14 +8156,14 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:8388: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 +echo "$as_me:8159: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6 if test $ac_cv_lib_dnet_dnet_ntoa = yes; then X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" fi if test $ac_cv_lib_dnet_dnet_ntoa = no; then - echo "$as_me:8395: checking for dnet_ntoa in -ldnet_stub" >&5 + echo "$as_me:8166: checking for dnet_ntoa in -ldnet_stub" >&5 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -8400,7 +8171,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-ldnet_stub $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8403 "configure" +#line 8174 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8419,16 +8190,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8422: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8193: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8425: \$? = $ac_status" >&5 + echo "$as_me:8196: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8428: \"$ac_try\"") >&5 + { (eval echo "$as_me:8199: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8431: \$? = $ac_status" >&5 + echo "$as_me:8202: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dnet_stub_dnet_ntoa=yes else @@ -8439,7 +8210,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:8442: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 +echo "$as_me:8213: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6 if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" @@ -8458,13 +8229,13 @@ # on Irix 5.2, according to T.E. Dickey. # The functions gethostbyname, getservbyname, and inet_addr are # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. - echo "$as_me:8461: checking for gethostbyname" >&5 + echo "$as_me:8232: checking for gethostbyname" >&5 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6 if test "${ac_cv_func_gethostbyname+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 8467 "configure" +#line 8238 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char gethostbyname (); below. */ @@ -8487,7 +8258,7 @@ #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) choke me #else -f = gethostbyname; +f = gethostbyname; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -8495,16 +8266,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8498: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8269: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8501: \$? = $ac_status" >&5 + echo "$as_me:8272: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8504: \"$ac_try\"") >&5 + { (eval echo "$as_me:8275: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8507: \$? = $ac_status" >&5 + echo "$as_me:8278: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_gethostbyname=yes else @@ -8514,11 +8285,11 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:8517: result: $ac_cv_func_gethostbyname" >&5 +echo "$as_me:8288: result: $ac_cv_func_gethostbyname" >&5 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6 if test $ac_cv_func_gethostbyname = no; then - echo "$as_me:8521: checking for gethostbyname in -lnsl" >&5 + echo "$as_me:8292: checking for gethostbyname in -lnsl" >&5 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -8526,7 +8297,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lnsl $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8529 "configure" +#line 8300 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8545,16 +8316,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8548: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8319: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8551: \$? = $ac_status" >&5 + echo "$as_me:8322: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8554: \"$ac_try\"") >&5 + { (eval echo "$as_me:8325: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8557: \$? = $ac_status" >&5 + echo "$as_me:8328: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_nsl_gethostbyname=yes else @@ -8565,14 +8336,14 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:8568: result: $ac_cv_lib_nsl_gethostbyname" >&5 +echo "$as_me:8339: result: $ac_cv_lib_nsl_gethostbyname" >&5 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6 if test $ac_cv_lib_nsl_gethostbyname = yes; then X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" fi if test $ac_cv_lib_nsl_gethostbyname = no; then - echo "$as_me:8575: checking for gethostbyname in -lbsd" >&5 + echo "$as_me:8346: checking for gethostbyname in -lbsd" >&5 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -8580,7 +8351,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lbsd $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8583 "configure" +#line 8354 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8599,16 +8370,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8602: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8373: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8605: \$? = $ac_status" >&5 + echo "$as_me:8376: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8608: \"$ac_try\"") >&5 + { (eval echo "$as_me:8379: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8611: \$? = $ac_status" >&5 + echo "$as_me:8382: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_bsd_gethostbyname=yes else @@ -8619,7 +8390,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:8622: result: $ac_cv_lib_bsd_gethostbyname" >&5 +echo "$as_me:8393: result: $ac_cv_lib_bsd_gethostbyname" >&5 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6 if test $ac_cv_lib_bsd_gethostbyname = yes; then X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" @@ -8635,13 +8406,13 @@ # variants that don't use the nameserver (or something). -lsocket # must be given before -lnsl if both are needed. We assume that # if connect needs -lnsl, so does gethostbyname. - echo "$as_me:8638: checking for connect" >&5 + echo "$as_me:8409: checking for connect" >&5 echo $ECHO_N "checking for connect... $ECHO_C" >&6 if test "${ac_cv_func_connect+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 8644 "configure" +#line 8415 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char connect (); below. */ @@ -8664,7 +8435,7 @@ #if defined (__stub_connect) || defined (__stub___connect) choke me #else -f = connect; +f = connect; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -8672,16 +8443,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8675: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8446: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8678: \$? = $ac_status" >&5 + echo "$as_me:8449: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8681: \"$ac_try\"") >&5 + { (eval echo "$as_me:8452: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8684: \$? = $ac_status" >&5 + echo "$as_me:8455: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_connect=yes else @@ -8691,11 +8462,11 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:8694: result: $ac_cv_func_connect" >&5 +echo "$as_me:8465: result: $ac_cv_func_connect" >&5 echo "${ECHO_T}$ac_cv_func_connect" >&6 if test $ac_cv_func_connect = no; then - echo "$as_me:8698: checking for connect in -lsocket" >&5 + echo "$as_me:8469: checking for connect in -lsocket" >&5 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6 if test "${ac_cv_lib_socket_connect+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -8703,7 +8474,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lsocket $X_EXTRA_LIBS $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8706 "configure" +#line 8477 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8722,16 +8493,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8725: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8496: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8728: \$? = $ac_status" >&5 + echo "$as_me:8499: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8731: \"$ac_try\"") >&5 + { (eval echo "$as_me:8502: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8734: \$? = $ac_status" >&5 + echo "$as_me:8505: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_socket_connect=yes else @@ -8742,7 +8513,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:8745: result: $ac_cv_lib_socket_connect" >&5 +echo "$as_me:8516: result: $ac_cv_lib_socket_connect" >&5 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6 if test $ac_cv_lib_socket_connect = yes; then X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" @@ -8751,13 +8522,13 @@ fi # Guillermo Gomez says -lposix is necessary on A/UX. - echo "$as_me:8754: checking for remove" >&5 + echo "$as_me:8525: checking for remove" >&5 echo $ECHO_N "checking for remove... $ECHO_C" >&6 if test "${ac_cv_func_remove+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 8760 "configure" +#line 8531 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char remove (); below. */ @@ -8780,7 +8551,7 @@ #if defined (__stub_remove) || defined (__stub___remove) choke me #else -f = remove; +f = remove; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -8788,16 +8559,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8791: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8562: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8794: \$? = $ac_status" >&5 + echo "$as_me:8565: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8797: \"$ac_try\"") >&5 + { (eval echo "$as_me:8568: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8800: \$? = $ac_status" >&5 + echo "$as_me:8571: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_remove=yes else @@ -8807,11 +8578,11 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:8810: result: $ac_cv_func_remove" >&5 +echo "$as_me:8581: result: $ac_cv_func_remove" >&5 echo "${ECHO_T}$ac_cv_func_remove" >&6 if test $ac_cv_func_remove = no; then - echo "$as_me:8814: checking for remove in -lposix" >&5 + echo "$as_me:8585: checking for remove in -lposix" >&5 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6 if test "${ac_cv_lib_posix_remove+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -8819,7 +8590,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lposix $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8822 "configure" +#line 8593 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8838,16 +8609,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8841: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8612: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8844: \$? = $ac_status" >&5 + echo "$as_me:8615: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8847: \"$ac_try\"") >&5 + { (eval echo "$as_me:8618: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8850: \$? = $ac_status" >&5 + echo "$as_me:8621: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_posix_remove=yes else @@ -8858,7 +8629,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:8861: result: $ac_cv_lib_posix_remove" >&5 +echo "$as_me:8632: result: $ac_cv_lib_posix_remove" >&5 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6 if test $ac_cv_lib_posix_remove = yes; then X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" @@ -8867,13 +8638,13 @@ fi # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. - echo "$as_me:8870: checking for shmat" >&5 + echo "$as_me:8641: checking for shmat" >&5 echo $ECHO_N "checking for shmat... $ECHO_C" >&6 if test "${ac_cv_func_shmat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 8876 "configure" +#line 8647 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char shmat (); below. */ @@ -8896,7 +8667,7 @@ #if defined (__stub_shmat) || defined (__stub___shmat) choke me #else -f = shmat; +f = shmat; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -8904,16 +8675,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8907: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8678: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8910: \$? = $ac_status" >&5 + echo "$as_me:8681: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8913: \"$ac_try\"") >&5 + { (eval echo "$as_me:8684: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8916: \$? = $ac_status" >&5 + echo "$as_me:8687: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_shmat=yes else @@ -8923,11 +8694,11 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:8926: result: $ac_cv_func_shmat" >&5 +echo "$as_me:8697: result: $ac_cv_func_shmat" >&5 echo "${ECHO_T}$ac_cv_func_shmat" >&6 if test $ac_cv_func_shmat = no; then - echo "$as_me:8930: checking for shmat in -lipc" >&5 + echo "$as_me:8701: checking for shmat in -lipc" >&5 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6 if test "${ac_cv_lib_ipc_shmat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -8935,7 +8706,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lipc $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 8938 "configure" +#line 8709 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -8954,16 +8725,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:8957: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8728: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:8960: \$? = $ac_status" >&5 + echo "$as_me:8731: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:8963: \"$ac_try\"") >&5 + { (eval echo "$as_me:8734: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:8966: \$? = $ac_status" >&5 + echo "$as_me:8737: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_ipc_shmat=yes else @@ -8974,7 +8745,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:8977: result: $ac_cv_lib_ipc_shmat" >&5 +echo "$as_me:8748: result: $ac_cv_lib_ipc_shmat" >&5 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6 if test $ac_cv_lib_ipc_shmat = yes; then X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" @@ -8992,7 +8763,7 @@ # These have to be linked with before -lX11, unlike the other # libraries we check for below, so use a different variable. # John Interrante, Karl Berry - echo "$as_me:8995: checking for IceConnectionNumber in -lICE" >&5 + echo "$as_me:8766: checking for IceConnectionNumber in -lICE" >&5 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -9000,7 +8771,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lICE $X_EXTRA_LIBS $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 9003 "configure" +#line 8774 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -9019,16 +8790,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:9022: \"$ac_link\"") >&5 +if { (eval echo "$as_me:8793: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:9025: \$? = $ac_status" >&5 + echo "$as_me:8796: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:9028: \"$ac_try\"") >&5 + { (eval echo "$as_me:8799: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:9031: \$? = $ac_status" >&5 + echo "$as_me:8802: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_ICE_IceConnectionNumber=yes else @@ -9039,7 +8810,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:9042: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 +echo "$as_me:8813: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6 if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" @@ -9049,7 +8820,7 @@ fi -echo "$as_me:9052: checking if you want to use pkg-config" >&5 +echo "$as_me:8823: checking if you want to use pkg-config" >&5 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6 # Check whether --with-pkg-config or --without-pkg-config was given. @@ -9059,7 +8830,7 @@ else cf_pkg_config=yes fi; -echo "$as_me:9062: result: $cf_pkg_config" >&5 +echo "$as_me:8833: result: $cf_pkg_config" >&5 echo "${ECHO_T}$cf_pkg_config" >&6 case $cf_pkg_config in #(vi @@ -9071,7 +8842,7 @@ if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 -echo "$as_me:9074: checking for $ac_word" >&5 +echo "$as_me:8845: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -9088,7 +8859,7 @@ test -z "$ac_dir" && ac_dir=. if $as_executable_p "$ac_dir/$ac_word"; then ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word" - echo "$as_me:9091: found $ac_dir/$ac_word" >&5 + echo "$as_me:8862: found $ac_dir/$ac_word" >&5 break fi done @@ -9099,10 +8870,10 @@ PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then - echo "$as_me:9102: result: $PKG_CONFIG" >&5 + echo "$as_me:8873: result: $PKG_CONFIG" >&5 echo "${ECHO_T}$PKG_CONFIG" >&6 else - echo "$as_me:9105: result: no" >&5 + echo "$as_me:8876: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -9111,7 +8882,7 @@ ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 -echo "$as_me:9114: checking for $ac_word" >&5 +echo "$as_me:8885: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -9128,7 +8899,7 @@ test -z "$ac_dir" && ac_dir=. if $as_executable_p "$ac_dir/$ac_word"; then ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word" - echo "$as_me:9131: found $ac_dir/$ac_word" >&5 + echo "$as_me:8902: found $ac_dir/$ac_word" >&5 break fi done @@ -9140,10 +8911,10 @@ ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then - echo "$as_me:9143: result: $ac_pt_PKG_CONFIG" >&5 + echo "$as_me:8914: result: $ac_pt_PKG_CONFIG" >&5 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 else - echo "$as_me:9146: result: no" >&5 + echo "$as_me:8917: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -9174,7 +8945,7 @@ ;; .[a-zA-Z]:[\\/]*) #(vi OS/2 EMX ;; -.\${*prefix}*) #(vi +.\${*prefix}*|.\${*dir}*) #(vi eval PKG_CONFIG="$PKG_CONFIG" case ".$PKG_CONFIG" in #(vi .NONE/*) @@ -9186,7 +8957,7 @@ PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%` ;; *) - { { echo "$as_me:9189: error: expected a pathname, not \"$PKG_CONFIG\"" >&5 + { { echo "$as_me:8960: error: expected a pathname, not \"$PKG_CONFIG\"" >&5 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;} { (exit 1); exit 1; }; } ;; @@ -9199,17 +8970,17 @@ if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then test -n "$verbose" && echo " found package xt" 1>&6 -echo "${as_me:-configure}:9202: testing found package xt ..." 1>&5 +echo "${as_me:-configure}:8973: testing found package xt ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`" test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:9208: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:8979: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:9212: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:8983: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -9296,14 +9067,14 @@ ;; *) # we have an "xt" package, but it may omit Xt's dependency on X11 -echo "$as_me:9299: checking for usable X dependency" >&5 +echo "$as_me:9070: checking for usable X dependency" >&5 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6 if test "${cf_cv_xt_x11_compat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 9306 "configure" +#line 9077 "configure" #include "confdefs.h" #include @@ -9322,16 +9093,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:9325: \"$ac_link\"") >&5 +if { (eval echo "$as_me:9096: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:9328: \$? = $ac_status" >&5 + echo "$as_me:9099: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:9331: \"$ac_try\"") >&5 + { (eval echo "$as_me:9102: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:9334: \$? = $ac_status" >&5 + echo "$as_me:9105: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xt_x11_compat=yes else @@ -9341,30 +9112,30 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:9344: result: $cf_cv_xt_x11_compat" >&5 +echo "$as_me:9115: result: $cf_cv_xt_x11_compat" >&5 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6 if test "$cf_cv_xt_x11_compat" = no then test -n "$verbose" && echo " work around broken X11 dependency" 1>&6 -echo "${as_me:-configure}:9350: testing work around broken X11 dependency ..." 1>&5 +echo "${as_me:-configure}:9121: testing work around broken X11 dependency ..." 1>&5 # 2010/11/19 - good enough until a working Xt on Xcb is delivered. if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then test -n "$verbose" && echo " found package x11" 1>&6 -echo "${as_me:-configure}:9357: testing found package x11 ..." 1>&5 +echo "${as_me:-configure}:9128: testing found package x11 ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`" test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:9363: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:9134: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:9367: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:9138: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -9447,15 +9218,17 @@ LIBS="$cf_pkgconfig_libs $LIBS" : else + cf_pkgconfig_incs= + cf_pkgconfig_libs= test -n "$verbose" && echo " ...before $LIBS" 1>&6 -echo "${as_me:-configure}:9453: testing ...before $LIBS ..." 1>&5 +echo "${as_me:-configure}:9226: testing ...before $LIBS ..." 1>&5 -LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lX11 ," -e 's/ / /g'` +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'` test -n "$verbose" && echo " ...after $LIBS" 1>&6 -echo "${as_me:-configure}:9458: testing ...after $LIBS ..." 1>&5 +echo "${as_me:-configure}:9231: testing ...after $LIBS ..." 1>&5 fi @@ -9463,14 +9236,14 @@ ;; esac -echo "$as_me:9466: checking for usable X Toolkit package" >&5 +echo "$as_me:9239: checking for usable X Toolkit package" >&5 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6 if test "${cf_cv_xt_ice_compat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 9473 "configure" +#line 9246 "configure" #include "confdefs.h" #include @@ -9485,16 +9258,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:9488: \"$ac_link\"") >&5 +if { (eval echo "$as_me:9261: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:9491: \$? = $ac_status" >&5 + echo "$as_me:9264: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:9494: \"$ac_try\"") >&5 + { (eval echo "$as_me:9267: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:9497: \$? = $ac_status" >&5 + echo "$as_me:9270: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xt_ice_compat=yes else @@ -9504,7 +9277,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:9507: result: $cf_cv_xt_ice_compat" >&5 +echo "$as_me:9280: result: $cf_cv_xt_ice_compat" >&5 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6 if test "$cf_cv_xt_ice_compat" = no @@ -9518,22 +9291,22 @@ *) test -n "$verbose" && echo " work around broken ICE dependency" 1>&6 -echo "${as_me:-configure}:9521: testing work around broken ICE dependency ..." 1>&5 +echo "${as_me:-configure}:9294: testing work around broken ICE dependency ..." 1>&5 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then test -n "$verbose" && echo " found package ice" 1>&6 -echo "${as_me:-configure}:9526: testing found package ice ..." 1>&5 +echo "${as_me:-configure}:9299: testing found package ice ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`" test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:9532: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:9305: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:9536: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:9309: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -9618,17 +9391,17 @@ if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then test -n "$verbose" && echo " found package sm" 1>&6 -echo "${as_me:-configure}:9621: testing found package sm ..." 1>&5 +echo "${as_me:-configure}:9394: testing found package sm ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`" test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:9627: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:9400: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:9631: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:9404: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -9711,19 +9484,23 @@ LIBS="$cf_pkgconfig_libs $LIBS" : else + cf_pkgconfig_incs= + cf_pkgconfig_libs= : fi else + cf_pkgconfig_incs= + cf_pkgconfig_libs= test -n "$verbose" && echo " ...before $LIBS" 1>&6 -echo "${as_me:-configure}:9721: testing ...before $LIBS ..." 1>&5 +echo "${as_me:-configure}:9498: testing ...before $LIBS ..." 1>&5 -LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt $X_PRE_LIBS ," -e 's/ / /g'` +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'` test -n "$verbose" && echo " ...after $LIBS" 1>&6 -echo "${as_me:-configure}:9726: testing ...after $LIBS ..." 1>&5 +echo "${as_me:-configure}:9503: testing ...after $LIBS ..." 1>&5 fi @@ -9736,12 +9513,14 @@ cf_have_X_LIBS=yes else + cf_pkgconfig_incs= + cf_pkgconfig_libs= LDFLAGS="$X_LIBS $LDFLAGS" test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6 -echo "${as_me:-configure}:9744: testing checking additions to CFLAGS ..." 1>&5 +echo "${as_me:-configure}:9523: testing checking additions to CFLAGS ..." 1>&5 cf_check_cflags="$CFLAGS" cf_check_cppflags="$CPPFLAGS" @@ -9812,7 +9591,7 @@ if test -n "$cf_new_cflags" ; then test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6 -echo "${as_me:-configure}:9815: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 +echo "${as_me:-configure}:9594: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 CFLAGS="$CFLAGS $cf_new_cflags" fi @@ -9820,7 +9599,7 @@ if test -n "$cf_new_cppflags" ; then test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6 -echo "${as_me:-configure}:9823: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 +echo "${as_me:-configure}:9602: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 CPPFLAGS="$CPPFLAGS $cf_new_cppflags" fi @@ -9828,14 +9607,14 @@ if test -n "$cf_new_extra_cppflags" ; then test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6 -echo "${as_me:-configure}:9831: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 +echo "${as_me:-configure}:9610: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" fi if test "$cf_check_cflags" != "$CFLAGS" ; then cat >conftest.$ac_ext <<_ACEOF -#line 9838 "configure" +#line 9617 "configure" #include "confdefs.h" #include int @@ -9847,16 +9626,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:9850: \"$ac_link\"") >&5 +if { (eval echo "$as_me:9629: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:9853: \$? = $ac_status" >&5 + echo "$as_me:9632: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:9856: \"$ac_try\"") >&5 + { (eval echo "$as_me:9635: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:9859: \$? = $ac_status" >&5 + echo "$as_me:9638: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else @@ -9864,12 +9643,12 @@ cat conftest.$ac_ext >&5 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6 -echo "${as_me:-configure}:9867: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5 +echo "${as_me:-configure}:9646: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5 if test "$cf_check_cppflags" != "$CPPFLAGS" ; then test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6 -echo "${as_me:-configure}:9872: testing but keeping change to \$CPPFLAGS ..." 1>&5 +echo "${as_me:-configure}:9651: testing but keeping change to \$CPPFLAGS ..." 1>&5 fi CFLAGS="$cf_check_flags" @@ -9877,13 +9656,13 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi - echo "$as_me:9880: checking for XOpenDisplay" >&5 + echo "$as_me:9659: checking for XOpenDisplay" >&5 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6 if test "${ac_cv_func_XOpenDisplay+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 9886 "configure" +#line 9665 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char XOpenDisplay (); below. */ @@ -9906,7 +9685,7 @@ #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay) choke me #else -f = XOpenDisplay; +f = XOpenDisplay; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -9914,16 +9693,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:9917: \"$ac_link\"") >&5 +if { (eval echo "$as_me:9696: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:9920: \$? = $ac_status" >&5 + echo "$as_me:9699: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:9923: \"$ac_try\"") >&5 + { (eval echo "$as_me:9702: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:9926: \$? = $ac_status" >&5 + echo "$as_me:9705: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_XOpenDisplay=yes else @@ -9933,13 +9712,13 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:9936: result: $ac_cv_func_XOpenDisplay" >&5 +echo "$as_me:9715: result: $ac_cv_func_XOpenDisplay" >&5 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6 if test $ac_cv_func_XOpenDisplay = yes; then : else - echo "$as_me:9942: checking for XOpenDisplay in -lX11" >&5 + echo "$as_me:9721: checking for XOpenDisplay in -lX11" >&5 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -9947,7 +9726,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 9950 "configure" +#line 9729 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -9966,16 +9745,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:9969: \"$ac_link\"") >&5 +if { (eval echo "$as_me:9748: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:9972: \$? = $ac_status" >&5 + echo "$as_me:9751: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:9975: \"$ac_try\"") >&5 + { (eval echo "$as_me:9754: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:9978: \$? = $ac_status" >&5 + echo "$as_me:9757: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_X11_XOpenDisplay=yes else @@ -9986,7 +9765,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:9989: result: $ac_cv_lib_X11_XOpenDisplay" >&5 +echo "$as_me:9768: result: $ac_cv_lib_X11_XOpenDisplay" >&5 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6 if test $ac_cv_lib_X11_XOpenDisplay = yes; then LIBS="-lX11 $LIBS" @@ -9994,13 +9773,13 @@ fi - echo "$as_me:9997: checking for XtAppInitialize" >&5 + echo "$as_me:9776: checking for XtAppInitialize" >&5 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6 if test "${ac_cv_func_XtAppInitialize+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 10003 "configure" +#line 9782 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char XtAppInitialize (); below. */ @@ -10023,7 +9802,7 @@ #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize) choke me #else -f = XtAppInitialize; +f = XtAppInitialize; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -10031,16 +9810,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:10034: \"$ac_link\"") >&5 +if { (eval echo "$as_me:9813: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:10037: \$? = $ac_status" >&5 + echo "$as_me:9816: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:10040: \"$ac_try\"") >&5 + { (eval echo "$as_me:9819: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:10043: \$? = $ac_status" >&5 + echo "$as_me:9822: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_XtAppInitialize=yes else @@ -10050,13 +9829,13 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:10053: result: $ac_cv_func_XtAppInitialize" >&5 +echo "$as_me:9832: result: $ac_cv_func_XtAppInitialize" >&5 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6 if test $ac_cv_func_XtAppInitialize = yes; then : else - echo "$as_me:10059: checking for XtAppInitialize in -lXt" >&5 + echo "$as_me:9838: checking for XtAppInitialize in -lXt" >&5 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -10064,7 +9843,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 10067 "configure" +#line 9846 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -10083,16 +9862,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:10086: \"$ac_link\"") >&5 +if { (eval echo "$as_me:9865: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:10089: \$? = $ac_status" >&5 + echo "$as_me:9868: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:10092: \"$ac_try\"") >&5 + { (eval echo "$as_me:9871: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:10095: \$? = $ac_status" >&5 + echo "$as_me:9874: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_Xt_XtAppInitialize=yes else @@ -10103,10 +9882,11 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:10106: result: $ac_cv_lib_Xt_XtAppInitialize" >&5 +echo "$as_me:9885: result: $ac_cv_lib_Xt_XtAppInitialize" >&5 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6 if test $ac_cv_lib_Xt_XtAppInitialize = yes; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define HAVE_LIBXT 1 EOF @@ -10119,7 +9899,7 @@ fi if test $cf_have_X_LIBS = no ; then - { echo "$as_me:10122: WARNING: Unable to successfully link X Toolkit library (-lXt) with + { echo "$as_me:9902: WARNING: Unable to successfully link X Toolkit library (-lXt) with test program. You will have to check and add the proper libraries by hand to makefile." >&5 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with @@ -10137,23 +9917,23 @@ do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:10140: checking for $ac_header" >&5 +echo "$as_me:9920: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 10146 "configure" +#line 9926 "configure" #include "confdefs.h" #include <$ac_header> _ACEOF -if { (eval echo "$as_me:10150: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:9930: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:10156: \$? = $ac_status" >&5 + echo "$as_me:9936: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -10172,7 +9952,7 @@ fi rm -f conftest.err conftest.$ac_ext fi -echo "$as_me:10175: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "$as_me:9955: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <&5 -echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6 -withval= +cf_save_cppflags="${CPPFLAGS}" +cf_save_ldflags="${LDFLAGS}" -# Check whether --with-Xaw3d or --without-Xaw3d was given. -if test "${with_Xaw3d+set}" = set; then - withval="$with_Xaw3d" +echo "$as_me:9970: checking if you want to use the Xpm library for colored icon" >&5 +echo $ECHO_N "checking if you want to use the Xpm library for colored icon... $ECHO_C" >&6 -fi; -if test "$withval" = yes ; then - cf_x_athena=Xaw3d - echo "$as_me:10198: result: yes" >&5 -echo "${ECHO_T}yes" >&6 +# Check whether --with-xpm or --without-xpm was given. +if test "${with_xpm+set}" = set; then + withval="$with_xpm" + cf_Xpm_library="$withval" else - echo "$as_me:10201: result: no" >&5 -echo "${ECHO_T}no" >&6 + cf_Xpm_library=yes +fi; +echo "$as_me:9980: result: $cf_Xpm_library" >&5 +echo "${ECHO_T}$cf_Xpm_library" >&6 + +if test "$cf_Xpm_library" != no ; then + if test "$cf_Xpm_library" != yes ; then + CPPFLAGS="$CPPFLAGS -I$withval/include" + LDFLAGS="$LDFLAGS -L$withval/lib" + fi + echo "$as_me:9988: checking for X11/xpm.h" >&5 +echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6 +if test "${ac_cv_header_X11_xpm_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 9994 "configure" +#include "confdefs.h" +#include +_ACEOF +if { (eval echo "$as_me:9998: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:10004: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + ac_cv_header_X11_xpm_h=yes +else + echo "$as_me: failed program was:" >&5 + cat conftest.$ac_ext >&5 + ac_cv_header_X11_xpm_h=no +fi +rm -f conftest.err conftest.$ac_ext +fi +echo "$as_me:10023: result: $ac_cv_header_X11_xpm_h" >&5 +echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6 +if test $ac_cv_header_X11_xpm_h = yes; then + + echo "$as_me:10027: checking for XpmCreatePixmapFromData in -lXpm" >&5 +echo $ECHO_N "checking for XpmCreatePixmapFromData in -lXpm... $ECHO_C" >&6 +if test "${ac_cv_lib_Xpm_XpmCreatePixmapFromData+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lXpm -lX11 $X_LIBS $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line 10035 "configure" +#include "confdefs.h" + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XpmCreatePixmapFromData (); +int +main () +{ +XpmCreatePixmapFromData (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:10054: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:10057: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:10060: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:10063: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_Xpm_XpmCreatePixmapFromData=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_Xpm_XpmCreatePixmapFromData=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:10074: result: $ac_cv_lib_Xpm_XpmCreatePixmapFromData" >&5 +echo "${ECHO_T}$ac_cv_lib_Xpm_XpmCreatePixmapFromData" >&6 +if test $ac_cv_lib_Xpm_XpmCreatePixmapFromData = yes; then + +cat >>confdefs.h <<\EOF +#define HAVE_LIBXPM 1 +EOF + + ICON_SUFFIX=.xpm + LIBS="-lXpm $LIBS" +else + CPPFLAGS="${cf_save_cppflags}" LDFLAGS="${cf_save_ldflags}" +fi + +else + CPPFLAGS="${cf_save_cppflags}" LDFLAGS="${cf_save_ldflags}" +fi + +fi + +cf_x_athena=${cf_x_athena:-Xaw} + +echo "$as_me:10096: checking if you want to link with Xaw 3d library" >&5 +echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6 +withval= + +# Check whether --with-Xaw3d or --without-Xaw3d was given. +if test "${with_Xaw3d+set}" = set; then + withval="$with_Xaw3d" + +fi; +if test "$withval" = yes ; then + cf_x_athena=Xaw3d + echo "$as_me:10107: result: yes" >&5 +echo "${ECHO_T}yes" >&6 +else + echo "$as_me:10110: result: no" >&5 +echo "${ECHO_T}no" >&6 fi -echo "$as_me:10205: checking if you want to link with neXT Athena library" >&5 +echo "$as_me:10114: checking if you want to link with neXT Athena library" >&5 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6 withval= @@ -10213,14 +10122,14 @@ fi; if test "$withval" = yes ; then cf_x_athena=neXtaw - echo "$as_me:10216: result: yes" >&5 + echo "$as_me:10125: result: yes" >&5 echo "${ECHO_T}yes" >&6 else - echo "$as_me:10219: result: no" >&5 + echo "$as_me:10128: result: no" >&5 echo "${ECHO_T}no" >&6 fi -echo "$as_me:10223: checking if you want to link with Athena-Plus library" >&5 +echo "$as_me:10132: checking if you want to link with Athena-Plus library" >&5 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6 withval= @@ -10231,10 +10140,10 @@ fi; if test "$withval" = yes ; then cf_x_athena=XawPlus - echo "$as_me:10234: result: yes" >&5 + echo "$as_me:10143: result: yes" >&5 echo "${ECHO_T}yes" >&6 else - echo "$as_me:10237: result: no" >&5 + echo "$as_me:10146: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -10254,17 +10163,17 @@ if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6 -echo "${as_me:-configure}:10257: testing found package $cf_athena_pkg ..." 1>&5 +echo "${as_me:-configure}:10166: testing found package $cf_athena_pkg ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`" test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:10263: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:10172: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:10267: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:10176: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -10354,14 +10263,27 @@ #define $cf_x_athena_LIBS 1 EOF -echo "$as_me:10357: checking for usable $cf_x_athena/Xmu package" >&5 + for cf_trim_lib in Xmu Xt X11 + do + case "$LIBS" in + *-l$cf_trim_lib\ *-l$cf_trim_lib*) + LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'` + test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6 + +echo "${as_me:-configure}:10273: testing ..trimmed $LIBS ..." 1>&5 + + ;; + esac + done + +echo "$as_me:10279: checking for usable $cf_x_athena/Xmu package" >&5 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6 if test "${cf_cv_xaw_compat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 10364 "configure" +#line 10286 "configure" #include "confdefs.h" #include @@ -10377,16 +10299,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:10380: \"$ac_link\"") >&5 +if { (eval echo "$as_me:10302: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:10383: \$? = $ac_status" >&5 + echo "$as_me:10305: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:10386: \"$ac_try\"") >&5 + { (eval echo "$as_me:10308: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:10389: \$? = $ac_status" >&5 + echo "$as_me:10311: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xaw_compat=yes else @@ -10396,7 +10318,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:10399: result: $cf_cv_xaw_compat" >&5 +echo "$as_me:10321: result: $cf_cv_xaw_compat" >&5 echo "${ECHO_T}$cf_cv_xaw_compat" >&6 if test "$cf_cv_xaw_compat" = no @@ -10408,22 +10330,25 @@ *) test -n "$verbose" && echo " work around broken package" 1>&6 -echo "${as_me:-configure}:10411: testing work around broken package ..." 1>&5 +echo "${as_me:-configure}:10333: testing work around broken package ..." 1>&5 + + cf_save_xmu="$LIBS" + cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'` if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then test -n "$verbose" && echo " found package xmu" 1>&6 -echo "${as_me:-configure}:10416: testing found package xmu ..." 1>&5 +echo "${as_me:-configure}:10341: testing found package xmu ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`" test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:10422: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:10347: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:10426: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:10351: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -10504,26 +10429,54 @@ fi LIBS="$cf_pkgconfig_libs $LIBS" - : + + LIBS="$cf_save_xmu" + +test -n "$verbose" && echo " ...before $LIBS" 1>&6 + +echo "${as_me:-configure}:10437: testing ...before $LIBS ..." 1>&5 + +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'` +test -n "$verbose" && echo " ...after $LIBS" 1>&6 + +echo "${as_me:-configure}:10442: testing ...after $LIBS ..." 1>&5 + else + cf_pkgconfig_incs= + cf_pkgconfig_libs= test -n "$verbose" && echo " ...before $LIBS" 1>&6 -echo "${as_me:-configure}:10512: testing ...before $LIBS ..." 1>&5 +echo "${as_me:-configure}:10450: testing ...before $LIBS ..." 1>&5 -LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lXmu ," -e 's/ / /g'` +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'` test -n "$verbose" && echo " ...after $LIBS" 1>&6 -echo "${as_me:-configure}:10517: testing ...after $LIBS ..." 1>&5 +echo "${as_me:-configure}:10455: testing ...after $LIBS ..." 1>&5 fi + for cf_trim_lib in Xmu Xt X11 + do + case "$LIBS" in + *-l$cf_trim_lib\ *-l$cf_trim_lib*) + LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'` + test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6 + +echo "${as_me:-configure}:10466: testing ..trimmed $LIBS ..." 1>&5 + + ;; + esac + done + ;; esac fi break else + cf_pkgconfig_incs= + cf_pkgconfig_libs= : fi @@ -10535,17 +10488,17 @@ if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then test -n "$verbose" && echo " found package Xext" 1>&6 -echo "${as_me:-configure}:10538: testing found package Xext ..." 1>&5 +echo "${as_me:-configure}:10491: testing found package Xext ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`" test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:10544: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:10497: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:10548: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:10501: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -10628,8 +10581,10 @@ LIBS="$cf_pkgconfig_libs $LIBS" : else + cf_pkgconfig_incs= + cf_pkgconfig_libs= - echo "$as_me:10632: checking for XextCreateExtension in -lXext" >&5 + echo "$as_me:10587: checking for XextCreateExtension in -lXext" >&5 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -10637,7 +10592,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lXext $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 10640 "configure" +#line 10595 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -10656,16 +10611,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:10659: \"$ac_link\"") >&5 +if { (eval echo "$as_me:10614: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:10662: \$? = $ac_status" >&5 + echo "$as_me:10617: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:10665: \"$ac_try\"") >&5 + { (eval echo "$as_me:10620: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:10668: \$? = $ac_status" >&5 + echo "$as_me:10623: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_Xext_XextCreateExtension=yes else @@ -10676,7 +10631,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:10679: result: $ac_cv_lib_Xext_XextCreateExtension" >&5 +echo "$as_me:10634: result: $ac_cv_lib_Xext_XextCreateExtension" >&5 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6 if test $ac_cv_lib_Xext_XextCreateExtension = yes; then LIBS="-lXext $LIBS" @@ -10689,17 +10644,17 @@ if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then test -n "$verbose" && echo " found package xt" 1>&6 -echo "${as_me:-configure}:10692: testing found package xt ..." 1>&5 +echo "${as_me:-configure}:10647: testing found package xt ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`" test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:10698: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:10653: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:10702: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:10657: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -10786,14 +10741,14 @@ ;; *) # we have an "xt" package, but it may omit Xt's dependency on X11 -echo "$as_me:10789: checking for usable X dependency" >&5 +echo "$as_me:10744: checking for usable X dependency" >&5 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6 if test "${cf_cv_xt_x11_compat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 10796 "configure" +#line 10751 "configure" #include "confdefs.h" #include @@ -10812,16 +10767,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:10815: \"$ac_link\"") >&5 +if { (eval echo "$as_me:10770: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:10818: \$? = $ac_status" >&5 + echo "$as_me:10773: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:10821: \"$ac_try\"") >&5 + { (eval echo "$as_me:10776: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:10824: \$? = $ac_status" >&5 + echo "$as_me:10779: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xt_x11_compat=yes else @@ -10831,30 +10786,30 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:10834: result: $cf_cv_xt_x11_compat" >&5 +echo "$as_me:10789: result: $cf_cv_xt_x11_compat" >&5 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6 if test "$cf_cv_xt_x11_compat" = no then test -n "$verbose" && echo " work around broken X11 dependency" 1>&6 -echo "${as_me:-configure}:10840: testing work around broken X11 dependency ..." 1>&5 +echo "${as_me:-configure}:10795: testing work around broken X11 dependency ..." 1>&5 # 2010/11/19 - good enough until a working Xt on Xcb is delivered. if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then test -n "$verbose" && echo " found package x11" 1>&6 -echo "${as_me:-configure}:10847: testing found package x11 ..." 1>&5 +echo "${as_me:-configure}:10802: testing found package x11 ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`" test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:10853: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:10808: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:10857: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:10812: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -10937,15 +10892,17 @@ LIBS="$cf_pkgconfig_libs $LIBS" : else + cf_pkgconfig_incs= + cf_pkgconfig_libs= test -n "$verbose" && echo " ...before $LIBS" 1>&6 -echo "${as_me:-configure}:10943: testing ...before $LIBS ..." 1>&5 +echo "${as_me:-configure}:10900: testing ...before $LIBS ..." 1>&5 -LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt -lX11 ," -e 's/ / /g'` +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'` test -n "$verbose" && echo " ...after $LIBS" 1>&6 -echo "${as_me:-configure}:10948: testing ...after $LIBS ..." 1>&5 +echo "${as_me:-configure}:10905: testing ...after $LIBS ..." 1>&5 fi @@ -10953,14 +10910,14 @@ ;; esac -echo "$as_me:10956: checking for usable X Toolkit package" >&5 +echo "$as_me:10913: checking for usable X Toolkit package" >&5 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6 if test "${cf_cv_xt_ice_compat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 10963 "configure" +#line 10920 "configure" #include "confdefs.h" #include @@ -10975,16 +10932,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:10978: \"$ac_link\"") >&5 +if { (eval echo "$as_me:10935: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:10981: \$? = $ac_status" >&5 + echo "$as_me:10938: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:10984: \"$ac_try\"") >&5 + { (eval echo "$as_me:10941: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:10987: \$? = $ac_status" >&5 + echo "$as_me:10944: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xt_ice_compat=yes else @@ -10994,7 +10951,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:10997: result: $cf_cv_xt_ice_compat" >&5 +echo "$as_me:10954: result: $cf_cv_xt_ice_compat" >&5 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6 if test "$cf_cv_xt_ice_compat" = no @@ -11008,22 +10965,22 @@ *) test -n "$verbose" && echo " work around broken ICE dependency" 1>&6 -echo "${as_me:-configure}:11011: testing work around broken ICE dependency ..." 1>&5 +echo "${as_me:-configure}:10968: testing work around broken ICE dependency ..." 1>&5 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then test -n "$verbose" && echo " found package ice" 1>&6 -echo "${as_me:-configure}:11016: testing found package ice ..." 1>&5 +echo "${as_me:-configure}:10973: testing found package ice ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`" test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:11022: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:10979: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:11026: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:10983: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -11108,17 +11065,17 @@ if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then test -n "$verbose" && echo " found package sm" 1>&6 -echo "${as_me:-configure}:11111: testing found package sm ..." 1>&5 +echo "${as_me:-configure}:11068: testing found package sm ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`" test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:11117: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:11074: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:11121: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:11078: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -11201,19 +11158,23 @@ LIBS="$cf_pkgconfig_libs $LIBS" : else + cf_pkgconfig_incs= + cf_pkgconfig_libs= : fi else + cf_pkgconfig_incs= + cf_pkgconfig_libs= test -n "$verbose" && echo " ...before $LIBS" 1>&6 -echo "${as_me:-configure}:11211: testing ...before $LIBS ..." 1>&5 +echo "${as_me:-configure}:11172: testing ...before $LIBS ..." 1>&5 -LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXt ,-lXt $X_PRE_LIBS ," -e 's/ / /g'` +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'` test -n "$verbose" && echo " ...after $LIBS" 1>&6 -echo "${as_me:-configure}:11216: testing ...after $LIBS ..." 1>&5 +echo "${as_me:-configure}:11177: testing ...after $LIBS ..." 1>&5 fi @@ -11226,12 +11187,14 @@ cf_have_X_LIBS=yes else + cf_pkgconfig_incs= + cf_pkgconfig_libs= LDFLAGS="$X_LIBS $LDFLAGS" test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6 -echo "${as_me:-configure}:11234: testing checking additions to CFLAGS ..." 1>&5 +echo "${as_me:-configure}:11197: testing checking additions to CFLAGS ..." 1>&5 cf_check_cflags="$CFLAGS" cf_check_cppflags="$CPPFLAGS" @@ -11302,7 +11265,7 @@ if test -n "$cf_new_cflags" ; then test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6 -echo "${as_me:-configure}:11305: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 +echo "${as_me:-configure}:11268: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 CFLAGS="$CFLAGS $cf_new_cflags" fi @@ -11310,7 +11273,7 @@ if test -n "$cf_new_cppflags" ; then test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6 -echo "${as_me:-configure}:11313: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 +echo "${as_me:-configure}:11276: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 CPPFLAGS="$CPPFLAGS $cf_new_cppflags" fi @@ -11318,489 +11281,806 @@ if test -n "$cf_new_extra_cppflags" ; then test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6 -echo "${as_me:-configure}:11321: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 +echo "${as_me:-configure}:11284: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" fi if test "$cf_check_cflags" != "$CFLAGS" ; then cat >conftest.$ac_ext <<_ACEOF -#line 11328 "configure" +#line 11291 "configure" #include "confdefs.h" #include int main () { -printf("Hello world"); +printf("Hello world"); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:11303: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:11306: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:11309: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:11312: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + : +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6 + +echo "${as_me:-configure}:11320: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5 + + if test "$cf_check_cppflags" != "$CPPFLAGS" ; then + test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6 + +echo "${as_me:-configure}:11325: testing but keeping change to \$CPPFLAGS ..." 1>&5 + + fi + CFLAGS="$cf_check_flags" +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +fi + + echo "$as_me:11333: checking for XOpenDisplay" >&5 +echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6 +if test "${ac_cv_func_XOpenDisplay+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 11339 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char XOpenDisplay (); below. */ +#include +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XOpenDisplay (); +char (*f) (); + +int +main () +{ +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay) +choke me +#else +f = XOpenDisplay; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:11370: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:11373: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:11376: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:11379: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_func_XOpenDisplay=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_func_XOpenDisplay=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +fi +echo "$as_me:11389: result: $ac_cv_func_XOpenDisplay" >&5 +echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6 +if test $ac_cv_func_XOpenDisplay = yes; then + : +else + + echo "$as_me:11395: checking for XOpenDisplay in -lX11" >&5 +echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6 +if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line 11403 "configure" +#include "confdefs.h" + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XOpenDisplay (); +int +main () +{ +XOpenDisplay (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:11422: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:11425: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:11428: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:11431: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_X11_XOpenDisplay=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_X11_XOpenDisplay=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:11442: result: $ac_cv_lib_X11_XOpenDisplay" >&5 +echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6 +if test $ac_cv_lib_X11_XOpenDisplay = yes; then + LIBS="-lX11 $LIBS" +fi + +fi + + echo "$as_me:11450: checking for XtAppInitialize" >&5 +echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6 +if test "${ac_cv_func_XtAppInitialize+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 11456 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char XtAppInitialize (); below. */ +#include +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XtAppInitialize (); +char (*f) (); + +int +main () +{ +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize) +choke me +#else +f = XtAppInitialize; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:11487: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:11490: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:11493: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:11496: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_func_XtAppInitialize=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_func_XtAppInitialize=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +fi +echo "$as_me:11506: result: $ac_cv_func_XtAppInitialize" >&5 +echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6 +if test $ac_cv_func_XtAppInitialize = yes; then + : +else + + echo "$as_me:11512: checking for XtAppInitialize in -lXt" >&5 +echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6 +if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line 11520 "configure" +#include "confdefs.h" + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XtAppInitialize (); +int +main () +{ +XtAppInitialize (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:11539: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:11542: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:11545: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:11548: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_Xt_XtAppInitialize=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_Xt_XtAppInitialize=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:11559: result: $ac_cv_lib_Xt_XtAppInitialize" >&5 +echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6 +if test $ac_cv_lib_Xt_XtAppInitialize = yes; then + +cat >>confdefs.h <<\EOF +#define HAVE_LIBXT 1 +EOF + + cf_have_X_LIBS=Xt + LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS" +fi + +fi + +fi + +if test $cf_have_X_LIBS = no ; then + { echo "$as_me:11576: WARNING: Unable to successfully link X Toolkit library (-lXt) with +test program. You will have to check and add the proper libraries by hand +to makefile." >&5 +echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with +test program. You will have to check and add the proper libraries by hand +to makefile." >&2;} +fi + +cf_x_athena_root=$cf_x_athena +cf_x_athena_inc="" + +for cf_path in default \ + /usr/contrib/X11R6 \ + /usr/contrib/X11R5 \ + /usr/lib/X11R5 \ + /usr/local +do + if test -z "$cf_x_athena_inc" ; then + cf_save="$CPPFLAGS" + cf_test=X11/$cf_x_athena_root/SimpleMenu.h + if test $cf_path != default ; then + CPPFLAGS="$cf_save -I$cf_path/include" + echo "$as_me:11598: checking for $cf_test in $cf_path" >&5 +echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6 + else + echo "$as_me:11601: checking for $cf_test" >&5 +echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6 + fi + cat >conftest.$ac_ext <<_ACEOF +#line 11605 "configure" +#include "confdefs.h" + +#include +#include <$cf_test> +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:11619: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:11622: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:11625: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:11628: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + cf_result=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +cf_result=no +fi +rm -f conftest.$ac_objext conftest.$ac_ext + echo "$as_me:11637: result: $cf_result" >&5 +echo "${ECHO_T}$cf_result" >&6 + if test "$cf_result" = yes ; then + cf_x_athena_inc=$cf_path + break + else + CPPFLAGS="$cf_save" + fi + fi +done + +if test -z "$cf_x_athena_inc" ; then + { echo "$as_me:11649: WARNING: Unable to successfully find Athena header files with test program" >&5 +echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;} +elif test "$cf_x_athena_inc" != default ; then + CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc" +fi + +cf_x_athena_root=$cf_x_athena +cf_x_athena_lib="" + +for cf_path in default \ + /usr/contrib/X11R6 \ + /usr/contrib/X11R5 \ + /usr/lib/X11R5 \ + /usr/local +do + for cf_lib in \ + ${cf_x_athena_root} \ + ${cf_x_athena_root}7 \ + ${cf_x_athena_root}6 + do + for cf_libs in \ + "-l$cf_lib -lXmu" \ + "-l$cf_lib -lXpm -lXmu" \ + "-l${cf_lib}_s -lXmu_s" + do + if test -z "$cf_x_athena_lib" ; then + cf_save="$LIBS" + cf_test=XawSimpleMenuAddGlobalActions + if test $cf_path != default ; then + LIBS="-L$cf_path/lib $cf_libs $LIBS" + echo "$as_me:11679: checking for $cf_libs in $cf_path" >&5 +echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6 + else + LIBS="$cf_libs $LIBS" + echo "$as_me:11683: checking for $cf_test in $cf_libs" >&5 +echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6 + fi + cat >conftest.$ac_ext <<_ACEOF +#line 11687 "configure" +#include "confdefs.h" + +#include +#include + +int +main () +{ + +$cf_test((XtAppContext) 0) ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:11340: \"$ac_link\"") >&5 +if { (eval echo "$as_me:11703: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:11343: \$? = $ac_status" >&5 + echo "$as_me:11706: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:11346: \"$ac_try\"") >&5 + { (eval echo "$as_me:11709: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11349: \$? = $ac_status" >&5 + echo "$as_me:11712: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - : + cf_result=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6 +cf_result=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext + echo "$as_me:11721: result: $cf_result" >&5 +echo "${ECHO_T}$cf_result" >&6 + if test "$cf_result" = yes ; then + cf_x_athena_lib="$cf_libs" + break + fi + LIBS="$cf_save" + fi + done # cf_libs + test -n "$cf_x_athena_lib" && break + done # cf_lib +done -echo "${as_me:-configure}:11357: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5 +if test -z "$cf_x_athena_lib" ; then + { { echo "$as_me:11735: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5 +echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;} + { (exit 1); exit 1; }; } +fi - if test "$cf_check_cppflags" != "$CPPFLAGS" ; then - test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6 +cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` -echo "${as_me:-configure}:11362: testing but keeping change to \$CPPFLAGS ..." 1>&5 +cat >>confdefs.h <&5 -echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6 -if test "${ac_cv_func_XOpenDisplay+set}" = set; then +for ac_header in X11/Xpoll.h +do +as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +echo "$as_me:11751: checking for $ac_header" >&5 +echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 11376 "configure" +#line 11757 "configure" #include "confdefs.h" -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char XOpenDisplay (); below. */ -#include -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char XOpenDisplay (); -char (*f) (); - -int -main () -{ -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay) -choke me -#else -f = XOpenDisplay; -#endif - - ; - return 0; -} +#include <$ac_header> _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:11407: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:11410: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:11413: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 +if { (eval echo "$as_me:11761: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? - echo "$as_me:11416: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_func_XOpenDisplay=yes + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:11767: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 -ac_cv_func_XOpenDisplay=no + cat conftest.$ac_ext >&5 + eval "$as_ac_Header=no" fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +rm -f conftest.err conftest.$ac_ext fi -echo "$as_me:11426: result: $ac_cv_func_XOpenDisplay" >&5 -echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6 -if test $ac_cv_func_XOpenDisplay = yes; then - : -else +echo "$as_me:11786: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +if test `eval echo '${'$as_ac_Header'}'` = yes; then + cat >>confdefs.h <&5 -echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6 -if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then +fi +done + +echo "$as_me:11796: checking for declaration of fd_set" >&5 +echo $ECHO_N "checking for declaration of fd_set... $ECHO_C" >&6 +if test "${cf_cv_type_fd_set+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" + +echo "${as_me:-configure}:11802: testing sys/types alone ..." 1>&5 + cat >conftest.$ac_ext <<_ACEOF -#line 11440 "configure" +#line 11805 "configure" #include "confdefs.h" -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char XOpenDisplay (); +#include int main () { -XOpenDisplay (); +fd_set x ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:11459: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:11818: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:11462: \$? = $ac_status" >&5 + echo "$as_me:11821: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:11465: \"$ac_try\"") >&5 + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:11824: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11468: \$? = $ac_status" >&5 + echo "$as_me:11827: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_lib_X11_XOpenDisplay=yes + cf_cv_type_fd_set=sys/types.h else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_lib_X11_XOpenDisplay=no -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -echo "$as_me:11479: result: $ac_cv_lib_X11_XOpenDisplay" >&5 -echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6 -if test $ac_cv_lib_X11_XOpenDisplay = yes; then - LIBS="-lX11 $LIBS" -fi -fi +echo "${as_me:-configure}:11834: testing X11/Xpoll.h ..." 1>&5 - echo "$as_me:11487: checking for XtAppInitialize" >&5 -echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6 -if test "${ac_cv_func_XtAppInitialize+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 11493 "configure" +cat >conftest.$ac_ext <<_ACEOF +#line 11837 "configure" #include "confdefs.h" -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char XtAppInitialize (); below. */ -#include -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char XtAppInitialize (); -char (*f) (); +#ifdef HAVE_X11_XPOLL_H +#include +#endif int main () { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize) -choke me -#else -f = XtAppInitialize; -#endif - +fd_set x ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:11524: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:11852: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:11527: \$? = $ac_status" >&5 + echo "$as_me:11855: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:11530: \"$ac_try\"") >&5 + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:11858: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11533: \$? = $ac_status" >&5 + echo "$as_me:11861: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_func_XtAppInitialize=yes + cf_cv_type_fd_set=X11/Xpoll.h else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_func_XtAppInitialize=no -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -fi -echo "$as_me:11543: result: $ac_cv_func_XtAppInitialize" >&5 -echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6 -if test $ac_cv_func_XtAppInitialize = yes; then - : -else - echo "$as_me:11549: checking for XtAppInitialize in -lXt" >&5 -echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6 -if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" +echo "${as_me:-configure}:11868: testing sys/select.h ..." 1>&5 + cat >conftest.$ac_ext <<_ACEOF -#line 11557 "configure" +#line 11871 "configure" #include "confdefs.h" -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char XtAppInitialize (); +#include +#include int main () { -XtAppInitialize (); +fd_set x ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:11576: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:11885: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:11579: \$? = $ac_status" >&5 + echo "$as_me:11888: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:11582: \"$ac_try\"") >&5 + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:11891: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11585: \$? = $ac_status" >&5 + echo "$as_me:11894: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_lib_Xt_XtAppInitialize=yes + cf_cv_type_fd_set=sys/select.h else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_lib_Xt_XtAppInitialize=no +cf_cv_type_fd_set=unknown fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:11596: result: $ac_cv_lib_Xt_XtAppInitialize" >&5 -echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6 -if test $ac_cv_lib_Xt_XtAppInitialize = yes; then - cat >>confdefs.h <<\EOF -#define HAVE_LIBXT 1 +rm -f conftest.$ac_objext conftest.$ac_ext +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi +echo "$as_me:11908: result: $cf_cv_type_fd_set" >&5 +echo "${ECHO_T}$cf_cv_type_fd_set" >&6 +if test $cf_cv_type_fd_set = sys/select.h ; then + +cat >>confdefs.h <<\EOF +#define USE_SYS_SELECT_H 1 EOF - cf_have_X_LIBS=Xt - LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS" fi -fi +echo "$as_me:11918: checking for declaration of fd_mask" >&5 +echo $ECHO_N "checking for declaration of fd_mask... $ECHO_C" >&6 +if test "${cf_cv_type_fd_mask+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else -fi + if test x$cf_cv_type_fd_set = xX11/Xpoll.h ; then + cat >conftest.$ac_ext <<_ACEOF +#line 11926 "configure" +#include "confdefs.h" -if test $cf_have_X_LIBS = no ; then - { echo "$as_me:11612: WARNING: Unable to successfully link X Toolkit library (-lXt) with -test program. You will have to check and add the proper libraries by hand -to makefile." >&5 -echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with -test program. You will have to check and add the proper libraries by hand -to makefile." >&2;} -fi +#include +int +main () +{ +fd_mask x + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:11939: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:11942: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:11945: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:11948: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + : +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 -cf_x_athena_root=$cf_x_athena -cf_x_athena_inc="" +echo "${as_me:-configure}:11955: testing if we must define CSRG_BASED ..." 1>&5 -for cf_path in default \ - /usr/contrib/X11R6 \ - /usr/contrib/X11R5 \ - /usr/lib/X11R5 \ - /usr/local -do - if test -z "$cf_x_athena_inc" ; then - cf_save="$CPPFLAGS" - cf_test=X11/$cf_x_athena_root/SimpleMenu.h - if test $cf_path != default ; then - CPPFLAGS="$cf_save -I$cf_path/include" - echo "$as_me:11634: checking for $cf_test in $cf_path" >&5 -echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6 - else - echo "$as_me:11637: checking for $cf_test" >&5 -echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6 - fi - cat >conftest.$ac_ext <<_ACEOF -#line 11641 "configure" +# Xosdefs.h on Mac OS X may not define this (but it should). + cat >conftest.$ac_ext <<_ACEOF +#line 11959 "configure" #include "confdefs.h" -#include -#include <$cf_test> +#define CSRG_BASED +#include int main () { - +fd_mask x ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:11655: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:11973: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:11658: \$? = $ac_status" >&5 + echo "$as_me:11976: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:11661: \"$ac_try\"") >&5 + { (eval echo "$as_me:11979: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11664: \$? = $ac_status" >&5 + echo "$as_me:11982: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_result=yes + cf_cv_type_fd_mask=CSRG_BASED else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_result=no fi rm -f conftest.$ac_objext conftest.$ac_ext - echo "$as_me:11673: result: $cf_result" >&5 -echo "${ECHO_T}$cf_result" >&6 - if test "$cf_result" = yes ; then - cf_x_athena_inc=$cf_path - break - else - CPPFLAGS="$cf_save" - fi - fi -done +fi +rm -f conftest.$ac_objext conftest.$ac_ext + else + cf_cv_type_fd_mask=$cf_cv_type_fd_set + fi -if test -z "$cf_x_athena_inc" ; then - { echo "$as_me:11685: WARNING: Unable to successfully find Athena header files with test program" >&5 -echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;} -elif test "$cf_x_athena_inc" != default ; then - CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc" fi +echo "$as_me:11997: result: $cf_cv_type_fd_mask" >&5 +echo "${ECHO_T}$cf_cv_type_fd_mask" >&6 +if test x$cf_cv_type_fd_mask = xCSRG_BASED ; then -cf_x_athena_root=$cf_x_athena -cf_x_athena_lib="" +cat >>confdefs.h <<\EOF +#define CSRG_BASED 1 +EOF -for cf_path in default \ - /usr/contrib/X11R6 \ - /usr/contrib/X11R5 \ - /usr/lib/X11R5 \ - /usr/local -do - for cf_lib in \ - ${cf_x_athena_root} \ - ${cf_x_athena_root}7 \ - ${cf_x_athena_root}6 - do - for cf_libs in \ - "-l$cf_lib -lXmu" \ - "-l$cf_lib -lXpm -lXmu" \ - "-l${cf_lib}_s -lXmu_s" - do - if test -z "$cf_x_athena_lib" ; then - cf_save="$LIBS" - cf_test=XawSimpleMenuAddGlobalActions - if test $cf_path != default ; then - LIBS="-L$cf_path/lib $cf_libs $LIBS" - echo "$as_me:11715: checking for $cf_libs in $cf_path" >&5 -echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6 - else - LIBS="$cf_libs $LIBS" - echo "$as_me:11719: checking for $cf_test in $cf_libs" >&5 -echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6 - fi - cat >conftest.$ac_ext <<_ACEOF -#line 11723 "configure" -#include "confdefs.h" +fi -#include -#include +echo "$as_me:12007: checking for IRIX 6.5 baud-rate redefinitions" >&5 +echo $ECHO_N "checking for IRIX 6.5 baud-rate redefinitions... $ECHO_C" >&6 +if test "${cf_cv_termio_c_ispeed+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else +cat >conftest.$ac_ext <<_ACEOF +#line 12014 "configure" +#include "confdefs.h" + +#include +#include int main () { -$cf_test((XtAppContext) 0) +struct termio foo; +foo.c_ispeed = B38400; +foo.c_ospeed = B9600; + ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:11739: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:12032: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:11742: \$? = $ac_status" >&5 + echo "$as_me:12035: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:11745: \"$ac_try\"") >&5 + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:12038: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11748: \$? = $ac_status" >&5 + echo "$as_me:12041: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_result=yes + cf_cv_termio_c_ispeed=yes + else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_result=no +cf_cv_termio_c_ispeed=no fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext - echo "$as_me:11757: result: $cf_result" >&5 -echo "${ECHO_T}$cf_result" >&6 - if test "$cf_result" = yes ; then - cf_x_athena_lib="$cf_libs" - break - fi - LIBS="$cf_save" - fi - done # cf_libs - test -n "$cf_x_athena_lib" && break - done # cf_lib -done +rm -f conftest.$ac_objext conftest.$ac_ext -if test -z "$cf_x_athena_lib" ; then - { { echo "$as_me:11771: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5 -echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;} - { (exit 1); exit 1; }; } fi - -cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` - -cat >>confdefs.h <&5 +echo "${ECHO_T}$cf_cv_termio_c_ispeed" >&6 +test "$cf_cv_termio_c_ispeed" = yes && +cat >>confdefs.h <<\EOF +#define HAVE_TERMIO_C_ISPEED 1 EOF -fi +LIBS="$LIBS $X_EXTRA_LIBS" + +for ac_header in \ +stropts.h \ -for ac_header in X11/Xpoll.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:11787: checking for $ac_header" >&5 +echo "$as_me:12067: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 11793 "configure" +#line 12073 "configure" #include "confdefs.h" #include <$ac_header> _ACEOF -if { (eval echo "$as_me:11797: \"$ac_cpp conftest.$ac_ext\"") >&5 +if { (eval echo "$as_me:12077: \"$ac_cpp conftest.$ac_ext\"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? egrep -v '^ *\+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 - echo "$as_me:11803: \$? = $ac_status" >&5 + echo "$as_me:12083: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag @@ -11819,7 +12099,7 @@ fi rm -f conftest.err conftest.$ac_ext fi -echo "$as_me:11822: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "$as_me:12102: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <&5 -echo $ECHO_N "checking for declaration of fd_set... $ECHO_C" >&6 -if test "${cf_cv_type_fd_set+set}" = set; then +cf_func_grantpt="grantpt ptsname" +case $host_os in #(vi +darwin[0-9].*) #(vi + ;; +*) + cf_func_grantpt="$cf_func_grantpt posix_openpt" + ;; +esac + +for ac_func in $cf_func_grantpt +do +as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +echo "$as_me:12124: checking for $ac_func" >&5 +echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else + cat >conftest.$ac_ext <<_ACEOF +#line 12130 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func (); below. */ +#include +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func (); +char (*f) (); + +int +main () +{ +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:12161: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:12164: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:12167: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:12170: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + eval "$as_ac_var=yes" +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +eval "$as_ac_var=no" +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +fi +echo "$as_me:12180: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +if test `eval echo '${'$as_ac_var'}'` = yes; then + cat >>confdefs.h <&5 +fi +done + +cf_grantpt_opts= +if test "x$ac_cv_func_grantpt" = "xyes" ; then + echo "$as_me:12192: checking if grantpt really works" >&5 +echo $ECHO_N "checking if grantpt really works... $ECHO_C" >&6 + cat >conftest.$ac_ext <<_ACEOF +#line 12195 "configure" +#include "confdefs.h" + +#include +#include +#include +#include +#include +#include + +#ifndef HAVE_POSIX_OPENPT +#undef posix_openpt +#define posix_openpt(mode) open("/dev/ptmx", mode) +#endif + +#ifdef HAVE_STROPTS_H +#include +#endif + +static void failed(int code) +{ + perror("conftest"); + exit(code); +} + +static void my_timeout(int sig) +{ + exit(99); +} + +int +main () +{ + + int code = 0; + int rc; + int pty; + int tty; + char *slave; + struct termios tio; + + signal(SIGALRM, my_timeout); + + if (alarm(2) == 9) + failed(9); + else if ((pty = posix_openpt(O_RDWR)) < 0) + failed(1); + else if ((rc = grantpt(pty)) < 0) + failed(2); + else if ((rc = unlockpt(pty)) < 0) + failed(3); + else if ((slave = ptsname(pty)) == 0) + failed(4); +#if (CONFTEST == 3) || defined(CONFTEST_isatty) + else if (!isatty(pty)) + failed(4); +#endif +#if CONFTEST >= 4 + else if ((rc = tcgetattr(pty, &tio)) < 0) + failed(20); + else if ((rc = tcsetattr(pty, TCSAFLUSH, &tio)) < 0) + failed(21); +#endif + /* BSD posix_openpt does not treat pty as a terminal until slave is opened. + * Linux does treat it that way. + */ + else if ((tty = open(slave, O_RDWR)) < 0) + failed(5); +#ifdef CONFTEST +#ifdef I_PUSH +#if (CONFTEST == 0) || defined(CONFTEST_ptem) + else if ((rc = ioctl(tty, I_PUSH, "ptem")) < 0) + failed(10); +#endif +#if (CONFTEST == 1) || defined(CONFTEST_ldterm) + else if ((rc = ioctl(tty, I_PUSH, "ldterm")) < 0) + failed(11); +#endif +#if (CONFTEST == 2) || defined(CONFTEST_ttcompat) + else if ((rc = ioctl(tty, I_PUSH, "ttcompat")) < 0) + failed(12); +#endif +#endif /* I_PUSH */ +#if CONFTEST >= 5 + else if ((rc = tcgetattr(tty, &tio)) < 0) + failed(30); + else if ((rc = tcsetattr(tty, TCSAFLUSH, &tio)) < 0) + failed(31); +#endif +#endif /* CONFTEST */ -cat >conftest.$ac_ext <<_ACEOF -#line 11841 "configure" -#include "confdefs.h" + ${cf_cv_main_return:-return}(code); -#include -int -main () -{ -fd_set x ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:11854: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:12293: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:11857: \$? = $ac_status" >&5 + echo "$as_me:12296: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:11860: \"$ac_try\"") >&5 + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:12299: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11863: \$? = $ac_status" >&5 + echo "$as_me:12302: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_type_fd_set=sys/types.h + + if test "$cross_compiling" = yes; then + ac_cv_func_grantpt=maybe else - echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 + cat >conftest.$ac_ext <<_ACEOF +#line 12309 "configure" +#include "confdefs.h" -echo "${as_me:-configure}:11870: testing X11/Xpoll.h ..." 1>&5 +#include +#include +#include +#include +#include +#include -cat >conftest.$ac_ext <<_ACEOF -#line 11873 "configure" -#include "confdefs.h" +#ifndef HAVE_POSIX_OPENPT +#undef posix_openpt +#define posix_openpt(mode) open("/dev/ptmx", mode) +#endif -#ifdef HAVE_X11_XPOLL_H -#include +#ifdef HAVE_STROPTS_H +#include #endif -int -main () + +static void failed(int code) { -fd_set x - ; - return 0; + perror("conftest"); + exit(code); +} + +static void my_timeout(int sig) +{ + exit(99); +} + +int main(void) +{ + + int code = 0; + int rc; + int pty; + int tty; + char *slave; + struct termios tio; + + signal(SIGALRM, my_timeout); + + if (alarm(2) == 9) + failed(9); + else if ((pty = posix_openpt(O_RDWR)) < 0) + failed(1); + else if ((rc = grantpt(pty)) < 0) + failed(2); + else if ((rc = unlockpt(pty)) < 0) + failed(3); + else if ((slave = ptsname(pty)) == 0) + failed(4); +#if (CONFTEST == 3) || defined(CONFTEST_isatty) + else if (!isatty(pty)) + failed(4); +#endif +#if CONFTEST >= 4 + else if ((rc = tcgetattr(pty, &tio)) < 0) + failed(20); + else if ((rc = tcsetattr(pty, TCSAFLUSH, &tio)) < 0) + failed(21); +#endif + /* BSD posix_openpt does not treat pty as a terminal until slave is opened. + * Linux does treat it that way. + */ + else if ((tty = open(slave, O_RDWR)) < 0) + failed(5); +#ifdef CONFTEST +#ifdef I_PUSH +#if (CONFTEST == 0) || defined(CONFTEST_ptem) + else if ((rc = ioctl(tty, I_PUSH, "ptem")) < 0) + failed(10); +#endif +#if (CONFTEST == 1) || defined(CONFTEST_ldterm) + else if ((rc = ioctl(tty, I_PUSH, "ldterm")) < 0) + failed(11); +#endif +#if (CONFTEST == 2) || defined(CONFTEST_ttcompat) + else if ((rc = ioctl(tty, I_PUSH, "ttcompat")) < 0) + failed(12); +#endif +#endif /* I_PUSH */ +#if CONFTEST >= 5 + else if ((rc = tcgetattr(tty, &tio)) < 0) + failed(30); + else if ((rc = tcsetattr(tty, TCSAFLUSH, &tio)) < 0) + failed(31); +#endif +#endif /* CONFTEST */ + + ${cf_cv_main_return:-return}(code); + } + _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:11888: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest$ac_exeext +if { (eval echo "$as_me:12405: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:11891: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:11894: \"$ac_try\"") >&5 + echo "$as_me:12408: \$? = $ac_status" >&5 + (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:12410: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11897: \$? = $ac_status" >&5 + echo "$as_me:12413: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_type_fd_set=X11/Xpoll.h + : +else + echo "$as_me: program exited with status $ac_status" >&5 +echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_func_grantpt=no + +fi +rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +fi + else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 +ac_cv_func_grantpt=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext + echo "$as_me:12432: result: $ac_cv_func_grantpt" >&5 +echo "${ECHO_T}$ac_cv_func_grantpt" >&6 -echo "${as_me:-configure}:11904: testing sys/select.h ..." 1>&5 + if test "x$ac_cv_func_grantpt" != "xno" ; then -cat >conftest.$ac_ext <<_ACEOF -#line 11907 "configure" + if test "x$ac_cv_func_grantpt" = "xyes" ; then + echo "$as_me:12438: checking for pty features" >&5 +echo $ECHO_N "checking for pty features... $ECHO_C" >&6 + if test "x$ac_cv_header_stropts_h" = xyes + then + cf_pty_this=0 + else + cf_pty_this=3 + fi + + cf_pty_defines= + while test $cf_pty_this != 6 + do + + cf_pty_feature= + cf_pty_next=`expr $cf_pty_this + 1` + +echo "${as_me:-configure}:12454: testing pty feature test $cf_pty_next:5 ..." 1>&5 + + if test "$cross_compiling" = yes; then + { { echo "$as_me:12457: error: cannot run test program while cross compiling" >&5 +echo "$as_me: error: cannot run test program while cross compiling" >&2;} + { (exit 1); exit 1; }; } +else + cat >conftest.$ac_ext <<_ACEOF +#line 12462 "configure" #include "confdefs.h" +#define CONFTEST $cf_pty_this +$cf_pty_defines -#include -#include -int -main () +#include +#include +#include +#include +#include +#include + +#ifndef HAVE_POSIX_OPENPT +#undef posix_openpt +#define posix_openpt(mode) open("/dev/ptmx", mode) +#endif + +#ifdef HAVE_STROPTS_H +#include +#endif + +static void failed(int code) { -fd_set x - ; - return 0; + perror("conftest"); + exit(code); +} + +static void my_timeout(int sig) +{ + exit(99); +} + +int main(void) +{ + + int code = 0; + int rc; + int pty; + int tty; + char *slave; + struct termios tio; + + signal(SIGALRM, my_timeout); + + if (alarm(2) == 9) + failed(9); + else if ((pty = posix_openpt(O_RDWR)) < 0) + failed(1); + else if ((rc = grantpt(pty)) < 0) + failed(2); + else if ((rc = unlockpt(pty)) < 0) + failed(3); + else if ((slave = ptsname(pty)) == 0) + failed(4); +#if (CONFTEST == 3) || defined(CONFTEST_isatty) + else if (!isatty(pty)) + failed(4); +#endif +#if CONFTEST >= 4 + else if ((rc = tcgetattr(pty, &tio)) < 0) + failed(20); + else if ((rc = tcsetattr(pty, TCSAFLUSH, &tio)) < 0) + failed(21); +#endif + /* BSD posix_openpt does not treat pty as a terminal until slave is opened. + * Linux does treat it that way. + */ + else if ((tty = open(slave, O_RDWR)) < 0) + failed(5); +#ifdef CONFTEST +#ifdef I_PUSH +#if (CONFTEST == 0) || defined(CONFTEST_ptem) + else if ((rc = ioctl(tty, I_PUSH, "ptem")) < 0) + failed(10); +#endif +#if (CONFTEST == 1) || defined(CONFTEST_ldterm) + else if ((rc = ioctl(tty, I_PUSH, "ldterm")) < 0) + failed(11); +#endif +#if (CONFTEST == 2) || defined(CONFTEST_ttcompat) + else if ((rc = ioctl(tty, I_PUSH, "ttcompat")) < 0) + failed(12); +#endif +#endif /* I_PUSH */ +#if CONFTEST >= 5 + else if ((rc = tcgetattr(tty, &tio)) < 0) + failed(30); + else if ((rc = tcsetattr(tty, TCSAFLUSH, &tio)) < 0) + failed(31); +#endif +#endif /* CONFTEST */ + + ${cf_cv_main_return:-return}(code); + } + _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:11921: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest$ac_exeext +if { (eval echo "$as_me:12560: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:11924: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:11927: \"$ac_try\"") >&5 + echo "$as_me:12563: \$? = $ac_status" >&5 + (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:12565: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11930: \$? = $ac_status" >&5 + echo "$as_me:12568: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_type_fd_set=sys/select.h + + case $cf_pty_next in #(vi + 1) #(vi - streams + cf_pty_feature=ptem + ;; + 2) #(vi - streams + cf_pty_feature=ldterm + ;; + 3) #(vi - streams + cf_pty_feature=ttcompat + ;; + 4) #(vi + cf_pty_feature=pty_isatty + ;; + 5) #(vi + cf_pty_feature=pty_tcsetattr + ;; + 6) #(vi + cf_pty_feature=tty_tcsetattr + ;; + esac + else - echo "$as_me: failed program was:" >&5 + echo "$as_me: program exited with status $ac_status" >&5 +echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_type_fd_set=unknown -fi -rm -f conftest.$ac_objext conftest.$ac_ext -fi -rm -f conftest.$ac_objext conftest.$ac_ext + + case $cf_pty_next in #(vi + 1|2|3) + +echo "${as_me:-configure}:12600: testing skipping remaining streams features $cf_pty_this..2 ..." 1>&5 + + cf_pty_next=3 + ;; + esac + fi -rm -f conftest.$ac_objext conftest.$ac_ext +rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:11944: result: $cf_cv_type_fd_set" >&5 -echo "${ECHO_T}$cf_cv_type_fd_set" >&6 -if test $cf_cv_type_fd_set = sys/select.h ; then - cat >>confdefs.h <<\EOF -#define USE_SYS_SELECT_H 1 -EOF + if test -n "$cf_pty_feature" + then + cf_pty_defines="$cf_pty_defines +#define CONFTEST_$cf_pty_feature 1 +" + cf_grantpt_opts="$cf_grantpt_opts $cf_pty_feature" + fi + cf_pty_this=$cf_pty_next + done + echo "$as_me:12619: result: $cf_grantpt_opts" >&5 +echo "${ECHO_T}$cf_grantpt_opts" >&6 + cf_grantpt_opts=`echo "$cf_grantpt_opts" | sed -e 's/ isatty//'` + fi + fi fi -echo "$as_me:11953: checking for declaration of fd_mask" >&5 -echo $ECHO_N "checking for declaration of fd_mask... $ECHO_C" >&6 -if test "${cf_cv_type_fd_mask+set}" = set; then +if test "x$disable_openpty" != "xyes" || test -z "$cf_grantpt_opts" ; then + echo "$as_me:12627: checking for openpty in -lutil" >&5 +echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6 +if test "${ac_cv_lib_util_openpty+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - - if test x$cf_cv_type_fd_set = xX11/Xpoll.h ; then - cat >conftest.$ac_ext <<_ACEOF -#line 11961 "configure" + ac_check_lib_save_LIBS=$LIBS +LIBS="-lutil $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line 12635 "configure" #include "confdefs.h" -#include +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char openpty (); int main () { -fd_mask x +openpty (); ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:11974: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:12654: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:11977: \$? = $ac_status" >&5 + echo "$as_me:12657: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:11980: \"$ac_try\"") >&5 + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:12660: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:11983: \$? = $ac_status" >&5 + echo "$as_me:12663: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - : + ac_cv_lib_util_openpty=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 +ac_cv_lib_util_openpty=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:12674: result: $ac_cv_lib_util_openpty" >&5 +echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6 +if test $ac_cv_lib_util_openpty = yes; then + cf_have_openpty=yes +else + cf_have_openpty=no +fi -echo "${as_me:-configure}:11990: testing if we must define CSRG_BASED ..." 1>&5 + if test "$cf_have_openpty" = yes ; then + ac_cv_func_grantpt=no + LIBS="-lutil $LIBS" -# Xosdefs.h on Mac OS X may not define this (but it should). - cat >conftest.$ac_ext <<_ACEOF -#line 11994 "configure" -#include "confdefs.h" +cat >>confdefs.h <<\EOF +#define HAVE_OPENPTY 1 +EOF -#define CSRG_BASED -#include -int -main () -{ -fd_mask x - ; - return 0; -} +for ac_header in \ + util.h \ + libutil.h \ + pty.h \ + +do +as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +echo "$as_me:12697: checking for $ac_header" >&5 +echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 12703 "configure" +#include "confdefs.h" +#include <$ac_header> _ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:12008: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - echo "$as_me:12011: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:12014: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 +if { (eval echo "$as_me:12707: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? - echo "$as_me:12017: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - cf_cv_type_fd_mask=CSRG_BASED + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:12713: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 -cat conftest.$ac_ext >&5 + cat conftest.$ac_ext >&5 + eval "$as_ac_Header=no" fi -rm -f conftest.$ac_objext conftest.$ac_ext +rm -f conftest.err conftest.$ac_ext fi -rm -f conftest.$ac_objext conftest.$ac_ext - else - cf_cv_type_fd_mask=$cf_cv_type_fd_set - fi +echo "$as_me:12732: result: `eval echo '${'$as_ac_Header'}'`" >&5 +echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +if test `eval echo '${'$as_ac_Header'}'` = yes; then + cat >>confdefs.h <&5 -echo "${ECHO_T}$cf_cv_type_fd_mask" >&6 -if test x$cf_cv_type_fd_mask = xCSRG_BASED ; then - cat >>confdefs.h <<\EOF -#define CSRG_BASED 1 +done + + fi +fi + +if test "x$ac_cv_func_grantpt" != xno +then + test -n "$verbose" && echo " will rely upon grantpt" 1>&6 + +echo "${as_me:-configure}:12749: testing will rely upon grantpt ..." 1>&5 + +cat >>confdefs.h <<\EOF +#define HAVE_WORKING_GRANTPT 1 +EOF + + for cf_feature in $cf_grantpt_opts + do + cf_feature=`echo "$cf_feature" | sed -e 's/ //g'` + +cf_FEATURE=`echo "$cf_feature" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` + + cat >>confdefs.h <&6 + +echo "${as_me:-configure}:12770: testing will rely upon BSD-pseudoterminals ..." 1>&5 + +else + test -n "$verbose" && echo " will rely upon openpty" 1>&6 + +echo "${as_me:-configure}:12775: testing will rely upon openpty ..." 1>&5 + fi -echo "$as_me:12041: checking for IRIX 6.5 baud-rate redefinitions" >&5 -echo $ECHO_N "checking for IRIX 6.5 baud-rate redefinitions... $ECHO_C" >&6 -if test "${cf_cv_termio_c_ispeed+set}" = set; then +echo "$as_me:12779: checking if we can use XkbQueryExtension" >&5 +echo $ECHO_N "checking if we can use XkbQueryExtension... $ECHO_C" >&6 +if test "${cf_cv_xkb_query_extension+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 12048 "configure" +#line 12786 "configure" #include "confdefs.h" -#include -#include +#include +#include +#include + int main () { -struct termio foo; -foo.c_ispeed = B38400; -foo.c_ospeed = B9600; + int xkbmajor = XkbMajorVersion; + int xkbminor = XkbMinorVersion; + int xkbopcode, xkbevent, xkberror; + + if (XkbLibraryVersion(&xkbmajor, &xkbminor) + && XkbQueryExtension((Display *)0, + &xkbopcode, + &xkbevent, + &xkberror, + &xkbmajor, + &xkbminor)) + return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:12066: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:12815: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:12069: \$? = $ac_status" >&5 + echo "$as_me:12818: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:12072: \"$ac_try\"") >&5 + { (eval echo "$as_me:12821: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:12075: \$? = $ac_status" >&5 + echo "$as_me:12824: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - cf_cv_termio_c_ispeed=yes + +cf_cv_xkb_query_extension=yes else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -cf_cv_termio_c_ispeed=no + +cf_cv_xkb_query_extension=no + fi rm -f conftest.$ac_objext conftest.$ac_ext fi -echo "$as_me:12087: result: $cf_cv_termio_c_ispeed" >&5 -echo "${ECHO_T}$cf_cv_termio_c_ispeed" >&6 -test "$cf_cv_termio_c_ispeed" = yes && cat >>confdefs.h <<\EOF -#define HAVE_TERMIO_C_ISPEED 1 -EOF - -LIBS="$LIBS $X_EXTRA_LIBS" +echo "$as_me:12839: result: $cf_cv_xkb_query_extension" >&5 +echo "${ECHO_T}$cf_cv_xkb_query_extension" >&6 -cf_func_grantpt="grantpt ptsname" -case $host_os in #(vi -darwin[0-9].*) #(vi - ;; -*) - cf_func_grantpt="$cf_func_grantpt posix_openpt" - ;; -esac +if test $cf_cv_xkb_query_extension = yes +then -for ac_func in $cf_func_grantpt +for ac_func in XkbQueryExtension do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -echo "$as_me:12107: checking for $ac_func" >&5 +echo "$as_me:12848: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 12113 "configure" +#line 12854 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. */ @@ -12133,7 +12874,7 @@ #if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -f = $ac_func; +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -12141,16 +12882,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:12144: \"$ac_link\"") >&5 +if { (eval echo "$as_me:12885: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:12147: \$? = $ac_status" >&5 + echo "$as_me:12888: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:12150: \"$ac_try\"") >&5 + { (eval echo "$as_me:12891: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:12153: \$? = $ac_status" >&5 + echo "$as_me:12894: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_var=yes" else @@ -12160,7 +12901,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:12163: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "$as_me:12904: result: `eval echo '${'$as_ac_var'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <&5 -echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6 -if test "${ac_cv_lib_util_openpty+set}" = set; then +fi + +echo "$as_me:12916: checking if we can use XkbKeycodeToKeysym" >&5 +echo $ECHO_N "checking if we can use XkbKeycodeToKeysym... $ECHO_C" >&6 +if test "${cf_cv_xkb_keycode_to_keysym+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lutil $LIBS" + cat >conftest.$ac_ext <<_ACEOF -#line 12182 "configure" +#line 12923 "configure" #include "confdefs.h" -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char openpty (); +#include +#include + int main () { -openpty (); + + KeySym keysym = XkbKeycodeToKeysym((Display *)0, 0, 0, 0); + ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:12201: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 +rm -f conftest.$ac_objext +if { (eval echo "$as_me:12940: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:12204: \$? = $ac_status" >&5 + echo "$as_me:12943: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:12207: \"$ac_try\"") >&5 + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:12946: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:12210: \$? = $ac_status" >&5 + echo "$as_me:12949: \$? = $ac_status" >&5 (exit $ac_status); }; }; then - ac_cv_lib_util_openpty=yes + +cf_cv_xkb_keycode_to_keysym=yes + else echo "$as_me: failed program was:" >&5 cat conftest.$ac_ext >&5 -ac_cv_lib_util_openpty=no -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -echo "$as_me:12221: result: $ac_cv_lib_util_openpty" >&5 -echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6 -if test $ac_cv_lib_util_openpty = yes; then - cf_have_openpty=yes -else - cf_have_openpty=no -fi - - if test "$cf_have_openpty" = yes ; then - LIBS="-lutil $LIBS" - cat >>confdefs.h <<\EOF -#define HAVE_OPENPTY 1 -EOF -for ac_header in \ - util.h \ - libutil.h \ - pty.h \ +cf_cv_xkb_keycode_to_keysym=no -do -as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` -echo "$as_me:12242: checking for $ac_header" >&5 -echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 -if eval "test \"\${$as_ac_Header+set}\" = set"; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - cat >conftest.$ac_ext <<_ACEOF -#line 12248 "configure" -#include "confdefs.h" -#include <$ac_header> -_ACEOF -if { (eval echo "$as_me:12252: \"$ac_cpp conftest.$ac_ext\"") >&5 - (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 - ac_status=$? - egrep -v '^ *\+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:12258: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null; then - if test -s conftest.err; then - ac_cpp_err=$ac_c_preproc_warn_flag - else - ac_cpp_err= - fi -else - ac_cpp_err=yes -fi -if test -z "$ac_cpp_err"; then - eval "$as_ac_Header=yes" -else - echo "$as_me: failed program was:" >&5 - cat conftest.$ac_ext >&5 - eval "$as_ac_Header=no" fi -rm -f conftest.err conftest.$ac_ext -fi -echo "$as_me:12277: result: `eval echo '${'$as_ac_Header'}'`" >&5 -echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 -if test `eval echo '${'$as_ac_Header'}'` = yes; then - cat >>confdefs.h <&5 +echo "${ECHO_T}$cf_cv_xkb_keycode_to_keysym" >&6 - fi -fi +if test $cf_cv_xkb_keycode_to_keysym = yes +then -for ac_func in XkbQueryExtension +for ac_func in XkbKeycodeToKeysym do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -echo "$as_me:12293: checking for $ac_func" >&5 +echo "$as_me:12973: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 12299 "configure" +#line 12979 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. */ @@ -12319,7 +12999,7 @@ #if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -f = $ac_func; +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -12327,16 +13007,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:12330: \"$ac_link\"") >&5 +if { (eval echo "$as_me:13010: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:12333: \$? = $ac_status" >&5 + echo "$as_me:13013: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:12336: \"$ac_try\"") >&5 + { (eval echo "$as_me:13016: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:12339: \$? = $ac_status" >&5 + echo "$as_me:13019: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_var=yes" else @@ -12346,7 +13026,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:12349: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "$as_me:13029: result: `eval echo '${'$as_ac_var'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <&5 +fi + +echo "$as_me:13041: checking for XKB Bell extension" >&5 echo $ECHO_N "checking for XKB Bell extension... $ECHO_C" >&6 if test "${cf_cv_xkb_bell_ext+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 12366 "configure" +#line 13048 "configure" #include "confdefs.h" #include @@ -12383,16 +13065,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:12386: \"$ac_link\"") >&5 +if { (eval echo "$as_me:13068: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:12389: \$? = $ac_status" >&5 + echo "$as_me:13071: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:12392: \"$ac_try\"") >&5 + { (eval echo "$as_me:13074: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:12395: \$? = $ac_status" >&5 + echo "$as_me:13077: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xkb_bell_ext=yes else @@ -12403,22 +13085,23 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:12406: result: $cf_cv_xkb_bell_ext" >&5 +echo "$as_me:13088: result: $cf_cv_xkb_bell_ext" >&5 echo "${ECHO_T}$cf_cv_xkb_bell_ext" >&6 -test "$cf_cv_xkb_bell_ext" = yes && cat >>confdefs.h <<\EOF +test "$cf_cv_xkb_bell_ext" = yes && +cat >>confdefs.h <<\EOF #define HAVE_XKB_BELL_EXT 1 EOF for ac_func in Xutf8LookupString do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -echo "$as_me:12415: checking for $ac_func" >&5 +echo "$as_me:13098: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 12421 "configure" +#line 13104 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. */ @@ -12441,7 +13124,7 @@ #if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -f = $ac_func; +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -12449,16 +13132,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:12452: \"$ac_link\"") >&5 +if { (eval echo "$as_me:13135: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:12455: \$? = $ac_status" >&5 + echo "$as_me:13138: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:12458: \"$ac_try\"") >&5 + { (eval echo "$as_me:13141: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:12461: \$? = $ac_status" >&5 + echo "$as_me:13144: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_var=yes" else @@ -12468,7 +13151,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:12471: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "$as_me:13154: result: `eval echo '${'$as_ac_var'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <&5 +echo "$as_me:13170: checking if you want narrow prototypes for X libraries" >&5 echo $ECHO_N "checking if you want narrow prototypes for X libraries... $ECHO_C" >&6 case `$ac_config_guess` in #(vi @@ -12510,10 +13193,10 @@ enable_narrowproto=$cf_default_narrowproto fi; -echo "$as_me:12513: result: $enable_narrowproto" >&5 +echo "$as_me:13196: result: $enable_narrowproto" >&5 echo "${ECHO_T}$enable_narrowproto" >&6 -echo "$as_me:12516: checking if we should use imake to help" >&5 +echo "$as_me:13199: checking if we should use imake to help" >&5 echo $ECHO_N "checking if we should use imake to help... $ECHO_C" >&6 # Check whether --enable-imake or --disable-imake was given. @@ -12530,7 +13213,7 @@ enable_imake=yes fi; -echo "$as_me:12533: result: $enable_imake" >&5 +echo "$as_me:13216: result: $enable_imake" >&5 echo "${ECHO_T}$enable_imake" >&6 if test "$enable_imake" = yes ; then @@ -12539,7 +13222,7 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:12542: checking for $ac_word" >&5 +echo "$as_me:13225: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_path_IMAKE+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -12556,7 +13239,7 @@ test -z "$ac_dir" && ac_dir=. if $as_executable_p "$ac_dir/$ac_word"; then ac_cv_path_IMAKE="$ac_dir/$ac_word" - echo "$as_me:12559: found $ac_dir/$ac_word" >&5 + echo "$as_me:13242: found $ac_dir/$ac_word" >&5 break fi done @@ -12567,10 +13250,10 @@ IMAKE=$ac_cv_path_IMAKE if test -n "$IMAKE"; then - echo "$as_me:12570: result: $IMAKE" >&5 + echo "$as_me:13253: result: $IMAKE" >&5 echo "${ECHO_T}$IMAKE" >&6 else - echo "$as_me:12573: result: no" >&5 + echo "$as_me:13256: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -12630,7 +13313,7 @@ then test -n "$verbose" && echo " Using $IMAKE $cf_imake_opts" 1>&6 -echo "${as_me:-configure}:12633: testing Using $IMAKE $cf_imake_opts ..." 1>&5 +echo "${as_me:-configure}:13316: testing Using $IMAKE $cf_imake_opts ..." 1>&5 else # sometimes imake doesn't have the config path compiled in. Find it. @@ -12648,7 +13331,7 @@ esac done if test -z "$cf_config" ; then - { echo "$as_me:12651: WARNING: Could not find imake config-directory" >&5 + { echo "$as_me:13334: WARNING: Could not find imake config-directory" >&5 echo "$as_me: WARNING: Could not find imake config-directory" >&2;} else cf_imake_opts="$cf_imake_opts -I$cf_config" @@ -12656,10 +13339,10 @@ then test -n "$verbose" && echo " Using $IMAKE $cf_config" 1>&6 -echo "${as_me:-configure}:12659: testing Using $IMAKE $cf_config ..." 1>&5 +echo "${as_me:-configure}:13342: testing Using $IMAKE $cf_config ..." 1>&5 else - { echo "$as_me:12662: WARNING: Cannot run $IMAKE" >&5 + { echo "$as_me:13345: WARNING: Cannot run $IMAKE" >&5 echo "$as_me: WARNING: Cannot run $IMAKE" >&2;} fi fi @@ -12703,7 +13386,7 @@ else test -n "$verbose" && echo " suppressed \"$cf_nostdinc\" and \"$cf_std_incl\"" 1>&6 -echo "${as_me:-configure}:12706: testing suppressed \"$cf_nostdinc\" and \"$cf_std_incl\" ..." 1>&5 +echo "${as_me:-configure}:13389: testing suppressed \"$cf_nostdinc\" and \"$cf_std_incl\" ..." 1>&5 IMAKE_CFLAGS="$cf_cpp_opts" fi @@ -12725,11 +13408,11 @@ test -n "$verbose" && echo " IMAKE_CFLAGS $IMAKE_CFLAGS" 1>&6 -echo "${as_me:-configure}:12728: testing IMAKE_CFLAGS $IMAKE_CFLAGS ..." 1>&5 +echo "${as_me:-configure}:13411: testing IMAKE_CFLAGS $IMAKE_CFLAGS ..." 1>&5 test -n "$verbose" && echo " IMAKE_LOADFLAGS $IMAKE_LOADFLAGS" 1>&6 -echo "${as_me:-configure}:12732: testing IMAKE_LOADFLAGS $IMAKE_LOADFLAGS ..." 1>&5 +echo "${as_me:-configure}:13415: testing IMAKE_LOADFLAGS $IMAKE_LOADFLAGS ..." 1>&5 fi @@ -12818,7 +13501,7 @@ IMAKE_LOADFLAGS= test -n "$verbose" && echo " make fallback definitions" 1>&6 -echo "${as_me:-configure}:12821: testing make fallback definitions ..." 1>&5 +echo "${as_me:-configure}:13504: testing make fallback definitions ..." 1>&5 # We prefer config.guess' values when we can get them, to avoid # inconsistent results with uname (AIX for instance). However, @@ -12950,67 +13633,259 @@ case "$IMAKE_CFLAGS" in *-DUSE_TERMINFO\ -DHAVE_TIGETSTR*) - test -n "$verbose" && echo " removing terminfo flags from IMAKE_CFLAGS" 1>&6 + test -n "$verbose" && echo " removing terminfo flags from IMAKE_CFLAGS" 1>&6 + +echo "${as_me:-configure}:13638: testing removing terminfo flags from IMAKE_CFLAGS ..." 1>&5 + + IMAKE_CFLAGS=`echo "$IMAKE_CFLAGS" | sed -e 's/-DUSE_TERMINFO[ ]*-DHAVE_TIGETSTR[ ]*//'` + test -n "$verbose" && echo " ...result $IMAKE_CFLAGS" 1>&6 + +echo "${as_me:-configure}:13643: testing ...result $IMAKE_CFLAGS ..." 1>&5 + + test -n "$verbose" && echo " removing terminfo flags from CPPFLAGS" 1>&6 + +echo "${as_me:-configure}:13647: testing removing terminfo flags from CPPFLAGS ..." 1>&5 + + CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/-DUSE_TERMINFO[ ]*-DHAVE_TIGETSTR[ ]*//'` + test -n "$verbose" && echo " ...result $CPPFLAGS" 1>&6 + +echo "${as_me:-configure}:13652: testing ...result $CPPFLAGS ..." 1>&5 + + ;; + esac +fi + +echo "$as_me:13658: checking for default terminal-id" >&5 +echo $ECHO_N "checking for default terminal-id... $ECHO_C" >&6 + +# Check whether --with-terminal-id or --without-terminal-id was given. +if test "${with_terminal_id+set}" = set; then + withval="$with_terminal_id" + default_termid=$withval +else + default_termid=vt420 +fi; +echo "$as_me:13668: result: $default_termid" >&5 +echo "${ECHO_T}$default_termid" >&6 +case $default_termid in +vt*) default_termid=`echo $default_termid | sed -e 's/^..//'` + ;; +esac + +cat >>confdefs.h <&5 +echo $ECHO_N "checking for default terminal-type... $ECHO_C" >&6 + +# Check whether --with-terminal-type or --without-terminal-type was given. +if test "${with_terminal_type+set}" = set; then + withval="$with_terminal_type" + default_TERM=$withval +else + default_TERM=xterm +fi; +echo "$as_me:13689: result: $default_TERM" >&5 +echo "${ECHO_T}$default_TERM" >&6 + +cat >>confdefs.h <&5 +echo $ECHO_N "checking if backarrow-key should be BS... $ECHO_C" >&6 + +# Check whether --enable-backarrow-key or --disable-backarrow-key was given. +if test "${enable_backarrow_key+set}" = set; then + enableval="$enable_backarrow_key" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + backarrow_is_bs=$enableval + else + backarrow_is_bs=yes + fi +else + enableval=yes + backarrow_is_bs=yes + +fi; + +echo "$as_me:13715: result: $backarrow_is_bs" >&5 +echo "${ECHO_T}$backarrow_is_bs" >&6 +case $backarrow_is_bs in #(vi +yes) #(vi + backarrow_is_bs=true + ;; +no) #(vi + backarrow_is_bs=false + ;; +esac +cf_xbool1=`echo "$backarrow_is_bs"|sed -e 's/^\(.\).*/\1/'` + +cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` + +cf_xbool2=`echo "$backarrow_is_bs"|sed -e 's/^.//'` +backarrow_is_bs=${cf_xbool1}${cf_xbool2} + +cat >>confdefs.h <&5 +echo $ECHO_N "checking if backarrow-key should be treated as erase... $ECHO_C" >&6 + +# Check whether --enable-backarrow-is-erase or --disable-backarrow-is-erase was given. +if test "${enable_backarrow_is_erase+set}" = set; then + enableval="$enable_backarrow_is_erase" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + backarrow_is_erase=$enableval + else + backarrow_is_erase=no + fi +else + enableval=no + backarrow_is_erase=no + +fi; + +echo "$as_me:13754: result: $backarrow_is_erase" >&5 +echo "${ECHO_T}$backarrow_is_erase" >&6 +case $backarrow_is_erase in #(vi +yes) #(vi + backarrow_is_erase=true + ;; +no) #(vi + backarrow_is_erase=false + ;; +esac +cf_xbool1=`echo "$backarrow_is_erase"|sed -e 's/^\(.\).*/\1/'` + +cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` -echo "${as_me:-configure}:12955: testing removing terminfo flags from IMAKE_CFLAGS ..." 1>&5 +cf_xbool2=`echo "$backarrow_is_erase"|sed -e 's/^.//'` +backarrow_is_erase=${cf_xbool1}${cf_xbool2} - IMAKE_CFLAGS=`echo "$IMAKE_CFLAGS" | sed -e 's/-DUSE_TERMINFO[ ]*-DHAVE_TIGETSTR[ ]*//'` - test -n "$verbose" && echo " ...result $IMAKE_CFLAGS" 1>&6 +cat >>confdefs.h <&5 +echo "$as_me:13775: checking for default backspace/DEL setting" >&5 +echo $ECHO_N "checking for default backspace/DEL setting... $ECHO_C" >&6 - test -n "$verbose" && echo " removing terminfo flags from CPPFLAGS" 1>&6 +# Check whether --enable-delete-is-del or --disable-delete-is-del was given. +if test "${enable_delete_is_del+set}" = set; then + enableval="$enable_delete_is_del" + delete_is_del=$enableval +else + delete_is_del=maybe +fi; -echo "${as_me:-configure}:12964: testing removing terminfo flags from CPPFLAGS ..." 1>&5 +echo "$as_me:13786: result: $delete_is_del" >&5 +echo "${ECHO_T}$delete_is_del" >&6 +case $delete_is_del in #(vi +yes) #(vi + delete_is_del=true + ;; +no) #(vi + delete_is_del=false + ;; +esac +cf_xbool1=`echo "$delete_is_del"|sed -e 's/^\(.\).*/\1/'` - CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/-DUSE_TERMINFO[ ]*-DHAVE_TIGETSTR[ ]*//'` - test -n "$verbose" && echo " ...result $CPPFLAGS" 1>&6 +cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` -echo "${as_me:-configure}:12969: testing ...result $CPPFLAGS ..." 1>&5 +cf_xbool2=`echo "$delete_is_del"|sed -e 's/^.//'` +delete_is_del=${cf_xbool1}${cf_xbool2} - ;; - esac -fi +cat >>confdefs.h <&5 -echo $ECHO_N "checking for default terminal-id... $ECHO_C" >&6 +echo "$as_me:13807: checking if alt should send ESC" >&5 +echo $ECHO_N "checking if alt should send ESC... $ECHO_C" >&6 -# Check whether --with-terminal-id or --without-terminal-id was given. -if test "${with_terminal_id+set}" = set; then - withval="$with_terminal_id" - default_termid=$withval +# Check whether --enable-alt-sends-esc or --disable-alt-sends-esc was given. +if test "${enable_alt_sends_esc+set}" = set; then + enableval="$enable_alt_sends_esc" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + alt_sends_esc=$enableval + else + alt_sends_esc=no + fi else - default_termid=vt100 + enableval=no + alt_sends_esc=no + fi; -echo "$as_me:12985: result: $default_termid" >&5 -echo "${ECHO_T}$default_termid" >&6 -case $default_termid in -vt*) default_termid=`echo $default_termid | sed -e 's/^..//'` + +echo "$as_me:13825: result: $alt_sends_esc" >&5 +echo "${ECHO_T}$alt_sends_esc" >&6 +case $alt_sends_esc in #(vi +yes) #(vi + alt_sends_esc=true + ;; +no) #(vi + alt_sends_esc=false ;; esac +cf_xbool1=`echo "$alt_sends_esc"|sed -e 's/^\(.\).*/\1/'` + +cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` + +cf_xbool2=`echo "$alt_sends_esc"|sed -e 's/^.//'` +alt_sends_esc=${cf_xbool1}${cf_xbool2} + cat >>confdefs.h <&5 -echo $ECHO_N "checking for default terminal-type... $ECHO_C" >&6 +echo "$as_me:13846: checking if meta should send ESC" >&5 +echo $ECHO_N "checking if meta should send ESC... $ECHO_C" >&6 -# Check whether --with-terminal-type or --without-terminal-type was given. -if test "${with_terminal_type+set}" = set; then - withval="$with_terminal_type" - default_TERM=$withval +# Check whether --enable-meta-sends-esc or --disable-meta-sends-esc was given. +if test "${enable_meta_sends_esc+set}" = set; then + enableval="$enable_meta_sends_esc" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + meta_sends_esc=$enableval + else + meta_sends_esc=no + fi else - default_TERM=xterm + enableval=no + meta_sends_esc=no + fi; -echo "$as_me:13005: result: $default_TERM" >&5 -echo "${ECHO_T}$default_TERM" >&6 + +echo "$as_me:13864: result: $meta_sends_esc" >&5 +echo "${ECHO_T}$meta_sends_esc" >&6 +case $meta_sends_esc in #(vi +yes) #(vi + meta_sends_esc=true + ;; +no) #(vi + meta_sends_esc=false + ;; +esac +cf_xbool1=`echo "$meta_sends_esc"|sed -e 's/^\(.\).*/\1/'` + +cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` + +cf_xbool2=`echo "$meta_sends_esc"|sed -e 's/^.//'` +meta_sends_esc=${cf_xbool1}${cf_xbool2} + cat >>confdefs.h <&5 +echo "$as_me:13888: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_cf_tic_prog+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -13025,7 +13900,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_cf_tic_prog="yes" -echo "$as_me:13028: found $ac_dir/$ac_word" >&5 +echo "$as_me:13903: found $ac_dir/$ac_word" >&5 break done @@ -13034,15 +13909,15 @@ fi cf_tic_prog=$ac_cv_prog_cf_tic_prog if test -n "$cf_tic_prog"; then - echo "$as_me:13037: result: $cf_tic_prog" >&5 + echo "$as_me:13912: result: $cf_tic_prog" >&5 echo "${ECHO_T}$cf_tic_prog" >&6 else - echo "$as_me:13040: result: no" >&5 + echo "$as_me:13915: result: no" >&5 echo "${ECHO_T}no" >&6 fi if test "$cf_tic_prog" = yes ; then - echo "$as_me:13045: checking for private terminfo-directory" >&5 + echo "$as_me:13920: checking for private terminfo-directory" >&5 echo $ECHO_N "checking for private terminfo-directory... $ECHO_C" >&6 # Check whether --with-own-terminfo or --without-own-terminfo was given. @@ -13052,19 +13927,20 @@ else TERMINFO_DIR=${TERMINFO-none} fi; - echo "$as_me:13055: result: $TERMINFO_DIR" >&5 + echo "$as_me:13930: result: $TERMINFO_DIR" >&5 echo "${ECHO_T}$TERMINFO_DIR" >&6 if test "$TERMINFO_DIR" = yes ; then - { echo "$as_me:13058: WARNING: no value given" >&5 + { echo "$as_me:13933: WARNING: no value given" >&5 echo "$as_me: WARNING: no value given" >&2;} elif test "$TERMINFO_DIR" != none ; then if test -d $TERMINFO_DIR ; then - cat >>confdefs.h <>confdefs.h <&5 + { echo "$as_me:13943: WARNING: not a directory" >&5 echo "$as_me: WARNING: not a directory" >&2;} fi elif test "$prefix" != NONE ; then @@ -13088,7 +13964,7 @@ ############################################################################### -echo "$as_me:13091: checking if you want active-icons" >&5 +echo "$as_me:13967: checking if you want active-icons" >&5 echo $ECHO_N "checking if you want active-icons... $ECHO_C" >&6 # Check whether --enable-active-icon or --disable-active-icon was given. @@ -13105,16 +13981,17 @@ enable_active_icon=yes fi; -echo "$as_me:13108: result: $enable_active_icon" >&5 +echo "$as_me:13984: result: $enable_active_icon" >&5 echo "${ECHO_T}$enable_active_icon" >&6 if test "$enable_active_icon" = no ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define NO_ACTIVE_ICON 1 EOF fi -echo "$as_me:13117: checking if you want ANSI color" >&5 +echo "$as_me:13994: checking if you want ANSI color" >&5 echo $ECHO_N "checking if you want ANSI color... $ECHO_C" >&6 # Check whether --enable-ansi-color or --disable-ansi-color was given. @@ -13131,15 +14008,16 @@ enable_ansi_color=yes fi; -echo "$as_me:13134: result: $enable_ansi_color" >&5 +echo "$as_me:14011: result: $enable_ansi_color" >&5 echo "${ECHO_T}$enable_ansi_color" >&6 -test "$enable_ansi_color" = no && cat >>confdefs.h <<\EOF +test "$enable_ansi_color" = no && +cat >>confdefs.h <<\EOF #define OPT_ISO_COLORS 0 EOF if test "$enable_ansi_color" = yes ; then - echo "$as_me:13142: checking if you want 16 colors like aixterm" >&5 + echo "$as_me:14020: checking if you want 16 colors like aixterm" >&5 echo $ECHO_N "checking if you want 16 colors like aixterm... $ECHO_C" >&6 # Check whether --enable-16-color or --disable-16-color was given. @@ -13156,13 +14034,14 @@ enable_16_color=yes fi; - echo "$as_me:13159: result: $enable_16_color" >&5 + echo "$as_me:14037: result: $enable_16_color" >&5 echo "${ECHO_T}$enable_16_color" >&6 - test "$enable_16_color" = no && cat >>confdefs.h <<\EOF + test "$enable_16_color" = no && +cat >>confdefs.h <<\EOF #define OPT_AIX_COLORS 0 EOF - echo "$as_me:13165: checking if you want 256 colors" >&5 + echo "$as_me:14044: checking if you want 256 colors" >&5 echo $ECHO_N "checking if you want 256 colors... $ECHO_C" >&6 # Check whether --enable-256-color or --disable-256-color was given. @@ -13179,17 +14058,18 @@ enable_256_color=no fi; - echo "$as_me:13182: result: $enable_256_color" >&5 + echo "$as_me:14061: result: $enable_256_color" >&5 echo "${ECHO_T}$enable_256_color" >&6 if test "$enable_256_color" = yes ; then CHARPROC_DEPS="$CHARPROC_DEPS 256colres.h" EXTRAHDRS="$EXTRAHDRS 256colres.h" - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_256_COLORS 1 EOF else - echo "$as_me:13192: checking if you want 88 colors" >&5 + echo "$as_me:14072: checking if you want 88 colors" >&5 echo $ECHO_N "checking if you want 88 colors... $ECHO_C" >&6 # Check whether --enable-88-color or --disable-88-color was given. @@ -13206,12 +14086,13 @@ enable_88_color=no fi; - echo "$as_me:13209: result: $enable_88_color" >&5 + echo "$as_me:14089: result: $enable_88_color" >&5 echo "${ECHO_T}$enable_88_color" >&6 if test "$enable_88_color" = yes ; then CHARPROC_DEPS="$CHARPROC_DEPS 88colres.h" EXTRAHDRS="$EXTRAHDRS 88colres.h" - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_88_COLORS 1 EOF @@ -13220,7 +14101,7 @@ fi -echo "$as_me:13223: checking if you want blinking cursor" >&5 +echo "$as_me:14104: checking if you want blinking cursor" >&5 echo $ECHO_N "checking if you want blinking cursor... $ECHO_C" >&6 # Check whether --enable-blink-cursor or --disable-blink-cursor was given. @@ -13237,13 +14118,14 @@ enable_blink_curs=yes fi; -echo "$as_me:13240: result: $enable_blink_curs" >&5 +echo "$as_me:14121: result: $enable_blink_curs" >&5 echo "${ECHO_T}$enable_blink_curs" >&6 -test "$enable_blink_curs" = no && cat >>confdefs.h <<\EOF +test "$enable_blink_curs" = no && +cat >>confdefs.h <<\EOF #define OPT_BLINK_CURS 0 EOF -echo "$as_me:13246: checking if you want to ignore Linux's broken palette-strings" >&5 +echo "$as_me:14128: checking if you want to ignore Linux's broken palette-strings" >&5 echo $ECHO_N "checking if you want to ignore Linux's broken palette-strings... $ECHO_C" >&6 case $host_os in #(vi @@ -13267,21 +14149,23 @@ enable_broken_osc=$enableval fi; -echo "$as_me:13270: result: $enable_broken_osc" >&5 +echo "$as_me:14152: result: $enable_broken_osc" >&5 echo "${ECHO_T}$enable_broken_osc" >&6 if test "$enable_broken_osc" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_BROKEN_OSC 1 EOF else - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_BROKEN_OSC 0 EOF fi -echo "$as_me:13284: checking if you want to allow broken string-terminators" >&5 +echo "$as_me:14168: checking if you want to allow broken string-terminators" >&5 echo $ECHO_N "checking if you want to allow broken string-terminators... $ECHO_C" >&6 # Check whether --enable-broken-st or --disable-broken-st was given. @@ -13298,13 +14182,14 @@ enable_broken_st=yes fi; -echo "$as_me:13301: result: $enable_broken_st" >&5 +echo "$as_me:14185: result: $enable_broken_st" >&5 echo "${ECHO_T}$enable_broken_st" >&6 -test "$enable_broken_st" = no && cat >>confdefs.h <<\EOF +test "$enable_broken_st" = no && +cat >>confdefs.h <<\EOF #define OPT_BROKEN_ST 0 EOF -echo "$as_me:13307: checking if you want printable 128-159" >&5 +echo "$as_me:14192: checking if you want printable 128-159" >&5 echo $ECHO_N "checking if you want printable 128-159... $ECHO_C" >&6 # Check whether --enable-c1-print or --disable-c1-print was given. @@ -13321,15 +14206,16 @@ enable_c1_print=yes fi; -echo "$as_me:13324: result: $enable_c1_print" >&5 +echo "$as_me:14209: result: $enable_c1_print" >&5 echo "${ECHO_T}$enable_c1_print" >&6 -test "$enable_c1_print" = no && cat >>confdefs.h <<\EOF +test "$enable_c1_print" = no && +cat >>confdefs.h <<\EOF #define OPT_C1_PRINT 0 EOF if test "$enable_ansi_color" = yes ; then - echo "$as_me:13332: checking if you want bold colors mapped like IBM PC" >&5 + echo "$as_me:14218: checking if you want bold colors mapped like IBM PC" >&5 echo $ECHO_N "checking if you want bold colors mapped like IBM PC... $ECHO_C" >&6 # Check whether --enable-bold-color or --disable-bold-color was given. @@ -13346,13 +14232,14 @@ enable_pc_color=yes fi; - echo "$as_me:13349: result: $enable_pc_color" >&5 + echo "$as_me:14235: result: $enable_pc_color" >&5 echo "${ECHO_T}$enable_pc_color" >&6 - test "$enable_pc_color" = no && cat >>confdefs.h <<\EOF + test "$enable_pc_color" = no && +cat >>confdefs.h <<\EOF #define OPT_PC_COLORS 0 EOF - echo "$as_me:13355: checking if you want separate color-classes" >&5 + echo "$as_me:14242: checking if you want separate color-classes" >&5 echo $ECHO_N "checking if you want separate color-classes... $ECHO_C" >&6 # Check whether --enable-color-class or --disable-color-class was given. @@ -13369,13 +14256,14 @@ enable_color_class=yes fi; - echo "$as_me:13372: result: $enable_color_class" >&5 + echo "$as_me:14259: result: $enable_color_class" >&5 echo "${ECHO_T}$enable_color_class" >&6 - test "$enable_color_class" = no && cat >>confdefs.h <<\EOF -#define OPT_COLOR_CLASS FALSE + test "$enable_color_class" = no && +cat >>confdefs.h <<\EOF +#define OPT_COLOR_CLASS 0 EOF - echo "$as_me:13378: checking if you want color-mode enabled by default" >&5 + echo "$as_me:14266: checking if you want color-mode enabled by default" >&5 echo $ECHO_N "checking if you want color-mode enabled by default... $ECHO_C" >&6 # Check whether --enable-color-mode or --disable-color-mode was given. @@ -13392,15 +14280,16 @@ default_colormode=yes fi; - echo "$as_me:13395: result: $default_colormode" >&5 + echo "$as_me:14283: result: $default_colormode" >&5 echo "${ECHO_T}$default_colormode" >&6 - test "$default_colormode" = no && cat >>confdefs.h <<\EOF -#define DFT_COLORMODE FALSE + test "$default_colormode" = no && +cat >>confdefs.h <<\EOF +#define DFT_COLORMODE 0 EOF fi -echo "$as_me:13403: checking if you want support for color highlighting" >&5 +echo "$as_me:14292: checking if you want support for color highlighting" >&5 echo $ECHO_N "checking if you want support for color highlighting... $ECHO_C" >&6 # Check whether --enable-highlighting or --disable-highlighting was given. @@ -13417,13 +14306,14 @@ default_highlight=yes fi; -echo "$as_me:13420: result: $default_highlight" >&5 +echo "$as_me:14309: result: $default_highlight" >&5 echo "${ECHO_T}$default_highlight" >&6 -test "$default_highlight" = no && cat >>confdefs.h <<\EOF +test "$default_highlight" = no && +cat >>confdefs.h <<\EOF #define OPT_HIGHLIGHT_COLOR 0 EOF -echo "$as_me:13426: checking if you want support for doublesize characters" >&5 +echo "$as_me:14316: checking if you want support for doublesize characters" >&5 echo $ECHO_N "checking if you want support for doublesize characters... $ECHO_C" >&6 # Check whether --enable-doublechars or --disable-doublechars was given. @@ -13439,95 +14329,286 @@ enableval=yes enable_doublechars=yes -fi; -echo "$as_me:13443: result: $enable_doublechars" >&5 -echo "${ECHO_T}$enable_doublechars" >&6 -test "$enable_doublechars" = no && cat >>confdefs.h <<\EOF -#define OPT_DEC_CHRSET 0 -EOF +fi; +echo "$as_me:14333: result: $enable_doublechars" >&5 +echo "${ECHO_T}$enable_doublechars" >&6 +test "$enable_doublechars" = no && +cat >>confdefs.h <<\EOF +#define OPT_DEC_CHRSET 0 +EOF + +echo "$as_me:14340: checking if you want fallback-support for box characters" >&5 +echo $ECHO_N "checking if you want fallback-support for box characters... $ECHO_C" >&6 + +# Check whether --enable-boxchars or --disable-boxchars was given. +if test "${enable_boxchars+set}" = set; then + enableval="$enable_boxchars" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_boxchars=no + else + enable_boxchars=yes + fi +else + enableval=yes + enable_boxchars=yes + +fi; +echo "$as_me:14357: result: $enable_boxchars" >&5 +echo "${ECHO_T}$enable_boxchars" >&6 +test "$enable_boxchars" = no && +cat >>confdefs.h <<\EOF +#define OPT_BOX_CHARS 0 +EOF + +echo "$as_me:14364: checking if you want to allow spawning new xterms" >&5 +echo $ECHO_N "checking if you want to allow spawning new xterms... $ECHO_C" >&6 + +# Check whether --enable-exec-xterm or --disable-exec-xterm was given. +if test "${enable_exec_xterm+set}" = set; then + enableval="$enable_exec_xterm" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + enable_exec_xterm=yes + else + enable_exec_xterm=no + fi +else + enableval=no + enable_exec_xterm=no + +fi; +echo "$as_me:14381: result: $enable_exec_xterm" >&5 +echo "${ECHO_T}$enable_exec_xterm" >&6 +if test "$enable_exec_xterm" = yes ; then + +echo "$as_me:14385: checking for proc tree with cwd-support" >&5 +echo $ECHO_N "checking for proc tree with cwd-support... $ECHO_C" >&6 +if test "${cf_cv_procfs_cwd+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + +cf_cv_procfs_cwd=no +for cf_path in /proc /compat/linux/proc /usr/compat/linux/proc +do + if test -d $cf_path && \ + test -d $cf_path/$$ && \ + ( test -d $cf_path/$$/cwd || \ + test -L $cf_path/$$/cwd ); then + cf_cv_procfs_cwd=$cf_path + break + fi +done + +fi +echo "$as_me:14404: result: $cf_cv_procfs_cwd" >&5 +echo "${ECHO_T}$cf_cv_procfs_cwd" >&6 + + if test "$cf_cv_procfs_cwd" = no ; then + { echo "$as_me:14408: WARNING: no suitable proc filesystem found" >&5 +echo "$as_me: WARNING: no suitable proc filesystem found" >&2;} + else + +cat >>confdefs.h <>confdefs.h <<\EOF +#define OPT_EXEC_XTERM 1 +EOF + + fi +fi + +echo "$as_me:14423: checking if you want to use double-buffering" >&5 +echo $ECHO_N "checking if you want to use double-buffering... $ECHO_C" >&6 + +# Check whether --enable-double-buffer or --disable-double-buffer was given. +if test "${enable_double_buffer+set}" = set; then + enableval="$enable_double_buffer" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + enable_double_bfr=yes + else + enable_double_bfr=no + fi +else + enableval=no + enable_double_bfr=no + +fi; +echo "$as_me:14440: result: $enable_double_bfr" >&5 +echo "${ECHO_T}$enable_double_bfr" >&6 +if test "$enable_double_bfr" = yes ; then + case "x$LIBS" in + *Xext*) + ;; + *) + +if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then + test -n "$verbose" && echo " found package Xext" 1>&6 + +echo "${as_me:-configure}:14451: testing found package Xext ..." 1>&5 + + cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`" + cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`" + test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6 + +echo "${as_me:-configure}:14457: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5 + + test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6 + +echo "${as_me:-configure}:14461: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5 + +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= +cf_new_extra_cppflags= + +for cf_add_cflags in $cf_pkgconfig_incs +do +case $cf_fix_cppflags in +no) + case $cf_add_cflags in #(vi + -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi + case $cf_add_cflags in + -D*) + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=yes + + if test $cf_fix_cppflags = yes ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + elif test "${cf_tst_cflags}" = "\"'" ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + fi + ;; + esac + case "$CPPFLAGS" in + *$cf_add_cflags) #(vi + ;; + *) #(vi + case $cf_add_cflags in #(vi + -D*) + cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` + +CPPFLAGS=`echo "$CPPFLAGS" | \ + sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` + + ;; + esac + cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" + ;; + esac + ;; + *) + cf_new_cflags="$cf_new_cflags $cf_add_cflags" + ;; + esac + ;; +yes) + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; +esac +done + +if test -n "$cf_new_cflags" ; then -echo "$as_me:13449: checking if you want fallback-support for box characters" >&5 -echo $ECHO_N "checking if you want fallback-support for box characters... $ECHO_C" >&6 + CFLAGS="$CFLAGS $cf_new_cflags" +fi -# Check whether --enable-boxchars or --disable-boxchars was given. -if test "${enable_boxchars+set}" = set; then - enableval="$enable_boxchars" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - enable_boxchars=no - else - enable_boxchars=yes - fi -else - enableval=yes - enable_boxchars=yes +if test -n "$cf_new_cppflags" ; then -fi; -echo "$as_me:13466: result: $enable_boxchars" >&5 -echo "${ECHO_T}$enable_boxchars" >&6 -test "$enable_boxchars" = no && cat >>confdefs.h <<\EOF -#define OPT_BOX_CHARS 0 -EOF + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" +fi -echo "$as_me:13472: checking if you want to allow spawning new xterms" >&5 -echo $ECHO_N "checking if you want to allow spawning new xterms... $ECHO_C" >&6 +if test -n "$cf_new_extra_cppflags" ; then -# Check whether --enable-exec-xterm or --disable-exec-xterm was given. -if test "${enable_exec_xterm+set}" = set; then - enableval="$enable_exec_xterm" - test "$enableval" != yes && enableval=no - if test "$enableval" != "no" ; then - enable_exec_xterm=yes - else - enable_exec_xterm=no - fi -else - enableval=no - enable_exec_xterm=no + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" +fi -fi; -echo "$as_me:13489: result: $enable_exec_xterm" >&5 -echo "${ECHO_T}$enable_exec_xterm" >&6 -if test "$enable_exec_xterm" = yes ; then + LIBS="$cf_pkgconfig_libs $LIBS" + : +else + cf_pkgconfig_incs= + cf_pkgconfig_libs= -echo "$as_me:13493: checking for proc tree with cwd-support" >&5 -echo $ECHO_N "checking for proc tree with cwd-support... $ECHO_C" >&6 -if test "${cf_cv_procfs_cwd+set}" = set; then + echo "$as_me:14547: checking for XextCreateExtension in -lXext" >&5 +echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6 +if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lXext $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line 14555 "configure" +#include "confdefs.h" -cf_cv_procfs_cwd=no -for cf_path in /proc /compat/linux/proc /usr/compat/linux/proc -do - if test -d $cf_path && \ - test -d $cf_path/$$ && \ - ( test -d $cf_path/$$/cwd || \ - test -L $cf_path/$$/cwd ); then - cf_cv_procfs_cwd=$cf_path - break - fi -done +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XextCreateExtension (); +int +main () +{ +XextCreateExtension (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:14574: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:14577: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:14580: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:14583: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_Xext_XextCreateExtension=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_Xext_XextCreateExtension=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:14594: result: $ac_cv_lib_Xext_XextCreateExtension" >&5 +echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6 +if test $ac_cv_lib_Xext_XextCreateExtension = yes; then + LIBS="-lXext $LIBS" +fi fi -echo "$as_me:13512: result: $cf_cv_procfs_cwd" >&5 -echo "${ECHO_T}$cf_cv_procfs_cwd" >&6 - if test "$cf_cv_procfs_cwd" = no ; then - { echo "$as_me:13516: WARNING: no suitable proc filesystem found" >&5 -echo "$as_me: WARNING: no suitable proc filesystem found" >&2;} - else - cat >>confdefs.h <>confdefs.h <<\EOF -#define OPT_EXEC_XTERM 1 +cat >>confdefs.h <<\EOF +#define OPT_DOUBLE_BUFFER 1 EOF - fi fi -echo "$as_me:13530: checking if you want to use FreeType library" >&5 +echo "$as_me:14611: checking if you want to use FreeType library" >&5 echo $ECHO_N "checking if you want to use FreeType library... $ECHO_C" >&6 # Check whether --enable-freetype or --disable-freetype was given. @@ -13544,7 +14625,7 @@ enable_freetype=yes fi; -echo "$as_me:13547: result: $enable_freetype" >&5 +echo "$as_me:14628: result: $enable_freetype" >&5 echo "${ECHO_T}$enable_freetype" >&6 if test "$enable_freetype" = yes ; then @@ -13554,7 +14635,7 @@ FREETYPE_CONFIG=none FREETYPE_PARAMS= -echo "$as_me:13557: checking for FreeType configuration script" >&5 +echo "$as_me:14638: checking for FreeType configuration script" >&5 echo $ECHO_N "checking for FreeType configuration script... $ECHO_C" >&6 # Check whether --with-freetype-config or --without-freetype-config was given. @@ -13566,12 +14647,12 @@ fi; test -z $cf_cv_x_freetype_cfgs && cf_cv_x_freetype_cfgs=auto test $cf_cv_x_freetype_cfgs = no && cf_cv_x_freetype_cfgs=none -echo "$as_me:13569: result: $cf_cv_x_freetype_cfgs" >&5 +echo "$as_me:14650: result: $cf_cv_x_freetype_cfgs" >&5 echo "${ECHO_T}$cf_cv_x_freetype_cfgs" >&6 case $cf_cv_x_freetype_cfgs in none) #(vi - echo "$as_me:13574: checking if you specified -D/-I options for FreeType" >&5 + echo "$as_me:14655: checking if you specified -D/-I options for FreeType" >&5 echo $ECHO_N "checking if you specified -D/-I options for FreeType... $ECHO_C" >&6 # Check whether --with-freetype-cflags or --without-freetype-cflags was given. @@ -13581,10 +14662,10 @@ else cf_cv_x_freetype_incs=no fi; - echo "$as_me:13584: result: $cf_cv_x_freetype_incs" >&5 + echo "$as_me:14665: result: $cf_cv_x_freetype_incs" >&5 echo "${ECHO_T}$cf_cv_x_freetype_incs" >&6 - echo "$as_me:13587: checking if you specified -L/-l options for FreeType" >&5 + echo "$as_me:14668: checking if you specified -L/-l options for FreeType" >&5 echo $ECHO_N "checking if you specified -L/-l options for FreeType... $ECHO_C" >&6 # Check whether --with-freetype-libs or --without-freetype-libs was given. @@ -13594,7 +14675,7 @@ else cf_cv_x_freetype_libs=no fi; - echo "$as_me:13597: result: $cf_cv_x_freetype_libs" >&5 + echo "$as_me:14678: result: $cf_cv_x_freetype_libs" >&5 echo "${ECHO_T}$cf_cv_x_freetype_libs" >&6 ;; auto) #(vi @@ -13604,7 +14685,7 @@ else # Extract the first word of "freetype-config", so it can be a program name with args. set dummy freetype-config; ac_word=$2 -echo "$as_me:13607: checking for $ac_word" >&5 +echo "$as_me:14688: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_path_FREETYPE_CONFIG+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -13621,7 +14702,7 @@ test -z "$ac_dir" && ac_dir=. if $as_executable_p "$ac_dir/$ac_word"; then ac_cv_path_FREETYPE_CONFIG="$ac_dir/$ac_word" - echo "$as_me:13624: found $ac_dir/$ac_word" >&5 + echo "$as_me:14705: found $ac_dir/$ac_word" >&5 break fi done @@ -13633,10 +14714,10 @@ FREETYPE_CONFIG=$ac_cv_path_FREETYPE_CONFIG if test -n "$FREETYPE_CONFIG"; then - echo "$as_me:13636: result: $FREETYPE_CONFIG" >&5 + echo "$as_me:14717: result: $FREETYPE_CONFIG" >&5 echo "${ECHO_T}$FREETYPE_CONFIG" >&6 else - echo "$as_me:13639: result: no" >&5 + echo "$as_me:14720: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -13646,7 +14727,7 @@ else # Extract the first word of "xft-config", so it can be a program name with args. set dummy xft-config; ac_word=$2 -echo "$as_me:13649: checking for $ac_word" >&5 +echo "$as_me:14730: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_path_FREETYPE_OLD_CONFIG+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -13663,7 +14744,7 @@ test -z "$ac_dir" && ac_dir=. if $as_executable_p "$ac_dir/$ac_word"; then ac_cv_path_FREETYPE_OLD_CONFIG="$ac_dir/$ac_word" - echo "$as_me:13666: found $ac_dir/$ac_word" >&5 + echo "$as_me:14747: found $ac_dir/$ac_word" >&5 break fi done @@ -13675,10 +14756,10 @@ FREETYPE_OLD_CONFIG=$ac_cv_path_FREETYPE_OLD_CONFIG if test -n "$FREETYPE_OLD_CONFIG"; then - echo "$as_me:13678: result: $FREETYPE_OLD_CONFIG" >&5 + echo "$as_me:14759: result: $FREETYPE_OLD_CONFIG" >&5 echo "${ECHO_T}$FREETYPE_OLD_CONFIG" >&6 else - echo "$as_me:13681: result: no" >&5 + echo "$as_me:14762: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -13693,14 +14774,14 @@ FREETYPE_CONFIG=$cf_cv_x_freetype_cfgs FREETYPE_PARAMS=xft else - { echo "$as_me:13696: WARNING: cannot find pkg-config for Xft" >&5 + { echo "$as_me:14777: WARNING: cannot find pkg-config for Xft" >&5 echo "$as_me: WARNING: cannot find pkg-config for Xft" >&2;} fi ;; *) #(vi # Extract the first word of "$cf_cv_x_freetype_cfgs", so it can be a program name with args. set dummy $cf_cv_x_freetype_cfgs; ac_word=$2 -echo "$as_me:13703: checking for $ac_word" >&5 +echo "$as_me:14784: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_path_FREETYPE_XFT_CONFIG+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -13717,7 +14798,7 @@ test -z "$ac_dir" && ac_dir=. if $as_executable_p "$ac_dir/$ac_word"; then ac_cv_path_FREETYPE_XFT_CONFIG="$ac_dir/$ac_word" - echo "$as_me:13720: found $ac_dir/$ac_word" >&5 + echo "$as_me:14801: found $ac_dir/$ac_word" >&5 break fi done @@ -13729,41 +14810,41 @@ FREETYPE_XFT_CONFIG=$ac_cv_path_FREETYPE_XFT_CONFIG if test -n "$FREETYPE_XFT_CONFIG"; then - echo "$as_me:13732: result: $FREETYPE_XFT_CONFIG" >&5 + echo "$as_me:14813: result: $FREETYPE_XFT_CONFIG" >&5 echo "${ECHO_T}$FREETYPE_XFT_CONFIG" >&6 else - echo "$as_me:13735: result: no" >&5 + echo "$as_me:14816: result: no" >&5 echo "${ECHO_T}no" >&6 fi if test "$FREETYPE_XFT_CONFIG" != none; then FREETYPE_CONFIG=$FREETYPE_XFT_CONFIG else - { echo "$as_me:13742: WARNING: cannot find config script for Xft" >&5 + { echo "$as_me:14823: WARNING: cannot find config script for Xft" >&5 echo "$as_me: WARNING: cannot find config script for Xft" >&2;} fi ;; esac if test "$FREETYPE_CONFIG" != none ; then - echo "$as_me:13749: checking for FreeType config" >&5 + echo "$as_me:14830: checking for FreeType config" >&5 echo $ECHO_N "checking for FreeType config... $ECHO_C" >&6 - echo "$as_me:13751: result: $FREETYPE_CONFIG $FREETYPE_PARAMS" >&5 + echo "$as_me:14832: result: $FREETYPE_CONFIG $FREETYPE_PARAMS" >&5 echo "${ECHO_T}$FREETYPE_CONFIG $FREETYPE_PARAMS" >&6 if test "$cf_cv_x_freetype_incs" = no ; then - echo "$as_me:13755: checking for $FREETYPE_CONFIG cflags" >&5 + echo "$as_me:14836: checking for $FREETYPE_CONFIG cflags" >&5 echo $ECHO_N "checking for $FREETYPE_CONFIG cflags... $ECHO_C" >&6 cf_cv_x_freetype_incs="`$FREETYPE_CONFIG $FREETYPE_PARAMS --cflags 2>/dev/null`" - echo "$as_me:13758: result: $cf_cv_x_freetype_incs" >&5 + echo "$as_me:14839: result: $cf_cv_x_freetype_incs" >&5 echo "${ECHO_T}$cf_cv_x_freetype_incs" >&6 fi if test "$cf_cv_x_freetype_libs" = no ; then - echo "$as_me:13763: checking for $FREETYPE_CONFIG libs" >&5 + echo "$as_me:14844: checking for $FREETYPE_CONFIG libs" >&5 echo $ECHO_N "checking for $FREETYPE_CONFIG libs... $ECHO_C" >&6 cf_cv_x_freetype_libs="$cf_extra_freetype_libs `$FREETYPE_CONFIG $FREETYPE_PARAMS --libs 2>/dev/null`" - echo "$as_me:13766: result: $cf_cv_x_freetype_libs" >&5 + echo "$as_me:14847: result: $cf_cv_x_freetype_libs" >&5 echo "${ECHO_T}$cf_cv_x_freetype_libs" >&6 fi fi @@ -13776,7 +14857,7 @@ cf_cv_x_freetype_libs=-lXft fi -echo "$as_me:13779: checking if we can link with FreeType libraries" >&5 +echo "$as_me:14860: checking if we can link with FreeType libraries" >&5 echo $ECHO_N "checking if we can link with FreeType libraries... $ECHO_C" >&6 cf_save_LIBS="$LIBS" @@ -13786,7 +14867,7 @@ CPPFLAGS="$CPPFLAGS $cf_cv_x_freetype_incs" cat >conftest.$ac_ext <<_ACEOF -#line 13789 "configure" +#line 14870 "configure" #include "confdefs.h" #include @@ -13802,16 +14883,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:13805: \"$ac_link\"") >&5 +if { (eval echo "$as_me:14886: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:13808: \$? = $ac_status" >&5 + echo "$as_me:14889: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:13811: \"$ac_try\"") >&5 + { (eval echo "$as_me:14892: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:13814: \$? = $ac_status" >&5 + echo "$as_me:14895: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_found_freetype=yes else @@ -13820,7 +14901,7 @@ cf_cv_found_freetype=no fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -echo "$as_me:13823: result: $cf_cv_found_freetype" >&5 +echo "$as_me:14904: result: $cf_cv_found_freetype" >&5 echo "${ECHO_T}$cf_cv_found_freetype" >&6 LIBS="$cf_save_LIBS" @@ -13907,7 +14988,7 @@ EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" fi - cat >>confdefs.h <<\EOF +cat >>confdefs.h <<\EOF #define XRENDERFONT 1 EOF @@ -13918,13 +14999,13 @@ do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -echo "$as_me:13921: checking for $ac_func" >&5 +echo "$as_me:15002: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 13927 "configure" +#line 15008 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. */ @@ -13947,7 +15028,7 @@ #if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -f = $ac_func; +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -13955,16 +15036,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:13958: \"$ac_link\"") >&5 +if { (eval echo "$as_me:15039: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:13961: \$? = $ac_status" >&5 + echo "$as_me:15042: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:13964: \"$ac_try\"") >&5 + { (eval echo "$as_me:15045: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:13967: \$? = $ac_status" >&5 + echo "$as_me:15048: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_var=yes" else @@ -13974,7 +15055,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:13977: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "$as_me:15058: result: `eval echo '${'$as_ac_var'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <&5 + { echo "$as_me:15069: WARNING: No libraries found for FreeType" >&5 echo "$as_me: WARNING: No libraries found for FreeType" >&2;} CPPFLAGS=`echo "$CPPFLAGS" | sed -e s/-DXRENDERFONT//` fi @@ -13993,14 +15074,14 @@ # FIXME: revisit this if needed if test "$cf_cv_found_freetype" = yes ; then -echo "$as_me:13996: checking for usable Xft/fontconfig package" >&5 +echo "$as_me:15077: checking for usable Xft/fontconfig package" >&5 echo $ECHO_N "checking for usable Xft/fontconfig package... $ECHO_C" >&6 if test "${cf_cv_xft_compat+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 14003 "configure" +#line 15084 "configure" #include "confdefs.h" #include @@ -14019,16 +15100,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:14022: \"$ac_link\"") >&5 +if { (eval echo "$as_me:15103: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:14025: \$? = $ac_status" >&5 + echo "$as_me:15106: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:14028: \"$ac_try\"") >&5 + { (eval echo "$as_me:15109: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:14031: \$? = $ac_status" >&5 + echo "$as_me:15112: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_xft_compat=yes else @@ -14039,7 +15120,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:14042: result: $cf_cv_xft_compat" >&5 +echo "$as_me:15123: result: $cf_cv_xft_compat" >&5 echo "${ECHO_T}$cf_cv_xft_compat" >&6 if test "$cf_cv_xft_compat" = no @@ -14051,22 +15132,24 @@ *) test -n "$verbose" && echo " work around broken package" 1>&6 -echo "${as_me:-configure}:14054: testing work around broken package ..." 1>&5 +echo "${as_me:-configure}:15135: testing work around broken package ..." 1>&5 + + cf_save_fontconfig="$LIBS" if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists fontconfig; then test -n "$verbose" && echo " found package fontconfig" 1>&6 -echo "${as_me:-configure}:14059: testing found package fontconfig ..." 1>&5 +echo "${as_me:-configure}:15142: testing found package fontconfig ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags fontconfig 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs fontconfig 2>/dev/null`" test -n "$verbose" && echo " package fontconfig CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:14065: testing package fontconfig CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:15148: testing package fontconfig CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package fontconfig LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:14069: testing package fontconfig LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:15152: testing package fontconfig LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -14147,17 +15230,108 @@ fi LIBS="$cf_pkgconfig_libs $LIBS" - : + +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= +cf_new_extra_cppflags= + +for cf_add_cflags in $cf_pkgconfig_incs +do +case $cf_fix_cppflags in +no) + case $cf_add_cflags in #(vi + -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi + case $cf_add_cflags in + -D*) + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=yes + + if test $cf_fix_cppflags = yes ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + elif test "${cf_tst_cflags}" = "\"'" ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + fi + ;; + esac + case "$CPPFLAGS" in + *$cf_add_cflags) #(vi + ;; + *) #(vi + case $cf_add_cflags in #(vi + -D*) + cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` + +CPPFLAGS=`echo "$CPPFLAGS" | \ + sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` + + ;; + esac + cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" + ;; + esac + ;; + *) + cf_new_cflags="$cf_new_cflags $cf_add_cflags" + ;; + esac + ;; +yes) + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; +esac +done + +if test -n "$cf_new_cflags" ; then + + CFLAGS="$CFLAGS $cf_new_cflags" +fi + +if test -n "$cf_new_cppflags" ; then + + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" +fi + +if test -n "$cf_new_extra_cppflags" ; then + + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" +fi + + LIBS="$cf_save_fontconfig" + +test -n "$verbose" && echo " ...before $LIBS" 1>&6 + +echo "${as_me:-configure}:15316: testing ...before $LIBS ..." 1>&5 + +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXft %-lXft $cf_pkgconfig_libs %" -e 's% % %g'` +test -n "$verbose" && echo " ...after $LIBS" 1>&6 + +echo "${as_me:-configure}:15321: testing ...after $LIBS ..." 1>&5 + else + cf_pkgconfig_incs= + cf_pkgconfig_libs= test -n "$verbose" && echo " ...before $LIBS" 1>&6 -echo "${as_me:-configure}:14155: testing ...before $LIBS ..." 1>&5 +echo "${as_me:-configure}:15329: testing ...before $LIBS ..." 1>&5 -LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s,-lXft ,-lXft -lfontconfig ," -e 's/ / /g'` +LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXft %-lXft -lfontconfig %" -e 's% % %g'` test -n "$verbose" && echo " ...after $LIBS" 1>&6 -echo "${as_me:-configure}:14160: testing ...after $LIBS ..." 1>&5 +echo "${as_me:-configure}:15334: testing ...after $LIBS ..." 1>&5 fi @@ -14170,7 +15344,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | sed -e s/-DXRENDERFONT//` fi -echo "$as_me:14173: checking if you want support for HP-style function keys" >&5 +echo "$as_me:15347: checking if you want support for HP-style function keys" >&5 echo $ECHO_N "checking if you want support for HP-style function keys... $ECHO_C" >&6 # Check whether --enable-hp-fkeys or --disable-hp-fkeys was given. @@ -14187,16 +15361,17 @@ enable_hp_fkeys=no fi; -echo "$as_me:14190: result: $enable_hp_fkeys" >&5 +echo "$as_me:15364: result: $enable_hp_fkeys" >&5 echo "${ECHO_T}$enable_hp_fkeys" >&6 if test "$enable_hp_fkeys" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_HP_FUNC_KEYS 1 EOF fi -echo "$as_me:14199: checking if you want support for SCO-style function keys" >&5 +echo "$as_me:15374: checking if you want support for SCO-style function keys" >&5 echo $ECHO_N "checking if you want support for SCO-style function keys... $ECHO_C" >&6 # Check whether --enable-sco-fkeys or --disable-sco-fkeys was given. @@ -14213,16 +15388,17 @@ enable_sco_fkeys=no fi; -echo "$as_me:14216: result: $enable_sco_fkeys" >&5 +echo "$as_me:15391: result: $enable_sco_fkeys" >&5 echo "${ECHO_T}$enable_sco_fkeys" >&6 if test "$enable_sco_fkeys" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_SCO_FUNC_KEYS 1 EOF fi -echo "$as_me:14225: checking if you want support for Sun-style function keys" >&5 +echo "$as_me:15401: checking if you want support for Sun-style function keys" >&5 echo $ECHO_N "checking if you want support for Sun-style function keys... $ECHO_C" >&6 # Check whether --enable-sun-fkeys or --disable-sun-fkeys was given. @@ -14239,16 +15415,17 @@ enable_sun_fkeys=yes fi; -echo "$as_me:14242: result: $enable_sun_fkeys" >&5 +echo "$as_me:15418: result: $enable_sun_fkeys" >&5 echo "${ECHO_T}$enable_sun_fkeys" >&6 if test "$enable_sun_fkeys" = no ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_SUN_FUNC_KEYS 0 EOF fi -echo "$as_me:14251: checking if you want saved-lines stored as a FIFO" >&5 +echo "$as_me:15428: checking if you want saved-lines stored as a FIFO" >&5 echo $ECHO_N "checking if you want saved-lines stored as a FIFO... $ECHO_C" >&6 # Check whether --enable-fifo-lines or --disable-fifo-lines was given. @@ -14265,16 +15442,17 @@ enable_fifo_lines=yes fi; -echo "$as_me:14268: result: $enable_fifo_lines" >&5 +echo "$as_me:15445: result: $enable_fifo_lines" >&5 echo "${ECHO_T}$enable_fifo_lines" >&6 if test "$enable_fifo_lines" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_FIFO_LINES 1 EOF fi -echo "$as_me:14277: checking if you want support for internationalization" >&5 +echo "$as_me:15455: checking if you want support for internationalization" >&5 echo $ECHO_N "checking if you want support for internationalization... $ECHO_C" >&6 # Check whether --enable-i18n or --disable-i18n was given. @@ -14291,16 +15469,17 @@ enable_i18n=yes fi; -echo "$as_me:14294: result: $enable_i18n" >&5 +echo "$as_me:15472: result: $enable_i18n" >&5 echo "${ECHO_T}$enable_i18n" >&6 if test "$enable_i18n" = no ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_I18N_SUPPORT 0 EOF fi -echo "$as_me:14303: checking if you want support for initial-erase setup" >&5 +echo "$as_me:15482: checking if you want support for initial-erase setup" >&5 echo $ECHO_N "checking if you want support for initial-erase setup... $ECHO_C" >&6 # Check whether --enable-initial-erase or --disable-initial-erase was given. @@ -14317,16 +15496,17 @@ enable_ie=yes fi; -echo "$as_me:14320: result: $enable_ie" >&5 +echo "$as_me:15499: result: $enable_ie" >&5 echo "${ECHO_T}$enable_ie" >&6 if test "$enable_ie" = no ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_INITIAL_ERASE 0 EOF fi -echo "$as_me:14329: checking if you want support for input-method" >&5 +echo "$as_me:15509: checking if you want support for input-method" >&5 echo $ECHO_N "checking if you want support for input-method... $ECHO_C" >&6 # Check whether --enable-input-method or --disable-input-method was given. @@ -14343,17 +15523,17 @@ enable_ximp=yes fi; -echo "$as_me:14346: result: $enable_ximp" >&5 +echo "$as_me:15526: result: $enable_ximp" >&5 echo "${ECHO_T}$enable_ximp" >&6 -echo "$as_me:14349: checking if X libraries support input-method" >&5 +echo "$as_me:15529: checking if X libraries support input-method" >&5 echo $ECHO_N "checking if X libraries support input-method... $ECHO_C" >&6 if test "${cf_cv_input_method+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 14356 "configure" +#line 15536 "configure" #include "confdefs.h" #include @@ -14385,16 +15565,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:14388: \"$ac_link\"") >&5 +if { (eval echo "$as_me:15568: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:14391: \$? = $ac_status" >&5 + echo "$as_me:15571: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:14394: \"$ac_try\"") >&5 + { (eval echo "$as_me:15574: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:14397: \$? = $ac_status" >&5 + echo "$as_me:15577: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_input_method=yes else @@ -14404,18 +15584,19 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:14407: result: $cf_cv_input_method" >&5 +echo "$as_me:15587: result: $cf_cv_input_method" >&5 echo "${ECHO_T}$cf_cv_input_method" >&6 test "$cf_cv_input_method" = no && enable_ximp=no if test "$enable_ximp" = no ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_INPUT_METHOD 0 EOF fi -echo "$as_me:14418: checking if you want support for load-vt-fonts" >&5 +echo "$as_me:15599: checking if you want support for load-vt-fonts" >&5 echo $ECHO_N "checking if you want support for load-vt-fonts... $ECHO_C" >&6 # Check whether --enable-load-vt-fonts or --disable-load-vt-fonts was given. @@ -14432,16 +15613,17 @@ enable_load_vt_fonts=no fi; -echo "$as_me:14435: result: $enable_load_vt_fonts" >&5 +echo "$as_me:15616: result: $enable_load_vt_fonts" >&5 echo "${ECHO_T}$enable_load_vt_fonts" >&6 if test "$enable_load_vt_fonts" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_LOAD_VTFONTS 1 EOF fi -echo "$as_me:14444: checking if you want support for logging" >&5 +echo "$as_me:15626: checking if you want support for logging" >&5 echo $ECHO_N "checking if you want support for logging... $ECHO_C" >&6 # Check whether --enable-logging or --disable-logging was given. @@ -14458,14 +15640,15 @@ enable_logging=no fi; -echo "$as_me:14461: result: $enable_logging" >&5 +echo "$as_me:15643: result: $enable_logging" >&5 echo "${ECHO_T}$enable_logging" >&6 if test "$enable_logging" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define ALLOWLOGGING 1 EOF - echo "$as_me:14468: checking if you want to allow logging via a pipe" >&5 + echo "$as_me:15651: checking if you want to allow logging via a pipe" >&5 echo $ECHO_N "checking if you want to allow logging via a pipe... $ECHO_C" >&6 # Check whether --enable-logfile-exec or --disable-logfile-exec was given. @@ -14482,17 +15665,18 @@ enable_log_exec=no fi; - echo "$as_me:14485: result: $enable_log_exec" >&5 + echo "$as_me:15668: result: $enable_log_exec" >&5 echo "${ECHO_T}$enable_log_exec" >&6 if test "$enable_log_exec" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define ALLOWLOGFILEEXEC 1 EOF fi fi -echo "$as_me:14495: checking if you want support for iconify/maximize translations" >&5 +echo "$as_me:15679: checking if you want support for iconify/maximize translations" >&5 echo $ECHO_N "checking if you want support for iconify/maximize translations... $ECHO_C" >&6 # Check whether --enable-maximize or --disable-maximize was given. @@ -14509,13 +15693,14 @@ enable_maximize=yes fi; -echo "$as_me:14512: result: $enable_maximize" >&5 +echo "$as_me:15696: result: $enable_maximize" >&5 echo "${ECHO_T}$enable_maximize" >&6 -test "$enable_maximize" = no && cat >>confdefs.h <<\EOF +test "$enable_maximize" = no && +cat >>confdefs.h <<\EOF #define OPT_MAXIMIZE 0 EOF -echo "$as_me:14518: checking if you want NumLock to override keyboard tables" >&5 +echo "$as_me:15703: checking if you want NumLock to override keyboard tables" >&5 echo $ECHO_N "checking if you want NumLock to override keyboard tables... $ECHO_C" >&6 # Check whether --enable-num-lock or --disable-num-lock was given. @@ -14532,13 +15717,14 @@ enable_numlock=yes fi; -echo "$as_me:14535: result: $enable_numlock" >&5 +echo "$as_me:15720: result: $enable_numlock" >&5 echo "${ECHO_T}$enable_numlock" >&6 -test "$enable_numlock" = no && cat >>confdefs.h <<\EOF +test "$enable_numlock" = no && +cat >>confdefs.h <<\EOF #define OPT_NUM_LOCK 0 EOF -echo "$as_me:14541: checking if you want support for get/set of base64 selection data" >&5 +echo "$as_me:15727: checking if you want support for get/set of base64 selection data" >&5 echo $ECHO_N "checking if you want support for get/set of base64 selection data... $ECHO_C" >&6 # Check whether --enable-paste64 or --disable-paste64 was given. @@ -14555,21 +15741,23 @@ enable_paste64=yes fi; -echo "$as_me:14558: result: $enable_paste64" >&5 +echo "$as_me:15744: result: $enable_paste64" >&5 echo "${ECHO_T}$enable_paste64" >&6 if test "$enable_paste64" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_PASTE64 1 EOF else - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_PASTE64 0 EOF fi -echo "$as_me:14572: checking if you want support for pty-handshaking" >&5 +echo "$as_me:15760: checking if you want support for pty-handshaking" >&5 echo $ECHO_N "checking if you want support for pty-handshaking... $ECHO_C" >&6 # Check whether --enable-pty-handshake or --disable-pty-handshake was given. @@ -14586,21 +15774,23 @@ enable_pty_handshake=yes fi; -echo "$as_me:14589: result: $enable_pty_handshake" >&5 +echo "$as_me:15777: result: $enable_pty_handshake" >&5 echo "${ECHO_T}$enable_pty_handshake" >&6 if test "$enable_pty_handshake" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_PTY_HANDSHAKE 1 EOF else - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_PTY_HANDSHAKE 0 EOF fi -echo "$as_me:14603: checking if you want support for mouse in readline applications" >&5 +echo "$as_me:15793: checking if you want support for mouse in readline applications" >&5 echo $ECHO_N "checking if you want support for mouse in readline applications... $ECHO_C" >&6 # Check whether --enable-readline-mouse or --disable-readline-mouse was given. @@ -14617,16 +15807,17 @@ enable_readline_mouse=no fi; -echo "$as_me:14620: result: $enable_readline_mouse" >&5 +echo "$as_me:15810: result: $enable_readline_mouse" >&5 echo "${ECHO_T}$enable_readline_mouse" >&6 if test "$enable_readline_mouse" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_READLINE 1 EOF fi -echo "$as_me:14629: checking if you want support for regular-expression selections" >&5 +echo "$as_me:15820: checking if you want support for regular-expression selections" >&5 echo $ECHO_N "checking if you want support for regular-expression selections... $ECHO_C" >&6 # Check whether --enable-regex or --disable-regex was given. @@ -14643,11 +15834,11 @@ enable_regex=yes fi; -echo "$as_me:14646: result: $enable_regex" >&5 +echo "$as_me:15837: result: $enable_regex" >&5 echo "${ECHO_T}$enable_regex" >&6 if test "$enable_regex" = yes ; then -echo "$as_me:14650: checking if you want to use PCRE for regular-expressions" >&5 +echo "$as_me:15841: checking if you want to use PCRE for regular-expressions" >&5 echo $ECHO_N "checking if you want to use PCRE for regular-expressions... $ECHO_C" >&6 # Check whether --with-pcre or --without-pcre was given. @@ -14656,7 +15847,7 @@ fi; test -z "$with_pcre" && with_pcre=no -echo "$as_me:14659: result: $with_pcre" >&5 +echo "$as_me:15850: result: $with_pcre" >&5 echo "${ECHO_T}$with_pcre" >&6 if test "$with_pcre" != no ; then @@ -14664,17 +15855,17 @@ if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists libpcre; then test -n "$verbose" && echo " found package libpcre" 1>&6 -echo "${as_me:-configure}:14667: testing found package libpcre ..." 1>&5 +echo "${as_me:-configure}:15858: testing found package libpcre ..." 1>&5 cf_pkgconfig_incs="`$PKG_CONFIG --cflags libpcre 2>/dev/null`" cf_pkgconfig_libs="`$PKG_CONFIG --libs libpcre 2>/dev/null`" test -n "$verbose" && echo " package libpcre CFLAGS: $cf_pkgconfig_incs" 1>&6 -echo "${as_me:-configure}:14673: testing package libpcre CFLAGS: $cf_pkgconfig_incs ..." 1>&5 +echo "${as_me:-configure}:15864: testing package libpcre CFLAGS: $cf_pkgconfig_incs ..." 1>&5 test -n "$verbose" && echo " package libpcre LIBS: $cf_pkgconfig_libs" 1>&6 -echo "${as_me:-configure}:14677: testing package libpcre LIBS: $cf_pkgconfig_libs ..." 1>&5 +echo "${as_me:-configure}:15868: testing package libpcre LIBS: $cf_pkgconfig_libs ..." 1>&5 cf_fix_cppflags=no cf_new_cflags= @@ -14757,8 +15948,10 @@ LIBS="$cf_pkgconfig_libs $LIBS" : else + cf_pkgconfig_incs= + cf_pkgconfig_libs= -echo "$as_me:14761: checking for pcre_compile in -lpcre" >&5 +echo "$as_me:15954: checking for pcre_compile in -lpcre" >&5 echo $ECHO_N "checking for pcre_compile in -lpcre... $ECHO_C" >&6 if test "${ac_cv_lib_pcre_pcre_compile+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -14766,7 +15959,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lpcre $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 14769 "configure" +#line 15962 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -14785,16 +15978,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:14788: \"$ac_link\"") >&5 +if { (eval echo "$as_me:15981: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:14791: \$? = $ac_status" >&5 + echo "$as_me:15984: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:14794: \"$ac_try\"") >&5 + { (eval echo "$as_me:15987: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:14797: \$? = $ac_status" >&5 + echo "$as_me:15990: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_pcre_pcre_compile=yes else @@ -14805,7 +15998,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:14808: result: $ac_cv_lib_pcre_pcre_compile" >&5 +echo "$as_me:16001: result: $ac_cv_lib_pcre_pcre_compile" >&5 echo "${ECHO_T}$ac_cv_lib_pcre_pcre_compile" >&6 if test $ac_cv_lib_pcre_pcre_compile = yes; then cat >>confdefs.h <&5 + { { echo "$as_me:16011: error: Cannot find PCRE library" >&5 echo "$as_me: error: Cannot find PCRE library" >&2;} { (exit 1); exit 1; }; } fi fi - cat >>confdefs.h <<\EOF +cat >>confdefs.h <<\EOF #define HAVE_LIB_PCRE 1 EOF @@ -14830,7 +16023,7 @@ *pcreposix*) #(vi ;; *) - echo "$as_me:14833: checking for pcreposix_regcomp in -lpcreposix" >&5 + echo "$as_me:16026: checking for pcreposix_regcomp in -lpcreposix" >&5 echo $ECHO_N "checking for pcreposix_regcomp in -lpcreposix... $ECHO_C" >&6 if test "${ac_cv_lib_pcreposix_pcreposix_regcomp+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -14838,7 +16031,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lpcreposix $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 14841 "configure" +#line 16034 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -14857,16 +16050,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:14860: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16053: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:14863: \$? = $ac_status" >&5 + echo "$as_me:16056: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:14866: \"$ac_try\"") >&5 + { (eval echo "$as_me:16059: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:14869: \$? = $ac_status" >&5 + echo "$as_me:16062: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_pcreposix_pcreposix_regcomp=yes else @@ -14877,16 +16070,17 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:14880: result: $ac_cv_lib_pcreposix_pcreposix_regcomp" >&5 +echo "$as_me:16073: result: $ac_cv_lib_pcreposix_pcreposix_regcomp" >&5 echo "${ECHO_T}$ac_cv_lib_pcreposix_pcreposix_regcomp" >&6 if test $ac_cv_lib_pcreposix_pcreposix_regcomp = yes; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define HAVE_PCREPOSIX_H 1 EOF LIBS="-lpcreposix $LIBS" else - echo "$as_me:14889: checking for regcomp in -lpcreposix" >&5 + echo "$as_me:16083: checking for regcomp in -lpcreposix" >&5 echo $ECHO_N "checking for regcomp in -lpcreposix... $ECHO_C" >&6 if test "${ac_cv_lib_pcreposix_regcomp+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -14894,7 +16088,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lpcreposix $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 14897 "configure" +#line 16091 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -14913,16 +16107,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:14916: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16110: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:14919: \$? = $ac_status" >&5 + echo "$as_me:16113: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:14922: \"$ac_try\"") >&5 + { (eval echo "$as_me:16116: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:14925: \$? = $ac_status" >&5 + echo "$as_me:16119: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_pcreposix_regcomp=yes else @@ -14933,17 +16127,17 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:14936: result: $ac_cv_lib_pcreposix_regcomp" >&5 +echo "$as_me:16130: result: $ac_cv_lib_pcreposix_regcomp" >&5 echo "${ECHO_T}$ac_cv_lib_pcreposix_regcomp" >&6 if test $ac_cv_lib_pcreposix_regcomp = yes; then - cat >>confdefs.h <<\EOF +cat >>confdefs.h <<\EOF #define HAVE_PCREPOSIX_H 1 EOF LIBS="-lpcreposix $LIBS" else - { { echo "$as_me:14946: error: Cannot find PCRE POSIX library" >&5 + { { echo "$as_me:16140: error: Cannot find PCRE POSIX library" >&5 echo "$as_me: error: Cannot find PCRE POSIX library" >&2;} { (exit 1); exit 1; }; } fi @@ -14961,17 +16155,17 @@ cf_regex_libs="regex re" case $host_os in #(vi mingw*) - cf_regex_libs="regex.dll $cf_regex_libs" + cf_regex_libs="gnurx $cf_regex_libs" ;; esac -echo "$as_me:14968: checking for regcomp" >&5 +echo "$as_me:16162: checking for regcomp" >&5 echo $ECHO_N "checking for regcomp... $ECHO_C" >&6 if test "${ac_cv_func_regcomp+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 14974 "configure" +#line 16168 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char regcomp (); below. */ @@ -14994,7 +16188,7 @@ #if defined (__stub_regcomp) || defined (__stub___regcomp) choke me #else -f = regcomp; +f = regcomp; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -15002,16 +16196,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:15005: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16199: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:15008: \$? = $ac_status" >&5 + echo "$as_me:16202: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:15011: \"$ac_try\"") >&5 + { (eval echo "$as_me:16205: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:15014: \$? = $ac_status" >&5 + echo "$as_me:16208: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_regcomp=yes else @@ -15021,7 +16215,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:15024: result: $ac_cv_func_regcomp" >&5 +echo "$as_me:16218: result: $ac_cv_func_regcomp" >&5 echo "${ECHO_T}$ac_cv_func_regcomp" >&6 if test $ac_cv_func_regcomp = yes; then cf_regex_func=regcomp @@ -15030,7 +16224,7 @@ for cf_regex_lib in $cf_regex_libs do as_ac_Lib=`echo "ac_cv_lib_$cf_regex_lib''_regcomp" | $as_tr_sh` -echo "$as_me:15033: checking for regcomp in -l$cf_regex_lib" >&5 +echo "$as_me:16227: checking for regcomp in -l$cf_regex_lib" >&5 echo $ECHO_N "checking for regcomp in -l$cf_regex_lib... $ECHO_C" >&6 if eval "test \"\${$as_ac_Lib+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -15038,7 +16232,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-l$cf_regex_lib $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 15041 "configure" +#line 16235 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -15057,16 +16251,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:15060: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16254: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:15063: \$? = $ac_status" >&5 + echo "$as_me:16257: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:15066: \"$ac_try\"") >&5 + { (eval echo "$as_me:16260: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:15069: \$? = $ac_status" >&5 + echo "$as_me:16263: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_Lib=yes" else @@ -15077,7 +16271,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:15080: result: `eval echo '${'$as_ac_Lib'}'`" >&5 +echo "$as_me:16274: result: `eval echo '${'$as_ac_Lib'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 if test `eval echo '${'$as_ac_Lib'}'` = yes; then @@ -15091,13 +16285,13 @@ fi if test "$cf_regex_func" = no ; then - echo "$as_me:15094: checking for compile" >&5 + echo "$as_me:16288: checking for compile" >&5 echo $ECHO_N "checking for compile... $ECHO_C" >&6 if test "${ac_cv_func_compile+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 15100 "configure" +#line 16294 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char compile (); below. */ @@ -15120,7 +16314,7 @@ #if defined (__stub_compile) || defined (__stub___compile) choke me #else -f = compile; +f = compile; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -15128,16 +16322,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:15131: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16325: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:15134: \$? = $ac_status" >&5 + echo "$as_me:16328: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:15137: \"$ac_try\"") >&5 + { (eval echo "$as_me:16331: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:15140: \$? = $ac_status" >&5 + echo "$as_me:16334: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_compile=yes else @@ -15147,13 +16341,13 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:15150: result: $ac_cv_func_compile" >&5 +echo "$as_me:16344: result: $ac_cv_func_compile" >&5 echo "${ECHO_T}$ac_cv_func_compile" >&6 if test $ac_cv_func_compile = yes; then cf_regex_func=compile else - echo "$as_me:15156: checking for compile in -lgen" >&5 + echo "$as_me:16350: checking for compile in -lgen" >&5 echo $ECHO_N "checking for compile in -lgen... $ECHO_C" >&6 if test "${ac_cv_lib_gen_compile+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -15161,7 +16355,7 @@ ac_check_lib_save_LIBS=$LIBS LIBS="-lgen $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 15164 "configure" +#line 16358 "configure" #include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ @@ -15180,16 +16374,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:15183: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16377: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:15186: \$? = $ac_status" >&5 + echo "$as_me:16380: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:15189: \"$ac_try\"") >&5 + { (eval echo "$as_me:16383: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:15192: \$? = $ac_status" >&5 + echo "$as_me:16386: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_gen_compile=yes else @@ -15200,7 +16394,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -echo "$as_me:15203: result: $ac_cv_lib_gen_compile" >&5 +echo "$as_me:16397: result: $ac_cv_lib_gen_compile" >&5 echo "${ECHO_T}$ac_cv_lib_gen_compile" >&6 if test $ac_cv_lib_gen_compile = yes; then @@ -15213,11 +16407,11 @@ fi if test "$cf_regex_func" = no ; then - { echo "$as_me:15216: WARNING: cannot find regular expression library" >&5 + { echo "$as_me:16410: WARNING: cannot find regular expression library" >&5 echo "$as_me: WARNING: cannot find regular expression library" >&2;} fi -echo "$as_me:15220: checking for regular-expression headers" >&5 +echo "$as_me:16414: checking for regular-expression headers" >&5 echo $ECHO_N "checking for regular-expression headers... $ECHO_C" >&6 if test "${cf_cv_regex_hdrs+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -15229,7 +16423,7 @@ for cf_regex_hdr in regexp.h regexpr.h do cat >conftest.$ac_ext <<_ACEOF -#line 15232 "configure" +#line 16426 "configure" #include "confdefs.h" #include <$cf_regex_hdr> int @@ -15244,16 +16438,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:15247: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16441: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:15250: \$? = $ac_status" >&5 + echo "$as_me:16444: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:15253: \"$ac_try\"") >&5 + { (eval echo "$as_me:16447: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:15256: \$? = $ac_status" >&5 + echo "$as_me:16450: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_regex_hdrs=$cf_regex_hdr @@ -15270,7 +16464,7 @@ for cf_regex_hdr in regex.h do cat >conftest.$ac_ext <<_ACEOF -#line 15273 "configure" +#line 16467 "configure" #include "confdefs.h" #include #include <$cf_regex_hdr> @@ -15288,16 +16482,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:15291: \"$ac_link\"") >&5 +if { (eval echo "$as_me:16485: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:15294: \$? = $ac_status" >&5 + echo "$as_me:16488: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:15297: \"$ac_try\"") >&5 + { (eval echo "$as_me:16491: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:15300: \$? = $ac_status" >&5 + echo "$as_me:16494: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_cv_regex_hdrs=$cf_regex_hdr @@ -15313,39 +16507,43 @@ esac fi -echo "$as_me:15316: result: $cf_cv_regex_hdrs" >&5 +echo "$as_me:16510: result: $cf_cv_regex_hdrs" >&5 echo "${ECHO_T}$cf_cv_regex_hdrs" >&6 case $cf_cv_regex_hdrs in #(vi - no) { echo "$as_me:15320: WARNING: no regular expression header found" >&5 + no) { echo "$as_me:16514: WARNING: no regular expression header found" >&5 echo "$as_me: WARNING: no regular expression header found" >&2;} ;; #(vi - regex.h) cat >>confdefs.h <<\EOF + regex.h) +cat >>confdefs.h <<\EOF #define HAVE_REGEX_H_FUNCS 1 EOF ;; #(vi - regexp.h) cat >>confdefs.h <<\EOF + regexp.h) +cat >>confdefs.h <<\EOF #define HAVE_REGEXP_H_FUNCS 1 EOF ;; #(vi - regexpr.h) cat >>confdefs.h <<\EOF + regexpr.h) +cat >>confdefs.h <<\EOF #define HAVE_REGEXPR_H_FUNCS 1 EOF ;; esac if test "X$cf_cv_regex_hdrs" != "Xregex.h" ; then - { { echo "$as_me:15337: error: Only POSIX or PCRE regular expressions are supported" >&5 + { { echo "$as_me:16534: error: Only POSIX or PCRE regular expressions are supported" >&5 echo "$as_me: error: Only POSIX or PCRE regular expressions are supported" >&2;} { (exit 1); exit 1; }; } fi fi - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_SELECT_REGEX 1 EOF fi -echo "$as_me:15348: checking if you want support for right-scrollbar" >&5 +echo "$as_me:16546: checking if you want support for right-scrollbar" >&5 echo $ECHO_N "checking if you want support for right-scrollbar... $ECHO_C" >&6 # Check whether --enable-rightbar or --disable-rightbar was given. @@ -15355,591 +16553,1173 @@ if test "$enableval" != "yes" ; then enable_rightbar=no else - enable_rightbar=yes + enable_rightbar=yes + fi +else + enableval=yes + enable_rightbar=yes + +fi; +echo "$as_me:16563: result: $enable_rightbar" >&5 +echo "${ECHO_T}$enable_rightbar" >&6 +if test "$enable_rightbar" = yes ; then + +cat >>confdefs.h <<\EOF +#define SCROLLBAR_RIGHT 1 +EOF + +fi + +echo "$as_me:16573: checking if you want check for redundant name-change" >&5 +echo $ECHO_N "checking if you want check for redundant name-change... $ECHO_C" >&6 + +# Check whether --enable-samename or --disable-samename was given. +if test "${enable_samename+set}" = set; then + enableval="$enable_samename" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_samename=no + else + enable_samename=yes + fi +else + enableval=yes + enable_samename=yes + +fi; +echo "$as_me:16590: result: $enable_samename" >&5 +echo "${ECHO_T}$enable_samename" >&6 +test "$enable_samename" = no && +cat >>confdefs.h <<\EOF +#define OPT_SAME_NAME 0 +EOF + +echo "$as_me:16597: checking if you want support for selection-actions" >&5 +echo $ECHO_N "checking if you want support for selection-actions... $ECHO_C" >&6 + +# Check whether --enable-selection-ops or --disable-selection-ops was given. +if test "${enable_selection_ops+set}" = set; then + enableval="$enable_selection_ops" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_selection_ops=no + else + enable_selection_ops=yes + fi +else + enableval=yes + enable_selection_ops=yes + +fi; +echo "$as_me:16614: result: $enable_selection_ops" >&5 +echo "${ECHO_T}$enable_selection_ops" >&6 +test "$enable_selection_ops" = no && +cat >>confdefs.h <<\EOF +#define OPT_SELECTION_OPS 0 +EOF + +echo "$as_me:16621: checking if you want support for session management" >&5 +echo $ECHO_N "checking if you want support for session management... $ECHO_C" >&6 + +# Check whether --enable-session-mgt or --disable-session-mgt was given. +if test "${enable_session_mgt+set}" = set; then + enableval="$enable_session_mgt" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_session_mgt=no + else + enable_session_mgt=yes + fi +else + enableval=yes + enable_session_mgt=yes + +fi; +echo "$as_me:16638: result: $enable_session_mgt" >&5 +echo "${ECHO_T}$enable_session_mgt" >&6 +test "$enable_session_mgt" = no && +cat >>confdefs.h <<\EOF +#define OPT_SESSION_MGT 0 +EOF + +echo "$as_me:16645: checking if you want to use termcap function-keys" >&5 +echo $ECHO_N "checking if you want to use termcap function-keys... $ECHO_C" >&6 + +# Check whether --enable-tcap-fkeys or --disable-tcap-fkeys was given. +if test "${enable_tcap_fkeys+set}" = set; then + enableval="$enable_tcap_fkeys" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_tcap_fkeys=no + else + enable_tcap_fkeys=yes + fi +else + enableval=yes + enable_tcap_fkeys=yes + +fi; +echo "$as_me:16662: result: $enable_tcap_fkeys" >&5 +echo "${ECHO_T}$enable_tcap_fkeys" >&6 +test "$enable_tcap_fkeys" = yes && +cat >>confdefs.h <<\EOF +#define OPT_TCAP_FKEYS 1 +EOF + +echo "$as_me:16669: checking if you want to use termcap-query/report" >&5 +echo $ECHO_N "checking if you want to use termcap-query/report... $ECHO_C" >&6 + +# Check whether --enable-tcap-query or --disable-tcap-query was given. +if test "${enable_tcap_query+set}" = set; then + enableval="$enable_tcap_query" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_tcap_query=no + else + enable_tcap_query=yes + fi +else + enableval=yes + enable_tcap_query=yes + +fi; +echo "$as_me:16686: result: $enable_tcap_query" >&5 +echo "${ECHO_T}$enable_tcap_query" >&6 +test "$enable_tcap_query" = yes && +cat >>confdefs.h <<\EOF +#define OPT_TCAP_QUERY 1 +EOF + +echo "$as_me:16693: checking if you want support for tek4014" >&5 +echo $ECHO_N "checking if you want support for tek4014... $ECHO_C" >&6 + +# Check whether --enable-tek4014 or --disable-tek4014 was given. +if test "${enable_tek4014+set}" = set; then + enableval="$enable_tek4014" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_tek4014=no + else + enable_tek4014=yes + fi +else + enableval=yes + enable_tek4014=yes + +fi; +echo "$as_me:16710: result: $enable_tek4014" >&5 +echo "${ECHO_T}$enable_tek4014" >&6 +if test "$enable_tek4014" = no ; then + +cat >>confdefs.h <<\EOF +#define OPT_TEK4014 0 +EOF + +else + EXTRAHDRS="$EXTRAHDRS Tekparse.h" + EXTRASRCS="$EXTRASRCS TekPrsTbl.c Tekproc.c" + EXTRAOBJS="$EXTRAOBJS TekPrsTbl.o Tekproc.o" +fi + +echo "$as_me:16724: checking if you want pulldown menus with a toolbar" >&5 +echo $ECHO_N "checking if you want pulldown menus with a toolbar... $ECHO_C" >&6 + +# Check whether --enable-toolbar or --disable-toolbar was given. +if test "${enable_toolbar+set}" = set; then + enableval="$enable_toolbar" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + enable_toolbar=yes + else + enable_toolbar=no + fi +else + enableval=no + enable_toolbar=no + +fi; +echo "$as_me:16741: result: $enable_toolbar" >&5 +echo "${ECHO_T}$enable_toolbar" >&6 +if test "$enable_toolbar" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_TOOLBAR 1 +EOF + +fi + +echo "$as_me:16751: checking if you want VT52 emulation" >&5 +echo $ECHO_N "checking if you want VT52 emulation... $ECHO_C" >&6 + +# Check whether --enable-vt52 or --disable-vt52 was given. +if test "${enable_vt52+set}" = set; then + enableval="$enable_vt52" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_vt52=no + else + enable_vt52=yes + fi +else + enableval=yes + enable_vt52=yes + +fi; +echo "$as_me:16768: result: $enable_vt52" >&5 +echo "${ECHO_T}$enable_vt52" >&6 +test "$enable_vt52" = no && +cat >>confdefs.h <<\EOF +#define OPT_VT52_MODE 0 +EOF + +echo "$as_me:16775: checking if you want wide-character support" >&5 +echo $ECHO_N "checking if you want wide-character support... $ECHO_C" >&6 + +# Check whether --enable-wide-chars or --disable-wide-chars was given. +if test "${enable_wide_chars+set}" = set; then + enableval="$enable_wide_chars" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_wchar=no + else + enable_wchar=yes + fi +else + enableval=yes + enable_wchar=yes + +fi; +echo "$as_me:16792: result: $enable_wchar" >&5 +echo "${ECHO_T}$enable_wchar" >&6 + +echo "$as_me:16795: checking if you want only 16-bit character support" >&5 +echo $ECHO_N "checking if you want only 16-bit character support... $ECHO_C" >&6 + +# Check whether --enable-16bit-chars or --disable-16bit-chars was given. +if test "${enable_16bit_chars+set}" = set; then + enableval="$enable_16bit_chars" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + enable_16bit_chars=yes + else + enable_16bit_chars=no + fi +else + enableval=no + enable_16bit_chars=no + +fi; +echo "$as_me:16812: result: $enable_16bit_chars" >&5 +echo "${ECHO_T}$enable_16bit_chars" >&6 + +if test "$enable_16bit_chars" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_WIDER_ICHAR 0 +EOF + + enable_wchar=yes +fi + +if test "$enable_wchar" = yes ; then + +echo "$as_me:16826: checking if you want to use mini-luit/Latin9 built-in support" >&5 +echo $ECHO_N "checking if you want to use mini-luit/Latin9 built-in support... $ECHO_C" >&6 + +# Check whether --enable-mini-luit or --disable-mini-luit was given. +if test "${enable_mini_luit+set}" = set; then + enableval="$enable_mini_luit" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + enable_mini_luit=yes + else + enable_mini_luit=no fi else - enableval=yes - enable_rightbar=yes + enableval=no + enable_mini_luit=no fi; -echo "$as_me:15365: result: $enable_rightbar" >&5 -echo "${ECHO_T}$enable_rightbar" >&6 -if test "$enable_rightbar" = yes ; then - cat >>confdefs.h <<\EOF -#define SCROLLBAR_RIGHT 1 +echo "$as_me:16843: result: $enable_mini_luit" >&5 +echo "${ECHO_T}$enable_mini_luit" >&6 +if test "$enable_mini_luit" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_MINI_LUIT 1 EOF fi -echo "$as_me:15374: checking if you want check for redundant name-change" >&5 -echo $ECHO_N "checking if you want check for redundant name-change... $ECHO_C" >&6 +echo "$as_me:16853: checking if you want to use luit" >&5 +echo $ECHO_N "checking if you want to use luit... $ECHO_C" >&6 -# Check whether --enable-samename or --disable-samename was given. -if test "${enable_samename+set}" = set; then - enableval="$enable_samename" +# Check whether --enable-luit or --disable-luit was given. +if test "${enable_luit+set}" = set; then + enableval="$enable_luit" test "$enableval" != no && enableval=yes if test "$enableval" != "yes" ; then - enable_samename=no + enable_luit=no else - enable_samename=yes + enable_luit=yes fi else enableval=yes - enable_samename=yes + enable_luit=yes fi; -echo "$as_me:15391: result: $enable_samename" >&5 -echo "${ECHO_T}$enable_samename" >&6 -test "$enable_samename" = no && cat >>confdefs.h <<\EOF -#define OPT_SAME_NAME 0 +echo "$as_me:16870: result: $enable_luit" >&5 +echo "${ECHO_T}$enable_luit" >&6 +if test "$enable_luit" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_LUIT_PROG 1 EOF -echo "$as_me:15397: checking if you want support for selection-actions" >&5 -echo $ECHO_N "checking if you want support for selection-actions... $ECHO_C" >&6 +test -z "$LUIT" && LUIT=xterm-filter +for ac_prog in $LUIT xterm-filter bluit luit +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +echo "$as_me:16883: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_path_LUIT+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + case $LUIT in + [\\/]* | ?:[\\/]*) + ac_cv_path_LUIT="$LUIT" # Let the user override the test with a path. + ;; + *) + ac_save_IFS=$IFS; IFS=$ac_path_separator +ac_dummy="$PATH" +for ac_dir in $ac_dummy; do + IFS=$ac_save_IFS + test -z "$ac_dir" && ac_dir=. + if $as_executable_p "$ac_dir/$ac_word"; then + ac_cv_path_LUIT="$ac_dir/$ac_word" + echo "$as_me:16900: found $ac_dir/$ac_word" >&5 + break +fi +done -# Check whether --enable-selection-ops or --disable-selection-ops was given. -if test "${enable_selection_ops+set}" = set; then - enableval="$enable_selection_ops" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - enable_selection_ops=no - else - enable_selection_ops=yes - fi + ;; +esac +fi +LUIT=$ac_cv_path_LUIT + +if test -n "$LUIT"; then + echo "$as_me:16911: result: $LUIT" >&5 +echo "${ECHO_T}$LUIT" >&6 else - enableval=yes - enable_selection_ops=yes + echo "$as_me:16914: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi -fi; -echo "$as_me:15414: result: $enable_selection_ops" >&5 -echo "${ECHO_T}$enable_selection_ops" >&6 -test "$enable_selection_ops" = no && cat >>confdefs.h <<\EOF -#define OPT_SELECTION_OPS 0 -EOF + test -n "$LUIT" && break +done +test -n "$LUIT" || LUIT="$LUIT" -echo "$as_me:15420: checking if you want support for session management" >&5 -echo $ECHO_N "checking if you want support for session management... $ECHO_C" >&6 +cf_path_prog="" +cf_path_args="" +IFS="${IFS:- }"; cf_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR" +for cf_temp in $ac_cv_path_LUIT +do + if test -z "$cf_path_prog" ; then + if test "$with_full_paths" = yes ; then -# Check whether --enable-session-mgt or --disable-session-mgt was given. -if test "${enable_session_mgt+set}" = set; then - enableval="$enable_session_mgt" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - enable_session_mgt=no - else - enable_session_mgt=yes - fi +if test "x$prefix" != xNONE; then + cf_path_syntax="$prefix" else - enableval=yes - enable_session_mgt=yes + cf_path_syntax="$ac_default_prefix" +fi -fi; -echo "$as_me:15437: result: $enable_session_mgt" >&5 -echo "${ECHO_T}$enable_session_mgt" >&6 -test "$enable_session_mgt" = no && cat >>confdefs.h <<\EOF -#define OPT_SESSION_MGT 0 +case ".$cf_temp" in #(vi +.\$\(*\)*|.\'*\'*) #(vi + ;; +..|./*|.\\*) #(vi + ;; +.[a-zA-Z]:[\\/]*) #(vi OS/2 EMX + ;; +.\${*prefix}*|.\${*dir}*) #(vi + eval cf_temp="$cf_temp" + case ".$cf_temp" in #(vi + .NONE/*) + cf_temp=`echo $cf_temp | sed -e s%NONE%$cf_path_syntax%` + ;; + esac + ;; #(vi +.no|.NONE/*) + cf_temp=`echo $cf_temp | sed -e s%NONE%$cf_path_syntax%` + ;; +*) + break + ;; +esac + + cf_path_prog="$cf_temp" + else + cf_path_prog="`basename $cf_temp`" + fi + elif test -z "$cf_path_args" ; then + cf_path_args="$cf_temp" + else + cf_path_args="$cf_path_args $cf_temp" + fi +done +IFS="$cf_save_ifs" + +if test -n "$cf_path_prog" ; then + +echo "${as_me:-configure}:16973: testing defining path for ${cf_path_prog} ..." 1>&5 + +cat >>confdefs.h <&5 -echo $ECHO_N "checking if you want to use termcap function-keys... $ECHO_C" >&6 + test -n "$cf_path_args" && +cat >>confdefs.h <&5 -echo "${ECHO_T}$enable_tcap_fkeys" >&6 -test "$enable_tcap_fkeys" = yes && cat >>confdefs.h <<\EOF -#define OPT_TCAP_FKEYS 1 +fi + +cat >>confdefs.h <<\EOF +#define OPT_WIDE_CHARS 1 EOF -echo "$as_me:15466: checking if you want to use termcap-query/report" >&5 -echo $ECHO_N "checking if you want to use termcap-query/report... $ECHO_C" >&6 + EXTRAHDRS="$EXTRAHDRS charclass.h precompose.h wcwidth.h" + EXTRASRCS="$EXTRASRCS charclass.c precompose.c wcwidth.c" + EXTRAOBJS="$EXTRAOBJS charclass.o precompose.o wcwidth.o" +fi -# Check whether --enable-tcap-query or --disable-tcap-query was given. -if test "${enable_tcap_query+set}" = set; then - enableval="$enable_tcap_query" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - enable_tcap_query=no +echo "$as_me:16997: checking if you want dynamic-abbreviation support" >&5 +echo $ECHO_N "checking if you want dynamic-abbreviation support... $ECHO_C" >&6 + +# Check whether --enable-dabbrev or --disable-dabbrev was given. +if test "${enable_dabbrev+set}" = set; then + enableval="$enable_dabbrev" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + enable_dabbrev=yes else - enable_tcap_query=yes + enable_dabbrev=no fi else - enableval=yes - enable_tcap_query=yes + enableval=no + enable_dabbrev=no fi; -echo "$as_me:15483: result: $enable_tcap_query" >&5 -echo "${ECHO_T}$enable_tcap_query" >&6 -test "$enable_tcap_query" = yes && cat >>confdefs.h <<\EOF -#define OPT_TCAP_QUERY 1 +echo "$as_me:17014: result: $enable_dabbrev" >&5 +echo "${ECHO_T}$enable_dabbrev" >&6 +if test "$enable_dabbrev" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_DABBREV 1 EOF -echo "$as_me:15489: checking if you want support for tek4014" >&5 -echo $ECHO_N "checking if you want support for tek4014... $ECHO_C" >&6 +fi -# Check whether --enable-tek4014 or --disable-tek4014 was given. -if test "${enable_tek4014+set}" = set; then - enableval="$enable_tek4014" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - enable_tek4014=no +echo "$as_me:17024: checking if you want DECterm Locator support" >&5 +echo $ECHO_N "checking if you want DECterm Locator support... $ECHO_C" >&6 + +# Check whether --enable-dec-locator or --disable-dec-locator was given. +if test "${enable_dec_locator+set}" = set; then + enableval="$enable_dec_locator" + test "$enableval" != yes && enableval=no + if test "$enableval" != "no" ; then + enable_dec_locator=yes else - enable_tek4014=yes + enable_dec_locator=no fi else - enableval=yes - enable_tek4014=yes + enableval=no + enable_dec_locator=no fi; -echo "$as_me:15506: result: $enable_tek4014" >&5 -echo "${ECHO_T}$enable_tek4014" >&6 -if test "$enable_tek4014" = no ; then - cat >>confdefs.h <<\EOF -#define OPT_TEK4014 0 +echo "$as_me:17041: result: $enable_dec_locator" >&5 +echo "${ECHO_T}$enable_dec_locator" >&6 +if test "$enable_dec_locator" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_DEC_LOCATOR 1 EOF -else - EXTRAHDRS="$EXTRAHDRS Tekparse.h" - EXTRASRCS="$EXTRASRCS TekPrsTbl.c Tekproc.c" - EXTRAOBJS="$EXTRAOBJS TekPrsTbl.o Tekproc.o" fi -echo "$as_me:15519: checking if you want pulldown menus with a toolbar" >&5 -echo $ECHO_N "checking if you want pulldown menus with a toolbar... $ECHO_C" >&6 +echo "$as_me:17051: checking if you want sixel graphics support" >&5 +echo $ECHO_N "checking if you want sixel graphics support... $ECHO_C" >&6 -# Check whether --enable-toolbar or --disable-toolbar was given. -if test "${enable_toolbar+set}" = set; then - enableval="$enable_toolbar" +# Check whether --enable-sixel-graphics or --disable-sixel-graphics was given. +if test "${enable_sixel_graphics+set}" = set; then + enableval="$enable_sixel_graphics" test "$enableval" != yes && enableval=no if test "$enableval" != "no" ; then - enable_toolbar=yes + enable_sixel_graphics=yes else - enable_toolbar=no + enable_sixel_graphics=no fi else enableval=no - enable_toolbar=no + enable_sixel_graphics=no fi; -echo "$as_me:15536: result: $enable_toolbar" >&5 -echo "${ECHO_T}$enable_toolbar" >&6 -if test "$enable_toolbar" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_TOOLBAR 1 +echo "$as_me:17068: result: $enable_sixel_graphics" >&5 +echo "${ECHO_T}$enable_sixel_graphics" >&6 +if test "$enable_sixel_graphics" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_SIXEL_GRAPHICS 1 EOF + EXTRAHDRS="$EXTRAHDRS graphics.h" + EXTRASRCS="$EXTRASRCS graphics.c" + EXTRAOBJS="$EXTRAOBJS graphics.o" fi -echo "$as_me:15545: checking if you want VT52 emulation" >&5 -echo $ECHO_N "checking if you want VT52 emulation... $ECHO_C" >&6 +echo "$as_me:17081: checking if you want VT420 rectangle support" >&5 +echo $ECHO_N "checking if you want VT420 rectangle support... $ECHO_C" >&6 -# Check whether --enable-vt52 or --disable-vt52 was given. -if test "${enable_vt52+set}" = set; then - enableval="$enable_vt52" +# Check whether --enable-rectangles or --disable-rectangles was given. +if test "${enable_rectangles+set}" = set; then + enableval="$enable_rectangles" test "$enableval" != no && enableval=yes if test "$enableval" != "yes" ; then - enable_vt52=no + enable_rectangles=no else - enable_vt52=yes + enable_rectangles=yes fi else enableval=yes - enable_vt52=yes + enable_rectangles=yes fi; -echo "$as_me:15562: result: $enable_vt52" >&5 -echo "${ECHO_T}$enable_vt52" >&6 -test "$enable_vt52" = no && cat >>confdefs.h <<\EOF -#define OPT_VT52_MODE 0 +echo "$as_me:17098: result: $enable_rectangles" >&5 +echo "${ECHO_T}$enable_rectangles" >&6 +if test "$enable_rectangles" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_DEC_RECTOPS 1 EOF -echo "$as_me:15568: checking if you want to use mini-luit/Latin9 built-in support" >&5 -echo $ECHO_N "checking if you want to use mini-luit/Latin9 built-in support... $ECHO_C" >&6 +fi -# Check whether --enable-mini-luit or --disable-mini-luit was given. -if test "${enable_mini_luit+set}" = set; then - enableval="$enable_mini_luit" - test "$enableval" != yes && enableval=no - if test "$enableval" != "no" ; then - enable_mini_luit=yes +echo "$as_me:17108: checking if you want -ziconbeep option" >&5 +echo $ECHO_N "checking if you want -ziconbeep option... $ECHO_C" >&6 + +# Check whether --enable-ziconbeep or --disable-ziconbeep was given. +if test "${enable_ziconbeep+set}" = set; then + enableval="$enable_ziconbeep" + test "$enableval" != no && enableval=yes + if test "$enableval" != "yes" ; then + enable_ziconbeep=no else - enable_mini_luit=no + enable_ziconbeep=yes fi else - enableval=no - enable_mini_luit=no + enableval=yes + enable_ziconbeep=yes fi; -echo "$as_me:15585: result: $enable_mini_luit" >&5 -echo "${ECHO_T}$enable_mini_luit" >&6 -if test "$enable_mini_luit" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_MINI_LUIT 1 +echo "$as_me:17125: result: $enable_ziconbeep" >&5 +echo "${ECHO_T}$enable_ziconbeep" >&6 +test "$enable_ziconbeep" = no && +cat >>confdefs.h <<\EOF +#define OPT_ZICONBEEP 0 EOF -fi +############################################################################### -echo "$as_me:15594: checking if you want to use luit" >&5 -echo $ECHO_N "checking if you want to use luit... $ECHO_C" >&6 +echo "$as_me:17134: checking if you want debugging traces" >&5 +echo $ECHO_N "checking if you want debugging traces... $ECHO_C" >&6 -# Check whether --enable-luit or --disable-luit was given. -if test "${enable_luit+set}" = set; then - enableval="$enable_luit" +# Check whether --enable-trace or --disable-trace was given. +if test "${enable_trace+set}" = set; then + enableval="$enable_trace" test "$enableval" != yes && enableval=no if test "$enableval" != "no" ; then - enable_luit=yes + enable_trace=yes else - enable_luit=$enable_mini_luit + enable_trace=no fi else enableval=no - enable_luit=$enable_mini_luit + enable_trace=no fi; -echo "$as_me:15611: result: $enable_luit" >&5 -echo "${ECHO_T}$enable_luit" >&6 -if test "$enable_luit" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_LUIT_PROG 1 +echo "$as_me:17151: result: $enable_trace" >&5 +echo "${ECHO_T}$enable_trace" >&6 +if test "$enable_trace" = yes ; then + +cat >>confdefs.h <<\EOF +#define OPT_TRACE 1 EOF -test -z "$LUIT" && LUIT=xterm-filter -for ac_prog in $LUIT xterm-filter bluit luit -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -echo "$as_me:15623: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 -if test "${ac_cv_path_LUIT+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - case $LUIT in - [\\/]* | ?:[\\/]*) - ac_cv_path_LUIT="$LUIT" # Let the user override the test with a path. - ;; - *) - ac_save_IFS=$IFS; IFS=$ac_path_separator -ac_dummy="$PATH" -for ac_dir in $ac_dummy; do - IFS=$ac_save_IFS - test -z "$ac_dir" && ac_dir=. - if $as_executable_p "$ac_dir/$ac_word"; then - ac_cv_path_LUIT="$ac_dir/$ac_word" - echo "$as_me:15640: found $ac_dir/$ac_word" >&5 - break + EXTRASRCS="$EXTRASRCS trace.c" + EXTRAOBJS="$EXTRAOBJS trace.o" fi -done - ;; +echo "$as_me:17163: checking if you want to use dmalloc for testing" >&5 +echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6 + +# Check whether --with-dmalloc or --without-dmalloc was given. +if test "${with_dmalloc+set}" = set; then + withval="$with_dmalloc" + +cat >>confdefs.h <&5 +echo "${ECHO_T}${with_dmalloc:-no}" >&6 + +case .$with_cflags in #(vi +.*-g*) + case .$CFLAGS in #(vi + .*-g*) #(vi + ;; + *) + +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= +cf_new_extra_cppflags= + +for cf_add_cflags in -g +do +case $cf_fix_cppflags in +no) + case $cf_add_cflags in #(vi + -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi + case $cf_add_cflags in + -D*) + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=yes + + if test $cf_fix_cppflags = yes ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + elif test "${cf_tst_cflags}" = "\"'" ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + fi + ;; + esac + case "$CPPFLAGS" in + *$cf_add_cflags) #(vi + ;; + *) #(vi + case $cf_add_cflags in #(vi + -D*) + cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` + +CPPFLAGS=`echo "$CPPFLAGS" | \ + sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` + + ;; + esac + cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" + ;; + esac + ;; + *) + cf_new_cflags="$cf_new_cflags $cf_add_cflags" + ;; + esac + ;; +yes) + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; esac +done + +if test -n "$cf_new_cflags" ; then + + CFLAGS="$CFLAGS $cf_new_cflags" fi -LUIT=$ac_cv_path_LUIT -if test -n "$LUIT"; then - echo "$as_me:15651: result: $LUIT" >&5 -echo "${ECHO_T}$LUIT" >&6 -else - echo "$as_me:15654: result: no" >&5 -echo "${ECHO_T}no" >&6 +if test -n "$cf_new_cppflags" ; then + + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" fi - test -n "$LUIT" && break -done -test -n "$LUIT" || LUIT="$LUIT" +if test -n "$cf_new_extra_cppflags" ; then -cf_path_prog="" -cf_path_args="" -IFS="${IFS:- }"; cf_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR" -for cf_temp in $ac_cv_path_LUIT -do - if test -z "$cf_path_prog" ; then - if test "$with_full_paths" = yes ; then + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" +fi -if test "x$prefix" != xNONE; then - cf_path_syntax="$prefix" + ;; + esac + ;; +esac + +if test "$with_dmalloc" = yes ; then + echo "$as_me:17274: checking for dmalloc.h" >&5 +echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6 +if test "${ac_cv_header_dmalloc_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 17280 "configure" +#include "confdefs.h" +#include +_ACEOF +if { (eval echo "$as_me:17284: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:17290: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag + else + ac_cpp_err= + fi +else + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + ac_cv_header_dmalloc_h=yes +else + echo "$as_me: failed program was:" >&5 + cat conftest.$ac_ext >&5 + ac_cv_header_dmalloc_h=no +fi +rm -f conftest.err conftest.$ac_ext +fi +echo "$as_me:17309: result: $ac_cv_header_dmalloc_h" >&5 +echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6 +if test $ac_cv_header_dmalloc_h = yes; then + +echo "$as_me:17313: checking for dmalloc_debug in -ldmalloc" >&5 +echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6 +if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldmalloc $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line 17321 "configure" +#include "confdefs.h" + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dmalloc_debug (); +int +main () +{ +dmalloc_debug (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:17340: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:17343: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:17346: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:17349: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_dmalloc_dmalloc_debug=yes else - cf_path_syntax="$ac_default_prefix" + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_dmalloc_dmalloc_debug=no fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:17360: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5 +echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6 +if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then + cat >>confdefs.h <&5 +fi - cat >>confdefs.h <&5 +echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6 - test -n "$cf_path_args" && cat >>confdefs.h <>confdefs.h <&5 +echo "${ECHO_T}${with_dbmalloc:-no}" >&6 -fi +case .$with_cflags in #(vi +.*-g*) + case .$CFLAGS in #(vi + .*-g*) #(vi + ;; + *) -echo "$as_me:15727: checking if you want wide-character support" >&5 -echo $ECHO_N "checking if you want wide-character support... $ECHO_C" >&6 +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= +cf_new_extra_cppflags= -# Check whether --enable-wide-chars or --disable-wide-chars was given. -if test "${enable_wide_chars+set}" = set; then - enableval="$enable_wide_chars" - test "$enableval" != no && enableval=yes - if test "$enableval" != "$enable_luit" ; then - enable_wchar=yes - else - enable_wchar=$enable_luit - fi -else - enableval=$enable_luit - enable_wchar=$enable_luit +for cf_add_cflags in -g +do +case $cf_fix_cppflags in +no) + case $cf_add_cflags in #(vi + -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi + case $cf_add_cflags in + -D*) + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` -fi; -echo "$as_me:15744: result: $enable_wchar" >&5 -echo "${ECHO_T}$enable_wchar" >&6 + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=yes -echo "$as_me:15747: checking if you want only 16-bit character support" >&5 -echo $ECHO_N "checking if you want only 16-bit character support... $ECHO_C" >&6 + if test $cf_fix_cppflags = yes ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + elif test "${cf_tst_cflags}" = "\"'" ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + fi + ;; + esac + case "$CPPFLAGS" in + *$cf_add_cflags) #(vi + ;; + *) #(vi + case $cf_add_cflags in #(vi + -D*) + cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` -# Check whether --enable-16bit-chars or --disable-16bit-chars was given. -if test "${enable_16bit_chars+set}" = set; then - enableval="$enable_16bit_chars" - test "$enableval" != yes && enableval=no - if test "$enableval" != "no" ; then - enable_16bit_chars=yes - else - enable_16bit_chars=no - fi -else - enableval=no - enable_16bit_chars=no +CPPFLAGS=`echo "$CPPFLAGS" | \ + sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` -fi; -echo "$as_me:15764: result: $enable_16bit_chars" >&5 -echo "${ECHO_T}$enable_16bit_chars" >&6 + ;; + esac + cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" + ;; + esac + ;; + *) + cf_new_cflags="$cf_new_cflags $cf_add_cflags" + ;; + esac + ;; +yes) + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" -if test "$enable_16bit_chars" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_WIDER_ICHAR 0 -EOF + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` - enable_wchar=yes -fi + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; +esac +done -if test "$enable_wchar" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_WIDE_CHARS 1 -EOF +if test -n "$cf_new_cflags" ; then - EXTRAHDRS="$EXTRAHDRS charclass.h precompose.h wcwidth.h" - EXTRASRCS="$EXTRASRCS charclass.c precompose.c wcwidth.c" - EXTRAOBJS="$EXTRAOBJS charclass.o precompose.o wcwidth.o" + CFLAGS="$CFLAGS $cf_new_cflags" fi -echo "$as_me:15785: checking if you want dynamic-abbreviation support" >&5 -echo $ECHO_N "checking if you want dynamic-abbreviation support... $ECHO_C" >&6 +if test -n "$cf_new_cppflags" ; then -# Check whether --enable-dabbrev or --disable-dabbrev was given. -if test "${enable_dabbrev+set}" = set; then - enableval="$enable_dabbrev" - test "$enableval" != yes && enableval=no - if test "$enableval" != "no" ; then - enable_dabbrev=yes - else - enable_dabbrev=no - fi -else - enableval=no - enable_dabbrev=no + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" +fi -fi; -echo "$as_me:15802: result: $enable_dabbrev" >&5 -echo "${ECHO_T}$enable_dabbrev" >&6 -if test "$enable_dabbrev" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_DABBREV 1 -EOF +if test -n "$cf_new_extra_cppflags" ; then + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" fi -echo "$as_me:15811: checking if you want DECterm Locator support" >&5 -echo $ECHO_N "checking if you want DECterm Locator support... $ECHO_C" >&6 + ;; + esac + ;; +esac -# Check whether --enable-dec-locator or --disable-dec-locator was given. -if test "${enable_dec_locator+set}" = set; then - enableval="$enable_dec_locator" - test "$enableval" != yes && enableval=no - if test "$enableval" != "no" ; then - enable_dec_locator=yes +if test "$with_dbmalloc" = yes ; then + echo "$as_me:17486: checking for dbmalloc.h" >&5 +echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6 +if test "${ac_cv_header_dbmalloc_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line 17492 "configure" +#include "confdefs.h" +#include +_ACEOF +if { (eval echo "$as_me:17496: \"$ac_cpp conftest.$ac_ext\"") >&5 + (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + egrep -v '^ *\+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:17502: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null; then + if test -s conftest.err; then + ac_cpp_err=$ac_c_preproc_warn_flag else - enable_dec_locator=no + ac_cpp_err= fi else - enableval=no - enable_dec_locator=no + ac_cpp_err=yes +fi +if test -z "$ac_cpp_err"; then + ac_cv_header_dbmalloc_h=yes +else + echo "$as_me: failed program was:" >&5 + cat conftest.$ac_ext >&5 + ac_cv_header_dbmalloc_h=no +fi +rm -f conftest.err conftest.$ac_ext +fi +echo "$as_me:17521: result: $ac_cv_header_dbmalloc_h" >&5 +echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6 +if test $ac_cv_header_dbmalloc_h = yes; then + +echo "$as_me:17525: checking for debug_malloc in -ldbmalloc" >&5 +echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6 +if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldbmalloc $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line 17533 "configure" +#include "confdefs.h" -fi; -echo "$as_me:15828: result: $enable_dec_locator" >&5 -echo "${ECHO_T}$enable_dec_locator" >&6 -if test "$enable_dec_locator" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_DEC_LOCATOR 1 +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char debug_malloc (); +int +main () +{ +debug_malloc (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:17552: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:17555: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:17558: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:17561: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_dbmalloc_debug_malloc=yes +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +ac_cv_lib_dbmalloc_debug_malloc=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:17572: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5 +echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6 +if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then + cat >>confdefs.h <&5 -echo $ECHO_N "checking if you want VT420 rectangle support... $ECHO_C" >&6 +fi -# Check whether --enable-rectangles or --disable-rectangles was given. -if test "${enable_rectangles+set}" = set; then - enableval="$enable_rectangles" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - enable_rectangles=no - else - enable_rectangles=yes - fi -else - enableval=yes - enable_rectangles=yes +fi -fi; -echo "$as_me:15854: result: $enable_rectangles" >&5 -echo "${ECHO_T}$enable_rectangles" >&6 -if test "$enable_rectangles" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_DEC_RECTOPS 1 -EOF +echo "$as_me:17587: checking if you want to use valgrind for testing" >&5 +echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6 -fi +# Check whether --with-valgrind or --without-valgrind was given. +if test "${with_valgrind+set}" = set; then + withval="$with_valgrind" -echo "$as_me:15863: checking if you want -ziconbeep option" >&5 -echo $ECHO_N "checking if you want -ziconbeep option... $ECHO_C" >&6 +cat >>confdefs.h <&5 -echo "${ECHO_T}$enable_ziconbeep" >&6 -test "$enable_ziconbeep" = no && cat >>confdefs.h <<\EOF -#define OPT_ZICONBEEP 0 -EOF +echo "$as_me:17604: result: ${with_valgrind:-no}" >&5 +echo "${ECHO_T}${with_valgrind:-no}" >&6 -############################################################################### +case .$with_cflags in #(vi +.*-g*) + case .$CFLAGS in #(vi + .*-g*) #(vi + ;; + *) -echo "$as_me:15888: checking if you want debugging traces" >&5 -echo $ECHO_N "checking if you want debugging traces... $ECHO_C" >&6 +cf_fix_cppflags=no +cf_new_cflags= +cf_new_cppflags= +cf_new_extra_cppflags= -# Check whether --enable-trace or --disable-trace was given. -if test "${enable_trace+set}" = set; then - enableval="$enable_trace" - test "$enableval" != yes && enableval=no - if test "$enableval" != "no" ; then - enable_trace=yes - else - enable_trace=no - fi -else - enableval=no - enable_trace=no +for cf_add_cflags in -g +do +case $cf_fix_cppflags in +no) + case $cf_add_cflags in #(vi + -undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) #(vi + case $cf_add_cflags in + -D*) + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` -fi; -echo "$as_me:15905: result: $enable_trace" >&5 -echo "${ECHO_T}$enable_trace" >&6 -if test "$enable_trace" = yes ; then - cat >>confdefs.h <<\EOF -#define OPT_TRACE 1 -EOF + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=yes - EXTRASRCS="$EXTRASRCS trace.c" - EXTRAOBJS="$EXTRAOBJS trace.o" + if test $cf_fix_cppflags = yes ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + elif test "${cf_tst_cflags}" = "\"'" ; then + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + continue + fi + ;; + esac + case "$CPPFLAGS" in + *$cf_add_cflags) #(vi + ;; + *) #(vi + case $cf_add_cflags in #(vi + -D*) + cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` + +CPPFLAGS=`echo "$CPPFLAGS" | \ + sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ + -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` + + ;; + esac + cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" + ;; + esac + ;; + *) + cf_new_cflags="$cf_new_cflags $cf_add_cflags" + ;; + esac + ;; +yes) + cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" + + cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` + + test "${cf_add_cflags}" != "${cf_tst_cflags}" \ + && test -z "${cf_tst_cflags}" \ + && cf_fix_cppflags=no + ;; +esac +done + +if test -n "$cf_new_cflags" ; then + + CFLAGS="$CFLAGS $cf_new_cflags" +fi + +if test -n "$cf_new_cppflags" ; then + + CPPFLAGS="$CPPFLAGS $cf_new_cppflags" +fi + +if test -n "$cf_new_extra_cppflags" ; then + + EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" fi -echo "$as_me:15916: checking if you want to test memory leaks" >&5 -echo $ECHO_N "checking if you want to test memory leaks... $ECHO_C" >&6 + ;; + esac + ;; +esac + +echo "$as_me:17697: checking if you want to perform memory-leak testing" >&5 +echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6 # Check whether --enable-leaks or --disable-leaks was given. if test "${enable_leaks+set}" = set; then enableval="$enable_leaks" - test "$enableval" != no && enableval=yes - if test "$enableval" != "yes" ; then - disable_leaks=yes - else - disable_leaks=no - fi + if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi else - enableval=yes - disable_leaks=no - + : ${with_no_leaks:=no} fi; -echo "$as_me:15933: result: $disable_leaks" >&5 -echo "${ECHO_T}$disable_leaks" >&6 -if test "$disable_leaks" = yes ; then - cat >>confdefs.h <<\EOF +echo "$as_me:17707: result: $with_no_leaks" >&5 +echo "${ECHO_T}$with_no_leaks" >&6 + +if test "$with_no_leaks" = yes ; then + +cat >>confdefs.h <<\EOF #define NO_LEAKS 1 EOF +cat >>confdefs.h <<\EOF +#define YY_NO_LEAKS 1 +EOF + fi -echo "$as_me:15942: checking if you want to see long compiling messages" >&5 +echo "$as_me:17722: checking if you want to see long compiling messages" >&5 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6 # Check whether --enable-echo or --disable-echo was given. @@ -15973,10 +17753,10 @@ ECHO_CC='' fi; -echo "$as_me:15976: result: $enableval" >&5 +echo "$as_me:17756: result: $enableval" >&5 echo "${ECHO_T}$enableval" >&6 -echo "$as_me:15979: checking if you want magic cookie emulation" >&5 +echo "$as_me:17759: checking if you want magic cookie emulation" >&5 echo $ECHO_N "checking if you want magic cookie emulation... $ECHO_C" >&6 # Check whether --enable-xmc-glitch or --disable-xmc-glitch was given. @@ -15993,10 +17773,11 @@ enable_xmc=no fi; -echo "$as_me:15996: result: $enable_xmc" >&5 +echo "$as_me:17776: result: $enable_xmc" >&5 echo "${ECHO_T}$enable_xmc" >&6 if test "$enable_xmc" = yes ; then - cat >>confdefs.h <<\EOF + +cat >>confdefs.h <<\EOF #define OPT_XMC_GLITCH 1 EOF @@ -16007,13 +17788,13 @@ for ac_func in tigetstr do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` -echo "$as_me:16010: checking for $ac_func" >&5 +echo "$as_me:17791: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 16016 "configure" +#line 17797 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. */ @@ -16036,7 +17817,7 @@ #if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -f = $ac_func; +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -16044,16 +17825,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:16047: \"$ac_link\"") >&5 +if { (eval echo "$as_me:17828: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:16050: \$? = $ac_status" >&5 + echo "$as_me:17831: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:16053: \"$ac_try\"") >&5 + { (eval echo "$as_me:17834: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:16056: \$? = $ac_status" >&5 + echo "$as_me:17837: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_var=yes" else @@ -16063,7 +17844,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:16066: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "$as_me:17847: result: `eval echo '${'$as_ac_var'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <&5 +echo "$as_me:17862: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 if eval "test \"\${$as_ac_var+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF -#line 16087 "configure" +#line 17868 "configure" #include "confdefs.h" /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. */ @@ -16107,7 +17888,7 @@ #if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -f = $ac_func; +f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; #endif ; @@ -16115,16 +17896,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:16118: \"$ac_link\"") >&5 +if { (eval echo "$as_me:17899: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:16121: \$? = $ac_status" >&5 + echo "$as_me:17902: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:16124: \"$ac_try\"") >&5 + { (eval echo "$as_me:17905: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:16127: \$? = $ac_status" >&5 + echo "$as_me:17908: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_var=yes" else @@ -16134,7 +17915,7 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext fi -echo "$as_me:16137: result: `eval echo '${'$as_ac_var'}'`" >&5 +echo "$as_me:17918: result: `eval echo '${'$as_ac_var'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <&5 +echo "$as_me:17931: checking if you want to turn on gcc warnings" >&5 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6 # Check whether --enable-warnings or --disable-warnings was given. @@ -16164,7 +17945,7 @@ with_warnings=no fi; -echo "$as_me:16167: result: $with_warnings" >&5 +echo "$as_me:17948: result: $with_warnings" >&5 echo "${ECHO_T}$with_warnings" >&6 if test "$with_warnings" = yes then @@ -16187,10 +17968,10 @@ EOF if test "$GCC" = yes then - { echo "$as_me:16190: checking for $CC __attribute__ directives..." >&5 + { echo "$as_me:17971: checking for $CC __attribute__ directives..." >&5 echo "$as_me: checking for $CC __attribute__ directives..." >&6;} cat > conftest.$ac_ext <&5 + if { (eval echo "$as_me:18023: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:16245: \$? = $ac_status" >&5 + echo "$as_me:18026: \$? = $ac_status" >&5 (exit $ac_status); }; then - test -n "$verbose" && echo "$as_me:16247: result: ... $cf_attribute" >&5 + test -n "$verbose" && echo "$as_me:18028: result: ... $cf_attribute" >&5 echo "${ECHO_T}... $cf_attribute" >&6 cat conftest.h >>confdefs.h case $cf_attribute in #(vi - printf) #(vi - if test "$cf_printf_attribute" = no ; then - cat >>confdefs.h <>confdefs.h <>confdefs.h <>confdefs.h <<\EOF +#define GCC_PRINTF 1 EOF + fi + +cat >>confdefs.h <>confdefs.h <>confdefs.h <>confdefs.h <<\EOF +#define GCC_SCANF 1 EOF + fi + +cat >>confdefs.h <>confdefs.h <&5 -echo $ECHO_N "checking version of $CC... $ECHO_C" >&6 - GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`" - test -z "$GCC_VERSION" && GCC_VERSION=unknown - echo "$as_me:16288: result: $GCC_VERSION" >&5 -echo "${ECHO_T}$GCC_VERSION" >&6 -fi - INTEL_COMPILER=no if test "$GCC" = yes ; then case $host_os in linux*|gnu*) - echo "$as_me:16297: checking if this is really Intel C compiler" >&5 + echo "$as_me:18092: checking if this is really Intel C compiler" >&5 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6 cf_save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -no-gcc" cat >conftest.$ac_ext <<_ACEOF -#line 16302 "configure" +#line 18097 "configure" #include "confdefs.h" int @@ -16316,16 +18111,16 @@ } _ACEOF rm -f conftest.$ac_objext -if { (eval echo "$as_me:16319: \"$ac_compile\"") >&5 +if { (eval echo "$as_me:18114: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:16322: \$? = $ac_status" >&5 + echo "$as_me:18117: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:16325: \"$ac_try\"") >&5 + { (eval echo "$as_me:18120: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:16328: \$? = $ac_status" >&5 + echo "$as_me:18123: \$? = $ac_status" >&5 (exit $ac_status); }; }; then INTEL_COMPILER=yes cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc" @@ -16336,14 +18131,63 @@ fi rm -f conftest.$ac_objext conftest.$ac_ext CFLAGS="$cf_save_CFLAGS" - echo "$as_me:16339: result: $INTEL_COMPILER" >&5 + echo "$as_me:18134: result: $INTEL_COMPILER" >&5 echo "${ECHO_T}$INTEL_COMPILER" >&6 ;; esac fi +CLANG_COMPILER=no + +if test "$GCC" = yes ; then + echo "$as_me:18143: checking if this is really Clang C compiler" >&5 +echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6 + cf_save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Qunused-arguments" + cat >conftest.$ac_ext <<_ACEOF +#line 18148 "configure" +#include "confdefs.h" + +int +main () +{ + +#ifdef __clang__ +#else +make an error +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:18165: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:18168: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:18171: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:18174: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + CLANG_COMPILER=yes +cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments" + +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +fi +rm -f conftest.$ac_objext conftest.$ac_ext + CFLAGS="$cf_save_CFLAGS" + echo "$as_me:18185: result: $CLANG_COMPILER" >&5 +echo "${ECHO_T}$CLANG_COMPILER" >&6 +fi + cat > conftest.$ac_ext <&5 + { echo "$as_me:18207: checking for $CC warning options..." >&5 echo "$as_me: checking for $CC warning options..." >&6;} cf_save_CFLAGS="$CFLAGS" EXTRA_CFLAGS="-Wall" @@ -16376,12 +18220,12 @@ wd981 do CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt" - if { (eval echo "$as_me:16379: \"$ac_compile\"") >&5 + if { (eval echo "$as_me:18223: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:16382: \$? = $ac_status" >&5 + echo "$as_me:18226: \$? = $ac_status" >&5 (exit $ac_status); }; then - test -n "$verbose" && echo "$as_me:16384: result: ... -$cf_opt" >&5 + test -n "$verbose" && echo "$as_me:18228: result: ... -$cf_opt" >&5 echo "${ECHO_T}... -$cf_opt" >&6 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt" fi @@ -16390,7 +18234,7 @@ elif test "$GCC" = yes then - { echo "$as_me:16393: checking for $CC warning options..." >&5 + { echo "$as_me:18237: checking for $CC warning options..." >&5 echo "$as_me: checking for $CC warning options..." >&6;} cf_save_CFLAGS="$CFLAGS" EXTRA_CFLAGS= @@ -16410,12 +18254,12 @@ Wundef $cf_warn_CONST Wdeclaration-after-statement Wextra Wno-unknown-pragmas Wswitch-enum do CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt" - if { (eval echo "$as_me:16413: \"$ac_compile\"") >&5 + if { (eval echo "$as_me:18257: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? - echo "$as_me:16416: \$? = $ac_status" >&5 + echo "$as_me:18260: \$? = $ac_status" >&5 (exit $ac_status); }; then - test -n "$verbose" && echo "$as_me:16418: result: ... -$cf_opt" >&5 + test -n "$verbose" && echo "$as_me:18262: result: ... -$cf_opt" >&5 echo "${ECHO_T}... -$cf_opt" >&6 case $cf_opt in #(vi Wcast-qual) #(vi @@ -16426,7 +18270,17 @@ [34].*) test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6 -echo "${as_me:-configure}:16429: testing feature is broken in gcc $GCC_VERSION ..." 1>&5 +echo "${as_me:-configure}:18273: testing feature is broken in gcc $GCC_VERSION ..." 1>&5 + + continue;; + esac + ;; + Wpointer-arith) #(vi + case $GCC_VERSION in + [12].*) + test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6 + +echo "${as_me:-configure}:18283: testing feature is broken in gcc $GCC_VERSION ..." 1>&5 continue;; esac @@ -16442,11 +18296,13 @@ fi fi -test "$disable_setuid" = yes && cat >>confdefs.h <<\EOF +test "$disable_setuid" = yes && +cat >>confdefs.h <<\EOF #define DISABLE_SETUID 1 EOF -test "$disable_setgid" = yes && cat >>confdefs.h <<\EOF +test "$disable_setgid" = yes && +cat >>confdefs.h <<\EOF #define DISABLE_SETGID 1 EOF @@ -16477,7 +18333,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | sed -e s/-D$cf_def//` done -echo "$as_me:16480: checking if filesystem supports mixed-case filenames" >&5 +echo "$as_me:18336: checking if filesystem supports mixed-case filenames" >&5 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6 if test "${cf_cv_mixedcase+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -16504,9 +18360,10 @@ fi fi -echo "$as_me:16507: result: $cf_cv_mixedcase" >&5 +echo "$as_me:18363: result: $cf_cv_mixedcase" >&5 echo "${ECHO_T}$cf_cv_mixedcase" >&6 -test "$cf_cv_mixedcase" = yes && cat >>confdefs.h <<\EOF +test "$cf_cv_mixedcase" = yes && +cat >>confdefs.h <<\EOF #define MIXEDCASE_FILENAMES 1 EOF @@ -16514,7 +18371,7 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:16517: checking for $ac_word" >&5 +echo "$as_me:18374: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CTAGS+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -16529,7 +18386,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_CTAGS="$ac_prog" -echo "$as_me:16532: found $ac_dir/$ac_word" >&5 +echo "$as_me:18389: found $ac_dir/$ac_word" >&5 break done @@ -16537,10 +18394,10 @@ fi CTAGS=$ac_cv_prog_CTAGS if test -n "$CTAGS"; then - echo "$as_me:16540: result: $CTAGS" >&5 + echo "$as_me:18397: result: $CTAGS" >&5 echo "${ECHO_T}$CTAGS" >&6 else - echo "$as_me:16543: result: no" >&5 + echo "$as_me:18400: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -16551,7 +18408,7 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:16554: checking for $ac_word" >&5 +echo "$as_me:18411: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ETAGS+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -16566,7 +18423,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_ETAGS="$ac_prog" -echo "$as_me:16569: found $ac_dir/$ac_word" >&5 +echo "$as_me:18426: found $ac_dir/$ac_word" >&5 break done @@ -16574,10 +18431,10 @@ fi ETAGS=$ac_cv_prog_ETAGS if test -n "$ETAGS"; then - echo "$as_me:16577: result: $ETAGS" >&5 + echo "$as_me:18434: result: $ETAGS" >&5 echo "${ECHO_T}$ETAGS" >&6 else - echo "$as_me:16580: result: no" >&5 + echo "$as_me:18437: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -16586,7 +18443,7 @@ # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args. set dummy ${CTAGS:-ctags}; ac_word=$2 -echo "$as_me:16589: checking for $ac_word" >&5 +echo "$as_me:18446: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -16601,7 +18458,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_MAKE_LOWER_TAGS="yes" -echo "$as_me:16604: found $ac_dir/$ac_word" >&5 +echo "$as_me:18461: found $ac_dir/$ac_word" >&5 break done @@ -16610,17 +18467,17 @@ fi MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS if test -n "$MAKE_LOWER_TAGS"; then - echo "$as_me:16613: result: $MAKE_LOWER_TAGS" >&5 + echo "$as_me:18470: result: $MAKE_LOWER_TAGS" >&5 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6 else - echo "$as_me:16616: result: no" >&5 + echo "$as_me:18473: result: no" >&5 echo "${ECHO_T}no" >&6 fi if test "$cf_cv_mixedcase" = yes ; then # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args. set dummy ${ETAGS:-etags}; ac_word=$2 -echo "$as_me:16623: checking for $ac_word" >&5 +echo "$as_me:18480: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -16635,7 +18492,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_MAKE_UPPER_TAGS="yes" -echo "$as_me:16638: found $ac_dir/$ac_word" >&5 +echo "$as_me:18495: found $ac_dir/$ac_word" >&5 break done @@ -16644,10 +18501,10 @@ fi MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS if test -n "$MAKE_UPPER_TAGS"; then - echo "$as_me:16647: result: $MAKE_UPPER_TAGS" >&5 + echo "$as_me:18504: result: $MAKE_UPPER_TAGS" >&5 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6 else - echo "$as_me:16650: result: no" >&5 + echo "$as_me:18507: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -16668,7 +18525,7 @@ fi LD_RPATH_OPT= -echo "$as_me:16671: checking for an rpath option" >&5 +echo "$as_me:18528: checking for an rpath option" >&5 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6 case $cf_cv_system_name in #(vi irix*) #(vi @@ -16699,17 +18556,17 @@ *) ;; esac -echo "$as_me:16702: result: $LD_RPATH_OPT" >&5 +echo "$as_me:18559: result: $LD_RPATH_OPT" >&5 echo "${ECHO_T}$LD_RPATH_OPT" >&6 case "x$LD_RPATH_OPT" in #(vi x-R*) - echo "$as_me:16707: checking if we need a space after rpath option" >&5 + echo "$as_me:18564: checking if we need a space after rpath option" >&5 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6 cf_save_LIBS="$LIBS" LIBS="${LD_RPATH_OPT}$libdir $LIBS" cat >conftest.$ac_ext <<_ACEOF -#line 16712 "configure" +#line 18569 "configure" #include "confdefs.h" int @@ -16721,16 +18578,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:16724: \"$ac_link\"") >&5 +if { (eval echo "$as_me:18581: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:16727: \$? = $ac_status" >&5 + echo "$as_me:18584: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:16730: \"$ac_try\"") >&5 + { (eval echo "$as_me:18587: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:16733: \$? = $ac_status" >&5 + echo "$as_me:18590: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_rpath_space=no else @@ -16740,13 +18597,13 @@ fi rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext LIBS="$cf_save_LIBS" - echo "$as_me:16743: result: $cf_rpath_space" >&5 + echo "$as_me:18600: result: $cf_rpath_space" >&5 echo "${ECHO_T}$cf_rpath_space" >&6 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT " ;; esac -echo "$as_me:16749: checking if rpath-hack should be disabled" >&5 +echo "$as_me:18606: checking if rpath-hack should be disabled" >&5 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6 # Check whether --enable-rpath-hack or --disable-rpath-hack was given. @@ -16763,21 +18620,21 @@ cf_disable_rpath_hack=no fi; -echo "$as_me:16766: result: $cf_disable_rpath_hack" >&5 +echo "$as_me:18623: result: $cf_disable_rpath_hack" >&5 echo "${ECHO_T}$cf_disable_rpath_hack" >&6 if test "$cf_disable_rpath_hack" = no ; then -echo "$as_me:16770: checking for updated LDFLAGS" >&5 +echo "$as_me:18627: checking for updated LDFLAGS" >&5 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6 if test -n "$LD_RPATH_OPT" ; then - echo "$as_me:16773: result: maybe" >&5 + echo "$as_me:18630: result: maybe" >&5 echo "${ECHO_T}maybe" >&6 for ac_prog in ldd do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -echo "$as_me:16780: checking for $ac_word" >&5 +echo "$as_me:18637: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 @@ -16792,7 +18649,7 @@ test -z "$ac_dir" && ac_dir=. $as_executable_p "$ac_dir/$ac_word" || continue ac_cv_prog_cf_ldd_prog="$ac_prog" -echo "$as_me:16795: found $ac_dir/$ac_word" >&5 +echo "$as_me:18652: found $ac_dir/$ac_word" >&5 break done @@ -16800,10 +18657,10 @@ fi cf_ldd_prog=$ac_cv_prog_cf_ldd_prog if test -n "$cf_ldd_prog"; then - echo "$as_me:16803: result: $cf_ldd_prog" >&5 + echo "$as_me:18660: result: $cf_ldd_prog" >&5 echo "${ECHO_T}$cf_ldd_prog" >&6 else - echo "$as_me:16806: result: no" >&5 + echo "$as_me:18663: result: no" >&5 echo "${ECHO_T}no" >&6 fi @@ -16817,7 +18674,7 @@ cf_rpath_oops= cat >conftest.$ac_ext <<_ACEOF -#line 16820 "configure" +#line 18677 "configure" #include "confdefs.h" #include int @@ -16829,16 +18686,16 @@ } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:16832: \"$ac_link\"") >&5 +if { (eval echo "$as_me:18689: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? - echo "$as_me:16835: \$? = $ac_status" >&5 + echo "$as_me:18692: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:16838: \"$ac_try\"") >&5 + { (eval echo "$as_me:18695: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? - echo "$as_me:16841: \$? = $ac_status" >&5 + echo "$as_me:18698: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort -u` cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort -u` @@ -16866,7 +18723,7 @@ then test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6 -echo "${as_me:-configure}:16869: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5 +echo "${as_me:-configure}:18726: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib" break @@ -16878,11 +18735,11 @@ test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6 -echo "${as_me:-configure}:16881: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 +echo "${as_me:-configure}:18738: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6 -echo "${as_me:-configure}:16885: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5 +echo "${as_me:-configure}:18742: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5 cf_rpath_dst= for cf_rpath_src in $LDFLAGS @@ -16919,7 +18776,7 @@ then test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6 -echo "${as_me:-configure}:16922: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 +echo "${as_me:-configure}:18779: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS" fi @@ -16932,11 +18789,11 @@ test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6 -echo "${as_me:-configure}:16935: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5 +echo "${as_me:-configure}:18792: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6 -echo "${as_me:-configure}:16939: testing ...checking LIBS $LIBS ..." 1>&5 +echo "${as_me:-configure}:18796: testing ...checking LIBS $LIBS ..." 1>&5 cf_rpath_dst= for cf_rpath_src in $LIBS @@ -16973,7 +18830,7 @@ then test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6 -echo "${as_me:-configure}:16976: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 +echo "${as_me:-configure}:18833: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS" fi @@ -16986,11 +18843,11 @@ test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6 -echo "${as_me:-configure}:16989: testing ...checked LIBS $LIBS ..." 1>&5 +echo "${as_me:-configure}:18846: testing ...checked LIBS $LIBS ..." 1>&5 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6 -echo "${as_me:-configure}:16993: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 +echo "${as_me:-configure}:18850: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 fi @@ -17084,7 +18941,7 @@ : ${CONFIG_STATUS=./config.status} ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ echo "$as_me:17087: creating $CONFIG_STATUS" >&5 +{ echo "$as_me:18944: creating $CONFIG_STATUS" >&5 echo "$as_me: creating $CONFIG_STATUS" >&6;} cat >$CONFIG_STATUS <<_ACEOF #! $SHELL @@ -17213,7 +19070,7 @@ cat >>$CONFIG_STATUS <&5 echo "$as_me: error: ambiguous option: $1 Try \`$0 --help' for more information." >&2;} @@ -17276,7 +19133,7 @@ ac_need_defaults=false;; # This is an error. - -*) { { echo "$as_me:17279: error: unrecognized option: $1 + -*) { { echo "$as_me:19136: error: unrecognized option: $1 Try \`$0 --help' for more information." >&5 echo "$as_me: error: unrecognized option: $1 Try \`$0 --help' for more information." >&2;} @@ -17295,7 +19152,7 @@ ## Running config.status. ## ## ----------------------- ## -This file was extended by $as_me 2.52.20101002, executed with +This file was extended by $as_me 2.52.20121002, executed with CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS @@ -17315,7 +19172,7 @@ "df-install" ) CONFIG_FILES="$CONFIG_FILES df-install" ;; "minstall" ) CONFIG_FILES="$CONFIG_FILES minstall:minstall.in" ;; "xtermcfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS xtermcfg.h:xtermcfg.hin" ;; - *) { { echo "$as_me:17318: error: invalid argument: $ac_config_target" >&5 + *) { { echo "$as_me:19175: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} { (exit 1); exit 1; }; };; esac @@ -17373,6 +19230,7 @@ s,@bindir@,$bindir,;t t s,@sbindir@,$sbindir,;t t s,@libexecdir@,$libexecdir,;t t +s,@datarootdir@,$datarootdir,;t t s,@datadir@,$datadir,;t t s,@sysconfdir@,$sysconfdir,;t t s,@sharedstatedir@,$sharedstatedir,;t t @@ -17411,20 +19269,29 @@ s,@ac_ct_CC@,$ac_ct_CC,;t t s,@EXEEXT@,$EXEEXT,;t t s,@OBJEXT@,$OBJEXT,;t t +s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t s,@CPP@,$CPP,;t t s,@AWK@,$AWK,;t t +s,@GROFF_PATH@,$GROFF_PATH,;t t +s,@GROFF_NOTE@,$GROFF_NOTE,;t t +s,@NROFF_NOTE@,$NROFF_NOTE,;t t s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t s,@INSTALL_DATA@,$INSTALL_DATA,;t t s,@LN_S@,$LN_S,;t t s,@LINT@,$LINT,;t t -s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t -s,@PROG_EXT@,$PROG_EXT,;t t s,@APP_CLASS@,$APP_CLASS,;t t -s,@appsdir@,$appsdir,;t t +s,@APPSDIR@,$APPSDIR,;t t s,@no_appsdir@,$no_appsdir,;t t -s,@icondir@,$icondir,;t t +s,@ICON_NAME@,$ICON_NAME,;t t +s,@ICON_SYMLINK@,$ICON_SYMLINK,;t t +s,@PIXMAPDIR@,$PIXMAPDIR,;t t +s,@no_pixmapdir@,$no_pixmapdir,;t t +s,@ICONDIR@,$ICONDIR,;t t s,@no_icondir@,$no_icondir,;t t +s,@ICON_FORMAT@,$ICON_FORMAT,;t t +s,@ICON_THEME@,$ICON_THEME,;t t +s,@ICON_LIST@,$ICON_LIST,;t t s,@desktop_utils@,$desktop_utils,;t t s,@DESKTOP_FLAGS@,$DESKTOP_FLAGS,;t t s,@DESKTOP_CATEGORY@,$DESKTOP_CATEGORY,;t t @@ -17437,11 +19304,17 @@ s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t s,@PKG_CONFIG@,$PKG_CONFIG,;t t s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t +s,@ICON_SUFFIX@,$ICON_SUFFIX,;t t s,@IMAKE@,$IMAKE,;t t s,@IMAKE_CFLAGS@,$IMAKE_CFLAGS,;t t s,@IMAKE_LOADFLAGS@,$IMAKE_LOADFLAGS,;t t s,@default_termid@,$default_termid,;t t s,@default_TERM@,$default_TERM,;t t +s,@backarrow_is_bs@,$backarrow_is_bs,;t t +s,@backarrow_is_erase@,$backarrow_is_erase,;t t +s,@delete_is_del@,$delete_is_del,;t t +s,@alt_sends_esc@,$alt_sends_esc,;t t +s,@meta_sends_esc@,$meta_sends_esc,;t t s,@cf_tic_prog@,$cf_tic_prog,;t t s,@no_ticprog@,$no_ticprog,;t t s,@TERMINFO_DIR@,$TERMINFO_DIR,;t t @@ -17584,7 +19457,7 @@ esac if test x"$ac_file" != x-; then - { echo "$as_me:17587: creating $ac_file" >&5 + { echo "$as_me:19460: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} rm -f "$ac_file" fi @@ -17602,7 +19475,7 @@ -) echo $tmp/stdin ;; [\\/$]*) # Absolute (can't be DOS-style, as IFS=:) - test -f "$f" || { { echo "$as_me:17605: error: cannot find input file: $f" >&5 + test -f "$f" || { { echo "$as_me:19478: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } echo $f;; @@ -17615,13 +19488,45 @@ echo $srcdir/$f else # /dev/null tree - { { echo "$as_me:17618: error: cannot find input file: $f" >&5 + { { echo "$as_me:19491: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } fi;; esac done` || { (exit 1); exit 1; } EOF +cat >>$CONFIG_STATUS <<\EOF + ac_warn_datarootdir=no + if test x"$ac_file" != x-; then + for ac_item in $ac_file_inputs + do + ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item` + if test -n "$ac_seen"; then + ac_used=`grep '@datarootdir@' $ac_item` + if test -z "$ac_used"; then + { echo "$as_me:19507: WARNING: datarootdir was used implicitly but not set: +$ac_seen" >&5 +echo "$as_me: WARNING: datarootdir was used implicitly but not set: +$ac_seen" >&2;} + ac_warn_datarootdir=yes + fi + fi + ac_seen=`grep '${datarootdir}' $ac_item` + if test -n "$ac_seen"; then + { echo "$as_me:19516: WARNING: datarootdir was used explicitly but not set: +$ac_seen" >&5 +echo "$as_me: WARNING: datarootdir was used explicitly but not set: +$ac_seen" >&2;} + ac_warn_datarootdir=yes + fi + done + fi + +if test "x$ac_warn_datarootdir" = xyes; then + ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'" +fi + +EOF cat >>$CONFIG_STATUS <$tmp/out rm -f $tmp/stdin if test x"$ac_file" != x-; then - mv $tmp/out $ac_file + cp $tmp/out $ac_file + + for ac_name in prefix exec_prefix datarootdir + do + ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file` + if test -n "$ac_seen"; then + ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file` + if test -z "$ac_init"; then + ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'` + { echo "$as_me:19553: WARNING: Variable $ac_name is used but was not set: +$ac_seen" >&5 +echo "$as_me: WARNING: Variable $ac_name is used but was not set: +$ac_seen" >&2;} + fi + fi + done + egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out + egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out + if test -s $tmp/out; then + ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out` + { echo "$as_me:19564: WARNING: Some variables may not be substituted: +$ac_seen" >&5 +echo "$as_me: WARNING: Some variables may not be substituted: +$ac_seen" >&2;} + fi else cat $tmp/out - rm -f $tmp/out fi + rm -f $tmp/out done EOF @@ -17681,7 +19610,7 @@ * ) ac_file_in=$ac_file.in ;; esac - test x"$ac_file" != x- && { echo "$as_me:17684: creating $ac_file" >&5 + test x"$ac_file" != x- && { echo "$as_me:19613: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} # First look for the input files in the build tree, otherwise in the @@ -17692,7 +19621,7 @@ -) echo $tmp/stdin ;; [\\/$]*) # Absolute (can't be DOS-style, as IFS=:) - test -f "$f" || { { echo "$as_me:17695: error: cannot find input file: $f" >&5 + test -f "$f" || { { echo "$as_me:19624: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } echo $f;; @@ -17705,7 +19634,7 @@ echo $srcdir/$f else # /dev/null tree - { { echo "$as_me:17708: error: cannot find input file: $f" >&5 + { { echo "$as_me:19637: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } fi;; @@ -17823,7 +19752,7 @@ rm -f $tmp/in if test x"$ac_file" != x-; then if cmp -s $ac_file $tmp/config.h 2>/dev/null; then - { echo "$as_me:17826: $ac_file is unchanged" >&5 + { echo "$as_me:19755: $ac_file is unchanged" >&5 echo "$as_me: $ac_file is unchanged" >&6;} else ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ diff -Nru xterm-278/configure.in xterm-297/configure.in --- xterm-278/configure.in 2012-01-05 10:27:54.000000000 +0000 +++ xterm-297/configure.in 2013-08-04 19:28:25.000000000 +0000 @@ -1,9 +1,9 @@ -dnl $XTermId: configure.in,v 1.285 2012/01/05 10:27:54 tom Exp $ +dnl $XTermId: configure.in,v 1.319 2013/08/04 19:28:25 tom Exp $ dnl dnl ----------------------------------------------------------------------------- dnl this file is part of xterm dnl -dnl Copyright 1997-2010,2011 by Thomas E. Dickey +dnl Copyright 1997-2012,2013 by Thomas E. Dickey dnl dnl All Rights Reserved dnl @@ -33,7 +33,7 @@ dnl --------------------------------------------------------------------------- dnl Process this file with autoconf to produce a configure script. dnl -AC_PREREQ(2.13.20030927) +AC_PREREQ(2.52.20030208) AC_INIT(charproc.c) AC_CONFIG_HEADER(xtermcfg.h:xtermcfg.hin) CF_CHECK_CACHE @@ -51,23 +51,16 @@ : ${LDFLAGS}="${LDFLAGS} -Wl,-bind_at_load";; esac -AC_PROG_CC +CF_PROG_CC AC_PROG_CPP -AC_PROG_GCC_TRADITIONAL AC_PROG_AWK +CF_PROG_GROFF AC_PROG_INSTALL AC_PROG_LN_S AC_ARG_PROGRAM AC_CHECK_PROGS(LINT, tdlint lint alint) -### checks for UNIX variants that set C preprocessor variables -AC_AIX -AC_ISC_POSIX - ### checks for compiler characteristics -CF_ANSI_CC_CHECK -AC_C_CONST -CF_PROG_EXT CF_XOPEN_SOURCE CF_SIGWINCH @@ -87,7 +80,6 @@ ### checks for typedefs CF_SIG_ATOMIC_T -CF_SIZE_T AC_CHECK_TYPE(time_t, long) CF_TYPE_CC_T AC_TYPE_MODE_T @@ -97,21 +89,17 @@ ### checks for library functions AC_CHECK_FUNCS( \ - bcopy \ gethostname \ getlogin \ - memmove \ putenv \ unsetenv \ sched_yield \ setpgid \ - strerror \ strftime \ tcgetattr \ waitpid \ wcswidth \ wcwidth ) -CF_FUNC_MEMMOVE CF_UTMP CF_STRUCT_LASTLOG CF_POSIX_SAVED_IDS @@ -121,9 +109,13 @@ CF_WITH_APP_CLASS(XTerm) CF_WITH_APP_DEFAULTS -CF_WITH_ICONDIR +CF_WITH_ICON_NAME(xterm-color) +CF_WITH_ICON_SYMLINK(xterm) +CF_WITH_ICON_THEME([icons/$ICON_NAME icons/${ICON_NAME}_48x48],,,icons/${ICON_NAME}_48x48) CF_DISABLE_DESKTOP(xterm) -CF_WITH_DESKTOP_CATEGORY(xterm,[*rxvt*|konsole|*-terminal],[System|TerminalEmulator|Utility|*]) +CF_WITH_DESKTOP_CATEGORY(xterm, + [*rxvt*|konsole|*-terminal], + [System|TerminalEmulator|Utility|*]) AC_MSG_CHECKING(for install-permissions reference) AC_ARG_WITH(reference, @@ -156,6 +148,14 @@ XTERM_SYMLINK="$with_symlink" fi +AC_MSG_CHECKING(if you want to disable openpty) +CF_ARG_DISABLE(openpty, + [ --disable-openpty disable openpty, prefer other interfaces], + [disable_openpty=yes], + [disable_openpty=no], + no) +AC_MSG_RESULT($disable_openpty) + AC_MSG_CHECKING(if you want to disable setuid) CF_ARG_DISABLE(setuid, [ --disable-setuid disable setuid in xterm, do not install setuid/setgid], @@ -205,7 +205,7 @@ if test "$cf_cv_posix_saved_ids" != yes ; then AC_MSG_ERROR(Your system does not support POSIX saved-ids) fi - AC_DEFINE(USE_UTMP_SETGID) + AC_DEFINE(USE_UTMP_SETGID,1,[Define to 1 if we should use setgid to access utmp/utmpx]) SINSTALL_OPTS="$SINSTALL_OPTS g+s -g $cf_cv_utmp_group" fi @@ -254,6 +254,7 @@ X11/extensions/XKB.h \ ) +CF_WITH_XPM CF_X_ATHENA CF_TYPE_FD_MASK CF_TERMIO_C_ISPEED @@ -261,8 +262,8 @@ LIBS="$LIBS $X_EXTRA_LIBS" CF_FUNC_GRANTPT -AC_CHECK_FUNCS(XkbQueryExtension) - +CF_XKB_QUERY_EXTENSION +CF_XKB_KEYCODE_TO_KEYSYM CF_XKB_BELL_EXT AC_CHECK_FUNCS(Xutf8LookupString, [],[ @@ -289,15 +290,15 @@ AC_MSG_CHECKING(for default terminal-id) AC_ARG_WITH(terminal-id, - [ --with-terminal-id=V set default decTerminalID (default: vt100)], + [ --with-terminal-id=V set default decTerminalID (default: vt420)], [default_termid=$withval], - [default_termid=vt100]) + [default_termid=vt420]) AC_MSG_RESULT($default_termid) case $default_termid in vt*) default_termid=`echo $default_termid | sed -e 's/^..//'` ;; esac -AC_DEFINE_UNQUOTED(DFT_DECID,"$default_termid") +AC_DEFINE_UNQUOTED(DFT_DECID,"$default_termid",[default terminal-id]) AC_SUBST(default_termid) AC_MSG_CHECKING(for default terminal-type) @@ -306,9 +307,46 @@ [default_TERM=$withval], [default_TERM=xterm]) AC_MSG_RESULT($default_TERM) -AC_DEFINE_UNQUOTED(DFT_TERMTYPE,"$default_TERM") +AC_DEFINE_UNQUOTED(DFT_TERMTYPE,"$default_TERM",[default terminal-type]) AC_SUBST(default_TERM) +############################################################################### +AC_MSG_CHECKING(if backarrow-key should be BS) +CF_ARG_DISABLE(backarrow-key, + [ --enable-backarrow-key set default backarrowKey resource (default: true)], + [backarrow_is_bs=$enableval], + [backarrow_is_bs=yes]) +CF_XBOOL_RESULT(DEF_BACKARO_BS,backarrow_is_bs,[Define to 1 if backarrow-key should be BS]) + +AC_MSG_CHECKING(if backarrow-key should be treated as erase) +CF_ARG_ENABLE(backarrow-is-erase, + [ --enable-backarrow-is-erase set default backarrowKeyIsErase resource (default: false)], + [backarrow_is_erase=$enableval], + [backarrow_is_erase=no]) +CF_XBOOL_RESULT(DEF_BACKARO_ERASE,backarrow_is_erase,[Define to 1 if backarrow-key should be treated as erase]) + +AC_MSG_CHECKING(for default backspace/DEL setting) +AC_ARG_ENABLE(delete-is-del, + [ --enable-delete-is-del set default deleteIsDEL resource (default: maybe)], + [delete_is_del=$enableval], + [delete_is_del=maybe]) +CF_XBOOL_RESULT(DEFDELETE_DEL,delete_is_del,[Define to 1 if default backspace/DEL setting is DEL]) + +AC_MSG_CHECKING(if alt should send ESC) +CF_ARG_ENABLE(alt-sends-esc, + [ --enable-alt-sends-esc set default altSendsEscape resource (default: no)], + [alt_sends_esc=$enableval], + [alt_sends_esc=no]) +CF_XBOOL_RESULT(DEF_ALT_SENDS_ESC,alt_sends_esc,[Define to 1 if alt should send ESC]) + +AC_MSG_CHECKING(if meta should send ESC) +CF_ARG_ENABLE(meta-sends-esc, + [ --enable-meta-sends-esc set default metaSendsEscape resource (default: no)], + [meta_sends_esc=$enableval], + [meta_sends_esc=no]) +CF_XBOOL_RESULT(DEF_META_SENDS_ESC,meta_sends_esc,[Define to 1 if meta should send ESC]) + +############################################################################### AC_CHECK_PROG(cf_tic_prog,tic,yes,no) if test "$cf_tic_prog" = yes ; then AC_MSG_CHECKING(for private terminfo-directory) @@ -321,7 +359,7 @@ AC_MSG_WARN(no value given) elif test "$TERMINFO_DIR" != none ; then if test -d $TERMINFO_DIR ; then - AC_DEFINE_UNQUOTED(OWN_TERMINFO_DIR,"$TERMINFO_DIR") + AC_DEFINE_UNQUOTED(OWN_TERMINFO_DIR,"$TERMINFO_DIR",[Define to override default TERMINFO value]) else AC_MSG_WARN(not a directory) fi @@ -357,7 +395,7 @@ [enable_active_icon=yes]) AC_MSG_RESULT($enable_active_icon) if test "$enable_active_icon" = no ; then - AC_DEFINE(NO_ACTIVE_ICON) + AC_DEFINE(NO_ACTIVE_ICON,1,[Define to 1 to disable X11R6.3 active-icon feature]) fi AC_MSG_CHECKING(if you want ANSI color) @@ -366,7 +404,7 @@ [enable_ansi_color=no], [enable_ansi_color=yes]) AC_MSG_RESULT($enable_ansi_color) -test "$enable_ansi_color" = no && AC_DEFINE(OPT_ISO_COLORS,0) +test "$enable_ansi_color" = no && AC_DEFINE(OPT_ISO_COLORS,0,[Define to 0 to disable ANSI color]) if test "$enable_ansi_color" = yes ; then @@ -376,7 +414,7 @@ [enable_16_color=no], [enable_16_color=yes]) AC_MSG_RESULT($enable_16_color) - test "$enable_16_color" = no && AC_DEFINE(OPT_AIX_COLORS,0) + test "$enable_16_color" = no && AC_DEFINE(OPT_AIX_COLORS,0,[Define to 0 to disable 16-color support]) AC_MSG_CHECKING(if you want 256 colors) CF_ARG_ENABLE(256-color, @@ -387,7 +425,7 @@ if test "$enable_256_color" = yes ; then CHARPROC_DEPS="$CHARPROC_DEPS 256colres.h" EXTRAHDRS="$EXTRAHDRS 256colres.h" - AC_DEFINE(OPT_256_COLORS,1) + AC_DEFINE(OPT_256_COLORS,1,[Define to 1 to enable 256-color support]) else AC_MSG_CHECKING(if you want 88 colors) CF_ARG_ENABLE(88-color, @@ -398,7 +436,7 @@ if test "$enable_88_color" = yes ; then CHARPROC_DEPS="$CHARPROC_DEPS 88colres.h" EXTRAHDRS="$EXTRAHDRS 88colres.h" - AC_DEFINE(OPT_88_COLORS,1) + AC_DEFINE(OPT_88_COLORS,1,[Define to 1 to enable 88-color support]) fi fi @@ -410,7 +448,7 @@ [enable_blink_curs=no], [enable_blink_curs=yes]) AC_MSG_RESULT($enable_blink_curs) -test "$enable_blink_curs" = no && AC_DEFINE(OPT_BLINK_CURS,0) +test "$enable_blink_curs" = no && AC_DEFINE(OPT_BLINK_CURS,0,[Define to 0 to disable support for blinking cursor]) AC_MSG_CHECKING(if you want to ignore Linux's broken palette-strings) @@ -428,9 +466,9 @@ [$assume_broken_osc]) AC_MSG_RESULT($enable_broken_osc) if test "$enable_broken_osc" = yes ; then - AC_DEFINE(OPT_BROKEN_OSC,1) + AC_DEFINE(OPT_BROKEN_OSC,1,[Define to 1 to allow broken Linux OSC-strings]) else - AC_DEFINE(OPT_BROKEN_OSC,0) + AC_DEFINE(OPT_BROKEN_OSC,0,[Define to 0 to allow broken Linux OSC-strings]) fi AC_MSG_CHECKING(if you want to allow broken string-terminators) @@ -439,7 +477,7 @@ [enable_broken_st=no], [enable_broken_st=yes]) AC_MSG_RESULT($enable_broken_st) -test "$enable_broken_st" = no && AC_DEFINE(OPT_BROKEN_ST,0) +test "$enable_broken_st" = no && AC_DEFINE(OPT_BROKEN_ST,0,[Define to 0 to disallow broken string-terminators]) AC_MSG_CHECKING(if you want printable 128-159) CF_ARG_DISABLE(c1-print, @@ -447,7 +485,7 @@ [enable_c1_print=no], [enable_c1_print=yes]) AC_MSG_RESULT($enable_c1_print) -test "$enable_c1_print" = no && AC_DEFINE(OPT_C1_PRINT,0) +test "$enable_c1_print" = no && AC_DEFINE(OPT_C1_PRINT,0,[Define to 0 to disallow -k8 option for printable 128-159]) if test "$enable_ansi_color" = yes ; then @@ -457,7 +495,7 @@ [enable_pc_color=no], [enable_pc_color=yes]) AC_MSG_RESULT($enable_pc_color) - test "$enable_pc_color" = no && AC_DEFINE(OPT_PC_COLORS,0) + test "$enable_pc_color" = no && AC_DEFINE(OPT_PC_COLORS,0,[Define to 0 to disable PC-style mapping of bold colors]) AC_MSG_CHECKING(if you want separate color-classes) CF_ARG_DISABLE(color-class, @@ -465,7 +503,7 @@ [enable_color_class=no], [enable_color_class=yes]) AC_MSG_RESULT($enable_color_class) - test "$enable_color_class" = no && AC_DEFINE(OPT_COLOR_CLASS,FALSE) + test "$enable_color_class" = no && AC_DEFINE(OPT_COLOR_CLASS,0,[Define to 0 to disable separate color class resources]) AC_MSG_CHECKING(if you want color-mode enabled by default) CF_ARG_DISABLE(color-mode, @@ -473,7 +511,7 @@ [default_colormode=no], [default_colormode=yes]) AC_MSG_RESULT($default_colormode) - test "$default_colormode" = no && AC_DEFINE(DFT_COLORMODE,FALSE) + test "$default_colormode" = no && AC_DEFINE(DFT_COLORMODE,0,[Define to 0 if you want color-mode enabled by default]) fi @@ -483,7 +521,7 @@ [default_highlight=no], [default_highlight=yes]) AC_MSG_RESULT($default_highlight) -test "$default_highlight" = no && AC_DEFINE(OPT_HIGHLIGHT_COLOR,0) +test "$default_highlight" = no && AC_DEFINE(OPT_HIGHLIGHT_COLOR,0,[Define to 1 if you want support for color highlighting]) AC_MSG_CHECKING(if you want support for doublesize characters) CF_ARG_DISABLE(doublechars, @@ -491,7 +529,7 @@ [enable_doublechars=no], [enable_doublechars=yes]) AC_MSG_RESULT($enable_doublechars) -test "$enable_doublechars" = no && AC_DEFINE(OPT_DEC_CHRSET,0) +test "$enable_doublechars" = no && AC_DEFINE(OPT_DEC_CHRSET,0,[Define to 0 to disable support for double-size chars]) AC_MSG_CHECKING(if you want fallback-support for box characters) CF_ARG_DISABLE(boxchars, @@ -499,7 +537,7 @@ [enable_boxchars=no], [enable_boxchars=yes]) AC_MSG_RESULT($enable_boxchars) -test "$enable_boxchars" = no && AC_DEFINE(OPT_BOX_CHARS,0) +test "$enable_boxchars" = no && AC_DEFINE(OPT_BOX_CHARS,0,[Define to 0 to disable fallback-support for box chars]) AC_MSG_CHECKING(if you want to allow spawning new xterms) CF_ARG_ENABLE(exec-xterm, @@ -512,11 +550,28 @@ if test "$cf_cv_procfs_cwd" = no ; then AC_MSG_WARN(no suitable proc filesystem found) else - AC_DEFINE_UNQUOTED(PROCFS_ROOT,"$cf_cv_procfs_cwd") - AC_DEFINE(OPT_EXEC_XTERM) + AC_DEFINE_UNQUOTED(PROCFS_ROOT,"$cf_cv_procfs_cwd",[This is defined via the --enable-exec-xterm option]) + AC_DEFINE(OPT_EXEC_XTERM,1,[Define to 1 to enable "spawn-new-terminal" action]) fi fi +AC_MSG_CHECKING(if you want to use double-buffering) +CF_ARG_ENABLE(double-buffer, + [ --enable-double-buffer enable double-buffering], + [enable_double_bfr=yes], + [enable_double_bfr=no]) +AC_MSG_RESULT($enable_double_bfr) +if test "$enable_double_bfr" = yes ; then + case "x$LIBS" in + *Xext*) + ;; + *) + CF_X_EXT + ;; + esac + AC_DEFINE(OPT_DOUBLE_BUFFER,1,[Define to 1 to enable double-buffering]) +fi + AC_MSG_CHECKING(if you want to use FreeType library) CF_ARG_DISABLE(freetype, [ --disable-freetype disable freetype library-support], @@ -536,7 +591,7 @@ [enable_hp_fkeys=no]) AC_MSG_RESULT($enable_hp_fkeys) if test "$enable_hp_fkeys" = yes ; then - AC_DEFINE(OPT_HP_FUNC_KEYS,1) + AC_DEFINE(OPT_HP_FUNC_KEYS,1,[Define to 1 to enable support for HP-style function keys]) fi AC_MSG_CHECKING(if you want support for SCO-style function keys) @@ -546,7 +601,7 @@ [enable_sco_fkeys=no]) AC_MSG_RESULT($enable_sco_fkeys) if test "$enable_sco_fkeys" = yes ; then - AC_DEFINE(OPT_SCO_FUNC_KEYS,1) + AC_DEFINE(OPT_SCO_FUNC_KEYS,1,[Define to 1 to enable support for SCO-style function keys]) fi AC_MSG_CHECKING(if you want support for Sun-style function keys) @@ -556,7 +611,7 @@ [enable_sun_fkeys=yes]) AC_MSG_RESULT($enable_sun_fkeys) if test "$enable_sun_fkeys" = no ; then - AC_DEFINE(OPT_SUN_FUNC_KEYS,0) + AC_DEFINE(OPT_SUN_FUNC_KEYS,0,[Define to 0 to disable support for Sun-style function keys]) fi AC_MSG_CHECKING(if you want saved-lines stored as a FIFO) @@ -566,7 +621,7 @@ [enable_fifo_lines=yes]) AC_MSG_RESULT($enable_fifo_lines) if test "$enable_fifo_lines" = yes ; then - AC_DEFINE(OPT_FIFO_LINES,1) + AC_DEFINE(OPT_FIFO_LINES,1,[Define to 1 to disable FIFO-storage for saved-lines]) fi AC_MSG_CHECKING(if you want support for internationalization) @@ -576,7 +631,7 @@ [enable_i18n=yes]) AC_MSG_RESULT($enable_i18n) if test "$enable_i18n" = no ; then - AC_DEFINE(OPT_I18N_SUPPORT,0) + AC_DEFINE(OPT_I18N_SUPPORT,0,[Define to 0 to disable internationalization]) fi AC_MSG_CHECKING(if you want support for initial-erase setup) @@ -586,7 +641,7 @@ [enable_ie=yes]) AC_MSG_RESULT($enable_ie) if test "$enable_ie" = no ; then - AC_DEFINE(OPT_INITIAL_ERASE,0) + AC_DEFINE(OPT_INITIAL_ERASE,0,[Define to 0 to disable setup for stty erase]) fi AC_MSG_CHECKING(if you want support for input-method) @@ -598,7 +653,7 @@ CF_INPUT_METHOD test "$cf_cv_input_method" = no && enable_ximp=no if test "$enable_ximp" = no ; then - AC_DEFINE(OPT_INPUT_METHOD,0) + AC_DEFINE(OPT_INPUT_METHOD,0,[Define to 0 to disable input-method]) fi AC_MSG_CHECKING(if you want support for load-vt-fonts) @@ -608,7 +663,7 @@ [enable_load_vt_fonts=no]) AC_MSG_RESULT($enable_load_vt_fonts) if test "$enable_load_vt_fonts" = yes ; then - AC_DEFINE(OPT_LOAD_VTFONTS,1) + AC_DEFINE(OPT_LOAD_VTFONTS,1,[Define to 1 to enable load-vt-fonts() action]) fi AC_MSG_CHECKING(if you want support for logging) @@ -618,7 +673,7 @@ [enable_logging=no]) AC_MSG_RESULT($enable_logging) if test "$enable_logging" = yes ; then - AC_DEFINE(ALLOWLOGGING) + AC_DEFINE(ALLOWLOGGING,1,[if you want support for logging]) AC_MSG_CHECKING(if you want to allow logging via a pipe) CF_ARG_ENABLE(logfile-exec, [ --enable-logfile-exec enable exec'd logfile filter], @@ -626,7 +681,7 @@ [enable_log_exec=no]) AC_MSG_RESULT($enable_log_exec) if test "$enable_log_exec" = yes ; then - AC_DEFINE(ALLOWLOGFILEEXEC) + AC_DEFINE(ALLOWLOGFILEEXEC,1,[if you want to allow logging via a pipe]) fi fi @@ -636,7 +691,7 @@ [enable_maximize=no], [enable_maximize=yes]) AC_MSG_RESULT($enable_maximize) -test "$enable_maximize" = no && AC_DEFINE(OPT_MAXIMIZE,0) +test "$enable_maximize" = no && AC_DEFINE(OPT_MAXIMIZE,0,[Define to 0 to disable actions for iconify/deiconify/maximize/restore]) AC_MSG_CHECKING(if you want NumLock to override keyboard tables) CF_ARG_DISABLE(num-lock, @@ -644,7 +699,7 @@ [enable_numlock=no], [enable_numlock=yes]) AC_MSG_RESULT($enable_numlock) -test "$enable_numlock" = no && AC_DEFINE(OPT_NUM_LOCK,0) +test "$enable_numlock" = no && AC_DEFINE(OPT_NUM_LOCK,0,[Define to 0 to disable NumLock keypad support]) AC_MSG_CHECKING(if you want support for get/set of base64 selection data) @@ -654,9 +709,9 @@ [enable_paste64=yes]) AC_MSG_RESULT($enable_paste64) if test "$enable_paste64" = yes ; then - AC_DEFINE(OPT_PASTE64,1) + AC_DEFINE(OPT_PASTE64,1,[Define to 1 to disable get/set base64 selection data]) else - AC_DEFINE(OPT_PASTE64,0) + AC_DEFINE(OPT_PASTE64,0,[Define to 0 to disable get/set base64 selection data]) fi AC_MSG_CHECKING(if you want support for pty-handshaking) @@ -667,9 +722,9 @@ [enable_pty_handshake=yes]) AC_MSG_RESULT($enable_pty_handshake) if test "$enable_pty_handshake" = yes ; then - AC_DEFINE(OPT_PTY_HANDSHAKE,1) + AC_DEFINE(OPT_PTY_HANDSHAKE,1,[Define to 1 to disable pty-handshake support]) else - AC_DEFINE(OPT_PTY_HANDSHAKE,0) + AC_DEFINE(OPT_PTY_HANDSHAKE,0,[Define to 0 to disable pty-handshake support]) fi AC_MSG_CHECKING(if you want support for mouse in readline applications) @@ -679,7 +734,7 @@ [enable_readline_mouse=no]) AC_MSG_RESULT($enable_readline_mouse) if test "$enable_readline_mouse" = yes ; then - AC_DEFINE(OPT_READLINE,1) + AC_DEFINE(OPT_READLINE,1,[Define to 1 to enable support for mouse in readline applications]) fi AC_MSG_CHECKING(if you want support for regular-expression selections) @@ -696,7 +751,7 @@ AC_MSG_ERROR(Only POSIX or PCRE regular expressions are supported) fi fi - AC_DEFINE(OPT_SELECT_REGEX) + AC_DEFINE(OPT_SELECT_REGEX,1,[Define to 1 to enable regular-expression selections]) fi AC_MSG_CHECKING(if you want support for right-scrollbar) @@ -706,7 +761,7 @@ [enable_rightbar=yes]) AC_MSG_RESULT($enable_rightbar) if test "$enable_rightbar" = yes ; then - AC_DEFINE(SCROLLBAR_RIGHT) + AC_DEFINE(SCROLLBAR_RIGHT,1,[Define to 1 to enable right-scrollbar support]) fi AC_MSG_CHECKING(if you want check for redundant name-change) @@ -715,7 +770,7 @@ [enable_samename=no], [enable_samename=yes]) AC_MSG_RESULT($enable_samename) -test "$enable_samename" = no && AC_DEFINE(OPT_SAME_NAME,0) +test "$enable_samename" = no && AC_DEFINE(OPT_SAME_NAME,0,[Define to 0 to disable check for redundant name-change]) AC_MSG_CHECKING(if you want support for selection-actions) CF_ARG_DISABLE(selection-ops, @@ -723,7 +778,7 @@ [enable_selection_ops=no], [enable_selection_ops=yes]) AC_MSG_RESULT($enable_selection_ops) -test "$enable_selection_ops" = no && AC_DEFINE(OPT_SELECTION_OPS,0) +test "$enable_selection_ops" = no && AC_DEFINE(OPT_SELECTION_OPS,0,[Define to 0 disable selection-action operations]) AC_MSG_CHECKING(if you want support for session management) CF_ARG_DISABLE(session-mgt, @@ -731,7 +786,7 @@ [enable_session_mgt=no], [enable_session_mgt=yes]) AC_MSG_RESULT($enable_session_mgt) -test "$enable_session_mgt" = no && AC_DEFINE(OPT_SESSION_MGT,0) +test "$enable_session_mgt" = no && AC_DEFINE(OPT_SESSION_MGT,0,[Define to 0 to disable support for session management]) AC_MSG_CHECKING(if you want to use termcap function-keys) CF_ARG_DISABLE(tcap-fkeys, @@ -739,7 +794,7 @@ [enable_tcap_fkeys=no], [enable_tcap_fkeys=yes]) AC_MSG_RESULT($enable_tcap_fkeys) -test "$enable_tcap_fkeys" = yes && AC_DEFINE(OPT_TCAP_FKEYS,1) +test "$enable_tcap_fkeys" = yes && AC_DEFINE(OPT_TCAP_FKEYS,1,[Define to 1 to disable termcap function-keys support]) AC_MSG_CHECKING(if you want to use termcap-query/report) CF_ARG_DISABLE(tcap-query, @@ -747,7 +802,7 @@ [enable_tcap_query=no], [enable_tcap_query=yes]) AC_MSG_RESULT($enable_tcap_query) -test "$enable_tcap_query" = yes && AC_DEFINE(OPT_TCAP_QUERY,1) +test "$enable_tcap_query" = yes && AC_DEFINE(OPT_TCAP_QUERY,1,[Define to 1 to disable compiled-in termcap-query support]) AC_MSG_CHECKING(if you want support for tek4014) CF_ARG_DISABLE(tek4014, @@ -756,7 +811,7 @@ [enable_tek4014=yes]) AC_MSG_RESULT($enable_tek4014) if test "$enable_tek4014" = no ; then - AC_DEFINE(OPT_TEK4014,0) + AC_DEFINE(OPT_TEK4014,0,[Define to 0 to disable tek4014 emulation]) else EXTRAHDRS="$EXTRAHDRS Tekparse.h" EXTRASRCS="$EXTRASRCS TekPrsTbl.c Tekproc.c" @@ -770,7 +825,7 @@ [enable_toolbar=no]) AC_MSG_RESULT($enable_toolbar) if test "$enable_toolbar" = yes ; then - AC_DEFINE(OPT_TOOLBAR,1) + AC_DEFINE(OPT_TOOLBAR,1,[Define to 1 to compile-in toolbar for pulldown menus]) fi AC_MSG_CHECKING(if you want VT52 emulation) @@ -779,35 +834,13 @@ [enable_vt52=no], [enable_vt52=yes]) AC_MSG_RESULT($enable_vt52) -test "$enable_vt52" = no && AC_DEFINE(OPT_VT52_MODE,0) - -AC_MSG_CHECKING(if you want to use mini-luit/Latin9 built-in support) -CF_ARG_ENABLE(mini-luit, - [ --enable-mini-luit enable mini-luit (built-in Latin9 support)], - [enable_mini_luit=yes], - [enable_mini_luit=no]) -AC_MSG_RESULT($enable_mini_luit) -if test "$enable_mini_luit" = yes ; then - AC_DEFINE(OPT_MINI_LUIT,1) -fi - -AC_MSG_CHECKING(if you want to use luit) -CF_ARG_ENABLE(luit, - [ --enable-luit enable luit filter (Unicode translation)], - [enable_luit=yes], - [enable_luit=$enable_mini_luit]) -AC_MSG_RESULT($enable_luit) -if test "$enable_luit" = yes ; then - AC_DEFINE(OPT_LUIT_PROG,1) - CF_PATH_PROG(LUIT,xterm-filter,bluit luit) -fi +test "$enable_vt52" = no && AC_DEFINE(OPT_VT52_MODE,0,[Define to 0 to disable VT52 emulation]) AC_MSG_CHECKING(if you want wide-character support) -CF_ARG_OPTION(wide-chars, - [ --enable-wide-chars enable wide-character support], - [enable_wchar=yes], - [enable_wchar=$enable_luit], - [$enable_luit]) +CF_ARG_DISABLE(wide-chars, + [ --disable-wide-chars disable wide-character support], + [enable_wchar=no], + [enable_wchar=yes]) AC_MSG_RESULT($enable_wchar) AC_MSG_CHECKING(if you want only 16-bit character support) @@ -818,12 +851,34 @@ AC_MSG_RESULT($enable_16bit_chars) if test "$enable_16bit_chars" = yes ; then - AC_DEFINE(OPT_WIDER_ICHAR,0) + AC_DEFINE(OPT_WIDER_ICHAR,0,[Define to 0 to enable 16-bit character support]) enable_wchar=yes fi if test "$enable_wchar" = yes ; then - AC_DEFINE(OPT_WIDE_CHARS,1) + +AC_MSG_CHECKING(if you want to use mini-luit/Latin9 built-in support) +CF_ARG_ENABLE(mini-luit, + [ --enable-mini-luit enable mini-luit (built-in Latin9 support)], + [enable_mini_luit=yes], + [enable_mini_luit=no]) +AC_MSG_RESULT($enable_mini_luit) +if test "$enable_mini_luit" = yes ; then + AC_DEFINE(OPT_MINI_LUIT,1,[Define to 1 to enable mini-luit (built-in Latin9 support)]) +fi + +AC_MSG_CHECKING(if you want to use luit) +CF_ARG_DISABLE(luit, + [ --disable-luit enable luit filter (Unicode translation)], + [enable_luit=no], + [enable_luit=yes]) +AC_MSG_RESULT($enable_luit) +if test "$enable_luit" = yes ; then + AC_DEFINE(OPT_LUIT_PROG,1,[Define to 1 to enable luit filter (Unicode translation)]) + CF_PATH_PROG(LUIT,xterm-filter,bluit luit) +fi + + AC_DEFINE(OPT_WIDE_CHARS,1,[Define to 1 to enable wide-character support]) EXTRAHDRS="$EXTRAHDRS charclass.h precompose.h wcwidth.h" EXTRASRCS="$EXTRASRCS charclass.c precompose.c wcwidth.c" EXTRAOBJS="$EXTRAOBJS charclass.o precompose.o wcwidth.o" @@ -836,7 +891,7 @@ [enable_dabbrev=no]) AC_MSG_RESULT($enable_dabbrev) if test "$enable_dabbrev" = yes ; then - AC_DEFINE(OPT_DABBREV,1) + AC_DEFINE(OPT_DABBREV,1,[Define to 1 to enable dynamic-abbreviation support]) fi AC_MSG_CHECKING(if you want DECterm Locator support) @@ -846,7 +901,20 @@ [enable_dec_locator=no]) AC_MSG_RESULT($enable_dec_locator) if test "$enable_dec_locator" = yes ; then - AC_DEFINE(OPT_DEC_LOCATOR,1) + AC_DEFINE(OPT_DEC_LOCATOR,1,[Define to 1 to enable DECterm Locator support]) +fi + +AC_MSG_CHECKING(if you want sixel graphics support) +CF_ARG_ENABLE(sixel-graphics, + [ --enable-sixel-graphics enable sixel graphics support], + [enable_sixel_graphics=yes], + [enable_sixel_graphics=no]) +AC_MSG_RESULT($enable_sixel_graphics) +if test "$enable_sixel_graphics" = yes ; then + AC_DEFINE(OPT_SIXEL_GRAPHICS,1,[Define to 1 to enable sixel graphics support]) + EXTRAHDRS="$EXTRAHDRS graphics.h" + EXTRASRCS="$EXTRASRCS graphics.c" + EXTRAOBJS="$EXTRAOBJS graphics.o" fi AC_MSG_CHECKING(if you want VT420 rectangle support) @@ -856,7 +924,7 @@ [enable_rectangles=yes]) AC_MSG_RESULT($enable_rectangles) if test "$enable_rectangles" = yes ; then - AC_DEFINE(OPT_DEC_RECTOPS,1) + AC_DEFINE(OPT_DEC_RECTOPS,1,[Define to 1 to disable VT420 rectangle support]) fi AC_MSG_CHECKING(if you want -ziconbeep option) @@ -865,7 +933,7 @@ [enable_ziconbeep=no], [enable_ziconbeep=yes]) AC_MSG_RESULT($enable_ziconbeep) -test "$enable_ziconbeep" = no && AC_DEFINE(OPT_ZICONBEEP,0) +test "$enable_ziconbeep" = no && AC_DEFINE(OPT_ZICONBEEP,0,[Define to 0 to disable -ziconbeep option]) ############################################################################### CF_HELP_MESSAGE(Testing/development Options:) @@ -877,21 +945,12 @@ [enable_trace=no]) AC_MSG_RESULT($enable_trace) if test "$enable_trace" = yes ; then - AC_DEFINE(OPT_TRACE) + AC_DEFINE(OPT_TRACE,1,[Define to 1 to enable debugging traces]) EXTRASRCS="$EXTRASRCS trace.c" EXTRAOBJS="$EXTRAOBJS trace.o" fi -AC_MSG_CHECKING(if you want to test memory leaks) -CF_ARG_DISABLE(leaks, - [ --disable-leaks test: set to test memory leaks], - [disable_leaks=yes], - [disable_leaks=no]) -AC_MSG_RESULT($disable_leaks) -if test "$disable_leaks" = yes ; then - AC_DEFINE(NO_LEAKS) -fi - +CF_DISABLE_LEAKS CF_DISABLE_ECHO AC_MSG_CHECKING(if you want magic cookie emulation) @@ -901,7 +960,7 @@ [enable_xmc=no]) AC_MSG_RESULT($enable_xmc) if test "$enable_xmc" = yes ; then - AC_DEFINE(OPT_XMC_GLITCH,1) + AC_DEFINE(OPT_XMC_GLITCH,1,[Define to 1 to enable xmc magic-cookie emulation]) EXTRASRCS="$EXTRASRCS testxmc.c" EXTRAOBJS="$EXTRAOBJS testxmc.o" fi @@ -934,8 +993,8 @@ AC_SUBST(EXTRASRCS) AC_SUBST(EXTRAOBJS) -test "$disable_setuid" = yes && AC_DEFINE(DISABLE_SETUID) -test "$disable_setgid" = yes && AC_DEFINE(DISABLE_SETGID) +test "$disable_setuid" = yes && AC_DEFINE(DISABLE_SETUID,1,[Define to 1 if you want to disable setuid]) +test "$disable_setgid" = yes && AC_DEFINE(DISABLE_SETGID,1,[Define to 1 if you want to disable setgid]) if test $disable_setuid = yes ; then MAY_SETUID="#" diff -Nru xterm-278/ctlseqs.ms xterm-297/ctlseqs.ms --- xterm-278/ctlseqs.ms 2011-12-11 19:18:48.000000000 +0000 +++ xterm-297/ctlseqs.ms 2013-08-22 09:21:50.000000000 +0000 @@ -1,9 +1,9 @@ .\"#! troff -ms $1 -*- Nroff -*- .\" "Xterm Control Sequences" document -.\" $XTermId: ctlseqs.ms,v 1.253 2011/12/11 19:18:48 tom Exp $ +.\" $XTermId: ctlseqs.ms,v 1.299 2013/08/22 09:21:50 tom Exp $ .\" .\" -.\" Copyright 1996-2010,2011 by Thomas E. Dickey +.\" Copyright 1996-2012,2013 by Thomas E. Dickey .\" .\" All Rights Reserved .\" @@ -67,6 +67,11 @@ .\" .\" Run this file through troff and use the -ms macro package. .\" +.ds XT XTerm +.ds xt xterm +.ds LF Patch #297 +.ds RF 2013/08/22 +.\" .if n .pl 9999v \" no page breaks in nroff .ND .\" Start a list of controls @@ -83,7 +88,7 @@ .. .\" Bulleted paragraph .de bP -.IP \(bu 4 +.IP \(bu 0.2i .. .\" Normal leading paragraph .de lP @@ -106,16 +111,18 @@ .de Ss .LP .B +\\$* +.br .. .ds CH \" as nothing -.ds LH Xterm Control Sequences +.ds LH \*(XT Control Sequences .nr s 6*\n(PS/10 .ds L \s\nsBEL\s0 .ds E \s\nsESC\s0 .ds T \s\nsTAB\s0 .ds X \s\nsETX\s0 .ds N \s\nsENQ\s0 -.ds e \s\nsETB\s0 +.ds ET \s\nsETB\s0 .ds C \s\nsCAN\s0 .ds S \s\nsSUB\s0 .\" space between chars @@ -130,7 +137,7 @@ .if \nw>\n([W .nr [W \nw .nr w \w'\*N'u .if \nw>\n([W .nr [W \nw -.nr w \w'\*e'u +.nr w \w'\*(ET'u .if \nw>\n([W .nr [W \nw .nr w \w'\*C'u .if \nw>\n([W .nr [W \nw @@ -158,7 +165,7 @@ .[] Sg \v'-1p'\s\nsSPA\s0\v'1p' .[] Dc \v'-1p'\s\nsDCS\s0\v'1p' .[] Ht \v'-1p'\s\nsHTS\s0\v'1p' -.[] ID \v'-1p'\s\nsIND\s0\v'1p' +.[] Id \v'-1p'\s\nsIND\s0\v'1p' .[] Nl \v'-1p'\s\nsNEL\s0\v'1p' .[] Os \v'-1p'\s\nsOSC\s0\v'1p' .[] RI \v'-1p'\s\nsRI\s0\v'1p' @@ -172,7 +179,7 @@ .[] So \v'-1p'\s\nsSO\s0\v'1p' .[] Sp \v'-1p'\s\nsSP\s0\v'1p' .[] Si \v'-1p'\s\nsSI\s0\v'1p' -.[] Eb \v'-1p'\*e\v'1p' +.[] Eb \v'-1p'\*(ET\v'1p' .[] Ca \v'-1p'\*C\v'1p' .[] Su \v'-1p'\*S\v'1p' .[] Es \v'-1p'\*E\v'1p' @@ -249,6 +256,7 @@ .[] b b .[] c c .[] d d +.[] e e .[] f f .[] g g .[] h h @@ -280,10 +288,14 @@ .ds Cb \fIC\v'.3m'\h'-.2m'\s-2b\s0\v'-.3m'\fP .ds Cx \fIC\v'.3m'\h'-.2m'\s-2x\s0\v'-.3m'\fP .ds Cy \fIC\v'.3m'\h'-.2m'\s-2y\s0\v'-.3m'\fP +.ds Pa \fIP\v'.3m'\h'-.2m'\s-2a\s0\v'-.3m'\fP .ds Pb \fIP\v'.3m'\h'-.2m'\s-2b\s0\v'-.3m'\fP .ds Pc \fIP\v'.3m'\h'-.2m'\s-2c\s0\v'-.3m'\fP .ds Pd \fIP\v'.3m'\h'-.2m'\s-2d\s0\v'-.3m'\fP .ds Pe \fIP\v'.3m'\h'-.2m'\s-2e\s0\v'-.3m'\fP +.ds Pg \fIP\v'.3m'\h'-.2m'\s-2g\s0\v'-.3m'\fP +.ds Ph \fIP\v'.3m'\h'-.2m'\s-2h\s0\v'-.3m'\fP +.ds Pi \fIP\v'.3m'\h'-.2m'\s-2i\s0\v'-.3m'\fP .ds Pl \fIP\v'.3m'\h'-.2m'\s-2l\s0\v'-.3m'\fP .ds Pm \fIP\v'.3m'\h'-.2m'\s-2m\s0\v'-.3m'\fP .ds Pn \fIP\v'.3m'\h'-.2m'\s-2n\s0\v'-.3m'\fP @@ -303,7 +315,7 @@ .el .nr LL 72m .if n .na .TL -Xterm Control Sequences +\*(XT Control Sequences .AU Edward Moy .AI @@ -318,7 +330,8 @@ Thomas Dickey .AI XFree86 Project (1996-2006) -invisible-island.net (2006-2011) +invisible-island.net (2006-2013) +updated for \*(XT \*(LF (\*(RF) .AU . .am BT \" add page numbers after first page @@ -345,7 +358,7 @@ The following pairs of 7-bit and 8-bit control characters are equivalent: .St .IP \\*(Es\\*D -Index (\*(ID is 0x84). +Index (\*(Id is 0x84). .IP \\*(Es\\*E Next Line (\*(Nl is 0x85). .IP \\*(Es\\*H @@ -385,22 +398,27 @@ .Sh "VT100 Mode" .LP Most of these control sequences are standard VT102 control sequences, -but there is support for later DEC VT terminals (i.e., VT220, VT320, VT420), +but there is support for later DEC VT terminals +(i.e., VT220, VT320, VT420, VT510), as well as ISO 6429 and \fIaixterm\fP color controls. The only VT102 feature not supported is auto-repeat, since the only way X provides for this will affect all windows. +.LP There are additional control sequences to provide \fIxterm-\fPdependent functions, such as the scrollbar or window size. Where the function is specified by DEC or ISO 6429, the code assigned to it is given in parentheses. +.LP The escape codes to designate and invoke character sets are specified by ISO 2022; see that document for a discussion of character sets. +.LP +Many of the features are optional; +\fI\*(xt\fP can be configured and built without support for them. . .St .\" -.Ss -Single-character functions +.Ss Single-character functions .\" .IP \\*(Be Bell (Ctrl-G). @@ -443,8 +461,7 @@ .\" .\" .St -.Ss -Controls beginning with \*(Es +.Ss Controls beginning with \*(Es .LP This excludes controls where \*(Es is part of a 7-bit equivalent to 8-bit C1 controls, ordered by the final character(s). .\" @@ -488,17 +505,25 @@ Designate G0 Character Set (ISO 2022, VT100). .br Final character \*(Cc for designating 94-character sets. -In this list, \*0, \*A and \*(cB apply to VT100 and up, the remainder to VT220 and up: +In this list, \*0, \*A and \*(cB apply to VT100 and up, the remainder to VT220 and up. +The VT220 character sets, together with the Portuguese character set are activated by +the National Replacement Character controls. The \*A is a special case, since it is +also activated by the VT300-control for British Latin-1 separately from the National +Replacement Character controls. \*(Cc = \*0 \(-> DEC Special Character and Line Drawing Set. + \*(Cc = \*< \(-> DEC Supplementary (VT200). + \*(Cc = \*%\*5 \(-> DEC Supplementary Graphics (VT300). + \*(Cc = \*> \(-> DEC Technical (VT300). \*(Cc = \*A \(-> United Kingdom (UK). \*(Cc = \*(cB \(-> United States (USASCII). \*(Cc = \*4 \(-> Dutch. \*(Cc = \*C or \*5 \(-> Finnish. - \*(Cc = \*R \(-> French. - \*(Cc = \*Q \(-> French Canadian. + \*(Cc = \*R or \*f \(-> French. + \*(Cc = \*Q or \*9 \(-> French Canadian (VT200, VT300). \*(Cc = \*K \(-> German. \*(Cc = \*Y \(-> Italian. - \*(Cc = \*E or \*6 \(-> Norwegian/Danish. + \*(Cc = \*`, \*E or \*6 \(-> Norwegian/Danish. + \*(Cc = \*%\*6 \(-> Portuguese (VT300). \*(Cc = \*Z \(-> Spanish. \*(Cc = \*H or \*7 \(-> Swedish. \*(Cc = \*= \(-> Swiss. @@ -552,10 +577,10 @@ Forward Index (DECFI), VT420 and up. . .IP \\*(Es\\*= -Application Keypad (DECPAM). +Application Keypad (DECKPAM). . .IP \\*(Es\\*> -Normal Keypad (DECPNM). +Normal Keypad (DECKPNM). . .IP \\*(Es\\*F Cursor to lower left corner of screen. This is @@ -588,16 +613,14 @@ .Ed . .St -.Ss -Application Program-Control functions +.Ss Application Program-Control functions .IP \\*(AP\\*(Pt\\*s\\*(ST None. \fIxterm\fP implements no \*(AP functions; \*(Pt is ignored. \*(Pt need not be printable characters. .Ed . .St -.Ss -Device-Control functions +.Ss Device-Control functions .IP \\*(Dc\\*(Ps\\*;\\*(Ps\\*|\\*(Pt\\*s\\*(ST User-Defined Keys (DECUDK). The first parameter: @@ -619,6 +642,7 @@ \*(c"\*p \(-> DECSCL \*r \(-> DECSTBM \*m \(-> SGR + \*(Sp\*q \(-> DECSCUSR .br \fIxterm\fP responds with \*(Dc\*1\*$\*r\*(Pt\*s\*(ST @@ -651,7 +675,7 @@ \fIxterm\fP responds with \*(Dc\*1\*+\*r\*(Pt\*s\*(ST for valid requests, adding to \*(Pt an \*=, -and the value of the corresponding string that xterm would send, +and the value of the corresponding string that \fI\*(xt\fP would send, or \*(Dc\*0\*+\*r\*(Pt\*s\*(ST for invalid requests. @@ -659,8 +683,7 @@ .Ed .\" .St -.Ss -Functions using \*(Cs, ordered by the final character(s) +.Ss Functions using \*(Cs, ordered by the final character(s) .IP \\*(Cs\\*(Ps\\*s\\*@ Insert \*(Ps (Blank) Character(s) (default = 1) (ICH). . @@ -756,6 +779,9 @@ .IP \\*(Cs\\*(Pm\\*s\\*` Character Position Absolute [column] (default = [row,1]) (HPA). . +.IP \\*(Cs\\*(Pm\\*s\\*a +Character Position Relative [columns] (default = [row,col+1]) (HPR). +. .IP \\*(Cs\\*(Ps\\*s\\*b Repeat the preceding graphic character \*(Ps times (REP). . @@ -774,8 +800,10 @@ \*(Ps = \*2 \(-> Printer. \*(Ps = \*6 \(-> Selective erase. \*(Ps = \*8 \(-> User-defined keys. - \*(Ps = \*9 \(-> National replacement character sets. + \*(Ps = \*9 \(-> National Replacement Character sets. \*(Ps = \*1\*5 \(-> Technical characters. + \*(Ps = \*1\*8 \(-> User windows. + \*(Ps = \*2\*1 \(-> Horizontal scrolling. \*(Ps = \*2\*2 \(-> ANSI color, e.g., VT525. \*(Ps = \*2\*9 \(-> ANSI text locator (i.e., DEC Locator mode). . @@ -789,6 +817,14 @@ where \*(Pp denotes the terminal type \*(Pp = \*0 \(-> ``VT100''. \*(Pp = \*1 \(-> ``VT220''. + \*(Pp = \*2 \(-> ``VT240''. + \*(Pp = \*18 \(-> ``VT330''. + \*(Pp = \*19 \(-> ``VT340''. + \*(Pp = \*24 \(-> ``VT320''. + \*(Pp = \*41 \(-> ``VT420''. + \*(Pp = \*61 \(-> ``VT510''. + \*(Pp = \*64 \(-> ``VT520''. + \*(Pp = \*65 \(-> ``VT525''. .br and \*(Pv is the firmware version (for \fIxterm\fP, this was originally the XFree86 patch number, starting with 95). @@ -798,6 +834,9 @@ .IP \\*(Cs\\*(Pm\\*s\\*d Line Position Absolute [row] (default = [1,column]) (VPA). . +.IP \\*(Cs\\*(Pm\\*s\\*e +Line Position Relative [rows] (default = [row+1,column]) (VPR). +. .IP \\*(Cs\\*(Ps\\*s\\*;\\*(Ps\\*s\\*f Horizontal and Vertical Position [row;column] (default = [1,1]) (HVP). . @@ -836,7 +875,7 @@ \*(Ps = \*3\*8 \(-> Enter Tektronix Mode (DECTEK). \*(Ps = \*4\*0 \(-> Allow 80 \z\(<-\(-> 132 Mode. \*(Ps = \*4\*1 \(-> \fImore\fP(1) fix (see \fBcurses\fP resource). - \*(Ps = \*4\*2 \(-> Enable Nation Replacement Character sets (DECNRCM). + \*(Ps = \*4\*2 \(-> Enable National Replacement Character sets (DECNRCM). \*(Ps = \*4\*4 \(-> Turn On Margin Bell. \*(Ps = \*4\*5 \(-> Reverse-wraparound Mode. \*(Ps = \*4\*6 \(-> Start Logging. @@ -845,14 +884,19 @@ disabled by the \fBtiteInhibit\fP resource). \*(Ps = \*6\*6 \(-> Application keypad (DECNKM). \*(Ps = \*6\*7 \(-> Backarrow key sends backspace (DECBKM). + \*(Ps = \*6\*9 \(-> Enable left and right margin mode (DECLRMM), VT420 and up. + \*(Ps = \*9\*5 \(-> Do not clear screen when DECCOLM is set/reset (DECNCSM), VT510 and up. \*(Ps = \*1\*0\*0\*0 \(-> Send Mouse X & Y on button press and release. See the section \fBMouse Tracking\fP. \*(Ps = \*1\*0\*0\*1 \(-> Use Hilite Mouse Tracking. \*(Ps = \*1\*0\*0\*2 \(-> Use Cell Motion Mouse Tracking. \*(Ps = \*1\*0\*0\*3 \(-> Use All Motion Mouse Tracking. \*(Ps = \*1\*0\*0\*4 \(-> Send FocusIn/FocusOut events. - \*(Ps = \*1\*0\*0\*5 \(-> Enable Extended Mouse Mode. + \*(Ps = \*1\*0\*0\*5 \(-> Enable UTF-8 Mouse Mode. + \*(Ps = \*1\*0\*0\*6 \(-> Enable SGR Mouse Mode. + \*(Ps = \*1\*0\*0\*7 \(-> Enable Alternate Scroll Mode. \*(Ps = \*1\*0\*1\*0 \(-> Scroll to bottom on tty output (rxvt). + \*(Ps = \*1\*0\*1\*5 \(-> Enable urxvt Mouse Mode. \*(Ps = \*1\*0\*1\*1 \(-> Scroll to bottom on key press (rxvt). \*(Ps = \*1\*0\*3\*4 \(-> Interpret "meta" key, sets eighth bit. (enables the \fBeightBitInput\fP resource). @@ -929,7 +973,7 @@ \*(Ps = \*3\*5 \(-> Disable font-shifting functions (rxvt). \*(Ps = \*4\*0 \(-> Disallow 80 \z\(<-\(-> 132 Mode. \*(Ps = \*4\*1 \(-> No \fImore\fP(1) fix (see \fBcurses\fP resource). - \*(Ps = \*4\*2 \(-> Disable Nation Replacement Character sets (DECNRCM). + \*(Ps = \*4\*2 \(-> Disable National Replacement Character sets (DECNRCM). \*(Ps = \*4\*4 \(-> Turn Off Margin Bell. \*(Ps = \*4\*5 \(-> No Reverse-wraparound Mode. \*(Ps = \*4\*6 \(-> Stop Logging. @@ -937,6 +981,8 @@ \*(Ps = \*4\*7 \(-> Use Normal Screen Buffer. \*(Ps = \*6\*6 \(-> Numeric keypad (DECNKM). \*(Ps = \*6\*7 \(-> Backarrow key sends delete (DECBKM). + \*(Ps = \*6\*9 \(-> Disable left and right margin mode (DECLRMM), VT420 and up. + \*(Ps = \*9\*5 \(-> Clear screen when DECCOLM is set/reset (DECNCSM), VT510 and up. \*(Ps = \*1\*0\*0\*0 \(-> Don't send Mouse X & Y on button press and release. See the section \fBMouse Tracking\fP. @@ -944,8 +990,11 @@ \*(Ps = \*1\*0\*0\*2 \(-> Don't use Cell Motion Mouse Tracking. \*(Ps = \*1\*0\*0\*3 \(-> Don't use All Motion Mouse Tracking. \*(Ps = \*1\*0\*0\*4 \(-> Don't send FocusIn/FocusOut events. - \*(Ps = \*1\*0\*0\*5 \(-> Disable Extended Mouse Mode. + \*(Ps = \*1\*0\*0\*5 \(-> Disable UTF-8 Mouse Mode. + \*(Ps = \*1\*0\*0\*6 \(-> Disable SGR Mouse Mode. + \*(Ps = \*1\*0\*0\*7 \(-> Disable Alternate Scroll Mode. \*(Ps = \*1\*0\*1\*0 \(-> Don't scroll to bottom on tty output (rxvt). + \*(Ps = \*1\*0\*1\*5 \(-> Disable urxvt Mouse Mode. \*(Ps = \*1\*0\*1\*1 \(-> Don't scroll to bottom on key press (rxvt). \*(Ps = \*1\*0\*3\*4 \(-> Don't interpret "meta" key. (This disables the \fBeightBitInput\fP resource). @@ -1038,8 +1087,23 @@ the following, from \fIrxvt\fP: \*(Ps = \*1\*0\*0 \(-> Set foreground and background color to default. .sP -If 88- or 256-color support is compiled, the following apply. +\fIXterm\fP maintains a color palette whose entries are identified by an index beginning with zero. +If 88- or 256-color support is compiled, the following apply: +.RS +.bP +All parameters are decimal integers. +.bP +RGB values range from zero (0) to 255. +.bP +ISO-8613-3 can be interpreted in more than one way; +\fIxterm\fP allows the semicolons in this control to be replaced by colons +(but after the first colon, colons must be used). +.RE +.sP +These ISO-8613-3 controls are supported: + \*(Ps = \*3\*8 ; \*2 ; \*(Pr ; \*(Pg ; \*(Pb \(-> Set foreground color to the closest match in \fIxterm\fP's palette for the given RGB \*(Pr/\*(Pg/\*(Pb. \*(Ps = \*3\*8 ; \*5 ; \*(Ps \(-> Set foreground color to the second \*(Ps. + \*(Ps = \*4\*8 ; \*2 ; \*(Pr ; \*(Pg ; \*(Pb \(-> Set background color to the closest match in \fIxterm\fP's palette for the given RGB \*(Pr/\*(Pg/\*(Pb. \*(Ps = \*4\*8 ; \*5 ; \*(Ps \(-> Set background color to the second \*(Ps. .sp . @@ -1050,6 +1114,7 @@ The first parameter identifies the resource to set/reset. The second parameter is the value to assign to the resource. If the second parameter is omitted, the resource is reset to its initial value. + \*(Ps = \*0 \(-> modifyKeyboard. \*(Ps = \*1 \(-> modifyCursorKeys. \*(Ps = \*2 \(-> modifyFunctionKeys. \*(Ps = \*4 \(-> modifyOtherKeys. @@ -1064,6 +1129,21 @@ \*(Ps = \*6 \(-> Report Cursor Position (CPR) [row;column]. Result is .br \*(Cs\*(Ir\*s\*;\*(Ic\*s\*R +.sp +\fBNote\fP: +it is possible for this sequence to be sent by a function key. +For example, with the default keyboard configuration +the shifted F1 key may send (with shift-, control-, alt-modifiers) +.br + \*(Cs\*1\*s\*;\*2\*s\*R, or + \*(Cs\*1\*s\*;\*5\*s\*R, or + \*(Cs\*1\*s\*;\*6\*s\*R, etc. +.br +The second parameter encodes the modifiers; values range from 2 to 16. +See the section \fBPC-Style Function Keys\fP for the codes. +The \fBmodifyFunctionKeys\fP and \fBmodifyKeyboard\fP resources +can change the form of the string sent from the modified F1 key. +.sp . .IP \\*(Cs\\*>\\*(Ps\\*s\\*n Disable modifiers which may be enabled via the @@ -1072,6 +1152,7 @@ This corresponds to a resource value of "-1", which cannot be set with the other sequence. The parameter identifies the resource to be disabled: + \*(Ps = \*0 \(-> modifyKeyboard. \*(Ps = \*1 \(-> modifyCursorKeys. \*(Ps = \*2 \(-> modifyFunctionKeys. \*(Ps = \*4 \(-> modifyOtherKeys. @@ -1083,27 +1164,42 @@ . .IP \\*(Cs\\*?\\*(Ps\\*s\\*n Device Status Report (DSR, DEC-specific). - \*(Ps = \*6 \(-> Report Cursor Position (CPR) [row;column] as + \*(Ps = \*6 \(-> Report Cursor Position (DECXCPR) [row;column] as \*(Cs\*?\*(Ir\*s\*;\*(Ic\*s\*R -(assumes page is zero). +(assumes the default page, i.e., "1"). \*(Ps = \*1\*5 \(-> Report Printer status as -\*(Cs\*?\*1\*0\*s\*n (ready). +\*(Cs\*?\*1\*0\*n (ready). or -\*(Cs\*?\*1\*1\*s\*n (not ready). +\*(Cs\*?\*1\*1\*n (not ready). \*(Ps = \*2\*5 \(-> Report UDK status as -\*(Cs\*?\*2\*0\*s\*n (unlocked) +\*(Cs\*?\*2\*0\*n (unlocked) or -\*(Cs\*?\*2\*1\*s\*n (locked). +\*(Cs\*?\*2\*1\*n (locked). \*(Ps = \*2\*6 \(-> Report Keyboard status as .br -\*(Cs\*?\*2\*7\*s\*;\*s\*1\*s\*;\*s\*0\*s\*;\*s\*0\*s\*n (North American). +\*(Cs\*?\*2\*7\*;\*1\*;\*0\*;\*0\*n (North American). .br The last two parameters apply to VT400 & up, and denote keyboard ready and LK01 respectively. \*(Ps = \*5\*3 \(-> Report Locator status as -.br -\*(Cs\*?\*5\*3\*s\*n Locator available, if compiled-in, or -.br -\*(Cs\*?\*5\*0\*s\*n No Locator, if not. +\*(Cs\*?\*5\*3\*n Locator available, if compiled-in, or +\*(Cs\*?\*5\*0\*n No Locator, if not. + \*(Ps = \*5\*5 \(-> Report Locator status as +\*(Cs\*?\*5\*3\*n Locator available, if compiled-in, or +\*(Cs\*?\*5\*0\*n No Locator, if not. + \*(Ps = \*5\*6 \(-> Report Locator type as +\*(Cs\*?\*5\*7\*;\*1\*n Mouse, if compiled-in, or +\*(Cs\*?\*5\*7\*;\*0\*n Cannot identify, if not. + \*(Ps = \*6\*2 \(-> Report macro space (DECMSR) as +\*(Cs\*(Pn\*s\\*\*s\*{ + \*(Ps = \*6\*3 \(-> Report memory checksum (DECCKSR) as +\*(Dc\*(Pt\*s\*!x\*sx\*sx\*sx\*s\*(ST +.br + \*(Pt is the request id (from an optional parameter to the request). + The x's are hexadecimal digits 0-9 and A-F. + \*(Ps = \*7\*5 \(-> Report data integrity as +\*(Cs\*?\*7\*0\*n (ready, no errors) + \*(Ps = \*8\*5 \(-> Report multi-session configuration as +\*(Cs\*?\*8\*3\*n (not configured for multiple-session operation). . .IP \\*(Cs\\*>\\*(Ps\\*s\\*p Set resource value \fIpointerMode\fP. @@ -1112,14 +1208,15 @@ Valid values for the parameter: \*(Ps = \*0 \(-> never hide the pointer. \*(Ps = \*1 \(-> hide if the mouse tracking mode is not enabled. - \*(Ps = \*2 \(-> always hide the pointer. + \*(Ps = \*2 \(-> always hide the pointer, except when leaving the window. + \*(Ps = \*3 \(-> always hide the pointer, even if leaving/entering the window. If no parameter is given, \fIxterm\fP uses the default, which is \*1. . .IP \\*(Cs\\*!\\*p Soft terminal reset (DECSTR). . -.IP \\*(Cs\\*(Ps\\*$\\*p +.IP \\*(Cs\\*(Ps\\*s\\*$\\*p .br Request ANSI mode (DECRQM). For VT300 and up, reply is @@ -1139,7 +1236,7 @@ Request DEC private mode (DECRQM). For VT300 and up, reply is .br - \*(Cs\*?\*(Ps\*;\*(Pm\*$\*p + \*(Cs\*?\*(Ps\*;\*(Pm\*$\*y .br where \*(Ps is the mode number as in DECSET, \*(Pm is the mode value as in the ANSI DECRQM. @@ -1170,9 +1267,11 @@ Set cursor style (DECSCUSR, VT520). \*(Ps = \*0 \(-> blinking block. \*(Ps = \*1 \(-> blinking block (default). - \*(Ps = \*2 \(-> steady block. - \*(Ps = \*3 \(-> blinking underline. - \*(Ps = \*4 \(-> steady underline. + \*(Ps = \*2 \(-> steady block. + \*(Ps = \*3 \(-> blinking underline. + \*(Ps = \*4 \(-> steady underline. + \*(Ps = \*5 \(-> blinking bar (xterm). + \*(Ps = \*6 \(-> steady bar (xterm). . .IP \\*(Cs\\*(Ps\\*s\\*(c"\\*q Select character protection attribute (DECSCA). @@ -1194,8 +1293,11 @@ \*(Pt\*;\*(Pl\*;\*(Pb\*;\*(Pr denotes the rectangle. \*(Ps denotes the SGR attributes to change: 0, 1, 4, 5, 7. . +.IP \\*(Cs\\*s\\*(Pl\\*s\\*;\\*(Pr\\*s\\*(cs +Set left and right margins (DECSLRM), available only when DECLRMM is enabled (VT420 and up). +. .IP \\*(Cs\\*(cs -Save cursor (ANSI.SYS). +Save cursor (ANSI.SYS), available only when DECLRMM is disabled. . .IP \\*(Cs\\*?\\*(Pm\\*s\\*(cs Save DEC Private Mode Values. @@ -1219,8 +1321,11 @@ Zero parameters use the display's height or width. \*(Ps = \*9\*s\*;\*s\*0 \(-> Restore maximized window. \*(Ps = \*9\*s\*;\*s\*1 \(-> Maximize window (i.e., resize to screen size). + \*(Ps = \*9\*s\*;\*s\*2 \(-> Maximize window vertically. + \*(Ps = \*9\*s\*;\*s\*3 \(-> Maximize window horizontally. \*(Ps = \*1\*0\*s\*;\*s\*0 \(-> Undo full-screen mode. \*(Ps = \*1\*0\*s\*;\*s\*1 \(-> Change to full-screen. + \*(Ps = \*1\*0\*s\*;\*s\*2 \(-> Toggle full-screen. \*(Ps = \*1\*1 \(-> Report \fIxterm\fP window state. If the \fIxterm\fP window is open (non-iconified), it returns \*(Cs\*1\*t. If the \fIxterm\fP window is iconified, it returns \*(Cs\*2\*t. @@ -1307,13 +1412,24 @@ \*(Pn = \*1 \(<- clock multiplier. \*(Pn = \*0 \(<- STP flags. . -.IP \\*(Cs\\*(Ps\\*s\\*x +.IP \\*(Cs\\*(Ps\\*s\\**\\*x Select Attribute Change Extent (DECSACE). \*(Ps = \*0 \(-> from start to end position, wrapped. \*(Ps = \*1 \(-> from start to end position, wrapped. \*(Ps = \*2 \(-> rectangle (exact). . -.IP \\*(Cs\\*(Pc\\*;\\*(Pt\\*;\\*(Pl\\*;\\*(Pb\\*;\\*(Pr\\*$\\*x +.IP \\*(Cs\\*(Pi\\*s\\*;\\*(Pg\\*s\\*;\\*(Pt\\*;\\*(Pl\\*;\\*(Pb\\*;\\*(Pr\\*s\\**\\*y +Request Checksum of Rectangular Area (DECRQCRA), VT420 and up. +Response is +.br +\*(Dc\*(Pt\*s\*!x\*sx\*sx\*sx\*s\*(ST +.br + \*(Pi is the request id. + \*(Pg is the page number. + \*(Pt\*;\*(Pl\*;\*(Pb\*;\*(Pr denotes the rectangle. + The x's are hexadecimal digits 0-9 and A-F. +. +.IP \\*(Cs\\*(Pc\\*s\\*;\\*(Pt\\*s\\*;\\*(Pl\\*s\\*;\\*(Pb\\*s\\*;\\*(Pr\\*s\\*$\\*x Fill Rectangular Area (DECFRA), VT420 and up. \*(Pc is the character to use. \*(Pt\*;\*(Pl\*;\*(Pb\*;\*(Pr denotes the rectangle. @@ -1342,13 +1458,14 @@ .br Valid values for the first (and any additional parameters) are: \*(Ps = \*0 \(-> only respond to explicit host requests (DECRQLP). - (This is default). It also cancels any filter rectangle. + (This is default). It also cancels any filter + rectangle. \*(Ps = \*1 \(-> report button down transitions. \*(Ps = \*2 \(-> do not report button down transitions. \*(Ps = \*3 \(-> report button up transitions. \*(Ps = \*4 \(-> do not report button up transitions. . -.IP \\*(Cs\\*(Pt\\*;\\*(Pl\\*;\\*(Pb\\*;\\*(Pr\\*$\\*{ +.IP \\*(Cs\\*(Pt\\*;\\*(Pl\\*;\\*(Pb\\*;\\*(Pr\\*s\\*$\\*{ Selective Erase Rectangular Area (DECSERA), VT400 and up. \*(Pt\*;\*(Pl\*;\*(Pb\*;\*(Pr denotes the rectangle. . @@ -1358,7 +1475,7 @@ Valid values for the parameter are: \*(Ps = \*0, 1 or omitted \(-> transmit a single DECLRP locator report. .sP -If Locator Reporting has been enabled by a DECELR, xterm will respond +If Locator Reporting has been enabled by a DECELR, \fI\*(xt\fP will respond with a DECLRP Locator Report. This report is also generated on button up and down events if they have been enabled with a DECSLE, or when @@ -1371,7 +1488,7 @@ .br Valid values for the event: \*(Pe = \*0 \(-> locator unavailable - no other parameters sent. - \*(Pe = \*1 \(-> request - xterm received a DECRQLP. + \*(Pe = \*1 \(-> request - \fI\*(xt\fP received a DECRQLP. \*(Pe = \*2 \(-> left button down. \*(Pe = \*3 \(-> left button up. \*(Pe = \*4 \(-> middle button down. @@ -1390,21 +1507,20 @@ \*(Pb & \*8 \(<- M4 button down. .br ``row'' and ``column'' parameters are the coordinates of the locator -position in the xterm window, encoded as ASCII decimal. +position in the \fI\*(xt\fP window, encoded as ASCII decimal. .br -The ``page'' parameter is not used by xterm, and will be omitted. +The ``page'' parameter is not used by \*(xt, and will be omitted. . -.IP \\*(Cs\\*(Pm\\*s\\*(Sp\\*} +.IP \\*(Cs\\*(Pm\\*s\\*(qu\\*} Insert \*(Ps Column(s) (default = 1) (DECIC), VT420 and up. . -.IP \\*(Cs\\*(Pm\\*s\\*(Sp\\*~ +.IP \\*(Cs\\*(Pm\\*s\\*(qu\\*~ Delete \*(Ps Column(s) (default = 1) (DECDC), VT420 and up. . .Ed . .St -.Ss -Operating System Controls +.Ss Operating System Controls . .IP \\*(Os\\*(Ps\\*s\\*;\\*(Pt\\*s\\*(ST .IP \\*(Os\\*(Ps\\*s\\*;\\*(Pt\\*s\\*(Be @@ -1429,7 +1545,7 @@ and if supported, the remainder of the 88-color or 256-color table. .sP If a "?" is given rather than a name or RGB specification, -xterm replies with a control sequence of the same form which can be used +\fI\*(xt\fP replies with a control sequence of the same form which can be used to set the corresponding color. Because more than one pair of color number and specification can be given in one control sequence, \fIxterm\fR can make more than one reply. @@ -1459,7 +1575,7 @@ The colors are specified by name or RGB specification as per \fIXParseColor\fP. .sP If a "?" is given rather than a name or RGB specification, -xterm replies with a control sequence of the same form which can be used +\fI\*(xt\fP replies with a control sequence of the same form which can be used to set the corresponding dynamic color. Because more than one pair of color number and specification can be given in one control sequence, \fIxterm\fR can make more than one reply. @@ -1555,8 +1671,7 @@ \*(Ps = \*1\*1\*8 \(-> Reset Tektronix cursor color. . .St -.Ss -Privacy Message +.Ss Privacy Message .IP \\*(PM\\*(Pt\\*s\\*(ST \fIxterm\fP implements no \*(PM functions; \*(Pt is ignored. \*(Pt need not be printable characters. @@ -1571,7 +1686,7 @@ By using \fIxmodmap\fP one may have the modifier assigned to a different key, and have "real" alt and meta keys. Here is an example: -.DS B +.ID ! put meta on mod3 to distinguish it from alt keycode 64 = Alt_L clear mod1 @@ -1595,12 +1710,15 @@ The table shows the result for a given character "x" with modifiers according to the default translations with the resources set on or off. This assumes \fBaltIsNotMeta\fP is set: -.ne 23 -.TS +.\" page-eject to work around grohtml bugs +.if t .bp +.TS H center; -lf3 lf3 lf3 lf3 lf3w(2c) lf3w(2c) lf3w(2c) lf3w(2c) . _ +.TH +.T& +l | l | l | l . key altSendsEscape metaSendsEscape result _ x off off x @@ -1637,13 +1755,14 @@ .lP The cursor keys transmit the following escape sequences depending on the mode specified via the \fBDECCKM\fP escape sequence. -.ne 10 -.TS +.TS H center; -cf3 cf3 cf3 lf3w(2c) lf3w(2c) lf3w(2c) . Key Normal Application _ +.TH +.T& +l | l | l . Cursor Up \*(Cs\*A \*(S3\*A Cursor Down \*(Cs\*(cB \*(S3\*(cB Cursor Right \*(Cs\*C \*(S3\*C @@ -1654,31 +1773,33 @@ (unlike PageUp and other keys also on the 6-key editing keypad) are considered "cursor keys" by \fIxterm\fP. Their mode is also controlled by the \fBDECCKM\fP escape sequence: -.ne 8 -.TS +.TS H center; -cf3 cf3 cf3 lf3w(2c) lf3w(2c) lf3w(2c) . Key Normal Application _ +.TH +.T& +l | l | l . Home \*(Cs\*H \*(S3\*H End \*(Cs\*F \*(S3\*F _ .TE .lP The application keypad transmits the following escape sequences depending on the -mode specified via the \fBDECPNM\fP and \fBDECPAM\fP escape sequences. +mode specified via the \fBDECKPNM\fP and \fBDECKPAM\fP escape sequences. Use the NumLock key to override the application mode. .lP Not all keys are present on the Sun/PC keypad (e.g., PF1, Tab), but are supported by the program. -.ne 30 -.TS +.TS H center; -cf3 cf3 cf3 cf3 cf3 lf3w(2c) lf3w(2c) lf3w(2c) lf3w(2c) lf3w(2c) . Key Numeric Application Terminfo Termcap _ +.TH +.T& +l | l | l | l | l . Space \*(Sp \*(S3\*(Sp - - Tab \*(Ta \*(S3\*I - - Enter \*(Cr \*(S3\*M kent @8 @@ -1707,13 +1828,14 @@ .TE .br They also provide 12 function keys, as well as a few other special-purpose keys: -.ne 18 -.TS +.TS H center; -cf3 cf3 lf3w(2c) lf3w(2c) . Key Escape Sequence _ +.TH +.T& +l | l . F1 \*(S3\*P F2 \*(S3\*Q F3 \*(S3\*R @@ -1733,13 +1855,14 @@ These can be activated by setting the \fBoldXtermFKeys\fP resource. However, since they do not correspond to any hardware terminal, they have been deprecated. (The DEC VT220 reserves F1 through F5 for local functions such as \fBSetup\fP). -.ne 10 -.TS +.TS H center; -cf3 cf3 lf3w(2c) lf3w(2c) . Key Escape Sequence _ +.TH +.T& +l | l . F1 \*(Cs\*1\*1\*(c~ F2 \*(Cs\*1\*2\*(c~ F3 \*(Cs\*1\*3\*(c~ @@ -1751,13 +1874,14 @@ \fIxterm\fP recognizes function key modifiers which are parameters appended before the final character of the control sequence. -.ne 13 -.TS +.TS H center; -cf3 lf3 cf3w(2c) lf3w(2c) . Code Modifiers _ +.TH +.T& +c | l . 2 Shift 3 Alt 4 Shift + Alt @@ -1765,6 +1889,14 @@ 6 Shift + Control 7 Alt + Control 8 Shift + Alt + Control +9 Meta +10 Meta + Shift +11 Meta + Alt +12 Meta + Alt + Shift +13 Meta + Ctrl +14 Meta + Ctrl + Shift +15 Meta + Ctrl + Alt +16 Meta + Ctrl +Alt + Shift _ .TE For example, shift-F5 would be sent as @@ -1780,13 +1912,14 @@ .lP The VT102/VT220 application keypad transmits unique escape sequences in application mode, which are distinct from the cursor and scrolling keypad: -.ne 32 -.TS +.TS H center; -cf3 cf3 cf3 lf3w(2c) lf3w(2c) lf3w(2c) . Key Numeric Application _ +.TH +.T& +l | l | l . Space \*(Sp \*(S3\*(Sp Tab \*(Ta \*(S3\*I Enter \*(Cr \*(S3\*M @@ -1815,14 +1948,15 @@ .TE The VT220 provides a 6-key editing keypad, which is analogous to that on the PC keyboard. -It is not affected by \fBDECCKM\fP or \fBDECPNM\fP/\fBDECPAM\fP: -.ne 12 -.TS +It is not affected by \fBDECCKM\fP or \fBDECKPNM\fP/\fBDECKPAM\fP: +.TS H center; -cf3 cf3 cf3 lf3w(2c) lf3w(2c) lf3w(2c) . Key Normal Application _ +.TH +.T& +l | l | l . \f1Insert\fP \*(Cs\*2\*(c~ \*(Cs\*2\*(c~ \f1Delete\fP \*(Cs\*3\*(c~ \*(Cs\*3\*(c~ \f1Home\fP \*(Cs\*1\*(c~ \*(Cs\*1\*(c~ @@ -1834,13 +1968,14 @@ .LP The VT220 provides 8 additional function keys. With a Sun/PC keyboard, access these keys by Control/F1 for F13, etc. -.ne 16 -.TS +.TS H center; -cf3 cf3 lf3w(2c) lf3w(2c) . Key Escape Sequence _ +.TH +.T& +l | l . F13 \*(Cs\*2\*5\*(c~ F14 \*(Cs\*2\*6\*(c~ F15 \*(Cs\*2\*8\*(c~ @@ -1856,13 +1991,14 @@ A VT52 does not have function keys, but it does have a numeric keypad and cursor keys. They differ from the other emulations by the prefix. Also, the cursor keys do not change: -.ne 13 -.TS +.TS H center; -cf3 cf3 lf3w(2c) lf3w(2c) . Key Normal/Application _ +.TH +.T& +l | l . Cursor Up \*(Es\*A Cursor Down \*(Es\*(cB Cursor Right \*(Es\*C @@ -1870,13 +2006,14 @@ _ .TE The keypad is similar: -.ne 33 -.TS +.TS H center; -cf3 cf3 cf3 lf3w(2c) lf3w(2c) lf3w(2c) . Key Numeric Application _ +.TH +.T& +l | l | l . Space \*(Sp \*(Es\*?\*(Sp Tab \*(Ta \*(Es\*?\*I Enter \*(Cr \*(Es\*?\*M @@ -2027,7 +2164,7 @@ Manifest constants for the parameter values are defined in \fBxcharmouse.h\fP as follows: . -.DS B +.ID #define SET_X10_MOUSE 9 #define SET_VT200_MOUSE 1000 #define SET_VT200_HIGHLIGHT_MOUSE 1001 @@ -2039,6 +2176,8 @@ #define SET_EXT_MODE_MOUSE 1005 #define SET_SGR_EXT_MODE_MOUSE 1006 #define SET_URXVT_EXT_MODE_MOUSE 1015 + +#define SET_ALTERNATE_SCROLL 1007 .DE .br The motion reporting modes are strictly \fIxterm\fP extensions, and are not @@ -2054,6 +2193,7 @@ The upper left character position on the terminal is denoted as 1,1. This scheme dates back to X10, though the normal mouse-tracking (from X11) is more elaborate. +.Ss X10 compatbility mode .lP X10 compatibility mode sends an escape sequence only on button press, encoding the location and the mouse button pressed. @@ -2065,6 +2205,7 @@ .bP \*(Cx and \*(Cy are the x and y coordinates of the mouse when the button was pressed. +.Ss Normal tracking mode .lP Normal tracking mode sends an escape sequence on both button press and release. @@ -2086,12 +2227,24 @@ .bP \*(Cx and \*(Cy are the x and y coordinates of the mouse event, encoded as in X10 mode. +.Ss Wheel mice .lP Wheel mice may return buttons 4 and 5. Those buttons are represented by the same event codes as buttons 1 and 2 respectively, except that 64 is added to the event code. Release events for the wheel buttons are not reported. +By default, +the wheel mouse events are translated to \fIscroll-back\fP +and \fIscroll-forw\fP actions. +Those actions normally scroll the whole window, +as if the scrollbar was used. +However if Alternate Scroll mode is set, +then cursor up/down controls are sent when the terminal is displaying +the alternate screen. +The initial state of Alternate Scroll mode is set +using the \fBalternateScroll\fP resource. +.Ss Highlight tracking .lP Mouse highlight tracking notifies a program of a button press, receives a range of lines from the program, highlights the region covered by @@ -2131,14 +2284,15 @@ .br The parameters are \fIstartx, starty, endx, endy, mousex,\fP and \fImousey.\fP .RS -.IP \- 5 +.IP \- 0.2i \fIstartx, starty, endx, \fPand\fI endy\fP give the starting and ending character positions of the region. -.IP \- 5 +.IP \- 0.2i \fImousex\fP and \fImousey\fP give the location of the mouse at button up, which may not be over a character. .RE +.Ss Button-event tracking .lP Button-event tracking is essentially the same as normal tracking, but \fIxterm\fP also reports button-motion events. @@ -2159,16 +2313,19 @@ Similarly, motion with button 3 down is reported as \*(Cs\*M\*(cB\*(Cx\*(Cy. (\ \*(cB = 32 + 2 (button 3) + 32 (motion indicator)\ ). +.Ss Any-event tracking .lP Any-event mode is the same as button-event mode, except that all motion events are reported, even if no mouse button is down. It is enabled by specifying 1003 to DECSET. +.Ss FocusIn/FocusOut .lP FocusIn/FocusOut can be combined with any of the mouse events since it uses a different protocol. When set, it causes \fIxterm\fP to send \*(Cs\*I when the terminal gains focus, and \*(Cs\*O when it loses focus. +.Ss Extended coordinates .lP The original X10 mouse protocol limits the \*(Cx and \*(Cy ordinates to 223 (=255\ -\ 32). @@ -2199,13 +2356,17 @@ the \*(Cx and \*(Cy ordinates and a final character which is \*M for button press and \*m for button release. -.IP +.RS +.bP The encoded button value in this case does not add 32 since that was useful only in the X10 scheme for ensuring that the byte containing the button value is a printable code. +.bP The modifiers are encoded in the same way. +.bP A different final character is used for button release to resolve the X10 ambiguity regarding which button was released. +.RE .IP The highlight tracking responses are also modified to an SGR-like format, using the same SGR-style scheme and button-encodings. @@ -2224,6 +2385,38 @@ For these reasons, the 1015 control is not recommended; it is not an improvement over 1005. . +.Sh "Sixel Graphics" +.LP +If \fI\*(xt\fP is configured as +VT240, +VT241, +VT330 or +VT340 +using the \fBdecTerminalID\fP resource, +it supports Sixel Graphics controls, a subset of ReGIS graphics. +.St +.IP \\*(Cs\\*(Ps\\*s\\*c +\fI\*(xt\fP responds to Send Device Attributes (Primary DA) with these +additional codes: + \*(Ps = \*3 \(-> ReGIS graphics. + \*(Ps = \*4 \(-> SIXEL graphics. +.IP \\*(Cs\\*?\\*(Pm\\*s\\*h +\fI\*(xt\fP has these additional private Set Mode values: + \*(Ps = \*8\*0 \(-> SIXEL scrolling. + \*(Ps = \*1\*0\*7\*0 \(-> use private color registers for each graphic. +.IP \\*(Dc\\*(Pa\\*;\\*(Pb\\*;\\*(Ph\\*s\\*q\\*s\\*(Ps..\\*(Ps\fP\\*(ST +See +.ID +http://vt100.net/docs/vt3xx-gp/chapter14.html +.DE +The sixel data device control string has three positional parameters, +following the \*q with sixel data. + \*(Pa \(-> pixel aspect ratio + \*(Pb \(-> background color option + \*(Ph \(-> horizontal grid size (ignored). + \*(Ps \(-> sixel data +.Ed +. .Sh "Tektronix 4014 Mode" .LP Most of these sequences are standard Tektronix 4014 control sequences. diff -Nru xterm-278/ctlseqs.txt xterm-297/ctlseqs.txt --- xterm-278/ctlseqs.txt 2011-12-11 19:18:48.000000000 +0000 +++ xterm-297/ctlseqs.txt 2013-08-22 09:22:13.000000000 +0000 @@ -7,7 +7,8 @@ - Xterm Control Sequences + XTerm Control Sequences + Edward Moy University of California, Berkeley @@ -19,7 +20,8 @@ Thomas Dickey XFree86 Project (1996-2006) - invisible-island.net (2006-2011) + invisible-island.net (2006-2013) + updated for XTerm Patch #297 (2013/08/22) @@ -85,14 +87,17 @@ VT100 Mode Most of these control sequences are standard VT102 control sequences, but there is support for later DEC VT terminals (i.e., VT220, VT320, -VT420), as well as ISO 6429 and aixterm color controls. The only VT102 -feature not supported is auto-repeat, since the only way X provides for -this will affect all windows. There are additional control sequences to -provide xterm-dependent functions, such as the scrollbar or window size. -Where the function is specified by DEC or ISO 6429, the code assigned to -it is given in parentheses. The escape codes to designate and invoke -character sets are specified by ISO 2022; see that document for a dis- -cussion of character sets. +VT420, VT510), as well as ISO 6429 and aixterm color controls. The only +VT102 feature not supported is auto-repeat, since the only way X pro- +vides for this will affect all windows. +There are additional control sequences to provide xterm-dependent func- +tions, such as the scrollbar or window size. Where the function is +specified by DEC or ISO 6429, the code assigned to it is given in paren- +theses. +The escape codes to designate and invoke character sets are specified by +ISO 2022; see that document for a discussion of character sets. +Many of the features are optional; xterm can be configured and built +without support for them. Single-character functions BEL Bell (Ctrl-G). @@ -128,17 +133,26 @@ ESC ( C Designate G0 Character Set (ISO 2022, VT100). Final character C for designating 94-character sets. In this list, 0 , A and B apply to VT100 and up, the remainder to - VT220 and up: + VT220 and up. The VT220 character sets, together with the + Portuguese character set are activated by the National + Replacement Character controls. The A is a special case, + since it is also activated by the VT300-control for British + Latin-1 separately from the National Replacement Character + controls. C = 0 -> DEC Special Character and Line Drawing Set. + C = < -> DEC Supplementary (VT200). + C = % 5 -> DEC Supplementary Graphics (VT300). + C = > -> DEC Technical (VT300). C = A -> United Kingdom (UK). C = B -> United States (USASCII). C = 4 -> Dutch. C = C or 5 -> Finnish. - C = R -> French. - C = Q -> French Canadian. + C = R or f -> French. + C = Q or 9 -> French Canadian (VT200, VT300). C = K -> German. C = Y -> Italian. - C = E or 6 -> Norwegian/Danish. + C = ` , E or 6 -> Norwegian/Danish. + C = % 6 -> Portuguese (VT300). C = Z -> Spanish. C = H or 7 -> Swedish. C = = -> Swiss. @@ -159,8 +173,8 @@ ESC 7 Save Cursor (DECSC). ESC 8 Restore Cursor (DECRC). ESC 9 Forward Index (DECFI), VT420 and up. -ESC = Application Keypad (DECPAM). -ESC > Normal Keypad (DECPNM). +ESC = Application Keypad (DECKPAM). +ESC > Normal Keypad (DECKPNM). ESC F Cursor to lower left corner of screen. This is enabled by the hpLowerleftBugCompat resource. ESC c Full Reset (RIS). @@ -197,6 +211,7 @@ " p -> DECSCL r -> DECSTBM m -> SGR + SP q -> DECSCUSR xterm responds with DCS 1 $ r Pt ST for valid requests, replacing the Pt with the corresponding CSI string, or DCS 0 $ r Pt ST for invalid requests. @@ -208,8 +223,8 @@ as by the Request Termcap/Terminfo String control. DCS + q Pt ST Request Termcap/Terminfo String (xterm, experimental). The - string following the "q" is a list of names encoded in hex- - adecimal (2 digits per character) separated by ; which corre- + string following the "q" is a list of names encoded in hexa- + decimal (2 digits per character) separated by ; which corre- spond to termcap or terminfo key names. Two special features are also recognized, which are not key names: Co for termcap colors (or colors for terminfo colors), @@ -275,6 +290,8 @@ CSI Ps Z Cursor Backward Tabulation Ps tab stops (default = 1) (CBT). CSI Pm ` Character Position Absolute [column] (default = [row,1]) (HPA). +CSI Pm a Character Position Relative [columns] (default = [row,col+1]) + (HPR). CSI Ps b Repeat the preceding graphic character Ps times (REP). CSI Ps c Send Device Attributes (Primary DA). Ps = 0 or omitted -> request attributes from terminal. The @@ -290,8 +307,10 @@ Ps = 2 -> Printer. Ps = 6 -> Selective erase. Ps = 8 -> User-defined keys. - Ps = 9 -> National replacement character sets. + Ps = 9 -> National Replacement Character sets. Ps = 1 5 -> Technical characters. + Ps = 1 8 -> User windows. + Ps = 2 1 -> Horizontal scrolling. Ps = 2 2 -> ANSI color, e.g., VT525. Ps = 2 9 -> ANSI text locator (i.e., DEC Locator mode). CSI > Ps c @@ -304,11 +323,21 @@ where Pp denotes the terminal type Pp = 0 -> ``VT100''. Pp = 1 -> ``VT220''. + Pp = 2 -> ``VT240''. + Pp = 1 8 -> ``VT330''. + Pp = 1 9 -> ``VT340''. + Pp = 2 4 -> ``VT320''. + Pp = 4 1 -> ``VT420''. + Pp = 6 1 -> ``VT510''. + Pp = 6 4 -> ``VT520''. + Pp = 6 5 -> ``VT525''. and Pv is the firmware version (for xterm, this was originally the XFree86 patch number, starting with 95). In a DEC termi- nal, Pc indicates the ROM cartridge registration number and is always zero. CSI Pm d Line Position Absolute [row] (default = [1,column]) (VPA). +CSI Pm e Line Position Relative [rows] (default = [row+1,column]) + (VPR). CSI Ps ; Ps f Horizontal and Vertical Position [row;column] (default = [1,1]) (HVP). @@ -343,8 +372,8 @@ Ps = 3 8 -> Enter Tektronix Mode (DECTEK). Ps = 4 0 -> Allow 80 -> 132 Mode. Ps = 4 1 -> more(1) fix (see curses resource). - Ps = 4 2 -> Enable Nation Replacement Character sets (DECN- - RCM). + Ps = 4 2 -> Enable National Replacement Character sets + (DECNRCM). Ps = 4 4 -> Turn On Margin Bell. Ps = 4 5 -> Reverse-wraparound Mode. Ps = 4 6 -> Start Logging. This is normally disabled by a @@ -353,14 +382,21 @@ abled by the titeInhibit resource). Ps = 6 6 -> Application keypad (DECNKM). Ps = 6 7 -> Backarrow key sends backspace (DECBKM). + Ps = 6 9 -> Enable left and right margin mode (DECLRMM), + VT420 and up. + Ps = 9 5 -> Do not clear screen when DECCOLM is set/reset + (DECNCSM), VT510 and up. Ps = 1 0 0 0 -> Send Mouse X & Y on button press and release. See the section Mouse Tracking. Ps = 1 0 0 1 -> Use Hilite Mouse Tracking. Ps = 1 0 0 2 -> Use Cell Motion Mouse Tracking. Ps = 1 0 0 3 -> Use All Motion Mouse Tracking. Ps = 1 0 0 4 -> Send FocusIn/FocusOut events. - Ps = 1 0 0 5 -> Enable Extended Mouse Mode. + Ps = 1 0 0 5 -> Enable UTF-8 Mouse Mode. + Ps = 1 0 0 6 -> Enable SGR Mouse Mode. + Ps = 1 0 0 7 -> Enable Alternate Scroll Mode. Ps = 1 0 1 0 -> Scroll to bottom on tty output (rxvt). + Ps = 1 0 1 5 -> Enable urxvt Mouse Mode. Ps = 1 0 1 1 -> Scroll to bottom on key press (rxvt). Ps = 1 0 3 4 -> Interpret "meta" key, sets eighth bit. (enables the eightBitInput resource). @@ -433,8 +469,8 @@ Ps = 3 5 -> Disable font-shifting functions (rxvt). Ps = 4 0 -> Disallow 80 -> 132 Mode. Ps = 4 1 -> No more(1) fix (see curses resource). - Ps = 4 2 -> Disable Nation Replacement Character sets (DEC- - NRCM). + Ps = 4 2 -> Disable National Replacement Character sets + (DECNRCM). Ps = 4 4 -> Turn Off Margin Bell. Ps = 4 5 -> No Reverse-wraparound Mode. Ps = 4 6 -> Stop Logging. (This is normally disabled by a @@ -442,15 +478,22 @@ Ps = 4 7 -> Use Normal Screen Buffer. Ps = 6 6 -> Numeric keypad (DECNKM). Ps = 6 7 -> Backarrow key sends delete (DECBKM). + Ps = 6 9 -> Disable left and right margin mode (DECLRMM), + VT420 and up. + Ps = 9 5 -> Clear screen when DECCOLM is set/reset (DEC- + NCSM), VT510 and up. Ps = 1 0 0 0 -> Don't send Mouse X & Y on button press and release. See the section Mouse Tracking. Ps = 1 0 0 1 -> Don't use Hilite Mouse Tracking. Ps = 1 0 0 2 -> Don't use Cell Motion Mouse Tracking. Ps = 1 0 0 3 -> Don't use All Motion Mouse Tracking. Ps = 1 0 0 4 -> Don't send FocusIn/FocusOut events. - Ps = 1 0 0 5 -> Disable Extended Mouse Mode. + Ps = 1 0 0 5 -> Disable UTF-8 Mouse Mode. + Ps = 1 0 0 6 -> Disable SGR Mouse Mode. + Ps = 1 0 0 7 -> Disable Alternate Scroll Mode. Ps = 1 0 1 0 -> Don't scroll to bottom on tty output (rxvt). + Ps = 1 0 1 5 -> Disable urxvt Mouse Mode. Ps = 1 0 1 1 -> Don't scroll to bottom on key press (rxvt). Ps = 1 0 3 4 -> Don't interpret "meta" key. (This disables the eightBitInput resource). @@ -545,9 +588,22 @@ Ps = 1 0 0 -> Set foreground and background color to default. - If 88- or 256-color support is compiled, the following apply. + Xterm maintains a color palette whose entries are identified + by an index beginning with zero. If 88- or 256-color support + is compiled, the following apply: + o All parameters are decimal integers. + o RGB values range from zero (0) to 255. + o ISO-8613-3 can be interpreted in more than one way; xterm + allows the semicolons in this control to be replaced by + colons (but after the first colon, colons must be used). + + These ISO-8613-3 controls are supported: + Ps = 3 8 ; 2 ; Pr ; Pg ; Pb -> Set foreground color to the + closest match in xterm's palette for the given RGB Pr/Pg/Pb. Ps = 3 8 ; 5 ; Ps -> Set foreground color to the second Ps. + Ps = 4 8 ; 2 ; Pr ; Pg ; Pb -> Set background color to the + closest match in xterm's palette for the given RGB Pr/Pg/Pb. Ps = 4 8 ; 5 ; Ps -> Set background color to the second Ps. @@ -558,6 +614,7 @@ tifies the resource to set/reset. The second parameter is the value to assign to the resource. If the second parameter is omitted, the resource is reset to its initial value. + Ps = 0 -> modifyKeyboard. Ps = 1 -> modifyCursorKeys. Ps = 2 -> modifyFunctionKeys. Ps = 4 -> modifyOtherKeys. @@ -569,11 +626,26 @@ Ps = 6 -> Report Cursor Position (CPR) [row;column]. Result is CSI r ; c R + + Note: it is possible for this sequence to be sent by a func- + tion key. For example, with the default keyboard configura- + tion the shifted F1 key may send (with shift-, control-, alt- + modifiers) + CSI 1 ; 2 R , or + CSI 1 ; 5 R , or + CSI 1 ; 6 R , etc. + The second parameter encodes the modifiers; values range from + 2 to 16. See the section PC-Style Function Keys for the + codes. The modifyFunctionKeys and modifyKeyboard resources + can change the form of the string sent from the modified F1 + key. + CSI > Ps n Disable modifiers which may be enabled via the CSI > Ps; Ps m sequence. This corresponds to a resource value of "-1", which cannot be set with the other sequence. The parameter identi- fies the resource to be disabled: + Ps = 0 -> modifyKeyboard. Ps = 1 -> modifyCursorKeys. Ps = 2 -> modifyFunctionKeys. Ps = 4 -> modifyOtherKeys. @@ -584,29 +656,45 @@ fiers. CSI ? Ps n Device Status Report (DSR, DEC-specific). - Ps = 6 -> Report Cursor Position (CPR) [row;column] as CSI - ? r ; c R (assumes page is zero). - Ps = 1 5 -> Report Printer status as CSI ? 1 0 n (ready). - or CSI ? 1 1 n (not ready). - Ps = 2 5 -> Report UDK status as CSI ? 2 0 n (unlocked) - or CSI ? 2 1 n (locked). + Ps = 6 -> Report Cursor Position (DECXCPR) [row;column] as + CSI ? r ; c R (assumes the default page, i.e., "1"). + Ps = 1 5 -> Report Printer status as CSI ? 1 0 n (ready). + or CSI ? 1 1 n (not ready). + Ps = 2 5 -> Report UDK status as CSI ? 2 0 n (unlocked) or + CSI ? 2 1 n (locked). Ps = 2 6 -> Report Keyboard status as - CSI ? 2 7 ; 1 ; 0 ; 0 n (North American). + CSI ? 2 7 ; 1 ; 0 ; 0 n (North American). The last two parameters apply to VT400 & up, and denote key- board ready and LK01 respectively. - Ps = 5 3 -> Report Locator status as - CSI ? 5 3 n Locator available, if compiled-in, or - CSI ? 5 0 n No Locator, if not. + Ps = 5 3 -> Report Locator status as CSI ? 5 3 n Locator + available, if compiled-in, or CSI ? 5 0 n No Locator, if not. + Ps = 5 5 -> Report Locator status as CSI ? 5 3 n Locator + available, if compiled-in, or CSI ? 5 0 n No Locator, if not. + Ps = 5 6 -> Report Locator type as CSI ? 5 7 ; 1 n Mouse, + if compiled-in, or CSI ? 5 7 ; 0 n Cannot identify, if not. + Ps = 6 2 -> Report macro space (DECMSR) as CSI Pn \* { + Ps = 6 3 -> Report memory checksum (DECCKSR) as DCS Pt ! x + x x x ST + Pt is the request id (from an optional parameter to the + request). + The x's are hexadecimal digits 0-9 and A-F. + Ps = 7 5 -> Report data integrity as CSI ? 7 0 n (ready, + no errors) + Ps = 8 5 -> Report multi-session configuration as CSI ? 8 3 + n (not configured for multiple-session operation). CSI > Ps p Set resource value pointerMode. This is used by xterm to decide whether to hide the pointer cursor as the user types. Valid values for the parameter: Ps = 0 -> never hide the pointer. Ps = 1 -> hide if the mouse tracking mode is not enabled. - Ps = 2 -> always hide the pointer. If no parameter is - given, xterm uses the default, which is 1 . + Ps = 2 -> always hide the pointer, except when leaving the + window. + Ps = 3 -> always hide the pointer, even if leaving/entering + the window. If no parameter is given, xterm uses the default, + which is 1 . CSI ! p Soft terminal reset (DECSTR). -CSI Ps$ p +CSI Ps $ p Request ANSI mode (DECRQM). For VT300 and up, reply is CSI Ps; Pm$ y where Ps is the mode number as in RM, and Pm is the mode @@ -618,7 +706,7 @@ 4 - permanently reset CSI ? Ps$ p Request DEC private mode (DECRQM). For VT300 and up, reply is - CSI ? Ps; Pm$ p + CSI ? Ps; Pm$ y where Ps is the mode number as in DECSET, Pm is the mode value as in the ANSI DECRQM. CSI Ps ; Ps " p @@ -646,6 +734,8 @@ Ps = 2 -> steady block. Ps = 3 -> blinking underline. Ps = 4 -> steady underline. + Ps = 5 -> blinking bar (xterm). + Ps = 6 -> steady bar (xterm). CSI Ps " q Select character protection attribute (DECSCA). Valid values for the parameter: @@ -662,7 +752,11 @@ Change Attributes in Rectangular Area (DECCARA), VT400 and up. Pt; Pl; Pb; Pr denotes the rectangle. Ps denotes the SGR attributes to change: 0, 1, 4, 5, 7. -CSI s Save cursor (ANSI.SYS). +CSI Pl ; Pr s + Set left and right margins (DECSLRM), available only when + DECLRMM is enabled (VT420 and up). +CSI s Save cursor (ANSI.SYS), available only when DECLRMM is dis- + abled. CSI ? Pm s Save DEC Private Mode Values. Ps values are the same as for DECSET. @@ -690,8 +784,11 @@ Ps = 9 ; 0 -> Restore maximized window. Ps = 9 ; 1 -> Maximize window (i.e., resize to screen size). + Ps = 9 ; 2 -> Maximize window vertically. + Ps = 9 ; 3 -> Maximize window horizontally. Ps = 1 0 ; 0 -> Undo full-screen mode. Ps = 1 0 ; 1 -> Change to full-screen. + Ps = 1 0 ; 2 -> Toggle full-screen. Ps = 1 1 -> Report xterm window state. If the xterm window is open (non-iconified), it returns CSI 1 t . If the xterm window is iconified, it returns CSI 2 t . @@ -768,11 +865,20 @@ Pn = 1 <- 2 8 receive 38.4k baud. Pn = 1 <- clock multiplier. Pn = 0 <- STP flags. -CSI Ps x Select Attribute Change Extent (DECSACE). +CSI Ps * x + Select Attribute Change Extent (DECSACE). Ps = 0 -> from start to end position, wrapped. Ps = 1 -> from start to end position, wrapped. Ps = 2 -> rectangle (exact). -CSI Pc; Pt; Pl; Pb; Pr$ x +CSI Pi ; Pg ; Pt; Pl; Pb; Pr * y + Request Checksum of Rectangular Area (DECRQCRA), VT420 and up. + Response is + DCS Pt ! x x x x ST + Pi is the request id. + Pg is the page number. + Pt; Pl; Pb; Pr denotes the rectangle. + The x's are hexadecimal digits 0-9 and A-F. +CSI Pc ; Pt ; Pl ; Pb ; Pr $ x Fill Rectangular Area (DECFRA), VT420 and up. Pc is the character to use. Pt; Pl; Pb; Pr denotes the rectangle. @@ -797,12 +903,12 @@ are: Ps = 0 -> only respond to explicit host requests (DECRQLP). (This is default). It also cancels any filter - rectangle. + rectangle. Ps = 1 -> report button down transitions. Ps = 2 -> do not report button down transitions. Ps = 3 -> report button up transitions. Ps = 4 -> do not report button up transitions. -CSI Pt; Pl; Pb; Pr$ { +CSI Pt; Pl; Pb; Pr $ { Selective Erase Rectangular Area (DECSERA), VT400 and up. Pt; Pl; Pb; Pr denotes the rectangle. CSI Ps ' | @@ -845,9 +951,9 @@ mal. The ``page'' parameter is not used by xterm, and will be omit- ted. -CSI Pm SP } +CSI Pm ' } Insert Ps Column(s) (default = 1) (DECIC), VT420 and up. -CSI Pm SP ~ +CSI Pm ' ~ Delete Ps Column(s) (default = 1) (DECDC), VT420 and up. Operating System Controls @@ -992,13 +1098,13 @@ using xmodmap one may have the modifier assigned to a different key, and have "real" alt and meta keys. Here is an example: - ! put meta on mod3 to distinguish it from alt - keycode 64 = Alt_L - clear mod1 - add mod1 = Alt_L - keycode 115 = Meta_L - clear mod3 - add mod3 = Meta_L + ! put meta on mod3 to distinguish it from alt + keycode 64 = Alt_L + clear mod1 + add mod1 = Alt_L + keycode 115 = Meta_L + clear mod3 + add mod3 = Meta_L The metaSendsEscape resource (and altSendsEscape if altIsNotMeta is set) @@ -1013,24 +1119,24 @@ ----------------------------------------------------------- key altSendsEscape metaSendsEscape result - ----------------------------------------------------------- - x off off x - Meta-x off off shift - Alt-x off off shift - Alt+Meta-x off off shift - x ON off x - Meta-x ON off shift - Alt-x ON off ESC x - Alt+Meta-x ON off ESC shift - x off ON x - Meta-x off ON ESC x - Alt-x off ON shift - Alt+Meta-x off ON ESC shift - x ON ON x - Meta-x ON ON ESC x - Alt-x ON ON ESC x - Alt+Meta-x ON ON ESC x - ----------------------------------------------------------- + -----------+----------------+-----------------+------------ + x | off | off | x + Meta-x | off | off | shift + Alt-x | off | off | shift + Alt+Meta-x | off | off | shift + x | ON | off | x + Meta-x | ON | off | shift + Alt-x | ON | off | ESC x + Alt+Meta-x | ON | off | ESC shift + x | off | ON | x + Meta-x | off | ON | ESC x + Alt-x | off | ON | shift + Alt+Meta-x | off | ON | ESC shift + x | ON | ON | x + Meta-x | ON | ON | ESC x + Alt-x | ON | ON | ESC x + Alt+Meta-x | ON | ON | ESC x + -----------+----------------+-----------------+------------ PC-Style Function Keys @@ -1048,78 +1154,78 @@ The cursor keys transmit the following escape sequences depending on the mode specified via the DECCKM escape sequence. - Key Normal Application - -------------------------------------- - Cursor Up CSI A SS3 A - Cursor Down CSI B SS3 B - Cursor Right CSI C SS3 C - Cursor Left CSI D SS3 D - -------------------------------------- + Key Normal Application + -------------+----------+------------- + Cursor Up | CSI A | SS3 A + Cursor Down | CSI B | SS3 B + Cursor Right | CSI C | SS3 C + Cursor Left | CSI D | SS3 D + -------------+----------+------------- The home- and end-keys (unlike PageUp and other keys also on the 6-key editing keypad) are considered "cursor keys" by xterm. Their mode is also controlled by the DECCKM escape sequence: - Key Normal Application - ---------------------------------- - Home CSI H SS3 H - End CSI F SS3 F - ---------------------------------- + Key Normal Application + ---------+----------+------------- + Home | CSI H | SS3 H + End | CSI F | SS3 F + ---------+----------+------------- The application keypad transmits the following escape sequences depend- -ing on the mode specified via the DECPNM and DECPAM escape sequences. +ing on the mode specified via the DECKPNM and DECKPAM escape sequences. Use the NumLock key to override the application mode. Not all keys are present on the Sun/PC keypad (e.g., PF1, Tab), but are supported by the program. - Key Numeric Application Terminfo Termcap - -------------------------------------------------------------- - Space SP SS3 SP - - - Tab TAB SS3 I - - - Enter CR SS3 M kent @8 - PF1 SS3 P SS3 P kf1 k1 - PF2 SS3 Q SS3 Q kf2 k2 - PF3 SS3 R SS3 R kf3 k3 - PF4 SS3 S SS3 S kf4 k4 - * (multiply) * SS3 j - - - + (add) + SS3 k - - - , (comma) , SS3 l - - - - (minus) - SS3 m - - - . (Delete) . CSI 3 ~ - - - / (divide) / SS3 o - - - 0 (Insert) 0 CSI 2 ~ - - - 1 (End) 1 SS3 F kc1 K4 - 2 (DownArrow) 2 CSI B - - - 3 (PageDown) 3 CSI 6 ~ kc3 K5 - 4 (LeftArrow) 4 CSI D - - - 5 (Begin) 5 CSI E kb2 K2 - 6 (RightArrow) 6 CSI C - - - 7 (Home) 7 SS3 H ka1 K1 - 8 (UpArrow) 8 CSI A - - - 9 (PageUp) 9 CSI 5 ~ ka3 K3 - = (equal) = SS3 X - - - -------------------------------------------------------------- + Key Numeric Application Terminfo Termcap + ---------------+----------+-------------+----------+---------- + Space | SP | SS3 SP | - | - + Tab | TAB | SS3 I | - | - + Enter | CR | SS3 M | kent | @8 + PF1 | SS3 P | SS3 P | kf1 | k1 + PF2 | SS3 Q | SS3 Q | kf2 | k2 + PF3 | SS3 R | SS3 R | kf3 | k3 + PF4 | SS3 S | SS3 S | kf4 | k4 + * (multiply) | * | SS3 j | - | - + + (add) | + | SS3 k | - | - + , (comma) | , | SS3 l | - | - + - (minus) | - | SS3 m | - | - + . (Delete) | . | CSI 3 ~ | - | - + / (divide) | / | SS3 o | - | - + 0 (Insert) | 0 | CSI 2 ~ | - | - + 1 (End) | 1 | SS3 F | kc1 | K4 + 2 (DownArrow) | 2 | CSI B | - | - + 3 (PageDown) | 3 | CSI 6 ~ | kc3 | K5 + 4 (LeftArrow) | 4 | CSI D | - | - + 5 (Begin) | 5 | CSI E | kb2 | K2 + 6 (RightArrow) | 6 | CSI C | - | - + 7 (Home) | 7 | SS3 H | ka1 | K1 + 8 (UpArrow) | 8 | CSI A | - | - + 9 (PageUp) | 9 | CSI 5 ~ | ka3 | K3 + = (equal) | = | SS3 X | - | - + ---------------+----------+-------------+----------+---------- They also provide 12 function keys, as well as a few other special-pur- pose keys: - Key Escape Sequence - --------------------------- - F1 SS3 P - F2 SS3 Q - F3 SS3 R - F4 SS3 S - F5 CSI 1 5 ~ - F6 CSI 1 7 ~ - F7 CSI 1 8 ~ - F8 CSI 1 9 ~ - F9 CSI 2 0 ~ - F10 CSI 2 1 ~ - F11 CSI 2 3 ~ - F12 CSI 2 4 ~ - --------------------------- + Key Escape Sequence + ---------+----------------- + F1 | SS3 P + F2 | SS3 Q + F3 | SS3 R + F4 | SS3 S + F5 | CSI 1 5 ~ + F6 | CSI 1 7 ~ + F7 | CSI 1 8 ~ + F8 | CSI 1 9 ~ + F9 | CSI 2 0 ~ + F10 | CSI 2 1 ~ + F11 | CSI 2 3 ~ + F12 | CSI 2 4 ~ + ---------+----------------- Older versions of xterm implement different escape sequences for F1 @@ -1128,28 +1234,36 @@ nal, they have been deprecated. (The DEC VT220 reserves F1 through F5 for local functions such as Setup). - Key Escape Sequence - --------------------------- - F1 CSI 1 1 ~ - F2 CSI 1 2 ~ - F3 CSI 1 3 ~ - F4 CSI 1 4 ~ - --------------------------- + Key Escape Sequence + ---------+----------------- + F1 | CSI 1 1 ~ + F2 | CSI 1 2 ~ + F3 | CSI 1 3 ~ + F4 | CSI 1 4 ~ + ---------+----------------- In normal mode, i.e., a Sun/PC keyboard when the sunKeyboard resource is false, xterm recognizes function key modifiers which are parameters appended before the final character of the control sequence. - Code Modifiers - --------------------------------- - 2 Shift - 3 Alt - 4 Shift + Alt - 5 Control - 6 Shift + Control - 7 Alt + Control - 8 Shift + Alt + Control - --------------------------------- + Code Modifiers + ---------+-------------------------- + 2 | Shift + 3 | Alt + 4 | Shift + Alt + 5 | Control + 6 | Shift + Control + 7 | Alt + Control + 8 | Shift + Alt + Control + 9 | Meta + 10 | Meta + Shift + 11 | Meta + Alt + 12 | Meta + Alt + Shift + 13 | Meta + Ctrl + 14 | Meta + Ctrl + Shift + 15 | Meta + Ctrl + Alt + 16 | Meta + Ctrl +Alt + Shift + ---------+-------------------------- For example, shift-F5 would be sent as CSI 1 5 ; 2 ~ @@ -1165,61 +1279,61 @@ application mode, which are distinct from the cursor and scrolling key- pad: - Key Numeric Application - -------------------------------------- - Space SP SS3 SP - Tab TAB SS3 I - Enter CR SS3 M - PF1 SS3 P SS3 P - PF2 SS3 Q SS3 Q - PF3 SS3 R SS3 R - PF4 SS3 S SS3 S - * (multiply) * SS3 j - + (add) + SS3 k - , (comma) , SS3 l - - (minus) - SS3 m - . (period) . SS3 n - / (divide) / SS3 o - 0 0 SS3 p - 1 1 SS3 q - 2 2 SS3 r - 3 3 SS3 s - 4 4 SS3 t - 5 5 SS3 u - 6 6 SS3 v - 7 7 SS3 w - 8 8 SS3 x - 9 9 SS3 y - = (equal) = SS3 X - -------------------------------------- + Key Numeric Application + -------------+----------+------------- + Space | SP | SS3 SP + Tab | TAB | SS3 I + Enter | CR | SS3 M + PF1 | SS3 P | SS3 P + PF2 | SS3 Q | SS3 Q + PF3 | SS3 R | SS3 R + PF4 | SS3 S | SS3 S + * (multiply) | * | SS3 j + + (add) | + | SS3 k + , (comma) | , | SS3 l + - (minus) | - | SS3 m + . (period) | . | SS3 n + / (divide) | / | SS3 o + 0 | 0 | SS3 p + 1 | 1 | SS3 q + 2 | 2 | SS3 r + 3 | 3 | SS3 s + 4 | 4 | SS3 t + 5 | 5 | SS3 u + 6 | 6 | SS3 v + 7 | 7 | SS3 w + 8 | 8 | SS3 x + 9 | 9 | SS3 y + = (equal) | = | SS3 X + -------------+----------+------------- The VT220 provides a 6-key editing keypad, which is analogous to that on -the PC keyboard. It is not affected by DECCKM or DECPNM/DECPAM: +the PC keyboard. It is not affected by DECCKM or DECKPNM/DECKPAM: - Key Normal Application - ---------------------------------- - Insert CSI 2 ~ CSI 2 ~ - Delete CSI 3 ~ CSI 3 ~ - Home CSI 1 ~ CSI 1 ~ - End CSI 4 ~ CSI 4 ~ - PageUp CSI 5 ~ CSI 5 ~ - PageDown CSI 6 ~ CSI 6 ~ - ---------------------------------- + Key Normal Application + ---------+----------+------------- + Insert | CSI 2 ~ | CSI 2 ~ + Delete | CSI 3 ~ | CSI 3 ~ + Home | CSI 1 ~ | CSI 1 ~ + End | CSI 4 ~ | CSI 4 ~ + PageUp | CSI 5 ~ | CSI 5 ~ + PageDown | CSI 6 ~ | CSI 6 ~ + ---------+----------+------------- The VT220 provides 8 additional function keys. With a Sun/PC keyboard, access these keys by Control/F1 for F13, etc. - Key Escape Sequence - --------------------------- - F13 CSI 2 5 ~ - F14 CSI 2 6 ~ - F15 CSI 2 8 ~ - F16 CSI 2 9 ~ - F17 CSI 3 1 ~ - F18 CSI 3 2 ~ - F19 CSI 3 3 ~ - F20 CSI 3 4 ~ - --------------------------- + Key Escape Sequence + ---------+----------------- + F13 | CSI 2 5 ~ + F14 | CSI 2 6 ~ + F15 | CSI 2 8 ~ + F16 | CSI 2 9 ~ + F17 | CSI 3 1 ~ + F18 | CSI 3 2 ~ + F19 | CSI 3 3 ~ + F20 | CSI 3 4 ~ + ---------+----------------- VT52-Style Function Keys @@ -1227,43 +1341,43 @@ and cursor keys. They differ from the other emulations by the prefix. Also, the cursor keys do not change: - Key Normal/Application - ---------------------------------- - Cursor Up ESC A - Cursor Down ESC B - Cursor Right ESC C - Cursor Left ESC D - ---------------------------------- + Key Normal/Application + -------------+-------------------- + Cursor Up | ESC A + Cursor Down | ESC B + Cursor Right | ESC C + Cursor Left | ESC D + -------------+-------------------- The keypad is similar: - Key Numeric Application - -------------------------------------- - Space SP ESC ? SP - Tab TAB ESC ? I - Enter CR ESC ? M - PF1 ESC P ESC P - PF2 ESC Q ESC Q - PF3 ESC R ESC R - PF4 ESC S ESC S - * (multiply) * ESC ? j - + (add) + ESC ? k - , (comma) , ESC ? l - - (minus) - ESC ? m - . (period) . ESC ? n - / (divide) / ESC ? o - 0 0 ESC ? p - 1 1 ESC ? q - 2 2 ESC ? r - 3 3 ESC ? s - 4 4 ESC ? t - 5 5 ESC ? u - 6 6 ESC ? v - 7 7 ESC ? w - 8 8 ESC ? x - 9 9 ESC ? y - = (equal) = ESC ? X - -------------------------------------- + Key Numeric Application + -------------+----------+------------- + Space | SP | ESC ? SP + Tab | TAB | ESC ? I + Enter | CR | ESC ? M + PF1 | ESC P | ESC P + PF2 | ESC Q | ESC Q + PF3 | ESC R | ESC R + PF4 | ESC S | ESC S + * (multiply) | * | ESC ? j + + (add) | + | ESC ? k + , (comma) | , | ESC ? l + - (minus) | - | ESC ? m + . (period) | . | ESC ? n + / (divide) | / | ESC ? o + 0 | 0 | ESC ? p + 1 | 1 | ESC ? q + 2 | 2 | ESC ? r + 3 | 3 | ESC ? s + 4 | 4 | ESC ? t + 5 | 5 | ESC ? u + 6 | 6 | ESC ? v + 7 | 7 | ESC ? w + 8 | 8 | ESC ? x + 9 | 9 | ESC ? y + = (equal) | = | ESC ? X + -------------+----------+------------- Sun-Style Function Keys @@ -1348,8 +1462,8 @@ other full-screen applications that want to make use of the mouse. There are two sets of mutually exclusive modes: -o mouse protocol -o protocol encoding +o mouse protocol +o protocol encoding The mouse protocols include DEC Locator mode, enabled by the DECELR CSI Ps ; Ps ' z control sequence, and is not described here (control @@ -1360,17 +1474,19 @@ Manifest constants for the parameter values are defined in xcharmouse.h as follows: - #define SET_X10_MOUSE 9 - #define SET_VT200_MOUSE 1000 - #define SET_VT200_HIGHLIGHT_MOUSE 1001 - #define SET_BTN_EVENT_MOUSE 1002 - #define SET_ANY_EVENT_MOUSE 1003 - - #define SET_FOCUS_EVENT_MOUSE 1004 - - #define SET_EXT_MODE_MOUSE 1005 - #define SET_SGR_EXT_MODE_MOUSE 1006 - #define SET_URXVT_EXT_MODE_MOUSE 1015 + #define SET_X10_MOUSE 9 + #define SET_VT200_MOUSE 1000 + #define SET_VT200_HIGHLIGHT_MOUSE 1001 + #define SET_BTN_EVENT_MOUSE 1002 + #define SET_ANY_EVENT_MOUSE 1003 + + #define SET_FOCUS_EVENT_MOUSE 1004 + + #define SET_EXT_MODE_MOUSE 1005 + #define SET_SGR_EXT_MODE_MOUSE 1006 + #define SET_URXVT_EXT_MODE_MOUSE 1015 + + #define SET_ALTERNATE_SCROLL 1007 The motion reporting modes are strictly xterm extensions, and are not part of any standard, though they are analogous to the DEC VT200 DECELR @@ -1382,35 +1498,44 @@ the value 1. The upper left character position on the terminal is denoted as 1,1. This scheme dates back to X10, though the normal mouse- tracking (from X11) is more elaborate. +X10 compatbility mode X10 compatibility mode sends an escape sequence only on button press, encoding the location and the mouse button pressed. It is enabled by specifying parameter 9 to DECSET. On button press, xterm sends CSI M CbCxCy (6 characters). -o Cb is button-1. -o Cx and Cy are the x and y coordinates of the mouse when the button - was pressed. +o Cb is button-1. +o Cx and Cy are the x and y coordinates of the mouse when the button was + pressed. +Normal tracking mode Normal tracking mode sends an escape sequence on both button press and release. Modifier key (shift, ctrl, meta) information is also sent. It is enabled by specifying parameter 1000 to DECSET. On button press or release, xterm sends CSI M CbCxCy. -o The low two bits of Cb encode button information: 0=MB1 pressed, - 1=MB2 pressed, 2=MB3 pressed, 3=release. -o The next three bits encode the modifiers which were down when the - button was pressed and are added together: 4=Shift, 8=Meta, 16=Con- - trol. Note however that the shift and control bits are normally - unavailable because xterm uses the control modifier with mouse for - popup menus, and the shift modifier is used in the default transla- - tions for button events. The Meta modifier recognized by xterm is - the mod1 mask, and is not necessarily the "Meta" key (see xmodmap). -o Cx and Cy are the x and y coordinates of the mouse event, encoded as - in X10 mode. +o The low two bits of Cb encode button information: 0=MB1 pressed, 1=MB2 + pressed, 2=MB3 pressed, 3=release. +o The next three bits encode the modifiers which were down when the but- + ton was pressed and are added together: 4=Shift, 8=Meta, 16=Control. + Note however that the shift and control bits are normally unavailable + because xterm uses the control modifier with mouse for popup menus, + and the shift modifier is used in the default translations for button + events. The Meta modifier recognized by xterm is the mod1 mask, and + is not necessarily the "Meta" key (see xmodmap). +o Cx and Cy are the x and y coordinates of the mouse event, encoded as + in X10 mode. +Wheel mice Wheel mice may return buttons 4 and 5. Those buttons are represented by the same event codes as buttons 1 and 2 respectively, except that 64 is added to the event code. Release events for the wheel buttons are not -reported. +reported. By default, the wheel mouse events are translated to scroll- +back and scroll-forw actions. Those actions normally scroll the whole +window, as if the scrollbar was used. However if Alternate Scroll mode +is set, then cursor up/down controls are sent when the terminal is dis- +playing the alternate screen. The initial state of Alternate Scroll +mode is set using the alternateScroll resource. +Highlight tracking Mouse highlight tracking notifies a program of a button press, receives a range of lines from the program, highlights the region covered by the @@ -1433,37 +1558,40 @@ always be above row lastrow. (The top of the screen is row 1.) When the button is released, xterm reports the ending position one of two ways: -o if the start and end coordinates are the same locations: - CSI t CxCy. -o otherwise: - CSI T CxCyCxCyCxCy. - The parameters are startx, starty, endx, endy, mousex, and mousey. - - startx, starty, endx, and endy give the starting and ending - character positions of the region. - - mousex and mousey give the location of the mouse at button up, - which may not be over a character. +o if the start and end coordinates are the same locations: + CSI t CxCy. +o otherwise: + CSI T CxCyCxCyCxCy. + The parameters are startx, starty, endx, endy, mousex, and mousey. + - startx, starty, endx, and endy give the starting and ending charac- + ter positions of the region. + - mousex and mousey give the location of the mouse at button up, which + may not be over a character. +Button-event tracking Button-event tracking is essentially the same as normal tracking, but xterm also reports button-motion events. Motion events are reported only if the mouse pointer has moved to a different character cell. It is enabled by specifying parameter 1002 to DECSET. On button press or release, xterm sends the same codes used by normal tracking mode. -o On button-motion events, xterm adds 32 to the event code (the third - character, Cb). -o The other bits of the event code specify button and modifier keys as - in normal mode. For example, motion into cell x,y with button 1 - down is reported as CSI M @ CxCy. ( @ = 32 + 0 (button 1) + 32 - (motion indicator) ). Similarly, motion with button 3 down is - reported as CSI M B CxCy. ( B = 32 + 2 (button 3) + 32 (motion - indicator) ). +o On button-motion events, xterm adds 32 to the event code (the third + character, Cb). +o The other bits of the event code specify button and modifier keys as + in normal mode. For example, motion into cell x,y with button 1 down + is reported as CSI M @ CxCy. ( @ = 32 + 0 (button 1) + 32 (motion + indicator) ). Similarly, motion with button 3 down is reported as CSI + M B CxCy. ( B = 32 + 2 (button 3) + 32 (motion indicator) ). +Any-event tracking Any-event mode is the same as button-event mode, except that all motion events are reported, even if no mouse button is down. It is enabled by specifying 1003 to DECSET. +FocusIn/FocusOut FocusIn/FocusOut can be combined with any of the mouse events since it uses a different protocol. When set, it causes xterm to send CSI I when the terminal gains focus, and CSI O when it loses focus. +Extended coordinates The original X10 mouse protocol limits the Cx and Cy ordinates to 223 (=255 - 32). Xterm supports more than one scheme for extending this @@ -1490,12 +1618,13 @@ semicolon-separated encoded button value, the Cx and Cy ordi- nates and a final character which is M for button press and m for button release. - The encoded button value in this case does not add 32 since - that was useful only in the X10 scheme for ensuring that the - byte containing the button value is a printable code. The - modifiers are encoded in the same way. A different final - character is used for button release to resolve the X10 ambi- - guity regarding which button was released. + o The encoded button value in this case does not add 32 since + that was useful only in the X10 scheme for ensuring that the + byte containing the button value is a printable code. + o The modifiers are encoded in the same way. + o A different final character is used for button release to + resolve the X10 ambiguity regarding which button was + released. The highlight tracking responses are also modified to an SGR- like format, using the same SGR-style scheme and button-encod- ings. @@ -1511,6 +1640,32 @@ sons, the 1015 control is not recommended; it is not an improvement over 1005. +Sixel Graphics +If xterm is configured as VT240, VT241, VT330 or VT340 using the decTer- +minalID resource, it supports Sixel Graphics controls, a subset of ReGIS +graphics. + +CSI Ps c xterm responds to Send Device Attributes (Primary DA) with + these additional codes: + Ps = 3 -> ReGIS graphics. + Ps = 4 -> SIXEL graphics. +CSI ? Pm h + xterm has these additional private Set Mode values: + Ps = 8 0 -> SIXEL scrolling. + Ps = 1 0 7 0 -> use private color registers for each + graphic. +DCS Pa; Pb; Ph q Ps..PsST + See + + http://vt100.net/docs/vt3xx-gp/chapter14.html + + The sixel data device control string has three positional + parameters, following the q with sixel data. + Pa -> pixel aspect ratio + Pb -> background color option + Ph -> horizontal grid size (ignored). + Ps -> sixel data + Tektronix 4014 Mode Most of these sequences are standard Tektronix 4014 control sequences. Graph mode supports the 12-bit addressing of the Tektronix 4014. The diff -Nru xterm-278/cursor.c xterm-297/cursor.c --- xterm-278/cursor.c 2010-04-17 17:12:01.000000000 +0000 +++ xterm-297/cursor.c 2013-08-08 08:16:40.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: cursor.c,v 1.55 2010/04/17 17:12:01 tom Exp $ */ +/* $XTermId: cursor.c,v 1.68 2013/08/08 08:16:40 Iwamoto.Kouichi Exp $ */ /* - * Copyright 2002-2009,2010 by Thomas E. Dickey + * Copyright 2002-2010,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -68,23 +68,32 @@ CursorSet(TScreen * screen, int row, int col, unsigned flags) { int use_row = row; - int max_row; + int use_col = col; + int max_col = screen->max_col; + int max_row = screen->max_row; + + if (flags & ORIGIN) { + use_col += screen->lft_marg; + max_col = screen->rgt_marg; + } + use_col = (use_col < 0 ? 0 : use_col); + set_cur_col(screen, (use_col <= max_col ? use_col : max_col)); - col = (col < 0 ? 0 : col); - set_cur_col(screen, (col <= screen->max_col ? col : screen->max_col)); - max_row = screen->max_row; if (flags & ORIGIN) { use_row += screen->top_marg; max_row = screen->bot_marg; } use_row = (use_row < 0 ? 0 : use_row); set_cur_row(screen, (use_row <= max_row ? use_row : max_row)); - screen->do_wrap = False; - TRACE(("CursorSet(%d,%d) margins [%d..%d] -> %d,%d %s\n", + ResetWrap(screen); + + TRACE(("CursorSet(%d,%d) margins V[%d..%d] H[%d..%d] -> %d,%d %s\n", row, col, screen->top_marg, screen->bot_marg, + screen->lft_marg, + screen->rgt_marg, screen->cur_row, screen->cur_col, (flags & ORIGIN ? "origin" : "normal"))); @@ -96,47 +105,65 @@ void CursorBack(XtermWidget xw, int n) { +#define WRAP_MASK (REVERSEWRAP | WRAPAROUND) TScreen *screen = TScreenOf(xw); - int i, j, k, rev; + int offset, in_row, length, rev; + int left = ScrnLeftMargin(xw); + int before = screen->cur_col; - if ((rev = (xw->flags & (REVERSEWRAP | WRAPAROUND)) == - (REVERSEWRAP | WRAPAROUND)) != 0 - && screen->do_wrap) + if ((rev = (xw->flags & WRAP_MASK) == WRAP_MASK) != 0 + && screen->do_wrap) { n--; - if ((screen->cur_col -= n) < 0) { + } + + /* if the cursor is already before the left-margin, we have to let it go */ + if (before < left) + left = 0; + + if ((screen->cur_col -= n) < left) { if (rev) { - if ((i = ((j = MaxCols(screen)) - * screen->cur_row) + screen->cur_col) < 0) { - k = j * MaxRows(screen); - i += ((-i) / k + 1) * k; + in_row = ScrnRightMargin(xw) - left + 1; + offset = (in_row * screen->cur_row) + screen->cur_col - left; + if (offset < 0) { + length = in_row * MaxRows(screen); + offset += ((-offset) / length + 1) * length; } - set_cur_row(screen, i / j); - set_cur_col(screen, i % j); + set_cur_row(screen, (offset / in_row)); + set_cur_col(screen, (offset % in_row) + left); do_xevents(); } else { - set_cur_col(screen, 0); + set_cur_col(screen, left); } } - screen->do_wrap = False; + ResetWrap(screen); } /* * moves the cursor forward n, no wraparound */ void -CursorForward(TScreen * screen, int n) +CursorForward(XtermWidget xw, int n) { + TScreen *screen = TScreenOf(xw); #if OPT_DEC_CHRSET LineData *ld = getLineData(screen, screen->cur_row); #endif int next = screen->cur_col + n; - int max = LineMaxCol(screen, ld); + int max; + + if (IsLeftRightMode(xw)) { + max = screen->rgt_marg; + if (screen->cur_col > max) + max = screen->max_col; + } else { + max = LineMaxCol(screen, ld); + } if (next > max) next = max; set_cur_col(screen, next); - screen->do_wrap = False; + ResetWrap(screen); } /* @@ -157,7 +184,7 @@ next = screen->max_row; set_cur_row(screen, next); - screen->do_wrap = False; + ResetWrap(screen); } /* @@ -179,7 +206,7 @@ next = 0; set_cur_row(screen, next); - screen->do_wrap = False; + ResetWrap(screen); } /* @@ -197,13 +224,14 @@ * if cursor high enough, no scrolling necessary. */ if (screen->cur_row > screen->bot_marg - || screen->cur_row + amount <= screen->bot_marg) { + || screen->cur_row + amount <= screen->bot_marg + || (IsLeftRightMode(xw) + && !ScrnIsColInMargins(screen, screen->cur_col))) { CursorDown(screen, amount); - return; + } else { + CursorDown(screen, j = screen->bot_marg - screen->cur_row); + xtermScroll(xw, amount - j); } - - CursorDown(screen, j = screen->bot_marg - screen->cur_row); - xtermScroll(xw, amount - j); } /* @@ -220,13 +248,14 @@ * if cursor low enough, no reverse indexing needed */ if (screen->cur_row < screen->top_marg - || screen->cur_row - amount >= screen->top_marg) { + || screen->cur_row - amount >= screen->top_marg + || (IsLeftRightMode(xw) + && !ScrnIsColInMargins(screen, screen->cur_col))) { CursorUp(screen, amount); - return; + } else { + RevScroll(xw, amount - (screen->cur_row - screen->top_marg)); + CursorUp(screen, screen->cur_row - screen->top_marg); } - - RevScroll(xw, amount - (screen->cur_row - screen->top_marg)); - CursorUp(screen, screen->cur_row - screen->top_marg); } /* @@ -234,10 +263,27 @@ * (Note: xterm doesn't implement SLH, SLL which would affect use of this) */ void -CarriageReturn(TScreen * screen) +CarriageReturn(XtermWidget xw) { - set_cur_col(screen, 0); - screen->do_wrap = False; + TScreen *screen = TScreenOf(xw); + int left = ScrnLeftMargin(xw); + int col; + + if (xw->flags & ORIGIN) { + col = left; + } else if (screen->cur_col >= left) { + col = left; + } else { + /* + * If origin-mode is not active, it is possible to use cursor + * addressing outside the margins. In that case we will go to the + * first column rather than following the margin. + */ + col = 0; + } + + set_cur_col(screen, col); + ResetWrap(screen); do_xevents(); } @@ -330,10 +376,12 @@ * Move the cursor to the first column of the n-th next line. */ void -CursorNextLine(TScreen * screen, int count) +CursorNextLine(XtermWidget xw, int count) { + TScreen *screen = TScreenOf(xw); + CursorDown(screen, count < 1 ? 1 : count); - CarriageReturn(screen); + CarriageReturn(xw); do_xevents(); } @@ -341,13 +389,45 @@ * Move the cursor to the first column of the n-th previous line. */ void -CursorPrevLine(TScreen * screen, int count) +CursorPrevLine(XtermWidget xw, int count) { + TScreen *screen = TScreenOf(xw); + CursorUp(screen, count < 1 ? 1 : count); - CarriageReturn(screen); + CarriageReturn(xw); do_xevents(); } +/* + * Return col/row values which can be passed to CursorSet() preserving the + * current col/row, e.g., accounting for DECOM. + */ +int +CursorCol(XtermWidget xw) +{ + TScreen *screen = TScreenOf(xw); + int result = screen->cur_col; + if (xw->flags & ORIGIN) { + result -= ScrnLeftMargin(xw); + if (result < 0) + result = 0; + } + return result; +} + +int +CursorRow(XtermWidget xw) +{ + TScreen *screen = TScreenOf(xw); + int result = screen->cur_row; + if (xw->flags & ORIGIN) { + result -= screen->top_marg; + if (result < 0) + result = 0; + } + return result; +} + #if OPT_TRACE int set_cur_row(TScreen * screen, int value) diff -Nru xterm-278/data.h xterm-297/data.h --- xterm-278/data.h 2011-07-12 08:37:24.000000000 +0000 +++ xterm-297/data.h 2012-10-14 18:51:30.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: data.h,v 1.119 2011/07/12 08:37:24 tom Exp $ */ +/* $XTermId: data.h,v 1.121 2012/10/14 18:51:30 tom Exp $ */ /* - * Copyright 2002-2009,2011 by Thomas E. Dickey + * Copyright 2002-2011,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -144,6 +144,7 @@ typedef struct XTERM_RESOURCE { char *icon_geometry; char *title; + char *icon_hint; char *icon_name; char *term_name; char *tty_modes; @@ -192,6 +193,7 @@ Boolean useInsertMode; #if OPT_ZICONBEEP int zIconBeep; /* beep level when output while iconified */ + char *zIconFormat; /* format for icon name */ #endif #if OPT_PTY_HANDSHAKE Boolean wait_for_map; diff -Nru xterm-278/debian/README.source xterm-297/debian/README.source --- xterm-278/debian/README.source 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/README.source 2013-10-29 05:19:15.000000000 +0000 @@ -47,27 +47,3 @@ case, it appears directly in the .diff.gz. * Otherwise, the patch is added to debian/patches/ which is managed with quilt as documented in /usr/share/doc/quilt/README.source. - -quilt is actually invoked by the Debian X packaging through a larger -set of scripts called XSFBS. XSFBS brings some other X specific -features such as managing dependencies and conflicts due to the video -and input driver ABIs. -XSFBS itself is maintained in a separate repository at - git://git.debian.org/pkg-xorg/xsfbs.git -and it is pulled inside the other Debian X repositories when needed. - -The XSFBS patching system requires a build dependency on quilt. Also -a dependency on $(STAMP_DIR)/patch has to be added to debian/rules -so that the XSFBS patching occurs before the actual build. So the -very first target of the build (likely the one running autoreconf) -should depend on $(STAMP_DIR)/patch. It should also not depend on -anything so that parallel builds are correctly supported (nothing -should probably run while patching is being done). And finally, the -clean target should depend on the xsfclean target so that patches -are unapplied on clean. - -When the upstream sources contain some DFSG-nonfree files, they are -listed in text files in debian/prune/ in the "debian-*" branch of -the Debian repository. XSFBS' scripts then take care of removing -these listed files during the build so as to generate a modified -DFSG-free .orig.tar.gz tarball. diff -Nru xterm-278/debian/changelog xterm-297/debian/changelog --- xterm-278/debian/changelog 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/changelog 2013-10-29 05:19:15.000000000 +0000 @@ -1,3 +1,120 @@ +xterm (297-1ubuntu1) trusty; urgency=low + + * Resynchronise with Debian. Remaining changes: + - debian/patches/950_ubuntu_charclass_highlight.diff: Enable URL + highlighting. + - debian/patches/Add 951_uxterm_utf8_title.diff: Set utf8Titles to true + by default when using uxterm, so that it displays utf8 directories in + titles properly. May cause issues with apps that use control + sequences for updating the xterm titlebar - users should use xterm or + set utf8Title to false in this case. + - debian/gbp.conf: Use "Ubuntu" in "debian-branch" directly. + - Use autotools-dev's debhelper integration to update + config.guess/config.sub for each build. + + -- Colin Watson Mon, 28 Oct 2013 22:15:39 -0700 + +xterm (297-1) unstable; urgency=low + + * New upstream release. + * Enable sixel graphics (Closes: #716660). + + -- Sven Joachim Sun, 15 Sep 2013 15:52:21 +0200 + +xterm (295-1) unstable; urgency=low + + * New upstream release. + - Amend fix from xterm 292 by removing now-unneeded chunk which + introduced problem in selection (Closes: #714527). + * Update debian/copyright. + * Switch Vcs-* fields to anonscm.debian.org. + * Update copy of XTerm FAQ to revision 1.243 (dated 2013/07/05). + + -- Sven Joachim Sun, 07 Jul 2013 17:30:07 +0200 + +xterm (293-1) unstable; urgency=low + + * New upstream release. + - Improve description of initialFont, set-vt-font and set-tex-text + in manpage (Closes: #707899). + * Update copyright year in debian/copyright. + + -- Sven Joachim Wed, 29 May 2013 17:19:26 +0200 + +xterm (292-1) unstable; urgency=low + + * New upstream release. + * Refresh 904_fontops.diff. + * Update copy of XTerm FAQ to revision 1.229 (dated 2013/05/18). + * Bump debhelper compatibility level to 9. + * Use dh_install's --fail-missing option. + * Convert debian/rules to dh and drop xsfbs. + * Bump Standards-Version to 3.9.4, no changes needed. + * Add myself to Uploaders. + + -- Sven Joachim Sun, 26 May 2013 11:22:26 +0200 + +xterm (290-1) experimental; urgency=low + + * New upstream release + * Drop 100_manpage_whatis.diff, no longer necessary. + * Drop explicit --with-desktop-category, no longer necessary. + * Update copy of XTerm FAQ to revision 1.221 (dated 2013/01/26). + + -- Julien Cristau Sat, 23 Feb 2013 16:09:09 +0100 + +xterm (287-1) experimental; urgency=low + + * New upstream release (closes: #694375) + - add alternateScroll resource and corresponding control sequences which + modify the scroll-forw and scroll-back actions: when the alternate + screen is displayed, wheel mouse up/down will send cursor keys (closes: + #683942) + - improve rendering for the case when a Unicode character is absent in the + bold font but present in the normal font by temporarily falling back to + the normal font (closes: #359006, #408666) + - check for misconfigured printerCommand resource on the first use, warn + and disable it if it does not specify an executable command (closes: + #691642) + * Drop upstream patches. + * Refresh remaining patches. + * Explicitly set --with-desktop-category to avoid desktop-file-install + failure. + * Enable backarrowKeyIsErase in configure instead of 900_debian_xterm.diff. + * Install png/svg icons. + * Change xterm.man's NAME section to keep whatis(1) happy. + + -- Julien Cristau Tue, 27 Nov 2012 22:27:28 +0100 + +xterm (278-4) unstable; urgency=low + + * Update copy of XTerm FAQ to revision 1.199 (dated 2012/11/11). + + -- Julien Cristau Tue, 27 Nov 2012 20:17:49 +0100 + +xterm (278-3) unstable; urgency=low + + [ Timo Aaltonen ] + * control: Mark the package as Multi-Arch: foreign. + + [ Julien Cristau ] + * Apply a few patches recommended by upstream in #694375 (thanks!) + - amend patch from 278-2 to catch more cases + - amend fix for Debian #650291 in patch #277 changes to account for + different data returned by vnc4server (closes: #670638) + - correct macro definition used for testing modes used in ANSI/DEC + request-mode controls introduced in patch #262 + - add a null-pointer check in OkPasswd macro to fix a problem in resize + with Fedora 17 and a serial console (report/patch by Daniel Drake). + + -- Julien Cristau Tue, 27 Nov 2012 19:57:47 +0100 + +xterm (278-2) unstable; urgency=low + + * Fix crash in Tektronix mode (Closes: #685458). + + -- Cyril Brulebois Mon, 27 Aug 2012 02:14:38 +0200 + xterm (278-1ubuntu3) saucy; urgency=low * Use autotools-dev's debhelper integration to update @@ -958,7 +1075,7 @@ * 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/ diff -Nru xterm-278/debian/clean xterm-297/debian/clean --- xterm-278/debian/clean 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/debian/clean 2013-10-29 05:19:15.000000000 +0000 @@ -0,0 +1 @@ +debian/local/xterm.faq diff -Nru xterm-278/debian/compat xterm-297/debian/compat --- xterm-278/debian/compat 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/compat 2013-10-29 05:19:15.000000000 +0000 @@ -1 +1 @@ -5 +9 diff -Nru xterm-278/debian/control xterm-297/debian/control --- xterm-278/debian/control 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/control 2013-10-29 05:19:15.000000000 +0000 @@ -3,10 +3,10 @@ Priority: optional Maintainer: Ubuntu X-SWAT XSBC-Original-Maintainer: Debian X Strike Force -Uploaders: Cyril Brulebois -Standards-Version: 3.9.2 -Vcs-Browser: http://git.debian.org/?p=pkg-xorg/app/xterm.git -Vcs-Git: git://git.debian.org/git/pkg-xorg/app/xterm +Uploaders: Cyril Brulebois , Sven Joachim +Standards-Version: 3.9.4 +Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-xorg/app/xterm.git +Vcs-Git: git://anonscm.debian.org/pkg-xorg/app/xterm Homepage: http://invisible-island.net/xterm/xterm.html Build-Depends: libncurses5-dev | libncurses-dev, @@ -14,7 +14,7 @@ libxaw7-dev, libxkbfile-dev, libutempter-dev, - debhelper (>= 5), + debhelper (>= 9), quilt, lynx-cur | lynx, xorg-docs-core, @@ -100,7 +100,7 @@ # main.c:#include # xorg-docs-core provides X(7) which minstall.sh tries to # detect -# debhelper (>= 5) debian/compat = 5 +# debhelper (>= 9) debian/compat = 9 # quilt patch management system # lynx-cur | lynx generates plain-text version of xterm faq # desktop-file-utils for installing xterm.desktop diff -Nru xterm-278/debian/copyright xterm-297/debian/copyright --- xterm-278/debian/copyright 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/copyright 2013-10-29 05:19:15.000000000 +0000 @@ -4,8 +4,9 @@ Upstream sources: http://invisible-island.net/xterm/xterm.html -Copyright 1997-2011 by Thomas E. Dickey +Copyright 1997-2013 by Thomas E. Dickey Copyright 1999-2000 by Steve Wall +Copyright 2013 by Ross Combs All Rights Reserved diff -Nru xterm-278/debian/local/xterm.faq.html xterm-297/debian/local/xterm.faq.html --- xterm-278/debian/local/xterm.faq.html 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/local/xterm.faq.html 2013-10-29 05:19:15.000000000 +0000 @@ -1,7 +1,6 @@ - + + + "HTML Tidy for Linux (vers 25 March 2009), see www.w3.org"> - XTerm - Frequently Asked Questions (FAQ) + XTerm – Frequently Asked Questions (FAQ) + + + + +
- http://invisible-island.net/xterm/
- Copyright © 1997-2011,2012 by Thomas E. Dickey +

http://invisible-island.net/xterm/
+ Copyright © 1997-2012,2013 by Thomas E. Dickey


- Here is - the latest version of this file. -

Contents

+

Here is the latest version of + this file.

- +

What is XTerm?

@@ -93,13 +110,15 @@

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. +

The xterm program is a terminal emulator for the X Window + System. It provides DEC VT102/VT220 and selected features from + higher-level terminals such as VT320/VT420/VT520 (VTxxx). It + also provides Tektronix 4014 emulation for programs that cannot + 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.

That is, xterm (pronounced "eks-xterm") is a @@ -110,6 +129,10 @@ the specific program as well as other programs that imitate it.

+

As a stylistic convention, the capitalized form is + "XTerm", which corresponds to the X resource class name. + Similarly, uxterm becomes "UXTerm".

+

Who wrote XTerm?

@@ -118,6 +141,9 @@

But the program is much older than that.

+

A + Prehistory Perspective

+

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, @@ -126,7 +152,7 @@ Email from Jim Gettys provides some background:

- Cast of thousands... +

Cast of thousands...

To give a bit of history, xterm predates X!

@@ -159,9 +185,9 @@

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 +

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 @@ -196,13 +222,94 @@ 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. + 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.

+

My + Involvement

+ +

My involvement with xterm through XFree86 + began at the end of 1995. This + website has been "here" since 2001/6/5, replacing my ClarkNet + page. I started the ClarkNet page 1996/12/31, as a followup to + the + release of ncurses 4.0) which featured xterm as one of the 16 + programs I was involved with. From the outset, the page provided + a link to a snapshot of the current source. Copies of patches + which I sent to XFree86 were available on the ftp area.

+ +

XFree86 had its sources in CVS, but (like others in that era), + were not directly visible to random developers. That came later. + I started by downloading the sources (30Mb of compressed + tar-files on a 56Kb phone connection took about 6 hours) and + updating them with patches from the XFree86 mailing list.

+ +

Like the other programs that I worked on with others (vile, tin, lynx), I set up + an RCS archive to track my changes locally before sending patches + to the development list. As the XFree86 developers issued new + patches, I would re-synchronize my archive. Later, XFree86 + provided CVS (initially readonly). I was granted commit + privileges on this + in November 2000.

+ +

Throughout this period, my work on xterm was + released as part of XFree86. It was rare for a separate package + to be provided. That was due to the potential conflict between + the install procedures. Users of the downloads from my web/ftp + site were predominantly individual developers.

+ +

There were exceptions. Christian Weisgerber proposed a package + for FreeBSD ports later in 1999 (ports/15545: + new port: x11/xterm, followup in March + 2000). However, that was an exception. None of the Linux + distributions provided a separate package before 2003 (when Mike + Harris created a package of patch #177 for Red Hat). Again + that is more of an exception than a rule:

+ +
    +
  • SuSE's package began October 23, 2004 with patch #196.
  • + +
  • Mandriva's package began October 22, 2005 with patch #205.
  • + +
  • The Debian package for xterm began in January 6, 2006 with + patch #204.
  • +
+ +

Given that context (sources distributed via XFree86 CVS, + releases via XFree86), the statement made by an Xorg hacker + + early in 2005 asserting that "It has not been maintained by + anyone within the XFree86 or X.org trees for many years" was at + best misleading.

+ +

After the "fork" (sic) of Xorg in 2004, + I continued to commit changes for xterm in XFree86 + CVS until patch #216 + in mid-2006. I stopped at that point because it was not possible + to incorporate changes into xterm which were not sent to me + first. I still send patch announcements to both the XFree86 and + Xorg mailing lists, of course.

+ +

Focus of this FAQ

+

This FAQ is oriented toward the version of xterm originally distributed with XFree86 (more commonly known as modern, or "new xterm", with a corresponding terminal description "xterm-new"), @@ -340,67 +447,112 @@ source. These include

There are similar programs not based on xterm's source, which are compatible to different degrees. These include

-

Some of these use the VTE widget. - Since that supplies most of the terminal emulation, the remaining - differences between programs using VTE tend to be at the level of - the window manager (menus, borders, etc.). Other (older) programs - which are based on reusable widgets include dtterm and emu.

+

Some of these use the VTE + widget. Since that supplies most of the terminal emulation, + the remaining differences between programs using VTE tend to be + at the level of the window manager (menus, borders, etc.). Other + (older) programs which are based on reusable widgets include + dtterm and emu.

(I am aware of a few others, such as xcterm, but have not seen a working version of these).

+

Finally of course, there are a multitude of programs which set + TERM to "xterm", in the hope that applications will treat them + the same as xterm. For example, PuTTY does this. But its wrapping + behavior is incompatible with xterm (and any vt100 emulator). You + can see this in the first menu entry for vttest.

+ +

Each of the programs noted here which are well-established and + which are known to differ markedly from xterm have their own + terminal descriptions in ncurses, to which TERM should be set. + Otherwise, bug-reports are misdirected to ncurses which should + have been addressed by the respective developers of these + programs. ncurses. These + include

+ +
    +
  • Eterm
  • + +
  • gnome (obsolete)
  • + +
  • konsole
  • + +
  • mlterm
  • + +
  • mrxvt
  • + +
  • putty
  • + +
  • rxvt
  • + +
  • vte (preferred)
  • +
+

Comparing versions, by counting controls

@@ -409,10 +561,11 @@ developers, or their users) to emulate "most" of xterm. To me, "most" would be something quantifiable, e.g., 80 percent. To satisfy my curiousity, I wrote a script to extract the control - sequence information from ctlseqs.txt. - This counts each control sequence, as well as the variations such - as setting bold, color, inverse video. Then I (laboriously) - inspected these terminal implementations:

+ sequence information from ctlseqs.txt. This counts each + control sequence, as well as the variations such as setting bold, + color, inverse video. Then I (laboriously) inspected these + terminal implementations:

Here's another source of information: - Xterm-Title HowTo

+ "http://tldp.org/HOWTO/Xterm-Title.html">Xterm-Title + HowTo

@@ -2073,136 +2431,156 @@ @@ -2232,8 +2610,8 @@
-        # ls -l /dev/ptmx
-        crw-rw----    1 root     tty        5,   2 Aug 21 20:19 /dev/ptmx
+# ls -l /dev/ptmx
+crw-rw----    1 root     tty        5,   2 Aug 21 20:19 /dev/ptmx
 
@@ -2277,7 +2655,7 @@
-        xterm -e foo
+xterm -e foo
 
@@ -2307,11 +2685,13 @@
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 + + +

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). + others do not (e.g., tcsh).

Why is my screen size not set?

@@ -2327,7 +2707,7 @@
-        stty -a
+stty -a
 
@@ -2367,19 +2747,24 @@ 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
+
+  
+
+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
-
+
+  
+
+setenv LINES 24
+setenv COLUMNS 80
 
+

Why 65 lines? The standard xterm terminfo description specifies 65 lines, perhaps because someone liked it that way. @@ -2399,28 +2784,45 @@ 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:

+ widget:

-

-         XTerm*geometry: 80x24
+

+ -

+

+ XTerm*geometry: 80x24
+

+

while this applies only to the VT100 widget (which is probably - what you intended):

+ what you intended):

-

-         XTerm.VT100.geometry: 80x24
+

+ -

+

+ XTerm.VT100.geometry: 80x24
+

+

or better yet (to allow for the toolbar option, which uses a - level of widget hierarchy):

+ level of widget hierarchy):

-

-         XTerm*VT100.geometry: 80x24
+

+ -

+

+ XTerm*VT100.geometry: 80x24
+

+

Font problems

@@ -2468,16 +2870,20 @@ 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:

+ the path:

-

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

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

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

+ FontPath        "/usr/lib/X11/fonts/misc/:unscaled"
+ +

+

You can suppress xterm's overstriking for bold fonts using the alwaysBoldMode and related resources. However, @@ -2540,39 +2946,50 @@ latter is where an overbroad pattern can cause xterm to use a different font than you expect.

-

Suppose your resource setting includes this pattern -

+

Suppose your resource setting includes this pattern

+ +
+ + +

+ *VT100*font: fixed
+

+
+ +

It could be interpreted as this:

+ +
+ -

- *VT100*font: fixed
-

- -

It could be interpreted as this:

- -

- *VT100.font: fixed
- *VT100.utf8Fonts.font: fixed
-

+

+ *VT100.font: fixed
+ *VT100.utf8Fonts.font: fixed
+

+

XTerm uses the utf8Fonts subresources to provide runtime-switchable fonts between IS0-8859-1 (Latin-1) and ISO-10646 (Unicode). Modifying the Unicode font to "fixed" will make most of the characters unavailable (i.e., shown as boxes). If instead your resource - looks like

+ looks like

-

- *VT100.font: fixed
-

+
+ + +

+ *VT100.font: fixed
+

+

it would be unambiguous, and not modify the utf8Fonts value.

@@ -2609,7 +3026,7 @@ around 2000 is the core of the problem:

- ISO10646-1, ISO8859-1, ISO8859-2, ISO8859-3, ISO8859-4, +

ISO10646-1, ISO8859-1, ISO8859-2, ISO8859-3, ISO8859-4, ISO8859-5, ISO8859-6, ISO8859-7, ISO8859-8, ISO8859-9, ISO8859-10, ISO8859-11, ISO8859-13, ISO8859-14, ISO8859-15, ISO8859-16, JISX0201.1976-0, TIS620-0, GB2312.1980-0, @@ -2618,7 +3035,7 @@ IBM-CP1133, MULELAO-1, VISCII1.1-1, TCVN-5712, GEORGIAN-ACADEMY, GEORGIAN-PS, ISO8859-9E, MICROSOFT-CP1251, MICROSOFT-CP1255, MICROSOFT-CP1256, BIG5-0, BIG5-E0, BIG5-E1, - ISO10646-1, ISO10646-1 + ISO10646-1, ISO10646-1

However, xterm is going to use only the characters shown in @@ -2654,11 +3071,14 @@

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 ~)
+
+  
+
+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 @@ -2699,7 +3119,7 @@

-        appres XTerm
+appres XTerm
 
@@ -2748,7 +3168,7 @@
-        keysym BackSpace = Delete
+keysym BackSpace = Delete
 
@@ -2756,7 +3176,7 @@
-        keycode 22 = 0xff08
+keycode 22 = 0xff08
 
@@ -2766,14 +3186,20 @@

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

+ e.g.,

-

-         XTerm*VT100.translations: #override \n\
+

+ -                 <Key>Delete: string(0x7f)
+

+ 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 @@ -2797,34 +3223,40 @@ 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     |  .  |     |
-        +-----+-----+-----+-----+
+
+  
+
++-----+-----+-----+-----+
+| 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     |  .  |     |
-        +-----+-----+-----+-----+
+
+  
+
++-----+-----+-----+-----+
+| 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 @@ -2832,35 +3264,44 @@ "+" 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 + 6-key editing keypad. Here's a picture of the VT220 editing keypad:

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

and the similar Sun and PC keypads:

-
-        +--------+--------+--------+
-        | Insert | Home   | PageUp |
-        +--------+--------+--------+
-        | Delete | End    | PageDn |
-        +--------+--------+--------+
+
+  
+
++--------+--------+--------+
+| 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   |
-        +--------+--------+--------+
+
+  
+
++--------+--------+--------+
+| Insert | Find   | Prev   |
++--------+--------+--------+
+| Remove | Select | Next   |
++--------+--------+--------+
 
+

I test the keyboard (for VT52/VT100/VT220) using vttest. If you find (or think that @@ -2878,103 +3319,110 @@ 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.

+ "xterm.faq.html#bug_xterm_r6">xterm.

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

-        /usr/lib/X11/app-defaults/XTerm
+/usr/lib/X11/app-defaults/XTerm
 

as a guide. The relevant section of the app-default file looks - like

+ like

-

- *VT100.translations:    #override \
-         @Num_Lock
<Key>KP_0: string(0)\n\
+

+ -         @Num_Lock<Key>KP_1: string(1)\n\
+

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

+ lets you override:

-

- XTerm*VT100.translations:       #override \n\
+

+ -         ~Shift<Key>Home:  string(\033[1~)\n\
+

+ XTerm*VT100.translations:       #override \n\
-         ~Shift
<Key>End:   string(\033[4~)\n\
+         ~Shift<Key>Home:  string(\033[1~)\n\
-         ~Shift
<Key>Prior: string(\033[5~)\n\
+         ~Shift<Key>End:   string(\033[4~)\n\
-         ~Shift
<Key>Next:  string(\033[6~)\n\
+         ~Shift<Key>Prior: string(\033[5~)\n\
-         Shift
<Key>Prior:  scroll-back(1,page) \n\
+         ~Shift<Key>Next:  string(\033[6~)\n\
-         Shift
<Key>Next:   scroll-forw(1,page) \n\
+         Shift<Key>Prior:  scroll-back(1,page) \n\
-         Shift
<Key>Home:   scroll-back(100,page) \n\
+         Shift<Key>Next:   scroll-forw(1,page) \n\
-         Shift
<Key>End:    scroll-forw(100,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 @@ -2984,24 +3432,30 @@ "xterm_pc_style">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.

+ xterm. That program is + simply broken in this respect.

At the beginning, when the home/end keys were fixed for modern 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
+
+  
+
+ESC [ H
+ESC [ F
 
+

for normal mode, and

-
-        ESC O H
-        ESC O F
+
+  
+
+ESC O H
+ESC O F
 
+

for cursor application mode.

@@ -3011,8 +3465,8 @@ 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.

+ "xterm.faq.html#xterm_keypad">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) @@ -3038,23 +3492,29 @@ 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: + .Xdefaults file: -

-         *sunKeyboard: true
-

+
+ + +

+ *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.

+ "xterm.faq.html#xterm_xmodmap">this for more + discussion.

- But xterm continues to evolve past the stable patch #88. The - keyboard support was still unsatisfactory for two reasons: + + +

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 @@ -3074,12 +3534,13 @@ 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.

    + "xterm.faq.html#xterm_erased">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):

    @@ -3090,108 +3551,116 @@ 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 + 3.3.x has an error. Setting -

    -         *sunKeyboard: true
    -

    +
    + + +

    + *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 -

    + with that resource set. Similarly, setting

    -

    -         *backarrowKey: false
    -

    +
    + + +

    + *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 - + resources from the app-defaults file, I see that it sets + +
    + -

    -         *backarrowKeyIsErase: true
    -

    +

    + *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: - -

! $Id: xterm.faq.html,v 1.169 2012/02/05 11:58:56 - tom Exp $
! Settings to make xterm-88c work as expected for Debian.
-
!
! Patch #88 was the basis for XFree86 3.3.1 xterm.  There were a few additions
-
! through patch 88c, to incorporate the ptyInitialErase resource.  Debian uses
-
! the VT220-style keyboard, which at #88 was the xterm-xfree86 terminfo entry,
-
! with one change: kbs changed from ^H to ^?.
-
!
! After patch 88, I started work on keyboard changes.  The result was that the
-
! xterm-xfree86 terminfo entry was set to the PC-style keyboard, and I added
-
! xterm-vt220, which corresponded mostly to the older (patch-88) version of the
-
! xterm-xfree86 terminfo entry.
 
- - ! The terminfo with patch #88 assumed sunKeyboard was set (actually a bug, but
-
! also assumed in Debian).
!
-
! A different problem (addressed after patch #88) is that if you wanted to use
-
! a VT100/VT220-style numeric keypad's escape sequences, you had to have
-
! NumLock set.  Otherwise, in keypad application mode, the keys would transmit
-
! only the PC-style escape sequences corresponding to the key labels, e.g., the
-
! page-up string rather than the escape sequence for keypad-9.
-
XTerm*sunKeyboard: true
-  
- ! These settings overlap to some extent (backarrowKeys says to send a 127 for
-
! the "backspace" key, and ptyInitialErase says to use the pty's initial sense
-
! of the erase character, which is reported to be the same on Linux).
-
XTerm*backarrowKey: false
- XTerm*ptyInitialErase: true
-

+ + +

Here is a resource file which I + tested with xterm-88c, xterm-149 and xterm-158, using $TERM set + to xterm-debian:

+ +
+ + +

+ ! $Id: xterm.faq.html,v 1.169 + 2012/02/05 11:58:56 tom Exp $
! Settings to make xterm-88c work as expected for Debian.
+
!
! Patch #88 was the basis for XFree86 3.3.1 xterm.  There were a few additions
+
! through patch 88c, to incorporate the ptyInitialErase resource.  Debian uses
+
! the VT220-style keyboard, which at #88 was the xterm-xfree86 terminfo entry,
+
! with one change: kbs changed from ^H to ^?.
+
!
! After patch 88, I started work on keyboard changes.  The result was that the
+
! xterm-xfree86 terminfo entry was set to the PC-style keyboard, and I added
+
! xterm-vt220, which corresponded mostly to the older (patch-88) version of the
+
! xterm-xfree86 terminfo entry.
 
+ + ! The terminfo with patch #88 assumed sunKeyboard was set (actually a bug, but
+
! also assumed in Debian).
!
+
! A different problem (addressed after patch #88) is that if you wanted to use
+
! a VT100/VT220-style numeric keypad's escape sequences, you had to have
+
! NumLock set.  Otherwise, in keypad application mode, the keys would transmit
+
! only the PC-style escape sequences corresponding to the key labels, e.g., the
+
! page-up string rather than the escape sequence for keypad-9.
+
XTerm*sunKeyboard: true
+  
+ ! These settings overlap to some extent (backarrowKeys says to send a 127 for
+
! the "backspace" key, and ptyInitialErase says to use the pty's initial sense
+
! of the erase character, which is reported to be the same on Linux).
+
XTerm*backarrowKey: false
+ XTerm*ptyInitialErase: true
+

+

Why can't I use the cursor keys in (whatever) @@ -3240,12 +3709,14 @@ given for the cursor or keypad keys.

Alt-keys do not work in bash

See - Alt-keys do - not work in bash. + "bash_meta_mode">Alt-keys do not work in bash

+ +

See Alt-keys do not work + in bash.

-

Colors and - other graphic rendition

+

Colors and other graphic rendition

My terminal doesn't recognize color

@@ -3255,12 +3726,12 @@ 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.

+ "xterm.faq.html#my_xdefaults">.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.

+ "xterm.faq.html#alloc_color">warning message for this.

Check the terminal description, to see if it is installed properly, e.g., for What $TERM should I use? +

XTerm provides in its sources both terminfo and termcap files. They are designed + to allow scripting to override the most common choices, e.g., the + backspace key.

+

The xterm-color value for $TERM is a bad choice for modern xterm because it is commonly used for a terminfo entry which happens to not support bce. Complicating @@ -3353,7 +3829,8 @@ resource accordingly in the app-defaults file for the system which has the newer xterm.

-

However – see above.

+

However – see above.

My colors changed in vim

@@ -3390,6 +3867,168 @@ make the colors work as before – and work consistently with other terminals.

+

Aren't bright colors the same as + bold?

+ +

No.

+ +

Actually, "bold" happens to be whatever the terminal shows + when it is sent the control-string that says "show bold".

+ +

The standard (ANSI aka ISO-6429 or ECMA-48) says no more than + that. ANSI specified eight (8) colors. In fact, ANSI did not + specify the appearance. That is an implementation detail.

+ +

XTerm can be configured to use colors 8-15 for displaying bold + text. Or it can be configured to use those colors as part of a + 16-color scheme (a feature of aixterm). They use different + control strings. When xterm is configured to use the 16-color + scheme, it displays bold text by relying on the font to show + "bold" (usually thicker characters).

+ +

By default, colors 8-15 are brighter versions of colors 0-7 + (with some special handling for blue). But again, xterm is + configurable and you can use anything that you like for the + numbered colors.

+ +

I don't like that shade of blue

+ +

Nobody does. But there are no universal solutions.

+ +

If your terminal (or the application running in it has a dark + background, then darker blues are hard to see. With a light + background, yellows are hard to see.

+ +

The available standards do not help: there are no + standards for terminal colors. Here is an illustration which I + made in reply to a bug + report, contrasting different choices for blue, against some + of the other terminals which (were said to) provide "standard + vt100 colors":

+ +
+

+

+
+ +

Of course, anyone developing a terminal emulator + already knew that vt100's never did do + colors.

+ +

Ultimately it is up to the application running in a terminal + to enforce the colors it needs. XTerm merely provides the best + compromise on default visibility that I and my users have + found.

+ +

Why doesn't xterm support italics?

+ +

Well, actually it does and it doesn't.

+ +

You can display "any" font using xterm (though proportional + fonts may be disappointing).

+ +

But xterm has specific types of graphic rendition that it will + do. If you want italics, then xterm has an option + (italicULMode) to use that rendition instead of + underlining. That is the usual typographic alternative, though of + course some people want both at the same time.

+ +

However, curses does not support italics. Few terminals do + this reliably, so it was disregarded long ago, never was + standardized except for low-level applications (in terminfo). No + bit was reserved in the curses header for adding italics for + high-level applications. (As a special case, ncurses could be + modified to do this, but other implementations would not + work).

+ +

XTerm stores each cell of the display in fixed-size + structures. One byte stores the graphic rendition. XTerm is using + all of the bits in this byte for its VT220 emulation:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
MnemonicBitDescription
INVERSE0show cell reverse-video
UNDERLINE1show cell underlined
BOLD2show cell as bold
BLINK3show cell as blinking
BG_COLOR4use background color
FG_COLOR5use foreground color
PROTECTED6character cannot be erased
CHARDRAWN7character has been drawn here on the screen
+ +

While additional bytes could be added to each cell, the cost + to the typical user has so far not been in line with the + usefulness of the feature.

+

"grep --color" does not show the right output

@@ -3433,6 +4072,59 @@ of the next line. In that case, grep's output will not look right.

+

That description of wrapping is odd, say + more?

+ +

This is one of the aspects of the so-called "vt100 glitch", as + mentioned in the terminfo manpage:

+ +
+

Terminals which ignore a line-feed immediately after an am + wrap, such as the Concept and vt100, should indicate xenl.

+
+ +

When the terminal reaches the right margin, it is in a special + state where it ignores tab characters and other formatting + controls (carriage return and newline), and in effect is + expecting only printable characters to wrap to the next line.

+ +

Without it, it is misleading to refer to a terminal as a vt100 + emulator. After all, it is a well-known feature named for the + VT100. The applicable standards (ISO-6429, ECMA-48) do not go + into enough detail to address this sort of behavior, so the other + terminal emulators can be referred to most accurately as ANSI + terminals (if they obey the other guidelines).

+ +

In 2004, I added a test-screen + to vttest to demonstrate this. It was in response to someone who + insisted that xterm was wrong and one of those other terminal + emulators was "right". I investigated, found that the behavior + had not changed in xterm at least since the early 1990s, and that + it matched the description of behavior from the DEC manuals. One + of my users verified the correctness of the test on a VT520.

+ +

Reviewing the results with xterm-alikes or less ambitious + "vt100 emulators" in mid-2012:

+ +
    +
  • xterm, kterm, mlterm, rxvt are consistent with the VT100 + behavior.
  • + +
  • screen, putty (pterm), konsole, vte (gnome-terminal), + xfce4-terminal are not consistent with VT100 (and behave + differently compared to each other). + +

    I included screen here because it claims to be a vt100 + emulator, and putty since it claims to be an xterm emulator. + I did not include tmux, because it does not make either + claim.

    +
  • + +
  • mrxvt does not get to that screen; it resizes its window to + a single line.
  • +
+

Odd behavior

@@ -3449,8 +4141,8 @@

Why can't I select tabs in xterm?

-

This issue was noted early on, here - in 1997.

+

This issue was noted early on, here in 1997.

XTerm is copying from the screen, which stores only printable characters. That includes spaces and @@ -3567,18 +4259,26 @@

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

+ 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
+

+ cp /usr/lib/terminfo/x/xterm /usr/lib/terminfo/x/xterm.orig
-         tic /tmp/xterm.src
+ 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:

@@ -3644,7 +4344,8 @@

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 + discussion of titeInhibit, full-screen applications can expect the initialization string to save the cursor's position, and the end-string to restore it.

@@ -3683,10 +4384,12 @@ hackers.

For instance

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

Why can't my program read the window title?

@@ -3726,91 +4429,290 @@

You should be able to override it, as noted above via resource settings or menu entry ("Allow Window Ops").

-

Sample .Xdefaults Color-Settings for - XTerm

- -

-         XTerm*internalBorder:  10
- -         XTerm*highlightSelection:  true
- -         XTerm*VT100.colorBDMode:  on
- -         XTerm*VT100.colorBD:  blue
- -         XTerm*VT100.colorULMode:  on
+

Why is the text in the + wrong place?

-         XTerm*VT100.colorUL:  magenta
+

Are you using Ubuntu? This is a frequently-reported problem + for Ubuntu users. With other systems, it can occur (as of + September 2012), but is less frequent. But it has been an issue + with Ubuntu since 2008.

-         XTerm*VT100.eightBitInput:  true
+

There are several related symptoms, e.g.,

-         XTerm*VT100.eightBitOutput:  true
- -         XTerm*scrollBar:  true
- -         XTerm*VT100.titeInhibit:  true
- -  
-         XTerm*VT100.colorMode:  on
+
    +
  • text may be the wrong size
  • -         XTerm*VT100.dynamicColors:  on
    +
  • repainting the screen puts text in the wrong place
  • +
-  
-         ! Uncomment this to use color for underline attribute
-
-         XTerm*VT100.colorULMode:  on
+

Here are some of the corresponding bug reports:

-         XTerm*VT100.underLine:  off
+ -         XTerm*VT100.colorUL: yellow
+

Since the problem is not in xterm, all I can do is to help + forward those bug-reports to whatever package owns + compiz. What these have in common is that someone + has written code which is tested against only a small subset of + the X protocol.

+ +

Looking for solutions (since compiz is not being fixed), it is + possible to disable compiz. The means for doing this vary with + time. Aside from pointing to the root cause of the problem, there + is little advice that is useful.

+ +
    +
  • For instance, this + comment by Eric Williams suggests that the problem can be + worked around by setting xterm's borderWidth + resource to zero.
  • + +
  • other comments suggest turning off the "desktop effects" or + "animation".
  • + +
  • On my machines using the default Ubuntu desktop, I + can see misbehavior easily in Ubuntu 12.04 using vttest. However, Ubuntu 12.04 + provides Ubuntu 2D, which does not show those + problems (and is noticeably faster).
  • +
-         XTerm*VT100.colorBD: white
+

Sample .Xdefaults Color-Settings for + XTerm

-  
-         XTerm*VT100.cursorColor: lime green
+
+ -

+

+ 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
+

+

XTerm comes with two copies of each resource file, one with color only (XTerm-col.ad, which is @@ -3819,13 +4721,16 @@ 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:

+ file:

+ +
+ -

-         *customization: -color
-

+

+ *customization: -color
+

+

What is this warning message?

@@ -3862,12 +4767,17 @@

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:

+ setting a resource:

-

-         XTerm*openIm:false
+

+ -

+

+ XTerm*openIm:false
+

+
Warning: Actions not found: ignore, @@ -3876,50 +4786,61 @@
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 + support them. For example, this -

-         XTerm*translations:     #override\n\
+

+ -                 <Leave>, ~Ctrl ~Meta <Btn2Up>: ignore()\n\
+

+ XTerm*translations:     #override\n\
+         
<Leave>, ~Ctrl ~Meta <Btn2Up>: ignore()\n\
-                 ~Shift 
<Key>KP_8: scroll-back(1,line)\n\
+         ~Shift <Key>KP_8: scroll-back(1,line)\n\
-                 ~Shift 
<Key>KP_2: scroll-forw(1,line)\n\
+         ~Shift <Key>KP_2: scroll-forw(1,line)\n\
-                 Shift 
<Key>KP_8: scroll-back(1,halfpage)\n\
+         Shift <Key>KP_8: scroll-back(1,halfpage)\n\
-                 Shift 
<Key>KP_2: scroll-forw(1,halfpage)
+         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
+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.

+ "VT100" widget.

-

-         XTerm*VT100.translations:     #override\n\
+

+ -                 <Leave>, ~Ctrl ~Meta <Btn2Up>: ignore()\n\
+

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

+

+
During resource initialization, xterm attempts to allocate @@ -3963,7 +4884,7 @@ 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 +

Note that of the emulators that support color, some 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 @@ -3972,10 +4893,11 @@ (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.
  • +
  • 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.
  • @@ -4007,9 +4929,11 @@
  • 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:
+

(These bugs are also present in the X11R5 version).

+ +

Update 2004/04/08:
Complicating this discussion is the "X.Org" xterm (from 2004). That is the XFree86 xterm from XFree86 CVS with all visible "xfree86" strings changed to "X.Org" or "xorg", depending on the @@ -4025,7 +4949,7 @@

COLOR_XTERM download

+ "ftp://ftp.x.org/contrib/applications/color_xterm-beta1.tar.gz">download

This is based on the X Consortium X11R5 source, with the same bugs.

@@ -4045,7 +4969,7 @@

ANSI_XTERM + "ftp://ftp.x.org/contrib/applications/xterm-R6-sb_right-ansi-3d.tar.gz"> download

This is based on the X Consortium source, with the same @@ -4087,7 +5011,7 @@

EMU 1.3 download

+ "ftp://ftp.x.org/contrib/applications/emu-1.31.tar.gz">download

This is not based on the X Consortium source. The authors state that it implements VT220 emulation. It is in need of @@ -4116,21 +5040,21 @@

GNOME Terminal is developed separately from both xterm and rxvt, and was originally 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 xterm's - vt220-style "Send Device Attributes" (Secondary DA) control - sequence to obtain the terminal emulator's version. That is, it - sends

+ 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 xterm's vt220-style "Send + Device Attributes" (Secondary DA) control sequence to obtain the + terminal emulator's version. That is, it sends

-        \E[>c
+\E[>c
 
@@ -4138,7 +5062,7 @@
-        \E[>0;138;0c
+\E[>0;138;0c
 
@@ -4184,14 +5108,14 @@

The documentation for GNOME terminal asserts:

- GNOME Terminal emulates the xterm application developed by the - X Consortium. In turn, the xterm application emulates the DEC - VT102 terminal and also supports the DEC VT220 escape +

GNOME Terminal emulates the xterm application developed by + the X Consortium. In turn, the xterm application emulates the + DEC VT102 terminal and also supports the DEC VT220 escape sequences. An escape sequence is a series of characters that starts with the Esc character. GNOME Terminal accepts all of the escape sequences that the VT102 and VT220 terminals use for functions such as to position the cursor and to clear the - screen. + screen.

That sounds fine, except that it is both inaccurate and @@ -4215,10 +5139,10 @@

misleading
-
as noted in Xterm Control - Sequences, xterm (mostly after "X Consortium") supports - control sequences which are not VT100/VT220. GNOME Terminal - implements many of these, but not all.
+
as noted in Xterm + Control Sequences, xterm (mostly after "X Consortium") + supports control sequences which are not VT100/VT220. GNOME + Terminal implements many of these, but not all.

Perhaps that was unintentional – GNOME developers did @@ -4243,8 +5167,9 @@

VTE's README file asserts

- VTE supports Unicode and character set conversion, as well as - emulating any terminal known to the system's terminfo database. +

VTE supports Unicode and character set conversion, as well + as emulating any terminal known to the system's terminfo + database.

The latter part of that ("emulating any terminal") is @@ -4300,9 +5225,9 @@

For instance, VTE cannot emulate dtterm, because of differences in color - behavior. In fact, VTE does not use any of the termcap data to - support its interpretation of color control sequences.

+ "xterm.faq.html#bug_dtterm">dtterm, because of differences in + color behavior. In fact, VTE does not use any of the termcap data + to support its interpretation of color control sequences.

Because of GNOME Terminal's reputation for excessive code bloat, developers of every other program based on VTE advertise @@ -4348,7 +5273,7 @@

HANTERM download

+ "http://www.debian.org/Packages/frozen/x11/hanterm.html">download

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

@@ -4357,9 +5282,10 @@ "bug_konsole">KONSOLE link -

More than just a rewrite of kvt into - C++. But there are several incompatibilities between konsole - (noted with version 1.0.2 in late 2001) and xterm:

+

More than just a rewrite of kvt into C++. But there are several + incompatibilities between konsole (noted with version 1.0.2 in + late 2001) and xterm:

  • none of the selections of keyboard mappings match the @@ -4380,25 +5306,26 @@
  • 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.
  • + "xterm.faq.html#xterm_tite">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.

The problems with setmode 1049 were fixed after some time; other issues linger on.

-

Like GNOME Terminal, konsole's - documentation is incomplete and inaccurate. This gem from its - handbook illustrates the problem:

+

Like GNOME + Terminal, konsole's documentation is incomplete and + inaccurate. This gem from its handbook illustrates the + problem:

- After a decade, Konsole is the first rewrite from the ground +

After a decade, Konsole is the first rewrite from the ground up. While xterm has definitely been hacked to death (its README begins with the words Abandon All Hope, Ye Who Enter Here), Konsole offers a fresh start using contemporary technologies - and understanding of X. + and understanding of X.

The problem:

@@ -4407,11 +5334,11 @@
  • the remark was apparently written in 1997. It was inaccurate at that time, since it disregards the earlier xvt/rxvt applications. Limiting it only to a plain statement - that konsole was a rewrite of kvt would - have been more accurate. Lacking that context, we find - nonfactual articles such as this on the - net.
  • + that konsole was a rewrite of kvt would have been more accurate. + Lacking that context, we find nonfactual articles such as + this + on the net.
  • for those lacking a proper education, the README was apparently intended to be a humorous reference to Dante's @@ -4423,7 +5350,7 @@

    KTERM download

    + "ftp://ftp.x.org/contrib/applications/kterm-6.2.0.tar.gz">download

    KTerm stands for "Kanji term" (Japanese). This is based on the X Consortium source, with the same bugs (though the list of @@ -4461,10 +5388,9 @@

    -    (mouse@Lightning.McRCIM.McGill.EDU) Available:
    -    larry.mcrcim.mcgill.edu (132.206.1.1) in
    -    /X/mterm.src/mterm.ball-o-wax.
    -  
    +(mouse@Lightning.McRCIM.McGill.EDU) Available:
    +larry.mcrcim.mcgill.edu (132.206.1.1) in
    +/X/mterm.src/mterm.ball-o-wax.  
     
    @@ -4531,9 +5457,9 @@ "bug_nxterm">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.

    + 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
    • @@ -4555,12 +5481,12 @@ comment:

      - rxvt, version 2.6.2, is a colour vt102 terminal emulator +

      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. + X sessions.

      How much is much less? Perhaps not as much as one @@ -4570,9 +5496,9 @@

      The toolkit-style configurability glibly referenced is the ability to redefine keys on the keyboard without recompiling the - program, i.e., the translations - resource. It also is the way mouse events and other actions are - passed to xterm.

      + program, i.e., the translations resource. It also is + the way mouse events and other actions are passed to xterm.

      The toolkit-style configurability accounts for about 300kb, which does add up if you happen to be running 50 xterm processes @@ -4581,10 +5507,10 @@

      This comment was topical in December 2001:

      - Compared with something like GNOME Terminal, which takes 2-3 +

      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. + indistinguishable to the normal user.

      In June 2010, the numbers have changed somewhat. Here is a @@ -4899,10 +5825,27 @@ conflicting. For example, some versions of rxvt may accept a font resource which does not match the XLFD pattern. It accepts a prefix of "xft:". This feature (apparently - introduced by konsole) tells rxvt to - interpret the remainder of the string as a TrueType (Xft) font - rather than a bitmap font. xterm uses the faceName - resource for these values.

      + introduced by konsole) + tells rxvt to interpret the remainder of the string as a TrueType + (Xft) font rather than a bitmap font. xterm uses the + faceName resource for these values.

      + +

      st link

      + +

      Rxvt revisited, this program depends only on the X11 library. + As of January 2013, it is in heavy development, and (according to + comments on its developer's list) growing steadily as the + developers implement useful features adapted from xterm.

      + +

      For instance, the size counting libraries for st 0.3 on my + Debian testing machine is on a par with rxvt (and half that of + xterm, which uses the X Toolkit library).

      + +

      By the way, the page quotes the README file from xterm's + sources, omitting my editorial comment at the top noting that the + paraphrase of the opening from Dante's Inferno dated + from 1991, and pointing to this FAQ to provide better + context.

      XGTERM
      -        xmkmf
      -        make
      +xmkmf
      +make
       
      @@ -4985,7 +5928,7 @@
      -        configure --help
      +configure --help
       
      @@ -4995,6 +5938,57 @@ autoconfigured values, it will still continue to build properly with the imake environment.

      +

      However, I usually build xterm using the configure script. By + default, it looks for imake and will use it to help with a few + places where a reliable configure check cannot be created. One of + these (see Why doesn't the + scrollbar work?) can be a problem.

      + +

      As with all of my projects, I routinely check for strict + compiler warnings. For gcc, that is done with the "gcc-stricter" + script which you can find here. The X libraries have a + longstanding issue which has been ignored so far (as of + mid-2012). To work around this (and get useful warnings), I apply + this patch:

      + +
      +
      +--- Intrinsic.h.orig    2009-08-25 13:22:15.000000000 -0400
      ++++ Intrinsic.h 2009-12-06 09:48:39.000000000 -0500
      +@@ -66,7 +66,11 @@
      + 
      + #define XtSpecificationRelease 6
      + 
      ++#ifdef _CONST_X_STRING
      ++typedef const char *String;
      ++#else
      + typedef char *String;
      ++#endif
      + 
      + /* We do this in order to get "const" declarations to work right.  We
      +  * use _XtString instead of String so that C++ applications can
      +--- Xresource.h.orig    2009-07-19 14:43:21.000000000 -0400
      ++++ Xresource.h 2009-12-06 10:11:19.000000000 -0500
      +@@ -338,8 +338,8 @@
      + } XrmOptionKind;
      + 
      + typedef struct {
      +-    char           *option;        /* Option abbreviation in argv          */
      +-    char           *specifier;     /* Resource specifier                   */
      ++    _Xconst char    *option;       /* Option abbreviation in argv          */
      ++    _Xconst char    *specifier;            /* Resource specifier                   */
      +     XrmOptionKind   argKind;       /* Which style of option it is          */
      +     XPointer       value;          /* Value to provide if XrmoptionNoArg   */
      + } XrmOptionDescRec, *XrmOptionDescList;
      +  
      +
      +
      + +

      I made note of it on the Xorg mailing + list, but as you can see, there was no response.

      +

      How do I report bugs?

      @@ -5010,17 +6004,48 @@

      There appears to be no comprehensive source of information on xterm better than the documentation which comes with the source - code.

      + code

      + +

      Other Sites

      -

      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.

      +
        +
      • I have found Richard Shuford's archive to be invaluable for + notes on the DEC VT220 and related terminals. This was a + webpage + but was last seen via ftp. (I have a snapshot + from the ftp site).
      • + +
      • 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 XTerm Manual

      @@ -5029,26 +6054,24 @@ options of xterm are documented in the manual page.

      Here are copies of the file in various forms: html, - pdf and - text.

      + "manpage/xterm.html">html, pdf, ps + and text.

      Xterm Control Sequences

      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 different - part of the tree long ago). Note that you must format this file - with different options than a manpage, e.g.,

      + "xterm.faq.html#latest_version">program source. (It used to + be in the same directory in the X distribution, but was moved to + a different part of the tree long 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
      +tbl ctlseqs.ms | nroff -ms >ctlseqs.txt
      +tbl ctlseqs.ms | groff -ms >ctlseqs.ps
       
      @@ -5057,30 +6080,72 @@ text file equally readable.

      Here are copies of the file in various forms: html, - pdf - and text.

      + "ctlseqs/ctlseqs.html">html, pdf, ps and text.

      resize – set TERMCAP and terminal settings to - current xterm window size

      resize is useful by - itself, but is maintained for historical reasons as part of - xterm. html, - pdf - and text. + current xterm window size + +

      resize is useful by itself, but is maintained for + historical reasons as part of xterm. html, pdf, ps + and text.

      + +

      uxterm – a UTF-8 wrapper for xterm

      + +

      XTerm does not automatically set your locale. It can + be told to use your locale settings. This is a shell + script which sets xterm's resources to use UTF-8 encoding, and + use UTF-8 fonts. There is a similar lxterm script, but + it relies upon non-portable applications, unlike uxterm.

      + +

      Here are copies of uxterm's documentation: html, pdf, ps + and text.

      + +

      Incidentally, there was a different program named "uxterm" + before the shell script was added to xterm in mid-2000. Roman Czyborra + commented in 1998 that it was based on the original X11 xterm + source (very likely, since "strings" run on the executable shows + the xterm actions, resources and even the Tek4014 support). There + are few references to it to provide details: the first appearance + was in + 1994, and the last was Czyborra's page in 1998. For the + curious, there is a copy on + ibiblio.org (no Linux executables, no source, however).

      + +

      koi8rxterm – a KOI8-R wrapper for + xterm

      + +

      As a special case, this wrapper is packaged with xterm to + provide KOI8-R encoding.

      + +

      Here are copies of koi8rxterm's documentation: html, pdf, ps and text.

      luit – Locale and ISO 2022 support for Unicode - terminals

      luit also is - maintained as part of xterm, since its upstream maintainer is - inactive, and the ostensible maintainers have more than once - delivered unusable versions, causing many bug reports to be - issued against xterm. + terminals + +

      luit also is maintained as + part of xterm, since its upstream maintainer is inactive, and the + ostensible maintainers have more than once delivered unusable + versions, causing many bug reports to be issued against + xterm.

      Ongoing/future work

      @@ -5100,13 +6165,14 @@

      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).

      + "xterm.faq.html#bug_mxterm">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 diff -Nru xterm-278/debian/patches/900_debian_xterm.diff xterm-297/debian/patches/900_debian_xterm.diff --- xterm-278/debian/patches/900_debian_xterm.diff 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/patches/900_debian_xterm.diff 2013-10-29 05:19:15.000000000 +0000 @@ -12,8 +12,7 @@ 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. +* Set the "ptyInitialErase" parameter 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 @@ -38,7 +37,7 @@ =================================================================== --- xterm.orig/terminfo +++ xterm/terminfo -@@ -139,6 +139,8 @@ xterm-new|modern xterm terminal emulator +@@ -137,6 +137,8 @@ xterm-new|modern xterm terminal emulator use=xterm+pcfkeys, use=xterm+tmux, use=xterm-basic, @@ -47,7 +46,7 @@ # # Encode modifiers using parameters (see "Xterm Control Sequences" ctlseqs.ms). # Note that this is unrelated to PCTERM. -@@ -1963,11 +1965,13 @@ xterm-r5|xterm R5 version, +@@ -1967,11 +1969,13 @@ xterm-r5|xterm R5 version, # This is the only entry which you should have to customize, since "xterm" # is widely used for a variety of incompatible terminal emulations including # color_xterm and rxvt. @@ -67,12 +66,11 @@ =================================================================== --- xterm.orig/XTerm.ad +++ xterm/XTerm.ad -@@ -159,6 +159,10 @@ +@@ -159,6 +159,9 @@ *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, diff -Nru xterm-278/debian/patches/902_windowops.diff xterm-297/debian/patches/902_windowops.diff --- xterm-278/debian/patches/902_windowops.diff 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/patches/902_windowops.diff 2013-10-29 05:19:15.000000000 +0000 @@ -2,7 +2,7 @@ =================================================================== --- xterm.orig/xterm.man +++ xterm/xterm.man -@@ -2273,8 +2273,9 @@ This is a comma-separated list of names, +@@ -2416,8 +2416,9 @@ This is a comma-separated list of names, from \fIdtterm\fP the operation number). The default value is .RS @@ -12,4 +12,4 @@ +(i.e. no operations are allowed). .IP The names are listed below. - \fIxterm\fP ignores capitalization, but + \fI\*n\fP ignores capitalization, but diff -Nru xterm-278/debian/patches/904_fontops.diff xterm-297/debian/patches/904_fontops.diff --- xterm-278/debian/patches/904_fontops.diff 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/patches/904_fontops.diff 2013-10-29 05:19:15.000000000 +0000 @@ -2,12 +2,12 @@ =================================================================== --- xterm.orig/xterm.man +++ xterm/xterm.man -@@ -1611,7 +1611,7 @@ The default is \*(``true\*(''. +@@ -1707,7 +1707,7 @@ The default is \*(``true\*(''. .TP .B "allowFontOps (\fPclass\fB AllowFontOps)" Specifies whether control sequences that set/query the font should be allowed. -The default is \*(``true\*(''. +The default is \*(``false\*(''. - .TP 8 - .B "allowScrollLock (\fPclass\fB AllowScrollLock)" - Specifies whether control sequences that set/query + .TP 5 + .B "allowPasteControls (\fPclass\fB AllowPasteControls)" + If true, allow control characters such as BEL and CAN to be pasted. diff -Nru xterm-278/debian/patches/950_ubuntu_charclass_highlight.diff xterm-297/debian/patches/950_ubuntu_charclass_highlight.diff --- xterm-278/debian/patches/950_ubuntu_charclass_highlight.diff 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/patches/950_ubuntu_charclass_highlight.diff 2013-10-29 05:19:15.000000000 +0000 @@ -1,9 +1,9 @@ -Index: xterm-229/XTerm.ad +Index: b/XTerm.ad =================================================================== ---- xterm-229.orig/XTerm.ad 2008-02-06 19:24:14.000000000 +0100 -+++ xterm-229/XTerm.ad 2008-02-06 20:10:01.000000000 +0100 -@@ -187,7 +187,7 @@ - *SimpleMenu*borderWidth: 2 +--- a/XTerm.ad ++++ b/XTerm.ad +@@ -237,7 +237,7 @@ + !*faceSize: 8 ! Here is a pattern that is useful for double-clicking on a URL: -!*charClass: 33:48,35:48,37-38:48,43-47:48,58:48,61:48,63-64:48,95:48,126:48 diff -Nru xterm-278/debian/rules xterm-297/debian/rules --- xterm-278/debian/rules 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/rules 2013-10-29 05:19:15.000000000 +0000 @@ -6,33 +6,16 @@ # Licensed under the GNU General Public License, version 2. See the file # /usr/share/common-licenses/GPL or . -include debian/xsfbs/xsfbs.mk - -# debhelper -export DH_OPTIONS - -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 = $(shell dpkg-buildflags --get CFLAGS) CFLAGS += -Wall LDFLAGS = $(shell dpkg-buildflags --get LDFLAGS) CPPFLAGS = $(shell dpkg-buildflags --get CPPFLAGS) -ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) - NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) - MAKEFLAGS += -j$(NUMJOBS) -endif - HTML2TEXT:=lynx -dump -nolist +DEBTREEDIR:=$(CURDIR)/debian/tmp + DESKTOP_FLAGS = --vendor debian \ --dir=$(DEBTREEDIR)/usr/share/applications @@ -42,18 +25,12 @@ -DDEF_ALLOW_TCAP=False \ -DDEF_DISALLOWED_WINDOW=\\\"1,2,3,4,5,6,7,8,9,11,13,14,18,19,20,21,GetSelection,SetSelection,SetWinLines,SetXprop\\\" -.PHONY: configure -configure: $(STAMP_DIR)/configure -$(STAMP_DIR)/configure: $(STAMP_DIR)/patch - dh_testdir - dh_autotools-dev_updateconfig - [ -d build ] || mkdir build - cd build && \ - ../configure \ - --prefix=/usr \ +override_dh_auto_configure: + dh_auto_configure -- \ --exec-prefix=/usr \ - --mandir=/usr/share/man \ --with-app-defaults=/etc/X11/app-defaults \ + --with-icondir=/usr/share/icons \ + --with-icon-theme=yes \ --with-tty-group=tty \ --enable-logging \ --enable-wide-chars \ @@ -63,75 +40,31 @@ --enable-narrowproto \ --enable-exec-xterm \ --enable-dabbrev \ + --enable-backarrow-is-erase \ + --enable-sixel-graphics \ --with-utempter \ - $(confflags) \ DESKTOP_FLAGS="$(DESKTOP_FLAGS)" \ CFLAGS="$(CFLAGS)" \ CPPFLAGS="$(CPPFLAGS)" \ LDFLAGS="$(LDFLAGS)" \ LUIT=/usr/bin/luit - >$@ +override_dh_auto_build: + dh_auto_build + $(HTML2TEXT) debian/local/xterm.faq.html >debian/local/xterm.faq -.PHONY: build -build: $(STAMP_DIR)/build -$(STAMP_DIR)/build: $(STAMP_DIR)/configure debian/local/xterm.faq - dh_testdir - cd build && $(MAKE) - >$@ - -.PHONY: clean -clean: xsfclean - dh_testdir - rm -rf $(STAMP_DIR) - rm -rf build - dh_autotools-dev_restoreconfig - dh_clean debian/local/xterm.faq - -.PHONY: install -install: build - dh_testdir - dh_testroot - dh_clean -k - dh_installdirs - # General installation - cd build && \ - $(MAKE) install install-desktop mandir=/usr/share/man/man1 libdir=/etc DESTDIR=$(DEBTREEDIR) - +override_dh_auto_install: + dh_auto_install --destdir=debian/tmp -- install-desktop ## Install lxterm command and manual page. install -m 755 debian/local/lxterm $(DEBTREEDIR)/usr/bin install -m 755 debian/local/lxterm.1 $(DEBTREEDIR)/usr/share/man/man1 ## Install terminfo and termcap precompiled definitions. - install -d $(DEBTREEDIR)/usr/lib - install -m 644 termcap $(DEBTREEDIR)/usr/lib/xterm.termcap - install -m 644 terminfo $(DEBTREEDIR)/usr/lib/xterm.terminfo - dh_installdocs - dh_installchangelogs - dh_installmenu - dh_install --sourcedir=debian/tmp --list-missing - -# Generate plain text XTerm FAQ from HTML. -debian/local/xterm.faq: debian/local/xterm.faq.html - $(HTML2TEXT) $< >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 - dh_installdeb - dh_shlibdeps - dh_gencontrol - dh_md5sums - dh_builddeb - -# this target is required by policy -.PHONY: binary-indep -binary-indep: + install -d $(DEBTREEDIR)/usr/share/doc/xterm + install -m 644 termcap $(DEBTREEDIR)/usr/share/doc/xterm/xterm.termcap + install -m 644 terminfo $(DEBTREEDIR)/usr/share/doc/xterm/xterm.terminfo + +override_dh_install: + dh_install --fail-missing -# vim:set ai noet sw=8 ts=8 tw=0: +%: + dh $@ --with quilt,autotools_dev --builddirectory=build/ --parallel diff -Nru xterm-278/debian/xsfbs/repack.sh xterm-297/debian/xsfbs/repack.sh --- xterm-278/debian/xsfbs/repack.sh 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/xsfbs/repack.sh 1970-01-01 00:00:00.000000000 +0000 @@ -1,32 +0,0 @@ -#!/bin/sh - -set -e - -if ! [ -d debian/prune ]; then - exit 0 -fi - -if [ "x$1" != x--upstream-version ]; then - exit 1 -fi - -version="$2" -filename="$3" - -if [ -z "$version" ] || ! [ -f "$filename" ]; then - exit 1 -fi - -dir="$(pwd)" -tempdir="$(mktemp -d)" - -cd "$tempdir" -tar xf "$dir/$filename" -cat "$dir"/debian/prune/* | while read file; do rm -f */$file; done - -tar czf "$dir/$filename" * -cd "$dir" -rm -rf "$tempdir" -echo "Done pruning upstream tarball" - -exit 0 diff -Nru xterm-278/debian/xsfbs/xsfbs.mk xterm-297/debian/xsfbs/xsfbs.mk --- xterm-278/debian/xsfbs/xsfbs.mk 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/xsfbs/xsfbs.mk 1970-01-01 00:00:00.000000000 +0000 @@ -1,285 +0,0 @@ -#!/usr/bin/make -f - -# Debian X Strike Force Build System (XSFBS): Make portion - -# Copyright 1996 Stephen Early -# Copyright 1997 Mark Eichin -# Copyright 1998-2005, 2007 Branden Robinson -# Copyright 2005 David Nusinow -# -# Licensed under the GNU General Public License, version 2. See the file -# /usr/share/common-licenses/GPL or . - -# Originally by Stephen Early -# Modified by Mark W. Eichin -# Modified by Adam Heath -# Modified by Branden Robinson -# Modified by Fabio Massimo Di Nitto -# Modified by David Nusinow -# Acknowledgements to Manoj Srivastava. - -# Pass $(DH_OPTIONS) into the environment for debhelper's benefit. -export DH_OPTIONS - -# force quilt to not use ~/.quiltrc and to use debian/patches -QUILT = QUILT_PATCHES=debian/patches quilt --quiltrc /dev/null - -# Set up parameters for the upstream build environment. - -# Determine (source) package name from Debian changelog. -SOURCE_NAME:=$(shell dpkg-parsechangelog -ldebian/changelog \ - | grep '^Source:' | awk '{print $$2}') - -# Determine package version from Debian changelog. -SOURCE_VERSION:=$(shell dpkg-parsechangelog -ldebian/changelog \ - | grep '^Version:' | awk '{print $$2}') - -# Determine upstream version number. -UPSTREAM_VERSION:=$(shell echo $(SOURCE_VERSION) | sed 's/-.*//') - -# Determine the source version without the epoch for make-orig-tar-gz -NO_EPOCH_VER:=$(shell echo $(UPSTREAM_VERSION) | sed 's/^.://') - -# Figure out who's building this package. -BUILDER:=$(shell echo $${DEBEMAIL:-$${EMAIL:-$$(echo $$LOGNAME@$$(cat /etc/mailname 2>/dev/null))}}) - -# Find out if this is an official build; an official build has nothing but -# digits, dots, and/or the codename of a release in the Debian part of the -# version number. Anything else indicates an unofficial build. -OFFICIAL_BUILD:=$(shell VERSION=$(SOURCE_VERSION); if ! expr "$$(echo $${VERSION\#\#*-} | sed 's/\(woody\|sarge\|etch\|lenny\)//g')" : ".*[^0-9.].*" >/dev/null 2>&1; then echo yes; fi) - -# Set up parameters for the Debian build environment. - -# Determine our architecture. -BUILD_ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH) -# Work around some old-time dpkg braindamage. -BUILD_ARCH:=$(subst i486,i386,$(BUILD_ARCH)) -# The DEB_HOST_ARCH variable may be set per the Debian cross-compilation policy. -ifdef DEB_HOST_ARCH - ARCH:=$(DEB_HOST_ARCH) -else - # dpkg-cross sets the ARCH environment variable; if set, use it. - ifdef ARCH - ARCH:=$(ARCH) - else - ARCH:=$(BUILD_ARCH) - endif -endif - -# $(STAMP_DIR) houses stamp files for complex targets. -STAMP_DIR:=stampdir - -# $(DEBTREEDIR) is where all install rules are told (via $(DESTDIR)) to place -# their files. -DEBTREEDIR:=$(CURDIR)/debian/tmp - -# All "important" targets have four lines: -# 1) A target name that is invoked by a package-building tool or the user. -# This consists of a dependency on a "$(STAMP_DIR)/"-prefixed counterpart. -# 2) A line delcaring 1) as a phony target (".PHONY:"). -# 3) A "$(STAMP_DIR)/"-prefixed target which does the actual work, and may -# depend on other targets. -# 4) A line declaring 3) as a member of the $(stampdir_targets) variable; the -# "$(STAMP_DIR)/" prefix is omitted. -# -# This indirection is needed so that the "stamp" files that signify when a rule -# is done can be located in a separate "stampdir". Recall that make has no way -# to know when a goal has been met for a phony target (like "build" or -# "install"). -# -# At the end of each "$(STAMP_DIR)/" target, be sure to run the command ">$@" -# so that the target will not be run again. Removing the file will make Make -# run the target over. - -# All phony targets should be declared as dependencies of .PHONY, even if they -# do not have "($STAMP_DIR)/"-prefixed counterparts. - -# Define a harmless default rule to keep things from going nuts by accident. -.PHONY: default -default: - -# Set up the $(STAMP_DIR) directory. -.PHONY: stampdir -stampdir_targets+=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 -stampdir_targets+=prepare -prepare: $(STAMP_DIR)/prepare -$(STAMP_DIR)/prepare: $(STAMP_DIR)/logdir $(STAMP_DIR)/genscripts - >$@ - -.PHONY: logdir -stampdir_targets+=logdir -logdir: $(STAMP_DIR)/logdir -$(STAMP_DIR)/logdir: $(STAMP_DIR)/stampdir - mkdir -p $(STAMP_DIR)/log - >$@ - -# Apply all patches to the upstream source. -.PHONY: patch -stampdir_targets+=patch -patch: $(STAMP_DIR)/patch -$(STAMP_DIR)/patch: $(STAMP_DIR)/prepare - if ! [ `which quilt` ]; then \ - echo "Couldn't find quilt. Please install it or add it to the build-depends for this package."; \ - exit 1; \ - fi; \ - if $(QUILT) next >/dev/null 2>&1; then \ - 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; \ - else \ - echo "No patches to apply"; \ - fi; \ - >$@ - -# Revert all patches to the upstream source. -.PHONY: unpatch -unpatch: $(STAMP_DIR)/logdir - rm -f $(STAMP_DIR)/patch - @echo -n "Unapplying patches..."; \ - if $(QUILT) applied >/dev/null 2>/dev/null; then \ - 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; \ - else \ - echo "nothing to do."; \ - fi - -# Clean the generated maintainer scripts. -.PHONY: cleanscripts -cleanscripts: - rm -f $(STAMP_DIR)/genscripts - rm -f debian/*.config \ - debian/*.postinst \ - debian/*.postrm \ - debian/*.preinst \ - debian/*.prerm - -# Clean the package build tree. -.PHONY: xsfclean -xsfclean: cleanscripts unpatch - dh_testdir - rm -rf .pc - rm -rf $(STAMP_DIR) - dh_clean - -# Remove files from the upstream source tree that we don't need, or which have -# licensing problems. It must be run before creating the .orig.tar.gz. -# -# Note: This rule is for Debian package maintainers' convenience, and is not -# needed for conventional build scenarios. -.PHONY: prune-upstream-tree -prune-upstream-tree: - # Ensure we're in the correct directory. - dh_testdir - grep -rvh '^#' debian/prune/ | xargs --no-run-if-empty rm -rf - -# Verify that there are no offsets or fuzz in the patches we apply. -# -# Note: This rule is for Debian package maintainers' convenience, and is not -# needed for conventional build scenarios. -.PHONY: patch-audit -patch-audit: prepare unpatch - @echo -n "Auditing patches..."; \ - >$(STAMP_DIR)/log/patch; \ - FUZZY=; \ - while [ -n "$$($(QUILT) next)" ]; do \ - RESULT=$$($(QUILT) push -v | tee -a $(STAMP_DIR)/log/patch | grep ^Hunk | sed 's/^Hunk.*\(succeeded\|FAILED\).*/\1/');\ - case "$$RESULT" in \ - succeeded) \ - echo "fuzzy patch: $$($(QUILT) top)" \ - | tee -a $(STAMP_DIR)/log/$$($(QUILT) top); \ - FUZZY=yes; \ - ;; \ - FAILED) \ - echo "broken patch: $$($(QUILT) next)" \ - | tee -a $(STAMP_DIR)/log/$$($(QUILT) next); \ - exit 1; \ - ;; \ - esac; \ - done; \ - if [ -n "$$FUZZY" ]; then \ - echo "there were fuzzy patches; please fix."; \ - exit 1; \ - else \ - echo "done."; \ - fi - -# Generate the maintainer scripts. -.PHONY: genscripts -stampdir_targets+=genscripts -genscripts: $(STAMP_DIR)/genscripts -$(STAMP_DIR)/genscripts: $(STAMP_DIR)/stampdir - for FILE in debian/*.config.in \ - debian/*.postinst.in \ - debian/*.postrm.in \ - debian/*.preinst.in \ - debian/*.prerm.in; do \ - if [ -e "$$FILE" ]; then \ - MAINTSCRIPT=$$(echo $$FILE | sed 's/.in$$//'); \ - sed -n '1,/^#INCLUDE_SHELL_LIB#$$/p' <$$FILE \ - | sed -e '/^#INCLUDE_SHELL_LIB#$$/d' >$$MAINTSCRIPT.tmp; \ - cat debian/xsfbs/xsfbs.sh >>$$MAINTSCRIPT.tmp; \ - sed -n '/^#INCLUDE_SHELL_LIB#$$/,$$p' <$$FILE \ - | sed -e '/^#INCLUDE_SHELL_LIB#$$/d' >>$$MAINTSCRIPT.tmp; \ - sed -e 's/@SOURCE_VERSION@/$(SOURCE_VERSION)/' \ - -e 's/@OFFICIAL_BUILD@/$(OFFICIAL_BUILD)/' \ - <$$MAINTSCRIPT.tmp >$$MAINTSCRIPT; \ - rm $$MAINTSCRIPT.tmp; \ - fi; \ - done - # Validate syntax of generated shell scripts. - #sh debian/scripts/validate-posix-sh debian/*.config \ - # debian/*.postinst \ - # debian/*.postrm \ - # debian/*.preinst \ - # debian/*.prerm - >$@ - -# Compute dependencies for drivers -# -VIDEODEP = $(shell cat /usr/share/xserver-xorg/videodrvdep 2>/dev/null) -INPUTDEP = $(shell cat /usr/share/xserver-xorg/xinputdep 2>/dev/null) - -# these two can be removed post-squeeze -VIDEOABI = $(shell cat /usr/share/xserver-xorg/videoabiver 2>/dev/null) -INPUTABI = $(shell cat /usr/share/xserver-xorg/inputabiver 2>/dev/null) -VIDDRIVER_PROVIDES = xserver-xorg-video-$(VIDEOABI), xorg-driver-video -INPDRIVER_PROVIDES = xserver-xorg-input-$(INPUTABI), xorg-driver-input - -ifeq ($(PACKAGE),) -PACKAGE=$(shell awk '/^Package:/ { print $$2; exit }' < debian/control) -endif - -.PHONY: serverabi -serverabi: install -ifeq ($(VIDEODEP),) - @echo 'error: xserver-xorg-dev >= 1.7.6.901 needs to be installed' - @exit 1 -else - echo "xviddriver:Depends=$(VIDEODEP)" >> debian/$(PACKAGE).substvars - echo "xinpdriver:Depends=$(INPUTDEP)" >> debian/$(PACKAGE).substvars - # the following is there for compatibility... - echo "xviddriver:Provides=$(VIDDRIVER_PROVIDES)" >> debian/$(PACKAGE).substvars - echo "xinpdriver:Provides=$(INPDRIVER_PROVIDES)" >> debian/$(PACKAGE).substvars - echo "xserver:Depends=$(VIDEODEP), $(INPUTDEP)" >> debian/$(PACKAGE).substvars -endif - -# vim:set noet ai sts=8 sw=8 tw=0: diff -Nru xterm-278/debian/xsfbs/xsfbs.sh xterm-297/debian/xsfbs/xsfbs.sh --- xterm-278/debian/xsfbs/xsfbs.sh 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/xsfbs/xsfbs.sh 1970-01-01 00:00:00.000000000 +0000 @@ -1,622 +0,0 @@ -# This is the X Strike Force shell library for X Window System package -# maintainer scripts. It serves to define shell functions commonly used by -# such packages, and performs some error checking necessary for proper operation -# of those functions. By itself, it does not "do" much; the maintainer scripts -# invoke the functions defined here to accomplish package installation and -# removal tasks. - -# If you are reading this within a Debian package maintainer script (e.g., -# /var/lib/dpkg/info/PACKAGE.{config,preinst,postinst,prerm,postrm}), you can -# skip past this library by scanning forward in this file to the string -# "GOBSTOPPER". - -SOURCE_VERSION=@SOURCE_VERSION@ -OFFICIAL_BUILD=@OFFICIAL_BUILD@ - -# Use special abnormal exit codes so that problems with this library are more -# easily tracked down. -SHELL_LIB_INTERNAL_ERROR=86 -SHELL_LIB_THROWN_ERROR=74 -SHELL_LIB_USAGE_ERROR=99 - -# old -> new variable names -if [ -z "$DEBUG_XORG_PACKAGE" ] && [ -n "$DEBUG_XFREE86_PACKAGE" ]; then - DEBUG_XORG_PACKAGE="$DEBUG_XFREE86_PACKAGE" -fi -if [ -z "$DEBUG_XORG_DEBCONF" ] && [ -n "$DEBUG_XFREE86_DEBCONF" ]; then - DEBUG_XORG_DEBCONF="$DEBUG_XFREE86_DEBCONF" -fi - -# initial sanity checks -if [ -z "$THIS_PACKAGE" ]; then - cat >&2 < on the World Wide Web for -instructions, read the file /usr/share/doc/debian/bug-reporting.txt from the -"doc-debian" package, or install the "reportbug" package and use the command of -the same name to file a report against version $SOURCE_VERSION of this package. -EOF - exit $SHELL_LIB_USAGE_ERROR -fi - -if [ -z "$THIS_SCRIPT" ]; then - cat >&2 < on the World Wide Web for -instructions, read the file /usr/share/doc/debian/bug-reporting.txt from the -"doc-debian" package, or install the "reportbug" package and use the command of -the same name to file a report against version $SOURCE_VERSION of the -"$THIS_PACKAGE" package. -EOF - exit $SHELL_LIB_USAGE_ERROR -fi - -if [ "$1" = "reconfigure" ] || [ -n "$DEBCONF_RECONFIGURE" ]; then - RECONFIGURE="true" -else - RECONFIGURE= -fi - -if ([ "$1" = "install" ] || [ "$1" = "configure" ]) && [ -z "$2" ]; then - FIRSTINST="yes" -fi - -if [ -z "$RECONFIGURE" ] && [ -z "$FIRSTINST" ]; then - UPGRADE="yes" -fi - -trap "message;\ - message \"Received signal. Aborting $THIS_PACKAGE package $THIS_SCRIPT script.\";\ - message;\ - exit 1" HUP INT QUIT TERM - -reject_nondigits () { - # syntax: reject_nondigits [ operand ... ] - # - # scan operands (typically shell variables whose values cannot be trusted) for - # characters other than decimal digits and barf if any are found - while [ -n "$1" ]; do - # does the operand contain anything but digits? - if ! expr "$1" : "[[:digit:]]\+$" > /dev/null 2>&1; then - # can't use die(), because it wraps message() which wraps this function - echo "$THIS_PACKAGE $THIS_SCRIPT error: reject_nondigits() encountered" \ - "possibly malicious garbage \"$1\"" >&2 - exit $SHELL_LIB_THROWN_ERROR - fi - shift - done -} - -reject_unlikely_path_chars () { - # syntax: reject_unlikely_path_chars [ operand ... ] - # - # scan operands (typically shell variables whose values cannot be trusted) for - # characters unlikely to be seen in a path and which the shell might - # interpret and barf if any are found - while [ -n "$1" ]; do - # does the operand contain any funny characters? - if expr "$1" : '.*[!$&()*;<>?|].*' > /dev/null 2>&1; then - # can't use die(), because I want to avoid forward references - echo "$THIS_PACKAGE $THIS_SCRIPT error: reject_unlikely_path_chars()" \ - "encountered possibly malicious garbage \"$1\"" >&2 - exit $SHELL_LIB_THROWN_ERROR - fi - shift - done -} - -# Query the terminal to establish a default number of columns to use for -# displaying messages to the user. This is used only as a fallback in the -# event the COLUMNS variable is not set. ($COLUMNS can react to SIGWINCH while -# the script is running, and this cannot, only being calculated once.) -DEFCOLUMNS=$(stty size 2> /dev/null | awk '{print $2}') || true -if ! expr "$DEFCOLUMNS" : "[[:digit:]]\+$" > /dev/null 2>&1; then - DEFCOLUMNS=80 -fi - -message () { - # pretty-print messages of arbitrary length - reject_nondigits "$COLUMNS" - echo "$*" | fmt -t -w ${COLUMNS:-$DEFCOLUMNS} >&2 -} - -observe () { - # syntax: observe message ... - # - # issue observational message suitable for logging someday when support for - # it exists in dpkg - if [ -n "$DEBUG_XORG_PACKAGE" ]; then - message "$THIS_PACKAGE $THIS_SCRIPT note: $*" - fi -} - -warn () { - # syntax: warn message ... - # - # issue warning message suitable for logging someday when support for - # it exists in dpkg; also send to standard error - message "$THIS_PACKAGE $THIS_SCRIPT warning: $*" -} - -die () { - # syntax: die message ... - # - # exit script with error message - message "$THIS_PACKAGE $THIS_SCRIPT error: $*" - exit $SHELL_LIB_THROWN_ERROR -} - -internal_error () { - # exit script with error; essentially a "THIS SHOULD NEVER HAPPEN" message - message "internal error: $*" - if [ -n "$OFFICIAL_BUILD" ]; then - message "Please report a bug in the $THIS_SCRIPT script of the" \ - "$THIS_PACKAGE package, version $SOURCE_VERSION to the Debian Bug" \ - "Tracking System. Include all messages above that mention the" \ - "$THIS_PACKAGE package. Visit " \ - " on the World Wide Web for" \ - "instructions, read the file" \ - "/usr/share/doc/debian/bug-reporting.txt from the doc-debian" \ - "package, or install the reportbug package and use the command of" \ - "the same name to file a report." - fi - exit $SHELL_LIB_INTERNAL_ERROR -} - -usage_error () { - message "usage error: $*" - message "Please report a bug in the $THIS_SCRIPT script of the" \ - "$THIS_PACKAGE package, version $SOURCE_VERSION to the Debian Bug" \ - "Tracking System. Include all messages above that mention the" \ - "$THIS_PACKAGE package. Visit " \ - " on the World Wide Web for" \ - "instructions, read the file" \ - "/usr/share/doc/debian/bug-reporting.txt from the doc-debian" \ - "package, or install the reportbug package and use the command of" \ - "the same name to file a report." - exit $SHELL_LIB_USAGE_ERROR -} - -font_update () { - # run $UPDATECMDS in $FONTDIRS - - local dir cmd shortcmd x_font_dir_prefix - - x_font_dir_prefix="/usr/share/fonts/X11" - - if [ -z "$UPDATECMDS" ]; then - usage_error "font_update() called but \$UPDATECMDS not set" - fi - if [ -z "$FONTDIRS" ]; then - usage_error "font_update() called but \$FONTDIRS not set" - fi - - reject_unlikely_path_chars "$UPDATECMDS" - reject_unlikely_path_chars "$FONTDIRS" - - for dir in $FONTDIRS; do - if [ -d "$x_font_dir_prefix/$dir" ]; then - for cmd in $UPDATECMDS; do - if which "$cmd" > /dev/null 2>&1; then - shortcmd=${cmd##*/} - observe "running $shortcmd in $dir font directory" - cmd_opts= - if [ "$shortcmd" = "update-fonts-alias" ]; then - cmd_opts=--x11r7-layout - fi - if [ "$shortcmd" = "update-fonts-dir" ]; then - cmd_opts=--x11r7-layout - fi - if [ "$shortcmd" = "update-fonts-scale" ]; then - cmd_opts=--x11r7-layout - fi - $cmd $cmd_opts $dir || warn "$cmd $cmd_opts $dir" \ - "failed; font directory data may not" \ - "be up to date" - else - warn "$cmd not found; not updating corresponding $dir font" \ - "directory data" - fi - done - else - warn "$dir is not a directory; not updating font directory data" - fi - done -} - -remove_conffile_prepare () { - # syntax: remove_conffile_prepare filename official_md5sum ... - # - # Check a conffile "filename" against a list of canonical MD5 checksums. - # If the file's current MD5 checksum matches one of the "official_md5sum" - # operands provided, then prepare the conffile for removal from the system. - # We defer actual deletion until the package is configured so that we can - # roll this operation back if package installation fails. - # - # Call this function from a preinst script in the event $1 is "upgrade" or - # "install" and verify $2 to ensure the package is being upgraded from a - # version (or installed over a version removed-but-not-purged) prior to the - # one in which the conffile was obsoleted. - - local conffile current_checksum - - # validate arguments - if [ $# -lt 2 ]; then - usage_error "remove_conffile_prepare() called with wrong number of" \ - "arguments; expected at least 2, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - conffile="$1" - shift - - # does the conffile even exist? - if [ -e "$conffile" ]; then - # calculate its checksum - current_checksum=$(md5sum < "$conffile" | sed 's/[[:space:]].*//') - # compare it to each supplied checksum - while [ -n "$1" ]; do - if [ "$current_checksum" = "$1" ]; then - # we found a match; move the confffile and stop looking - observe "preparing obsolete conffile $conffile for removal" - mv "$conffile" "$conffile.$THIS_PACKAGE-tmp" - break - fi - shift - done - fi -} - -remove_conffile_lookup () { - # syntax: remove_conffile_lookup package filename - # - # Lookup the md5sum of a conffile in dpkg's database, and prepare for removal - # if it matches the actual file's md5sum. - # - # Call this function when you would call remove_conffile_prepare but only - # want to check against dpkg's status database instead of known checksums. - - local package conffile old_md5sum - - # validate arguments - if [ $# -ne 2 ]; then - usage_error "remove_conffile_lookup() called with wrong number of" \ - "arguments; expected 1, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - package="$1" - conffile="$2" - - if ! [ -e "$conffile" ]; then - return - fi - old_md5sum="$(dpkg-query -W -f='${Conffiles}' "$package" | \ - awk '{ if (match($0, "^ '"$conffile"' ")) print $2}')" - if [ -n "$old_md5sum" ]; then - remove_conffile_prepare "$conffile" "$old_md5sum" - fi -} - -remove_conffile_commit () { - # syntax: remove_conffile_commit filename - # - # Complete the removal of a conffile "filename" that has become obsolete. - # - # Call this function from a postinst script after having used - # remove_conffile_prepare() in the preinst. - - local conffile - - # validate arguments - if [ $# -ne 1 ]; then - usage_error "remove_conffile_commit() called with wrong number of" \ - "arguments; expected 1, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - conffile="$1" - - # if the temporary file created by remove_conffile_prepare() exists, remove it - if [ -e "$conffile.$THIS_PACKAGE-tmp" ]; then - observe "committing removal of obsolete conffile $conffile" - rm "$conffile.$THIS_PACKAGE-tmp" - fi -} - -remove_conffile_rollback () { - # syntax: remove_conffile_rollback filename - # - # Roll back the removal of a conffile "filename". - # - # Call this function from a postrm script in the event $1 is "abort-upgrade" - # or "abort-install" is after having used remove_conffile_prepare() in the - # preinst. - - local conffile - - # validate arguments - if [ $# -ne 1 ]; then - usage_error "remove_conffile_rollback() called with wrong number of" \ - "arguments; expected 1, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - conffile="$1" - - # if the temporary file created by remove_conffile_prepare() exists, move it - # back - if [ -e "$conffile.$THIS_PACKAGE-tmp" ]; then - observe "rolling back removal of obsolete conffile $conffile" - mv "$conffile.$THIS_PACKAGE-tmp" "$conffile" - fi -} - -replace_conffile_with_symlink_prepare () { - # syntax: replace_conffile_with_symlink_prepare oldfilename newfilename \ - # official_md5sum ... - # - # Check a conffile "oldfilename" against a list of canonical MD5 checksums. - # If the file's current MD5 checksum matches one of the "official_md5sum" - # operands provided, then prepare the conffile for removal from the system. - # We defer actual deletion until the package is configured so that we can - # roll this operation back if package installation fails. Otherwise copy it - # to newfilename and let dpkg handle it through conffiles mechanism. - # - # Call this function from a preinst script in the event $1 is "upgrade" or - # "install" and verify $2 to ensure the package is being upgraded from a - # version (or installed over a version removed-but-not-purged) prior to the - # one in which the conffile was obsoleted. - - local conffile current_checksum - - # validate arguments - if [ $# -lt 3 ]; then - usage_error "replace_conffile_with_symlink_prepare() called with wrong" \ - " number of arguments; expected at least 3, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - oldconffile="$1" - shift - newconffile="$1" - shift - - remove_conffile_prepare "$_oldconffile" "$@" - # If $oldconffile still exists, then md5sums didn't match. - # Copy it to new one. - if [ -f "$oldconffile" ]; then - cp "$oldconffile" "$newconffile" - fi - -} - -replace_conffile_with_symlink_commit () { - # syntax: replace_conffile_with_symlink_commit oldfilename - # - # Complete the removal of a conffile "oldfilename" that has been - # replaced by a symlink. - # - # Call this function from a postinst script after having used - # replace_conffile_with_symlink_prepare() in the preinst. - - local conffile - - # validate arguments - if [ $# -ne 1 ]; then - usage_error "replace_conffile_with_symlink_commit() called with wrong" \ - "number of arguments; expected 1, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - conffile="$1" - - remove_conffile_commit "$conffile" -} - -replace_conffile_with_symlink_rollback () { - # syntax: replace_conffile_with_symlink_rollback oldfilename newfilename - # - # Roll back the replacing of a conffile "oldfilename" with symlink to - # "newfilename". - # - # Call this function from a postrm script in the event $1 is "abort-upgrade" - # or "abort-install" and verify $2 to ensure the package failed to upgrade - # from a version (or install over a version removed-but-not-purged) prior - # to the one in which the conffile was obsoleted. - # You should have used replace_conffile_with_symlink_prepare() in the - # preinst. - - local conffile - - # validate arguments - if [ $# -ne 2 ]; then - usage_error "replace_conffile_with_symlink_rollback() called with wrong" \ - "number of arguments; expected 2, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - oldconffile="$1" - newconffile="$2" - - remove_conffile_rollback "$_oldconffile" - if [ -f "$newconffile" ]; then - rm "$newconffile" - fi -} - -run () { - # syntax: run command [ argument ... ] - # - # Run specified command with optional arguments and report its exit status. - # Useful for commands whose exit status may be nonzero, but still acceptable, - # or commands whose failure is not fatal to us. - # - # NOTE: Do *not* use this function with db_get or db_metaget commands; in - # those cases the return value of the debconf command *must* be checked - # before the string returned by debconf is used for anything. - - local retval - - # validate arguments - if [ $# -lt 1 ]; then - usage_error "run() called with wrong number of arguments; expected at" \ - "least 1, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - "$@" || retval=$? - - if [ ${retval:-0} -ne 0 ]; then - observe "command \"$*\" exited with status $retval" - fi -} - -make_symlink_sane () { - # syntax: make_symlink_sane symlink target - # - # Ensure that the symbolic link symlink exists, and points to target. - # - # If symlink does not exist, create it and point it at target. - # - # If symlink exists but is not a symbolic link, back it up. - # - # If symlink exists, is a symbolic link, but points to the wrong location, fix - # it. - # - # If symlink exists, is a symbolic link, and already points to target, do - # nothing. - # - # This function wouldn't be needed if ln had an -I, --idempotent option. - - # Validate arguments. - if [ $# -ne 2 ]; then - usage_error "make_symlink_sane() called with wrong number of arguments;" \ - "expected 2, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - # We could just use the positional parameters as-is, but that makes things - # harder to follow. - local symlink target - - symlink="$1" - target="$2" - - if [ -L "$symlink" ] && [ "$(readlink "$symlink")" = "$target" ]; then - observe "link from $symlink to $target already exists" - else - observe "creating symbolic link from $symlink to $target" - mkdir -p "${target%/*}" "${symlink%/*}" - ln -s -b -S ".dpkg-old" "$target" "$symlink" - fi -} - -migrate_dir_to_symlink () { - # syntax: migrate_dir_to_symlink old_location new_location - # - # Per Debian Policy section 6.5.4, "A directory will never be replaced by a - # symbolic link to a directory or vice versa; instead, the existing state - # (symlink or not) will be left alone and dpkg will follow the symlink if - # there is one." - # - # We have to do it ourselves. - # - # This function moves the contents of old_location, a directory, into - # new_location, a directory, then makes old_location a symbolic link to - # new_location. - # - # old_location need not exist, but if it does, it must be a directory (or a - # symlink to a directory). If it is not, it is backed up. If new_location - # exists already and is not a directory, it is backed up. - # - # This function should be called from a package's preinst so that other - # packages unpacked after this one --- but before this package's postinst runs - # --- are unpacked into new_location even if their payloads contain - # old_location filespecs. - - # Validate arguments. - if [ $# -ne 2 ]; then - usage_error "migrate_dir_to_symlink() called with wrong number of" - "arguments; expected 2, got $#" - exit $SHELL_LIB_USAGE_ERROR - fi - - # We could just use the positional parameters as-is, but that makes things - # harder to follow. - local new old - - old="$1" - new="$2" - - # Is old location a symlink? - if [ -L "$old" ]; then - # Does it already point to new location? - if [ "$(readlink "$old")" = "$new" ]; then - # Nothing to do; migration has already been done. - observe "migration of $old to $new already done" - return 0 - else - # Back it up. - warn "backing up symbolic link $old as $old.dpkg-old" - mv -b "$old" "$old.dpkg-old" - fi - fi - - # Does old location exist, but is not a directory? - if [ -e "$old" ] && ! [ -d "$old" ]; then - # Back it up. - warn "backing up non-directory $old as $old.dpkg-old" - mv -b "$old" "$old.dpkg-old" - fi - - observe "migrating $old to $new" - - # Is new location a symlink? - if [ -L "$new" ]; then - # Does it point the wrong way, i.e., back to where we're migrating from? - if [ "$(readlink "$new")" = "$old" ]; then - # Get rid of it. - observe "removing symbolic link $new which points to $old" - rm "$new" - else - # Back it up. - warn "backing up symbolic link $new as $new.dpkg-old" - mv -b "$new" "$new.dpkg-old" - fi - fi - - # Does new location exist, but is not a directory? - if [ -e "$new" ] && ! [ -d "$new" ]; then - warn "backing up non-directory $new as $new.dpkg-old" - mv -b "$new" "$new.dpkg-old" - fi - - # Create new directory if it does not yet exist. - if ! [ -e "$new" ]; then - observe "creating $new" - mkdir -p "$new" - fi - - # Copy files in old location to new location. Back up any filenames that - # already exist in the new location with the extension ".dpkg-old". - observe "copying files from $old to $new" - if ! (cd "$old" && cp -a -b -S ".dpkg-old" . "$new"); then - die "error(s) encountered while copying files from $old to $new" - fi - - # Remove files at old location. - observe "removing $old" - rm -r "$old" - - # Create symlink from old location to new location. - make_symlink_sane "$old" "$new" -} - -# vim:set ai et sw=2 ts=2 tw=80: - -# GOBSTOPPER: The X Strike Force shell library ends here. diff -Nru xterm-278/debian/xterm.docs xterm-297/debian/xterm.docs --- xterm-278/debian/xterm.docs 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/xterm.docs 2013-10-29 05:19:15.000000000 +0000 @@ -4,5 +4,3 @@ xterm.log.html debian/local/xterm.faq.html debian/local/xterm.faq -debian/tmp/usr/lib/xterm.termcap -debian/tmp/usr/lib/xterm.terminfo diff -Nru xterm-278/debian/xterm.install xterm-297/debian/xterm.install --- xterm-278/debian/xterm.install 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/xterm.install 2013-10-29 05:19:15.000000000 +0000 @@ -1,6 +1,7 @@ etc/X11/app-defaults/* usr/bin/* -usr/share/applications/* +usr/share/doc usr/share/man/man1/* usr/share/pixmaps usr/share/applications/* +usr/share/icons diff -Nru xterm-278/debian/xterm.postinst xterm-297/debian/xterm.postinst --- xterm-278/debian/xterm.postinst 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/debian/xterm.postinst 2013-10-29 05:19:15.000000000 +0000 @@ -0,0 +1,34 @@ +#!/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. + +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 + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=4 ts=4 tw=80: diff -Nru xterm-278/debian/xterm.postinst.in xterm-297/debian/xterm.postinst.in --- xterm-278/debian/xterm.postinst.in 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/xterm.postinst.in 1970-01-01 00:00:00.000000000 +0000 @@ -1,39 +0,0 @@ -#!/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. - -set -e - -THIS_PACKAGE=xterm -THIS_SCRIPT=postinst - -#INCLUDE_SHELL_LIB# - -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 - -#DEBHELPER# - -exit 0 - -# vim:set ai et sw=4 ts=4 tw=80: diff -Nru xterm-278/debian/xterm.prerm xterm-297/debian/xterm.prerm --- xterm-278/debian/xterm.prerm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/debian/xterm.prerm 2013-10-29 05:19:15.000000000 +0000 @@ -0,0 +1,21 @@ +#!/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. + +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: diff -Nru xterm-278/debian/xterm.prerm.in xterm-297/debian/xterm.prerm.in --- xterm-278/debian/xterm.prerm.in 2013-10-29 05:19:15.000000000 +0000 +++ xterm-297/debian/xterm.prerm.in 1970-01-01 00:00:00.000000000 +0000 @@ -1,26 +0,0 @@ -#!/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. - -set -e - -THIS_PACKAGE=xterm -THIS_SCRIPT=prerm - -#INCLUDE_SHELL_LIB# - -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: diff -Nru xterm-278/df-install.in xterm-297/df-install.in --- xterm-278/df-install.in 2011-07-07 09:41:14.000000000 +0000 +++ xterm-297/df-install.in 2012-08-27 01:07:19.000000000 +0000 @@ -1,9 +1,9 @@ #!/bin/sh -# $XTermId: df-install.in,v 1.5 2011/07/07 09:41:14 tom Exp $ +# $XTermId: df-install.in,v 1.14 2012/08/27 01:07:19 tom Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 2011 by Thomas E. Dickey +# Copyright 2011,2012 by Thomas E. Dickey # # All Rights Reserved # @@ -79,12 +79,25 @@ exit 1 fi +# The newer dfi whines about deprecation of encoding, but no release provides +# --version or equivalent. really. +if desktop-file-install --help-all >/dev/null 2>&1 +then + NO_ENCODING="#Encoding" +else + NO_ENCODING="Encoding" +fi + NEW_FILE=`basename $OLD_FILE` sed \ + -e '/^Encoding=/s%Encoding%'$NO_ENCODING'%' \ + -e '/^[^#]*Icon=/s%=.*%=xterm-color%' \ + -e '/^[^#]*Category=/s%=.*%=@DESKTOP_CATEGORY@%' \ + -e '/^[^#]*Categories=/s%=.*%=@DESKTOP_CATEGORY@%' \ -e '/^[^#]/s%xterm%'$APP_NAME'%g' \ -e '/^[^#]/s%XTerm%@APP_CLASS@%g' \ - -e '/^Category=/s%=.*%@DESKTOP_CATEGORY@%' \ $OLD_FILE >$MY_TEMP/$NEW_FILE +diff -u $OLD_FILE $MY_TEMP/$NEW_FILE cd $MY_TEMP desktop-file-install $OPTS $NEW_FILE diff -Nru xterm-278/doublechr.c xterm-297/doublechr.c --- xterm-278/doublechr.c 2011-09-11 14:59:40.000000000 +0000 +++ xterm-297/doublechr.c 2013-08-30 21:35:13.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: doublechr.c,v 1.76 2011/09/11 14:59:40 tom Exp $ */ +/* $XTermId: doublechr.c,v 1.82 2013/08/30 21:35:13 tom Exp $ */ /* - * Copyright 1997-2010,2011 by Thomas E. Dickey + * Copyright 1997-2011,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -60,13 +60,14 @@ /* * Ignore repetition. */ - if ((ld = getLineData(screen, currow)) != 0) { + if (!IsLeftRightMode(xw) + && (ld = getLineData(screen, currow)) != 0) { unsigned oldChrSet = GetLineDblCS(ld); if (oldChrSet != newChrSet) { TRACE(("repaint_line(%2d,%2d) (%s -> %s)\n", currow, screen->cur_col, - visibleChrsetName(oldChrSet), - visibleChrsetName(newChrSet))); + visibleDblChrset(oldChrSet), + visibleDblChrset(newChrSet))); HideCursor(); /* If switching from single-width, keep the cursor in the visible part @@ -83,10 +84,11 @@ * single-size and double-size font. So we paint our own. */ ClearCurBackground(xw, - CursorY(screen, currow), - LineCursorX(screen, ld, 0), - (unsigned) FontHeight(screen), - len * (unsigned) LineFontWidth(screen, ld)); + currow, + 0, + 1, + len, + (unsigned) LineFontWidth(screen, ld)); SetLineDblCS(ld, newChrSet); @@ -134,6 +136,34 @@ #endif } +/* + * Reset all lines on the screen to single-width/single-height. + */ +void +xterm_ResetDouble(XtermWidget xw) +{ +#if OPT_DEC_CHRSET + TScreen *screen = TScreenOf(xw); + Boolean changed = False; + LineData *ld; + unsigned code; + int row; + + for (row = 0; row < screen->max_row; ++row) { + if ((ld = getLineData(screen, ROW2INX(screen, row))) != 0) { + code = GetLineDblCS(ld); + if (code != CSET_SWL) { + SetLineDblCS(ld, CSET_SWL); + changed = True; + } + } + } + if (changed) { + xtermRepaint(xw); + } +#endif +} + #if OPT_DEC_CHRSET static void discard_font(XtermWidget xw, int n) diff -Nru xterm-278/error.h xterm-297/error.h --- xterm-278/error.h 2011-04-17 16:09:20.000000000 +0000 +++ xterm-297/error.h 2012-10-05 00:17:51.000000000 +0000 @@ -1,4 +1,4 @@ -/* $XTermId: error.h,v 1.24 2011/04/17 16:09:20 tom Exp $ */ +/* $XTermId: error.h,v 1.25 2012/10/05 00:17:51 tom Exp $ */ /* * Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts. @@ -75,6 +75,3 @@ #define ERROR_SCALLOC 90 /* Alloc: calloc() failed on base */ #define ERROR_SCALLOC2 91 /* Alloc: calloc() failed on rows */ #define ERROR_SAVE_PTR 102 /* ScrnPointers: malloc/realloc() failed */ - -/* util.c */ -#define ERROR_MMALLOC 121 /* my_memmove: malloc/realloc failed */ diff -Nru xterm-278/fontutils.c xterm-297/fontutils.c --- xterm-278/fontutils.c 2011-12-27 10:20:50.000000000 +0000 +++ xterm-297/fontutils.c 2013-09-09 22:36:53.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: fontutils.c,v 1.380 2011/12/27 10:20:50 tom Exp $ */ +/* $XTermId: fontutils.c,v 1.391 2013/09/09 22:36:53 tom Exp $ */ /* - * Copyright 1998-2010,2011 by Thomas E. Dickey + * Copyright 1998-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -59,22 +59,22 @@ (((cs)->rbearing|(cs)->lbearing| \ (cs)->ascent|(cs)->descent) == 0)) -#define CI_GET_CHAR_INFO_1D(fs,col,def,cs) \ +#define CI_GET_CHAR_INFO_1D(fs,col,cs) \ { \ - cs = def; \ + cs = 0; \ if (col >= fs->min_char_or_byte2 && col <= fs->max_char_or_byte2) { \ if (fs->per_char == NULL) { \ cs = &fs->min_bounds; \ } else { \ cs = &fs->per_char[(col - fs->min_char_or_byte2)]; \ - if (CI_NONEXISTCHAR(cs)) cs = def; \ } \ + if (CI_NONEXISTCHAR(cs)) cs = 0; \ } \ } -#define CI_GET_CHAR_INFO_2D(fs,row,col,def,cs) \ +#define CI_GET_CHAR_INFO_2D(fs,row,col,cs) \ { \ - cs = def; \ + cs = 0; \ if (row >= fs->min_byte1 && row <= fs->max_byte1 && \ col >= fs->min_char_or_byte2 && col <= fs->max_char_or_byte2) { \ if (fs->per_char == NULL) { \ @@ -84,13 +84,11 @@ (fs->max_char_or_byte2 - \ fs->min_char_or_byte2 + 1)) + \ (col - fs->min_char_or_byte2)]; \ - if (CI_NONEXISTCHAR(cs)) cs = def; \ } \ + if (CI_NONEXISTCHAR(cs)) cs = 0; \ } \ } -#define MAX_FONTNAME 200 - /* * A structure to hold the relevant properties from a font * we need to make a well formed font name for it. @@ -173,7 +171,7 @@ #if OPT_RENDERFONT #define MIXED(name) screen->name[fontnum].map.mixed - if (xw->misc.render_font == True) { + if (xw->work.render_font == True) { int fontnum = screen->menu_font_number; screen->allow_packing = (Boolean) (MIXED(renderFontNorm) @@ -243,9 +241,6 @@ if (IsEmpty(name)) { TRACE(("fontname missing\n")); result = False; - } else if (strlen(name) >= MAX_FONTNAME - 1) { - TRACE(("fontname too large: %s\n", name)); - result = False; } return result; } @@ -258,7 +253,7 @@ * or NULL on error. */ static FontNameProperties * -get_font_name_props(Display * dpy, XFontStruct * fs, char *result) +get_font_name_props(Display *dpy, XFontStruct * fs, char **result) { static FontNameProperties props; static char *last_name; @@ -294,7 +289,9 @@ if (result != 0) { if (!check_fontname(name)) return 0; - strcpy(result, name); + if (*result != 0) + free(*result); + *result = x_strdup(name); } /* @@ -468,7 +465,7 @@ * fonts we double the pixel-size and Y-resolution */ char * -xtermSpecialFont(TScreen * screen, unsigned atts, unsigned chrset) +xtermSpecialFont(TScreen *screen, unsigned atts, unsigned chrset) { #if OPT_TRACE static char old_spacing[80]; @@ -515,7 +512,8 @@ old_props.res_x = res_x; old_props.res_x = res_y; old_props.pixel_size = pixel_size; - old_props.spacing = strcpy(old_spacing, props->spacing); + old_props.spacing = old_spacing; + sprintf(old_spacing, "%.*s", (int) sizeof(old_spacing) - 2, props->spacing); } #endif @@ -582,15 +580,16 @@ * offset. */ static int -got_bold_font(Display * dpy, XFontStruct * fs, String requested) +got_bold_font(Display *dpy, XFontStruct * fs, String requested) { - char actual[MAX_FONTNAME]; + char *actual = 0; int got; - if (get_font_name_props(dpy, fs, actual) == 0) + if (get_font_name_props(dpy, fs, &actual) == 0) got = 0; else got = same_font_name(requested, actual); + free(actual); return got; } @@ -662,7 +661,7 @@ #define FULL_WIDTH_CHAR2 0xAC00 /* Korean script syllable 'Ka' */ static Bool -is_double_width_font_xft(Display * dpy, XftFont * font) +is_double_width_font_xft(Display *dpy, XftFont * font) { XGlyphInfo gi1, gi2; FcChar32 c1 = HALF_WIDTH_CHAR1, c2 = HALF_WIDTH_CHAR2; @@ -727,7 +726,7 @@ } static void -cache_menu_font_name(TScreen * screen, int fontnum, int which, const char *name) +cache_menu_font_name(TScreen *screen, int fontnum, int which, const char *name) { if (name != 0) { char *last = (char *) screen->menu_font_names[fontnum][which]; @@ -876,7 +875,7 @@ Pixel new_normal; Pixel new_revers; char *tmpname = NULL; - char normal[MAX_FONTNAME]; + char *normal = NULL; Boolean proportional = False; fontWarningTypes warn[fMAX]; int j; @@ -945,10 +944,10 @@ goto bad; } - strcpy(normal, myfonts.f_n); + normal = x_strdup(myfonts.f_n); if (!check_fontname(myfonts.f_b)) { warn[fBold] = fwAlways; - fp = get_font_name_props(screen->display, fnts[fNorm].fs, normal); + fp = get_font_name_props(screen->display, fnts[fNorm].fs, &normal); if (fp != 0) { myfonts.f_b = bold_font_name(fp, fp->average_width); if (!xtermOpenFont(xw, myfonts.f_b, &fnts[fBold], fwAlways, False)) { @@ -984,12 +983,12 @@ */ if_OPT_WIDE_CHARS(screen, { Boolean derived; - char bold[MAX_FONTNAME]; + char *bold = NULL; if (check_fontname(myfonts.f_w)) { cache_menu_font_name(screen, fontnum, fWide, myfonts.f_w); } else if (screen->utf8_fonts && !is_double_width_font(fnts[fNorm].fs)) { - fp = get_font_name_props(screen->display, fnts[fNorm].fs, normal); + fp = get_font_name_props(screen->display, fnts[fNorm].fs, &normal); if (fp != 0) { myfonts.f_w = wide_font_name(fp); warn[fWide] = fwAlways; @@ -1007,7 +1006,7 @@ derived = False; if (!check_fontname(myfonts.f_wb)) { - fp = get_font_name_props(screen->display, fnts[fBold].fs, bold); + fp = get_font_name_props(screen->display, fnts[fBold].fs, &bold); if (fp != 0) { myfonts.f_wb = widebold_font_name(fp); warn[fWBold] = fwAlways; @@ -1059,6 +1058,8 @@ TRACE(("...cannot load wide bold font, use wide %s\n", NonNull(myfonts.f_w))); } + free(bold); + if (EmptyFont(fnts[fWBold].fs)) goto bad; /* can't use a 0-sized font */ }); @@ -1201,6 +1202,11 @@ { unsigned ch; + TRACE(("normal font is %scomplete\n", + FontIsIncomplete(&fnts[fNorm]) ? "in" : "")); + TRACE(("bold font is %scomplete\n", + FontIsIncomplete(&fnts[fBold]) ? "in" : "")); + for (ch = 1; ch < 32; ch++) { unsigned n = ch; #if OPT_WIDE_CHARS @@ -1251,12 +1257,16 @@ screen->menu_font_sizes[fontnum] = FontSize(fnts[fNorm].fs); #endif } + if (normal) + free(normal); set_cursor_gcs(xw); xtermUpdateFontInfo(xw, doresize); TRACE(("Success Cgs - xtermLoadFont\n")); return 1; bad: + if (normal) + free(normal); if (tmpname) free(tmpname); @@ -1525,7 +1535,7 @@ void HandleLoadVTFonts(Widget w, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *param_count GCC_UNUSED) { static char empty[] = ""; /* appease strict compilers */ @@ -1537,9 +1547,9 @@ char name_buf[80]; char class_buf[80]; String name = (String) ((*param_count > 0) ? params[0] : empty); - char *myName = (char *) MyStackAlloc(strlen(name), name_buf); + char *myName = (char *) MyStackAlloc(strlen(name) + 1, name_buf); String convert = (String) ((*param_count > 1) ? params[1] : myName); - char *myClass = (char *) MyStackAlloc(strlen(convert), class_buf); + char *myClass = (char *) MyStackAlloc(strlen(convert) + 1, class_buf); int n; TRACE(("HandleLoadVTFonts(%d)\n", *param_count)); @@ -1575,18 +1585,19 @@ * Set the limits for the box that outlines the cursor. */ void -xtermSetCursorBox(TScreen * screen) +xtermSetCursorBox(TScreen *screen) { static XPoint VTbox[NBOX]; XPoint *vp; int fw = FontWidth(screen) - 1; int fh = FontHeight(screen) - 1; - int hh = screen->cursor_underline ? 1 : fh; + int ww = isCursorBar(screen) ? 1 : fw; + int hh = isCursorUnderline(screen) ? 1 : fh; vp = &VTbox[1]; - (vp++)->x = (short) fw; + (vp++)->x = (short) ww; (vp++)->y = (short) hh; - (vp++)->x = (short) -fw; + (vp++)->x = (short) -ww; vp->y = (short) -hh; screen->box = VTbox; @@ -1789,7 +1800,7 @@ * rule. */ static void -setRenderFontsize(TScreen * screen, VTwin * win, XftFont * font, const char *tag) +setRenderFontsize(TScreen *screen, VTwin * win, XftFont * font, const char *tag) { if (font != 0) { int width, height, ascent, descent; @@ -1846,7 +1857,7 @@ #if OPT_RENDERFONT void -xtermCloseXft(TScreen * screen, XTermXftFonts * pub) +xtermCloseXft(TScreen *screen, XTermXftFonts * pub) { if (pub->font != 0) { XftFontClose(screen->display, pub->font); @@ -1856,7 +1867,7 @@ /* * Get the faceName/faceDoublesize resource setting. Strip off "xft:", which - * is not recognized by XftParseName(). + * is not recognized by XftNameParse(). */ String getFaceName(XtermWidget xw, Bool wideName GCC_UNUSED) @@ -2073,7 +2084,7 @@ } if (norm == 0) { TRACE(("...no TrueType font found for number %d, disable menu entry\n", fontnum)); - xw->misc.render_font = False; + xw->work.render_font = False; update_font_renderfont(); /* now we will fall through into the bitmap fonts */ } else { @@ -2136,7 +2147,7 @@ /* save this information as a side-effect for double-sized characters */ void -xtermSaveFontInfo(TScreen * screen, XFontStruct * font) +xtermSaveFontInfo(TScreen *screen, XFontStruct * font) { screen->fnt_wide = (Dimension) (font->max_bounds.width); screen->fnt_high = (Dimension) (font->ascent + font->descent); @@ -2187,32 +2198,27 @@ { Bool result = False; XFontStruct *fs = font->fs; - static XCharStruct dft, *tmp = &dft, *pc = 0; + XCharStruct *pc = 0; if (fs->max_byte1 == 0) { #if OPT_WIDE_CHARS - if (ch > 255) { - TRACE(("xtermMissingChar %#04x (row)\n", ch)); - return True; - } + if (ch < 256) #endif - CI_GET_CHAR_INFO_1D(fs, E2A(ch), tmp, pc); + { + CI_GET_CHAR_INFO_1D(fs, E2A(ch), pc); + } } #if OPT_WIDE_CHARS else { - CI_GET_CHAR_INFO_2D(fs, HI_BYTE(ch), LO_BYTE(ch), tmp, pc); + CI_GET_CHAR_INFO_2D(fs, HI_BYTE(ch), LO_BYTE(ch), pc); } -#else - - if (!pc) - return False; /* Urgh! */ #endif - if (CI_NONEXISTCHAR(pc)) { + if (pc == 0 || CI_NONEXISTCHAR(pc)) { TRACE(("xtermMissingChar %#04x (!exists)\n", ch)); result = True; } - if (ch < 256) { + if (ch < KNOWN_MISSING) { font->known_missing[ch] = (Char) (result ? 2 : 1); } return result; @@ -2482,7 +2488,7 @@ gc2 = getCgsGC(xw, cgsWin, cgsId); if (!(flags & NOBACKGROUND)) { - XFillRectangle(screen->display, VWindow(screen), gc2, x, y, + XFillRectangle(screen->display, VDrawable(screen), gc2, x, y, font_width, font_height); } @@ -2531,7 +2537,7 @@ } XFillPolygon(screen->display, - VWindow(screen), gc2, + VDrawable(screen), gc2, points, npoints, Convex, CoordModeOrigin); } else if (ch == 7) { /* degrees */ @@ -2544,7 +2550,7 @@ width = (unsigned) SCALED_X(width); XDrawArc(screen->display, - VWindow(screen), gc2, + VDrawable(screen), gc2, x + x_coord, y + y_coord, width, width, 0, 360 * 64); @@ -2558,7 +2564,7 @@ width = (unsigned) SCALED_X(width); XDrawArc(screen->display, - VWindow(screen), gc2, + VDrawable(screen), gc2, x + x_coord, y + y_coord, width, width, 0, 360 * 64); @@ -2574,7 +2580,7 @@ SCALE_X(coord[2]); SCALE_Y(coord[3]); XDrawLine(screen->display, - VWindow(screen), gc2, + VDrawable(screen), gc2, x + coord[0], y + coord[1], x + coord[2], y + coord[3]); n = 0; @@ -2582,7 +2588,7 @@ } } else if (screen->force_all_chars) { /* bounding rectangle, for debugging */ - XDrawRectangle(screen->display, VWindow(screen), gc2, x, y, + XDrawRectangle(screen->display, VDrawable(screen), gc2, x, y, font_width - 1, font_height - 1); } @@ -2957,7 +2963,7 @@ void HandleLargerFont(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *param_count GCC_UNUSED) { XtermWidget xw; @@ -2982,7 +2988,7 @@ void HandleSmallerFont(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *param_count GCC_UNUSED) { XtermWidget xw; @@ -3052,7 +3058,7 @@ void HandleSetFont(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params, + String *params, Cardinal *param_count) { XtermWidget xw; diff -Nru xterm-278/fontutils.h xterm-297/fontutils.h --- xterm-278/fontutils.h 2011-09-11 14:59:37.000000000 +0000 +++ xterm-297/fontutils.h 2013-09-09 22:50:26.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: fontutils.h,v 1.84 2011/09/11 14:59:37 tom Exp $ */ +/* $XTermId: fontutils.h,v 1.87 2013/09/09 22:50:26 tom Exp $ */ /* - * Copyright 1998-2010,2011 by Thomas E. Dickey + * Copyright 1998-2011,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -68,16 +68,22 @@ (xtermIsDecGraphic(ch) \ && (screen)->force_box_chars) + /* + * Keep track of (some) characters to make the check for missing + * characters faster. If the character is known to be missing, + * the cache value is '2'. If we have checked the character, the + * cached value is '1'. + */ #if OPT_WIDE_CHARS -#define CharKnownMissing(font, ch) \ - (((ch) < 256) && ((font)->known_missing[(Char)(ch)] > 1)) +#define CheckedKnownMissing(font, ch) \ + (((ch) < KNOWN_MISSING) && ((font)->known_missing[(Char)(ch)] > 0)) #else -#define CharKnownMissing(font, ch) \ - ((font)->known_missing[(Char)(ch)] > 1) +#define CheckedKnownMissing(font, ch) \ + ((font)->known_missing[(Char)(ch)] > 0) #endif #define IsXtermMissingChar(screen, ch, font) \ - (CharKnownMissing(font, ch) \ + (CheckedKnownMissing(font, ch) \ ? ((font)->known_missing[(Char)(ch)] > 1) \ : ((FontIsIncomplete(font) && xtermMissingChar(ch, font)) \ || ForceBoxChars(screen, ch))) diff -Nru xterm-278/graphics.c xterm-297/graphics.c --- xterm-278/graphics.c 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/graphics.c 2013-09-10 18:38:12.000000000 +0000 @@ -0,0 +1,1475 @@ +/* $XTermId: graphics.c,v 1.14 2013/09/10 18:38:12 tom Exp $ */ + +/* + * Copyright 2013 by Ross Combs + * + * 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. + */ + +#include + +#include +#include +#include +#include + +#include +#include +#include + +#include +#include + +#undef DUMP_SIXEL_BITMAP +#undef DEBUG_REFRESH + +/* TODO: + * ReGIS: + * - everything + * sixel: + * - erase graphic when erasing screen + * - maintain ordered list/array instead of qsort() + * - erase text under graphics if bg not transparent + * - erase scrolled portions of all graphics on alt buffer + * - delete graphic if scrolled past end of scrollback + * - delete graphic if all pixels are transparent/erased + * - dynamic memory allocation, add configurable limits + * - auto convert color graphics in VT330 mode + * - investigate second graphic framebuffer for ReGIS -- does this apply to text and sixel graphics? + * - fix problem where new_row < 0 during sixel parsing (see FIXME) + * VT55/VT105 waveform graphics + * - everything + * escape sequences + * - way to query font size without "window ops" (or make "window ops" permissions more fine grained) + * - way to query and/or set the maximum number of color registers + */ + +/* font sizes: + * VT510: + * 80 Columns 132 Columns Maximum Number of Lines + * 10 x 16 6 x 16 26 lines + keyboard indicator line + * 10 x 10 6 x 10 42 lines + keyboard indicator line + * 10 x 8 6 x 8 53 lines + keyboard indicator line + * 10 x 13 6 x 13 26 lines + keyboard indicator line +*/ + +/***====================================================================***/ +/* + * Parse numeric parameters which have the operator as a prefix rather than a + * suffix as in ANSI format. + * + * # 0 + * #1 1 + * #1; 1 + * "1;2;640;480 4 + * #1;2;0;0;0 5 + */ +static void +parse_prefixedtype_params(ANSI *params, const char **string) +{ + const char *cp = *string; + ParmType nparam = 0; + int last_empty = 1; + + memset(params, 0, sizeof(*params)); + params->a_final = CharOf(*cp); + if (*cp != '\0') + cp++; + + while (*cp != '\0') { + Char ch = CharOf(*cp); + + if (isdigit(ch)) { + last_empty = 0; + if (nparam < NPARAM) { + params->a_param[nparam] = + (ParmType) ((params->a_param[nparam] * 10) + + (ch - '0')); + } + } else if (ch == ';') { + last_empty = 1; + nparam++; + } else if (ch == ' ' || ch == '\r' || ch == '\n') { + /* EMPTY */ ; + } else { + break; + } + cp++; + } + + *string = cp; + if (!last_empty) + nparam++; + if (nparam > NPARAM) + params->a_nparam = NPARAM; + else + params->a_nparam = nparam; +} + +typedef struct { + Pixel pix; + short r, g, b; + short allocated; +} ColorRegister; + +#define MAX_COLOR_REGISTERS 256U +#define COLOR_HOLE ((unsigned short)MAX_COLOR_REGISTERS) +#define BUFFER_WIDTH 1000 +#define BUFFER_HEIGHT 800 +typedef struct { + RegisterNum pixels[BUFFER_HEIGHT * BUFFER_WIDTH]; + ColorRegister private_color_registers[MAX_COLOR_REGISTERS]; + ColorRegister *color_registers; + char color_registers_used[MAX_COLOR_REGISTERS]; + XtermWidget xw; + int max_width; /* largest image which can be stored */ + int max_height; /* largest image which can be stored */ + RegisterNum current_register; + int valid_registers; /* for wrap-around behavior */ + int device_background; /* 0: set to color 0, 1: unchanged */ + int background; /* current background color */ + int aspect_vertical; + int aspect_horizontal; + int declared_width; /* size as reported by the application */ + int declared_height; /* size as reported by the application */ + int actual_width; /* size measured during parsing */ + int actual_height; /* size measured during parsing */ + int private_colors; /* if not using the shared color registers */ + int charrow; /* upper left starting point in characters */ + int charcol; /* upper left starting point in characters */ + int pixw; /* width of graphic pixels in screen pixels */ + int pixh; /* height of graphic pixels in screen pixels */ + int row; /* context used during parsing */ + int col; /* context used during parsing */ + int bufferid; /* which screen buffer the graphic is associated with */ + unsigned int id; /* sequential id used for preserving layering */ + int valid; /* if the graphic has been initialized */ + int dirty; /* if the graphic needs to be redrawn */ +} SixelGraphic; + +static unsigned int next_sixel_id = 0U; + +static ColorRegister shared_color_registers[MAX_COLOR_REGISTERS]; + +#define MAX_SIXEL_GRAPHICS 16U +static SixelGraphic sixel_graphics[MAX_SIXEL_GRAPHICS]; + +/* sixel scrolling: + * VK100/GIGI ? (did it even support Sixel?) + * VT125 unsupported + * VT240 unsupported + * VT241 unsupported + * VT330 mode setting + * VT340 mode setting + * dxterm ? + */ + +static void +init_sixel_background(SixelGraphic *graphic) +{ + RegisterNum bgcolor = (RegisterNum) graphic->background; + int r, c; + + TRACE(("initializing sixel background to size=%dx%d bgcolor=%hu\n", + graphic->declared_width, + graphic->declared_height, + bgcolor)); + for (r = 0; r < graphic->max_height; r++) { + for (c = 0; c < graphic->max_width; c++) { + if (c < graphic->declared_width && r < graphic->declared_height) { + graphic->pixels[r * graphic->max_width + c] = bgcolor; + } else { + graphic->pixels[r * graphic->max_width + c] = COLOR_HOLE; + } + } + } +} + +static void +set_sixel(SixelGraphic *graphic, int sixel) +{ + RegisterNum color; + int pix; + + color = graphic->current_register; + TRACE(("drawing sixel at pos=%d,%d color=%hu (hole=%d, [%d,%d,%d])\n", + graphic->col, + graphic->row, + color, + color == COLOR_HOLE, + ((color != COLOR_HOLE) + ? (unsigned int) graphic->color_registers[color].r : 0U), + ((color != COLOR_HOLE) + ? (unsigned int) graphic->color_registers[color].g : 0U), + ((color != COLOR_HOLE) + ? (unsigned int) graphic->color_registers[color].b : 0U))); + for (pix = 0; pix < 6; pix++) { + if (graphic->col < graphic->max_width && + graphic->row + pix < graphic->max_height) { + if (sixel & (1 << pix)) { + if (graphic->col + 1 > graphic->actual_width) { + graphic->actual_width = graphic->col + 1; + } + if (graphic->row + pix + 1 > graphic->actual_height) { + graphic->actual_height = graphic->row + pix + 1; + } + graphic->pixels[ + (((graphic->row + pix) * graphic->max_width) + + graphic->col) + ] = color; + } + } else { + TRACE(("sixel pixel %d out of bounds\n", pix)); + } + } +} + +static void +set_sixel_color_register(ColorRegister *color_registers, + RegisterNum color, + int r, + int g, + int b) +{ + ColorRegister *reg = &color_registers[color]; + reg->r = (short) r; + reg->g = (short) g; + reg->b = (short) b; + reg->allocated = 0; +} + +static void +init_color_registers(ColorRegister *color_registers, int terminal_id) +{ + TRACE(("initializing colors for %d\n", terminal_id)); + { + unsigned int i; + + for (i = 0U; i < MAX_COLOR_REGISTERS; i++) { + set_sixel_color_register(color_registers, (RegisterNum) i, 0, 0, 0); + } + } + + /* + * default color registers: + * (mono) (color) + * VK100/GIGI (fixed) + * VT125: + * 0: 0% 0% + * 1: 33% blue + * 2: 66% red + * 3: 100% green + * VT240: + * 0: 0% 0% + * 1: 33% blue + * 2: 66% red + * 3: 100% green + * VT241: + * 0: 0% 0% + * 1: 33% blue + * 2: 66% red + * 3: 100% green + * VT330: + * 0: 0% 0% (bg for light on dark mode) + * 1: 33% blue (red?) + * 2: 66% red (green?) + * 3: 100% green (yellow?) (fg for light on dark mode) + * VT340: + * 0: 0% 0% (bg for light on dark mode) + * 1: 14% blue + * 2: 29% red + * 3: 43% green + * 4: 57% magenta + * 5: 71% cyan + * 6: 86% yellow + * 7: 100% 50% (fg for light on dark mode) + * 8: 0% 25% + * 9: 14% gray-blue + * 10: 29% gray-red + * 11: 43% gray-green + * 12: 57% gray-magenta + * 13: 71% gray-cyan + * 14: 86% gray-yellow + * 15: 100% 75% + * dxterm: + * ? + */ + switch (terminal_id) { + case 125: + case 241: + set_sixel_color_register(color_registers, 0, 0, 0, 0); + set_sixel_color_register(color_registers, 1, 0, 0, 100); + set_sixel_color_register(color_registers, 2, 0, 100, 0); + set_sixel_color_register(color_registers, 3, 100, 0, 0); + break; + case 240: + case 330: + set_sixel_color_register(color_registers, 0, 0, 0, 0); + set_sixel_color_register(color_registers, 1, 33, 33, 33); + set_sixel_color_register(color_registers, 2, 66, 66, 66); + set_sixel_color_register(color_registers, 3, 100, 100, 100); + break; + case 340: + default: + set_sixel_color_register(color_registers, 0, 0, 0, 0); + set_sixel_color_register(color_registers, 1, 20, 20, 80); + set_sixel_color_register(color_registers, 2, 80, 13, 13); + set_sixel_color_register(color_registers, 3, 20, 80, 20); + set_sixel_color_register(color_registers, 4, 80, 20, 80); + set_sixel_color_register(color_registers, 5, 20, 80, 80); + set_sixel_color_register(color_registers, 6, 80, 80, 20); + set_sixel_color_register(color_registers, 7, 53, 53, 53); + set_sixel_color_register(color_registers, 8, 26, 26, 26); + set_sixel_color_register(color_registers, 9, 33, 33, 60); + set_sixel_color_register(color_registers, 10, 60, 26, 26); + set_sixel_color_register(color_registers, 11, 33, 60, 33); + set_sixel_color_register(color_registers, 12, 60, 33, 60); + set_sixel_color_register(color_registers, 13, 33, 60, 60); + set_sixel_color_register(color_registers, 14, 60, 60, 33); + set_sixel_color_register(color_registers, 15, 80, 80, 80); + break; + } +} + +static void +init_sixel_graphic(SixelGraphic *graphic, int terminal_id, int private_colors) +{ + TRACE(("initializing sixel graphic\n")); + + graphic->dirty = 1; + memset(graphic->pixels, 0, sizeof(graphic->pixels)); + memset(graphic->color_registers_used, 0, sizeof(graphic->color_registers_used)); + + /* + * dimensions (REGIS logical, physical): + * VK100/GIGI 768x4?? 768x2?? + * VT125 768x460 768x230(+10status) (1:2 aspect ratio, REGIS halves vertical addresses through "odd y emulation") + * VT240 800x460 800x230(+10status) (1:2 aspect ratio, REGIS halves vertical addresses through "odd y emulation") + * VT241 800x460 800x230(+10status) (1:2 aspect ratio, REGIS halves vertical addresses through "odd y emulation") + * VT330 800x480 800x480(+?status) + * VT340 800x480 800x480(+?status) + * dxterm ?x? variable? + */ + graphic->max_width = BUFFER_WIDTH; + graphic->max_height = BUFFER_HEIGHT; + + /* default isn't white on the VT240, but not sure what it is */ + graphic->current_register = 3; /* FIXME: using green, but not sure what it should be */ + + /* + * When an application selects the monochrome map: the terminal sets the + * 16 entries of the color map to the default monochrome gray level. + * Therefore, the original colors are lost when changing from the color map + * to the monochrome map. + * + * If you change the color value (green, red, blue) using the Color Set-Up + * screen or a ReGIS command, the VT340 sets the gray scale by using the + * formula (2G + R)/3. + * + * When an application selects the color map: the terminal sets the 16 + * entries of the color map to the default (color) color map. + */ + + /* + * color capabilities: + * VK100/GIGI 1 plane (12x1 pixel attribute blocks) colorspace is 8 fixed colors (black, white, red, green, blue, cyan, yellow, magenta) + * VT125 2 planes (4 registers) colorspace is (64?) (color), ? (grayscale) + * VT240 2 planes (4 registers) colorspace is ? shades (grayscale) + * VT241 2 planes (4 registers) colorspace is ? (color), ? shades (grayscale) + * VT330 2 planes (4 registers) colorspace is 4 shades (grayscale) + * VT340 4 planes (16 registers) colorspace is r16g16b16 (color), 16 shades (grayscale) + * dxterm ? + */ + switch (terminal_id) { + case 125: + graphic->valid_registers = 4; + break; + case 240: + graphic->valid_registers = 4; + break; + case 241: + graphic->valid_registers = 4; + break; + case 330: + graphic->valid_registers = 4; + break; + case 340: + graphic->valid_registers = 16; + break; + default: + graphic->valid_registers = 64; /* unknown graphics model -- might as well be generous */ + break; + } + + /* + * text and graphics interactions: + * VK100/GIGI text writes on top of graphics buffer, color attribute shared with text + * VT240,VT241,VT330,VT340 text writes on top of graphics buffer + * VT125 graphics buffer overlaid on top of text in B&W display, text not present in color display + */ + + /* FIXME: is this always zero? what about in light background mode? */ + graphic->device_background = 0; /* default background color register */ + + /* pixel sizes seem to have differed by model and options */ + /* VT240 and VT340 defaulted to 2:1 ratio */ + graphic->aspect_vertical = 2; + graphic->aspect_horizontal = 1; + + graphic->declared_width = 0; + graphic->declared_height = 0; + + graphic->actual_width = 0; + graphic->actual_height = 0; + + graphic->private_colors = private_colors; + if (graphic->private_colors) { + TRACE(("sixel using private color registers\n")); + init_color_registers(graphic->private_color_registers, terminal_id); + graphic->color_registers = graphic->private_color_registers; + } else { + TRACE(("sixel using shared color registers\n")); + graphic->color_registers = shared_color_registers; + } + + graphic->charrow = 0; + graphic->charcol = 0; + + graphic->row = 0; + graphic->col = 0; + + graphic->valid = 0; +} + +static SixelGraphic * +get_sixel_graphic(XtermWidget xw) +{ + TScreen const *screen = TScreenOf(xw); + int bufferid = screen->whichBuf; + int terminal_id = screen->terminal_id; + int private_colors = screen->privatecolorregisters; + SixelGraphic *graphic; + unsigned int ii; + + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = &sixel_graphics[ii]; + if (!graphic->valid) + break; + } + + if (ii >= MAX_SIXEL_GRAPHICS) { + int min_charrow = 0; + SixelGraphic *min_graphic = NULL; + + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = &sixel_graphics[ii]; + if (!min_graphic || graphic->charrow < min_charrow) { + min_charrow = graphic->charrow; + min_graphic = graphic; + } + } + graphic = min_graphic; + } + + graphic->xw = xw; + graphic->bufferid = bufferid; + graphic->id = next_sixel_id++; + init_sixel_graphic(graphic, terminal_id, private_colors); + return graphic; +} + +static void +dump_sixel(SixelGraphic const *graphic) +{ +#ifdef DUMP_SIXEL_BITMAP + int r, c; + RegisterNum color; + ColorRegister const *reg; +#endif + + (void) graphic; + + TRACE(("sixel stats: charrow=%d charcol=%d actual_width=%d actual_height=%d pixw=%d pixh=%d\n", + graphic->charrow, + graphic->charcol, + graphic->actual_width, + graphic->actual_height, + graphic->pixw, + graphic->pixh)); + +#ifdef DUMP_SIXEL_BITMAP + TRACE(("sixel dump:\n")); + for (r = 0; r < graphic->max_height; r++) { + for (c = 0; c < graphic->max_width; c++) { + color = graphic->pixels[r * graphic->max_width + c]; + if (color == COLOR_HOLE) { + TRACE(("?")); + } else { + reg = &graphic->color_registers[color]; + if (reg->r + reg->g + reg->b > 200) { + TRACE(("#")); + } else if (reg->r + reg->g + reg->b > 150) { + TRACE(("%%")); + } else if (reg->r + reg->g + reg->b > 100) { + TRACE((":")); + } else if (reg->r + reg->g + reg->b > 80) { + TRACE((".")); + } else { + TRACE((" ")); + } + } + } + TRACE(("\n")); + } +#endif + TRACE(("\n")); +} + +static void +set_shared_color_register(RegisterNum color, int r, int g, int b) +{ + SixelGraphic *graphic; + unsigned int ii; + + assert(color < MAX_COLOR_REGISTERS); + + set_sixel_color_register(shared_color_registers, color, r, g, b); + + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = &sixel_graphics[ii]; + if (graphic->private_colors) + continue; + + if (graphic->color_registers_used[ii]) { + graphic->dirty = 1; + } + } +} + +#define ScaleForXColor(s) (unsigned short) ((long)(s) * 65535 / 100) + +static Pixel +sixel_register_to_xpixel(ColorRegister *reg, XtermWidget xw) +{ + if (!reg->allocated) { + XColor def; + + def.red = ScaleForXColor(reg->r); + def.green = ScaleForXColor(reg->g); + def.blue = ScaleForXColor(reg->b); + def.flags = DoRed | DoGreen | DoBlue; + if (!allocateBestRGB(xw, &def)) { + return 0UL; + } + reg->pix = def.pixel; + reg->allocated = 1; + } + + /* FIXME: with so many possible colors we need to determine + * when to free them to be nice to PseudoColor displays + */ + return reg->pix; +} + +static void +refresh_sixel_graphic(TScreen const *screen, + SixelGraphic *graphic, + int xbase, + int ybase, + int x, + int y, + int w, + int h) +{ + Display *display = screen->display; + Window vwindow = WhichVWin(screen)->window; + GC graphics_gc; + int r, c; + int wx, wy; + int pw, ph; + RegisterNum color; + RegisterNum old_fg; + XGCValues xgcv; + XtGCMask mask; + int holes, total; + + TRACE(("refreshing sixel graphic from %d,%d %dx%d (valid=%d, bg=%dx%d size=%dx%d, max=%dx%d) at base=%d,%d\n", + x, y, w, h, + graphic->valid, + graphic->declared_width, + graphic->declared_height, + graphic->actual_width, + graphic->actual_height, + graphic->max_width, + graphic->max_height, + xbase, ybase)); + + memset(&xgcv, 0, sizeof(xgcv)); + xgcv.foreground = 0UL; + xgcv.graphics_exposures = False; + mask = GCForeground | GCGraphicsExposures; + graphics_gc = XCreateGC(display, vwindow, mask, &xgcv); + + pw = graphic->pixw; + ph = graphic->pixh; + + TRACE(("refreshed graphic covers 0,0 to %d,%d\n", + (graphic->actual_width - 1) * pw + pw - 1, + (graphic->actual_height - 1) * ph + ph - 1)); + TRACE(("refreshed area covers %d,%d to %d,%d\n", + x, y, + x + w - 1, + y + h - 1)); + + old_fg = COLOR_HOLE; + holes = total = 0; + for (r = 0; r < graphic->actual_height; r++) + for (c = 0; c < graphic->actual_width; c++) { + if (r * ph + ph - 1 < y || + r * ph > y + h - 1 || + c * pw + pw - 1 < x || + c * pw > x + w - 1) + continue; + + wy = ybase + r * ph; + wx = xbase + c * pw; + + total++; + color = graphic->pixels[r * graphic->max_width + c]; + if (color == COLOR_HOLE) { + holes++; + continue; + } + + if (color != old_fg) { + xgcv.foreground = + sixel_register_to_xpixel(&graphic->color_registers[color], + graphic->xw); + XChangeGC(display, graphics_gc, mask, &xgcv); + old_fg = color; + } + + XFillRectangle(display, vwindow, graphics_gc, + wx, wy, (unsigned) pw, (unsigned) ph); + } + +#ifdef DEBUG_REFRESH + { + XColor def; + + def.red = (short) (1.0 * 65535.0); + def.green = (short) (0.1 * 65535.0); + def.blue = (short) (1.0 * 65535.0); + def.flags = DoRed | DoGreen | DoBlue; + if (allocateBestRGB(graphic->xw, &def)) { + xgcv.foreground = def.pixel; + XChangeGC(display, graphics_gc, mask, &xgcv); + } + XFillRectangle(display, vwindow, graphics_gc, + xbase + 0, + ybase + 0, + (unsigned) pw, (unsigned) ph); + XFillRectangle(display, vwindow, graphics_gc, + xbase + (graphic->actual_width - 1) * pw, + ybase + (graphic->actual_height - 1) * ph, + (unsigned) pw, (unsigned) ph); + + def.red = (unsigned short) ((1.0 - 0.1 * (rand() / (double) + RAND_MAX) * 65535.0)); + def.green = (unsigned short) ((0.7 + 0.2 * (rand() / (double) + RAND_MAX)) * 65535.0); + def.blue = (unsigned short) ((0.1 + 0.1 * (rand() / (double) + RAND_MAX)) * 65535.0); + def.flags = DoRed | DoGreen | DoBlue; + if (allocateBestRGB(graphic->xw, &def)) { + xgcv.foreground = def.pixel; + XChangeGC(display, graphics_gc, mask, &xgcv); + } + XDrawLine(display, vwindow, graphics_gc, + xbase + x + 0, ybase + y + 0, + xbase + x + w - 1, ybase + y + 0); + XDrawLine(display, vwindow, graphics_gc, + xbase + x + w - 1, ybase + y + 0, + xbase + x + 0, ybase + y + h - 1); + XDrawLine(display, vwindow, graphics_gc, + xbase + x + 0, ybase + y + h - 1, + xbase + x + w - 1, ybase + y + h - 1); + XDrawLine(display, vwindow, graphics_gc, + xbase + x + w - 1, ybase + y + h - 1, + xbase + x + 0, ybase + y + 0); + } +#endif + XFlush(display); + TRACE(("done refreshing sixel graphic: %d of %d refreshed pixels were holes\n", + holes, total)); + + XFreeGC(display, graphics_gc); +} + +/* + * Primary color hues: + * blue: 0 degrees + * red: 120 degrees + * green: 240 degrees + */ +static void +hls2rgb(int h, int l, int s, short *r, short *g, short *b) +{ + double hs = (h + 240) % 360; + double hv = hs / 360.0; + double lv = l / 100.0; + double sv = s / 100.0; + double c, x, m; + double r1, g1, b1; + int hpi; + + if (s == 0) { + *r = *g = *b = (short) l; + return; + } + + c = (1.0 - fabs(2.0 * lv - 1.0)) * sv; + hpi = (int) (hv * 6.0); + x = (hpi & 1) ? c : 0.0; + m = lv - 0.5 * c; + + switch (hpi) { + case 0: + r1 = c; + g1 = x; + b1 = 0.0; + break; + case 1: + r1 = x; + g1 = c; + b1 = 0.0; + break; + case 2: + r1 = 0.0; + g1 = c; + b1 = x; + break; + case 3: + r1 = 0.0; + g1 = x; + b1 = c; + break; + case 4: + r1 = x; + g1 = 0.0; + b1 = c; + break; + case 5: + r1 = c; + g1 = 0.0; + b1 = x; + break; + default: + printf("BAD\n"); + *r = (short) 100; + *g = (short) 100; + *b = (short) 100; + return; + } + + *r = (short) ((r1 + m) * 100.0 + 0.5); + *g = (short) ((g1 + m) * 100.0 + 0.5); + *b = (short) ((b1 + m) * 100.0 + 0.5); + + if (*r < 0) + *r = 0; + else if (*r > 100) + *r = 100; + if (*g < 0) + *g = 0; + else if (*g > 100) + *g = 100; + if (*b < 0) + *b = 0; + else if (*b > 100) + *b = 100; +} + +static void +update_sixel_aspect(SixelGraphic *graphic) +{ + /* We want to keep the ratio accurate but would like every pixel to have + * the same size so keep these as whole numbers. + */ + /* FIXME: DEC terminals had pixels about twice as tall as they were wide, + * and it seems the VT125 and VT24x only used data from odd graphic rows. + * This means it basically cancels out if we ignore both, except that + * the even rows of pixels may not be written by the application such that + * they are suitable for display. In practice this doesn't seem to be + * an issue but I have very few test files/programs. + */ + if (graphic->aspect_vertical < graphic->aspect_horizontal) { + graphic->pixw = 1; + graphic->pixh = ((graphic->aspect_vertical + + graphic->aspect_horizontal - 1) + / graphic->aspect_horizontal); + } else { + graphic->pixw = ((graphic->aspect_horizontal + + graphic->aspect_vertical - 1) + / graphic->aspect_vertical); + graphic->pixh = 1; + } + TRACE(("sixel aspect ratio: an=%d ad=%d -> pixw=%d pixh=%d\n", + graphic->aspect_vertical, + graphic->aspect_horizontal, + graphic->pixw, + graphic->pixh)); +} + +/* + * Interpret sixel graphics sequences. + * + * Resources: + * http://en.wikipedia.org/wiki/Sixel + * http://vt100.net/docs/vt3xx-gp/chapter14.html + * ftp://ftp.cs.utk.edu/pub/shuford/terminal/sixel_graphics_news.txt + * ftp://ftp.cs.utk.edu/pub/shuford/terminal/all_about_sixels.txt + */ +extern void +parse_sixel(XtermWidget xw, ANSI *params, char const *string) +{ + TScreen *screen = TScreenOf(xw); + SixelGraphic *graphic; + Char ch; + + graphic = get_sixel_graphic(xw); + + { + int Pmacro = params->a_param[0]; + int Pbgmode = params->a_param[1]; + int Phgrid = params->a_param[2]; + int Pan = params->a_param[3]; + int Pad = params->a_param[4]; + int Ph = params->a_param[5]; + int Pv = params->a_param[6]; + + (void) Phgrid; + + TRACE(("sixel bitmap graphics sequence: params=%d (Pmacro=%d Pbgmode=%d Phgrid=%d) scroll_amt=%d\n", + params->a_nparam, + Pmacro, + Pbgmode, + Phgrid, + screen->scroll_amt)); + + switch (params->a_nparam) { + case 7: + if (Pan == 0 || Pad == 0) { + TRACE(("DATA_ERROR: invalid raster ratio %d/%d\n", Pan, Pad)); + return; + } + graphic->aspect_vertical = Pan; + graphic->aspect_horizontal = Pad; + + if (Ph == 0 || Pv == 0) { + TRACE(("DATA_ERROR: raster image dimensions are invalid %dx%d\n", + Ph, Pv)); + return; + } + if (Ph > graphic->max_width || Pv > graphic->max_height) { + TRACE(("DATA_ERROR: raster image dimensions are too large %dx%d\n", + Ph, Pv)); + return; + } + graphic->declared_width = Ph; + graphic->declared_height = Pv; + if (graphic->declared_width > graphic->actual_width) { + graphic->actual_width = graphic->declared_width; + } + if (graphic->declared_height > graphic->actual_height) { + graphic->actual_height = graphic->declared_height; + } + break; + case 3: + case 2: + switch (Pmacro) { + case 0: + case 1: + graphic->aspect_vertical = 5; + graphic->aspect_horizontal = 1; + break; + case 2: + graphic->aspect_vertical = 3; + graphic->aspect_horizontal = 1; + break; + case 3: + case 4: + graphic->aspect_vertical = 2; + graphic->aspect_horizontal = 1; + break; + case 5: + case 6: + graphic->aspect_vertical = 2; + graphic->aspect_horizontal = 1; + break; + case 7: + case 8: + case 9: + graphic->aspect_vertical = 1; + graphic->aspect_horizontal = 1; + break; + default: + TRACE(("DATA_ERROR: unknown sixel macro mode parameter\n")); + return; + } + break; + case 0: + break; + default: + TRACE(("DATA_ERROR: unexpected parameter count (found %d)\n", params->a_nparam)); + return; + } + + if (Pbgmode == 1) { + graphic->background = COLOR_HOLE; + } else { + graphic->background = graphic->device_background; + } + + /* Ignore the grid parameter because it seems only printers paid attention to it. + * The VT3xx was always 0.0195 cm. + */ + } + +#if OPT_SIXEL_GRAPHICS + if (xw->keyboard.flags & MODE_DECSDM) { + TRACE(("sixel scrolling enabled: inline positioning for graphic\n")); + graphic->charrow = screen->cur_row; + graphic->charcol = screen->cur_col; + } + + update_sixel_aspect(graphic); +#endif + + for (;;) { + ch = CharOf(*string); + if (ch == '\0') + break; + + if (ch >= 0x3f && ch <= 0x7e) { + int sixel = ch - 0x3f; + TRACE(("sixel=%x (%c)\n", sixel, (char) ch)); + if (!graphic->valid) { + init_sixel_background(graphic); + graphic->valid = 1; + } + set_sixel(graphic, sixel); + graphic->col++; + } else if (ch == '$') { /* DECGCR */ + /* ignore DECCRNLM in sixel mode */ + TRACE(("sixel CR\n")); + graphic->col = 0; + } else if (ch == '-') { /* DECGNL */ + int scroll_lines; + TRACE(("sixel NL\n")); + scroll_lines = 0; + while (graphic->charrow - scroll_lines + + (((graphic->row + 6) * graphic->pixh + + FontHeight(screen) - 1) + / FontHeight(screen)) > screen->bot_marg) { + scroll_lines++; + } + graphic->col = 0; + graphic->row += 6; + /* If we hit the bottom margin on the graphics page (well, we just use the text margin for now), + * the behavior is to either scroll or to discard the remainder of the graphic depending on this + * setting. + */ + if (scroll_lines > 0) { + if (xw->keyboard.flags & MODE_DECSDM) { + Display *display = screen->display; + xtermScroll(xw, scroll_lines); + XSync(display, False); + TRACE(("graphic scrolled the screen %d lines. screen->scroll_amt=%d screen->topline=%d, now starting row is %d\n", + scroll_lines, + screen->scroll_amt, + screen->topline, + graphic->charrow)); + } else { + break; + } + } + } else if (ch == '!') { /* DECGRI */ + int Pcount; + const char *start; + int sixel; + int i; + + start = ++string; + for (;;) { + ch = CharOf(*string); + if (ch != '0' && + ch != '1' && + ch != '2' && + ch != '3' && + ch != '4' && + ch != '5' && + ch != '6' && + ch != '7' && + ch != '8' && + ch != '9' && + ch != ' ' && + ch != '\r' && + ch != '\n') + break; + string++; + } + if (ch == '\0') { + TRACE(("DATA_ERROR: sixel data string terminated in the middle of a repeat operator\n")); + return; + } + if (string == start) { + TRACE(("DATA_ERROR: sixel data string contains a repeat operator with empty count\n")); + return; + } + Pcount = atoi(start); + sixel = ch - 0x3f; + TRACE(("sixel repeat operator: sixel=%d (%c), count=%d\n", + sixel, (char) ch, Pcount)); + if (!graphic->valid) { + init_sixel_background(graphic); + graphic->valid = 1; + } + for (i = 0; i < Pcount; i++) { + set_sixel(graphic, sixel); + graphic->col++; + } + } else if (ch == '#') { /* DECGCI */ + ANSI color_params; + int Pregister; + + parse_prefixedtype_params(&color_params, &string); + Pregister = color_params.a_param[0]; + if (Pregister >= graphic->valid_registers) { + TRACE(("DATA_WARNING: sixel color operator uses out-of-range register %d\n", Pregister)); + /* FIXME: supposedly the DEC terminals wrapped register indicies -- verify */ + while (Pregister >= graphic->valid_registers) + Pregister -= graphic->valid_registers; + TRACE(("DATA_WARNING: converted to %d\n", Pregister)); + } + + if (color_params.a_nparam > 2 && color_params.a_nparam <= 5) { + int Pspace = color_params.a_param[1]; + int Pc1 = color_params.a_param[2]; + int Pc2 = color_params.a_param[3]; + int Pc3 = color_params.a_param[4]; + short r, g, b; + + TRACE(("sixel set color register=%d space=%d color=[%d,%d,%d] (nparams=%d)\n", + Pregister, Pspace, Pc1, Pc2, Pc3, color_params.a_nparam)); + + switch (Pspace) { + case 1: /* HLS */ + if (Pc1 > 360 || Pc2 > 100 || Pc3 > 100) { + TRACE(("DATA_ERROR: sixel set color operator uses out-of-range HLS color coordinates %d,%d,%d\n", + Pc1, Pc2, Pc3)); + return; + } + hls2rgb(Pc1, Pc2, Pc3, &r, &g, &b); + break; + case 2: /* RGB */ + if (Pc1 > 100 || Pc2 > 100 || Pc3 > 100) { + TRACE(("DATA_ERROR: sixel set color operator uses out-of-range RGB color coordinates %d,%d,%d\n", + Pc1, Pc2, Pc3)); + return; + } + r = (short) Pc1; + g = (short) Pc2; + b = (short) Pc3; + break; + default: /* unknown */ + TRACE(("DATA_ERROR: sixel set color operator uses unknown color space %d\n", Pspace)); + return; + } + if (graphic->private_colors) { + set_sixel_color_register(graphic->private_color_registers, + (RegisterNum) Pregister, + r, g, b); + } else { + set_shared_color_register((RegisterNum) Pregister, r, g, b); + } + graphic->color_registers_used[Pregister] = 1; + } else if (color_params.a_nparam == 1) { + TRACE(("sixel switch to color register=%d (nparams=%d)\n", + Pregister, color_params.a_nparam)); + graphic->current_register = (RegisterNum) Pregister; + } else { + TRACE(("DATA_ERROR: sixel switch color operator with unexpected parameter count (nparams=%d)\n", color_params.a_nparam)); + return; + } + continue; + } else if (ch == '"') /* DECGRA */ { + ANSI raster_params; + + parse_prefixedtype_params(&raster_params, &string); + if (raster_params.a_nparam < 2) { + TRACE(("DATA_ERROR: sixel raster attribute operator with incomplete parameters (found %d, expected 2 or 4)\n", raster_params.a_nparam)); + return; + } { + int Pan = raster_params.a_param[0]; + int Pad = raster_params.a_param[1]; + TRACE(("sixel raster attribute with h:w=%d:%d\n", Pan, Pad)); + if (Pan == 0 || Pad == 0) { + TRACE(("DATA_ERROR: invalid raster ratio %d/%d\n", Pan, Pad)); + return; + } + graphic->aspect_vertical = Pan; + graphic->aspect_horizontal = Pad; + update_sixel_aspect(graphic); + } + + if (raster_params.a_nparam >= 4) { + int Ph = raster_params.a_param[2]; + int Pv = raster_params.a_param[3]; + + TRACE(("sixel raster attribute with h=%d v=%d\n", Ph, Pv)); + if (Ph == 0 || Pv == 0) { + TRACE(("DATA_ERROR: raster image dimensions are invalid %dx%d\n", + Ph, Pv)); + return; + } + if (Ph > graphic->max_width || Pv > graphic->max_height) { + TRACE(("DATA_ERROR: raster image dimensions are too large %dx%d\n", + Ph, Pv)); + return; + } + graphic->declared_width = Ph; + graphic->declared_height = Pv; + if (graphic->declared_width > graphic->actual_width) { + graphic->actual_width = graphic->declared_width; + } + if (graphic->declared_height > graphic->actual_height) { + graphic->actual_height = graphic->declared_height; + } + } + + continue; + } else if (ch == ' ' || ch == '\r' || ch == '\n') { + /* EMPTY */ ; + } else { + TRACE(("DATA_ERROR: unknown sixel command %04x (%c)\n", + (int) ch, ch)); + } + + string++; + } + + /* update the screen */ + if (screen->scroll_amt) + FlushScroll(xw); + + if (xw->keyboard.flags & MODE_DECSDM) { + int new_row = (graphic->charrow + + ((graphic->actual_height * graphic->pixh) + / FontHeight(screen))); + int new_col = (graphic->charcol + + (((graphic->actual_width * graphic->pixw) + + FontWidth(screen) - 1) + / FontWidth(screen))); + + TRACE(("setting text position after %dx%d graphic starting on row=%d col=%d: cursor new_row=%d new_col=%d\n", + graphic->actual_width * graphic->pixw, + graphic->actual_height * graphic->pixh, + graphic->charrow, + graphic->charcol, + new_row, new_col)); + + if (new_col > screen->rgt_marg) { + new_col = screen->lft_marg; + new_row++; + TRACE(("column past left margin, overriding to row=%d col=%d\n", + new_row, new_col)); + } + + while (new_row > screen->bot_marg) { + xtermScroll(xw, 1); + new_row--; + TRACE(("bottom row was past screen. new start row=%d, cursor row=%d\n", + graphic->charrow, new_row)); + } + + if (new_row < 0) { + TRACE(("new row is going to be negative (%d)!", new_row)); /* FIXME: this was triggering, now it isn't */ + } + set_cur_row(screen, new_row); + set_cur_col(screen, new_col <= screen->rgt_marg ? new_col : screen->rgt_marg); + } + + refresh_modified_displayed_graphics(screen); + + TRACE(("DONE successfully parsed sixel data\n")); + dump_sixel(graphic); +} + +extern void +parse_regis(XtermWidget xw, ANSI *params, char const *string) +{ + (void) xw; + (void) string; + (void) params; + + TRACE(("ReGIS vector graphics mode, params=%d\n", params->a_nparam)); +} + +/* Erase the portion of any displayed graphic overlapping with a rectangle + * of the given size and location in pixels. + * This is used to allow text to "erase" graphics underneath it. + */ +static void +erase_sixel_graphic(SixelGraphic *graphic, int x, int y, int w, int h) +{ + RegisterNum hole = COLOR_HOLE; + int pw, ph; + int r, c; + + pw = graphic->pixw; + ph = graphic->pixh; + + TRACE(("erasing sixel bitmap %d,%d %dx%d\n", x, y, w, h)); + + for (r = 0; r < graphic->actual_height; r++) { + for (c = 0; c < graphic->actual_width; c++) { + if (r * ph + ph - 1 < y || + r * ph > y + h - 1 || + c * pw + pw - 1 < x || + c * pw > x + w - 1) + continue; + + graphic->pixels[r * graphic->max_width + c] = hole; + } + } +} + +static int +compare_sixel_ids(const void *left, const void *right) +{ + const SixelGraphic *l = *(const SixelGraphic *const *) left; + const SixelGraphic *r = *(const SixelGraphic *const *) right; + + if (!l->valid || !r->valid) + return 0; + if (l->id < r->id) + return -1; + else + return 1; +} + +extern void +refresh_displayed_graphics(TScreen const *screen, + int leftcol, + int toprow, + int ncols, + int nrows) +{ + SixelGraphic *ordered_graphics[MAX_SIXEL_GRAPHICS]; + SixelGraphic *graphic; + unsigned int ii; + int x, y, w, h; + int xbase, ybase; + + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + ordered_graphics[ii] = &sixel_graphics[ii]; + } + qsort(ordered_graphics, + (size_t) MAX_SIXEL_GRAPHICS, + sizeof(ordered_graphics[0]), + compare_sixel_ids); + + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = ordered_graphics[ii]; + if (!graphic->valid || graphic->bufferid != screen->whichBuf) + continue; + + x = (leftcol - graphic->charcol) * FontWidth(screen); + y = (toprow - graphic->charrow) * FontHeight(screen); + w = ncols * FontWidth(screen); + h = nrows * FontHeight(screen); + + xbase = (screen->border + + graphic->charcol * FontWidth(screen)); + ybase = (screen->border + + (graphic->charrow - screen->topline) * FontHeight(screen)); + + if (xbase + x + w + screen->border > FullWidth(screen)) + w = FullWidth(screen) - (xbase + x + screen->border); + if (ybase + y + h + screen->border > FullHeight(screen)) + h = FullHeight(screen) - (ybase + y + screen->border); + else if (ybase + y < screen->border) { + int diff = screen->border - (ybase + y); + y += diff; + h -= diff; + } + + TRACE(("graphics refresh: screen->topline=%d leftcol=%d toprow=%d nrows=%d ncols=%d x=%d y=%d w=%d h=%d xbase=%d ybase=%d\n", + screen->topline, + leftcol, toprow, + nrows, ncols, + x, y, w, h, + xbase, ybase)); + refresh_sixel_graphic(screen, graphic, xbase, ybase, x, y, w, h); + } +} + +extern void +refresh_modified_displayed_graphics(TScreen const *screen) +{ + SixelGraphic *graphic; + unsigned int ii; + int leftcol, toprow; + int nrows, ncols; + int x, y, w, h; + int xbase, ybase; + + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = &sixel_graphics[ii]; + if (!graphic->valid || graphic->bufferid != screen->whichBuf || !graphic->dirty) + continue; + + leftcol = graphic->charcol; + toprow = graphic->charrow; + nrows = (((graphic->actual_height * graphic->pixh) + + FontHeight(screen) - 1) + / FontHeight(screen)); + ncols = (((graphic->actual_width * graphic->pixw) + + FontWidth(screen) - 1) + / FontWidth(screen)); + + x = (leftcol - graphic->charcol) * FontWidth(screen); + y = (toprow - graphic->charrow) * FontHeight(screen); + w = ncols * FontWidth(screen); + h = nrows * FontHeight(screen); + + xbase = (screen->border + + graphic->charcol * FontWidth(screen)); + ybase = (screen->border + + (graphic->charrow - screen->topline) * FontHeight(screen)); + + if (xbase + x + w + screen->border > FullWidth(screen)) + w = FullWidth(screen) - (xbase + x + screen->border); + if (ybase + y + h + screen->border > FullHeight(screen)) + h = FullHeight(screen) - (ybase + y + screen->border); + else if (ybase + y < screen->border) { + int diff = screen->border - (ybase + y); + y += diff; + h -= diff; + } + + TRACE(("full graphics refresh: screen->topline=%d leftcol=%d toprow=%d nrows=%d ncols=%d x=%d y=%d w=%d h=%d xbase=%d ybase=%d\n", + screen->topline, + leftcol, toprow, + nrows, ncols, + x, y, w, h, + xbase, ybase)); + refresh_sixel_graphic(screen, graphic, xbase, ybase, x, y, w, h); + graphic->dirty = 0; + } +} + +extern void +scroll_displayed_graphics(int rows) +{ + SixelGraphic *graphic; + unsigned int ii; + + TRACE(("graphics scroll: moving all up %d rows\n", rows)); + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = &sixel_graphics[ii]; + if (!graphic->valid) + continue; + + graphic->charrow -= rows; + } +} + +extern void +pixelarea_clear_displayed_graphics(TScreen const *screen, + int winx, + int winy, + int w, + int h) +{ + SixelGraphic *graphic; + unsigned int ii; + int x, y; + + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = &sixel_graphics[ii]; + if (!graphic->valid) + continue; + + x = winx - graphic->charcol * FontWidth(screen); + y = winy - graphic->charrow * FontHeight(screen); + + TRACE(("pixelarea graphics erase: screen->topline=%d winx=%d winy=%d w=%d h=%d x=%d y=%d\n", + screen->topline, + winx, winy, + w, h, + x, y)); + erase_sixel_graphic(graphic, x, y, w, h); + } +} + +extern void +chararea_clear_displayed_graphics(TScreen const *screen, + int leftcol, + int toprow, + int ncols, + int nrows) +{ + int x, y, w, h; + + x = leftcol * FontWidth(screen); + y = toprow * FontHeight(screen); + w = ncols * FontWidth(screen); + h = nrows * FontHeight(screen); + + TRACE(("chararea clear graphics: screen->topline=%d leftcol=%d toprow=%d nrows=%d ncols=%d x=%d y=%d w=%d h=%d\n", + screen->topline, + leftcol, toprow, + nrows, ncols, + x, y, w, h)); + pixelarea_clear_displayed_graphics(screen, x, y, w, h); +} + +extern void +reset_displayed_graphics(TScreen const *screen) +{ + SixelGraphic *graphic; + unsigned int ii; + + init_color_registers(shared_color_registers, screen->terminal_id); + TRACE(("resetting all sixel graphics\n")); + for (ii = 0U; ii < MAX_SIXEL_GRAPHICS; ii++) { + graphic = &sixel_graphics[ii]; + graphic->valid = 0; + } +} diff -Nru xterm-278/graphics.h xterm-297/graphics.h --- xterm-278/graphics.h 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/graphics.h 2013-07-10 08:28:55.000000000 +0000 @@ -0,0 +1,70 @@ +/* $XTermId: graphics.h,v 1.6 2013/07/10 08:28:55 Ross.Combs Exp $ */ + +/* + * Copyright 2013 by Ross Combs + * Copyright 2013 by Thomas E. Dickey + * + * 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. + */ + +#ifndef included_graphics_h +#define included_graphics_h +/* *INDENT-OFF* */ + +#include + +#if OPT_SIXEL_GRAPHICS + +typedef unsigned short RegisterNum; + +extern void chararea_clear_displayed_graphics(TScreen const *screen, int leftcol, int toprow, int ncols, int nrows); +extern void parse_regis(XtermWidget xw, ANSI *params, char const *string); +extern void parse_sixel(XtermWidget xw, ANSI *params, char const *string); +extern void pixelarea_clear_displayed_graphics(TScreen const *screen, int winx, int winy, int w, int h); +extern void refresh_displayed_graphics(TScreen const *screen, int leftcol, int toprow, int ncols, int nrows); +extern void refresh_modified_displayed_graphics(TScreen const *screen); +extern void reset_displayed_graphics(TScreen const *screen); +extern void scroll_displayed_graphics(int rows); +extern void update_displayed_graphics_color_registers(TScreen const *screen, RegisterNum color, short r, short g, short b); + +#else + +#define chararea_clear_displayed_graphics(screen, leftcol, toprow, ncols, nrows) /* nothing */ +#define parse_regis(xw, params, string) /* nothing */ +#define parse_sixel(xw, params, string) /* nothing */ +#define pixelarea_clear_displayed_graphics(screen, winx, winy, w, h) /* nothing */ +#define refresh_displayed_graphics(screen, leftcol, toprow, ncols, nrows) /* nothing */ +#define refresh_modified_displayed_graphics(screen) /* nothing */ +#define reset_displayed_graphics(screen) /* nothing */ +#define scroll_displayed_graphics(rows) /* nothing */ +#define update_displayed_graphics_color_registers(screen, color, r, g, b) /* nothing */ + +#endif + +/* *INDENT-ON* */ + +#endif /* included_graphics_h */ Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/filled-xterm.png and /tmp/2MsnOjJWPZ/xterm-297/icons/filled-xterm.png differ diff -Nru xterm-278/icons/filled-xterm.svg xterm-297/icons/filled-xterm.svg --- xterm-278/icons/filled-xterm.svg 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/filled-xterm.svg 2012-10-07 22:53:18.000000000 +0000 @@ -0,0 +1,680 @@ + + + + + terminal + + + + + + + + + + image/svg+xml + + xterm + + + + Thomas E. Dickey + + + + + MIT-X11 + + + XTerm icon, in SVG format. + June 14, 2012 + http://invisible-island.net/xterm/ + http://invisible-island.net/xterm/xterm + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + X + TERM + + + + + + + + + diff -Nru xterm-278/icons/filled-xterm.xpms xterm-297/icons/filled-xterm.xpms --- xterm-278/icons/filled-xterm.xpms 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/filled-xterm.xpms 2012-10-07 22:58:01.000000000 +0000 @@ -0,0 +1,694 @@ +/* $XTermId: filled-xterm.xpms,v 1.1 2012/10/07 22:58:01 tom Exp $ */ +/* generated by ./make-xpms */ +/* vile:xpmmode */ +/* XPM */ +static const char * const filled_xterm_16x16_xpm[] = { +"16 16 110 2", +" c None", +". c #BAA9A9", +"+ c #C59C9C", +"@ c #C49999", +"# c #C6AAAA", +"$ c #4D4242", +"% c #F0E4E4", +"& c #CEBABA", +"* c #D5BEBE", +"= c #C6B5B5", +"- c #CEBEBE", +"; c #796D6D", +"> c #DEC5C5", +", c #B19B9B", +"' c #C6B8B8", +") c #B19696", +"! c #EBE5E5", +"~ c #FFFFFF", +"{ c #D6D6D6", +"] c #D0BDBD", +"^ c #FFF4F4", +"/ c #FEFDFD", +"( c #706969", +"_ c #CCC3C3", +": c #FFF0F0", +"< c #978989", +"[ c #A9A5A5", +"} c #A7A3A3", +"| c #E3E1E1", +"1 c #DACBCB", +"2 c #DEDEDE", +"3 c #FFF8F8", +"4 c #FFF6F6", +"5 c #FFFCFC", +"6 c #FFFEFE", +"7 c #D2D2D2", +"8 c #9C9C9C", +"9 c #9B8787", +"0 c #B3A0A0", +"a c #FFD5D5", +"b c #D4C2C2", +"c c #FFE7E7", +"d c #7A6F6F", +"e c #786F6F", +"f c #C2C2C2", +"g c #B4B4B4", +"h c #FFE3E3", +"i c #E1CECE", +"j c #FED8D8", +"k c #908888", +"l c #878080", +"m c #898383", +"n c #F3ECEC", +"o c #D8C2C2", +"p c #FFFAFA", +"q c #FFF2F2", +"r c #FFF9F9", +"s c #EFEFEF", +"t c #FEFEFE", +"u c #C8C3C3", +"v c #D2BFBF", +"w c #8A8383", +"x c #FCE5E5", +"y c #D9B6B6", +"z c #DDBCBC", +"A c #BCA0A0", +"B c #F0D2D2", +"C c #AB9C9C", +"D c #000000", +"E c #B0A2A2", +"F c #AE9F9F", +"G c #C6ABAB", +"H c #B48E8E", +"I c #C8ABAB", +"J c #C39A9A", +"K c #D0B2B2", +"L c #C3A0A0", +"M c #CFB2B2", +"N c #C59999", +"O c #CCC1C1", +"P c #3C3535", +"Q c #A39C9C", +"R c #FAEDED", +"S c #FEFCFC", +"T c #F9F2F2", +"U c #FEF7F7", +"V c #FAEBEB", +"W c #FEFAFA", +"X c #F9F1F1", +"Y c #FEF4F4", +"Z c #FAEFEF", +"` c #EBE0E0", +" . c #DFB9B9", +".. c #E8E3E3", +"+. c #BBB0B0", +"@. c #BBA9A9", +"#. c #CEC8C8", +"$. c #BCADAD", +"%. c #CDC8C8", +"&. c #C78D8D", +"*. c #E3B2B2", +"=. c #E3BCBC", +"-. c #BBAAAA", +";. c #746C6C", +">. c #858585", +",. c #8A7F7F", +"'. c #977878", +"). c #A38686", +"!. c #A78686", +"~. c #201717", +" . + @ @ @ @ @ @ @ @ # $ ", +" % & * * * * * * * * = - ; ", +" > , ' ) ! ~ ~ ~ ~ ~ { ] ^ ", +" > / ( _ ~ ~ ~ ~ ~ ~ { ] : ", +" > ~ < [ ~ ~ ~ ~ ~ ~ { ] : ", +" > } | 1 2 ~ ~ ~ ~ ~ { ] : ", +" > ~ ~ 3 ~ 4 4 5 6 4 7 ] : ", +" > 7 8 9 0 a b c d e f ] : ", +" > ~ g h i j k c l m f ] n ", +" o ~ ~ p ~ q 6 r s t u v w ", +" x y z z z z z z A z B C ", +" D ", +" E F G H I J K L M N O P ", +" Q R S T U V W X Y Z U ` Q ", +" ...+._ @.#.$.%.&.*.=.-.;. ", +" >.>.>.,.'.).).).).).!.~. "}; +/* XPM */ +static const char * const filled_xterm_32x32_xpm[] = { +"32 32 225 2", +" c None", +". c #000000", +"+ c #D9C2C2", +"@ c #EEE5E5", +"# c #EBE0E0", +"$ c #EBE1E1", +"% c #EDE1E1", +"& c #918484", +"* c #FFEEEE", +"= c #F2DCDC", +"- c #403838", +"; c #5A5A5A", +"> c #5B4545", +", c #FEF2F2", +"' c #E9E9E9", +") c #856868", +"! c #271D1D", +"~ c #FBCFCF", +"{ c #746060", +"] c #FFFBFB", +"^ c #FFFFFF", +"/ c #FAF0F0", +"( c #5E4949", +"_ c #E3DCDC", +": c #BAA8A8", +"< c #292020", +"[ c #F1C0C0", +"} c #D9C6C6", +"| c #FFECEC", +"1 c #FFE8E8", +"2 c #FFFAFA", +"3 c #FFF0F0", +"4 c #FFEFEF", +"5 c #705D5D", +"6 c #DED5D5", +"7 c #F9E6E6", +"8 c #D3C3C3", +"9 c #392F2F", +"0 c #FCF6F6", +"a c #BAA7A7", +"b c #524646", +"c c #D9D1D1", +"d c #F2EAEA", +"e c #796666", +"f c #FEF7F7", +"g c #BBAAAA", +"h c #918383", +"i c #1D1515", +"j c #EBDADA", +"k c #B5B5B5", +"l c #FFF4F4", +"m c #DDD0D0", +"n c #110A0A", +"o c #FEFBFB", +"p c #D3C7C7", +"q c #FFF3F3", +"r c #968484", +"s c #F2E9E9", +"t c #908484", +"u c #FFFDFD", +"v c #A89191", +"w c #776262", +"x c #CCB4B4", +"y c #9E7979", +"z c #705F5F", +"A c #FFCCCC", +"B c #FFEAEA", +"C c #FFE6E6", +"D c #FFF1F1", +"E c #FFFEFE", +"F c #FFE1E1", +"G c #FFF2F2", +"H c #FFF7F7", +"I c #C7B8B8", +"J c #AE9494", +"K c #5A4848", +"L c #C0AFAF", +"M c #D1BDBD", +"N c #4F3D3D", +"O c #513636", +"P c #BCB0B0", +"Q c #665757", +"R c #1A0C0C", +"S c #E4DCDC", +"T c #FCF3F3", +"U c #1F0C0C", +"V c #C3C3C3", +"W c #726363", +"X c #443A3A", +"Y c #FFF8F8", +"Z c #583D3D", +"` c #FCF4F4", +" . c #615757", +".. c #6C5656", +"+. c #A09393", +"@. c #9B8E8E", +"#. c #856464", +"$. c #4A3F3F", +"%. c #BBBBBB", +"&. c #C0BCBC", +"*. c #452F2F", +"=. c #736C6C", +"-. c #775656", +";. c #878787", +">. c #A38888", +",. c #624D4D", +"'. c #C9B4B4", +"). c #F8F0F0", +"!. c #FFEDED", +"~. c #604242", +"{. c #B5A8A8", +"]. c #FAE9E9", +"^. c #FBF3F3", +"/. c #BAB2B2", +"(. c #F8DEDE", +"_. c #7F6F6F", +":. c #B5A2A2", +"<. c #806F6F", +"[. c #AA8E8E", +"}. c #FEFDFD", +"|. c #BD9F9F", +"1. c #C3B4B4", +"2. c #E0DCDC", +"3. c #F9EEEE", +"4. c #080303", +"5. c #F3C1C1", +"6. c #B7A2A2", +"7. c #4C3A3A", +"8. c #DFD6D6", +"9. c #7E6D6D", +"0. c #FFE9E9", +"a. c #B39A9A", +"b. c #BBA5A5", +"c. c #DEC9C9", +"d. c #715D5D", +"e. c #F3DDDD", +"f. c #8B7979", +"g. c #060303", +"h. c #FFEBEB", +"i. c #EFE9E9", +"j. c #EAEAEA", +"k. c #FAEFEF", +"l. c #D1C3C3", +"m. c #0B0707", +"n. c #312222", +"o. c #584141", +"p. c #685252", +"q. c #5D5858", +"r. c #5F5F5F", +"s. c #5B5B5B", +"t. c #5C5858", +"u. c #473232", +"v. c #181111", +"w. c #ECD8D8", +"x. c #F9EFEF", +"y. c #DBC6C6", +"z. c #DEC5C5", +"A. c #F7EDED", +"B. c #DCC4C4", +"C. c #F8EDED", +"D. c #DEC3C3", +"E. c #E0C9C9", +"F. c #DEC1C1", +"G. c #DBC7C7", +"H. c #F7E8E8", +"I. c #E1CACA", +"J. c #DBC2C2", +"K. c #F8EFEF", +"L. c #796868", +"M. c #422B2B", +"N. c #B5A3A3", +"O. c #F8ECEC", +"P. c #F8EEEE", +"Q. c #FDF7F7", +"R. c #FEF9F9", +"S. c #F7EAEA", +"T. c #FDF6F6", +"U. c #F7EBEB", +"V. c #FDF5F5", +"W. c #F7EEEE", +"X. c #F8EBEB", +"Y. c #786565", +"Z. c #2C2121", +"`. c #F6E9E9", +" + c #F6E8E8", +".+ c #F9EDED", +"++ c #FEFCFC", +"@+ c #F7ECEC", +"#+ c #F7E9E9", +"$+ c #837070", +"%+ c #806C6C", +"&+ c #D4C3C3", +"*+ c #DCC8C8", +"=+ c #DDC2C2", +"-+ c #DBBFBF", +";+ c #E1C8C8", +">+ c #DEC8C8", +",+ c #DEC7C7", +"'+ c #DFC8C8", +")+ c #DEBBBB", +"!+ c #FAEEEE", +"~+ c #221B1B", +"{+ c #3E3131", +"]+ c #F8E8E8", +"^+ c #8D8181", +"/+ c #F6E7E7", +"(+ c #696969", +"_+ c #6D6D6D", +":+ c #6F6C6C", +"<+ c #835D5D", +"[+ c #875D5D", +"}+ c #9D7474", +"|+ c #A27A7A", +"1+ c #958989", +"2+ c #919191", +"3+ c #9D9797", +"4+ c #917E7E", +"5+ c #E3C8C8", +"6+ c #241B1B", +"7+ c #695959", +"8+ c #CEBCBC", +"9+ c #D1D1D1", +"0+ c #CFCBCB", +"a+ c #322424", +"b+ c #201818", +" ", +" . + @ # $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ % @ & . ", +" . * = - ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; > , ' ) ! ", +" . ~ { ] ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ / ( _ : / < ", +" . [ } | 1 1 2 3 1 4 ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ 7 . ", +" . [ } 8 9 0 a b * ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ 4 . ", +" . [ } ^ c d e f ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 g ^ 4 . ", +" . [ } ^ ^ h i j ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ l . ", +" . [ } ^ ^ m n | ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ ^ . ", +" . [ } ^ o { p q ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ ^ . ", +" . [ } ^ r s ^ t u ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ ^ . ", +" . [ } v w x ^ y z A ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ ^ . ", +" . [ } ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ ^ . ", +" . [ } B C C C D C C C E F G G ^ l C ^ ^ H ] 5 6 : ^ ^ . ", +" . [ } I J K L M N L L E O P Q l B R S T U V 5 6 : ^ ^ . ", +" . [ } ^ * W ^ * X ^ Y ^ Z ` .q B ..+.@.#.V 5 6 : ^ ^ . ", +" . [ } ^ * W ^ * $.%.&.^ *.=.-.u B ;.>.,.'.V 5 6 : ^ ).. ", +" . [ } ^ * W ^ * ,.!.!.E ~.^ {.].B ;.^./.(.V 5 6 : ^ _. ", +" . [ } ^ q :.^ l <.<.<.E [.^ }.|.3 1.^ ^ B 2.5 6 : 3.4. ", +" . 5.6.^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ] 7.8.: 9. ", +" . 0.a.b.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.d.e.' f.g. ", +" . h.2 i.j.j.j.j.j.j.j.j.j.j.j.j.j.j.j.j.j.k.^ l.m. ", +" . . . . . . . . . . . . . . . . . . . . . . . ", +" ", +" n.o.p.p.p.p.q.; r.s.; ; ; t.p.p.p.p.p.p.p.p.u.. ", +" v.w.x.y.z.A.3.} B.C.3.D.E.C.C.F.G.C.H.I.J.C.K.L.M. ", +" N.O.P.Q.R.S.S.f T.U.S.V.f W.A.Q.Q.P.P.Q.f O.X._.Y. ", +" Z.Y `. +V.f .+A.T.Q.O..+++V.K.@+f f #+A.R.V.`.$+x.%+ ", +" &+B.X.).*+=+C.#+-+;+C.O.>+,+U.#+'+)+@+#+F.*+!+9.k.~+ ", +" {+]+^+/+(+_+_+_+_+_+_+_+_+:+<+[+}+|+1+2+3+S.^+4+5+6+ ", +" 7+8+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+0+a+b+ ", +" "}; +/* XPM */ +static const char * const filled_xterm_48x48_xpm[] = { +"48 48 246 2", +" c None", +". c #000000", +"+ c #F6D5D5", +"@ c #FFEAEA", +"# c #FFD6D6", +"$ c #FFD2D2", +"% c #FFD3D3", +"& c #F8D6D6", +"* c #FFEFEF", +"= c #FFFFFF", +"- c #F6DBDB", +"; c #0F0707", +"> c #090505", +", c #F6DCDC", +"' c #FFEEEE", +") c #C99999", +"! c #030101", +"~ c #F7DEDE", +"{ c #150B0B", +"] c #E3C5C5", +"^ c #FFEDED", +"/ c #E4CBCB", +"( c #140B0B", +"_ c #F7DDDD", +": c #E0C9C9", +"< c #080303", +"[ c #FFD9D9", +"} c #0D0707", +"| c #E5CACA", +"1 c #E5CBCB", +"2 c #0B0606", +"3 c #FFDCDC", +"4 c #E2CECE", +"5 c #090303", +"6 c #E1CBCB", +"7 c #9F8A8A", +"8 c #3B2929", +"9 c #312020", +"0 c #FFD5D5", +"a c #ECC8C8", +"b c #402525", +"c c #351F1F", +"d c #663E3E", +"e c #E6DBDB", +"f c #FFFAFA", +"g c #FFFEFE", +"h c #8C7272", +"i c #B4A1A1", +"j c #A69494", +"k c #D8C0C0", +"l c #675353", +"m c #FFFDFD", +"n c #584545", +"o c #E1BFBF", +"p c #3C2929", +"q c #FCF3F3", +"r c #F6EAEA", +"s c #160F0F", +"t c #E9D3D3", +"u c #6E5C5C", +"v c #D6BABA", +"w c #CBBBBB", +"x c #0D0808", +"y c #F8E8E8", +"z c #FFE2E2", +"A c #F4EDED", +"B c #FFF2F2", +"C c #4B3A3A", +"D c #FFFBFB", +"E c #AD9292", +"F c #FFE1E1", +"G c #A28E8E", +"H c #CCBDBD", +"I c #8B7777", +"J c #231515", +"K c #ECCECE", +"L c #FFDADA", +"M c #251414", +"N c #9A8686", +"O c #FFF1F1", +"P c #FFECEC", +"Q c #FFE4E4", +"R c #FFDFDF", +"S c #FFDBDB", +"T c #FFF0F0", +"U c #FFDDDD", +"V c #FFEBEB", +"W c #FFF4F4", +"X c #FFE5E5", +"Y c #FFDEDE", +"Z c #B29E9E", +"` c #A08F8F", +" . c #8A7373", +".. c #1C1111", +"+. c #D7CACA", +"@. c #645555", +"#. c #5E4B4B", +"$. c #FFF7F7", +"%. c #BD9F9F", +"&. c #392B2B", +"*. c #A19090", +"=. c #867474", +"-. c #9C8D8D", +";. c #A99494", +">. c #0E0606", +",. c #FFE9E9", +"'. c #D5C6C6", +"). c #564545", +"!. c #FFE7E7", +"~. c #5B3D3D", +"{. c #352121", +"]. c #5B4242", +"^. c #FFD7D7", +"/. c #E7D2D2", +"(. c #1F1313", +"_. c #786363", +":. c #AC9191", +"<. c #FFE8E8", +"[. c #DBC7C7", +"}. c #897474", +"|. c #574E4E", +"1. c #999999", +"2. c #FFF6F6", +"3. c #170F0F", +"4. c #3B2B2B", +"5. c #190E0E", +"6. c #C7B6B6", +"7. c #5F4D4D", +"8. c #F6E1E1", +"9. c #FCE9E9", +"0. c #F1EAEA", +"a. c #FEFAFA", +"b. c #3D2828", +"c. c #382626", +"d. c #947D7D", +"e. c #FFFCFC", +"f. c #B09B9B", +"g. c #C2B2B2", +"h. c #EEDADA", +"i. c #FDEFEF", +"j. c #0B0505", +"k. c #DACACA", +"l. c #7D6565", +"m. c #C6A7A7", +"n. c #FDF9F9", +"o. c #6C4D4D", +"p. c #AB9797", +"q. c #927B7B", +"r. c #FCEDED", +"s. c #0A0404", +"t. c #120B0B", +"u. c #E8D1D1", +"v. c #E2CACA", +"w. c #0F0808", +"x. c #907979", +"y. c #F9DFDF", +"z. c #1D1111", +"A. c #E8D0D0", +"B. c #E1C8C8", +"C. c #1A0C0C", +"D. c #F8E0E0", +"E. c #F7D4D4", +"F. c #090404", +"G. c #FAE1E1", +"H. c #100A0A", +"I. c #100808", +"J. c #7C4F4F", +"K. c #F6D3D3", +"L. c #FFD8D8", +"M. c #F8D5D5", +"N. c #AF9393", +"O. c #FDE5E5", +"P. c #FDE9E9", +"Q. c #FDE2E2", +"R. c #FDF8F8", +"S. c #FDE6E6", +"T. c #FEECEC", +"U. c #FEE5E5", +"V. c #FFE6E6", +"W. c #F8D1D1", +"X. c #0D0404", +"Y. c #291D1D", +"Z. c #583030", +"`. c #FFF8F8", +" + c #683737", +".+ c #5B3333", +"++ c #582D2D", +"@+ c #593030", +"#+ c #5D3232", +"$+ c #5A2D2D", +"%+ c #663737", +"&+ c #5B3030", +"*+ c #897272", +"=+ c #996F6F", +"-+ c #DBC1C1", +";+ c #110808", +">+ c #FDDDDD", +",+ c #473636", +"'+ c #563232", +")+ c #FFF5F5", +"!+ c #5C3636", +"~+ c #FFF9F9", +"{+ c #582E2E", +"]+ c #6F4040", +"^+ c #5B3434", +"/+ c #6D3E3E", +"(+ c #5A3333", +"_+ c #EFD7D7", +":+ c #FCEFEF", +"<+ c #140A0A", +"[+ c #6A5252", +"}+ c #583333", +"|+ c #5C2A2A", +"1+ c #653737", +"2+ c #6B3C3C", +"3+ c #643434", +"4+ c #6A3C3C", +"5+ c #613535", +"6+ c #9C8787", +"7+ c #907A7A", +"8+ c #DDC3C3", +"9+ c #F8E5E5", +"0+ c #FDF3F3", +"a+ c #190D0D", +"b+ c #FAEAEA", +"c+ c #DCC4C4", +"d+ c #876E6E", +"e+ c #461F1F", +"f+ c #472020", +"g+ c #261414", +"h+ c #070000", +"i+ c #220000", +"j+ c #230101", +"k+ c #3A1818", +"l+ c #3F1D1D", +"m+ c #3E1E1E", +"n+ c #553333", +"o+ c #724646", +"p+ c #431F1F", +"q+ c #AB8F8F", +"r+ c #887171", +"s+ c #DAC0C0", +"t+ c #FBD1D1", +"u+ c #1A1010", +"v+ c #B27C7C", +"w+ c #020101", +" ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" . + @ @ # $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ % @ @ & . . ", +" . * = - ; . . . . . . . . . . . . . . . . . . . . . . . . . . > , = ' . ) ! ", +" . * ~ { ] ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ / ( _ ' . ^ : < ", +" . [ } | = = = = = = = = = = = = = = = = = = = = = = = = = = = = 1 2 3 . ^ = 4 5 ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ^ = = 6 . ", +" . [ . * 7 8 9 0 = a b c d = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = e f = g h i = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = j = k l g = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = m n o p q = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = r s . t = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = = u . v = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = w x y = = = = = = = = = = = = = = = = = = = = * . [ . z = = * . ", +" . [ . * = = A B B C D = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = E z = = F G = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * H I J K = = L M } N O = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * P Q Q R = = S Q Q Q T = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * [ U U U U U V z U U U U W X Y X ^ = = V U O = = O F ' * . [ . ' = = * . ", +" . [ . * Z ` ...` Q +.@.#.` ` Q $.%.&.*.=. ^ = -. = = ;.>.,.* . [ . ' = = * . ", +" . [ . * = = '. = = = Q = = = = %. = = ).!.= -.~. f f {.].,.* . [ . ' = = * . ", +" . [ . * = = '. = = = U U ^.= %. ^ /.(.' = -._.:.<.[.}.@.,.* . [ . ' = = * . ", +" . [ . * = = '. = = = @.|.1.1.2.= %.3.4.5. = = -. 6. 7.8.@.,.* . [ . ' = = 9.. ", +" . [ . * = = '. = = = Q = = = = %. = 0. ' = -. a.b.c.f @.,.* . [ . ' = = d.. ", +" . [ . * = = '. = = = 0 ^ ^ ^ e.%. = = f. m -. = g.h.= @.,.* . [ . ' = i.j. ", +" . [ . * = = k. = = = l.9 9 9 ' m. = = n.o.z p. = = = = l.X * . [ . ' = q.. ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ' r.s. ", +" . 3 t.u.= = = = = = = = = = = = = = = = = = = = = = = = = = = = v.w.S . ' x.. ", +" . * y.z.A.^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ B.C.D.' . E.F. ", +" . * = G.H.. . . . . . . . . . . . . . . . . . . . . . . . . . I.D.= ' . J.. ", +" . K.P P # $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ L.P P M.. . ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" ", +" ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" . N.O.P.O.P.Q.R.S.P.O.P.O.P.O.T.U.T.U.T.,.^ ,.^ ,.^ V.^ ,.= D W ,.^ W.X.. ", +" Y.W Z.`. +e..+e.++D @+$.Z.`. +e.#+e.$+D @+$.Z.`.%+e.#+e.$+e.&+$.Z.D *+=+. ", +" . -+D f e.m D `.= D e.D D f D m D `.= D e.D D f D m D `.= D e.D D f r.;+>+. ", +" ,+`.'+)+!+~+{+= ]+f .+`.Z.)+^+~+{+= /+f .+`.Z.)+^+~+{+= /+f (+`.Z.f q.q.T . ", +" . _+m f = D m ~+e.`.m f m f = D m ~+e.`.m f e.f = D m ~+e.`.m f m f :+<+i.T . ", +" . [+~+}+)+|+~+1+g 2+g 3+`.}+)+|+~+1+g 4+= 3+`.}+)+|+~+1+g 4+= 3+~+5+e.6+7+= 8+. ", +" ! 9+= ~+= T ' @ ' ,.' <.' <.' ' ' @ e.f = ~+= ~+= = = D = f = ~+= = 0+a+b+c+! ", +" . d+m e+f+e.g+. . . . . . . . . . . . h+i+i+j+k+l+l+c m+l+l+n+o+e.e+p+q+r+s+! ", +" . t+* @ @ P S [ L S S S S S S S S S S z ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ P z u+v+w+ ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" "}; +static const XPM_DATA filled_xterm_xpms[] = { + { "filled-xterm_16x16", filled_xterm_16x16_xpm }, + { "filled-xterm_32x32", filled_xterm_32x32_xpm }, + { "filled-xterm_48x48", filled_xterm_48x48_xpm } +}; diff -Nru xterm-278/icons/filled-xterm_16x16.xpm xterm-297/icons/filled-xterm_16x16.xpm --- xterm-278/icons/filled-xterm_16x16.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/filled-xterm_16x16.xpm 2012-10-07 22:56:14.000000000 +0000 @@ -0,0 +1,129 @@ +/* XPM */ +static char * filled_xterm_16x16_xpm[] = { +"16 16 110 2", +" c None", +". c #BAA9A9", +"+ c #C59C9C", +"@ c #C49999", +"# c #C6AAAA", +"$ c #4D4242", +"% c #F0E4E4", +"& c #CEBABA", +"* c #D5BEBE", +"= c #C6B5B5", +"- c #CEBEBE", +"; c #796D6D", +"> c #DEC5C5", +", c #B19B9B", +"' c #C6B8B8", +") c #B19696", +"! c #EBE5E5", +"~ c #FFFFFF", +"{ c #D6D6D6", +"] c #D0BDBD", +"^ c #FFF4F4", +"/ c #FEFDFD", +"( c #706969", +"_ c #CCC3C3", +": c #FFF0F0", +"< c #978989", +"[ c #A9A5A5", +"} c #A7A3A3", +"| c #E3E1E1", +"1 c #DACBCB", +"2 c #DEDEDE", +"3 c #FFF8F8", +"4 c #FFF6F6", +"5 c #FFFCFC", +"6 c #FFFEFE", +"7 c #D2D2D2", +"8 c #9C9C9C", +"9 c #9B8787", +"0 c #B3A0A0", +"a c #FFD5D5", +"b c #D4C2C2", +"c c #FFE7E7", +"d c #7A6F6F", +"e c #786F6F", +"f c #C2C2C2", +"g c #B4B4B4", +"h c #FFE3E3", +"i c #E1CECE", +"j c #FED8D8", +"k c #908888", +"l c #878080", +"m c #898383", +"n c #F3ECEC", +"o c #D8C2C2", +"p c #FFFAFA", +"q c #FFF2F2", +"r c #FFF9F9", +"s c #EFEFEF", +"t c #FEFEFE", +"u c #C8C3C3", +"v c #D2BFBF", +"w c #8A8383", +"x c #FCE5E5", +"y c #D9B6B6", +"z c #DDBCBC", +"A c #BCA0A0", +"B c #F0D2D2", +"C c #AB9C9C", +"D c #000000", +"E c #B0A2A2", +"F c #AE9F9F", +"G c #C6ABAB", +"H c #B48E8E", +"I c #C8ABAB", +"J c #C39A9A", +"K c #D0B2B2", +"L c #C3A0A0", +"M c #CFB2B2", +"N c #C59999", +"O c #CCC1C1", +"P c #3C3535", +"Q c #A39C9C", +"R c #FAEDED", +"S c #FEFCFC", +"T c #F9F2F2", +"U c #FEF7F7", +"V c #FAEBEB", +"W c #FEFAFA", +"X c #F9F1F1", +"Y c #FEF4F4", +"Z c #FAEFEF", +"` c #EBE0E0", +" . c #DFB9B9", +".. c #E8E3E3", +"+. c #BBB0B0", +"@. c #BBA9A9", +"#. c #CEC8C8", +"$. c #BCADAD", +"%. c #CDC8C8", +"&. c #C78D8D", +"*. c #E3B2B2", +"=. c #E3BCBC", +"-. c #BBAAAA", +";. c #746C6C", +">. c #858585", +",. c #8A7F7F", +"'. c #977878", +"). c #A38686", +"!. c #A78686", +"~. c #201717", +" . + @ @ @ @ @ @ @ @ # $ ", +" % & * * * * * * * * = - ; ", +" > , ' ) ! ~ ~ ~ ~ ~ { ] ^ ", +" > / ( _ ~ ~ ~ ~ ~ ~ { ] : ", +" > ~ < [ ~ ~ ~ ~ ~ ~ { ] : ", +" > } | 1 2 ~ ~ ~ ~ ~ { ] : ", +" > ~ ~ 3 ~ 4 4 5 6 4 7 ] : ", +" > 7 8 9 0 a b c d e f ] : ", +" > ~ g h i j k c l m f ] n ", +" o ~ ~ p ~ q 6 r s t u v w ", +" x y z z z z z z A z B C ", +" D ", +" E F G H I J K L M N O P ", +" Q R S T U V W X Y Z U ` Q ", +" ...+._ @.#.$.%.&.*.=.-.;. ", +" >.>.>.,.'.).).).).).!.~. "}; diff -Nru xterm-278/icons/filled-xterm_32x32.xpm xterm-297/icons/filled-xterm_32x32.xpm --- xterm-278/icons/filled-xterm_32x32.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/filled-xterm_32x32.xpm 2012-10-07 22:55:44.000000000 +0000 @@ -0,0 +1,260 @@ +/* XPM */ +static char * filled_xterm_32x32_xpm[] = { +"32 32 225 2", +" c None", +". c #000000", +"+ c #D9C2C2", +"@ c #EEE5E5", +"# c #EBE0E0", +"$ c #EBE1E1", +"% c #EDE1E1", +"& c #918484", +"* c #FFEEEE", +"= c #F2DCDC", +"- c #403838", +"; c #5A5A5A", +"> c #5B4545", +", c #FEF2F2", +"' c #E9E9E9", +") c #856868", +"! c #271D1D", +"~ c #FBCFCF", +"{ c #746060", +"] c #FFFBFB", +"^ c #FFFFFF", +"/ c #FAF0F0", +"( c #5E4949", +"_ c #E3DCDC", +": c #BAA8A8", +"< c #292020", +"[ c #F1C0C0", +"} c #D9C6C6", +"| c #FFECEC", +"1 c #FFE8E8", +"2 c #FFFAFA", +"3 c #FFF0F0", +"4 c #FFEFEF", +"5 c #705D5D", +"6 c #DED5D5", +"7 c #F9E6E6", +"8 c #D3C3C3", +"9 c #392F2F", +"0 c #FCF6F6", +"a c #BAA7A7", +"b c #524646", +"c c #D9D1D1", +"d c #F2EAEA", +"e c #796666", +"f c #FEF7F7", +"g c #BBAAAA", +"h c #918383", +"i c #1D1515", +"j c #EBDADA", +"k c #B5B5B5", +"l c #FFF4F4", +"m c #DDD0D0", +"n c #110A0A", +"o c #FEFBFB", +"p c #D3C7C7", +"q c #FFF3F3", +"r c #968484", +"s c #F2E9E9", +"t c #908484", +"u c #FFFDFD", +"v c #A89191", +"w c #776262", +"x c #CCB4B4", +"y c #9E7979", +"z c #705F5F", +"A c #FFCCCC", +"B c #FFEAEA", +"C c #FFE6E6", +"D c #FFF1F1", +"E c #FFFEFE", +"F c #FFE1E1", +"G c #FFF2F2", +"H c #FFF7F7", +"I c #C7B8B8", +"J c #AE9494", +"K c #5A4848", +"L c #C0AFAF", +"M c #D1BDBD", +"N c #4F3D3D", +"O c #513636", +"P c #BCB0B0", +"Q c #665757", +"R c #1A0C0C", +"S c #E4DCDC", +"T c #FCF3F3", +"U c #1F0C0C", +"V c #C3C3C3", +"W c #726363", +"X c #443A3A", +"Y c #FFF8F8", +"Z c #583D3D", +"` c #FCF4F4", +" . c #615757", +".. c #6C5656", +"+. c #A09393", +"@. c #9B8E8E", +"#. c #856464", +"$. c #4A3F3F", +"%. c #BBBBBB", +"&. c #C0BCBC", +"*. c #452F2F", +"=. c #736C6C", +"-. c #775656", +";. c #878787", +">. c #A38888", +",. c #624D4D", +"'. c #C9B4B4", +"). c #F8F0F0", +"!. c #FFEDED", +"~. c #604242", +"{. c #B5A8A8", +"]. c #FAE9E9", +"^. c #FBF3F3", +"/. c #BAB2B2", +"(. c #F8DEDE", +"_. c #7F6F6F", +":. c #B5A2A2", +"<. c #806F6F", +"[. c #AA8E8E", +"}. c #FEFDFD", +"|. c #BD9F9F", +"1. c #C3B4B4", +"2. c #E0DCDC", +"3. c #F9EEEE", +"4. c #080303", +"5. c #F3C1C1", +"6. c #B7A2A2", +"7. c #4C3A3A", +"8. c #DFD6D6", +"9. c #7E6D6D", +"0. c #FFE9E9", +"a. c #B39A9A", +"b. c #BBA5A5", +"c. c #DEC9C9", +"d. c #715D5D", +"e. c #F3DDDD", +"f. c #8B7979", +"g. c #060303", +"h. c #FFEBEB", +"i. c #EFE9E9", +"j. c #EAEAEA", +"k. c #FAEFEF", +"l. c #D1C3C3", +"m. c #0B0707", +"n. c #312222", +"o. c #584141", +"p. c #685252", +"q. c #5D5858", +"r. c #5F5F5F", +"s. c #5B5B5B", +"t. c #5C5858", +"u. c #473232", +"v. c #181111", +"w. c #ECD8D8", +"x. c #F9EFEF", +"y. c #DBC6C6", +"z. c #DEC5C5", +"A. c #F7EDED", +"B. c #DCC4C4", +"C. c #F8EDED", +"D. c #DEC3C3", +"E. c #E0C9C9", +"F. c #DEC1C1", +"G. c #DBC7C7", +"H. c #F7E8E8", +"I. c #E1CACA", +"J. c #DBC2C2", +"K. c #F8EFEF", +"L. c #796868", +"M. c #422B2B", +"N. c #B5A3A3", +"O. c #F8ECEC", +"P. c #F8EEEE", +"Q. c #FDF7F7", +"R. c #FEF9F9", +"S. c #F7EAEA", +"T. c #FDF6F6", +"U. c #F7EBEB", +"V. c #FDF5F5", +"W. c #F7EEEE", +"X. c #F8EBEB", +"Y. c #786565", +"Z. c #2C2121", +"`. c #F6E9E9", +" + c #F6E8E8", +".+ c #F9EDED", +"++ c #FEFCFC", +"@+ c #F7ECEC", +"#+ c #F7E9E9", +"$+ c #837070", +"%+ c #806C6C", +"&+ c #D4C3C3", +"*+ c #DCC8C8", +"=+ c #DDC2C2", +"-+ c #DBBFBF", +";+ c #E1C8C8", +">+ c #DEC8C8", +",+ c #DEC7C7", +"'+ c #DFC8C8", +")+ c #DEBBBB", +"!+ c #FAEEEE", +"~+ c #221B1B", +"{+ c #3E3131", +"]+ c #F8E8E8", +"^+ c #8D8181", +"/+ c #F6E7E7", +"(+ c #696969", +"_+ c #6D6D6D", +":+ c #6F6C6C", +"<+ c #835D5D", +"[+ c #875D5D", +"}+ c #9D7474", +"|+ c #A27A7A", +"1+ c #958989", +"2+ c #919191", +"3+ c #9D9797", +"4+ c #917E7E", +"5+ c #E3C8C8", +"6+ c #241B1B", +"7+ c #695959", +"8+ c #CEBCBC", +"9+ c #D1D1D1", +"0+ c #CFCBCB", +"a+ c #322424", +"b+ c #201818", +" ", +" . + @ # $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ % @ & . ", +" . * = - ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; > , ' ) ! ", +" . ~ { ] ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ / ( _ : / < ", +" . [ } | 1 1 2 3 1 4 ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ 7 . ", +" . [ } 8 9 0 a b * ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ 4 . ", +" . [ } ^ c d e f ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 g ^ 4 . ", +" . [ } ^ ^ h i j ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ l . ", +" . [ } ^ ^ m n | ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ ^ . ", +" . [ } ^ o { p q ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ ^ . ", +" . [ } ^ r s ^ t u ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 k ^ ^ . ", +" . [ } v w x ^ y z A ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ ^ . ", +" . [ } ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 5 6 : ^ ^ . ", +" . [ } B C C C D C C C E F G G ^ l C ^ ^ H ] 5 6 : ^ ^ . ", +" . [ } I J K L M N L L E O P Q l B R S T U V 5 6 : ^ ^ . ", +" . [ } ^ * W ^ * X ^ Y ^ Z ` .q B ..+.@.#.V 5 6 : ^ ^ . ", +" . [ } ^ * W ^ * $.%.&.^ *.=.-.u B ;.>.,.'.V 5 6 : ^ ).. ", +" . [ } ^ * W ^ * ,.!.!.E ~.^ {.].B ;.^./.(.V 5 6 : ^ _. ", +" . [ } ^ q :.^ l <.<.<.E [.^ }.|.3 1.^ ^ B 2.5 6 : 3.4. ", +" . 5.6.^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ] 7.8.: 9. ", +" . 0.a.b.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.c.d.e.' f.g. ", +" . h.2 i.j.j.j.j.j.j.j.j.j.j.j.j.j.j.j.j.j.k.^ l.m. ", +" . . . . . . . . . . . . . . . . . . . . . . . ", +" ", +" n.o.p.p.p.p.q.; r.s.; ; ; t.p.p.p.p.p.p.p.p.u.. ", +" v.w.x.y.z.A.3.} B.C.3.D.E.C.C.F.G.C.H.I.J.C.K.L.M. ", +" N.O.P.Q.R.S.S.f T.U.S.V.f W.A.Q.Q.P.P.Q.f O.X._.Y. ", +" Z.Y `. +V.f .+A.T.Q.O..+++V.K.@+f f #+A.R.V.`.$+x.%+ ", +" &+B.X.).*+=+C.#+-+;+C.O.>+,+U.#+'+)+@+#+F.*+!+9.k.~+ ", +" {+]+^+/+(+_+_+_+_+_+_+_+_+:+<+[+}+|+1+2+3+S.^+4+5+6+ ", +" 7+8+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+9+0+a+b+ ", +" "}; diff -Nru xterm-278/icons/filled-xterm_48x48.xpm xterm-297/icons/filled-xterm_48x48.xpm --- xterm-278/icons/filled-xterm_48x48.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/filled-xterm_48x48.xpm 2012-10-07 22:55:12.000000000 +0000 @@ -0,0 +1,297 @@ +/* XPM */ +static char * filled_xterm_48x48_xpm[] = { +"48 48 246 2", +" c None", +". c #000000", +"+ c #F6D5D5", +"@ c #FFEAEA", +"# c #FFD6D6", +"$ c #FFD2D2", +"% c #FFD3D3", +"& c #F8D6D6", +"* c #FFEFEF", +"= c #FFFFFF", +"- c #F6DBDB", +"; c #0F0707", +"> c #090505", +", c #F6DCDC", +"' c #FFEEEE", +") c #C99999", +"! c #030101", +"~ c #F7DEDE", +"{ c #150B0B", +"] c #E3C5C5", +"^ c #FFEDED", +"/ c #E4CBCB", +"( c #140B0B", +"_ c #F7DDDD", +": c #E0C9C9", +"< c #080303", +"[ c #FFD9D9", +"} c #0D0707", +"| c #E5CACA", +"1 c #E5CBCB", +"2 c #0B0606", +"3 c #FFDCDC", +"4 c #E2CECE", +"5 c #090303", +"6 c #E1CBCB", +"7 c #9F8A8A", +"8 c #3B2929", +"9 c #312020", +"0 c #FFD5D5", +"a c #ECC8C8", +"b c #402525", +"c c #351F1F", +"d c #663E3E", +"e c #E6DBDB", +"f c #FFFAFA", +"g c #FFFEFE", +"h c #8C7272", +"i c #B4A1A1", +"j c #A69494", +"k c #D8C0C0", +"l c #675353", +"m c #FFFDFD", +"n c #584545", +"o c #E1BFBF", +"p c #3C2929", +"q c #FCF3F3", +"r c #F6EAEA", +"s c #160F0F", +"t c #E9D3D3", +"u c #6E5C5C", +"v c #D6BABA", +"w c #CBBBBB", +"x c #0D0808", +"y c #F8E8E8", +"z c #FFE2E2", +"A c #F4EDED", +"B c #FFF2F2", +"C c #4B3A3A", +"D c #FFFBFB", +"E c #AD9292", +"F c #FFE1E1", +"G c #A28E8E", +"H c #CCBDBD", +"I c #8B7777", +"J c #231515", +"K c #ECCECE", +"L c #FFDADA", +"M c #251414", +"N c #9A8686", +"O c #FFF1F1", +"P c #FFECEC", +"Q c #FFE4E4", +"R c #FFDFDF", +"S c #FFDBDB", +"T c #FFF0F0", +"U c #FFDDDD", +"V c #FFEBEB", +"W c #FFF4F4", +"X c #FFE5E5", +"Y c #FFDEDE", +"Z c #B29E9E", +"` c #A08F8F", +" . c #8A7373", +".. c #1C1111", +"+. c #D7CACA", +"@. c #645555", +"#. c #5E4B4B", +"$. c #FFF7F7", +"%. c #BD9F9F", +"&. c #392B2B", +"*. c #A19090", +"=. c #867474", +"-. c #9C8D8D", +";. c #A99494", +">. c #0E0606", +",. c #FFE9E9", +"'. c #D5C6C6", +"). c #564545", +"!. c #FFE7E7", +"~. c #5B3D3D", +"{. c #352121", +"]. c #5B4242", +"^. c #FFD7D7", +"/. c #E7D2D2", +"(. c #1F1313", +"_. c #786363", +":. c #AC9191", +"<. c #FFE8E8", +"[. c #DBC7C7", +"}. c #897474", +"|. c #574E4E", +"1. c #999999", +"2. c #FFF6F6", +"3. c #170F0F", +"4. c #3B2B2B", +"5. c #190E0E", +"6. c #C7B6B6", +"7. c #5F4D4D", +"8. c #F6E1E1", +"9. c #FCE9E9", +"0. c #F1EAEA", +"a. c #FEFAFA", +"b. c #3D2828", +"c. c #382626", +"d. c #947D7D", +"e. c #FFFCFC", +"f. c #B09B9B", +"g. c #C2B2B2", +"h. c #EEDADA", +"i. c #FDEFEF", +"j. c #0B0505", +"k. c #DACACA", +"l. c #7D6565", +"m. c #C6A7A7", +"n. c #FDF9F9", +"o. c #6C4D4D", +"p. c #AB9797", +"q. c #927B7B", +"r. c #FCEDED", +"s. c #0A0404", +"t. c #120B0B", +"u. c #E8D1D1", +"v. c #E2CACA", +"w. c #0F0808", +"x. c #907979", +"y. c #F9DFDF", +"z. c #1D1111", +"A. c #E8D0D0", +"B. c #E1C8C8", +"C. c #1A0C0C", +"D. c #F8E0E0", +"E. c #F7D4D4", +"F. c #090404", +"G. c #FAE1E1", +"H. c #100A0A", +"I. c #100808", +"J. c #7C4F4F", +"K. c #F6D3D3", +"L. c #FFD8D8", +"M. c #F8D5D5", +"N. c #AF9393", +"O. c #FDE5E5", +"P. c #FDE9E9", +"Q. c #FDE2E2", +"R. c #FDF8F8", +"S. c #FDE6E6", +"T. c #FEECEC", +"U. c #FEE5E5", +"V. c #FFE6E6", +"W. c #F8D1D1", +"X. c #0D0404", +"Y. c #291D1D", +"Z. c #583030", +"`. c #FFF8F8", +" + c #683737", +".+ c #5B3333", +"++ c #582D2D", +"@+ c #593030", +"#+ c #5D3232", +"$+ c #5A2D2D", +"%+ c #663737", +"&+ c #5B3030", +"*+ c #897272", +"=+ c #996F6F", +"-+ c #DBC1C1", +";+ c #110808", +">+ c #FDDDDD", +",+ c #473636", +"'+ c #563232", +")+ c #FFF5F5", +"!+ c #5C3636", +"~+ c #FFF9F9", +"{+ c #582E2E", +"]+ c #6F4040", +"^+ c #5B3434", +"/+ c #6D3E3E", +"(+ c #5A3333", +"_+ c #EFD7D7", +":+ c #FCEFEF", +"<+ c #140A0A", +"[+ c #6A5252", +"}+ c #583333", +"|+ c #5C2A2A", +"1+ c #653737", +"2+ c #6B3C3C", +"3+ c #643434", +"4+ c #6A3C3C", +"5+ c #613535", +"6+ c #9C8787", +"7+ c #907A7A", +"8+ c #DDC3C3", +"9+ c #F8E5E5", +"0+ c #FDF3F3", +"a+ c #190D0D", +"b+ c #FAEAEA", +"c+ c #DCC4C4", +"d+ c #876E6E", +"e+ c #461F1F", +"f+ c #472020", +"g+ c #261414", +"h+ c #070000", +"i+ c #220000", +"j+ c #230101", +"k+ c #3A1818", +"l+ c #3F1D1D", +"m+ c #3E1E1E", +"n+ c #553333", +"o+ c #724646", +"p+ c #431F1F", +"q+ c #AB8F8F", +"r+ c #887171", +"s+ c #DAC0C0", +"t+ c #FBD1D1", +"u+ c #1A1010", +"v+ c #B27C7C", +"w+ c #020101", +" ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" . + @ @ # $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ % @ @ & . . ", +" . * = - ; . . . . . . . . . . . . . . . . . . . . . . . . . . > , = ' . ) ! ", +" . * ~ { ] ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ / ( _ ' . ^ : < ", +" . [ } | = = = = = = = = = = = = = = = = = = = = = = = = = = = = 1 2 3 . ^ = 4 5 ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ^ = = 6 . ", +" . [ . * 7 8 9 0 = a b c d = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = e f = g h i = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = j = k l g = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = m n o p q = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = r s . t = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = = u . v = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = w x y = = = = = = = = = = = = = = = = = = = = * . [ . z = = * . ", +" . [ . * = = A B B C D = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = E z = = F G = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * H I J K = = L M } N O = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * P Q Q R = = S Q Q Q T = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ' = = * . ", +" . [ . * [ U U U U U V z U U U U W X Y X ^ = = V U O = = O F ' * . [ . ' = = * . ", +" . [ . * Z ` ...` Q +.@.#.` ` Q $.%.&.*.=. ^ = -. = = ;.>.,.* . [ . ' = = * . ", +" . [ . * = = '. = = = Q = = = = %. = = ).!.= -.~. f f {.].,.* . [ . ' = = * . ", +" . [ . * = = '. = = = U U ^.= %. ^ /.(.' = -._.:.<.[.}.@.,.* . [ . ' = = * . ", +" . [ . * = = '. = = = @.|.1.1.2.= %.3.4.5. = = -. 6. 7.8.@.,.* . [ . ' = = 9.. ", +" . [ . * = = '. = = = Q = = = = %. = 0. ' = -. a.b.c.f @.,.* . [ . ' = = d.. ", +" . [ . * = = '. = = = 0 ^ ^ ^ e.%. = = f. m -. = g.h.= @.,.* . [ . ' = i.j. ", +" . [ . * = = k. = = = l.9 9 9 ' m. = = n.o.z p. = = = = l.X * . [ . ' = q.. ", +" . [ . * = = = = = = = = = = = = = = = = = = = = = = = = = = = = * . [ . ' r.s. ", +" . 3 t.u.= = = = = = = = = = = = = = = = = = = = = = = = = = = = v.w.S . ' x.. ", +" . * y.z.A.^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ B.C.D.' . E.F. ", +" . * = G.H.. . . . . . . . . . . . . . . . . . . . . . . . . . I.D.= ' . J.. ", +" . K.P P # $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ L.P P M.. . ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" ", +" ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" . N.O.P.O.P.Q.R.S.P.O.P.O.P.O.T.U.T.U.T.,.^ ,.^ ,.^ V.^ ,.= D W ,.^ W.X.. ", +" Y.W Z.`. +e..+e.++D @+$.Z.`. +e.#+e.$+D @+$.Z.`.%+e.#+e.$+e.&+$.Z.D *+=+. ", +" . -+D f e.m D `.= D e.D D f D m D `.= D e.D D f D m D `.= D e.D D f r.;+>+. ", +" ,+`.'+)+!+~+{+= ]+f .+`.Z.)+^+~+{+= /+f .+`.Z.)+^+~+{+= /+f (+`.Z.f q.q.T . ", +" . _+m f = D m ~+e.`.m f m f = D m ~+e.`.m f e.f = D m ~+e.`.m f m f :+<+i.T . ", +" . [+~+}+)+|+~+1+g 2+g 3+`.}+)+|+~+1+g 4+= 3+`.}+)+|+~+1+g 4+= 3+~+5+e.6+7+= 8+. ", +" ! 9+= ~+= T ' @ ' ,.' <.' <.' ' ' @ e.f = ~+= ~+= = = D = f = ~+= = 0+a+b+c+! ", +" . d+m e+f+e.g+. . . . . . . . . . . . h+i+i+j+k+l+l+c m+l+l+n+o+e.e+p+q+r+s+! ", +" . t+* @ @ P S [ L S S S S S S S S S S z ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ P z u+v+w+ ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" "}; diff -Nru xterm-278/icons/make-xpms xterm-297/icons/make-xpms --- xterm-278/icons/make-xpms 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/make-xpms 2012-10-07 22:50:56.000000000 +0000 @@ -0,0 +1,26 @@ +#!/bin/sh +# $XTermId: make-xpms,v 1.6 2012/10/07 22:50:56 tom Exp $ +# some files are generated from other icons... +for name in mini.xterm filled-xterm xterm xterm-color +do + target=${name}.xpms + NAME=`echo "$target" | sed -e 's/[\.-]/_/g'` + LIST= + echo "** creating $target" + rm -f $target + echo "/* @XTermId@ */" | sed -e 's/@/$/g' >$target + echo "/* generated by $0 $* */" >>$target + echo "/* vile:xpmmode */" >>$target + for source in ${name}_*[0-9]x[1-9]*.xpm + do + echo ".. from $source" + BASE=`basename "$source" .xpm` + PART=`echo "$source" | sed -e 's/[\.-]/_/g'` + test -n "$LIST" && LIST="$LIST, " + LIST="$LIST + { \"$BASE\", $PART }" + sed -e 's/char \*/const char * const/' $source >>$target + done + echo "static const XPM_DATA $NAME[] = {$LIST +};" >>$target +done diff -Nru xterm-278/icons/mini.xterm.svg xterm-297/icons/mini.xterm.svg --- xterm-278/icons/mini.xterm.svg 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/mini.xterm.svg 2012-10-06 16:14:28.000000000 +0000 @@ -0,0 +1,128 @@ + + + + + + + + + + + + + + image/svg+xml + + XTerm mini-icon + August 21, 2012 + + + Thomas E. Dickey + + + + + + + + + + + + + + + X + + + T + + diff -Nru xterm-278/icons/mini.xterm.xpms xterm-297/icons/mini.xterm.xpms --- xterm-278/icons/mini.xterm.xpms 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/mini.xterm.xpms 2012-10-07 20:42:50.000000000 +0000 @@ -0,0 +1,553 @@ +/* $XTermId: mini.xterm.xpms,v 1.4 2012/10/07 20:42:50 tom Exp $ */ +/* generated by ./make-xpms */ +/* vile:xpmmode */ +/* XPM */ +static const char * const mini_xterm_16x16_xpm[] = { +"16 16 84 1", +" c None", +". c #FF3200", +"+ c #FF3C00", +"@ c #FF3F00", +"# c #FF3B00", +"$ c #FF3800", +"% c #FF2000", +"& c #FF1100", +"* c #FF3D00", +"= c #FF3900", +"- c #FF2200", +"; c #FF0A00", +"> c #FF5D00", +", c #FF1300", +"' c #FF0500", +") c #D0412F", +"! c #DD6722", +"~ c #DA3E25", +"{ c #D84727", +"] c #D03C2F", +"^ c #0023F3", +"/ c #000BF2", +"( c #0E21E6", +"_ c #4433B4", +": c #352EC3", +"< c #0010F2", +"[ c #0004F1", +"} c #2C33CB", +"| c #3E2ABA", +"1 c #011EF3", +"2 c #0012F3", +"3 c #022DF5", +"4 c #F2140D", +"5 c #FF5E00", +"6 c #052AF0", +"7 c #0013F3", +"8 c #DD4822", +"9 c #002CF5", +"0 c #004FF7", +"a c #003AF6", +"b c #1529E1", +"c c #D83827", +"d c #0037F7", +"e c #004CF8", +"f c #FF5900", +"g c #182EDE", +"h c #FF2100", +"i c #152CE1", +"j c #DD3B22", +"k c #FF2300", +"l c #FF2A00", +"m c #0C28E9", +"n c #E1571E", +"o c #FF2E00", +"p c #012AF4", +"q c #E1661E", +"r c #FF3600", +"s c #FF3500", +"t c #0028F4", +"u c #0011F2", +"v c #D64E29", +"w c #FF5C00", +"x c #FF2B00", +"y c #FF1D00", +"z c #FF2F00", +"A c #000EF2", +"B c #0003F1", +"C c #8C4072", +"D c #FF4C00", +"E c #FF2D00", +"F c #0360F6", +"G c #0031F6", +"H c #0016F3", +"I c #0827EE", +"J c #3D47BE", +"K c #E5631A", +"L c #FF4300", +"M c #FF3E00", +"N c #FF2400", +"O c #FF0700", +"P c #FF3400", +"Q c #FF5700", +"R c #FF5600", +"S c #FF3700", +" .+@#$% &$$*=- ", +" ;>#, '+ ", +" )!~ {] ", +" ^/(_:<[}|1/2 ", +" 2345=678 97 ", +" 0a =>b7c de ", +" fg7 ", +" hg7 ", +" $i7j ", +" klm7no ", +" # p7qr ", +" sk tuvwx ", +" yz ABCfDE ", +" = FGHHIJKr ", +" $LM$N O$PQRS- ", +" "}; +/* XPM */ +static const char * const mini_xterm_32x32_xpm[] = { +"32 32 143 2", +" c None", +". c #FF0000", +"+ c #FF1900", +"@ c #FF1F00", +"# c #FF0B00", +"$ c #FF1D00", +"% c #FF4A00", +"& c #FF5100", +"* c #FF5B00", +"= c #FF5E00", +"- c #FF5300", +"; c #FF3600", +"> c #FF0C00", +", c #FF5A00", +"' c #FF5C00", +") c #FF0A00", +"! c #FF0D00", +"~ c #FF2E00", +"{ c #FF5800", +"] c #FF2700", +"^ c #FF0500", +"/ c #0073FB", +"( c #0041F7", +"_ c #0074FB", +": c #0059F9", +"< c #0000F1", +"[ c #0505EC", +"} c #3A44BE", +"| c #615A9A", +"1 c #784285", +"2 c #3466C8", +"3 c #004DF8", +"4 c #0053F8", +"5 c #006CF9", +"6 c #3C44BD", +"7 c #2729CF", +"8 c #002CF5", +"9 c #2D2EC9", +"0 c #8D6E71", +"a c #E96416", +"b c #FF4400", +"c c #FF1800", +"d c #0019F3", +"e c #FF1400", +"f c #D66729", +"g c #73498A", +"h c #091FEB", +"i c #002CF4", +"j c #006FFC", +"k c #0002F1", +"l c #0059F8", +"m c #AD3252", +"n c #FF1700", +"o c #FF2B00", +"p c #B84A47", +"q c #0026F4", +"r c #FF0700", +"s c #FF1600", +"t c #003FF6", +"u c #0003F1", +"v c #006FFA", +"w c #0058F9", +"x c #0055FA", +"y c #FF3D00", +"z c #C3363C", +"A c #FF0400", +"B c #FF3F00", +"C c #FF1000", +"D c #003DF6", +"E c #005AF8", +"F c #002AF4", +"G c #FF0100", +"H c #FF5600", +"I c #C3643C", +"J c #A73958", +"K c #FF3100", +"L c #0020F3", +"M c #002DF5", +"N c #0089FD", +"O c #0022F4", +"P c #0085FD", +"Q c #C36E3C", +"R c #BC3943", +"S c #FF1300", +"T c #007AFC", +"U c #FF2200", +"V c #C3693C", +"W c #FF4600", +"X c #C3563C", +"Y c #FF1100", +"Z c #BD6C42", +"` c #C12F3E", +" . c #B13B4E", +".. c #C32F3C", +"+. c #C0283F", +"@. c #C34D3C", +"#. c #FF2400", +"$. c #BC3E43", +"%. c #C36D3C", +"&. c #FF3400", +"*. c #FF0800", +"=. c #C36B3C", +"-. c #FF4E00", +";. c #C3523C", +">. c #FF3E00", +",. c #FF1C00", +"'. c #FF0200", +"). c #BF3240", +"!. c #FF1A00", +"~. c #B4624B", +"{. c #FF5900", +"]. c #FF1200", +"^. c #B82E47", +"/. c #FF4800", +"(. c #FF3A00", +"_. c #001EF4", +":. c #001DF4", +"<. c #7D4882", +"[. c #FF4F00", +"}. c #0076FB", +"|. c #000CF2", +"1. c #0276F9", +"2. c #FF3800", +"3. c #FF5D00", +"4. c #004CF7", +"5. c #004CF8", +"6. c #FB0104", +"7. c #FF5500", +"8. c #B53E4A", +"9. c #0055F8", +"0. c #0038F6", +"a. c #0028F4", +"b. c #0039F6", +"c. c #0254F6", +"d. c #C66E39", +"e. c #FF3500", +"f. c #248ADB", +"g. c #785587", +"h. c #DE3121", +"i. c #FF1E00", +"j. c #FF2800", +"k. c #FF5700", +"l. c #FF1B00", +" ", +" ", +" . + @ @ @ @ @ @ @ @ @ # $ . @ @ @ @ @ @ @ @ . ", +" . % & & * = = = - & & ; @ > & & & , ' & & & ) ", +" . . . . ! = = = ~ . . . . . . . { ] ^ . . . ", +" / ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( _ ", +" : < < < [ } | 1 2 3 < < < < 4 5 6 7 < < < < : ", +" 8 < < 9 0 a = b c d < < d e f g h < < i ", +" j k < l m n = = = o p q < < q r { ] s t < u v ", +" w < x . y = = ' z q < < q A % B C D < E ", +" 8 F G H = = I q < < q J K & ! L M ", +" N O P r = = Q q < < q R ' S T O N ", +" . U = Q q < < q V ] s ", +" . W Q q < < q X Y ", +" G Z q < < q ` ", +" .q < < q .. ", +" +.q < < q @.#. ", +" $.q < < q %.+ &. ", +" *.=.q < < q Q - Y ", +" A -.;.q < < q Q = >.,. ", +" '.; -.).q < < q Q = = U ~ ", +" !., Y q < < q ~.= = {.]. ", +" *., U q < < q ^., = = /.s ", +" A -.(.]. _.< < :.<.C = = = ~ ] ", +" '.; [.! }.|.< < |.1.. 2.= = 3.s ", +" !., Y 4.< < < < 5. 6.7.= = & ]. ", +" *., U 8.9.0.a.< < < < < < a.b.c.d.= = (.@ ", +" A -.e.# f. g.h.= = = i.j. ", +" . @ @ ,.y , Y ,.@ @ G '.@ ,.].* = = k.l.@ @ . ", +" . & & & & & & & & & ) ,.& & & & & & & & & & ) ", +" . . . . . . . . . . . . . . . . . . . . . . . ", +" "}; +/* XPM */ +static const char * const mini_xterm_48x48_xpm[] = { +"48 48 213 2", +" c None", +". c #FF0000", +"+ c #FF5300", +"@ c #FF5E00", +"# c #FF4800", +"$ c #FF4200", +"% c #FF4000", +"& c #FF4B00", +"* c #FF5200", +"= c #FF5400", +"- c #FF3500", +"; c #FF5100", +"> c #FF5C00", +", c #FF3000", +"' c #FF4500", +") c #FF2000", +"! c #FF0300", +"~ c #FF1600", +"{ c #FF5D00", +"] c #FF3800", +"^ c #FF0200", +"/ c #FF0900", +"( c #FF2B00", +"_ c #FF3300", +": c #FF1A00", +"< c #FF1300", +"[ c #FF1200", +"} c #FF5700", +"| c #4577BA", +"1 c #874E78", +"2 c #887577", +"3 c #887E77", +"4 c #887977", +"5 c #875078", +"6 c #566CA9", +"7 c #5E70A1", +"8 c #884E77", +"9 c #887677", +"0 c #7C5B83", +"a c #795686", +"b c #008DFE", +"c c #0012F3", +"d c #000BF2", +"e c #008FFE", +"f c #006CFA", +"g c #0000F1", +"h c #0001F1", +"i c #0020F4", +"j c #0040F6", +"k c #0959F0", +"l c #1158E8", +"m c #1159E8", +"n c #0058F9", +"o c #001DF4", +"p c #0023F4", +"q c #005BFA", +"r c #0060FA", +"s c #0E58EB", +"t c #0651F3", +"u c #0033F5", +"v c #000EF2", +"w c #006EFA", +"x c #0092FF", +"y c #001FF4", +"z c #000FF2", +"A c #0C51EC", +"B c #326AC9", +"C c #7A6583", +"D c #CA6234", +"E c #FC5F03", +"F c #FF5800", +"G c #FF0800", +"H c #F4060B", +"I c #007CFB", +"J c #0013F3", +"K c #007EFB", +"L c #FF1800", +"M c #F3590C", +"N c #AB6152", +"O c #4F4EAD", +"P c #175CE4", +"Q c #0036F5", +"R c #0022F4", +"S c #0095FD", +"T c #0084FD", +"U c #0004F1", +"V c #0051F8", +"W c #345AC7", +"X c #E61519", +"Y c #FF5900", +"Z c #FF4600", +"` c #FF0100", +" . c #446EB9", +".. c #0034F6", +"+. c #0032F5", +"@. c #FF2200", +"#. c #006FFA", +"$. c #002DF5", +"%. c #0086FD", +"&. c #0046F7", +"*. c #0015F3", +"=. c #0076FC", +"-. c #FF0400", +";. c #FF2300", +">. c #FF2900", +",. c #9E3E61", +"'. c #0039F6", +"). c #FF2A00", +"!. c #FF4300", +"~. c #0071FB", +"{. c #005EF9", +"]. c #004DF7", +"^. c #008CFE", +"/. c #0008F2", +"(. c #001DF3", +"_. c #007DFB", +":. c #FF4100", +"<. c #FF5B00", +"[. c #A3425C", +"}. c #994C66", +"|. c #FF1100", +"1. c #0072FB", +"2. c #000AF2", +"3. c #006EFC", +"4. c #0017F3", +"5. c #007FFB", +"6. c #FF0600", +"7. c #FF5600", +"8. c #A56A5A", +"9. c #A53B5A", +"0. c #FF4F00", +"a. c #0076FB", +"b. c #0076FA", +"c. c #0093FF", +"d. c #007DFC", +"e. c #FF1C00", +"f. c #A5765A", +"g. c #A55D5A", +"h. c #006FFB", +"i. c #002CF5", +"j. c #008AFD", +"k. c #006BF9", +"l. c #FF3A00", +"m. c #FF5000", +"n. c #007BFB", +"o. c #008BFD", +"p. c #A5755A", +"q. c #9A5565", +"r. c #A43A5B", +"s. c #FF4D00", +"t. c #80507F", +"u. c #FF0F00", +"v. c #7A5485", +"w. c #A5555A", +"x. c #FF0A00", +"y. c #A53D5A", +"z. c #A4515B", +"A. c #A5685A", +"B. c #A5735A", +"C. c #FF0700", +"D. c #FF2E00", +"E. c #FF1500", +"F. c #A3705C", +"G. c #FF0500", +"H. c #9A4965", +"I. c #FF0E00", +"J. c #FF3B00", +"K. c #FF2D00", +"L. c #A13C5E", +"M. c #FF4C00", +"N. c #62649D", +"O. c #FF0B00", +"P. c #FF4700", +"Q. c #FF1D00", +"R. c #A56D5A", +"S. c #FF2C00", +"T. c #A4465B", +"U. c #FF1400", +"V. c #A03E61", +"W. c #FF3100", +"X. c #FF1B00", +"Y. c #FF1000", +"Z. c #0029F5", +"`. c #0027F4", +" + c #4571BA", +".+ c #FF3900", +"++ c #FF3200", +"@+ c #008EFD", +"#+ c #0019F3", +"$+ c #0090FD", +"%+ c #FF0D00", +"&+ c #FF1E00", +"*+ c #FF4E00", +"=+ c #0088FC", +"-+ c #0087FC", +";+ c #FF1900", +">+ c #0036F6", +",+ c #FF2100", +"'+ c #0073FB", +")+ c #0062FA", +"!+ c #001AF3", +"~+ c #2463D8", +"{+ c #3E58BE", +"]+ c #2A7FD3", +"^+ c #807B7F", +"/+ c #008EFB", +"(+ c #006AFA", +"_+ c #004CF8", +":+ c #717B8D", +"<+ c #EE0B11", +"[+ c #F73E08", +"}+ c #FF1F00", +"|+ c #FF5500", +" ", +" ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" . + @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ . . # @ @ @ @ @ @ @ @ @ @ @ @ $ . ", +" . % & & & * @ @ @ @ @ = & & & & & . . - & & & & & ; @ > & & & & , . ", +" . . . . . . * @ @ @ @ ; . . . . . . . . . . . . . ' @ ) . . . . . . ", +" ! ~ { @ @ @ @ ] ^ / ( @ $ . ", +" ^ _ @ @ @ @ @ : ! < [ > } ^ . ", +" | 1 2 3 3 3 3 4 5 6 7 8 9 3 0 a ", +" b c d d d d d d d d d d d d d d d d d d d d d d d d d d d d d d d d c e ", +" f g g g g g g h i j k l m n o g g g g g g p q r s t u v g g g g g g g w ", +" x y g g g g z A B C D E F G H I c g g g g J K L / M N O P Q h g g g g R S ", +" T g g g U V W X Y @ @ @ @ Z ` ...g g g g +. ` ' @ @.. #.$.g g g g %. ", +" &.g g *.=. -.;.@ @ @ @ @ >.,.'.g g g g '. / ).@ !.. ~.{.U g g ]. ", +" ^./.g (._. ` :.@ @ @ @ <.[.'.g g g g '.}.|.<.} ^ . 1.2.g d e ", +" 3.g 4.5. 6.7.@ @ @ @ 8.'.g g g g '.9.0.@ [ . a./.g b. ", +" c.R /.d. -.e.@ @ @ @ f.'.g g g g '.g.@ - . h.h i. ", +" j.k.%. ^ l.@ @ @ f.'.g g g g '.f.m.` n.f o. ", +" ! * @ @ f.'.g g g g '.p.G . ", +" ! ~ { @ f.'.g g g g '.q.. ", +" ^ _ @ f.'.g g g g '.r. ", +" ^ s.f.'.g g g g '.t. ", +" ^ u.p.'.g g g g '.v. ", +" ^ w.'.g g g g '.r. ", +" x.y.'.g g g g '.z.^ ", +" ` A.'.g g g g '.B.x.. ", +" C.D.f.'.g g g g '.f.# ` ", +" < E.{ F.'.g g g g '.f.@ ( ^ ", +" : G.; @ H.'.g g g g '.f.@ <.I.^ ", +" -.J.@ K.L.'.g g g g '.f.@ @ s.` ", +" I.) @ M.. N.'.g g g g '.f.@ @ @ _ ^ ", +" L O.F <.6.. '.g g g g '.f.@ @ @ { E.! ", +" ^ P.@ Q.. '.g g g g '.R.@ @ @ @ * ! ", +" G S.@ % . '.g g g g '.T.{ @ @ @ @ l.^ ", +" < U.> 7.^ ..g g g g u V.W.@ @ @ @ @ e.! ", +" X.-.m.@ Y.. Z.g g g g `. +` M.@ @ @ @ 7.6. ", +" -..+@ ++. @+#+g g g g #+$+^ %+<.@ @ @ @ :.` ", +" I.&+@ *+. =+h g g g g h -+ ! >.@ @ @ @ @ ;.^ ", +" ;+x.} > C.. >+g g g g g g >+ ` Z @ @ @ @ Y / . ", +" ` ' @ ,+. %.1.'+)+!+g g g g g g g g #+)+~+{+]+^+@ @ @ P.` ", +" / ).@ !.. /+(+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+(+:+@ @ @ @ ).^ ", +" I.[ > F . . <+[+@ @ @ @ <.I.` ", +" . . . . . . 0.@ }+. . . . . . . . . . . . . |+@ @ @ @ s.. . . . . . ", +" O.@ @ @ @ @ @ @ @ @ @ @ @ @ ^ ! $ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ $ . ", +" . & & & & & & & & & & & & & . . , & & & & & & & & & & & & & & & , . ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" ", +" "}; +static const XPM_DATA mini_xterm_xpms[] = { + { "mini.xterm_16x16", mini_xterm_16x16_xpm }, + { "mini.xterm_32x32", mini_xterm_32x32_xpm }, + { "mini.xterm_48x48", mini_xterm_48x48_xpm } +}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/mini.xterm_16x16.png and /tmp/2MsnOjJWPZ/xterm-297/icons/mini.xterm_16x16.png differ diff -Nru xterm-278/icons/mini.xterm_16x16.xpm xterm-297/icons/mini.xterm_16x16.xpm --- xterm-278/icons/mini.xterm_16x16.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/mini.xterm_16x16.xpm 2012-10-07 20:22:32.000000000 +0000 @@ -0,0 +1,103 @@ +/* XPM */ +static char * mini_xterm_16x16_xpm[] = { +"16 16 84 1", +" c None", +". c #FF3200", +"+ c #FF3C00", +"@ c #FF3F00", +"# c #FF3B00", +"$ c #FF3800", +"% c #FF2000", +"& c #FF1100", +"* c #FF3D00", +"= c #FF3900", +"- c #FF2200", +"; c #FF0A00", +"> c #FF5D00", +", c #FF1300", +"' c #FF0500", +") c #D0412F", +"! c #DD6722", +"~ c #DA3E25", +"{ c #D84727", +"] c #D03C2F", +"^ c #0023F3", +"/ c #000BF2", +"( c #0E21E6", +"_ c #4433B4", +": c #352EC3", +"< c #0010F2", +"[ c #0004F1", +"} c #2C33CB", +"| c #3E2ABA", +"1 c #011EF3", +"2 c #0012F3", +"3 c #022DF5", +"4 c #F2140D", +"5 c #FF5E00", +"6 c #052AF0", +"7 c #0013F3", +"8 c #DD4822", +"9 c #002CF5", +"0 c #004FF7", +"a c #003AF6", +"b c #1529E1", +"c c #D83827", +"d c #0037F7", +"e c #004CF8", +"f c #FF5900", +"g c #182EDE", +"h c #FF2100", +"i c #152CE1", +"j c #DD3B22", +"k c #FF2300", +"l c #FF2A00", +"m c #0C28E9", +"n c #E1571E", +"o c #FF2E00", +"p c #012AF4", +"q c #E1661E", +"r c #FF3600", +"s c #FF3500", +"t c #0028F4", +"u c #0011F2", +"v c #D64E29", +"w c #FF5C00", +"x c #FF2B00", +"y c #FF1D00", +"z c #FF2F00", +"A c #000EF2", +"B c #0003F1", +"C c #8C4072", +"D c #FF4C00", +"E c #FF2D00", +"F c #0360F6", +"G c #0031F6", +"H c #0016F3", +"I c #0827EE", +"J c #3D47BE", +"K c #E5631A", +"L c #FF4300", +"M c #FF3E00", +"N c #FF2400", +"O c #FF0700", +"P c #FF3400", +"Q c #FF5700", +"R c #FF5600", +"S c #FF3700", +" .+@#$% &$$*=- ", +" ;>#, '+ ", +" )!~ {] ", +" ^/(_:<[}|1/2 ", +" 2345=678 97 ", +" 0a =>b7c de ", +" fg7 ", +" hg7 ", +" $i7j ", +" klm7no ", +" # p7qr ", +" sk tuvwx ", +" yz ABCfDE ", +" = FGHHIJKr ", +" $LM$N O$PQRS- ", +" "}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/mini.xterm_256x256.png and /tmp/2MsnOjJWPZ/xterm-297/icons/mini.xterm_256x256.png differ Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/mini.xterm_32x32.png and /tmp/2MsnOjJWPZ/xterm-297/icons/mini.xterm_32x32.png differ diff -Nru xterm-278/icons/mini.xterm_32x32.xpm xterm-297/icons/mini.xterm_32x32.xpm --- xterm-278/icons/mini.xterm_32x32.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/mini.xterm_32x32.xpm 2012-10-07 20:23:40.000000000 +0000 @@ -0,0 +1,178 @@ +/* XPM */ +static char * mini_xterm_32x32_xpm[] = { +"32 32 143 2", +" c None", +". c #FF0000", +"+ c #FF1900", +"@ c #FF1F00", +"# c #FF0B00", +"$ c #FF1D00", +"% c #FF4A00", +"& c #FF5100", +"* c #FF5B00", +"= c #FF5E00", +"- c #FF5300", +"; c #FF3600", +"> c #FF0C00", +", c #FF5A00", +"' c #FF5C00", +") c #FF0A00", +"! c #FF0D00", +"~ c #FF2E00", +"{ c #FF5800", +"] c #FF2700", +"^ c #FF0500", +"/ c #0073FB", +"( c #0041F7", +"_ c #0074FB", +": c #0059F9", +"< c #0000F1", +"[ c #0505EC", +"} c #3A44BE", +"| c #615A9A", +"1 c #784285", +"2 c #3466C8", +"3 c #004DF8", +"4 c #0053F8", +"5 c #006CF9", +"6 c #3C44BD", +"7 c #2729CF", +"8 c #002CF5", +"9 c #2D2EC9", +"0 c #8D6E71", +"a c #E96416", +"b c #FF4400", +"c c #FF1800", +"d c #0019F3", +"e c #FF1400", +"f c #D66729", +"g c #73498A", +"h c #091FEB", +"i c #002CF4", +"j c #006FFC", +"k c #0002F1", +"l c #0059F8", +"m c #AD3252", +"n c #FF1700", +"o c #FF2B00", +"p c #B84A47", +"q c #0026F4", +"r c #FF0700", +"s c #FF1600", +"t c #003FF6", +"u c #0003F1", +"v c #006FFA", +"w c #0058F9", +"x c #0055FA", +"y c #FF3D00", +"z c #C3363C", +"A c #FF0400", +"B c #FF3F00", +"C c #FF1000", +"D c #003DF6", +"E c #005AF8", +"F c #002AF4", +"G c #FF0100", +"H c #FF5600", +"I c #C3643C", +"J c #A73958", +"K c #FF3100", +"L c #0020F3", +"M c #002DF5", +"N c #0089FD", +"O c #0022F4", +"P c #0085FD", +"Q c #C36E3C", +"R c #BC3943", +"S c #FF1300", +"T c #007AFC", +"U c #FF2200", +"V c #C3693C", +"W c #FF4600", +"X c #C3563C", +"Y c #FF1100", +"Z c #BD6C42", +"` c #C12F3E", +" . c #B13B4E", +".. c #C32F3C", +"+. c #C0283F", +"@. c #C34D3C", +"#. c #FF2400", +"$. c #BC3E43", +"%. c #C36D3C", +"&. c #FF3400", +"*. c #FF0800", +"=. c #C36B3C", +"-. c #FF4E00", +";. c #C3523C", +">. c #FF3E00", +",. c #FF1C00", +"'. c #FF0200", +"). c #BF3240", +"!. c #FF1A00", +"~. c #B4624B", +"{. c #FF5900", +"]. c #FF1200", +"^. c #B82E47", +"/. c #FF4800", +"(. c #FF3A00", +"_. c #001EF4", +":. c #001DF4", +"<. c #7D4882", +"[. c #FF4F00", +"}. c #0076FB", +"|. c #000CF2", +"1. c #0276F9", +"2. c #FF3800", +"3. c #FF5D00", +"4. c #004CF7", +"5. c #004CF8", +"6. c #FB0104", +"7. c #FF5500", +"8. c #B53E4A", +"9. c #0055F8", +"0. c #0038F6", +"a. c #0028F4", +"b. c #0039F6", +"c. c #0254F6", +"d. c #C66E39", +"e. c #FF3500", +"f. c #248ADB", +"g. c #785587", +"h. c #DE3121", +"i. c #FF1E00", +"j. c #FF2800", +"k. c #FF5700", +"l. c #FF1B00", +" ", +" ", +" . + @ @ @ @ @ @ @ @ @ # $ . @ @ @ @ @ @ @ @ . ", +" . % & & * = = = - & & ; @ > & & & , ' & & & ) ", +" . . . . ! = = = ~ . . . . . . . { ] ^ . . . ", +" / ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( _ ", +" : < < < [ } | 1 2 3 < < < < 4 5 6 7 < < < < : ", +" 8 < < 9 0 a = b c d < < d e f g h < < i ", +" j k < l m n = = = o p q < < q r { ] s t < u v ", +" w < x . y = = ' z q < < q A % B C D < E ", +" 8 F G H = = I q < < q J K & ! L M ", +" N O P r = = Q q < < q R ' S T O N ", +" . U = Q q < < q V ] s ", +" . W Q q < < q X Y ", +" G Z q < < q ` ", +" .q < < q .. ", +" +.q < < q @.#. ", +" $.q < < q %.+ &. ", +" *.=.q < < q Q - Y ", +" A -.;.q < < q Q = >.,. ", +" '.; -.).q < < q Q = = U ~ ", +" !., Y q < < q ~.= = {.]. ", +" *., U q < < q ^., = = /.s ", +" A -.(.]. _.< < :.<.C = = = ~ ] ", +" '.; [.! }.|.< < |.1.. 2.= = 3.s ", +" !., Y 4.< < < < 5. 6.7.= = & ]. ", +" *., U 8.9.0.a.< < < < < < a.b.c.d.= = (.@ ", +" A -.e.# f. g.h.= = = i.j. ", +" . @ @ ,.y , Y ,.@ @ G '.@ ,.].* = = k.l.@ @ . ", +" . & & & & & & & & & ) ,.& & & & & & & & & & ) ", +" . . . . . . . . . . . . . . . . . . . . . . . ", +" "}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/mini.xterm_48x48.png and /tmp/2MsnOjJWPZ/xterm-297/icons/mini.xterm_48x48.png differ diff -Nru xterm-278/icons/mini.xterm_48x48.xpm xterm-297/icons/mini.xterm_48x48.xpm --- xterm-278/icons/mini.xterm_48x48.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/mini.xterm_48x48.xpm 2012-10-07 20:24:18.000000000 +0000 @@ -0,0 +1,264 @@ +/* XPM */ +static char * mini_xterm_48x48_xpm[] = { +"48 48 213 2", +" c None", +". c #FF0000", +"+ c #FF5300", +"@ c #FF5E00", +"# c #FF4800", +"$ c #FF4200", +"% c #FF4000", +"& c #FF4B00", +"* c #FF5200", +"= c #FF5400", +"- c #FF3500", +"; c #FF5100", +"> c #FF5C00", +", c #FF3000", +"' c #FF4500", +") c #FF2000", +"! c #FF0300", +"~ c #FF1600", +"{ c #FF5D00", +"] c #FF3800", +"^ c #FF0200", +"/ c #FF0900", +"( c #FF2B00", +"_ c #FF3300", +": c #FF1A00", +"< c #FF1300", +"[ c #FF1200", +"} c #FF5700", +"| c #4577BA", +"1 c #874E78", +"2 c #887577", +"3 c #887E77", +"4 c #887977", +"5 c #875078", +"6 c #566CA9", +"7 c #5E70A1", +"8 c #884E77", +"9 c #887677", +"0 c #7C5B83", +"a c #795686", +"b c #008DFE", +"c c #0012F3", +"d c #000BF2", +"e c #008FFE", +"f c #006CFA", +"g c #0000F1", +"h c #0001F1", +"i c #0020F4", +"j c #0040F6", +"k c #0959F0", +"l c #1158E8", +"m c #1159E8", +"n c #0058F9", +"o c #001DF4", +"p c #0023F4", +"q c #005BFA", +"r c #0060FA", +"s c #0E58EB", +"t c #0651F3", +"u c #0033F5", +"v c #000EF2", +"w c #006EFA", +"x c #0092FF", +"y c #001FF4", +"z c #000FF2", +"A c #0C51EC", +"B c #326AC9", +"C c #7A6583", +"D c #CA6234", +"E c #FC5F03", +"F c #FF5800", +"G c #FF0800", +"H c #F4060B", +"I c #007CFB", +"J c #0013F3", +"K c #007EFB", +"L c #FF1800", +"M c #F3590C", +"N c #AB6152", +"O c #4F4EAD", +"P c #175CE4", +"Q c #0036F5", +"R c #0022F4", +"S c #0095FD", +"T c #0084FD", +"U c #0004F1", +"V c #0051F8", +"W c #345AC7", +"X c #E61519", +"Y c #FF5900", +"Z c #FF4600", +"` c #FF0100", +" . c #446EB9", +".. c #0034F6", +"+. c #0032F5", +"@. c #FF2200", +"#. c #006FFA", +"$. c #002DF5", +"%. c #0086FD", +"&. c #0046F7", +"*. c #0015F3", +"=. c #0076FC", +"-. c #FF0400", +";. c #FF2300", +">. c #FF2900", +",. c #9E3E61", +"'. c #0039F6", +"). c #FF2A00", +"!. c #FF4300", +"~. c #0071FB", +"{. c #005EF9", +"]. c #004DF7", +"^. c #008CFE", +"/. c #0008F2", +"(. c #001DF3", +"_. c #007DFB", +":. c #FF4100", +"<. c #FF5B00", +"[. c #A3425C", +"}. c #994C66", +"|. c #FF1100", +"1. c #0072FB", +"2. c #000AF2", +"3. c #006EFC", +"4. c #0017F3", +"5. c #007FFB", +"6. c #FF0600", +"7. c #FF5600", +"8. c #A56A5A", +"9. c #A53B5A", +"0. c #FF4F00", +"a. c #0076FB", +"b. c #0076FA", +"c. c #0093FF", +"d. c #007DFC", +"e. c #FF1C00", +"f. c #A5765A", +"g. c #A55D5A", +"h. c #006FFB", +"i. c #002CF5", +"j. c #008AFD", +"k. c #006BF9", +"l. c #FF3A00", +"m. c #FF5000", +"n. c #007BFB", +"o. c #008BFD", +"p. c #A5755A", +"q. c #9A5565", +"r. c #A43A5B", +"s. c #FF4D00", +"t. c #80507F", +"u. c #FF0F00", +"v. c #7A5485", +"w. c #A5555A", +"x. c #FF0A00", +"y. c #A53D5A", +"z. c #A4515B", +"A. c #A5685A", +"B. c #A5735A", +"C. c #FF0700", +"D. c #FF2E00", +"E. c #FF1500", +"F. c #A3705C", +"G. c #FF0500", +"H. c #9A4965", +"I. c #FF0E00", +"J. c #FF3B00", +"K. c #FF2D00", +"L. c #A13C5E", +"M. c #FF4C00", +"N. c #62649D", +"O. c #FF0B00", +"P. c #FF4700", +"Q. c #FF1D00", +"R. c #A56D5A", +"S. c #FF2C00", +"T. c #A4465B", +"U. c #FF1400", +"V. c #A03E61", +"W. c #FF3100", +"X. c #FF1B00", +"Y. c #FF1000", +"Z. c #0029F5", +"`. c #0027F4", +" + c #4571BA", +".+ c #FF3900", +"++ c #FF3200", +"@+ c #008EFD", +"#+ c #0019F3", +"$+ c #0090FD", +"%+ c #FF0D00", +"&+ c #FF1E00", +"*+ c #FF4E00", +"=+ c #0088FC", +"-+ c #0087FC", +";+ c #FF1900", +">+ c #0036F6", +",+ c #FF2100", +"'+ c #0073FB", +")+ c #0062FA", +"!+ c #001AF3", +"~+ c #2463D8", +"{+ c #3E58BE", +"]+ c #2A7FD3", +"^+ c #807B7F", +"/+ c #008EFB", +"(+ c #006AFA", +"_+ c #004CF8", +":+ c #717B8D", +"<+ c #EE0B11", +"[+ c #F73E08", +"}+ c #FF1F00", +"|+ c #FF5500", +" ", +" ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" . + @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ . . # @ @ @ @ @ @ @ @ @ @ @ @ $ . ", +" . % & & & * @ @ @ @ @ = & & & & & . . - & & & & & ; @ > & & & & , . ", +" . . . . . . * @ @ @ @ ; . . . . . . . . . . . . . ' @ ) . . . . . . ", +" ! ~ { @ @ @ @ ] ^ / ( @ $ . ", +" ^ _ @ @ @ @ @ : ! < [ > } ^ . ", +" | 1 2 3 3 3 3 4 5 6 7 8 9 3 0 a ", +" b c d d d d d d d d d d d d d d d d d d d d d d d d d d d d d d d d c e ", +" f g g g g g g h i j k l m n o g g g g g g p q r s t u v g g g g g g g w ", +" x y g g g g z A B C D E F G H I c g g g g J K L / M N O P Q h g g g g R S ", +" T g g g U V W X Y @ @ @ @ Z ` ...g g g g +. ` ' @ @.. #.$.g g g g %. ", +" &.g g *.=. -.;.@ @ @ @ @ >.,.'.g g g g '. / ).@ !.. ~.{.U g g ]. ", +" ^./.g (._. ` :.@ @ @ @ <.[.'.g g g g '.}.|.<.} ^ . 1.2.g d e ", +" 3.g 4.5. 6.7.@ @ @ @ 8.'.g g g g '.9.0.@ [ . a./.g b. ", +" c.R /.d. -.e.@ @ @ @ f.'.g g g g '.g.@ - . h.h i. ", +" j.k.%. ^ l.@ @ @ f.'.g g g g '.f.m.` n.f o. ", +" ! * @ @ f.'.g g g g '.p.G . ", +" ! ~ { @ f.'.g g g g '.q.. ", +" ^ _ @ f.'.g g g g '.r. ", +" ^ s.f.'.g g g g '.t. ", +" ^ u.p.'.g g g g '.v. ", +" ^ w.'.g g g g '.r. ", +" x.y.'.g g g g '.z.^ ", +" ` A.'.g g g g '.B.x.. ", +" C.D.f.'.g g g g '.f.# ` ", +" < E.{ F.'.g g g g '.f.@ ( ^ ", +" : G.; @ H.'.g g g g '.f.@ <.I.^ ", +" -.J.@ K.L.'.g g g g '.f.@ @ s.` ", +" I.) @ M.. N.'.g g g g '.f.@ @ @ _ ^ ", +" L O.F <.6.. '.g g g g '.f.@ @ @ { E.! ", +" ^ P.@ Q.. '.g g g g '.R.@ @ @ @ * ! ", +" G S.@ % . '.g g g g '.T.{ @ @ @ @ l.^ ", +" < U.> 7.^ ..g g g g u V.W.@ @ @ @ @ e.! ", +" X.-.m.@ Y.. Z.g g g g `. +` M.@ @ @ @ 7.6. ", +" -..+@ ++. @+#+g g g g #+$+^ %+<.@ @ @ @ :.` ", +" I.&+@ *+. =+h g g g g h -+ ! >.@ @ @ @ @ ;.^ ", +" ;+x.} > C.. >+g g g g g g >+ ` Z @ @ @ @ Y / . ", +" ` ' @ ,+. %.1.'+)+!+g g g g g g g g #+)+~+{+]+^+@ @ @ P.` ", +" / ).@ !.. /+(+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+(+:+@ @ @ @ ).^ ", +" I.[ > F . . <+[+@ @ @ @ <.I.` ", +" . . . . . . 0.@ }+. . . . . . . . . . . . . |+@ @ @ @ s.. . . . . . ", +" O.@ @ @ @ @ @ @ @ @ @ @ @ @ ^ ! $ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ $ . ", +" . & & & & & & & & & & & & & . . , & & & & & & & & & & & & & & & , . ", +" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ", +" ", +" "}; diff -Nru xterm-278/icons/terminal_48x48.svg xterm-297/icons/terminal_48x48.svg --- xterm-278/icons/terminal_48x48.svg 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/terminal_48x48.svg 2012-06-14 08:58:22.000000000 +0000 @@ -0,0 +1,643 @@ + + + + terminal + + + + + + + + + + image/svg+xml + + terminal + + + + Thomas E. Dickey + + + + + MIT-X11 + + + Translated from the X11 bitmaps/terminal file through stages to svg. + June 14, 2012 + http://invisible-island.net/xterm/ + http://invisible-island.net/xterm/terminal_48x48 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -Nru xterm-278/icons/terminal_48x48.xpm xterm-297/icons/terminal_48x48.xpm --- xterm-278/icons/terminal_48x48.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/terminal_48x48.xpm 2012-06-13 21:11:20.000000000 +0000 @@ -0,0 +1,53 @@ +/* XPM */ +static char * terminal_48x48_xpm[] = { +"48 48 2 1", +" c #000000", +". c #FFFFFF", +"................................................", +"...... ........", +"..... .................................. ......", +"..... ... ... . .....", +"..... .. ............................ .. .. ....", +"..... . .............................. . ... ...", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . .... ..", +"..... . .............................. . ... ...", +"..... . .............................. . ... ...", +"..... . .............................. . .. ....", +"..... . .............................. . .. ....", +"..... . .............................. . . .....", +"..... .. ............................ .. . .....", +"..... ... ... ......", +"..... .................................. ......", +"...... ........", +"................................................", +"................................................", +"...... ......", +"..... .................................. ......", +"..... . . . . . . . . . . . . . . . . .. ......", +".... .................................. . ......", +".... . . . . . . . . . . . . . . . . .. . ......", +"... .................................. .. ......", +"... . . . . . . . . . . . . . . . . .. .. ......", +".. .................................. .. .......", +".. . . . . . ........", +". .................................. . .........", +". ..........", +"................................................"}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/xterm-color.png and /tmp/2MsnOjJWPZ/xterm-297/icons/xterm-color.png differ diff -Nru xterm-278/icons/xterm-color.svg xterm-297/icons/xterm-color.svg --- xterm-278/icons/xterm-color.svg 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/xterm-color.svg 2012-10-07 20:15:20.000000000 +0000 @@ -0,0 +1,792 @@ + + + + + terminal + + + + + + + + + + image/svg+xml + + xterm + + + + Thomas E. Dickey + + + + + MIT-X11 + + + XTerm icon, in SVG format. + June 14, 2012 + http://invisible-island.net/xterm/ + http://invisible-island.net/xterm/xterm + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + X + TERM + + + + + + + + + + + + + + + + + + diff -Nru xterm-278/icons/xterm-color.xpms xterm-297/icons/xterm-color.xpms --- xterm-278/icons/xterm-color.xpms 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/xterm-color.xpms 2012-10-09 10:48:48.000000000 +0000 @@ -0,0 +1,263 @@ +/* $XTermId: xterm-color.xpms,v 1.3 2012/10/09 10:48:48 tom Exp $ */ +/* generated by ./make-xpms */ +/* vile:xpmmode */ +/* XPM */ +static const char * const xterm_color_16x16_xpm[] = { +"16 16 80 1", +". c None", +" c #555500", +"+ c #545400", +"@ c #3A3A00", +"# c #222200", +"$ c #2A2A00", +"% c #2B2B00", +"& c #151500", +"* c #5E5E00", +"= c #5A5A00", +"- c #909098", +"; c #3E3E3E", +"> c #000000", +", c #F2F2F2", +"' c #2E2E36", +") c #343400", +"! c #4C0000", +"~ c #140000", +"{ c #7C0000", +"] c #7F7F7F", +"^ c #858588", +"/ c #EA0000", +"( c #0B0000", +"_ c #460000", +": c #8E0000", +"< c #A80000", +"[ c #474747", +"} c #868686", +"| c #404548", +"1 c #8F3400", +"2 c #451200", +"3 c #299000", +"4 c #1F6C00", +"5 c #192E48", +"6 c #1B3448", +"7 c #888888", +"8 c #CF4C00", +"9 c #3B0700", +"0 c #39C700", +"a c #42E800", +"b c #2D5181", +"c c #55A3E3", +"d c #305C81", +"e c #989898", +"f c #D84F00", +"g c #3A0600", +"h c #258100", +"i c #376599", +"j c #396D99", +"k c #7E7E7E", +"l c #010100", +"m c #000101", +"n c #9A9A9A", +"o c #101000", +"p c #5B5B00", +"q c #3D3D00", +"r c #272700", +"s c #2F2F00", +"t c #303000", +"u c #1A1A00", +"v c #464636", +"w c #7A7A7F", +"x c #8B8B90", +"y c #1B1B00", +"z c #0F0F00", +"A c #FFFFFF", +"B c #5B5B5B", +"C c #C9C9C9", +"D c #BFBFBF", +"E c #B5B5B5", +"F c #5C5C5C", +"G c #79797F", +"H c #7F7F88", +"I c #484835", +"J c #3C3C00", +"K c #1E1E00", +"L c #909090", +"M c #333336", +"N c #464600", +"O c #575700", +".+@#$$$$$$$$%&*+", +".=-;>>>>>>>>>,')", +".=>!~{>>>>>>>>]^", +".=>>/(>>>>>>>>]]", +".=>_:<>>>>>>>>]]", +".=>>>>>>>>>>>>]]", +".=>[}|12345>6>]]", +".=>>7>890abcd>]]", +".=>>e>fgh0i>j>k^", +".=>>>l>>>>>m>>no", +".=-;>>>>>>>>>,>p", +".+qrsssssssstu*.", +".pvwwwwwwwwwwxy.", +"+zABABCDDDEAFG*.", +"*HBABAEDDDCBAIJ.", +"KL]]]]]]]]]]MNO."}; +/* XPM */ +static const char * const xterm_color_32x32_xpm[] = { +"32 32 60 1", +". c None", +" c #FFFFFF", +"+ c #000000", +"@ c #EFEFEF", +"# c #FEFEFE", +"$ c #FBFBFB", +"% c #F3F3F3", +"& c #ADADAD", +"* c #909090", +"= c #737373", +"- c #D2D2D2", +"; c #646464", +"> c #9A9A9A", +", c #8D8D8D", +"' c #D3D3D3", +") c #0E0E0E", +"! c #F6F6F6", +"~ c #5E5E5E", +"{ c #B1B1B1", +"] c #777777", +"^ c #949494", +"/ c #757575", +"( c #C4C4C4", +"_ c #E7E7E7", +": c #F1F1F1", +"< c #F8F8F8", +"[ c #EEEEEE", +"} c #F0F0F0", +"| c #FAFAFA", +"1 c #7B7B7B", +"2 c #3D3D3D", +"3 c #868686", +"4 c #4F4F4F", +"5 c #ABABAB", +"6 c #545454", +"7 c #5B5B5B", +"8 c #AFAFAF", +"9 c #292929", +"0 c #181818", +"a c #C7C7C7", +"b c #CFCFCF", +"c c #7F7F7F", +"d c #A3A3A3", +"e c #4D4D4D", +"f c #6A6A6A", +"g c #A1A1A1", +"h c #8E8E8E", +"i c #696969", +"j c #474747", +"k c #5A5A5A", +"l c #959595", +"m c #767676", +"n c #8B8B8B", +"o c #BCBCBC", +"p c #BFBFBF", +"q c #D7D7D7", +"r c #404040", +"s c #636363", +"t c #989898", +"u c #8A8A8A", +"................................", +".....+++++++++++++++++++++++....", +"....+..+++++++++++++++++++..++..", +"....+.+...................+.+.+.", +"....++.@#.$%................+..+", +"....++.&*.=-................+..+", +"....++..;>,.................+..+", +"....++..')!.................+..+", +"....++.#~{].................+..+", +"....++.^{./(................+..+", +"....++......................+..+", +"....++......................+..+", +"....++.____:___<_[..<}..[|..+..+", +"....++.1;21341156]7.89$:0a..+..+", +"....++..bc.8^__8d.e.8fghia..+..+", +"....++..bc.84115jkl.887mna..+..+", +"....++..bc.8d..8dof.88pqna..+..+", +"....++..bc.8rss5d.tu88..na..+...", +"....++......................+.+.", +"....++......................+.+.", +"....+.+...................+.++..", +"....+..+++++++++++++++++++..+...", +".....+++++++++++++++++++++++....", +"................................", +".....++++++++++++++++++++++++...", +"....+.......................+...", +"...+.......................+....", +"...+..++..++.++..++..+..++.+....", +"....++..++..+..++..++.++........", +"..+.......................+.+...", +".+.......................+......", +".++++++++++++++++++++++++++....."}; +/* XPM */ +static const char * const xterm_color_48x48_xpm[] = { +"48 48 10 1", +". c None", +" c #555500", +"+ c #000000", +"@ c #FFFFFF", +"# c #FF0000", +"$ c #070700", +"% c #0B0B00", +"& c #FF8400", +"* c #49FF00", +"= c #60B7FF", +"................................................", +"......++++++++++++++++++++++++++++++++++........", +".....+@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@++......", +".....+@@@++++++++++++++++++++++++++++@@@+@+.....", +".....+@@++++++++++++++++++++++++++++++@@+@@+....", +".....+@++++++++++++++++++++++++++++++++@+@@@+...", +".....+@++###++++###++++++++++++++++++++@+@@@@+..", +".....+@+++##++++##+++++++++++++++++++++@+@@@@+..", +".....+@++++##++##++++++++++++++++++++++@+@@@@+..", +".....+@++++##++##++++++++++++++++++++++@+@@@@+..", +".....+@+++++####+++++++++++++++++++++++@+@@@@+..", +".....+@+++++####+++++++++++++++++++++++@+@@@@+..", +".....+@++++++##++++++++++++++++++++++++@+@@@@+..", +".....+@+++++####+++++++++++++++++++++++@+@@@@+..", +".....+@+++++####+++++++++++++++++++++++@+@@@@+..", +".....+@++++##++##++++++++++++++++++++++@+@@@@+..", +".....+@++++##++##++++++++++++++++++++++@+@@@@+..", +".....+@+++##++++##+++++++++++++++++++++@+@@@@+..", +".....+@++###++++###++++++++++++++++++++@+@@@@+..", +".....+@++++++++++++++++++++++++++++++++@+@@@@+..", +".....+@$+++++++++++++++++++++++++++++++@+@@@@+..", +".....+@%@@@@@@@+&&&&&++****+++==+++==++@+@@@@+..", +".....+@++++@++++&++++++*+++*++==+++==++@+@@@@+..", +".....+@++++@++++&++++++*+++*++=+=+=+=++@+@@@@+..", +".....+@++++@++++&&&&+++****+++=+=+=+=++@+@@@@+..", +".....+@++++@++++&++++++*+*++++=++=++=++@+@@@+...", +".....+@++++@++++&++++++*++*+++=++=++=++@+@@@+...", +".....+@++++@++++&&&&&++*+++*++=+++++=++@+@@+....", +".....+@++++++++++++++++++++++++++++++++@+@@+....", +".....+@++++++++++++++++++++++++++++++++@+@+.....", +".....+@@++++++++++++++++++++++++++++++@@+@+.....", +".....+@@@++++++++++++++++++++++++++++@@@++......", +".....+@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@++......", +"......++++++++++++++++++++++++++++++++++........", +"................................................", +"................................................", +"......++++++++++++++++++++++++++++++++++++......", +".....+@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@++......", +".....+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@@++......", +"....+@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@+@+......", +"....+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@@+@+......", +"...+@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@+@@+......", +"...+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@+@@+@@+......", +"..+@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@+@@+.......", +"..+@++@++++++++++++++++++++++++++@++@+@+........", +".+@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@+@+.........", +".+++++++++++++++++++++++++++++++++++++..........", +"................................................"}; +static const XPM_DATA xterm_color_xpms[] = { + { "xterm-color_16x16", xterm_color_16x16_xpm }, + { "xterm-color_32x32", xterm_color_32x32_xpm }, + { "xterm-color_48x48", xterm_color_48x48_xpm } +}; diff -Nru xterm-278/icons/xterm-color_16x16.xpm xterm-297/icons/xterm-color_16x16.xpm --- xterm-278/icons/xterm-color_16x16.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/xterm-color_16x16.xpm 2012-10-09 10:41:41.000000000 +0000 @@ -0,0 +1,99 @@ +/* XPM */ +static char * xterm_color_16x16_xpm[] = { +"16 16 80 1", +". c None", +" c #555500", +"+ c #545400", +"@ c #3A3A00", +"# c #222200", +"$ c #2A2A00", +"% c #2B2B00", +"& c #151500", +"* c #5E5E00", +"= c #5A5A00", +"- c #909098", +"; c #3E3E3E", +"> c #000000", +", c #F2F2F2", +"' c #2E2E36", +") c #343400", +"! c #4C0000", +"~ c #140000", +"{ c #7C0000", +"] c #7F7F7F", +"^ c #858588", +"/ c #EA0000", +"( c #0B0000", +"_ c #460000", +": c #8E0000", +"< c #A80000", +"[ c #474747", +"} c #868686", +"| c #404548", +"1 c #8F3400", +"2 c #451200", +"3 c #299000", +"4 c #1F6C00", +"5 c #192E48", +"6 c #1B3448", +"7 c #888888", +"8 c #CF4C00", +"9 c #3B0700", +"0 c #39C700", +"a c #42E800", +"b c #2D5181", +"c c #55A3E3", +"d c #305C81", +"e c #989898", +"f c #D84F00", +"g c #3A0600", +"h c #258100", +"i c #376599", +"j c #396D99", +"k c #7E7E7E", +"l c #010100", +"m c #000101", +"n c #9A9A9A", +"o c #101000", +"p c #5B5B00", +"q c #3D3D00", +"r c #272700", +"s c #2F2F00", +"t c #303000", +"u c #1A1A00", +"v c #464636", +"w c #7A7A7F", +"x c #8B8B90", +"y c #1B1B00", +"z c #0F0F00", +"A c #FFFFFF", +"B c #5B5B5B", +"C c #C9C9C9", +"D c #BFBFBF", +"E c #B5B5B5", +"F c #5C5C5C", +"G c #79797F", +"H c #7F7F88", +"I c #484835", +"J c #3C3C00", +"K c #1E1E00", +"L c #909090", +"M c #333336", +"N c #464600", +"O c #575700", +".+@#$$$$$$$$%&*+", +".=-;>>>>>>>>>,')", +".=>!~{>>>>>>>>]^", +".=>>/(>>>>>>>>]]", +".=>_:<>>>>>>>>]]", +".=>>>>>>>>>>>>]]", +".=>[}|12345>6>]]", +".=>>7>890abcd>]]", +".=>>e>fgh0i>j>k^", +".=>>>l>>>>>m>>no", +".=-;>>>>>>>>>,>p", +".+qrsssssssstu*.", +".pvwwwwwwwwwwxy.", +"+zABABCDDDEAFG*.", +"*HBABAEDDDCBAIJ.", +"KL]]]]]]]]]]MNO."}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/xterm-color_32x32.xcf and /tmp/2MsnOjJWPZ/xterm-297/icons/xterm-color_32x32.xcf differ diff -Nru xterm-278/icons/xterm-color_32x32.xpm xterm-297/icons/xterm-color_32x32.xpm --- xterm-278/icons/xterm-color_32x32.xpm 2007-06-16 18:00:33.000000000 +0000 +++ xterm-297/icons/xterm-color_32x32.xpm 2012-10-09 10:41:47.000000000 +0000 @@ -1,46 +1,95 @@ /* XPM */ static char * xterm_color_32x32_xpm[] = { -"32 32 11 1", -" c None", -". c #555500", +"32 32 60 1", +". c None", +" c #FFFFFF", "+ c #000000", -"@ c #FFFFFF", -"# c #FF0000", -"$ c #980000", -"% c #FF5E00", -"& c #49FF00", -"* c #2FA300", -"= c #60B7FF", -"- c #3A709B", +"@ c #EFEFEF", +"# c #FEFEFE", +"$ c #FBFBFB", +"% c #F3F3F3", +"& c #ADADAD", +"* c #909090", +"= c #737373", +"- c #D2D2D2", +"; c #646464", +"> c #9A9A9A", +", c #8D8D8D", +"' c #D3D3D3", +") c #0E0E0E", +"! c #F6F6F6", +"~ c #5E5E5E", +"{ c #B1B1B1", +"] c #777777", +"^ c #949494", +"/ c #757575", +"( c #C4C4C4", +"_ c #E7E7E7", +": c #F1F1F1", +"< c #F8F8F8", +"[ c #EEEEEE", +"} c #F0F0F0", +"| c #FAFAFA", +"1 c #7B7B7B", +"2 c #3D3D3D", +"3 c #868686", +"4 c #4F4F4F", +"5 c #ABABAB", +"6 c #545454", +"7 c #5B5B5B", +"8 c #AFAFAF", +"9 c #292929", +"0 c #181818", +"a c #C7C7C7", +"b c #CFCFCF", +"c c #7F7F7F", +"d c #A3A3A3", +"e c #4D4D4D", +"f c #6A6A6A", +"g c #A1A1A1", +"h c #8E8E8E", +"i c #696969", +"j c #474747", +"k c #5A5A5A", +"l c #959595", +"m c #767676", +"n c #8B8B8B", +"o c #BCBCBC", +"p c #BFBFBF", +"q c #D7D7D7", +"r c #404040", +"s c #636363", +"t c #989898", +"u c #8A8A8A", "................................", ".....+++++++++++++++++++++++....", -"....+@@+++++++++++++++++++@@++..", -"....+@+++++++++++++++++++++@+@+.", -"....+++++++++++++++++++++++++@@+", -"....+++#$+$#+++++++++++++++++@@+", -"....++++$#$++++++++++++++++++@@+", -"....++++$#+++++++++++++++++++@@+", -"....++++$#$++++++++++++++++++@@+", -"....+++#$+$#+++++++++++++++++@@+", -"....+++++++++++++++++++++++++@@+", -"....+++++++++++++++++++++++++@@+", -"....+++++++++++++++++++++++++@@+", -"....+++@@@@+%%%+&&&*+=++=++++@@+", -"....+++++@++%+++&+&*+=-==++++@@+", -"....+++++@++%%%+&&&*+==-=++++@@+", -"....+++++@++%+++&+&++=++=++++@@+", -"....+++++@++%%%+&+*&+=++=++++@@+", -"....+++++++++++++++++++++++++@+.", -"....+++++++++++++++++++++++++@+.", -"....+@+++++++++++++++++++++@++..", -"....+@@+++++++++++++++++++@@+...", +"....+..+++++++++++++++++++..++..", +"....+.+...................+.+.+.", +"....++.@#.$%................+..+", +"....++.&*.=-................+..+", +"....++..;>,.................+..+", +"....++..')!.................+..+", +"....++.#~{].................+..+", +"....++.^{./(................+..+", +"....++......................+..+", +"....++......................+..+", +"....++.____:___<_[..<}..[|..+..+", +"....++.1;21341156]7.89$:0a..+..+", +"....++..bc.8^__8d.e.8fghia..+..+", +"....++..bc.84115jkl.887mna..+..+", +"....++..bc.8d..8dof.88pqna..+..+", +"....++..bc.8rss5d.tu88..na..+...", +"....++......................+.+.", +"....++......................+.+.", +"....+.+...................+.++..", +"....+..+++++++++++++++++++..+...", ".....+++++++++++++++++++++++....", "................................", ".....++++++++++++++++++++++++...", -"....+@@@@@@@@@@@@@@@@@@@@@@@+...", -"...+@@@@@@@@@@@@@@@@@@@@@@@+....", -"...+@@++@@++@++@@++@@+@@++@+....", -"..+@++@@++@@+@@++@@++@++@@@+....", -"..+@@@@@@@@@@@@@@@@@@@@@@@+.+...", -".+@@@@@@@@@@@@@@@@@@@@@@@+......", +"....+.......................+...", +"...+.......................+....", +"...+..++..++.++..++..+..++.+....", +"....++..++..+..++..++.++........", +"..+.......................+.+...", +".+.......................+......", ".++++++++++++++++++++++++++....."}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/xterm-color_48x48.xcf and /tmp/2MsnOjJWPZ/xterm-297/icons/xterm-color_48x48.xcf differ diff -Nru xterm-278/icons/xterm-color_48x48.xpm xterm-297/icons/xterm-color_48x48.xpm --- xterm-278/icons/xterm-color_48x48.xpm 2007-06-16 16:01:44.000000000 +0000 +++ xterm-297/icons/xterm-color_48x48.xpm 2012-10-09 10:39:55.000000000 +0000 @@ -1,8 +1,8 @@ /* XPM */ static char * xterm_color_48x48_xpm[] = { "48 48 10 1", -" c None", -". c #555500", +". c None", +" c #555500", "+ c #000000", "@ c #FFFFFF", "# c #FF0000", Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/xterm.png and /tmp/2MsnOjJWPZ/xterm-297/icons/xterm.png differ diff -Nru xterm-278/icons/xterm.svg xterm-297/icons/xterm.svg --- xterm-278/icons/xterm.svg 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/xterm.svg 2012-10-07 22:47:45.000000000 +0000 @@ -0,0 +1,652 @@ + + + + + terminal + + + + + + + + + + image/svg+xml + + xterm + + + + Thomas E. Dickey + + + + + MIT-X11 + + + XTerm icon, in SVG format. + June 14, 2012 + http://invisible-island.net/xterm/ + http://invisible-island.net/xterm/xterm + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + X + TERM + + diff -Nru xterm-278/icons/xterm.xpms xterm-297/icons/xterm.xpms --- xterm-278/icons/xterm.xpms 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/xterm.xpms 2012-10-07 22:58:01.000000000 +0000 @@ -0,0 +1,119 @@ +/* $XTermId: xterm.xpms,v 1.3 2012/10/07 22:58:01 tom Exp $ */ +/* generated by ./make-xpms */ +/* vile:xpmmode */ +/* XPM */ +static const char * const xterm_16x16_xpm[] = { +"16 16 2 1", +" c None", +". c #000000", +" ", +" . ", +" .... . ", +" .. . ", +" .. . ", +" .. . . ", +" . ", +" .... .. . ", +" . . . .. . ", +" . . ", +" . . ", +" . ", +" . ", +" ", +" ", +" . "}; +/* XPM */ +static const char * const xterm_32x32_xpm[] = { +"32 32 2 1", +" c None", +". c #000000", +" ", +" . .. ", +" . ................... ... ", +" . . ... . ", +" . ... . ", +" . .. ... ... . ", +" . . . ... . ", +" . .. ... . ", +" . .. ... . ", +" . .. ... . ", +" . . . ... . ", +" . ... .. ... . ", +" . ... . ", +" . ... . ", +" . ........ ... .. ..... . ", +" . . . . . ........ . ", +" . . ... .. . . .... . ", +" . . . . . . . .... . ", +" . . ... . .. . .... . ", +" . . .... ", +" . . . ... ", +" . .. ", +" ....................... ", +" ", +" ........................ ", +" . .. ", +" .. ", +" . . . ", +" . . ", +" . . ................. .. . ", +" . .. ", +" "}; +/* XPM */ +static const char * const xterm_48x48_xpm[] = { +"48 48 2 1", +" c None", +". c #000000", +" ", +" .................................. ", +" . .. ", +" . ............................ . . ", +" . . . . . ", +" . . . . . ", +" . . . . . ", +" . . ... ... . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . .. . . . ", +" . . .. . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . ... ... . . . ", +" . . . . . ", +" . . . . . ", +" . . . . . ", +" . . . . . ", +" . . ..... ..... .... . . . . . ", +" . . . . . . .. .. . . . ", +" . . . . . . .. .. . . . ", +" . . . ..... .... . . . . . . . ", +" . . . . . . . ... . . . .. ", +" . . . . . . . . . . . . ", +" . . . ..... . . . . . . .. ", +" . . . . . ", +" . . . . .. ", +" . . . . . ", +" . ............................ ... ", +" . .. ", +" .................................. ", +" ", +" ", +" .................................... ", +" . .. ", +" . . . . . . . . . . . . . . . . . ... ", +" . . . ", +" . . . . . . . . . . . . . . . . . .. . ", +" . . . ", +" .. . . . . . . . . . . . . . . . . .. . ", +" . . . ", +" .. .. .......................... .... . ", +" . . . ", +" ..................................... ", +" "}; +static const XPM_DATA xterm_xpms[] = { + { "xterm_16x16", xterm_16x16_xpm }, + { "xterm_32x32", xterm_32x32_xpm }, + { "xterm_48x48", xterm_48x48_xpm } +}; diff -Nru xterm-278/icons/xterm_16x16.xpm xterm-297/icons/xterm_16x16.xpm --- xterm-278/icons/xterm_16x16.xpm 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/icons/xterm_16x16.xpm 2012-10-07 22:57:39.000000000 +0000 @@ -0,0 +1,21 @@ +/* XPM */ +static char * xterm_16x16_xpm[] = { +"16 16 2 1", +" c None", +". c #000000", +" ", +" . ", +" .... . ", +" .. . ", +" .. . ", +" .. . . ", +" . ", +" .... .. . ", +" . . . .. . ", +" . . ", +" . . ", +" . ", +" . ", +" ", +" ", +" . "}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/xterm_32x32.xcf and /tmp/2MsnOjJWPZ/xterm-297/icons/xterm_32x32.xcf differ diff -Nru xterm-278/icons/xterm_32x32.xpm xterm-297/icons/xterm_32x32.xpm --- xterm-278/icons/xterm_32x32.xpm 2007-06-16 17:22:59.000000000 +0000 +++ xterm-297/icons/xterm_32x32.xpm 2012-10-07 22:57:11.000000000 +0000 @@ -1,95 +1,37 @@ /* XPM */ static char * xterm_32x32_xpm[] = { -"32 32 60 1", +"32 32 2 1", " c None", -". c #FFFFFF", -"+ c #000000", -"@ c #EFEFEF", -"# c #FEFEFE", -"$ c #FBFBFB", -"% c #F3F3F3", -"& c #ADADAD", -"* c #909090", -"= c #737373", -"- c #D2D2D2", -"; c #646464", -"> c #9A9A9A", -", c #8D8D8D", -"' c #D3D3D3", -") c #0E0E0E", -"! c #F6F6F6", -"~ c #5E5E5E", -"{ c #B1B1B1", -"] c #777777", -"^ c #949494", -"/ c #757575", -"( c #C4C4C4", -"_ c #E7E7E7", -": c #F1F1F1", -"< c #F8F8F8", -"[ c #EEEEEE", -"} c #F0F0F0", -"| c #FAFAFA", -"1 c #7B7B7B", -"2 c #3D3D3D", -"3 c #868686", -"4 c #4F4F4F", -"5 c #ABABAB", -"6 c #545454", -"7 c #5B5B5B", -"8 c #AFAFAF", -"9 c #292929", -"0 c #181818", -"a c #C7C7C7", -"b c #CFCFCF", -"c c #7F7F7F", -"d c #A3A3A3", -"e c #4D4D4D", -"f c #6A6A6A", -"g c #A1A1A1", -"h c #8E8E8E", -"i c #696969", -"j c #474747", -"k c #5A5A5A", -"l c #959595", -"m c #767676", -"n c #8B8B8B", -"o c #BCBCBC", -"p c #BFBFBF", -"q c #D7D7D7", -"r c #404040", -"s c #636363", -"t c #989898", -"u c #8A8A8A", -"................................", -".....+++++++++++++++++++++++....", -"....+..+++++++++++++++++++..++..", -"....+.+...................+.+.+.", -"....++.@#.$%................+..+", -"....++.&*.=-................+..+", -"....++..;>,.................+..+", -"....++..')!.................+..+", -"....++.#~{].................+..+", -"....++.^{./(................+..+", -"....++......................+..+", -"....++......................+..+", -"....++.____:___<_[..<}..[|..+..+", -"....++.1;21341156]7.89$:0a..+..+", -"....++..bc.8^__8d.e.8fghia..+..+", -"....++..bc.84115jkl.887mna..+..+", -"....++..bc.8d..8dof.88pqna..+..+", -"....++..bc.8rss5d.tu88..na..+...", -"....++......................+.+.", -"....++......................+.+.", -"....+.+...................+.++..", -"....+..+++++++++++++++++++..+...", -".....+++++++++++++++++++++++....", -"................................", -".....++++++++++++++++++++++++...", -"....+.......................+...", -"...+.......................+....", -"...+..++..++.++..++..+..++.+....", -"....++..++..+..++..++.++........", -"..+.......................+.+...", -".+.......................+......", -".++++++++++++++++++++++++++....."}; +". c #000000", +" ", +" . .. ", +" . ................... ... ", +" . . ... . ", +" . ... . ", +" . .. ... ... . ", +" . . . ... . ", +" . .. ... . ", +" . .. ... . ", +" . .. ... . ", +" . . . ... . ", +" . ... .. ... . ", +" . ... . ", +" . ... . ", +" . ........ ... .. ..... . ", +" . . . . . ........ . ", +" . . ... .. . . .... . ", +" . . . . . . . .... . ", +" . . ... . .. . .... . ", +" . . .... ", +" . . . ... ", +" . .. ", +" ....................... ", +" ", +" ........................ ", +" . .. ", +" .. ", +" . . . ", +" . . ", +" . . ................. .. . ", +" . .. ", +" "}; Binary files /tmp/Rkv1nH2Gnh/xterm-278/icons/xterm_48x48.xcf and /tmp/2MsnOjJWPZ/xterm-297/icons/xterm_48x48.xcf differ diff -Nru xterm-278/icons/xterm_48x48.xpm xterm-297/icons/xterm_48x48.xpm --- xterm-278/icons/xterm_48x48.xpm 2007-06-16 16:28:19.000000000 +0000 +++ xterm-297/icons/xterm_48x48.xpm 2012-10-07 22:56:42.000000000 +0000 @@ -1,53 +1,53 @@ /* XPM */ static char * xterm_48x48_xpm[] = { "48 48 2 1", -" c #000000", -". c #FFFFFF", -"................................................", -"...... ........", -"..... .................................. ......", -"..... ... ... . .....", -"..... .. ............................ .. .. ....", -"..... . .............................. . ... ...", -"..... . . .... ................... . .... ..", -"..... . .. .... .................... . .... ..", -"..... . ... .. ..................... . .... ..", -"..... . ... .. ..................... . .... ..", -"..... . .... ...................... . .... ..", -"..... . .... ...................... . .... ..", -"..... . ..... ....................... . .... ..", -"..... . .... ...................... . .... ..", -"..... . .... ...................... . .... ..", -"..... . ... .. ..................... . .... ..", -"..... . ... .. ..................... . .... ..", -"..... . .. .... .................... . .... ..", -"..... . . .... ................... . .... ..", -"..... . .............................. . .... ..", -"..... . .............................. . .... ..", -"..... . . . .. ... ... . . .... ..", -"..... . ... .... ...... ... .. ... . . .... ..", -"..... . ... .... ...... ... .. . . . . . .... ..", -"..... . ... .... ... ... . . . . . .... ..", -"..... . ... .... ...... . .... .. .. . . ... ...", -"..... . ... .... ...... .. ... .. .. . . ... ...", -"..... . ... .... .. ... .. ..... . . .. ....", -"..... . .............................. . .. ....", -"..... . .............................. . . .....", -"..... .. ............................ .. . .....", -"..... ... ... ......", -"..... .................................. ......", -"...... ........", -"................................................", -"................................................", -"...... ......", -"..... .................................. ......", -"..... . . . . . . . . . . . . . . . . .. ......", -".... .................................. . ......", -".... . . . . . . . . . . . . . . . . .. . ......", -"... .................................. .. ......", -"... . . . . . . . . . . . . . . . . .. .. ......", -".. .................................. .. .......", -".. . . . . . ........", -". .................................. . .........", -". ..........", -"................................................"}; +" c None", +". c #000000", +" ", +" .................................. ", +" . .. ", +" . ............................ . . ", +" . . . . . ", +" . . . . . ", +" . . . . . ", +" . . ... ... . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . .. . . . ", +" . . .. . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . . . . . . ", +" . . ... ... . . . ", +" . . . . . ", +" . . . . . ", +" . . . . . ", +" . . . . . ", +" . . ..... ..... .... . . . . . ", +" . . . . . . .. .. . . . ", +" . . . . . . .. .. . . . ", +" . . . ..... .... . . . . . . . ", +" . . . . . . . ... . . . .. ", +" . . . . . . . . . . . . ", +" . . . ..... . . . . . . .. ", +" . . . . . ", +" . . . . .. ", +" . . . . . ", +" . ............................ ... ", +" . .. ", +" .................................. ", +" ", +" ", +" .................................... ", +" . .. ", +" . . . . . . . . . . . . . . . . . ... ", +" . . . ", +" . . . . . . . . . . . . . . . . . .. . ", +" . . . ", +" .. . . . . . . . . . . . . . . . . .. . ", +" . . . ", +" .. .. .......................... .... . ", +" . . . ", +" ..................................... ", +" "}; diff -Nru xterm-278/input.c xterm-297/input.c --- xterm-278/input.c 2012-01-07 02:01:05.000000000 +0000 +++ xterm-297/input.c 2013-08-21 12:03:16.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: input.c,v 1.333 2012/01/07 02:01:05 tom Exp $ */ +/* $XTermId: input.c,v 1.346 2013/08/21 12:03:16 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2011,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -74,6 +74,10 @@ #include #endif +#ifdef HAVE_XKBKEYCODETOKEYSYM +#include +#endif + #include #include #include @@ -139,42 +143,6 @@ static void hpfuncvalue(ANSI *, KEY_DATA *); static void scofuncvalue(ANSI *, KEY_DATA *); -#if OPT_TRACE -static const char * -ModifierName(unsigned modifier) -{ - const char *s = ""; - if (modifier & ShiftMask) - s = " Shift"; - else if (modifier & LockMask) - s = " Lock"; - else if (modifier & ControlMask) - s = " Control"; - else if (modifier & Mod1Mask) - s = " Mod1"; - else if (modifier & Mod2Mask) - s = " Mod2"; - else if (modifier & Mod3Mask) - s = " Mod3"; - else if (modifier & Mod4Mask) - s = " Mod4"; - else if (modifier & Mod5Mask) - s = " Mod5"; - return s; -} - -#define FMT_MODIFIER_NAMES "%s%s%s%s%s%s%s%s" -#define ARG_MODIFIER_NAMES(state) \ - ModifierName(state & ShiftMask), \ - ModifierName(state & LockMask), \ - ModifierName(state & ControlMask), \ - ModifierName(state & Mod1Mask), \ - ModifierName(state & Mod2Mask), \ - ModifierName(state & Mod3Mask), \ - ModifierName(state & Mod4Mask), \ - ModifierName(state & Mod5Mask) -#endif - static void AdjustAfterInput(XtermWidget xw) { @@ -201,21 +169,60 @@ /* * Return true if the key is on the editing keypad. This overlaps with - * IsCursorKey() and IsKeypadKey() and must be tested before those macro to + * IsCursorKey() and IsKeypadKey() and must be tested before those macros to * distinguish it from them. + * + * VT220 emulation uses the VT100 numeric keypad as well as a 6-key + * editing keypad. Here's a picture of the VT220 editing keypad: + * +--------+--------+--------+ + * | Find | Insert | Remove | + * +--------+--------+--------+ + * | Select | Prev | Next | + * +--------+--------+--------+ + * + * and the similar Sun and PC keypads: + * +--------+--------+--------+ + * | Insert | Home | PageUp | + * +--------+--------+--------+ + * | Delete | End | PageDn | + * +--------+--------+--------+ */ static Bool -IsEditFunctionKey(KeySym keysym) +IsEditKeypad(XtermWidget xw, KeySym keysym) { + Bool result; + switch (keysym) { - case XK_Prior: /* editing keypad */ - case XK_Next: /* editing keypad */ - case XK_Insert: /* editing keypad */ - case XK_Find: /* editing keypad */ - case XK_Select: /* editing keypad */ + case XK_Delete: + result = !xtermDeleteIsDEL(xw); + break; + case XK_Prior: + case XK_Next: + case XK_Insert: + case XK_Find: + case XK_Select: #ifdef DXK_Remove - case DXK_Remove: /* editing keypad */ + case DXK_Remove: #endif + result = True; + break; + default: + result = False; + break; + } + return result; +} + +/* + * Editing-keypad, plus other editing keys which are not included in the + * other macros. + */ +static Bool +IsEditFunctionKey(XtermWidget xw, KeySym keysym) +{ + Bool result; + + switch (keysym) { #ifdef XK_KP_Delete case XK_KP_Delete: /* editing key on numeric keypad */ case XK_KP_Insert: /* editing key on numeric keypad */ @@ -223,10 +230,13 @@ #ifdef XK_ISO_Left_Tab case XK_ISO_Left_Tab: #endif - return True; + result = True; + break; default: - return False; + result = IsEditKeypad(xw, keysym); + break; } + return result; } #if OPT_MOD_FKEYS @@ -301,24 +311,44 @@ * would be Home (XK_KP_Home). The other modifiers work, subject to the * usual window-manager assignments. */ +#if OPT_SUNPC_KBD +#define LegacyAllows(code) (!is_legacy || (code & xw->keyboard.modify_now.allow_keys) != 0) +#else +#define LegacyAllows(code) True +#endif + static Bool allowModifierParm(XtermWidget xw, KEY_DATA * kd) { TKeyboard *keyboard = &(xw->keyboard); TScreen *screen = TScreenOf(xw); int keypad_mode = ((keyboard->flags & MODE_DECKPAM) != 0); - + int is_legacy = (keyboard->type == keyboardIsLegacy); Bool result = False; - (void) screen; - if (!(IsKeypadKey(kd->keysym) && keypad_mode) #if OPT_SUNPC_KBD - && keyboard->type != keyboardIsVT220 + if (keyboard->type == keyboardIsVT220) + is_legacy = True; #endif + + (void) screen; #if OPT_VT52_MODE - && screen->vtXX_level != 0 + if (screen->vtXX_level != 0) #endif - ) { + { + if (IsCursorKey(kd->keysym) || IsEditFunctionKey(xw, kd->keysym)) { + result = LegacyAllows(2); + } else if (IsKeypadKey(kd->keysym)) { + if (keypad_mode) { + result = LegacyAllows(1); + } + } else if (IsFunctionKey(kd->keysym)) { + result = LegacyAllows(4); + } else if (IsMiscFunctionKey(kd->keysym)) { + result = LegacyAllows(8); + } + } + if (xw->keyboard.modify_now.other_keys != 0) { result = True; } return result; @@ -349,19 +379,15 @@ { unsigned result = 0; #if OPT_NUM_LOCK - if (param > MOD_NONE - && ((ShiftMask - | ControlMask - | xw->misc.alt_mods - | xw->misc.meta_mods) & xw->misc.other_mods) == 0) { + if (param > MOD_NONE) { if ((param - MOD_NONE) & MOD_SHIFT) UIntSet(result, ShiftMask); if ((param - MOD_NONE) & MOD_CTRL) UIntSet(result, ControlMask); if ((param - MOD_NONE) & MOD_ALT) - UIntSet(result, xw->misc.alt_mods); + UIntSet(result, xw->work.alt_mods); if ((param - MOD_NONE) & MOD_META) - UIntSet(result, xw->misc.meta_mods); + UIntSet(result, xw->work.meta_mods); } #else (void) xw; @@ -383,23 +409,21 @@ TRACE(("xtermStateToParam %#x\n", state)); #if OPT_NUM_LOCK - if ((state & xw->misc.other_mods) == 0) { - if (state & ShiftMask) { - modify_parm += MOD_SHIFT; - UIntClr(state, ShiftMask); - } - if (state & ControlMask) { - modify_parm += MOD_CTRL; - UIntClr(state, ControlMask); - } - if ((state & xw->misc.alt_mods) != 0) { - modify_parm += MOD_ALT; - UIntClr(state, xw->misc.alt_mods); - } - if ((state & xw->misc.meta_mods) != 0) { - modify_parm += MOD_META; - UIntClr(state, xw->misc.meta_mods); - } + if (state & ShiftMask) { + modify_parm += MOD_SHIFT; + UIntClr(state, ShiftMask); + } + if (state & ControlMask) { + modify_parm += MOD_CTRL; + UIntClr(state, ControlMask); + } + if ((state & xw->work.alt_mods) != 0) { + modify_parm += MOD_ALT; + UIntClr(state, xw->work.alt_mods); + } + if ((state & xw->work.meta_mods) != 0) { + modify_parm += MOD_META; + UIntClr(state, xw->work.meta_mods); } if (modify_parm == MOD_NONE) modify_parm = 0; @@ -463,7 +487,7 @@ allowedCharModifiers(XtermWidget xw, unsigned state, KEY_DATA * kd) { #if OPT_NUM_LOCK - unsigned a_or_m = (state & (xw->misc.meta_mods | xw->misc.alt_mods)); + unsigned a_or_m = (state & (xw->work.meta_mods | xw->work.alt_mods)); #else unsigned a_or_m = 0; #endif @@ -500,11 +524,11 @@ } #if OPT_NUM_LOCK result = filterAltMeta(result, - xw->misc.meta_mods, + xw->work.meta_mods, TScreenOf(xw)->meta_sends_esc, kd); if (TScreenOf(xw)->alt_is_not_meta) { result = filterAltMeta(result, - xw->misc.alt_mods, + xw->work.alt_mods, TScreenOf(xw)->alt_sends_esc, kd); } #endif @@ -534,16 +558,12 @@ * Exclude the keys already covered by a modifier. */ if (kd->is_fkey - || IsEditFunctionKey(kd->keysym) + || IsEditFunctionKey(xw, kd->keysym) || IsKeypadKey(kd->keysym) || IsCursorKey(kd->keysym) || IsPFKey(kd->keysym) || IsMiscFunctionKey(kd->keysym) - || IsPrivateKeypadKey(kd->keysym) -#if OPT_NUM_LOCK - || (state & xw->misc.other_mods) != 0 -#endif - ) { + || IsPrivateKeypadKey(kd->keysym)) { result = False; } else if (modify_parm != 0) { if (IsBackarrowToggle(keyboard, kd->keysym, state)) { @@ -644,7 +664,7 @@ * for more information. */ static Bool -modifyOtherKey(ANSI * reply, int input_char, unsigned modify_parm, int format_keys) +modifyOtherKey(ANSI *reply, int input_char, unsigned modify_parm, int format_keys) { Bool result = False; @@ -667,7 +687,7 @@ } static void -modifyCursorKey(ANSI * reply, int modify, unsigned *modify_parm) +modifyCursorKey(ANSI *reply, int modify, unsigned *modify_parm) { if (*modify_parm != 0) { if (modify < 0) { @@ -790,73 +810,58 @@ return result; } -void -Input(XtermWidget xw, - XKeyEvent * event, - Bool eightbit) +static Boolean +lookupKeyData(KEY_DATA * kd, XtermWidget xw, XKeyEvent * event) { - Char *string; - - TKeyboard *keyboard = &(xw->keyboard); TScreen *screen = TScreenOf(xw); + TKeyboard *keyboard = &(xw->keyboard); + Boolean result = True; - int j; - int key = False; - ANSI reply; - int dec_code; - unsigned modify_parm = 0; - int keypad_mode = ((keyboard->flags & MODE_DECKPAM) != 0); - unsigned evt_state = event->state; - unsigned mod_state; - KEY_DATA kd; - - /* Ignore characters typed at the keyboard */ - if (keyboard->flags & MODE_KAM) - return; + TRACE(("%s %#x\n", visibleEventType(event->type), event->keycode)); - kd.keysym = 0; - kd.is_fkey = False; + kd->keysym = 0; + kd->is_fkey = False; #if OPT_TCAP_QUERY if (screen->tc_query_code >= 0) { - kd.keysym = (KeySym) screen->tc_query_code; - kd.is_fkey = screen->tc_query_fkey; - if (kd.keysym != XK_BackSpace) { - kd.nbytes = 0; - kd.strbuf[0] = 0; + kd->keysym = (KeySym) screen->tc_query_code; + kd->is_fkey = screen->tc_query_fkey; + if (kd->keysym != XK_BackSpace) { + kd->nbytes = 0; + kd->strbuf[0] = 0; } else { - kd.nbytes = 1; - kd.strbuf[0] = 8; + kd->nbytes = 1; + kd->strbuf[0] = 8; } } else #endif { #if OPT_I18N_SUPPORT && OPT_INPUT_METHOD TInput *input = lookupTInput(xw, (Widget) xw); - if (input->xic) { + if (input && input->xic) { Status status_return; #if OPT_WIDE_CHARS if (screen->utf8_mode) { - kd.nbytes = Xutf8LookupString(input->xic, event, - kd.strbuf, (int) sizeof(kd.strbuf), - &kd.keysym, &status_return); + kd->nbytes = Xutf8LookupString(input->xic, event, + kd->strbuf, (int) sizeof(kd->strbuf), + &(kd->keysym), &status_return); } else #endif { - kd.nbytes = XmbLookupString(input->xic, event, - kd.strbuf, (int) sizeof(kd.strbuf), - &kd.keysym, &status_return); + kd->nbytes = XmbLookupString(input->xic, event, + kd->strbuf, (int) sizeof(kd->strbuf), + &(kd->keysym), &status_return); } #if OPT_MOD_FKEYS /* * Fill-in some code useful with IsControlAlias(): */ if (status_return == XLookupBoth - && kd.nbytes <= 1 - && !IsPredefinedKey(kd.keysym) + && kd->nbytes <= 1 + && !IsPredefinedKey(kd->keysym) && (keyboard->modify_now.other_keys > 1) - && !IsControlInput(&kd)) { - kd.nbytes = 1; - kd.strbuf[0] = (char) kd.keysym; + && !IsControlInput(kd)) { + kd->nbytes = 1; + kd->strbuf[0] = (char) kd->keysym; } #endif /* OPT_MOD_FKEYS */ } else @@ -864,11 +869,40 @@ { static XComposeStatus compose_status = {NULL, 0}; - kd.nbytes = XLookupString(event, kd.strbuf, (int) sizeof(kd.strbuf), - &kd.keysym, &compose_status); + kd->nbytes = XLookupString(event, + kd->strbuf, (int) sizeof(kd->strbuf), + &(kd->keysym), &compose_status); } - kd.is_fkey = IsFunctionKey(kd.keysym); + kd->is_fkey = IsFunctionKey(kd->keysym); } + return result; +} + +void +Input(XtermWidget xw, + XKeyEvent * event, + Bool eightbit) +{ + Char *string; + + TKeyboard *keyboard = &(xw->keyboard); + TScreen *screen = TScreenOf(xw); + + int j; + int key = False; + ANSI reply; + int dec_code; + unsigned modify_parm = 0; + int keypad_mode = ((keyboard->flags & MODE_DECKPAM) != 0); + unsigned evt_state = event->state; + unsigned mod_state; + KEY_DATA kd; + + /* Ignore characters typed at the keyboard */ + if (keyboard->flags & MODE_KAM) + return; + + lookupKeyData(&kd, xw, event); memset(&reply, 0, sizeof(reply)); @@ -888,7 +922,7 @@ IsPFKey(kd.keysym) ? " PFKey" : "", kd.is_fkey ? " FKey" : "", IsMiscFunctionKey(kd.keysym) ? " MiscFKey" : "", - IsEditFunctionKey(kd.keysym) ? " EditFkey" : "")); + IsEditFunctionKey(xw, kd.keysym) ? " EditFkey" : "")); #if OPT_SUNPC_KBD /* @@ -934,7 +968,7 @@ if (kd.nbytes == 1 && IsKeypadKey(kd.keysym) && xw->misc.real_NumLock - && (xw->misc.num_lock & evt_state) != 0) { + && (xw->work.num_lock & evt_state) != 0) { keypad_mode = 0; TRACE(("...Input num_lock, force keypad_mode off\n")); } @@ -1093,7 +1127,7 @@ modifyCursorKey(&reply, ((kd.is_fkey || IsMiscFunctionKey(kd.keysym) - || IsEditFunctionKey(kd.keysym)) + || IsEditFunctionKey(xw, kd.keysym)) ? keyboard->modify_now.function_keys : keyboard->modify_now.cursor_keys), &modify_parm); @@ -1101,7 +1135,7 @@ unparseseq(xw, &reply); } else if (((kd.is_fkey || IsMiscFunctionKey(kd.keysym) - || IsEditFunctionKey(kd.keysym)) + || IsEditFunctionKey(xw, kd.keysym)) #if OPT_MOD_FKEYS && !ModifyOtherKeys(xw, evt_state, &kd, modify_parm) #endif @@ -1247,9 +1281,9 @@ */ if (kd.nbytes != 0) { if (screen->meta_sends_esc - && (evt_state & xw->misc.meta_mods) != 0) { + && (evt_state & xw->work.meta_mods) != 0) { TRACE(("...input-char is modified by META\n")); - UIntClr(evt_state, xw->misc.meta_mods); + UIntClr(evt_state, xw->work.meta_mods); eightbit = False; prefix = ANSI_ESC; } else if (eightbit) { @@ -1257,8 +1291,8 @@ TRACE(("...input-char is shifted by META\n")); } if (screen->alt_is_not_meta - && (evt_state & xw->misc.alt_mods) != 0) { - UIntClr(evt_state, xw->misc.alt_mods); + && (evt_state & xw->work.alt_mods) != 0) { + UIntClr(evt_state, xw->work.alt_mods); if (screen->alt_sends_esc) { TRACE(("...input-char is modified by ALT\n")); eightbit = False; @@ -1313,7 +1347,8 @@ { /* VT220 & up: National Replacement Characters */ if ((xw->flags & NATIONAL) != 0) { - unsigned cmp = xtermCharSetIn(CharOf(kd.strbuf[0]), + unsigned cmp = xtermCharSetIn(screen, + CharOf(kd.strbuf[0]), screen->keyboard_dialect[0]); TRACE(("...input NRC %d, %s %d\n", CharOf(kd.strbuf[0]), @@ -1347,7 +1382,7 @@ } void -StringInput(XtermWidget xw, const Char * string, size_t nbytes) +StringInput(XtermWidget xw, const Char *string, size_t nbytes) { TRACE(("InputString (%s,%lu)\n", visibleChars(string, (unsigned) nbytes), @@ -1430,7 +1465,7 @@ } static void -hpfuncvalue(ANSI * reply, KEY_DATA * kd) +hpfuncvalue(ANSI *reply, KEY_DATA * kd) { #if OPT_HP_FUNC_KEYS int result; @@ -1487,7 +1522,7 @@ } static void -scofuncvalue(ANSI * reply, KEY_DATA * kd) +scofuncvalue(ANSI *reply, KEY_DATA * kd) { #if OPT_SCO_FUNC_KEYS int result; @@ -1577,7 +1612,7 @@ } static void -sunfuncvalue(ANSI * reply, KEY_DATA * kd) +sunfuncvalue(ANSI *reply, KEY_DATA * kd) { #if OPT_SUN_FUNC_KEYS ParmType result; @@ -1712,7 +1747,7 @@ } else if (ch == '\\') { escape = True; } else if (ch == '"') { - quoted = (Boolean) ! quoted; + quoted = (Boolean) !quoted; } else if (!quoted && isName(ch)) { const char *next = skipName(--parse); size_t need = (size_t) (next - parse); @@ -1924,10 +1959,10 @@ } #endif -#define SaveMask(name) xw->misc.name |= (unsigned) mask;\ - TRACE(("SaveMask(%s) %#x (%#x is%s modifier)\n", \ - #name, \ - xw->misc.name, (unsigned) mask, \ +#define SaveMask(name) xw->work.name |= (unsigned) mask;\ + TRACE(("SaveMask(%#x -> %s) %#x (%#x is%s modifier)\n", \ + (unsigned) keysym, #name, \ + xw->work.name, (unsigned) mask, \ ModifierName((unsigned) mask))); /* * Determine which modifier mask (if any) applies to the Num_Lock keysym. @@ -1996,7 +2031,11 @@ continue; for (l = 0; l < keysyms_per_keycode; ++l) { +#ifdef HAVE_XKBKEYCODETOKEYSYM + keysym = XkbKeycodeToKeysym(dpy, code, 0, l); +#else keysym = XKeycodeToKeysym(dpy, code, l); +#endif if (keysym == NoSymbol) { /* EMPTY */ ; } else if (keysym == XK_Num_Lock) { @@ -2005,23 +2044,6 @@ SaveMask(alt_mods); } else if (keysym == XK_Meta_L || keysym == XK_Meta_R) { SaveMask(meta_mods); - } else if (mask == ShiftMask - && (keysym == XK_Shift_L - || keysym == XK_Shift_R)) { - /* EMPTY */ ; - } else if (mask == ControlMask - && (keysym == XK_Control_L - || keysym == XK_Control_R)) { - /* EMPTY */ ; - } else if (mask == LockMask - && (keysym == XK_Caps_Lock)) { - /* EMPTY */ ; - } else if (keysym == XK_Mode_switch -#ifdef XK_ISO_Level3_Shift - || keysym == XK_ISO_Level3_Shift -#endif - ) { - SaveMask(other_mods); } } } @@ -2048,20 +2070,20 @@ * If the Alt modifier is used in translations, we would rather not * use it to modify function-keys when NumLock is active. */ - if ((xw->misc.alt_mods != 0) + if ((xw->work.alt_mods != 0) && xtermHasTranslation(xw, "alt", True)) { TRACE(("ALT is used as a modifier in translations (ignore mask)\n")); - xw->misc.alt_mods = 0; + xw->work.alt_mods = 0; } /* * If the Meta modifier is used in translations, we would rather not * use it to modify function-keys. */ - if ((xw->misc.meta_mods != 0) + if ((xw->work.meta_mods != 0) && xtermHasTranslation(xw, "meta", True)) { TRACE(("META is used as a modifier in translations\n")); - xw->misc.meta_mods = 0; + xw->work.meta_mods = 0; } } diff -Nru xterm-278/koi8rxterm.man xterm-297/koi8rxterm.man --- xterm-278/koi8rxterm.man 2011-08-16 09:44:32.000000000 +0000 +++ xterm-297/koi8rxterm.man 2013-01-01 00:43:18.000000000 +0000 @@ -1,4 +1,4 @@ -.\" $XTermId: koi8rxterm.man,v 1.4 2011/08/16 09:44:32 tom Exp $ +.\" $XTermId: koi8rxterm.man,v 1.6 2013/01/01 00:43:18 tom Exp $ .\" .\" Copyright 2004 Branden Robinson .\" @@ -19,22 +19,33 @@ .\" 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 koi8rxterm 1 "2004-12-19" "Debian Project" +.\" +.ds N Koi8rxterm +.ds n koi8rxterm +.\" +.ie \n(.g .ds AQ \(aq +.el .ds AQ ' +.ie \n(.g .ds `` \(lq +.el .ds `` `` +.ie \n(.g .ds '' \(rq +.el .ds '' '' +.\" +.TH KOI8RXTERM 1 "__app_date__" "__app_version__" "X Window System" .SH NAME koi8rxterm \- X terminal emulator for KOI8-R environments .SH SYNOPSIS -.B koi8rxterm +.B \*n [ .I xterm-options ] .SH DESCRIPTION -.B koi8rxterm +.B \*n is a wrapper around the .BR xterm(1) -program that invokes the latter program with the \(oqKOI8R__default_class__\(cq X +program that invokes the latter program with the \*(``KOI8R__default_class__\*('' X resource class set. All arguments to -.B koi8rxterm +.B \*n are passed to .B xterm without processing; the @@ -47,9 +58,9 @@ manual page for more information on .IR xterm-options . .PP -The environment's locale settings (see \(lqENVIRONMENT\(rq below) are +The environment's locale settings (see \*(``ENVIRONMENT\*('' below) are used to discern the locale's character set. -If no current locale can be determined, the locale \(oqru_RU.KOI8-R\(cq +If no current locale can be determined, the locale \*(``ru_RU.KOI8-R\*('' (the Russian language as used in the territory of Russia, with the KOI8-R character set) is assumed. The @@ -57,20 +68,20 @@ utility is used to determine whether the system supports the selected locale. If it does not, -.B koi8rxterm +.B \*n will exit with an error and report the output of .BR locale . .PP -.B Note: koi8rxterm +.B Note: \*n may produce unexpected results if the current locale is set to one in which the KOI8-R character encoding is not supported, or if fonts using that encoding are not available. -In the Debian system, the \(oqxfonts\-cyrillic\(cq package provides the +In the Debian system, the \*(``xfonts\-cyrillic\*('' package provides the fonts that -.B koi8rxterm +.B \*n uses by default. To change the fonts -.B koi8rxterm +.B \*n uses, edit the .I __apploaddir__/KOI8R__default_class__ file. @@ -84,7 +95,7 @@ The values of these variables are checked, in order, to determine the character set used by the current locale. .SH AUTHOR -.B koi8rxterm +.B \*n was written by Branden Robinson and is very heavily based on .BR uxterm , by Thomas Dickey. diff -Nru xterm-278/linedata.c xterm-297/linedata.c --- xterm-278/linedata.c 2011-09-11 14:59:39.000000000 +0000 +++ xterm-297/linedata.c 2013-02-08 00:11:16.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: linedata.c,v 1.80 2011/09/11 14:59:39 tom Exp $ */ +/* $XTermId: linedata.c,v 1.82 2013/02/08 00:11:16 tom Exp $ */ /* - * Copyright 2009-2010,2011 by Thomas E. Dickey + * Copyright 2009-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -31,7 +31,6 @@ */ #include -#include /* FIXME - needed for 'term' */ #include diff -Nru xterm-278/main.c xterm-297/main.c --- xterm-278/main.c 2012-01-06 22:04:40.000000000 +0000 +++ xterm-297/main.c 2013-05-27 22:11:11.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: main.c,v 1.678 2012/01/06 22:04:40 tom Exp $ */ +/* $XTermId: main.c,v 1.727 2013/05/27 22:11:11 tom Exp $ */ /* - * Copyright 2002-2010,2011 by Thomas E. Dickey + * Copyright 2002-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -90,6 +90,7 @@ #define RES_OFFSET(field) XtOffsetOf(XTERM_RESOURCE, field) #include +#include #include #include @@ -445,7 +446,7 @@ #endif #ifndef VMS -static SIGNAL_T reapchild(int /* n */ ); +static void reapchild(int /* n */ ); static int spawnXTerm(XtermWidget /* xw */ ); static void remove_termcap_entry(char *, const char *); #ifdef USE_PTY_SEARCH @@ -832,6 +833,7 @@ { Sres("iconGeometry", "IconGeometry", icon_geometry, NULL), Sres(XtNtitle, XtCTitle, title, NULL), + Sres(XtNiconHint, XtCIconHint, icon_hint, NULL), Sres(XtNiconName, XtCIconName, icon_name, NULL), Sres("termName", "TermName", term_name, NULL), Sres("ttyModes", "TtyModes", tty_modes, NULL), @@ -874,6 +876,7 @@ Bres("useInsertMode", "UseInsertMode", useInsertMode, False), #if OPT_ZICONBEEP Ires("zIconBeep", "ZIconBeep", zIconBeep, 0), + Sres("zIconTitleFormat", "ZIconTitleFormat", zIconFormat, "*** %s"), #endif #if OPT_PTY_HANDSHAKE Bres("waitForMap", "WaitForMap", wait_for_map, False), @@ -1519,26 +1522,32 @@ *valuep = 0; if (atbest >= 0) { - if (!exact && ambiguous1 >= 0 && ambiguous2 >= 0) { - xtermWarning( - "ambiguous option \"%s\" vs \"%s\"\n", - ITEM(ambiguous1)->option, - ITEM(ambiguous2)->option); - } result = ITEM(atbest); - TRACE(("...result %s\n", result->option)); - /* expand abbreviations */ - if (result->argKind != XrmoptionStickyArg - && strcmp(argv[*num], x_strdup(result->option))) { - argv[*num] = x_strdup(result->option); + if (!exact) { + if (ambiguous1 >= 0 && ambiguous2 >= 0) { + xtermWarning("ambiguous option \"%s\" vs \"%s\"\n", + ITEM(ambiguous1)->option, + ITEM(ambiguous2)->option); + } else if (strlen(option) > strlen(result->option)) { + result = 0; + } } + if (result != 0) { + TRACE(("...result %s\n", result->option)); + /* expand abbreviations */ + if (result->argKind != XrmoptionStickyArg) { + if (strcmp(argv[*num], result->option)) { + argv[*num] = x_strdup(result->option); + } + } - /* adjust (*num) to skip option value */ - (*num) += countArg(result); - TRACE(("...next %s\n", NonNull(argv[*num]))); - if (result->argKind == XrmoptionSkipArg) { - *valuep = argv[*num]; - TRACE(("...parameter %s\n", NonNull(*valuep))); + /* adjust (*num) to skip option value */ + (*num) += countArg(result); + TRACE(("...next %s\n", NonNull(argv[*num]))); + if (result->argKind == XrmoptionSkipArg) { + *valuep = argv[*num]; + TRACE(("...parameter %s\n", NonNull(*valuep))); + } } } #undef ITEM @@ -1847,7 +1856,7 @@ return (oact.sa_handler); } -#endif /* linux && _POSIX_SOURCE */ +#endif /* USE_POSIX_SIGNALS */ #if defined(DISABLE_SETUID) || defined(USE_UTMP_SETGID) static void @@ -1991,7 +2000,9 @@ for (n = 1; n < argc; n++) { if ((option_ptr = parseArg(&n, argv, &option_value)) == 0) { - if (isOption(argv[n])) { + if (argv[n] == 0) { + break; + } else if (isOption(argv[n])) { Syntax(argv[n]); } else if (explicit_shname != 0) { xtermWarning("Explicit shell already was %s\n", explicit_shname); @@ -2171,7 +2182,7 @@ my_class, optionDescList, XtNumber(optionDescList), - &argc, argv, + &argc, (String *) argv, fallback_resources, sessionShellWidgetClass, NULL, 0); @@ -2219,12 +2230,7 @@ override_tty_modes = True; } } -#if OPT_ZICONBEEP - if (resource.zIconBeep > 100 || resource.zIconBeep < -100) { - resource.zIconBeep = 0; /* was 100, but I prefer to defaulting off. */ - xtermWarning("a number between -100 and 100 is required for zIconBeep. 0 used by default\n"); - } -#endif /* OPT_ZICONBEEP */ + initZIconBeep(); hold_screen = resource.hold_screen ? 1 : 0; if (resource.icon_geometry != NULL) { int scr, junk; @@ -2386,9 +2392,10 @@ XtSetArg(args[0], XtNtitle, resource.title); XtSetArg(args[1], XtNiconName, resource.icon_name); - TRACE(("setting:\n\ttitle \"%s\"\n\ticon \"%s\"\n\tbased on command \"%s\"\n", + TRACE(("setting:\n\ttitle \"%s\"\n\ticon \"%s\"\n\thint \"%s\"\n\tbased on command \"%s\"\n", resource.title, resource.icon_name, + NonNull(resource.icon_hint), *command_to_exec)); XtSetValues(toplevel, args, 2); @@ -2425,21 +2432,19 @@ x_appendargv(command_to_exec_with_luit, command_to_exec); } TRACE_ARGV("luit command", command_to_exec_with_luit); + xtermSetenv("XTERM_FILTER", *command_to_exec_with_luit); } #endif -#ifdef DEBUG - { + if_DEBUG({ /* Set up stderr properly. Opening this log file cannot be done securely by a privileged xterm process (although we try), so the debug feature is disabled by default. */ char dbglogfile[TIMESTAMP_LEN + 20]; int i = -1; - if (debug) { - timestamp_filename(dbglogfile, "xterm.debug.log."); - if (creat_as(save_ruid, save_rgid, False, dbglogfile, 0600) > 0) { - i = open(dbglogfile, O_WRONLY | O_TRUNC); - } + timestamp_filename(dbglogfile, "xterm.debug.log."); + if (creat_as(save_ruid, save_rgid, False, dbglogfile, 0600) > 0) { + i = open(dbglogfile, O_WRONLY | O_TRUNC); } if (i >= 0) { dup2(i, 2); @@ -2447,8 +2452,7 @@ /* mark this file as close on exec */ (void) fcntl(i, F_SETFD, 1); } - } -#endif /* DEBUG */ + }); spawnXTerm(term); @@ -2527,10 +2531,9 @@ : (1 + screen->respond)); #endif /* !VMS */ -#ifdef DEBUG - if (debug) - printf("debugging on\n"); -#endif /* DEBUG */ + if_DEBUG({ + TRACE(("debugging on pid %d\n", (int) getpid())); + }); XSetErrorHandler(xerror); XSetIOErrorHandler(xioerror); IceSetIOErrorHandler(ice_error); @@ -2598,7 +2601,9 @@ { int result = 1; -#if defined(HAVE_POSIX_OPENPT) && defined(HAVE_PTSNAME) +#if defined(USE_OPENPTY) + result = openpty(pty, &opened_tty, ttydev, NULL, NULL); +#elif defined(HAVE_POSIX_OPENPT) && defined(HAVE_PTSNAME) && defined(HAVE_GRANTPT_PTY_ISATTY) if ((*pty = posix_openpt(O_RDWR)) >= 0) { char *name = ptsname(*pty); if (name != 0) { @@ -2612,19 +2617,11 @@ } #endif #elif defined(PUCC_PTYD) - result = ((*pty = openrpty(ttydev, ptydev, (resource.utmpInhibit ? OPTY_NOP : OPTY_LOGIN), save_ruid, from)) < 0); - -#elif defined(USE_OPENPTY) - - result = openpty(pty, &opened_tty, ttydev, NULL, NULL); - #elif defined(__QNXNTO__) - result = pty_search(pty); - #else #if defined(USE_USG_PTYS) || defined(__CYGWIN__) #ifdef __GLIBC__ /* if __GLIBC__ and USE_USG_PTYS, we know glibc >= 2.1 */ @@ -2773,6 +2770,11 @@ } else { result = -1; } + TRACE(("get_pty(ttydev=%s, ptydev=%s) %s fd=%d (utmp setgid)\n", + ttydev != 0 ? ttydev : "?", + ptydev != 0 ? ptydev : "?", + result ? "FAIL" : "OK", + pty != 0 ? *pty : -1)); return result; } #endif @@ -2886,11 +2888,11 @@ }; /* ARGSUSED */ -static SIGNAL_T +static void hungtty(int i GCC_UNUSED) { + DEBUG_MSG("handle:hungtty\n"); siglongjmp(env, 1); - SIGNAL_RETURN; } #if OPT_PTY_HANDSHAKE @@ -2980,7 +2982,7 @@ handshake.status = PTY_FATALERROR; handshake.error = errno; handshake.fatal_error = error; - strcpy(handshake.buffer, ttydev); + strncpy(handshake.buffer, ttydev, sizeof(handshake.buffer)); if (resource.ptyHandshake && (cp_pipe[1] >= 0)) { TRACE(("HsSysError errno=%d, error=%d device \"%s\"\n", @@ -3047,7 +3049,7 @@ TRACE_IDS; TRACE(("set_owner(%s, uid=%d, gid=%d, mode=%#o\n", - device, uid, gid, (unsigned) mode)); + device, (int) uid, (int) gid, (unsigned) mode)); if (chown(device, uid, gid) < 0) { why = errno; @@ -3070,7 +3072,7 @@ (unsigned long) mode, (unsigned long) (sb.st_mode & 0777U)); TRACE(("...stat uid=%d, gid=%d, mode=%#o\n", - sb.st_uid, sb.st_gid, (unsigned) sb.st_mode)); + (int) sb.st_uid, (int) sb.st_gid, (unsigned) sb.st_mode)); } } TRACE(("...chmod failed: %s\n", strerror(why))); @@ -3098,18 +3100,26 @@ find_utmp(struct UTMP_STR *tofind) { struct UTMP_STR *result; + struct UTMP_STR limited; struct UTMP_STR working; for (;;) { memset(&working, 0, sizeof(working)); working.ut_type = tofind->ut_type; - memcpy(working.ut_id, tofind->ut_id, sizeof(tofind->ut_id)); + strncpy(working.ut_id, tofind->ut_id, sizeof(tofind->ut_id)); #if defined(__digital__) && defined(__unix__) && (defined(OSMAJORVERSION) && OSMAJORVERSION < 5) working.ut_type = 0; #endif if ((result = call_getutid(&working)) == 0) break; - if (!strcmp(result->ut_line, tofind->ut_line)) + /* + * ut_line may not be null-terminated, but if it is, there may be + * garbage after the null. Use strncpy to ensure that the value + * we check is null-terminated (if there is enough space in the + * buffer), and that unused space is nulled. + */ + strncpy(limited.ut_line, result->ut_line, sizeof(result->ut_line)); + if (!memcmp(limited.ut_line, tofind->ut_line, sizeof(limited.ut_line))) break; /* * Solaris, IRIX64 and HPUX manpages say to fill the static area @@ -3178,7 +3188,8 @@ #endif /* sony */ #endif /* TERMIO_STRUCT */ - char *ptr, *shname, *shname_minus; + char *shell_path = 0; + char *shname, *shname_minus; int i; #if USE_NO_DEV_TTY int no_dev_tty = False; @@ -3373,6 +3384,7 @@ if (get_pty(&screen->respond, XDisplayString(screen->display))) { SysError(ERROR_PTYS); } + TRACE_TTYSIZE(screen->respond, "after get_pty"); #if OPT_INITIAL_ERASE if (resource.ptyInitialErase) { #ifdef TERMIO_STRUCT @@ -3443,7 +3455,7 @@ if (get_termcap(xw, next)) { free(TermName); TermName = next; - ok_termcap = True; + ok_termcap = True + 1; break; } else { free(next); @@ -3525,6 +3537,7 @@ TTYSIZE_COLS(ts), i)); #endif /* TTYSIZE_STRUCT */ +#if !defined(USE_OPENPTY) #if defined(USE_USG_PTYS) || defined(HAVE_POSIX_OPENPT) /* * utempter checks the ownership of the device; some implementations @@ -3534,7 +3547,9 @@ #endif #if !defined(USE_USG_PTYS) && defined(HAVE_POSIX_OPENPT) unlockpt(screen->respond); + TRACE_TTYSIZE(screen->respond, "after unlockpt"); #endif +#endif /* !USE_OPENPTY */ added_utmp_entry = False; #if defined(USE_UTEMPTER) @@ -3582,6 +3597,7 @@ setpgrp(); #endif unlockpt(screen->respond); + TRACE_TTYSIZE(screen->respond, "after unlockpt"); if ((pty_name = ptsname(screen->respond)) == 0) { SysError(ERROR_PTSNAME); } else if ((ptyfd = open(pty_name, O_RDWR)) < 0) { @@ -3639,6 +3655,8 @@ #if OPT_PTY_HANDSHAKE /* warning, goes for a long ways */ if (resource.ptyHandshake) { + char *ptr; + /* close parent's sides of the pipes */ close(cp_pipe[0]); close(pc_pipe[1]); @@ -3704,6 +3722,9 @@ IGNORE_RC(revoke(ttydev)); #endif if ((ttyfd = open(ttydev, O_RDWR)) >= 0) { + TRACE_TTYSIZE(ttyfd, "after open"); + TRACE_RC(i, SET_TTYSIZE(ttyfd, ts)); + TRACE_TTYSIZE(ttyfd, "after fixup"); #if defined(CRAY) && defined(TCSETCTTY) /* make /dev/tty work */ ioctl(ttyfd, TCSETCTTY, 0); @@ -3734,7 +3755,7 @@ /* let our master know that the open failed */ handshake.status = PTY_BAD; handshake.error = errno; - strcpy(handshake.buffer, ttydev); + strncpy(handshake.buffer, ttydev, sizeof(handshake.buffer)); TRACE_HANDSHAKE("writing", &handshake); IGNORE_RC(write(cp_pipe[1], (const char *) &handshake, @@ -3754,6 +3775,8 @@ } /* We have a new pty to try */ + if (ttyfd >= 0) + close(ttyfd); free(ttydev); ttydev = x_strdup(handshake.buffer); } @@ -3794,7 +3817,7 @@ /* input: nl->nl, don't ignore cr, cr->nl */ UIntClr(tio.c_iflag, (INLCR | IGNCR)); tio.c_iflag |= ICRNL; -#if OPT_WIDE_CHARS && defined(linux) && defined(IUTF8) +#if OPT_WIDE_CHARS && defined(IUTF8) #if OPT_LUIT_PROG if (command_to_exec_with_luit == 0) #endif @@ -4034,6 +4057,14 @@ xtermCopyEnv(environ); + /* + * standards.freedesktop.org/startup-notification-spec/ + * notes that this variable is used when a "reliable" mechanism is + * not available; in practice it must be unset to avoid confusing + * GTK applications. + */ + xtermUnsetenv("DESKTOP_STARTUP_ID"); + xtermSetenv("TERM", resource.term_name); if (!resource.term_name) *get_tcap_buffer(xw) = 0; @@ -4158,9 +4189,10 @@ if (!utret) TRACE(("getutid: NULL\n")); else - TRACE(("getutid: pid=%d type=%d user=%s line=%s id=%s\n", + TRACE(("getutid: pid=%d type=%d user=%s line=%.*s id=%.*s\n", (int) utret->ut_pid, utret->ut_type, utret->ut_user, - utret->ut_line, utret->ut_id)); + (int) sizeof(utret->ut_line), utret->ut_line, + (int) sizeof(utret->ut_id), utret->ut_id)); #endif /* set up the new entry */ @@ -4202,9 +4234,9 @@ if (!resource.utmpInhibit) { errno = 0; call_pututline(&utmp); - TRACE(("pututline: id %s, line %s, pid %ld, errno %d %s\n", - utmp.ut_id, - utmp.ut_line, + TRACE(("pututline: id %.*s, line %.*s, pid %ld, errno %d %s\n", + (int) sizeof(utmp.ut_id), utmp.ut_id, + (int) sizeof(utmp.ut_line), utmp.ut_line, (long) utmp.ut_pid, errno, (errno != 0) ? strerror(errno) : "")); } @@ -4218,7 +4250,7 @@ #else if (xw->misc.login_shell && (i = open(etc_wtmp, O_WRONLY | O_APPEND)) >= 0) { - write(i, (char *) &utmp, sizeof(utmp)); + IGNORE_RC(write(i, (char *) &utmp, sizeof(utmp))); close(i); } #endif @@ -4250,7 +4282,7 @@ utmp.ut_time = time((time_t *) 0); lseek(i, (long) (tslot * sizeof(utmp)), 0); - write(i, (char *) &utmp, sizeof(utmp)); + IGNORE_RC(write(i, (char *) &utmp, sizeof(utmp))); close(i); added_utmp_entry = True; #if defined(WTMP) @@ -4265,7 +4297,7 @@ (i = open(_U_LASTLOG, O_WRONLY)) >= 0) { lseek(i, (long) (screen->uid * sizeof(utmp)), 0); - write(i, (char *) &utmp, sizeof(utmp)); + IGNORE_RC(write(i, (char *) &utmp, sizeof(utmp))); close(i); } #endif /* WTMP or MNX_LASTLOG */ @@ -4308,7 +4340,7 @@ SetUtmpHost(lastlog.ll_host, screen); lastlog.ll_time = time((time_t *) 0); if (lseek(i, offset, 0) != (off_t) (-1)) { - write(i, (char *) &lastlog, size); + IGNORE_RC(write(i, (char *) &lastlog, size)); } close(i); } @@ -4326,7 +4358,7 @@ if (resource.ptyHandshake) { handshake.status = UTMP_ADDED; handshake.error = 0; - strcpy(handshake.buffer, ttydev); + strncpy(handshake.buffer, ttydev, sizeof(handshake.buffer)); TRACE_HANDSHAKE("writing", &handshake); IGNORE_RC(write(cp_pipe[1], (char *) &handshake, sizeof(handshake))); } @@ -4351,8 +4383,8 @@ #if OPT_PTY_HANDSHAKE if (resource.ptyHandshake) { /* mark the pipes as close on exec */ - fcntl(cp_pipe[1], F_SETFD, 1); - fcntl(pc_pipe[0], F_SETFD, 1); + (void) fcntl(cp_pipe[1], F_SETFD, 1); + (void) fcntl(pc_pipe[0], F_SETFD, 1); /* We are at the point where we are going to * exec our shell (or whatever). Let our parent @@ -4360,7 +4392,7 @@ */ handshake.status = PTY_GOOD; handshake.error = 0; - (void) strcpy(handshake.buffer, ttydev); + (void) strncpy(handshake.buffer, ttydev, sizeof(handshake.buffer)); TRACE_HANDSHAKE("writing", &handshake); IGNORE_RC(write(cp_pipe[1], (const char *) &handshake, @@ -4474,22 +4506,29 @@ * Incidentally, our setting of $SHELL tells luit to use that * program rather than choosing between $SHELL and "/bin/sh". */ - if ((ptr = explicit_shname) == NULL) { - if ((ptr = x_getenv("SHELL")) == NULL) { + if ((shell_path = explicit_shname) == NULL) { + if ((shell_path = x_getenv("SHELL")) == NULL) { if ((!OkPasswd(&pw) && !x_getpwuid(screen->uid, &pw)) - || *(ptr = pw.pw_shell) == 0) { - ptr = x_strdup("/bin/sh"); - } else if (ptr != 0) { - xtermSetenv("SHELL", ptr); + || *(shell_path = x_strdup(pw.pw_shell)) == 0) { + if (shell_path) + free(shell_path); + shell_path = x_strdup("/bin/sh"); + } else if (shell_path != 0) { + xtermSetenv("SHELL", shell_path); } } } else { xtermSetenv("SHELL", explicit_shname); } - xtermSetenv("XTERM_SHELL", ptr); + if (access(shell_path, X_OK) != 0) { + xtermPerror("Cannot use '%s' as shell", shell_path); + free(shell_path); + shell_path = x_strdup("/bin/sh"); + } + xtermSetenv("XTERM_SHELL", shell_path); - shname = x_basename(ptr); - TRACE(("shell path '%s' leaf '%s'\n", ptr, shname)); + shname = x_basename(shell_path); + TRACE(("shell path '%s' leaf '%s'\n", shell_path, shname)); #if OPT_LUIT_PROG /* @@ -4498,8 +4537,9 @@ * to command that the user gave anyway. */ if (command_to_exec_with_luit && command_to_exec) { - xtermSetenv("XTERM_SHELL", - xtermFindShell(*command_to_exec_with_luit, False)); + char *myShell = xtermFindShell(*command_to_exec_with_luit, False); + xtermSetenv("XTERM_SHELL", myShell); + free(myShell); TRACE_ARGV("spawning luit command", command_to_exec_with_luit); execvp(*command_to_exec_with_luit, command_to_exec_with_luit); xtermPerror("Can't execvp %s", *command_to_exec_with_luit); @@ -4507,12 +4547,14 @@ } #endif if (command_to_exec) { - xtermSetenv("XTERM_SHELL", - xtermFindShell(*command_to_exec, False)); + char *myShell = xtermFindShell(*command_to_exec, False); + xtermSetenv("XTERM_SHELL", myShell); + free(myShell); TRACE_ARGV("spawning command", command_to_exec); execvp(*command_to_exec, command_to_exec); if (command_to_exec[1] == 0) - execlp(ptr, shname, "-c", command_to_exec[0], (void *) 0); + execlp(shell_path, shname, "-c", command_to_exec[0], + (void *) 0); xtermPerror("Can't execvp %s", *command_to_exec); } #ifdef USE_SYSV_SIGHUP @@ -4552,13 +4594,14 @@ xtermPerror("Can't execvp %s", *command_to_exec_with_luit); } #endif - execlp(ptr, + execlp(shell_path, (xw->misc.login_shell ? shname_minus : shname), (void *) 0); /* Exec failed. */ - xtermPerror("Could not exec %s", ptr); + xtermPerror("Could not exec %s", shell_path); IGNORE_RC(sleep(5)); + free(shell_path); exit(ERROR_EXEC); } /* end if in child after fork */ @@ -4608,7 +4651,7 @@ exit(ERROR_PTYS); } handshake.status = PTY_NEW; - (void) strcpy(handshake.buffer, ttydev); + (void) strncpy(handshake.buffer, ttydev, sizeof(handshake.buffer)); TRACE_HANDSHAKE("writing", &handshake); IGNORE_RC(write(pc_pipe[1], (const char *) &handshake, @@ -4700,17 +4743,22 @@ signal(SIGTERM, Exit); signal(SIGPIPE, Exit); #endif /* USE_SYSV_SIGNALS and not SIGTSTP */ +#ifdef NO_LEAKS + if (ok_termcap != True) + free(TermName); +#endif return 0; } /* end spawnXTerm */ -SIGNAL_T +void Exit(int n) { XtermWidget xw = term; TScreen *screen = TScreenOf(xw); #ifdef USE_UTEMPTER + DEBUG_MSG("handle:Exit USE_UTEMPTER\n"); if (!resource.utmpInhibit && added_utmp_entry) { TRACE(("...calling removeFromUtmp\n")); removeFromUtmp(); @@ -4720,9 +4768,11 @@ struct UTMP_STR utmp; struct UTMP_STR *utptr; + DEBUG_MSG("handle:Exit USE_SYSV_UTMP\n"); /* don't do this more than once */ - if (xterm_exiting) - SIGNAL_RETURN; + if (xterm_exiting) { + exit(n); + } xterm_exiting = True; #ifdef PUCC_PTYD @@ -4772,7 +4822,7 @@ if (xw->misc.login_shell) { int fd; if ((fd = open(etc_wtmp, O_WRONLY | O_APPEND)) >= 0) { - write(fd, utptr, sizeof(*utptr)); + IGNORE_RC(write(fd, utptr, sizeof(*utptr))); close(fd); } } @@ -4792,6 +4842,7 @@ int wfd; struct utmp utmp; + DEBUG_MSG("handle:Exit !USE_SYSV_UTMP\n"); if (!resource.utmpInhibit && added_utmp_entry && (am_slave < 0 && tslot > 0)) { #if defined(USE_UTMP_SETGID) @@ -4801,7 +4852,7 @@ if ((wfd = open(etc_utmp, O_WRONLY)) >= 0) { memset(&utmp, 0, sizeof(utmp)); lseek(wfd, (long) (tslot * sizeof(utmp)), 0); - write(wfd, (char *) &utmp, sizeof(utmp)); + IGNORE_RC(write(wfd, (char *) &utmp, sizeof(utmp))); close(wfd); } #ifdef WTMP @@ -4811,7 +4862,7 @@ my_pty_name(ttydev), sizeof(utmp.ut_line)); utmp.ut_time = time((time_t *) 0); - write(wfd, (char *) &utmp, sizeof(utmp)); + IGNORE_RC(write(wfd, (char *) &utmp, sizeof(utmp))); close(wfd); } #endif /* WTMP */ @@ -4854,32 +4905,31 @@ #ifdef NO_LEAKS if (n == 0) { + Display *dpy = TScreenOf(xw)->display; + TRACE(("Freeing memory leaks\n")); - if (xw != 0) { - Display *dpy = TScreenOf(xw)->display; - if (toplevel) { - XtDestroyWidget(toplevel); - TRACE(("destroyed top-level widget\n")); - } - sortedOpts(0, 0, 0); - noleaks_charproc(); - noleaks_ptydata(); + if (toplevel) { + XtDestroyWidget(toplevel); + TRACE(("destroyed top-level widget\n")); + } + sortedOpts(0, 0, 0); + noleaks_charproc(); + noleaks_ptydata(); #if OPT_WIDE_CHARS - noleaks_CharacterClass(); + noleaks_CharacterClass(); #endif - /* XrmSetDatabase(dpy, 0); increases leaks ;-) */ - XtCloseDisplay(dpy); - XtDestroyApplicationContext(app_con); - xtermCloseSession(); - TRACE(("closed display\n")); - } + /* XrmSetDatabase(dpy, 0); increases leaks ;-) */ + XtCloseDisplay(dpy); + XtDestroyApplicationContext(app_con); + xtermCloseSession(); + TRACE(("closed display\n")); + TRACE_CLOSE(); } #endif exit(n); - SIGNAL_RETURN; } /* ARGSUSED */ @@ -4921,14 +4971,16 @@ ? MaxRows(screen) : MaxCols(screen))); temp += strlen(temp); - ptr1 = strchr(ptr1, ':'); - strncpy(temp, ptr1, i = (size_t) (ptr2 - ptr1)); - temp += i; - sprintf(temp, "%d", (li_first - ? MaxCols(screen) - : MaxRows(screen))); - ptr2 = strchr(ptr2, ':'); - strcat(temp, ptr2); + if ((ptr1 = strchr(ptr1, ':')) != 0 && (ptr1 < ptr2)) { + strncpy(temp, ptr1, i = (size_t) (ptr2 - ptr1)); + temp += i; + sprintf(temp, "%d", (li_first + ? MaxCols(screen) + : MaxRows(screen))); + if ((ptr2 = strchr(ptr2, ':')) != 0) { + strcat(temp, ptr2); + } + } TRACE((" ==> %s\n", newtc)); TRACE((" new size %dx%d\n", MaxRows(screen), MaxCols(screen))); } @@ -4968,12 +5020,14 @@ #ifndef VMS /* ARGSUSED */ -static SIGNAL_T +static void reapchild(int n GCC_UNUSED) { int olderrno = errno; int pid; + DEBUG_MSG("handle:reapchild\n"); + pid = wait(NULL); #ifdef USE_SYSV_SIGNALS @@ -4985,17 +5039,13 @@ do { if (pid == TScreenOf(term)->pid) { -#ifdef DEBUG - if (debug) - fputs("Exiting\n", stderr); -#endif + DEBUG_MSG("Exiting\n"); if (!hold_screen) need_cleanup = True; } } while ((pid = nonblocking_wait()) > 0); errno = olderrno; - SIGNAL_RETURN; } #endif /* !VMS */ @@ -5019,7 +5069,9 @@ if (*buf != 0) buf++; } - while ((*first++ = *buf++) != 0) ; + while ((*first++ = *buf++) != 0) { + ; + } TRACE(("...removed_termcap_entry('%s', '%s')\n", str, base)); return; } else if (*buf == '\\') { diff -Nru xterm-278/main.h xterm-297/main.h --- xterm-278/main.h 2011-12-14 22:43:02.000000000 +0000 +++ xterm-297/main.h 2013-04-24 08:52:20.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: main.h,v 1.57 2011/12/14 22:43:02 tom Exp $ */ +/* $XTermId: main.h,v 1.61 2013/04/24 08:52:20 tom Exp $ */ /* - * Copyright 2000-2010,2011 by Thomas E. Dickey + * Copyright 2000-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -145,6 +145,18 @@ #define DEF_BACKARO_ERASE False #endif +#ifndef DEF_BACKARO_BS +#define DEF_BACKARO_BS True +#endif + +#ifndef DEF_ALT_SENDS_ESC +#define DEF_ALT_SENDS_ESC False +#endif + +#ifndef DEF_META_SENDS_ESC +#define DEF_META_SENDS_ESC False +#endif + #ifndef DEF_8BIT_META #define DEF_8BIT_META "true" /* eightBitMeta */ #endif diff -Nru xterm-278/menu.c xterm-297/menu.c --- xterm-278/menu.c 2011-12-14 01:21:57.000000000 +0000 +++ xterm-297/menu.c 2013-06-23 22:46:18.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: menu.c,v 1.301 2011/12/14 01:21:57 tom Exp $ */ +/* $XTermId: menu.c,v 1.320 2013/06/23 22:46:18 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -228,6 +228,11 @@ static void do_sco_fkeys PROTO_XT_CALLBACK_ARGS; #endif +#if OPT_SIXEL_GRAPHICS +static void do_privatecolorregisters PROTO_XT_CALLBACK_ARGS; +static void do_sixelscrolling PROTO_XT_CALLBACK_ARGS; +#endif + #if OPT_SUN_FUNC_KEYS static void do_sun_fkeys PROTO_XT_CALLBACK_ARGS; #endif @@ -363,6 +368,10 @@ { "vthide", do_vthide, NULL }, #endif { "altscreen", do_altscreen, NULL }, +#if OPT_SIXEL_GRAPHICS + { "sixelScrolling", do_sixelscrolling, NULL }, + { "privateColorRegisters", do_privatecolorregisters, NULL }, +#endif }; MenuEntry fontMenuEntries[] = { @@ -778,10 +787,12 @@ update_bellIsUrgent(); update_cursorblink(); update_altscreen(); + update_decsdm(); /* Sixel Display Mode */ update_titeInhibit(); #ifndef NO_ACTIVE_ICON update_activeicon(); #endif /* NO_ACTIVE_ICON */ + update_privatecolorregisters(); } break; @@ -842,7 +853,7 @@ FindFontSelection(xw, NULL, True); SetItemSensitivity( fontMenuEntries[fontMenu_fontsel].widget, - (screen->menu_font_names[fontMenu_fontsel] + (screen->menu_font_names[fontMenu_fontsel][fNorm] ? True : False)); break; @@ -967,45 +978,6 @@ * action routines */ -#if OPT_MAXIMIZE -static void -do_fullscreen(Widget gw GCC_UNUSED, - XtPointer closure GCC_UNUSED, - XtPointer data GCC_UNUSED) -{ - XtermWidget xw = term; - TScreen *screen = TScreenOf(xw); - - if (resource.fullscreen != esNever) - FullScreen(xw, !screen->fullscreen); -} - -/* ARGSUSED */ -void -HandleFullscreen(Widget w, - XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, - Cardinal *param_count GCC_UNUSED) -{ - do_fullscreen(w, (XtPointer) 0, (XtPointer) 0); -} - -void -update_fullscreen(void) -{ - if (resource.fullscreen <= 1) { - UpdateCheckbox("update_fullscreen", - mainMenuEntries, - mainMenu_fullscreen, - TScreenOf(term)->fullscreen); - } else { - SetItemSensitivity(mainMenuEntries[mainMenu_fullscreen].widget, - False); - } -} - -#endif /* OPT_MAXIMIZE */ - static void do_securekbd(Widget gw GCC_UNUSED, XtPointer closure GCC_UNUSED, @@ -1613,9 +1585,9 @@ if (screen->iconVwin.window) { Widget shell = XtParent(term); - ToggleFlag(term->misc.active_icon); + ToggleFlag(term->work.active_icon); XtVaSetValues(shell, XtNiconWindow, - term->misc.active_icon ? screen->iconVwin.window : None, + term->work.active_icon ? screen->iconVwin.window : None, (XtPointer) 0); update_activeicon(); } @@ -1678,6 +1650,7 @@ char *entryname = (char *) closure; int i; + TRACE(("do_vtfont(%s)\n", entryname)); for (i = 0; i < NMENUFONTS; i++) { if (strcmp(entryname, fontMenuEntries[i].name) == 0) { SetVTFont(xw, i, True, NULL); @@ -1747,7 +1720,7 @@ String name = TScreenOf(xw)->MenuFontName(fontnum); DefaultRenderFont(xw); - ToggleFlag(xw->misc.render_font); + ToggleFlag(xw->work.render_font); update_font_renderfont(); xtermLoadFont(xw, xtermFontName(name), True, fontnum); ScrnRefresh(term, 0, 0, @@ -1950,50 +1923,57 @@ /* * public handler routines */ - -static void -handle_toggle(void (*proc) PROTO_XT_CALLBACK_ARGS, - int var, - String * params, - Cardinal nparams, - Widget w, - XtPointer closure, - XtPointer data) +int +decodeToggle(XtermWidget xw, String * params, Cardinal nparams) { - XtermWidget xw = term; - int dir = -2; + int dir = toggleErr; switch (nparams) { case 0: - dir = -1; + dir = toggleAll; break; case 1: if (XmuCompareISOLatin1(params[0], "on") == 0) - dir = 1; + dir = toggleOn; else if (XmuCompareISOLatin1(params[0], "off") == 0) - dir = 0; + dir = toggleOff; else if (XmuCompareISOLatin1(params[0], "toggle") == 0) - dir = -1; + dir = toggleAll; break; } - switch (dir) { - case -2: + if (dir == toggleErr) { Bell(xw, XkbBI_MinorError, 0); - break; + } + + return dir; +} - case -1: +static void +handle_toggle(void (*proc) PROTO_XT_CALLBACK_ARGS, + int var, + String * params, + Cardinal nparams, + Widget w, + XtPointer closure, + XtPointer data) +{ + XtermWidget xw = term; + + switch (decodeToggle(xw, params, nparams)) { + + case toggleAll: (*proc) (w, closure, data); break; - case 0: + case toggleOff: if (var) (*proc) (w, closure, data); else Bell(xw, XkbBI_MinorError, 0); break; - case 1: + case toggleOn: if (!var) (*proc) (w, closure, data); else @@ -2186,6 +2166,115 @@ params, *param_count, w); } +#if OPT_MAXIMIZE +#if OPT_TEK4014 +#define WhichEWMH (TEK4014_ACTIVE(xw) != 0) +#else +#define WhichEWMH 0 +#endif +static void +do_fullscreen(Widget gw GCC_UNUSED, + XtPointer closure GCC_UNUSED, + XtPointer data GCC_UNUSED) +{ + XtermWidget xw = term; + + if (resource.fullscreen != esNever) + FullScreen(xw, !xw->work.ewmh[WhichEWMH].mode); +} + +/* ARGSUSED */ +void +HandleFullscreen(Widget w, + XEvent * event GCC_UNUSED, + String * params GCC_UNUSED, + Cardinal *param_count GCC_UNUSED) +{ + XtermWidget xw = term; + + if (resource.fullscreen != esNever) { + handle_vt_toggle(do_fullscreen, xw->work.ewmh[WhichEWMH].mode, + params, *param_count, w); + } +} + +void +update_fullscreen(void) +{ + XtermWidget xw = term; + + if (resource.fullscreen <= 1) { + UpdateCheckbox("update_fullscreen", + mainMenuEntries, + mainMenu_fullscreen, + xw->work.ewmh[WhichEWMH].mode); + } else { + SetItemSensitivity(mainMenuEntries[mainMenu_fullscreen].widget, + False); + } +} + +#endif /* OPT_MAXIMIZE */ + +#if OPT_SIXEL_GRAPHICS +static void +do_sixelscrolling(Widget gw GCC_UNUSED, + XtPointer closure GCC_UNUSED, + XtPointer data GCC_UNUSED) +{ + term->keyboard.flags ^= MODE_DECSDM; + update_decsdm(); +} + +static void +do_privatecolorregisters(Widget gw GCC_UNUSED, + XtPointer closure GCC_UNUSED, + XtPointer data GCC_UNUSED) +{ + TScreen *screen = TScreenOf(term); + + ToggleFlag(screen->privatecolorregisters); + update_privatecolorregisters(); +} + +void +update_privatecolorregisters(void) +{ + UpdateCheckbox("update_privatecolorregisters", + vtMenuEntries, + vtMenu_privatecolorregisters, + TScreenOf(term)->privatecolorregisters); +} + +void +update_decsdm(void) +{ + UpdateCheckbox("update_decsdm", + vtMenuEntries, + vtMenu_sixelscrolling, + (term->keyboard.flags & MODE_DECSDM) != 0); +} + +void +HandleSetPrivateColorRegisters(Widget w, + XEvent * event GCC_UNUSED, + String * params, + Cardinal *param_count) +{ + HANDLE_VT_TOGGLE(privatecolorregisters); +} + +void +HandleSixelScrolling(Widget w, + XEvent * event GCC_UNUSED, + String * params, + Cardinal *param_count) +{ + handle_vt_toggle(do_sixelscrolling, term->keyboard.flags & MODE_DECSDM, + params, *param_count, w); +} +#endif + #if OPT_SUN_FUNC_KEYS void HandleSunFunctionKeys(Widget w, @@ -2573,7 +2662,7 @@ int n; for (n = 0; n <= fontMenu_lastBuiltin; ++n) { - Boolean active = (Boolean) (xw->misc.render_font || + Boolean active = (Boolean) (xw->work.render_font || (screen->menu_font_sizes[n] >= 0)); SetItemSensitivity(fontMenuEntries[n].widget, active); } @@ -2589,7 +2678,7 @@ DefaultRenderFont(xw); - handle_vt_toggle(do_font_renderfont, xw->misc.render_font, + handle_vt_toggle(do_font_renderfont, xw->work.render_font, params, *param_count, w); update_fontmenu(xw); @@ -2839,7 +2928,7 @@ if (shell == toplevel) { XawSimpleMenuAddGlobalActions(app_con); XtRegisterGrabAction(HandlePopupMenu, True, - (ButtonPressMask | ButtonReleaseMask), + (unsigned) (ButtonPressMask | ButtonReleaseMask), GrabModeAsync, GrabModeAsync); } #if OPT_TOOLBAR @@ -3465,7 +3554,7 @@ UpdateCheckbox("update_activeicon", vtMenuEntries, vtMenu_activeicon, - term->misc.active_icon); + term->work.active_icon); } #endif /* NO_ACTIVE_ICON */ @@ -3531,7 +3620,7 @@ UpdateCheckbox("update_font_renderfont", fontMenuEntries, fontMenu_render_font, - (term->misc.render_font == True)); + (term->work.render_font == True)); SetItemSensitivity(fontMenuEntries[fontMenu_render_font].widget, !IsEmpty(term->misc.face_name)); update_fontmenu(term); @@ -3769,15 +3858,18 @@ void update_vttekmode(void) { - if (!(TScreenOf(term)->inhibit & I_TEK)) { + XtermWidget xw = term; + + if (!(TScreenOf(xw)->inhibit & I_TEK)) { UpdateCheckbox("update_vtmode", vtMenuEntries, vtMenu_tekmode, - TEK4014_ACTIVE(term)); + TEK4014_ACTIVE(xw)); UpdateCheckbox("update_tekmode", tekMenuEntries, tekMenu_vtmode, - !TEK4014_ACTIVE(term)); + !TEK4014_ACTIVE(xw)); + update_fullscreen(); } } diff -Nru xterm-278/menu.h xterm-297/menu.h --- xterm-278/menu.h 2011-08-28 21:15:40.000000000 +0000 +++ xterm-297/menu.h 2013-06-23 20:52:38.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: menu.h,v 1.126 2011/08/28 21:15:40 tom Exp $ */ +/* $XTermId: menu.h,v 1.132 2013/06/23 20:52:38 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2011,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -126,10 +126,12 @@ extern void HandleSecure PROTO_XT_ACTIONS_ARGS; extern void HandleSendSignal PROTO_XT_ACTIONS_ARGS; extern void HandleSetPopOnBell PROTO_XT_ACTIONS_ARGS; +extern void HandleSetPrivateColorRegisters PROTO_XT_ACTIONS_ARGS; extern void HandleSetSelect PROTO_XT_ACTIONS_ARGS; extern void HandleSetTekText PROTO_XT_ACTIONS_ARGS; extern void HandleSetTerminalType PROTO_XT_ACTIONS_ARGS; extern void HandleSetVisualBell PROTO_XT_ACTIONS_ARGS; +extern void HandleSixelScrolling PROTO_XT_ACTIONS_ARGS; extern void HandleSoftReset PROTO_XT_ACTIONS_ARGS; extern void HandleSunFunctionKeys PROTO_XT_ACTIONS_ARGS; extern void HandleSunKeyboard PROTO_XT_ACTIONS_ARGS; @@ -255,6 +257,10 @@ vtMenu_vthide, #endif vtMenu_altscreen, +#if OPT_SIXEL_GRAPHICS + vtMenu_sixelscrolling, + vtMenu_privatecolorregisters, +#endif vtMenu_LAST } vtMenuIndices; @@ -340,6 +346,15 @@ extern void SetItemSensitivity(Widget mi, Bool val); +typedef enum { + toggleErr = -2, + toggleAll = -1, + toggleOff = 0, + toggleOn = 1 +} ToggleEnum; + +extern int decodeToggle(XtermWidget /* xw */, String * /* params */, Cardinal /* nparams */); + /* * there should be one of each of the following for each checkable item */ @@ -470,6 +485,14 @@ #define update_font_packed() /* nothing */ #endif +#if OPT_SIXEL_GRAPHICS +extern void update_decsdm(void); +extern void update_privatecolorregisters(void); +#else +#define update_decsdm() /* nothing */ +#define update_privatecolorregisters() /* nothing */ +#endif + #if OPT_DEC_SOFTFONT extern void update_font_loadable(void); #else diff -Nru xterm-278/minstall.in xterm-297/minstall.in --- xterm-278/minstall.in 2011-08-16 09:50:03.000000000 +0000 +++ xterm-297/minstall.in 2013-04-21 18:58:54.000000000 +0000 @@ -1,9 +1,9 @@ #!/bin/sh -# $XTermId: minstall.in,v 1.5 2011/08/16 09:50:03 tom Exp $ +# $XTermId: minstall.in,v 1.19 2013/04/21 18:58:54 Andres.Perera Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 2001-2010,2011 by Thomas E. Dickey +# Copyright 2001-2011,2012 by Thomas E. Dickey # # All Rights Reserved # @@ -41,6 +41,9 @@ # $3 = final installed-path # $4 = app-defaults directory # $5 = app-defaults class +# $6 = application name, normally "xterm" +# $7 = application name transformed +# $8 = pixmap directory # # Other values correspond to definitions in xtermcfg.h, and cannot be directly # modified using "make". They are substituted directly into this script. @@ -69,6 +72,9 @@ END_FILE="$3" APPS_DIR="$4" APP_TYPE="$5" +APP_name="$6" +USE_name="$7" +XPMS_DIR="$8" suffix=`echo "$END_FILE" | sed -e 's%^.*\.%%'` NEW_FILE=temp$$ @@ -114,18 +120,47 @@ X_MANSECT=`man X 2>&1 | tr '\012' '\020' | sed -e 's/^[^0123456789]*\([^) ][^) ]*\).*/\1/'` test -z "$X_MANSECT" && X_MANSECT=$suffix +VERSION_H=`echo "$OLD_FILE" | sed -e 's,/[^/]*$,/version.h,' -e s',^[^/]*$,version.h,'` +PATCH_NUM=`fgrep XTERM_PATCH $VERSION_H|sed -e 's/[^0-9]*//g'` +PATCH_YMD=`fgrep XTERM_DATE $VERSION_H|sed -e 's,[^0-9/.-]*,,g'` + +# Make capitalization variants +APP_chr0=`echo "$APP_name" | sed -e 's/^\(.\).*/\1/' | tr '[a-z]' '[A-Z]'` +APP_chr1=`echo "$APP_name" | sed -e 's/^.//'` +APP_Name=${APP_chr0}${APP_chr1} +APP_NAME=`echo "$APP_name" | tr '[a-z]' '[A-Z]'` + +# Provide for renaming in test-builds: +USE_chr0=`echo "$USE_name" | sed -e 's/^\(.\).*/\1/' | tr '[a-z]' '[A-Z]'` +USE_chr1=`echo "$USE_name" | sed -e 's/^.//'` +USE_Name=${USE_chr0}${USE_chr1} +USE_NAME=`echo "$USE_name" | tr '[a-z]' '[A-Z]'` + sed -e 's%__vendorversion__%"X Window System"%' \ + -e 's%__app_version__%Patch\ \#'$PATCH_NUM% \ + -e 's%__app_date__%'$PATCH_YMD% \ + -e "s%^\.TH [^ ][^ ]*%.TH $USE_NAME%" \ + -e "s%^\.ds N $APP_Name%.ds N $USE_Name%" \ + -e "s%^\.ds n $APP_name%.ds n $USE_name%" \ + -e 's%^'"$APP_name"' \\- %'"$USE_name"' \- %' \ -e s%__default_termname__%@default_TERM@% \ -e s%__default_termid__%@default_termid@% \ + -e s%__alt_sends_esc__%@alt_sends_esc@% \ + -e s%__meta_sends_esc__%@meta_sends_esc@% \ + -e s%__backarrow_is_bs__%@backarrow_is_bs@% \ + -e s%__backarrow_is_erase__%@backarrow_is_erase@% \ + -e s%__delete_is_del__%@delete_is_del@% \ -e s%__default_class__%$APP_TYPE% \ -e s%__apploaddir__%$APPS_DIR% \ -e s%__mansuffix__%$MY_MANSECT%g \ -e s%__miscmansuffix__%$X_MANSECT%g \ + -e s%__pixmapsdir__%$XPMS_DIR% \ -e s%fIutmp'\\%fI'$UTMP_NAME'\\%g' \ -e s%/etc/utmp%$UTMP_PATH%g \ -e s%fIwtmp'\\%fI'$WTMP_NAME'\\%g' \ -e s%/etc/wtmp%$WTMP_PATH%g \ $OLD_FILE >$NEW_FILE +# diff -u $OLD_FILE $NEW_FILE echo "$MINSTALL $OLD_FILE $END_FILE" eval "$MINSTALL $NEW_FILE $END_FILE" diff -Nru xterm-278/misc.c xterm-297/misc.c --- xterm-278/misc.c 2012-01-07 01:57:52.000000000 +0000 +++ xterm-297/misc.c 2013-08-05 08:25:55.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: misc.c,v 1.576 2012/01/07 01:57:52 tom Exp $ */ +/* $XTermId: misc.c,v 1.672 2013/08/05 08:25:55 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -77,6 +77,10 @@ #include #endif +#ifdef HAVE_LIBXPM +#include +#endif + #ifdef HAVE_LANGINFO_CODESET #include #endif @@ -87,10 +91,10 @@ #include #include #include -#include #include #include #include +#include #include @@ -122,6 +126,8 @@ static Boolean xtermAllocColor(XtermWidget, XColor *, const char *); static Cursor make_hidden_cursor(XtermWidget); +static char emptyString[] = ""; + #if OPT_EXEC_XTERM /* Like readlink(2), but returns a malloc()ed buffer, or NULL on error; adapted from libc docs */ @@ -180,7 +186,7 @@ { #if OPT_I18N_SUPPORT && OPT_INPUT_METHOD TInput *input = lookupTInput(xw, (Widget) xw); - if (input->xic) + if (input && input->xic) XSetICFocus(input->xic); #endif @@ -200,7 +206,7 @@ TRACE(("unselectwindow(%d) flag=%d\n", screen->select, flag)); - if (screen->hide_pointer) { + if (screen->hide_pointer && screen->pointer_mode < pFocused) { screen->hide_pointer = False; xtermDisplayCursor(xw); } @@ -218,7 +224,7 @@ { #if OPT_I18N_SUPPORT && OPT_INPUT_METHOD TInput *input = lookupTInput(xw, (Widget) xw); - if (input->xic) + if (input && input->xic) XUnsetICFocus(input->xic); #endif @@ -340,6 +346,7 @@ enable = True; break; case pAlways: + case pFocused: break; } } @@ -527,8 +534,10 @@ while (result && XtAppPeekEvent(app_con, &this_event)) { if (this_event.type == Expose) { result = mergeExposeEvents(&this_event); + TRACE(("got merged expose events\n")); } else if (this_event.type == ConfigureNotify) { result = mergeConfigureEvents(&this_event); + TRACE(("got merged configure notify events\n")); } else { TRACE(("pending %s\n", visibleEventType(this_event.type))); break; @@ -546,7 +555,7 @@ XtInputMask input_mask; if (need_cleanup) - Cleanup(0); + NormalExit(); if (screen->scroll_amt) FlushScroll(xw); @@ -614,20 +623,28 @@ * mouse pointer back on. */ if (screen->hide_pointer) { - switch (event.xany.type) { - case KeyPress: - case KeyRelease: - case ButtonPress: - case ButtonRelease: - /* also these... */ - case Expose: - case NoExpose: - case PropertyNotify: - case ClientMessage: - break; - default: - xtermShowPointer(xw, True); - break; + if (screen->pointer_mode >= pFocused) { + switch (event.xany.type) { + case MotionNotify: + xtermShowPointer(xw, True); + break; + } + } else { + switch (event.xany.type) { + case KeyPress: + case KeyRelease: + case ButtonPress: + case ButtonRelease: + /* also these... */ + case Expose: + case NoExpose: + case PropertyNotify: + case ClientMessage: + break; + default: + xtermShowPointer(xw, True); + break; + } } } @@ -695,7 +712,7 @@ void HandleKeyPressed(Widget w GCC_UNUSED, XEvent * event, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *nparams GCC_UNUSED) { TRACE(("Handle insert-seven-bit for %p\n", (void *) w)); @@ -706,7 +723,7 @@ void HandleEightBitKeyPressed(Widget w GCC_UNUSED, XEvent * event, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *nparams GCC_UNUSED) { TRACE(("Handle insert-eight-bit for %p\n", (void *) w)); @@ -717,7 +734,7 @@ void HandleStringEvent(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params, + String *params, Cardinal *nparams) { @@ -762,7 +779,7 @@ void HandleSpawnTerminal(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params, + String *params, Cardinal *nparams) { TScreen *screen = TScreenOf(term); @@ -821,7 +838,7 @@ myargv[n++] = child_exe; while (n < myargc) { - myargv[n++] = *params++; + myargv[n++] = (char *) *params++; } myargv[n] = 0; @@ -831,13 +848,12 @@ xtermWarning("exec of '%s': %s\n", child_exe, SysErrorMsg(errno)); } _exit(0); - } else { - /* We are the parent; clean up */ - if (child_cwd) - free(child_cwd); - if (child_exe) - free(child_exe); } + + /* We are the parent; clean up */ + if (child_cwd) + free(child_cwd); + free(child_exe); } #endif /* OPT_EXEC_XTERM */ @@ -857,7 +873,7 @@ void HandleInterpret(Widget w GCC_UNUSED, XEvent * event GCC_UNUSED, - String * params, + String *params, Cardinal *param_count) { if (*param_count == 1) { @@ -881,7 +897,7 @@ HandleEnterWindow(Widget w GCC_UNUSED, XtPointer eventdata GCC_UNUSED, XEvent * event GCC_UNUSED, - Boolean * cont GCC_UNUSED) + Boolean *cont GCC_UNUSED) { /* NOP since we handled it above */ TRACE(("HandleEnterWindow ignored\n")); @@ -893,7 +909,7 @@ HandleLeaveWindow(Widget w GCC_UNUSED, XtPointer eventdata GCC_UNUSED, XEvent * event GCC_UNUSED, - Boolean * cont GCC_UNUSED) + Boolean *cont GCC_UNUSED) { /* NOP since we handled it above */ TRACE(("HandleLeaveWindow ignored\n")); @@ -905,21 +921,28 @@ HandleFocusChange(Widget w GCC_UNUSED, XtPointer eventdata GCC_UNUSED, XEvent * ev, - Boolean * cont GCC_UNUSED) + Boolean *cont GCC_UNUSED) { XFocusChangeEvent *event = (XFocusChangeEvent *) ev; XtermWidget xw = term; TScreen *screen = TScreenOf(xw); - TRACE(("HandleFocusChange type=%s, mode=%d, detail=%d\n", + TRACE(("HandleFocusChange type=%s, mode=%s, detail=%s\n", visibleEventType(event->type), - event->mode, - event->detail)); + visibleNotifyMode(event->mode), + visibleNotifyDetail(event->detail))); TRACE_FOCUS(xw, event); if (screen->quiet_grab && (event->mode == NotifyGrab || event->mode == NotifyUngrab)) { /* EMPTY */ ; + } else if ((event->type == FocusIn || event->type == FocusOut) + && event->detail == NotifyPointer) { + /* + * NotifyPointer is sent to the window where the pointer is, and is + * in addition to events sent to the old/new focus-windows. + */ + /* EMPTY */ ; } else if (event->type == FocusIn) { setXUrgency(xw, False); @@ -1098,7 +1121,7 @@ #define VB_DELAY screen->visualBellDelay static void -flashWindow(TScreen * screen, Window window, GC visualGC, unsigned width, unsigned height) +flashWindow(TScreen *screen, Window window, GC visualGC, unsigned width, unsigned height) { int y = 0; int x = 0; @@ -1149,7 +1172,7 @@ HandleBellPropertyChange(Widget w GCC_UNUSED, XtPointer data GCC_UNUSED, XEvent * ev, - Boolean * more GCC_UNUSED) + Boolean *more GCC_UNUSED) { TScreen *screen = TScreenOf(term); @@ -1161,6 +1184,7 @@ void xtermWarning(const char *fmt,...) { + int save_err = errno; va_list ap; fprintf(stderr, "%s: ", ProgramName); @@ -1169,11 +1193,13 @@ (void) fflush(stderr); va_end(ap); + errno = save_err; } void xtermPerror(const char *fmt,...) { + int save_err = errno; char *msg = strerror(errno); va_list ap; @@ -1184,6 +1210,7 @@ (void) fflush(stderr); va_end(ap); + errno = save_err; } Window @@ -1224,7 +1251,7 @@ #define MAXWLEN 1024 /* maximum word length as in tcsh */ static int -dabbrev_prev_char(TScreen * screen, CELL * cell, LineData ** ld) +dabbrev_prev_char(TScreen *screen, CELL *cell, LineData **ld) { int result = -1; int firstLine = -(screen->savedlines); @@ -1248,7 +1275,7 @@ } static char * -dabbrev_prev_word(TScreen * screen, CELL * cell, LineData ** ld) +dabbrev_prev_word(TScreen *screen, CELL *cell, LineData **ld) { static char ab[MAXWLEN]; @@ -1283,7 +1310,7 @@ } static int -dabbrev_expand(TScreen * screen) +dabbrev_expand(TScreen *screen) { int pty = screen->respond; /* file descriptor of pty */ @@ -1385,7 +1412,7 @@ void HandleDabbrevExpand(Widget w, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *nparams GCC_UNUSED) { XtermWidget xw; @@ -1404,7 +1431,7 @@ void HandleDeIconify(Widget w, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *nparams GCC_UNUSED) { XtermWidget xw; @@ -1419,7 +1446,7 @@ void HandleIconify(Widget w, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *nparams GCC_UNUSED) { XtermWidget xw; @@ -1443,6 +1470,7 @@ int root_y = -1; unsigned root_border; unsigned root_depth; + int code; if (XGetGeometry(screen->display, RootWindowOfScreen(XtScreen(xw)), @@ -1479,9 +1507,13 @@ if ((unsigned) hints.max_height < *height) *height = (unsigned) hints.max_height; } - return 1; + code = 1; + } else { + *width = 0; + *height = 0; + code = 0; } - return 0; + return code; } void @@ -1490,67 +1522,89 @@ TScreen *screen = TScreenOf(xw); XWindowAttributes wm_attrs, vshell_attrs; unsigned root_width, root_height; + Boolean success = False; - TRACE(("RequestMaximize %s\n", maximize ? "maximize" : "restore")); - - if (maximize) { - - if (QueryMaximize(xw, &root_width, &root_height)) { + TRACE(("RequestMaximize %d:%s\n", + maximize, + (maximize + ? "maximize" + : "restore"))); - if (XGetWindowAttributes(screen->display, - WMFrameWindow(xw), - &wm_attrs)) { - - if (XGetWindowAttributes(screen->display, - VShellWindow(xw), - &vshell_attrs)) { - - if (screen->restore_data != True - || screen->restore_width != root_width - || screen->restore_height != root_height) { - screen->restore_data = True; - screen->restore_x = wm_attrs.x + wm_attrs.border_width; - screen->restore_y = wm_attrs.y + wm_attrs.border_width; - screen->restore_width = (unsigned) vshell_attrs.width; - screen->restore_height = (unsigned) vshell_attrs.height; - TRACE(("HandleMaximize: save window position %d,%d size %d,%d\n", - screen->restore_x, - screen->restore_y, - screen->restore_width, - screen->restore_height)); - } + /* + * Before any maximize, ensure that we can capture the current screensize + * as well as the estimated root-window size. + */ + if (maximize + && QueryMaximize(xw, &root_width, &root_height) + && xtermGetWinAttrs(screen->display, + WMFrameWindow(xw), + &wm_attrs) + && xtermGetWinAttrs(screen->display, + VShellWindow(xw), + &vshell_attrs)) { - /* subtract wm decoration dimensions */ - root_width -= - (unsigned) ((wm_attrs.width - vshell_attrs.width) - + (wm_attrs.border_width * 2)); - root_height -= - (unsigned) ((wm_attrs.height - vshell_attrs.height) - + (wm_attrs.border_width * 2)); - - XMoveResizeWindow(screen->display, VShellWindow(xw), - 0 + wm_attrs.border_width, /* x */ - 0 + wm_attrs.border_width, /* y */ - root_width, - root_height); - } - } - } - } else { - if (screen->restore_data) { - TRACE(("HandleRestoreSize: position %d,%d size %d,%d\n", + if (screen->restore_data != True + || screen->restore_width != root_width + || screen->restore_height != root_height) { + screen->restore_data = True; + screen->restore_x = wm_attrs.x + wm_attrs.border_width; + screen->restore_y = wm_attrs.y + wm_attrs.border_width; + screen->restore_width = (unsigned) vshell_attrs.width; + screen->restore_height = (unsigned) vshell_attrs.height; + TRACE(("RequestMaximize: save window position %d,%d size %d,%d\n", screen->restore_x, screen->restore_y, screen->restore_width, screen->restore_height)); - screen->restore_data = False; + } - XMoveResizeWindow(screen->display, - VShellWindow(xw), - screen->restore_x, - screen->restore_y, - screen->restore_width, - screen->restore_height); + /* subtract wm decoration dimensions */ + root_width -= (unsigned) ((wm_attrs.width - vshell_attrs.width) + + (wm_attrs.border_width * 2)); + root_height -= (unsigned) ((wm_attrs.height - vshell_attrs.height) + + (wm_attrs.border_width * 2)); + success = True; + } else if (screen->restore_data) { + success = True; + maximize = 0; + } + + if (success) { + switch (maximize) { + case 3: + FullScreen(xw, 3); /* depends on EWMH */ + break; + case 2: + FullScreen(xw, 2); /* depends on EWMH */ + break; + case 1: + FullScreen(xw, 0); /* overrides any EWMH hint */ + XMoveResizeWindow(screen->display, VShellWindow(xw), + 0 + wm_attrs.border_width, /* x */ + 0 + wm_attrs.border_width, /* y */ + root_width, + root_height); + break; + + default: + FullScreen(xw, 0); /* reset any EWMH hint */ + if (screen->restore_data) { + screen->restore_data = False; + + TRACE(("HandleRestoreSize: position %d,%d size %d,%d\n", + screen->restore_x, + screen->restore_y, + screen->restore_width, + screen->restore_height)); + + XMoveResizeWindow(screen->display, + VShellWindow(xw), + screen->restore_x, + screen->restore_y, + screen->restore_width, + screen->restore_height); + } + break; } } } @@ -1559,7 +1613,7 @@ void HandleMaximize(Widget w, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *nparams GCC_UNUSED) { XtermWidget xw; @@ -1573,7 +1627,7 @@ void HandleRestoreSize(Widget w, XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, + String *params GCC_UNUSED, Cardinal *nparams GCC_UNUSED) { XtermWidget xw; @@ -1714,7 +1768,7 @@ int childstat = 0; #ifndef HAVE_WAITPID int waited; - SIGNAL_T(*chldfunc) (int); + void (*chldfunc) (int); chldfunc = signal(SIGCHLD, SIG_DFL); #endif /* HAVE_WAITPID */ @@ -1780,7 +1834,7 @@ */ do if (waited == TScreenOf(term)->pid) - Cleanup(0); + NormalExit(); while ((waited = nonblocking_wait()) > 0) ; #endif /* HAVE_WAITPID */ #ifndef WIFEXITED @@ -1794,7 +1848,7 @@ #endif /* !VMS */ int -xtermResetIds(TScreen * screen) +xtermResetIds(TScreen *screen) { int result = 0; if (setgid(screen->gid) == -1) { @@ -1816,12 +1870,13 @@ */ #ifdef ALLOWLOGFILEEXEC -static SIGNAL_T +static void logpipe(int sig GCC_UNUSED) { XtermWidget xw = term; TScreen *screen = TScreenOf(xw); + DEBUG_MSG("handle:logpipe\n"); #ifdef SYSV (void) signal(SIGPIPE, SIG_IGN); #endif /* SYSV */ @@ -1895,8 +1950,34 @@ static char *shell; struct passwd pw; - if (pipe(p) < 0 || (pid = fork()) < 0) + if ((shell = x_getenv("SHELL")) == NULL) { + + if (x_getpwuid(screen->uid, &pw)) { + char *name = x_getlogin(screen->uid, &pw); + if (*(pw.pw_shell)) { + shell = pw.pw_shell; + } + free(name); + } + } + + if (shell == 0) { + static char dummy[] = "/bin/sh"; + shell = dummy; + } + + if (access(shell, X_OK) != 0) { + xtermPerror("Can't execute `%s'\n", shell); return; + } + + if (pipe(p) < 0) { + xtermPerror("Can't make a pipe connection\n"); + return; + } else if ((pid = fork()) < 0) { + xtermPerror("Can't fork...\n"); + return; + } if (pid == 0) { /* child */ /* * Close our output (we won't be talking back to the @@ -1913,21 +1994,6 @@ close(ConnectionNumber(screen->display)); close(screen->respond); - if ((shell = x_getenv("SHELL")) == NULL) { - - if (x_getpwuid(screen->uid, &pw)) { - x_getlogin(screen->uid, &pw); - if (*(pw.pw_shell)) { - shell = pw.pw_shell; - } - } - } - - if (shell == 0) { - static char dummy[] = "/bin/sh"; - shell = dummy; - } - signal(SIGHUP, SIG_DFL); signal(SIGCHLD, SIG_DFL); @@ -1935,9 +2001,12 @@ if (xtermResetIds(screen) < 0) exit(ERROR_SETUID); - execl(shell, shell, "-c", &screen->logfile[1], (void *) 0); - - xtermWarning("Can't exec `%s'\n", &screen->logfile[1]); + if (access(shell, X_OK) == 0) { + execl(shell, shell, "-c", &screen->logfile[1], (void *) 0); + xtermWarning("Can't exec `%s'\n", &screen->logfile[1]); + } else { + xtermWarning("Can't execute `%s'\n", shell); + } exit(ERROR_LOGEXEC); } close(p[0]); @@ -2027,7 +2096,7 @@ } static void -getColormapInfo(Display * display, unsigned *typep, unsigned *sizep) +getColormapInfo(Display *display, unsigned *typep, unsigned *sizep) { int numFound; XVisualInfo myTemplate, *visInfoPtr; @@ -2176,16 +2245,79 @@ #define ULONG_MAX (unsigned long)(~(0L)) #endif -static unsigned short -searchColortable(XColor * colortable, unsigned length, unsigned color) +#define CheckColor(result, value) \ + result = 0; \ + if (value.red) \ + result |= 1; \ + if (value.green) \ + result |= 2; \ + if (value.blue) \ + result |= 4 + +#define SelectColor(state, value, result) \ + switch (state) { \ + default: \ + case 1: \ + result = value.red; \ + break; \ + case 2: \ + result = value.green; \ + break; \ + case 4: \ + result = value.blue; \ + break; \ + } + +/* + * Check if the color map consists of values in exactly one of the red, green + * or blue columns. If it is not, we do not know how to use it for the exact + * match. + */ +static int +simpleColors(XColor * colortable, unsigned length) +{ + unsigned n; + int state = -1; + int check; + + for (n = 0; n < length; ++n) { + if (state == -1) { + CheckColor(state, colortable[n]); + if (state == 0) + state = -1; + } + if (state > 0) { + CheckColor(check, colortable[n]); + if (check > 0 && check != state) { + state = 0; + break; + } + } + } + switch (state) { + case 1: + case 2: + case 4: + break; + default: + state = 0; + break; + } + return state; +} + +static unsigned +searchColors(XColor * colortable, unsigned length, unsigned color, int state) { unsigned result = 0; unsigned n; unsigned long best = ULONG_MAX; unsigned long diff; + unsigned value; for (n = 0; n < length; ++n) { - diff = (color - colortable[n].blue); + SelectColor(state, colortable[n], value); + diff = (color - value); diff *= diff; if (diff < best) { #if 0 @@ -2200,7 +2332,8 @@ best = diff; } } - return colortable[result].blue; + SelectColor(state, colortable[result], value); + return value; } /* @@ -2243,20 +2376,19 @@ if (result) { unsigned cmap_type; unsigned cmap_size; + int state; getColormapInfo(screen->display, &cmap_type, &cmap_size); if ((cmap_type & 1) == 0) { XColor temp = *def; - if (loadColorTable(xw, cmap_size)) { - /* - * Note: the query will return only a value in the ".blue" - * member, leaving ".red" and ".green" as zeros. - */ - temp.red = searchColortable(screen->cmap_data, cmap_size, save.red); - temp.green = searchColortable(screen->cmap_data, cmap_size, save.green); - temp.blue = searchColortable(screen->cmap_data, cmap_size, save.blue); + if (loadColorTable(xw, cmap_size) + && (state = simpleColors(screen->cmap_data, cmap_size)) > 0) { +#define SearchColors(which) temp.which = (unsigned short) searchColors(screen->cmap_data, cmap_size, save.which, state) + SearchColors(red); + SearchColors(green); + SearchColors(blue); if (XAllocColor(screen->display, cmap, &temp) != 0) { #if OPT_TRACE if (temp.red != save.red @@ -2265,6 +2397,9 @@ TRACE(("...improved %x/%x/%x ->%x/%x/%x\n", save.red, save.green, save.blue, temp.red, temp.green, temp.blue)); + } else { + TRACE(("...no improvement for %x/%x/%x\n", + save.red, save.green, save.blue)); } #endif *def = temp; @@ -2303,8 +2438,15 @@ } else { result = 1; SET_COLOR_RES(res, def.pixel); - TRACE(("AllocateAnsiColor[%d] %s (pixel 0x%06lx)\n", - (int) (res - TScreenOf(xw)->Acolors), spec, def.pixel)); + res->red = def.red; + res->green = def.green; + res->blue = def.blue; + TRACE(("AllocateAnsiColor[%d] %s (rgb:%04x/%04x/%04x, pixel 0x%06lx)\n", + (int) (res - TScreenOf(xw)->Acolors), spec, + def.red, + def.green, + def.blue, + def.pixel)); #if OPT_COLOR_RES if (!res->mode) result = 0; @@ -2484,6 +2626,14 @@ #define allocateExactRGB(xw, cmap, def) XAllocColor(TScreenOf(xw)->display, cmap, def) #endif /* OPT_ISO_COLORS */ +Boolean +allocateBestRGB(XtermWidget xw, XColor * def) +{ + Colormap cmap = xw->core.colormap; + + return allocateExactRGB(xw, cmap, def) || allocateClosestRGB(xw, cmap, def); +} + static Boolean xtermAllocColor(XtermWidget xw, XColor * def, const char *spec) { @@ -2492,8 +2642,7 @@ Colormap cmap = xw->core.colormap; if (XParseColor(screen->display, cmap, spec, def) - && (allocateExactRGB(xw, cmap, def) - || allocateClosestRGB(xw, cmap, def))) { + && allocateBestRGB(xw, def)) { TRACE(("xtermAllocColor -> %x/%x/%x\n", def->red, def->green, def->blue)); result = True; @@ -2501,9 +2650,63 @@ return result; } +/* + * This provides an approximation (the closest color from xterm's palette) + * rather than the "exact" color (whatever the display could provide, actually) + * because of the context in which it is used. + */ +#define ColorDiff(given,cache) ((long) ((cache) >> 8) - (long) (given)) +int +xtermClosestColor(XtermWidget xw, int find_red, int find_green, int find_blue) +{ + int result = -1; +#if OPT_COLOR_RES && OPT_ISO_COLORS + int n; + int best_index = -1; + unsigned long best_value = 0; + unsigned long this_value; + long diff_red, diff_green, diff_blue; + + TRACE(("xtermClosestColor(%x/%x/%x)\n", find_red, find_green, find_blue)); + + for (n = NUM_ANSI_COLORS - 1; n >= 0; --n) { + ColorRes *res = &(TScreenOf(xw)->Acolors[n]); + + /* ensure that we have a value for each of the colors */ + if (!res->mode) { + (void) AllocateAnsiColor(xw, res, res->resource); + } + + /* find the closest match */ + if (res->mode == True) { + TRACE2(("...lookup %lx -> %x/%x/%x\n", + res->value, res->red, res->green, res->blue)); + diff_red = ColorDiff(find_red, res->red); + diff_green = ColorDiff(find_green, res->green); + diff_blue = ColorDiff(find_blue, res->blue); + this_value = (unsigned long) ((diff_red * diff_red) + + (diff_green * diff_green) + + (diff_blue * diff_blue)); + if (best_index < 0 || this_value < best_value) { + best_index = n; + best_value = this_value; + } + } + } + TRACE(("...best match at %d with diff %lx\n", best_index, best_value)); + result = best_index; +#else + (void) xw; + (void) find_red; + (void) find_green; + (void) find_blue; +#endif + return result; +} + #if OPT_PASTE64 static void -ManipulateSelectionData(XtermWidget xw, TScreen * screen, char *buf, int final) +ManipulateSelectionData(XtermWidget xw, TScreen *screen, char *buf, int final) { #define PDATA(a,b) { a, #b } static struct { @@ -2524,9 +2727,9 @@ }; const char *base = buf; - char *used = x_strdup(base); + char *used; Cardinal j, n = 0; - String *select_args = 0; + String *select_args; TRACE(("Manipulate selection data\n")); @@ -2539,46 +2742,54 @@ if (*base == '\0') base = "s0"; - if ((select_args = TypeCallocN(String, 1 + strlen(base))) == 0) - return; - while (*base != '\0') { - for (j = 0; j < XtNumber(table); ++j) { - if (*base == table[j].given) { - used[n] = *base; - select_args[n++] = table[j].result; - TRACE(("atom[%d] %s\n", n, table[j].result)); - break; - } - } - ++base; - } - used[n] = 0; - if (!strcmp(buf, "?")) { - if (AllowWindowOps(xw, ewGetSelection)) { - TRACE(("Getting selection\n")); - unparseputc1(xw, ANSI_OSC); - unparseputs(xw, "52"); - unparseputc(xw, ';'); - - unparseputs(xw, used); - unparseputc(xw, ';'); - - /* Tell xtermGetSelection data is base64 encoded */ - screen->base64_paste = n; - screen->base64_final = final; + if ((used = x_strdup(base)) != 0) { + if ((select_args = TypeCallocN(String, 2 + strlen(base))) != 0) { + while (*base != '\0') { + for (j = 0; j < XtNumber(table); ++j) { + if (*base == table[j].given) { + used[n] = *base; + select_args[n++] = table[j].result; + TRACE(("atom[%d] %s\n", n, table[j].result)); + break; + } + } + ++base; + } + used[n] = 0; - /* terminator will be written in this call */ - xtermGetSelection((Widget) xw, (Time) 0, select_args, n, NULL); - } - } else { - if (AllowWindowOps(xw, ewSetSelection)) { - TRACE(("Setting selection with %s\n", buf)); - ClearSelectionBuffer(screen); - while (*buf != '\0') - AppendToSelectionBuffer(screen, CharOf(*buf++)); - CompleteSelection(xw, select_args, n); + if (!strcmp(buf, "?")) { + if (AllowWindowOps(xw, ewGetSelection)) { + TRACE(("Getting selection\n")); + unparseputc1(xw, ANSI_OSC); + unparseputs(xw, "52"); + unparseputc(xw, ';'); + + unparseputs(xw, used); + unparseputc(xw, ';'); + + /* Tell xtermGetSelection data is base64 encoded */ + screen->base64_paste = n; + screen->base64_final = final; + + /* terminator will be written in this call */ + xtermGetSelection((Widget) xw, + XtLastTimestampProcessed(TScreenOf(xw)->display), + select_args, n, + NULL); + } + } else { + if (AllowWindowOps(xw, ewSetSelection)) { + TRACE(("Setting selection with %s\n", buf)); + ClearSelectionBuffer(screen); + while (*buf != '\0') + AppendToSelectionBuffer(screen, CharOf(*buf++)); + CompleteSelection(xw, select_args, n); + } + } + free(select_args); } + free(used); } } } @@ -2589,7 +2800,7 @@ #define IsSetUtf8Title(xw) (IsTitleMode(xw, tmSetUtf8) || (xw->screen.utf8_title)) static Bool -xtermIsPrintable(XtermWidget xw, Char ** bufp, Char * last) +xtermIsPrintable(XtermWidget xw, Char **bufp, Char *last) { TScreen *screen = TScreenOf(xw); Bool result = False; @@ -2914,7 +3125,7 @@ * the corresponding menu font entry. */ static int -ParseShiftedFont(XtermWidget xw, String source, String * target) +ParseShiftedFont(XtermWidget xw, String source, String *target) { TScreen *screen = TScreenOf(xw); int num = screen->menu_font_number; @@ -3079,7 +3290,7 @@ /***====================================================================***/ void -do_osc(XtermWidget xw, Char * oscbuf, size_t len, int final) +do_osc(XtermWidget xw, Char *oscbuf, size_t len, int final) { TScreen *screen = TScreenOf(xw); int mode; @@ -3146,6 +3357,27 @@ } /* + * Check if the palette changed and there are no more immediate changes + * that could be deferred to the next repaint. + */ + if (xw->misc.palette_changed) { + switch (mode) { + case 3: /* change X property */ + case 30: /* Konsole (unused) */ + case 31: /* Konsole (unused) */ + case 50: /* font operations */ + case 51: /* Emacs (unused) */ +#if OPT_PASTE64 + case 52: /* selection data */ +#endif + TRACE(("forced repaint after palette changed\n")); + xw->misc.palette_changed = False; + xtermRepaint(xw); + break; + } + } + + /* * Most OSC controls other than resets require data. Handle the others as * a special case. */ @@ -3214,14 +3446,14 @@ /* FALLTHRU */ case 4: if (ChangeAnsiColorRequest(xw, buf, ansi_colors, final)) - xtermRepaint(xw); + xw->misc.palette_changed = True; break; case OSC_Reset(5): ansi_colors = NUM_ANSI_COLORS; /* FALLTHRU */ case OSC_Reset(4): if (ResetAnsiColorRequest(xw, buf, ansi_colors)) - xtermRepaint(xw); + xw->misc.palette_changed = True; break; #endif case OSC_TEXT_FG: @@ -3371,7 +3603,7 @@ { while (*cp) { const char *base = cp; - char *str = CastMallocN(char, strlen(cp) + 1); + char *str = CastMallocN(char, strlen(cp) + 2); unsigned key = 0; int lo, hi; int len = 0; @@ -3386,6 +3618,7 @@ } } if (len > 0 && key < MAX_UDK) { + str[len] = '\0'; if (user_keys[key].str != 0) free(user_keys[key].str); user_keys[key].str = str; @@ -3400,12 +3633,55 @@ } } +/* + * Parse numeric parameters. Normally we use a state machine to simplify + * interspersing with control characters, but have the string already. + */ +static void +parse_ansi_params(ANSI *params, const char **string) +{ + const char *cp = *string; + ParmType nparam = 0; + int last_empty = 1; + + memset(params, 0, sizeof(*params)); + while (*cp != '\0') { + Char ch = CharOf(*cp++); + + if (isdigit(ch)) { + last_empty = 0; + if (nparam < NPARAM) { + params->a_param[nparam] = + (ParmType) ((params->a_param[nparam] * 10) + + (ch - '0')); + } + } else if (ch == ';') { + last_empty = 1; + nparam++; + } else if (ch < 32) { + /* EMPTY */ ; + } else { + /* should be 0x30 to 0x7e */ + params->a_final = ch; + break; + } + } + + *string = cp; + if (!last_empty) + nparam++; + if (nparam > NPARAM) + params->a_nparam = NPARAM; + else + params->a_nparam = nparam; +} + #if OPT_TRACE #define SOFT_WIDE 10 #define SOFT_HIGH 20 static void -parse_decdld(ANSI * params, const char *string) +parse_decdld(ANSI *params, const char *string) { char DscsName[8]; int len; @@ -3425,7 +3701,7 @@ ? Pcmw : (Pcmw + 3))); int char_high = ((Pcmh == 0) - ? ((Pcmw >= 2 || Pcmw <= 4) + ? ((Pcmw >= 2 && Pcmw <= 4) ? 10 : 20) : Pcmh); @@ -3514,42 +3790,8 @@ #define parse_decdld(p,q) /* nothing */ #endif -/* - * Parse numeric parameters. Normally we use a state machine to simplify - * interspersing with control characters, but have the string already. - */ -static void -parse_ansi_params(ANSI * params, const char **string) -{ - const char *cp = *string; - ParmType nparam = 0; - - memset(params, 0, sizeof(*params)); - while (*cp != '\0') { - Char ch = CharOf(*cp++); - - if (isdigit(ch)) { - if (nparam < NPARAM) { - params->a_param[nparam] = - (ParmType) ((params->a_param[nparam] * 10) - + (ch - '0')); - } - } else if (ch == ';') { - if (++nparam < NPARAM) - params->a_nparam = nparam; - } else if (ch < 32) { - /* EMPTY */ ; - } else { - /* should be 0x30 to 0x7e */ - params->a_final = ch; - break; - } - } - *string = cp; -} - void -do_dcs(XtermWidget xw, Char * dcsbuf, size_t dcslen) +do_dcs(XtermWidget xw, Char *dcsbuf, size_t dcslen) { TScreen *screen = TScreenOf(xw); char reply[BUFSIZ]; @@ -3575,6 +3817,10 @@ && (xw->flags & PROTECTED) ? 1 : 0, cp); } else if (!strcmp(cp, "\"p")) { /* DECSCL */ + if (screen->vtXX_level < 2) { + /* actually none of DECRQSS is valid for vt100's */ + break; + } sprintf(reply, "%d%s%s", (screen->vtXX_level ? screen->vtXX_level : 1) + 60, @@ -3587,6 +3833,12 @@ sprintf(reply, "%d;%dr", screen->top_marg + 1, screen->bot_marg + 1); + } else if (!strcmp(cp, "s")) { /* DECSLRM */ + if (screen->vtXX_level >= 4) { /* VT420 */ + sprintf(reply, "%d;%ds", + screen->lft_marg + 1, + screen->rgt_marg + 1); + } } else if (!strcmp(cp, "m")) { /* SGR */ strcpy(reply, "0"); if (xw->flags & BOLD) @@ -3646,20 +3898,22 @@ #endif strcat(reply, "m"); } else if (!strcmp(cp, " q")) { /* DECSCUSR */ - int code = 0; - if (screen->cursor_underline) - code |= 2; + int code = STEADY_BLOCK; + if (isCursorUnderline(screen)) + code = STEADY_UNDERLINE; + else if (isCursorBar(screen)) + code = STEADY_BAR; #if OPT_BLINK_CURS - if (screen->cursor_blink) - code |= 1; + if (screen->cursor_blink_esc == 0) + code -= 1; #endif - sprintf(reply, "%d%s", code + 1, cp); + sprintf(reply, "%d%s", code, cp); } else okay = False; if (okay) { unparseputc1(xw, ANSI_DCS); - unparseputc(xw, okay ? '1' : '0'); + unparseputc(xw, '1'); unparseputc(xw, '$'); unparseputc(xw, 'r'); cp = reply; @@ -3742,9 +3996,30 @@ break; #endif default: - if (screen->terminal_id >= 200) { /* VT220 */ + if (screen->terminal_id == 125 || + screen->vtXX_level >= 2) { /* VT220 */ parse_ansi_params(¶ms, &cp); switch (params.a_final) { +#if OPT_SIXEL_GRAPHICS + case 'p': + if (screen->terminal_id == 125 || + screen->terminal_id == 240 || + screen->terminal_id == 241 || + screen->terminal_id == 330 || + screen->terminal_id == 340) { + parse_regis(xw, ¶ms, cp); + } + break; + case 'q': + if (screen->terminal_id == 125 || + screen->terminal_id == 240 || + screen->terminal_id == 241 || + screen->terminal_id == 330 || + screen->terminal_id == 340) { + parse_sixel(xw, ¶ms, cp); + } + break; +#endif case '|': /* DECUDK */ if (params.a_param[0] == 0) reset_decudk(); @@ -3770,7 +4045,7 @@ }; #define MdBool(bool) ((bool) ? mdMaybeSet : mdMaybeReset) -#define MdFlag(mode,flag) MdBool(xw->keyboard.flags & MODE_KAM) +#define MdFlag(mode,flag) MdBool((mode) & (flag)) /* * Reply is the same format as the query, with pair of mode/value: @@ -3849,213 +4124,227 @@ TScreen *screen = TScreenOf(xw); switch (params[0]) { - case 1: /* DECCKM */ + case srm_DECCKM: result = MdFlag(xw->keyboard.flags, MODE_DECCKM); break; - case 2: /* DECANM - ANSI/VT52 mode */ + case srm_DECANM: /* ANSI/VT52 mode */ #if OPT_VT52_MODE - result = MdBool(screen->terminal_id >= 100); + result = MdBool(screen->vtXX_level >= 1); #else result = mdMaybeSet; #endif break; - case 3: /* DECCOLM */ + case srm_DECCOLM: result = MdFlag(xw->flags, IN132COLUMNS); break; - case 4: /* DECSCLM (slow scroll) */ + case srm_DECSCLM: /* (slow scroll) */ result = MdFlag(xw->flags, SMOOTHSCROLL); break; - case 5: /* DECSCNM */ + case srm_DECSCNM: result = MdFlag(xw->flags, REVERSE_VIDEO); break; - case 6: /* DECOM */ + case srm_DECOM: result = MdFlag(xw->flags, ORIGIN); break; - case 7: /* DECAWM */ + case srm_DECAWM: result = MdFlag(xw->flags, WRAPAROUND); break; - case 8: /* DECARM */ + case srm_DECARM: result = mdAlwaysReset; break; - case SET_X10_MOUSE: /* X10 mouse */ + case srm_X10_MOUSE: /* X10 mouse */ result = MdBool(screen->send_mouse_pos == X10_MOUSE); break; #if OPT_TOOLBAR - case 10: /* rxvt */ + case srm_RXVT_TOOLBAR: result = MdBool(resource.toolBar); break; #endif #if OPT_BLINK_CURS - case 12: /* att610: Start/stop blinking cursor */ + case srm_ATT610_BLINK: /* att610: Start/stop blinking cursor */ result = MdBool(screen->cursor_blink_res); break; #endif - case 18: /* DECPFF: print form feed */ + case srm_DECPFF: /* print form feed */ result = MdBool(PrinterOf(screen).printer_formfeed); break; - case 19: /* DECPEX: print extent */ + case srm_DECPEX: /* print extent */ result = MdBool(PrinterOf(screen).printer_extent); break; - case 25: /* DECTCEM: Show/hide cursor (VT200) */ + case srm_DECTCEM: /* Show/hide cursor (VT200) */ result = MdBool(screen->cursor_set); break; - case 30: /* rxvt */ + case srm_RXVT_SCROLLBAR: result = MdBool(screen->fullVwin.sb_info.width != OFF); break; #if OPT_SHIFT_FONTS - case 35: /* rxvt */ + case srm_RXVT_FONTSIZE: result = MdBool(xw->misc.shift_fonts); break; #endif #if OPT_TEK4014 - case 38: /* DECTEK */ + case srm_DECTEK: result = MdBool(TEK4014_ACTIVE(xw)); break; #endif - case 40: /* 132 column mode */ + case srm_132COLS: result = MdBool(screen->c132); break; - case 41: /* curses hack */ + case srm_CURSES_HACK: result = MdBool(screen->curses); break; - case 42: /* DECNRCM national charset (VT220) */ + case srm_DECNRCM: /* national charset (VT220) */ result = MdFlag(xw->flags, NATIONAL); break; - case 44: /* margin bell */ + case srm_MARGIN_BELL: /* margin bell */ result = MdBool(screen->marginbell); break; - case 45: /* reverse wraparound */ + case srm_REVERSEWRAP: /* reverse wraparound */ result = MdFlag(xw->flags, REVERSEWRAP); break; #ifdef ALLOWLOGGING - case 46: /* logging */ + case srm_ALLOWLOGGING: /* logging */ #ifdef ALLOWLOGFILEONOFF result = MdBool(screen->logging); #endif /* ALLOWLOGFILEONOFF */ break; #endif - case 1049: /* alternate buffer & cursor */ + case srm_OPT_ALTBUF_CURSOR: /* alternate buffer & cursor */ /* FALLTHRU */ - case 1047: + case srm_OPT_ALTBUF: /* FALLTHRU */ - case 47: /* alternate buffer */ + case srm_ALTBUF: result = MdBool(screen->whichBuf); break; - case 66: /* DECNKM */ + case srm_DECNKM: result = MdFlag(xw->keyboard.flags, MODE_DECKPAM); break; - case 67: /* DECBKM */ + case srm_DECBKM: result = MdFlag(xw->keyboard.flags, MODE_DECBKM); break; - case SET_VT200_MOUSE: /* xterm bogus sequence */ + case srm_DECLRMM: + result = MdFlag(xw->flags, LEFT_RIGHT); + break; +#if OPT_SIXEL_GRAPHICS + case srm_DECSDM: + result = MdFlag(xw->keyboard.flags, MODE_DECSDM); + break; +#endif + case srm_DECNCSM: + result = MdFlag(xw->flags, NOCLEAR_COLM); + break; + case srm_VT200_MOUSE: /* xterm bogus sequence */ result = MdBool(screen->send_mouse_pos == VT200_MOUSE); break; - case SET_VT200_HIGHLIGHT_MOUSE: /* xterm sequence w/hilite tracking */ + case srm_VT200_HIGHLIGHT_MOUSE: /* xterm sequence w/hilite tracking */ result = MdBool(screen->send_mouse_pos == VT200_HIGHLIGHT_MOUSE); break; - case SET_BTN_EVENT_MOUSE: + case srm_BTN_EVENT_MOUSE: result = MdBool(screen->send_mouse_pos == BTN_EVENT_MOUSE); break; - case SET_ANY_EVENT_MOUSE: + case srm_ANY_EVENT_MOUSE: result = MdBool(screen->send_mouse_pos == ANY_EVENT_MOUSE); break; #if OPT_FOCUS_EVENT - case SET_FOCUS_EVENT_MOUSE: + case srm_FOCUS_EVENT_MOUSE: result = MdBool(screen->send_focus_pos); break; #endif - case SET_EXT_MODE_MOUSE: + case srm_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_SGR_EXT_MODE_MOUSE: + case srm_SGR_EXT_MODE_MOUSE: /* FALLTHRU */ - case SET_URXVT_EXT_MODE_MOUSE: + case srm_URXVT_EXT_MODE_MOUSE: result = MdBool(screen->extend_coords == params[0]); break; - case 1010: /* rxvt */ + case srm_ALTERNATE_SCROLL: + result = MdBool(screen->alternateScroll); + break; + case srm_RXVT_SCROLL_TTY_OUTPUT: result = MdBool(screen->scrollttyoutput); break; - case 1011: /* rxvt */ + case srm_RXVT_SCROLL_TTY_KEYPRESS: result = MdBool(screen->scrollkey); break; - case 1034: + case srm_EIGHT_BIT_META: result = MdBool(screen->eight_bit_meta); break; #if OPT_NUM_LOCK - case 1035: + case srm_REAL_NUMLOCK: result = MdBool(xw->misc.real_NumLock); break; - case 1036: + case srm_META_SENDS_ESC: result = MdBool(screen->meta_sends_esc); break; #endif - case 1037: + case srm_DELETE_IS_DEL: result = MdBool(screen->delete_is_del); break; #if OPT_NUM_LOCK - case 1039: + case srm_ALT_SENDS_ESC: result = MdBool(screen->alt_sends_esc); break; #endif - case 1040: + case srm_KEEP_SELECTION: result = MdBool(screen->keepSelection); break; - case 1041: + case srm_SELECT_TO_CLIPBOARD: result = MdBool(screen->selectToClipboard); break; - case 1042: + case srm_BELL_IS_URGENT: result = MdBool(screen->bellIsUrgent); break; - case 1043: + case srm_POP_ON_BELL: result = MdBool(screen->poponbell); break; - case 1048: + case srm_TITE_INHIBIT: result = MdBool(screen->sc[screen->whichBuf].saved); break; #if OPT_TCAP_FKEYS - case 1050: + case srm_TCAP_FKEYS: result = MdBool(xw->keyboard.type == keyboardIsTermcap); break; #endif #if OPT_SUN_FUNC_KEYS - case 1051: + case srm_SUN_FKEYS: result = MdBool(xw->keyboard.type == keyboardIsSun); break; #endif #if OPT_HP_FUNC_KEYS - case 1052: + case srm_HP_FKEYS: result = MdBool(xw->keyboard.type == keyboardIsHP); break; #endif #if OPT_SCO_FUNC_KEYS - case 1053: + case srm_SCO_FKEYS: result = MdBool(xw->keyboard.type == keyboardIsSCO); break; #endif - case 1060: + case srm_LEGACY_FKEYS: result = MdBool(xw->keyboard.type == keyboardIsLegacy); break; #if OPT_SUNPC_KBD - case 1061: + case srm_VT220_FKEYS: result = MdBool(xw->keyboard.type == keyboardIsVT220); break; #endif #if OPT_READLINE - case SET_BUTTON1_MOVE_POINT: + case srm_BUTTON1_MOVE_POINT: result = MdBool(screen->click1_moves); break; - case SET_BUTTON2_MOVE_POINT: + case srm_BUTTON2_MOVE_POINT: result = MdBool(screen->paste_moves); break; - case SET_DBUTTON3_DELETE: + case srm_DBUTTON3_DELETE: result = MdBool(screen->dclick3_deletes); break; - case SET_PASTE_IN_BRACKET: + case srm_PASTE_IN_BRACKET: result = MdBool(screen->paste_brackets); break; - case SET_PASTE_QUOTE: + case srm_PASTE_QUOTE: result = MdBool(screen->paste_quotes); break; - case SET_PASTE_LITERAL_NL: + case srm_PASTE_LITERAL_NL: result = MdBool(screen->paste_literal_nl); break; #endif /* OPT_READLINE */ @@ -4082,13 +4371,243 @@ return 0; } -static void +#ifdef HAVE_LIBXPM + +#ifndef PIXMAP_ROOTDIR +#define PIXMAP_ROOTDIR "/usr/share/pixmaps/" +#endif + +typedef struct { + const char *name; + const char *const *data; +} XPM_DATA; + +static char * +x_find_icon(char **work, int *state, const char *suffix) +{ + const char *filename = resource.icon_hint; + const char *prefix = PIXMAP_ROOTDIR; + const char *larger = "_48x48"; + char *result = 0; + size_t length; + + if (*state >= 0) { + if ((*state & 1) == 0) + suffix = ""; + if ((*state & 2) == 0) + larger = ""; + if ((*state & 4) == 0) { + prefix = ""; + } else if (!strncmp(filename, "/", (size_t) 1) || + !strncmp(filename, "./", (size_t) 2) || + !strncmp(filename, "../", (size_t) 3)) { + *state = -1; + } else if (*state >= 8) { + *state = -1; + } + } + + if (*state >= 0) { + if (*work) { + free(*work); + *work = 0; + } + length = 3 + strlen(prefix) + strlen(filename) + strlen(larger) + + strlen(suffix); + if ((result = malloc(length)) != 0) { + sprintf(result, "%s%s%s%s", prefix, filename, larger, suffix); + *work = result; + } + *state += 1; + TRACE(("x_find_icon %d:%s\n", *state, result)); + } + return result; +} + +#if OPT_BUILTIN_XPMS +static const XPM_DATA * +BuiltInXPM(const XPM_DATA * table, Cardinal length) +{ + const char *find = resource.icon_hint; + const XPM_DATA *result = 0; + if (!IsEmpty(find)) { + Cardinal n; + for (n = 0; n < length; ++n) { + if (!x_strcasecmp(find, table[n].name)) { + result = table + n; + break; + } + } + + /* + * As a fallback, check if the icon name matches without the lengths, + * which are all _HHxWW format. + */ + if (result == 0) { + const char *base = table[0].name; + const char *last = strchr(base, '_'); + if (last != 0 + && !x_strncasecmp(find, base, (unsigned) (last - base))) { + result = table + length - 1; + } + } + } + return result; +} +#endif /* OPT_BUILTIN_XPMS */ + +typedef enum { + eHintDefault = 0 /* use the largest builtin-icon */ + ,eHintNone + ,eHintSearch +} ICON_HINT; + +static ICON_HINT +which_icon_hint(void) +{ + ICON_HINT result = eHintDefault; + if (!IsEmpty(resource.icon_hint)) { + if (!x_strcasecmp(resource.icon_hint, "none")) { + result = eHintNone; + } else { + result = eHintSearch; + } + } + return result; +} +#endif /* HAVE_LIBXPM */ + +int +getVisualDepth(XtermWidget xw) +{ + Display *display = TScreenOf(xw)->display; + XVisualInfo myTemplate, *visInfoPtr; + int numFound; + int result = 0; + + myTemplate.visualid = XVisualIDFromVisual(DefaultVisual(display, + XDefaultScreen(display))); + visInfoPtr = XGetVisualInfo(display, (long) VisualIDMask, + &myTemplate, &numFound); + if (visInfoPtr != 0) { + if (numFound != 0) { + result = visInfoPtr->depth; + } + XFree(visInfoPtr); + } + return result; +} + +/* + * WM_ICON_SIZE should be honored if possible. + */ +void +xtermLoadIcon(XtermWidget xw) +{ +#ifdef HAVE_LIBXPM + Display *dpy = XtDisplay(xw); + Pixmap myIcon = 0; + Pixmap myMask = 0; + char *workname = 0; + ICON_HINT hint = which_icon_hint(); +#if OPT_BUILTIN_XPMS +#include +#include +#include +#include +#else +#include +#endif + + TRACE(("xtermLoadIcon %p:%s\n", (void *) xw, NonNull(resource.icon_hint))); + + if (hint == eHintSearch) { + int state = 0; + while (x_find_icon(&workname, &state, ".xpm") != 0) { + Pixmap resIcon = 0; + Pixmap shapemask = 0; + XpmAttributes attributes; + + attributes.depth = (unsigned) getVisualDepth(xw); + attributes.valuemask = XpmDepth; + + if (XpmReadFileToPixmap(dpy, + DefaultRootWindow(dpy), + workname, + &resIcon, + &shapemask, + &attributes) == XpmSuccess) { + myIcon = resIcon; + myMask = shapemask; + TRACE(("...success\n")); + break; + } + } + } + + /* + * If no external file was found, look for the name in the built-in table. + * If that fails, just use the biggest mini-icon. + */ + if (myIcon == 0 && hint != eHintNone) { + char **data; +#if OPT_BUILTIN_XPMS + const XPM_DATA *myData = 0; + myData = BuiltInXPM(mini_xterm_xpms, XtNumber(mini_xterm_xpms)); + if (myData == 0) + myData = BuiltInXPM(filled_xterm_xpms, XtNumber(filled_xterm_xpms)); + if (myData == 0) + myData = BuiltInXPM(xterm_color_xpms, XtNumber(xterm_color_xpms)); + if (myData == 0) + myData = BuiltInXPM(xterm_xpms, XtNumber(xterm_xpms)); + if (myData == 0) + myData = &mini_xterm_xpms[XtNumber(mini_xterm_xpms) - 1]; + data = (char **) myData->data, +#else + data = (char **) &mini_xterm_48x48_xpm; +#endif + if (XpmCreatePixmapFromData(dpy, + DefaultRootWindow(dpy), + data, + &myIcon, &myMask, 0) != 0) { + myIcon = 0; + myMask = 0; + } + } + + if (myIcon != 0) { + XWMHints *hints = XGetWMHints(dpy, VShellWindow(xw)); + if (!hints) + hints = XAllocWMHints(); + + if (hints) { + hints->flags |= IconPixmapHint; + hints->icon_pixmap = myIcon; + if (myMask) { + hints->flags |= IconMaskHint; + hints->icon_mask = myMask; + } + + XSetWMHints(dpy, VShellWindow(xw), hints); + XFree(hints); + TRACE(("...loaded icon\n")); + } + } + + if (workname != 0) + free(workname); + +#else + (void) xw; +#endif +} + +void ChangeGroup(XtermWidget xw, const char *attribute, char *value) { #if OPT_WIDE_CHARS static Char *converted; /* NO_LEAKS */ #endif - static char empty[1]; Arg args[1]; Boolean changed = True; @@ -4105,14 +4624,16 @@ return; if (value == 0) - value = empty; + value = emptyString; if (IsTitleMode(xw, tmSetBase16)) { const char *temp; char *test; value = x_decode_hex(value, &temp); - if (*temp != '\0') + if (*temp != '\0') { + free(value); return; + } for (test = value; *test != '\0'; ++test) { if (CharOf(*test) < 32) { *test = '\0'; @@ -4218,13 +4739,12 @@ } #endif } - - free(my_attr); - - if (IsTitleMode(xw, tmSetBase16)) - free(value); - } + if (IsTitleMode(xw, tmSetBase16)) { + free(value); + } + free(my_attr); + return; } @@ -4232,22 +4752,9 @@ ChangeIconName(XtermWidget xw, char *name) { if (name == 0) { - static char dummy[] = ""; - name = dummy; + name = emptyString; } -#if OPT_ZICONBEEP /* If warning should be given then give it */ - if (resource.zIconBeep && TScreenOf(xw)->zIconBeep_flagged) { - char *newname = CastMallocN(char, strlen(name) + 4); - if (!newname) { - xtermWarning("malloc failed in ChangeIconName\n"); - return; - } - strcpy(newname, "*** "); - strcat(newname, name); - ChangeGroup(xw, XtNiconName, newname); - free(newname); - } else -#endif /* OPT_ZICONBEEP */ + if (!showZIconBeep(xw, name)) ChangeGroup(xw, XtNiconName, name); } @@ -4369,11 +4876,9 @@ void Panic(const char *s GCC_UNUSED, int a GCC_UNUSED) { -#ifdef DEBUG - if (debug) { + if_DEBUG({ xtermWarning(s, a); - } -#endif /* DEBUG */ + }); } const char * @@ -4430,7 +4935,6 @@ { ERROR_SCALLOC, "Alloc: calloc() failed on base" }, { ERROR_SCALLOC2, "Alloc: calloc() failed on rows" }, { ERROR_SAVE_PTR, "ScrnPointers: malloc/realloc() failed" }, - { ERROR_MMALLOC, "my_memmove: malloc/realloc failed" }, }; /* *INDENT-ON* */ @@ -4458,44 +4962,48 @@ Cleanup(code); } -/* - * cleanup by sending SIGHUP to client processes - */ void -Cleanup(int code) +NormalExit(void) { static Bool cleaning; - TScreen *screen = TScreenOf(term); /* * Process "-hold" and session cleanup only for a normal exit. */ - if (code == 0) { - if (cleaning) { - hold_screen = 0; - return; - } - - cleaning = True; - need_cleanup = False; + if (cleaning) { + hold_screen = 0; + return; + } - TRACE(("Cleanup %d\n", code)); + cleaning = True; + need_cleanup = False; - if (hold_screen) { - hold_screen = 2; - while (hold_screen) { - xevents(); - Sleep(10); - } + if (hold_screen) { + hold_screen = 2; + while (hold_screen) { + xevents(); + Sleep(10); } + } #if OPT_SESSION_MGT - if (resource.sessionMgt) { - XtVaSetValues(toplevel, - XtNjoinSession, False, - (void *) 0); - } -#endif + if (resource.sessionMgt) { + XtVaSetValues(toplevel, + XtNjoinSession, False, + (void *) 0); } +#endif + Cleanup(0); +} + +/* + * cleanup by sending SIGHUP to client processes + */ +void +Cleanup(int code) +{ + TScreen *screen = TScreenOf(term); + + TRACE(("Cleanup %d\n", code)); if (screen->pid > 1) { (void) kill_process_group(screen->pid, SIGHUP); @@ -4510,10 +5018,12 @@ char * xtermFindShell(char *leaf, Bool warning) { + char *s0; char *s; char *d; char *tmp; char *result = leaf; + Bool allocated = False; TRACE(("xtermFindShell(%s)\n", leaf)); @@ -4526,13 +5036,14 @@ if (getcwd(buffer, need) != 0) { sprintf(buffer + strlen(buffer), "/%s", result); result = buffer; + allocated = True; } else { free(buffer); } } } else if (*result != '\0' && strchr("+/-", *result) == 0) { /* find it in $PATH */ - if ((s = x_getenv("PATH")) != 0) { + if ((s = s0 = x_getenv("PATH")) != 0) { if ((tmp = TypeMallocN(char, strlen(leaf) + strlen(s) + 2)) != 0) { Bool found = False; while (*s != '\0') { @@ -4550,17 +5061,17 @@ && access(tmp, X_OK) == 0) { result = x_strdup(tmp); found = True; + allocated = True; } break; } - if (found) - break; } if (found) break; } free(tmp); } + free(s0); } } TRACE(("...xtermFindShell(%s)\n", result)); @@ -4569,8 +5080,13 @@ || access(result, X_OK) != 0) { if (warning) xtermWarning("No absolute path found for shell: %s\n", result); + if (allocated) + free(result); result = 0; } + /* be consistent, so that caller can always free the result */ + if (result != 0 && !allocated) + result = x_strdup(result); return result; } #endif /* VMS */ @@ -4715,7 +5231,7 @@ /*ARGSUSED*/ int -xerror(Display * d, XErrorEvent * ev) +xerror(Display *d, XErrorEvent * ev) { xtermWarning("warning, error event received:\n"); (void) XmuPrintDefaultErrorMessage(d, ev, stderr); @@ -4736,7 +5252,7 @@ /*ARGSUSED*/ int -xioerror(Display * dpy) +xioerror(Display *dpy) { int the_error = errno; @@ -4776,7 +5292,7 @@ #if OPT_TEK4014 static void -withdraw_window(Display * dpy, Window w, int scr) +withdraw_window(Display *dpy, Window w, int scr) { TRACE(("withdraw_window %#lx\n", (long) w)); (void) XmuUpdateMapHints(dpy, w, NULL); @@ -5031,7 +5547,9 @@ } else { code = 0; } - strcpy(temp, opt_array[j].desc); + sprintf(temp, "%.*s", + (int) sizeof(temp) - 2, + opt_array[j].desc); if (x_strindex(temp, "inhibit") != 0) code = -code; if (code != 0 @@ -5131,7 +5649,18 @@ #ifdef HAVE_LANGINFO_CODESET result = (strcmp(xtermEnvEncoding(), "UTF-8") == 0); #else - result = (strstr(xtermEnvLocale(), "UTF-8") != NULL); + { + char *locale = x_strdup(xtermEnvLocale()); + int n; + for (n = 0; locale[n] != 0; ++n) { + locale[n] = x_toupper(locale[n]); + } + if (strstr(locale, "UTF-8") != 0) + result = True; + else if (strstr(locale, "UTF8") != 0) + result = True; + free(locale); + } #endif TRACE(("xtermEnvUTF8 ->%s\n", BtoS(result))); } @@ -5140,45 +5669,6 @@ #endif /* OPT_WIDE_CHARS */ /* - * Returns the version-string used in the "-v' message as well as a few other - * places. It is derived (when possible) from the __vendorversion__ symbol - * that some newer imake configurations define. - */ -char * -xtermVersion(void) -{ - static char vendor_version[] = __vendorversion__; - static char *result; - - if (result == 0) { - char *vendor = vendor_version; - char first[BUFSIZ]; - char second[BUFSIZ]; - - result = CastMallocN(char, strlen(vendor) + 9); - if (result == 0) - result = vendor; - else { - /* some vendors leave trash in this string */ - for (;;) { - if (!strncmp(vendor, "Version ", (size_t) 8)) - vendor += 8; - else if (isspace(CharOf(*vendor))) - ++vendor; - else - break; - } - if (strlen(vendor) < BUFSIZ && - sscanf(vendor, "%[0-9.] %[A-Za-z_0-9.]", first, second) == 2) - sprintf(result, "%s %s(%d)", second, first, XTERM_PATCH); - else - sprintf(result, "%s(%d)", vendor, XTERM_PATCH); - } - } - return result; -} - -/* * Check if the current widget, or any parent, is the VT100 "xterm" widget. */ XtermWidget @@ -5206,7 +5696,7 @@ XtPointer client_data GCC_UNUSED, XtPointer call_data GCC_UNUSED) { - Cleanup(0); + NormalExit(); } static void @@ -5257,8 +5747,8 @@ XrmOptionDescRec * options, Cardinal num_options, int *argc_in_out, - String * argv_in_out, - String * fallback_resources, + String *argv_in_out, + String *fallback_resources, WidgetClass widget_class, ArgList args, Cardinal num_args) @@ -5296,7 +5786,7 @@ static int x11_errors; static int -catch_x11_error(Display * display, XErrorEvent * error_event) +catch_x11_error(Display *display, XErrorEvent * error_event) { (void) display; (void) error_event; @@ -5304,12 +5794,13 @@ return 0; } -static Boolean -validWindow(Display * dpy, Window win, XWindowAttributes * attrs) +Boolean +xtermGetWinAttrs(Display *dpy, Window win, XWindowAttributes * attrs) { Boolean result = False; Status code; + memset(attrs, 0, sizeof(*attrs)); if (win != None) { XErrorHandler save = XSetErrorHandler(catch_x11_error); x11_errors = 0; @@ -5325,6 +5816,44 @@ return result; } +Boolean +xtermGetWinProp(Display *display, + Window win, + Atom property, + long long_offset, + long long_length, + Atom req_type, + Atom * actual_type_return, + int *actual_format_return, + unsigned long *nitems_return, + unsigned long *bytes_after_return, + unsigned char **prop_return) +{ + Boolean result = True; + + if (win != None) { + XErrorHandler save = XSetErrorHandler(catch_x11_error); + x11_errors = 0; + if (XGetWindowProperty(display, + win, + property, + long_offset, + long_length, + False, + req_type, + actual_type_return, + actual_format_return, + nitems_return, + bytes_after_return, + prop_return) == Success + && x11_errors == 0) { + result = True; + } + XSetErrorHandler(save); + } + return result; +} + void xtermEmbedWindow(Window winToEmbedInto) { @@ -5332,7 +5861,7 @@ XWindowAttributes attrs; TRACE(("checking winToEmbedInto %#lx\n", winToEmbedInto)); - if (validWindow(dpy, winToEmbedInto, &attrs)) { + if (xtermGetWinAttrs(dpy, winToEmbedInto, &attrs)) { XtermWidget xw = term; TScreen *screen = TScreenOf(xw); diff -Nru xterm-278/os2main.c xterm-297/os2main.c --- xterm-278/os2main.c 2011-12-27 10:36:58.000000000 +0000 +++ xterm-297/os2main.c 1970-01-01 00:00:00.000000000 +0000 @@ -1,2227 +0,0 @@ -/* $XTermId: os2main.c,v 1.273 2011/12/27 10:36:58 tom Exp $ */ - -/* removed all foreign stuff to get the code more clear (hv) - * and did some rewrite for the obscure OS/2 environment - */ - -/*********************************************************** - -Copyright (c) 1987, 1988 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. - - 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 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. - -******************************************************************/ - -/* os2main.c */ -#define INCL_DOSFILEMGR -#define INCL_DOSDEVIOCTL -#define INCL_DOSSEMAPHORES -#ifdef __INNOTEK_LIBC__ -#define INCL_DOSDEVICES -#endif -#define I_NEED_OS2_H -#include -#define XTERM_MAIN - -#define RES_OFFSET(field) XtOffsetOf(XTERM_RESOURCE, field) - -#include - -#include -#ifdef I18N -#include -#endif - -#if OPT_TOOLBAR - -#if defined(HAVE_LIB_XAW) -#include -#elif defined(HAVE_LIB_XAW3D) -#include -#elif defined(HAVE_LIB_NEXTAW) -#include -#elif defined(HAVE_LIB_XAWPLUS) -#include -#endif - -#endif /* OPT_TOOLBAR */ - -#include -#include - -#include -#include -#include -#include -#include -#include -#include - -#if OPT_WIDE_CHARS -#include -#endif - -int -setpgrp(pid_t pid, gid_t pgid) -{ - return 0; -} - -int -chown(const char *fn, pid_t pid, gid_t gid) -{ - return 0; -} - -char * -ttyname(int fd) -{ - return "/dev/tty"; -} - -#include -#include /* for NOFILE */ -#include -#include - -static SIGNAL_T reapchild(int n); -static int spawnXTerm(XtermWidget /* xw */ ); -static void resize_termcap(XtermWidget xw); -static void set_owner(char *device, uid_t uid, gid_t gid, mode_t mode); - -static Bool added_utmp_entry = False; - -static uid_t save_ruid; -static gid_t save_rgid; - -/* -** Ordinarily it should be okay to omit the assignment in the following -** statement. Apparently the c89 compiler on AIX 4.1.3 has a bug, or does -** it? Without the assignment though the compiler will init command_to_exec -** to 0xffffffff instead of NULL; and subsequent usage, e.g. in spawnXTerm() to -** SEGV. -*/ -static char **command_to_exec = NULL; - -#if OPT_LUIT_PROG -static char **command_to_exec_with_luit = NULL; -#endif - -/* The following structures are initialized in main() in order -** to eliminate any assumptions about the internal order of their -** contents. -*/ -static struct termio d_tio; - -/* allow use of system default characters if defined and reasonable */ -#ifndef CEOF -#define CEOF CONTROL('D') -#endif -#ifndef CEOL -#define CEOL 0 -#endif -#ifndef CFLUSH -#define CFLUSH CONTROL('O') -#endif -#ifndef CLNEXT -#define CLNEXT CONTROL('V') -#endif -#ifndef CNUL -#define CNUL 0 -#endif -#ifndef CQUIT -#define CQUIT CONTROL('\\') -#endif -#ifndef CRPRNT -#define CRPRNT CONTROL('R') -#endif -#ifndef CSTART -#define CSTART CONTROL('Q') -#endif -#ifndef CSTOP -#define CSTOP CONTROL('S') -#endif -#ifndef CSUSP -#define CSUSP CONTROL('Z') -#endif -#ifndef CSWTCH -#define CSWTCH 0 -#endif -#ifndef CWERASE -#define CWERASE CONTROL('W') -#endif - -#define TERMIO_STRUCT struct termio - -/* - * SYSV has the termio.c_cc[V] and ltchars; BSD has tchars and ltchars; - * SVR4 has only termio.c_cc, but it includes everything from ltchars. - * POSIX termios has termios.c_cc, which is similar to SVR4. - */ -#define TTYMODE(name) { name, sizeof(name)-1, 0, 0 } -static Boolean override_tty_modes = False; -/* *INDENT-OFF* */ -static struct _xttymodes { - const char *name; - size_t len; - int set; - int value; -} ttymodelist[] = { - TTYMODE("intr"), /* tchars.t_intrc ; VINTR */ -#define XTTYMODE_intr 0 - TTYMODE("quit"), /* tchars.t_quitc ; VQUIT */ -#define XTTYMODE_quit 1 - TTYMODE("erase"), /* sgttyb.sg_erase ; VERASE */ -#define XTTYMODE_erase 2 - TTYMODE("kill"), /* sgttyb.sg_kill ; VKILL */ -#define XTTYMODE_kill 3 - TTYMODE("eof"), /* tchars.t_eofc ; VEOF */ -#define XTTYMODE_eof 4 - TTYMODE("eol"), /* VEOL */ -#define XTTYMODE_eol 5 - TTYMODE("swtch"), /* VSWTCH */ -#define XTTYMODE_swtch 6 - TTYMODE("start"), /* tchars.t_startc ; VSTART */ -#define XTTYMODE_start 7 - TTYMODE("stop"), /* tchars.t_stopc ; VSTOP */ -#define XTTYMODE_stop 8 - TTYMODE("brk"), /* tchars.t_brkc */ -#define XTTYMODE_brk 9 - TTYMODE("susp"), /* ltchars.t_suspc ; VSUSP */ -#define XTTYMODE_susp 10 - TTYMODE("dsusp"), /* ltchars.t_dsuspc ; VDSUSP */ -#define XTTYMODE_dsusp 11 - TTYMODE("rprnt"), /* ltchars.t_rprntc ; VREPRINT */ -#define XTTYMODE_rprnt 12 - TTYMODE("flush"), /* ltchars.t_flushc ; VDISCARD */ -#define XTTYMODE_flush 13 - TTYMODE("weras"), /* ltchars.t_werasc ; VWERASE */ -#define XTTYMODE_weras 14 - TTYMODE("lnext"), /* ltchars.t_lnextc ; VLNEXT */ -#define XTTYMODE_lnext 15 - { NULL, 0, 0, '\0' }, /* end of data */ -}; -/* *INDENT-ON* */ - -#define TMODE(ind,var) if (ttymodelist[ind].set) var = ttymodelist[ind].value - -static int parse_tty_modes(char *s, struct _xttymodes *modelist); - -static char passedPty[2]; /* name if pty if slave */ - -static int Console; -#include /* XmuGetHostname */ -#define MIT_CONSOLE_LEN 12 -#define MIT_CONSOLE "MIT_CONSOLE_" -static char mit_console_name[255 + MIT_CONSOLE_LEN + 1] = MIT_CONSOLE; -static Atom mit_console; - -static int tslot; -static jmp_buf env; - -/* used by VT (charproc.c) */ - -static XtResource application_resources[] = -{ - Sres("iconGeometry", "IconGeometry", icon_geometry, NULL), - Sres(XtNtitle, XtCTitle, title, NULL), - Sres(XtNiconName, XtCIconName, icon_name, NULL), - Sres("termName", "TermName", term_name, NULL), - Sres("ttyModes", "TtyModes", tty_modes, NULL), - Bres("hold", "Hold", hold_screen, False), - Bres("utmpInhibit", "UtmpInhibit", utmpInhibit, False), - Bres("utmpDisplayId", "UtmpDisplayId", utmpDisplayId, True), - Bres("messages", "Messages", messages, True), - Ires("minBufSize", "MinBufSize", minBufSize, 4096), - Ires("maxBufSize", "MaxBufSize", maxBufSize, 32768), - Sres("menuLocale", "MenuLocale", menuLocale, DEF_MENU_LOCALE), - Sres("omitTranslation", "OmitTranslation", omitTranslation, NULL), - Sres("keyboardType", "KeyboardType", keyboardType, "unknown"), -#if OPT_PRINT_ON_EXIT - Ires("printModeOnXError", "PrintModeOnXError", printModeOnXError, 0), - Sres("printFileOnXError", "PrintFileOnXError", printFileOnXError, NULL), -#endif -#if OPT_SUNPC_KBD - Bres("sunKeyboard", "SunKeyboard", sunKeyboard, False), -#endif -#if OPT_HP_FUNC_KEYS - Bres("hpFunctionKeys", "HpFunctionKeys", hpFunctionKeys, False), -#endif -#if OPT_SCO_FUNC_KEYS - Bres("scoFunctionKeys", "ScoFunctionKeys", scoFunctionKeys, False), -#endif -#if OPT_SUN_FUNC_KEYS - Bres("sunFunctionKeys", "SunFunctionKeys", sunFunctionKeys, False), -#endif -#if OPT_TCAP_FKEYS - Bres("tcapFunctionKeys", "TcapFunctionKeys", termcapKeys, False), -#endif -#if OPT_INITIAL_ERASE - Bres("ptyInitialErase", "PtyInitialErase", ptyInitialErase, DEF_INITIAL_ERASE), - Bres("backarrowKeyIsErase", "BackarrowKeyIsErase", backarrow_is_erase, DEF_BACKARO_ERASE), -#endif - Bres("useInsertMode", "UseInsertMode", useInsertMode, False), -#if OPT_ZICONBEEP - Ires("zIconBeep", "ZIconBeep", zIconBeep, 0), -#endif -#if OPT_PTY_HANDSHAKE - Bres("waitForMap", "WaitForMap", wait_for_map, False), - Bres("ptyHandshake", "PtyHandshake", ptyHandshake, True), - Bres("ptySttySize", "PtySttySize", ptySttySize, DEF_PTY_STTY_SIZE), -#endif -#if OPT_SAME_NAME - Bres("sameName", "SameName", sameName, True), -#endif -#if OPT_SESSION_MGT - Bres("sessionMgt", "SessionMgt", sessionMgt, True), -#endif -#if OPT_TOOLBAR - Bres(XtNtoolBar, XtCToolBar, toolBar, True), -#endif -#if OPT_MAXIMIZE - Bres(XtNmaximized, XtCMaximized, maximized, False), - Sres(XtNfullscreen, XtCFullscreen, fullscreen_s, "off"), -#endif -}; - -static String fallback_resources[] = -{ -#if OPT_TOOLBAR - "*toolBar: false", -#endif - "*SimpleMenu*menuLabel.vertSpace: 100", - "*SimpleMenu*HorizontalMargins: 16", - "*SimpleMenu*Sme.height: 16", - "*SimpleMenu*Cursor: left_ptr", - "*mainMenu.Label: Main Options (no app-defaults)", - "*vtMenu.Label: VT Options (no app-defaults)", - "*fontMenu.Label: VT Fonts (no app-defaults)", -#if OPT_TEK4014 - "*tekMenu.Label: Tek Options (no app-defaults)", -#endif - NULL -}; - -/* Command line options table. Only resources are entered here...there is a - pass over the remaining options after XrmParseCommand is let loose. */ -/* *INDENT-OFF* */ -static XrmOptionDescRec optionDescList[] = { -{"-geometry", "*vt100.geometry",XrmoptionSepArg, (XPointer) NULL}, -{"-132", "*c132", XrmoptionNoArg, (XPointer) "on"}, -{"+132", "*c132", XrmoptionNoArg, (XPointer) "off"}, -{"-ah", "*alwaysHighlight", XrmoptionNoArg, (XPointer) "on"}, -{"+ah", "*alwaysHighlight", XrmoptionNoArg, (XPointer) "off"}, -{"-aw", "*autoWrap", XrmoptionNoArg, (XPointer) "on"}, -{"+aw", "*autoWrap", XrmoptionNoArg, (XPointer) "off"}, -#ifndef NO_ACTIVE_ICON -{"-ai", "*activeIcon", XrmoptionNoArg, (XPointer) "off"}, -{"+ai", "*activeIcon", XrmoptionNoArg, (XPointer) "on"}, -#endif /* NO_ACTIVE_ICON */ -{"-b", "*internalBorder",XrmoptionSepArg, (XPointer) NULL}, -{"-bc", "*cursorBlink", XrmoptionNoArg, (XPointer) "on"}, -{"+bc", "*cursorBlink", XrmoptionNoArg, (XPointer) "off"}, -{"-bcf", "*cursorOffTime",XrmoptionSepArg, (XPointer) NULL}, -{"-bcn", "*cursorOnTime",XrmoptionSepArg, (XPointer) NULL}, -{"-bdc", "*colorBDMode", XrmoptionNoArg, (XPointer) "off"}, -{"+bdc", "*colorBDMode", XrmoptionNoArg, (XPointer) "on"}, -{"-cb", "*cutToBeginningOfLine", XrmoptionNoArg, (XPointer) "off"}, -{"+cb", "*cutToBeginningOfLine", XrmoptionNoArg, (XPointer) "on"}, -{"-cc", "*charClass", XrmoptionSepArg, (XPointer) NULL}, -{"-cm", "*colorMode", XrmoptionNoArg, (XPointer) "off"}, -{"+cm", "*colorMode", XrmoptionNoArg, (XPointer) "on"}, -{"-cn", "*cutNewline", XrmoptionNoArg, (XPointer) "off"}, -{"+cn", "*cutNewline", XrmoptionNoArg, (XPointer) "on"}, -{"-cr", "*cursorColor", XrmoptionSepArg, (XPointer) NULL}, -{"-cu", "*curses", XrmoptionNoArg, (XPointer) "on"}, -{"+cu", "*curses", XrmoptionNoArg, (XPointer) "off"}, -{"-dc", "*dynamicColors",XrmoptionNoArg, (XPointer) "off"}, -{"+dc", "*dynamicColors",XrmoptionNoArg, (XPointer) "on"}, -{"-fb", "*boldFont", XrmoptionSepArg, (XPointer) NULL}, -{"-fbb", "*freeBoldBox", XrmoptionNoArg, (XPointer)"off"}, -{"+fbb", "*freeBoldBox", XrmoptionNoArg, (XPointer)"on"}, -{"-fbx", "*forceBoxChars", XrmoptionNoArg, (XPointer)"off"}, -{"+fbx", "*forceBoxChars", XrmoptionNoArg, (XPointer)"on"}, -#ifndef NO_ACTIVE_ICON -{"-fi", "*iconFont", XrmoptionSepArg, (XPointer) NULL}, -#endif /* NO_ACTIVE_ICON */ -#if OPT_RENDERFONT -{"-fa", "*faceName", XrmoptionSepArg, (XPointer) NULL}, -{"-fd", "*faceNameDoublesize", XrmoptionSepArg, (XPointer) NULL}, -{"-fs", "*faceSize", XrmoptionSepArg, (XPointer) NULL}, -#endif -#if OPT_WIDE_CHARS -{"-fw", "*wideFont", XrmoptionSepArg, (XPointer) NULL}, -{"-fwb", "*wideBoldFont", XrmoptionSepArg, (XPointer) NULL}, -#endif -#if OPT_INPUT_METHOD -{"-fx", "*ximFont", XrmoptionSepArg, (XPointer) NULL}, -#endif -#if OPT_HIGHLIGHT_COLOR -{"-hc", "*highlightColor", XrmoptionSepArg, (XPointer) NULL}, -{"-hm", "*highlightColorMode", XrmoptionNoArg, (XPointer) "on"}, -{"+hm", "*highlightColorMode", XrmoptionNoArg, (XPointer) "off"}, -{"-selfg", "*highlightTextColor", XrmoptionSepArg, (XPointer) NULL}, -{"-selbg", "*highlightColor", XrmoptionSepArg, (XPointer) NULL}, -#endif -#if OPT_HP_FUNC_KEYS -{"-hf", "*hpFunctionKeys",XrmoptionNoArg, (XPointer) "on"}, -{"+hf", "*hpFunctionKeys",XrmoptionNoArg, (XPointer) "off"}, -#endif -{"-hold", "*hold", XrmoptionNoArg, (XPointer) "on"}, -{"+hold", "*hold", XrmoptionNoArg, (XPointer) "off"}, -#if OPT_INITIAL_ERASE -{"-ie", "*ptyInitialErase", XrmoptionNoArg, (XPointer) "on"}, -{"+ie", "*ptyInitialErase", XrmoptionNoArg, (XPointer) "off"}, -#endif -{"-j", "*jumpScroll", XrmoptionNoArg, (XPointer) "on"}, -{"+j", "*jumpScroll", XrmoptionNoArg, (XPointer) "off"}, -#if OPT_C1_PRINT -{"-k8", "*allowC1Printable", XrmoptionNoArg, (XPointer) "on"}, -{"+k8", "*allowC1Printable", XrmoptionNoArg, (XPointer) "off"}, -#endif -{"-kt", "*keyboardType", XrmoptionSepArg, (XPointer) NULL}, -{"+kt", "*keyboardType", XrmoptionSepArg, (XPointer) NULL}, -/* parse logging options anyway for compatibility */ -{"-l", "*logging", XrmoptionNoArg, (XPointer) "on"}, -{"+l", "*logging", XrmoptionNoArg, (XPointer) "off"}, -{"-lf", "*logFile", XrmoptionSepArg, (XPointer) NULL}, -{"-ls", "*loginShell", XrmoptionNoArg, (XPointer) "on"}, -{"+ls", "*loginShell", XrmoptionNoArg, (XPointer) "off"}, -{"-mb", "*marginBell", XrmoptionNoArg, (XPointer) "on"}, -{"+mb", "*marginBell", XrmoptionNoArg, (XPointer) "off"}, -{"-mc", "*multiClickTime", XrmoptionSepArg, (XPointer) NULL}, -{"-mesg", "*messages", XrmoptionNoArg, (XPointer) "off"}, -{"+mesg", "*messages", XrmoptionNoArg, (XPointer) "on"}, -{"-ms", "*pointerColor",XrmoptionSepArg, (XPointer) NULL}, -{"-nb", "*nMarginBell", XrmoptionSepArg, (XPointer) NULL}, -{"-nul", "*underLine", XrmoptionNoArg, (XPointer) "off"}, -{"+nul", "*underLine", XrmoptionNoArg, (XPointer) "on"}, -{"-pc", "*boldColors", XrmoptionNoArg, (XPointer) "on"}, -{"+pc", "*boldColors", XrmoptionNoArg, (XPointer) "off"}, -{"-rw", "*reverseWrap", XrmoptionNoArg, (XPointer) "on"}, -{"+rw", "*reverseWrap", XrmoptionNoArg, (XPointer) "off"}, -{"-s", "*multiScroll", XrmoptionNoArg, (XPointer) "on"}, -{"+s", "*multiScroll", XrmoptionNoArg, (XPointer) "off"}, -{"-sb", "*scrollBar", XrmoptionNoArg, (XPointer) "on"}, -{"+sb", "*scrollBar", XrmoptionNoArg, (XPointer) "off"}, -#ifdef SCROLLBAR_RIGHT -{"-leftbar", "*rightScrollBar", XrmoptionNoArg, (XPointer) "off"}, -{"-rightbar", "*rightScrollBar", XrmoptionNoArg, (XPointer) "on"}, -#endif -{"-rvc", "*colorRVMode", XrmoptionNoArg, (XPointer) "off"}, -{"+rvc", "*colorRVMode", XrmoptionNoArg, (XPointer) "on"}, -{"-sf", "*sunFunctionKeys", XrmoptionNoArg, (XPointer) "on"}, -{"+sf", "*sunFunctionKeys", XrmoptionNoArg, (XPointer) "off"}, -{"-si", "*scrollTtyOutput", XrmoptionNoArg, (XPointer) "off"}, -{"+si", "*scrollTtyOutput", XrmoptionNoArg, (XPointer) "on"}, -{"-sk", "*scrollKey", XrmoptionNoArg, (XPointer) "on"}, -{"+sk", "*scrollKey", XrmoptionNoArg, (XPointer) "off"}, -{"-sl", "*saveLines", XrmoptionSepArg, (XPointer) NULL}, -#if OPT_SUNPC_KBD -{"-sp", "*sunKeyboard", XrmoptionNoArg, (XPointer) "on"}, -{"+sp", "*sunKeyboard", XrmoptionNoArg, (XPointer) "off"}, -#endif -#if OPT_TEK4014 -{"-t", "*tekStartup", XrmoptionNoArg, (XPointer) "on"}, -{"+t", "*tekStartup", XrmoptionNoArg, (XPointer) "off"}, -#endif -{"-ti", "*decTerminalID",XrmoptionSepArg, (XPointer) NULL}, -{"-tm", "*ttyModes", XrmoptionSepArg, (XPointer) NULL}, -{"-tn", "*termName", XrmoptionSepArg, (XPointer) NULL}, -#if OPT_WIDE_CHARS -{"-u8", "*utf8", XrmoptionNoArg, (XPointer) "2"}, -{"+u8", "*utf8", XrmoptionNoArg, (XPointer) "0"}, -#endif -#if OPT_LUIT_PROG -{"-lc", "*locale", XrmoptionNoArg, (XPointer) "on"}, -{"+lc", "*locale", XrmoptionNoArg, (XPointer) "off"}, -{"-lcc", "*localeFilter",XrmoptionSepArg, (XPointer) NULL}, -{"-en", "*locale", XrmoptionSepArg, (XPointer) NULL}, -#endif -{"-uc", "*cursorUnderLine", XrmoptionNoArg, (XPointer) "on"}, -{"+uc", "*cursorUnderLine", XrmoptionNoArg, (XPointer) "off"}, -{"-ulc", "*colorULMode", XrmoptionNoArg, (XPointer) "off"}, -{"+ulc", "*colorULMode", XrmoptionNoArg, (XPointer) "on"}, -{"-ulit", "*italicULMode", XrmoptionNoArg, (XPointer) "off"}, -{"+ulit", "*italicULMode", XrmoptionNoArg, (XPointer) "on"}, -{"-ut", "*utmpInhibit", XrmoptionNoArg, (XPointer) "on"}, -{"+ut", "*utmpInhibit", XrmoptionNoArg, (XPointer) "off"}, -{"-im", "*useInsertMode", XrmoptionNoArg, (XPointer) "on"}, -{"+im", "*useInsertMode", XrmoptionNoArg, (XPointer) "off"}, -{"-vb", "*visualBell", XrmoptionNoArg, (XPointer) "on"}, -{"+vb", "*visualBell", XrmoptionNoArg, (XPointer) "off"}, -{"-pob", "*popOnBell", XrmoptionNoArg, (XPointer) "on"}, -{"+pob", "*popOnBell", XrmoptionNoArg, (XPointer) "off"}, -#if OPT_WIDE_CHARS -{"-wc", "*wideChars", XrmoptionNoArg, (XPointer) "on"}, -{"+wc", "*wideChars", XrmoptionNoArg, (XPointer) "off"}, -{"-mk_width", "*mkWidth", XrmoptionNoArg, (XPointer) "on"}, -{"+mk_width", "*mkWidth", XrmoptionNoArg, (XPointer) "off"}, -{"-cjk_width", "*cjkWidth", XrmoptionNoArg, (XPointer) "on"}, -{"+cjk_width", "*cjkWidth", XrmoptionNoArg, (XPointer) "off"}, -#endif -{"-wf", "*waitForMap", XrmoptionNoArg, (XPointer) "on"}, -{"+wf", "*waitForMap", XrmoptionNoArg, (XPointer) "off"}, -#if OPT_ZICONBEEP -{"-ziconbeep", "*zIconBeep", XrmoptionSepArg, (XPointer) NULL}, -#endif -#if OPT_SAME_NAME -{"-samename", "*sameName", XrmoptionNoArg, (XPointer) "on"}, -{"+samename", "*sameName", XrmoptionNoArg, (XPointer) "off"}, -#endif -#if OPT_SESSION_MGT -{"-sm", "*sessionMgt", XrmoptionNoArg, (XPointer) "on"}, -{"+sm", "*sessionMgt", XrmoptionNoArg, (XPointer) "off"}, -#endif -#if OPT_TOOLBAR -{"-tb", "*"XtNtoolBar, XrmoptionNoArg, (XPointer) "on"}, -{"+tb", "*"XtNtoolBar, XrmoptionNoArg, (XPointer) "off"}, -#endif -#if OPT_MAXIMIZE -{"-maximized", "*maximized", XrmoptionNoArg, (XPointer) "on"}, -{"+maximized", "*maximized", XrmoptionNoArg, (XPointer) "off"}, -{"-fullscreen", "*fullscreen", XrmoptionNoArg, (XPointer) "on"}, -{"+fullscreen", "*fullscreen", XrmoptionNoArg, (XPointer) "off"}, -#endif -/* options that we process ourselves */ -{"-help", NULL, XrmoptionSkipNArgs, (XPointer) NULL}, -{"-version", NULL, XrmoptionSkipNArgs, (XPointer) NULL}, -{"-class", NULL, XrmoptionSkipArg, (XPointer) NULL}, -{"-e", NULL, XrmoptionSkipLine, (XPointer) NULL}, -{"-into", NULL, XrmoptionSkipArg, (XPointer) NULL}, -/* bogus old compatibility stuff for which there are - standard XtOpenApplication options now */ -{"%", "*tekGeometry", XrmoptionStickyArg, (XPointer) NULL}, -{"#", ".iconGeometry",XrmoptionStickyArg, (XPointer) NULL}, -{"-T", ".title", XrmoptionSepArg, (XPointer) NULL}, -{"-n", "*iconName", XrmoptionSepArg, (XPointer) NULL}, -{"-r", "*reverseVideo",XrmoptionNoArg, (XPointer) "on"}, -{"+r", "*reverseVideo",XrmoptionNoArg, (XPointer) "off"}, -{"-rv", "*reverseVideo",XrmoptionNoArg, (XPointer) "on"}, -{"+rv", "*reverseVideo",XrmoptionNoArg, (XPointer) "off"}, -{"-w", ".borderWidth", XrmoptionSepArg, (XPointer) NULL}, -}; - -static OptionHelp xtermOptions[] = { -{ "-version", "print the version number" }, -{ "-help", "print out this message" }, -{ "-display displayname", "X server to contact" }, -{ "-geometry geom", "size (in characters) and position" }, -{ "-/+rv", "turn on/off reverse video" }, -{ "-bg color", "background color" }, -{ "-fg color", "foreground color" }, -{ "-bd color", "border color" }, -{ "-bw number", "border width in pixels" }, -{ "-fn fontname", "normal text font" }, -{ "-fb fontname", "bold text font" }, -{ "-/+fbb", "turn on/off normal/bold font comparison inhibit"}, -{ "-/+fbx", "turn off/on linedrawing characters"}, -#if OPT_RENDERFONT -{ "-fa pattern", "FreeType font-selection pattern" }, -{ "-fd pattern", "FreeType Doublesize font-selection pattern" }, -{ "-fs size", "FreeType font-size" }, -#endif -#if OPT_WIDE_CHARS -{ "-fw fontname", "doublewidth text font" }, -{ "-fwb fontname", "doublewidth bold text font" }, -#endif -#if OPT_INPUT_METHOD -{ "-fx fontname", "XIM fontset" }, -#endif -{ "-iconic", "start iconic" }, -{ "-name string", "client instance, icon, and title strings" }, -{ "-class string", "class string (XTerm)" }, -{ "-title string", "title string" }, -{ "-xrm resourcestring", "additional resource specifications" }, -{ "-/+132", "turn on/off 80/132 column switching" }, -{ "-/+ah", "turn on/off always highlight" }, -#ifndef NO_ACTIVE_ICON -{ "-/+ai", "turn off/on active icon" }, -{ "-fi fontname", "icon font for active icon" }, -#endif /* NO_ACTIVE_ICON */ -{ "-b number", "internal border in pixels" }, -{ "-/+bc", "turn on/off text cursor blinking" }, -{ "-bcf milliseconds", "time text cursor is off when blinking"}, -{ "-bcn milliseconds", "time text cursor is on when blinking"}, -{ "-/+bdc", "turn off/on display of bold as color"}, -{ "-/+cb", "turn on/off cut-to-beginning-of-line inhibit" }, -{ "-cc classrange", "specify additional character classes" }, -{ "-/+cm", "turn off/on ANSI color mode" }, -{ "-/+cn", "turn on/off cut newline inhibit" }, -{ "-cr color", "text cursor color" }, -{ "-/+cu", "turn on/off curses emulation" }, -{ "-/+dc", "turn off/on dynamic color selection" }, -#if OPT_HIGHLIGHT_COLOR -{ "-/+hm", "turn on/off selection-color override" }, -{ "-selbg color", "selection background color" }, -{ "-selfg color", "selection foreground color" }, -#endif -#if OPT_HP_FUNC_KEYS -{ "-/+hf", "turn on/off HP Function Key escape codes" }, -#endif -{ "-/+hold", "turn on/off logic that retains window after exit" }, -#if OPT_INITIAL_ERASE -{ "-/+ie", "turn on/off initialization of 'erase' from pty" }, -#endif -{ "-/+im", "use insert mode for TERMCAP" }, -{ "-/+j", "turn on/off jump scroll" }, -#if OPT_C1_PRINT -{ "-/+k8", "turn on/off C1-printable classification"}, -#endif -{ "-kt keyboardtype", "set keyboard type:" KEYBOARD_TYPES }, -#ifdef ALLOWLOGGING -{ "-/+l", "turn on/off logging" }, -{ "-lf filename", "logging filename" }, -#else -{ "-/+l", "turn on/off logging (not supported)" }, -{ "-lf filename", "logging filename (not supported)" }, -#endif -{ "-/+ls", "turn on/off login shell" }, -{ "-/+mb", "turn on/off margin bell" }, -{ "-mc milliseconds", "multiclick time in milliseconds" }, -{ "-/+mesg", "forbid/allow messages" }, -{ "-ms color", "pointer color" }, -{ "-nb number", "margin bell in characters from right end" }, -{ "-/+nul", "turn off/on display of underlining" }, -{ "-/+aw", "turn on/off auto wraparound" }, -{ "-/+pc", "turn on/off PC-style bold colors" }, -{ "-/+rw", "turn on/off reverse wraparound" }, -{ "-/+s", "turn on/off multiscroll" }, -{ "-/+sb", "turn on/off scrollbar" }, -#ifdef SCROLLBAR_RIGHT -{ "-rightbar", "force scrollbar right (default left)" }, -{ "-leftbar", "force scrollbar left" }, -#endif -{ "-/+rvc", "turn off/on display of reverse as color" }, -{ "-/+sf", "turn on/off Sun Function Key escape codes" }, -{ "-/+si", "turn on/off scroll-on-tty-output inhibit" }, -{ "-/+sk", "turn on/off scroll-on-keypress" }, -{ "-sl number", "number of scrolled lines to save" }, -#if OPT_SUNPC_KBD -{ "-/+sp", "turn on/off Sun/PC Function/Keypad mapping" }, -#endif -#if OPT_TEK4014 -{ "-/+t", "turn on/off Tek emulation window" }, -#endif -#if OPT_TOOLBAR -{ "-/+tb", "turn on/off toolbar" }, -#endif -{ "-ti termid", "terminal identifier" }, -{ "-tm string", "terminal mode keywords and characters" }, -{ "-tn name", "TERM environment variable name" }, -#if OPT_WIDE_CHARS -{ "-/+u8", "turn on/off UTF-8 mode (implies wide-characters)" }, -#endif -#if OPT_LUIT_PROG -{ "-/+lc", "turn on/off locale mode using luit" }, -{ "-lcc path", "filename of locale converter (" DEFLOCALEFILTER ")" }, -#endif -{ "-/+uc", "turn on/off underline cursor" }, -{ "-/+ulc", "turn off/on display of underline as color" }, -{ "-/+ut", "turn on/off utmp inhibit (not supported)" }, -{ "-/+ulit", "turn off/on display of underline as italics" }, -{ "-/+vb", "turn on/off visual bell" }, -{ "-/+pob", "turn on/off pop on bell" }, -#if OPT_WIDE_CHARS -{ "-/+wc", "turn on/off wide-character mode" }, -{ "-/+mk_width", "turn on/off simple width convention" }, -{ "-/+cjk_width", "turn on/off legacy CJK width convention" }, -#endif -{ "-/+wf", "turn on/off wait for map before command exec" }, -{ "-e command args ...", "command to execute" }, -#if OPT_TEK4014 -{ "%geom", "Tek window geometry" }, -#endif -{ "#geom", "icon window geometry" }, -{ "-T string", "title name for window" }, -{ "-n string", "icon name for window" }, -{ "-C", "intercept console messages" }, -{ "-Sccn", "slave mode on \"ttycc\", file descriptor \"n\"" }, -{ "-into windowId", "use the window id given to -into as the parent window rather than the default root window" }, -#if OPT_ZICONBEEP -{ "-ziconbeep percent", "beep and flag icon of window having hidden output" }, -#endif -#if OPT_SAME_NAME -{ "-/+samename", "turn on/off the no-flicker option for title and icon name" }, -#endif -#if OPT_SESSION_MGT -{ "-/+sm", "turn on/off the session-management support" }, -#endif -#if OPT_MAXIMIZE -{"-/+maximized", "turn on/off maxmize on startup" }, -#endif -{ NULL, NULL }}; -/* *INDENT-ON* */ - -#ifdef DBG_CONSOLE -FILE *confd; - -static void -closecons(void) -{ - if (confs != 0) { - fclose(confd); - confd = 0; - } -} -static void -opencons(void) -{ - closecons(); - if ((confd = fopen("/dev/console$", "w")) < 0) { - fputs("!!! Cannot open console device.\n", - stderr); - exit(1); - } -} -#else -#define opencons() /* nothing */ -#define closecons() /* nothing */ -#endif - -static const char *message[] = -{ - "Fonts should be fixed width and, if both normal and bold are specified, should", - "have the same size. If only a normal font is specified, it will be used for", - "both normal and bold text (by doing overstriking). The -e option, if given,", - "must appear at the end of the command line, otherwise the user's default shell", - "will be started. Options that start with a plus sign (+) restore the default.", - NULL}; - -/* - * Decode a key-definition. This combines the termcap and ttyModes, for - * comparison. Note that octal escapes in ttyModes are done by the normal - * resource translation. Also, ttyModes allows '^-' as a synonym for disabled. - */ -static int -decode_keyvalue(char **ptr, int termcap) -{ - char *string = *ptr; - int value = -1; - - TRACE(("decode_keyvalue '%s'\n", string)); - if (*string == '^') { - switch (*++string) { - case '?': - value = A2E(ANSI_DEL); - break; - case '-': - if (!termcap) { - errno = 0; -#if defined(_POSIX_VDISABLE) && defined(HAVE_UNISTD_H) - value = _POSIX_VDISABLE; -#endif -#if defined(_PC_VDISABLE) - if (value == -1) { - value = (int) fpathconf(0, _PC_VDISABLE); - if (value == -1) { - if (errno != 0) - break; /* skip this (error) */ - value = 0377; - } - } -#elif defined(VDISABLE) - if (value == -1) - value = VDISABLE; -#endif - break; - } - /* FALLTHRU */ - default: - value = CONTROL(*string); - break; - } - ++string; - } else if (termcap && (*string == '\\')) { - char *d; - int temp = (int) strtol(string + 1, &d, 8); - if (temp > 0 && d != string) { - value = temp; - string = d; - } - } else { - value = CharOf(*string); - ++string; - } - *ptr = string; - TRACE(("...decode_keyvalue %#x\n", value)); - return value; -} - -static int -abbrev(const char *tst, const char *cmp, size_t need) -{ - size_t len = strlen(tst); - return ((len >= need) && (!strncmp(tst, cmp, len))); -} - -static void -Syntax(char *badOption) -{ - OptionHelp *opt; - OptionHelp *list = sortedOpts(xtermOptions, optionDescList, XtNumber(optionDescList)); - int col; - - xtermWarning("bad command line option \"%s\"\r\n\n", badOption); - - fprintf(stderr, "usage: %s", ProgramName); - col = 8 + (int) strlen(ProgramName); - for (opt = list; opt->opt; opt++) { - int len = 3 + (int) strlen(opt->opt); /* space [ string ] */ - if (col + len > 79) { - fprintf(stderr, "\r\n "); /* 3 spaces */ - col = 3; - } - fprintf(stderr, " [%s]", opt->opt); - col += len; - } - - fprintf(stderr, "\r\n\nType %s -help for a full description.\r\n\n", - ProgramName); - exit(1); -} - -static void -Version(void) -{ - printf("%s\n", xtermVersion()); - fflush(stdout); -} - -static void -Help(void) -{ - OptionHelp *opt; - OptionHelp *list = sortedOpts(xtermOptions, optionDescList, XtNumber(optionDescList)); - const char **cpp; - - printf("%s usage:\n %s [-options ...] [-e command args]\n\n", - xtermVersion(), ProgramName); - printf("where options include:\n"); - for (opt = list; opt->opt; opt++) { - printf(" %-28s %s\n", opt->opt, opt->desc); - } - - putchar('\n'); - for (cpp = message; *cpp; cpp++) - puts(*cpp); - putchar('\n'); - fflush(stdout); -} - -/* ARGSUSED */ -static Boolean -ConvertConsoleSelection(Widget w GCC_UNUSED, - Atom * selection GCC_UNUSED, - Atom * target GCC_UNUSED, - Atom * type GCC_UNUSED, - XtPointer *value GCC_UNUSED, - unsigned long *length GCC_UNUSED, - int *format GCC_UNUSED) -{ - /* we don't save console output, so can't offer it */ - return False; -} - -#if OPT_SESSION_MGT -static void -die_callback(Widget w GCC_UNUSED, - XtPointer client_data GCC_UNUSED, - XtPointer call_data GCC_UNUSED) -{ - Cleanup(0); -} - -static void -save_callback(Widget w GCC_UNUSED, - XtPointer client_data GCC_UNUSED, - XtPointer call_data) -{ - XtCheckpointToken token = (XtCheckpointToken) call_data; - /* we have nothing to save */ - token->save_success = True; -} - -static void -icewatch(IceConn iceConn, - IcePointer clientData GCC_UNUSED, - Bool opening, - IcePointer * watchData GCC_UNUSED) -{ - if (opening) { - ice_fd = IceConnectionNumber(iceConn); - TRACE(("got IceConnectionNumber %d\n", ice_fd)); - } else { - ice_fd = -1; - TRACE(("reset IceConnectionNumber\n")); - } -} - -#endif /* OPT_SESSION_MGT */ - -/* - * DeleteWindow(): Action proc to implement ICCCM delete_window. - */ -/* ARGSUSED */ -static void -DeleteWindow(Widget w, - XEvent * event GCC_UNUSED, - String * params GCC_UNUSED, - Cardinal *num_params GCC_UNUSED) -{ -#if OPT_TEK4014 - if (w == toplevel) { - if (TEK4014_SHOWN(term)) - hide_vt_window(); - else - do_hangup(w, (XtPointer) 0, (XtPointer) 0); - } else if (TScreenOf(term)->Vshow) - hide_tek_window(); - else -#endif - do_hangup(w, (XtPointer) 0, (XtPointer) 0); -} - -/* ARGSUSED */ -static void -KeyboardMapping(Widget w GCC_UNUSED, - XEvent * event, - String * params GCC_UNUSED, - Cardinal *num_params GCC_UNUSED) -{ - switch (event->type) { - case MappingNotify: - XRefreshKeyboardMapping(&event->xmapping); - break; - } -} - -static XtActionsRec actionProcs[] = -{ - {"DeleteWindow", DeleteWindow}, - {"KeyboardMapping", KeyboardMapping}, -}; - -char **gblenvp; - -int -main(int argc, char **argv ENVP_ARG) -{ - Widget form_top, menu_top; - Dimension menu_high; - TScreen *screen; - int mode; - char *my_class = DEFCLASS; - Window winToEmbedInto = None; -#if OPT_COLOR_RES - Bool reversed = False; -#endif - - ProgramName = argv[0]; - - save_ruid = getuid(); - save_rgid = getgid(); - - /* Do these first, since we may not be able to open the display */ - TRACE_OPTS(xtermOptions, optionDescList, XtNumber(optionDescList)); - TRACE_ARGV("Before XtOpenApplication", argv); - if (argc > 1) { - int n; - size_t unique = 2; - Bool quit = False; - - for (n = 1; n < argc; n++) { - TRACE(("parsing %s\n", argv[n])); - if (abbrev(argv[n], "-version", unique)) { - Version(); - quit = True; - } else if (abbrev(argv[n], "-help", unique)) { - Help(); - quit = True; - } else if (abbrev(argv[n], "-class", (size_t) 3)) { - if ((my_class = argv[++n]) == 0) { - Help(); - quit = True; - } - } - } - if (quit) - exit(0); - } - - /* XXX: for some obscure reason EMX seems to lose the value of - * the environ variable, don't understand why, so save it recently - */ - gblenvp = envp; - -#ifdef I18N - setlocale(LC_ALL, NULL); -#endif - - opencons(); - - ttydev = TypeMallocN(char, PTMS_BUFSZ); - ptydev = TypeMallocN(char, PTMS_BUFSZ); - if (!ttydev || !ptydev) { - xtermWarning("unable to allocate memory for ttydev or ptydev\n"); - exit(1); - } - strcpy(ttydev, TTYDEV); - strcpy(ptydev, PTYDEV); - - /* Initialization is done here rather than above in order - * to prevent any assumptions about the order of the contents - * of the various terminal structures (which may change from - * implementation to implementation). - */ - d_tio.c_iflag = ICRNL | IXON; - d_tio.c_oflag = OPOST | ONLCR | TAB3; - d_tio.c_cflag = B38400 | CS8 | CREAD | PARENB | HUPCL; - d_tio.c_lflag = ISIG | ICANON | ECHO | ECHOE | ECHOK; - d_tio.c_line = 0; - d_tio.c_cc[VINTR] = CONTROL('C'); /* '^C' */ - d_tio.c_cc[VERASE] = ANSI_DEL; /* DEL */ - d_tio.c_cc[VKILL] = CONTROL('U'); /* '^U' */ - d_tio.c_cc[VQUIT] = CQUIT; /* '^\' */ - d_tio.c_cc[VEOF] = CEOF; /* '^D' */ - d_tio.c_cc[VEOL] = CEOL; /* '^@' */ - - XtSetErrorHandler(xt_error); -#if OPT_SESSION_MGT - toplevel = XtOpenApplication(&app_con, my_class, - optionDescList, - XtNumber(optionDescList), - &argc, argv, fallback_resources, - sessionShellWidgetClass, - NULL, 0); - IceAddConnectionWatch(icewatch, NULL); -#else - toplevel = XtAppInitialize(&app_con, my_class, - optionDescList, - XtNumber(optionDescList), - &argc, argv, fallback_resources, - NULL, 0); -#endif /* OPT_SESSION_MGT */ - XtSetErrorHandler((XtErrorHandler) 0); - - XtGetApplicationResources(toplevel, (XtPointer) &resource, - application_resources, - XtNumber(application_resources), NULL, 0); - TRACE_XRES(); -#if OPT_MAXIMIZE - resource.fullscreen = extendedBoolean(resource.fullscreen_s, - tblFullscreen, - XtNumber(tblFullscreen)); -#endif - - /* - * ICCCM delete_window. - */ - XtAppAddActions(app_con, actionProcs, XtNumber(actionProcs)); - - /* - * fill in terminal modes - */ - if (resource.tty_modes) { - int n = parse_tty_modes(resource.tty_modes, ttymodelist); - if (n < 0) { - xtermWarning("bad tty modes \"%s\"\n", resource.tty_modes); - } else if (n > 0) { - override_tty_modes = True; - } - } -#if OPT_ZICONBEEP - if (resource.zIconBeep > 100 || resource.zIconBeep < -100) { - resource.zIconBeep = 0; /* was 100, but I prefer to defaulting off. */ - xtermWarning("a number between -100 and 100 is required for zIconBeep. 0 used by default\n"); - } -#endif /* OPT_ZICONBEEP */ - hold_screen = resource.hold_screen ? 1 : 0; - if (resource.icon_geometry != NULL) { - int scr, junk; - int ix, iy; - Arg args[2]; - - for (scr = 0; /* yyuucchh */ - XtScreen(toplevel) != ScreenOfDisplay(XtDisplay(toplevel), scr); - scr++) ; - - args[0].name = XtNiconX; - args[1].name = XtNiconY; - XGeometry(XtDisplay(toplevel), scr, resource.icon_geometry, "", - 0, 0, 0, 0, 0, &ix, &iy, &junk, &junk); - args[0].value = (XtArgVal) ix; - args[1].value = (XtArgVal) iy; - XtSetValues(toplevel, args, 2); - } - - XtSetValues(toplevel, ourTopLevelShellArgs, - number_ourTopLevelShellArgs); - -#if OPT_WIDE_CHARS - /* seems as good a place as any */ - init_classtab(); -#endif - - /* Parse the rest of the command line */ - TRACE_ARGV("After XtOpenApplication", argv); - for (argc--, argv++; argc > 0; argc--, argv++) { - if (**argv != '-') - Syntax(*argv); - - TRACE(("parsing %s\n", argv[0])); - switch (argv[0][1]) { - case 'h': /* -help */ - Help(); - exit(0); - case 'v': /* -version */ - Version(); - exit(0); - case 'C': - { - struct stat sbuf; - - /* Must be owner and have read/write permission. - xdm cooperates to give the console the right user. */ - if (!stat("/dev/console", &sbuf) && - (sbuf.st_uid == save_ruid) && - !access("/dev/console", R_OK | W_OK)) { - Console = True; - } else - Console = False; - } - continue; - case 'S': - if (sscanf(*argv + 2, "%c%c%d", passedPty, passedPty + 1, - &am_slave) != 3) - Syntax(*argv); - continue; -#ifdef DEBUG - case 'D': - debug = True; - continue; -#endif /* DEBUG */ - case 'c': /* -class param */ - if (strcmp(argv[0] + 1, "class") == 0) - argc--, argv++; - else - Syntax(*argv); - continue; - case 'e': - if (argc <= 1) - Syntax(*argv); - command_to_exec = ++argv; - break; - case 'i': - if (argc <= 1) { - Syntax(*argv); - } else { - char *endPtr; - --argc; - ++argv; - winToEmbedInto = (Window) strtol(argv[0], &endPtr, 10); - } - continue; - - default: - Syntax(*argv); - } - break; - } - - SetupMenus(toplevel, &form_top, &menu_top, &menu_high); - - term = (XtermWidget) XtVaCreateManagedWidget("vt100", xtermWidgetClass, - form_top, -#if OPT_TOOLBAR - XtNmenuBar, menu_top, - XtNresizable, True, - XtNfromVert, menu_top, - XtNleft, XawChainLeft, - XtNright, XawChainRight, - XtNtop, XawChainTop, - XtNbottom, XawChainBottom, - XtNmenuHeight, menu_high, -#endif - (XtPointer) 0); - decode_keyboard_type(term, &resource); - - screen = TScreenOf(term); - screen->inhibit = 0; - -#ifdef ALLOWLOGGING - if (term->misc.logInhibit) - screen->inhibit |= I_LOG; -#endif - if (term->misc.signalInhibit) - screen->inhibit |= I_SIGNAL; -#if OPT_TEK4014 - if (term->misc.tekInhibit) - screen->inhibit |= I_TEK; -#endif - - /* - * We might start by showing the tek4014 window. - */ -#if OPT_TEK4014 - if (screen->inhibit & I_TEK) - TEK4014_ACTIVE(term) = False; - - if (TEK4014_ACTIVE(term) && !TekInit()) - SysError(ERROR_INIT); -#endif - - /* - * Start the toolbar at this point, after the first window has been setup. - */ -#if OPT_TOOLBAR - ShowToolbar(resource.toolBar); -#endif - -#if OPT_SESSION_MGT - if (resource.sessionMgt) { - TRACE(("Enabling session-management callbacks\n")); - XtAddCallback(toplevel, XtNdieCallback, die_callback, NULL); - XtAddCallback(toplevel, XtNsaveCallback, save_callback, NULL); - } -#endif - - /* - * Set title and icon name if not specified - */ - if (command_to_exec) { - Arg args[2]; - - if (!resource.title) { - if (command_to_exec) { - resource.title = x_basename(command_to_exec[0]); - } /* else not reached */ - } - - if (!resource.icon_name) - resource.icon_name = resource.title; - XtSetArg(args[0], XtNtitle, resource.title); - XtSetArg(args[1], XtNiconName, resource.icon_name); - - TRACE(("setting:\n\ttitle \"%s\"\n\ticon \"%s\"\n\tbased on command \"%s\"\n", - resource.title, - resource.icon_name, - *command_to_exec)); - - XtSetValues(toplevel, args, 2); - } -#if OPT_LUIT_PROG - if (term->misc.callfilter) { - int u = (term->misc.use_encoding ? 2 : 0); - if (command_to_exec) { - int n; - char **c; - for (n = 0, c = command_to_exec; *c; n++, c++) ; - c = TypeMallocN(char *, (unsigned) (n + 3 + u)); - if (c == NULL) - SysError(ERROR_LUMALLOC); - memcpy(c + 2 + u, command_to_exec, (unsigned) (n + 1) * sizeof(char *)); - c[0] = term->misc.localefilter; - if (u) { - c[1] = "-encoding"; - c[2] = term->misc.locale_str; - } - c[1 + u] = "--"; - command_to_exec_with_luit = c; - } else { - static char *luit[6]; - luit[0] = term->misc.localefilter; - if (u) { - luit[1] = "-encoding"; - luit[2] = term->misc.locale_str; - luit[3] = NULL; - } else - luit[1] = NULL; - command_to_exec_with_luit = luit; - } - } -#endif - -#ifdef DEBUG - { - /* Set up stderr properly. Opening this log file cannot be - done securely by a privileged xterm process (although we try), - so the debug feature is disabled by default. */ - char dbglogfile[TIMESTAMP_LEN + 20]; - int i = -1; - if (debug) { - timestamp_filename(dbglogfile, "xterm.debug.log."); - if (creat_as(save_ruid, save_rgid, False, dbglogfile, 0600) > 0) { - i = open(dbglogfile, O_WRONLY | O_TRUNC); - } - } - if (i >= 0) { - dup2(i, 2); - - /* mark this file as close on exec */ - (void) fcntl(i, F_SETFD, 1); - } - } -#endif /* DEBUG */ - - spawnXTerm(term); - - /* Child process is out there, let's catch its termination */ - (void) signal(SIGCHLD, reapchild); - - /* Realize procs have now been executed */ - - if (am_slave >= 0) { /* Write window id so master end can read and use */ - char buf[80]; - - buf[0] = '\0'; - sprintf(buf, "%lx\n", XtWindow(SHELL_OF(CURRENT_EMU()))); - IGNORE_RC(write(screen->respond, buf, strlen(buf))); - } - - if (0 > (mode = fcntl(screen->respond, F_GETFL, 0))) - SysError(ERROR_F_GETFL); - mode |= O_NDELAY; - - if (fcntl(screen->respond, F_SETFL, mode)) - SysError(ERROR_F_SETFL); - - FD_ZERO(&pty_mask); - FD_ZERO(&X_mask); - FD_ZERO(&Select_mask); - FD_SET(screen->respond, &pty_mask); - FD_SET(ConnectionNumber(screen->display), &X_mask); - FD_SET(screen->respond, &Select_mask); - FD_SET(ConnectionNumber(screen->display), &Select_mask); - max_plus1 = ((screen->respond < ConnectionNumber(screen->display)) - ? (1 + ConnectionNumber(screen->display)) - : (1 + screen->respond)); - -#ifdef DEBUG - if (debug) - printf("debugging on\n"); -#endif /* DEBUG */ - XSetErrorHandler(xerror); - XSetIOErrorHandler(xioerror); - - initPtyData(&VTbuffer); -#ifdef ALLOWLOGGING - if (term->misc.log_on) { - StartLog(term); - } -#endif - - TRACE(("checking winToEmbedInto %#lx\n", winToEmbedInto)); - if (winToEmbedInto != None) { - XtRealizeWidget(toplevel); - /* - * This should probably query the tree or check the attributes of - * winToEmbedInto in order to verify that it exists, but I'm still not - * certain what is the best way to do it -GPS - */ - TRACE(("...reparenting toplevel %#lx into %#lx\n", - XtWindow(toplevel), - winToEmbedInto)); - XReparentWindow(XtDisplay(toplevel), - XtWindow(toplevel), - winToEmbedInto, 0, 0); - } -#if OPT_COLOR_RES - TRACE(("checking reverseVideo before rv %s fg %s, bg %s\n", - term->misc.re_verse0 ? "reverse" : "normal", - NonNull(TScreenOf(term)->Tcolors[TEXT_FG].resource), - NonNull(TScreenOf(term)->Tcolors[TEXT_BG].resource))); - - if (term->misc.re_verse0) { - if (isDefaultForeground(TScreenOf(term)->Tcolors[TEXT_FG].resource) - && isDefaultBackground(TScreenOf(term)->Tcolors[TEXT_BG].resource)) { - TScreenOf(term)->Tcolors[TEXT_FG].resource = x_strdup(XtDefaultBackground); - TScreenOf(term)->Tcolors[TEXT_BG].resource = x_strdup(XtDefaultForeground); - } else { - ReverseVideo(term); - } - term->misc.re_verse = True; - update_reversevideo(); - TRACE(("updated reverseVideo after rv %s fg %s, bg %s\n", - term->misc.re_verse ? "reverse" : "normal", - NonNull(TScreenOf(term)->Tcolors[TEXT_FG].resource), - NonNull(TScreenOf(term)->Tcolors[TEXT_BG].resource))); - } -#endif /* OPT_COLOR_RES */ - -#if OPT_MAXIMIZE - if (resource.maximized) - RequestMaximize(term, True); -#endif - for (;;) { -#if OPT_TEK4014 - if (TEK4014_ACTIVE(term)) - TekRun(); - else -#endif - VTRun(term); - } - return 0; -} - -/* - * Called from get_pty to iterate over likely pseudo terminals - * we might allocate. Used on those systems that do not have - * a functional interface for allocating a pty. - * Returns 0 if found a pty, 1 if fails. - */ -static int -pty_search(int *pty) -{ - char namebuf[PTMS_BUFSZ]; - - /* ask the PTY manager */ - int fd = open("/dev/ptms$", 0); - if (fd && ptioctl(fd, PTMS_GETPTY, namebuf) == 0) { - strcpy(ttydev, namebuf); - strcpy(ptydev, namebuf); - *x_basename(ttydev) = 't'; - close(fd); - if ((*pty = open(ptydev, O_RDWR)) >= 0) { -#ifdef PTYDEBUG - ptioctl(*pty, XTY_TRACE, 0); -#endif - return 0; - } else { - xtermWarning("Unable to open %s, errno=%d\n", ptydev, errno); - } - } - return 1; -} - -/* - * This function opens up a pty master and stuffs its value into pty. - * - * If it finds one, it returns a value of 0. If it does not find one, - * it returns a value of !0. This routine is designed to be re-entrant, - * so that if a pty master is found and later, we find that the slave - * has problems, we can re-enter this function and get another one. - */ -static int -get_pty(int *pty) -{ - return pty_search(pty); -} - -/* - * The only difference in /etc/termcap between 4014 and 4015 is that - * the latter has support for switching character sets. We support the - * 4015 protocol, but ignore the character switches. Therefore, we - * choose 4014 over 4015. - * - * Features of the 4014 over the 4012: larger (19") screen, 12-bit - * graphics addressing (compatible with 4012 10-bit addressing), - * special point plot mode, incremental plot mode (not implemented in - * later Tektronix terminals), and 4 character sizes. - * All of these are supported by xterm. - */ - -#if OPT_TEK4014 -static char *tekterm[] = -{ - "tek4014", - "tek4015", /* 4014 with APL character set support */ - "tek4012", /* 4010 with lower case */ - "tek4013", /* 4012 with APL character set support */ - "tek4010", /* small screen, upper-case only */ - "dumb", - 0 -}; -#endif - -/* The VT102 is a VT100 with the Advanced Video Option included standard. - * It also adds Escape sequences for insert/delete character/line. - * The VT220 adds 8-bit character sets, selective erase. - * The VT320 adds a 25th status line, terminal state interrogation. - * The VT420 has up to 48 lines on the screen. - */ - -static const char *vtterm[] = -{ -#ifdef USE_X11TERM - "x11term", /* for people who want special term name */ -#endif - DFT_TERMTYPE, /* for people who want special term name */ - "xterm", /* the prefered name, should be fastest */ - "vt102", - "vt100", - "ansi", - "dumb", - 0 -}; - -/* ARGSUSED */ -static SIGNAL_T -hungtty(int i GCC_UNUSED) -{ - longjmp(env, 1); - SIGNAL_RETURN; -} - -#if OPT_PTY_HANDSHAKE -struct { - int rows; - int cols; -} handshake = { - - -1, -1 -}; - -void -first_map_occurred(void) -{ - if (resource.wait_for_map) { - TScreen *screen = TScreenOf(term); - handshake.rows = screen->max_row; - handshake.cols = screen->max_col; - resource.wait_for_map = False; - } -} -#endif /* OPT_PTY_HANDSHAKE else !OPT_PTY_HANDSHAKE */ - -static void -set_owner(char *device, uid_t uid, gid_t gid, mode_t mode) -{ - int why; - - if (chown(device, uid, gid) < 0) { - why = errno; - if (why != ENOENT - && save_ruid == 0) { - xtermPerror("Cannot chown %s to %ld,%ld", - device, (long) uid, (long) gid); - } - } -} - -#define THE_PARENT 1 -#define THE_CHILD 2 -int whoami = -1; - -SIGNAL_T -killit(int sig) -{ - switch (whoami) { - case -1: - signal(sig, killit); - kill(-getpid(), sig); - break; - case THE_PARENT: - wait(NULL); - signal(SIGTERM, SIG_DFL); - kill(-getpid(), SIGTERM); - Exit(0); - break; - case THE_CHILD: - signal(SIGTERM, SIG_DFL); - kill(-getppid(), SIGTERM); - Exit(0); - break; - } - - SIGNAL_RETURN; -} - -#define close_fd(fd) close(fd), fd = -1 - -static int -spawnXTerm(XtermWidget xw) -/* - * Inits pty and tty and forks a login process. - * Does not close fd Xsocket. - * If slave, the pty named in passedPty is already open for use - */ -{ - TScreen *screen = TScreenOf(xw); - int Xsocket = ConnectionNumber(screen->display); - - int ttyfd = -1; - TERMIO_STRUCT tio; - int status; - Bool ok_termcap; - - char *TermName = NULL; - char *ptr, *shname, buf[64]; - int i, no_dev_tty = False; - char *dev_tty_name = (char *) 0; - TTYSIZE_STRUCT ts; - int pgrp = getpid(); - char numbuf[12], **envnew; - - screen->uid = save_ruid; - screen->gid = save_rgid; - - if (am_slave >= 0) { - screen->respond = am_slave; - ptydev[strlen(ptydev) - 2] = - ttydev[strlen(ttydev) - 2] = passedPty[0]; - ptydev[strlen(ptydev) - 1] = - ttydev[strlen(ttydev) - 1] = passedPty[1]; - - (void) xtermResetIds(screen); - } else { - Bool tty_got_hung; - - /* - * Sometimes /dev/tty hangs on open (as in the case of a pty - * that has gone away). Simply make up some reasonable - * defaults. - */ - - signal(SIGALRM, hungtty); - alarm(2); /* alarm(1) might return too soon */ - if (!setjmp(env)) { - ttyfd = open("/dev/tty", O_RDWR); - alarm(0); - tty_got_hung = False; - } else { - tty_got_hung = True; - ttyfd = -1; - errno = ENXIO; - } - signal(SIGALRM, SIG_DFL); - - /* - * Check results and ignore current control terminal if - * necessary. ENXIO is what is normally returned if there is - * no controlling terminal, but some systems (e.g. SunOS 4.0) - * seem to return EIO. Solaris 2.3 is said to return EINVAL. - */ - if (ttyfd < 0) { - if (tty_got_hung || errno == ENXIO || errno == EIO || - errno == EINVAL || errno == ENOTTY) { - no_dev_tty = True; - tio = d_tio; - } else { - SysError(ERROR_OPDEVTTY); - } - } else { - - /* Get a copy of the current terminal's state, - * if we can. Some systems (e.g., SVR4 and MacII) - * may not have a controlling terminal at this point - * if started directly from xdm or xinit, - * in which case we just use the defaults as above. - */ - if (ioctl(ttyfd, TCGETA, &tio) == -1) - tio = d_tio; - - close_fd(ttyfd); - } - - if (get_pty(&screen->respond)) { - /* no ptys! */ - exit(ERROR_PTYS); - } - } - - /* avoid double MapWindow requests */ - XtSetMappedWhenManaged(SHELL_OF(CURRENT_EMU()), False); - - wm_delete_window = XInternAtom(XtDisplay(toplevel), "WM_DELETE_WINDOW", - False); - - if (!TEK4014_ACTIVE(xw)) - VTInit(xw); /* realize now so know window size for tty driver */ - - if (Console) { - /* - * Inform any running xconsole program - * that we are going to steal the console. - */ - XmuGetHostname(mit_console_name + MIT_CONSOLE_LEN, 255); - mit_console = XInternAtom(screen->display, mit_console_name, False); - /* the user told us to be the console, so we can use CurrentTime */ - XtOwnSelection(SHELL_OF(CURRENT_EMU()), - mit_console, CurrentTime, - ConvertConsoleSelection, NULL, NULL); - } -#if OPT_TEK4014 - if (TEK4014_ACTIVE(xw)) { - envnew = tekterm; - } else -#endif - { - envnew = vtterm; - } - - /* - * This used to exit if no termcap entry was found for the specified - * terminal name. That's a little unfriendly, so instead we'll allow - * the program to proceed (but not to set $TERMCAP) if the termcap - * entry is not found. - */ - ok_termcap = True; - if (!get_termcap(xw, TermName = resource.term_name)) { - const char *last = NULL; - char *next; - - TermName = x_strdup(*envnew); - ok_termcap = False; - while (*envnew != NULL) { - if (last == NULL || strcmp(last, *envnew)) { - next = x_strdup(*envnew); - if (get_termcap(xw, next)) { - free(TermName); - TermName = next; - ok_termcap = True; - break; - } else { - free(next); - } - } - last = *envnew; - envnew++; - } - } - if (ok_termcap) { - resource.term_name = TermName; - resize_termcap(xw); - } - - /* tell tty how big window is */ -#if OPT_TEK4014 - if (TEK4014_ACTIVE(xw)) { - TTYSIZE_ROWS(ts) = 38; - TTYSIZE_COLS(ts) = 81; - ts.ws_xpixel = TFullWidth(TekScreenOf(tekWidget)); - ts.ws_ypixel = TFullHeight(TekScreenOf(tekWidget)); - } else -#endif - { - TTYSIZE_ROWS(ts) = MaxRows(screen); - TTYSIZE_COLS(ts) = MaxCols(screen); - ts.ws_xpixel = FullWidth(screen); - ts.ws_ypixel = FullHeight(screen); - } - - if (am_slave < 0) { - - char sema[40]; - HEV sev; - /* start a child process - * use an event sema for sync - */ - sprintf(sema, "\\SEM32\\xterm%s", &ptydev[8]); - if (DosCreateEventSem(sema, &sev, DC_SEM_SHARED, False)) - SysError(ERROR_FORK); - - switch ((screen->pid = fork())) { - case -1: /* error */ - SysError(ERROR_FORK); - default: /* parent */ - whoami = THE_PARENT; - DosWaitEventSem(sev, 1000L); - DosCloseEventSem(sev); - break; - case 0: /* child */ - whoami = THE_CHILD; - - opencons(); - /* we don't need the socket, or the pty master anymore */ - close(ConnectionNumber(screen->display)); - close(screen->respond); - - /* Now is the time to set up our process group and - * open up the pty slave. - */ - if ((ttyfd = open(ttydev, O_RDWR)) < 0) { - /* dumm gelaufen */ - xtermWarning("Cannot open slave side of PTY\n"); - exit(1); - } - - /* use the same tty name that everyone else will use - * (from ttyname) - */ -#ifdef EMXNOTBOGUS - if ((ptr = ttyname(ttyfd)) != 0) { - ttydev = x_strdup(ptr); - } -#else - ptr = ttydev; -#endif - /* for safety: enable DUPs */ - ptioctl(ttyfd, XTY_ENADUP, 0); - - /* change ownership of tty to real group and user id */ - set_owner(ttydev, screen->uid, screen->gid, - (resource.messages ? 0622U : 0600U)); - - /* for the xf86sup-pty, we set the pty to bypass: OS/2 does - * not have a line discipline structure - */ - { - TERMIO_STRUCT t, t1; - if (ptioctl(ttyfd, TCGETA, (char *) &t) < 0) - t = d_tio; - - t.c_iflag = ICRNL; - t.c_oflag = OPOST | ONLCR; - t.c_lflag = ISIG | ICANON | ECHO | ECHOE | ECHOK; - - /* ignore error code, user will see it :-) */ - ptioctl(ttyfd, TCSETA, (char *) &t); - - /* set the console mode */ - if (Console) { - int on = 1; - if (ioctl(ttyfd, TIOCCONS, (char *) &on) == -1) - xtermPerror("cannot open console"); - } - } - - signal(SIGCHLD, SIG_DFL); - signal(SIGHUP, SIG_IGN); - - /* restore various signals to their defaults */ - signal(SIGINT, SIG_DFL); - signal(SIGQUIT, SIG_DFL); - signal(SIGTERM, SIG_DFL); - - xtermCopyEnv(gblenvp); - - xtermSetenv("TERM", resource.term_name); - if (!resource.term_name) - *get_tcap_buffer(xw) = 0; - - sprintf(buf, "%lu", - ((unsigned long) XtWindow(SHELL_OF(CURRENT_EMU())))); - xtermSetenv("WINDOWID", buf); - - /* put the display into the environment of the shell */ - xtermSetenv("DISPLAY", XDisplayString(screen->display)); - - xtermSetenv("XTERM_VERSION", xtermVersion()); - xtermSetenv("XTERM_LOCALE", xtermEnvLocale()); - - signal(SIGTERM, SIG_DFL); - - /* this is the time to go and set up stdin, out, and err - */ - /* dup the tty */ - for (i = 0; i <= 2; i++) - if (i != ttyfd) { - IGNORE_RC(close(i)); - IGNORE_RC(dup(ttyfd)); - } - - /* and close the tty */ - if (ttyfd > 2) - close_fd(ttyfd); - - setpgrp(0, pgrp); - (void) xtermResetIds(screen); - - if (handshake.rows > 0 && handshake.cols > 0) { - TRACE(("handshake ttysize: %dx%d\n", - handshake.rows, handshake.cols)); - set_max_row(screen, handshake.rows); - set_max_col(screen, handshake.cols); - TTYSIZE_ROWS(ts) = (ttySize_t) MaxRows(screen); - TTYSIZE_COLS(ts) = (ttySize_t) MaxCols(screen); - ts.ws_xpixel = (ttySize_t) FullWidth(screen); - ts.ws_ypixel = (ttySize_t) FullHeight(screen); - } - - sprintf(numbuf, "%d", MaxCols(screen)); - xtermSetenv("COLUMNS", numbuf); - sprintf(numbuf, "%d", MaxRows(screen)); - xtermSetenv("LINES", numbuf); - - gblenvp = environ; - - /* need to reset after all the ioctl bashing we did above */ - ptioctl(0, TIOCSWINSZ, (char *) &ts); - - signal(SIGHUP, SIG_DFL); - - /* okay everything seems right, so tell the parent, we are going */ - { - char sema[40]; - HEV sev; - sprintf(sema, "\\SEM32\\xterm%s", &ttydev[8]); - DosOpenEventSem(sema, &sev); - DosPostEventSem(sev); - DosCloseEventSem(sev); - } - -#if OPT_LUIT_PROG - /* - * Use two copies of command_to_exec, in case luit is not actually - * there, or refuses to run. In that case we will fall-through to - * to command that the user gave anyway. - */ - if (command_to_exec_with_luit) { - xtermSetenv("XTERM_SHELL", - xtermFindShell(*command_to_exec_with_luit, False)); - TRACE(("spawning command \"%s\"\n", *command_to_exec_with_luit)); - execvp(*command_to_exec_with_luit, command_to_exec_with_luit); - xtermPerror("Can't execvp %s", *command_to_exec_with_luit); - xtermWarning("cannot support your locale.\n"); - } -#endif - if (command_to_exec) { - xtermSetenv("XTERM_SHELL", - xtermFindShell(*command_to_exec, False)); - TRACE(("spawning command \"%s\"\n", *command_to_exec)); - execvpe(*command_to_exec, command_to_exec, gblenvp); - - /* print error message on screen */ - xtermWarning("Can't execvp %s\n", *command_to_exec); - } - - /* use a layered mechanism to find a shell */ - ptr = x_getenv("X11SHELL"); - if (!ptr) - ptr = x_getenv("SHELL"); - if (!ptr) - ptr = x_getenv("OS2_SHELL"); - if (!ptr) - ptr = "SORRY_NO_SHELL_FOUND"; - xtermSetenv("XTERM_SHELL", ptr); - - shname = x_basename(ptr); - if (command_to_exec) { - char *exargv[10]; /*XXX */ - - exargv[0] = ptr; - exargv[1] = "/C"; - exargv[2] = command_to_exec[0]; - exargv[3] = command_to_exec[1]; - exargv[4] = command_to_exec[2]; - exargv[5] = command_to_exec[3]; - exargv[6] = command_to_exec[4]; - exargv[7] = command_to_exec[5]; - exargv[8] = command_to_exec[6]; - exargv[9] = 0; - execvpe(exargv[0], exargv, gblenvp); - - /* print error message on screen */ - xtermWarning("Can't execvp %s\n", *command_to_exec); - } else { - execlpe(ptr, shname, 0, gblenvp); - - /* Exec failed. */ - xtermWarning("Could not exec %s!\n", ptr); - } - sleep(5); - - /* preventively shoot the parent */ - kill(-getppid(), SIGTERM); - - exit(ERROR_EXEC); - } /* endcase */ - } - /* !am_slave */ - signal(SIGHUP, SIG_IGN); -/* - * Unfortunately, System V seems to have trouble divorcing the child process - * from the process group of xterm. This is a problem because hitting the - * INTR or QUIT characters on the keyboard will cause xterm to go away if we - * don't ignore the signals. This is annoying. - */ - -/* signal (SIGINT, SIG_IGN);*/ - signal(SIGINT, killit); - signal(SIGTERM, killit); - - /* hung shell problem */ - signal(SIGQUIT, SIG_IGN); -/* signal (SIGTERM, SIG_IGN);*/ - return 0; -} /* end spawnXTerm */ - -SIGNAL_T -Exit(int n) -{ - XtermWidget xw = term; - TScreen *screen = TScreenOf(xw); - int pty = TScreenOf(xw)->respond; - close(pty); /* close explicitly to avoid race with slave side */ -#ifdef ALLOWLOGGING - if (screen->logging) - CloseLog(xw); -#endif - if (am_slave < 0) { - /* restore ownership of tty and pty */ - set_owner(ttydev, 0, 0, 0666U); - set_owner(ptydev, 0, 0, 0666U); - } - - /* - * Close after releasing ownership to avoid race condition: other programs - * grabbing it, and *then* having us release ownership.... - */ - close(screen->respond); /* close explicitly to avoid race with slave side */ -#ifdef ALLOWLOGGING - if (screen->logging) - CloseLog(xw); -#endif - -#ifdef NO_LEAKS - if (n == 0) { - TRACE(("Freeing memory leaks\n")); - if (xw != 0) { - Display *dpy = TScreenOf(xw)->display; - - if (toplevel) { - XtDestroyWidget(toplevel); - TRACE(("destroyed top-level widget\n")); - } - sortedOpts(0, 0, 0); - noleaks_charproc(); - noleaks_ptydata(); -#if OPT_WIDE_CHARS - noleaks_CharacterClass(); -#endif - /* XrmSetDatabase(dpy, 0); increases leaks ;-) */ - XtCloseDisplay(dpy); - XtDestroyApplicationContext(app_con); -#if OPT_SESSION_MGT - IceRemoveConnectionWatch(icewatch, NULL); -#endif - TRACE(("closed display\n")); - } - TRACE_CLOSE(); - } -#endif - - exit(n); - SIGNAL_RETURN; -} - -/* ARGSUSED */ -static void -resize_termcap(XtermWidget xw) -{ -} - -/* - * Does a non-blocking wait for a child process. If the system - * doesn't support non-blocking wait, do nothing. - * Returns the pid of the child, or 0 or -1 if none or error. - */ -int -nonblocking_wait(void) -{ - pid_t pid; - - pid = waitpid(-1, NULL, WNOHANG); - return pid; -} - -/* ARGSUSED */ -static SIGNAL_T -reapchild(int n GCC_UNUSED) -{ - int olderrno = errno; - int pid; - - pid = wait(NULL); - - /* cannot re-enable signal before waiting for child - * because then SVR4 loops. Sigh. HP-UX 9.01 too. - */ - (void) signal(SIGCHLD, reapchild); - - do { - if (pid == TScreenOf(term)->pid) { -#ifdef DEBUG - if (debug) - fputs("Exiting\n", stderr); -#endif - if (!hold_screen) - need_cleanup = True; - } - } while ((pid = nonblocking_wait()) > 0); - - errno = olderrno; - SIGNAL_RETURN; -} - -/* - * parse_tty_modes accepts lines of the following form: - * - * [SETTING] ... - * - * where setting consists of the words in the modelist followed by a character - * or ^char. - */ -static int -parse_tty_modes(char *s, struct _xttymodes *modelist) -{ - struct _xttymodes *mp; - int c; - int count = 0; - - TRACE(("parse_tty_modes\n")); - for (;;) { - size_t len; - - while (*s && isascii(CharOf(*s)) && isspace(CharOf(*s))) - s++; - if (!*s) - return count; - - for (len = 0; isalnum(CharOf(s[len])); ++len) ; - for (mp = modelist; mp->name; mp++) { - if (len == mp->len - && strncmp(s, mp->name, mp->len) == 0) - break; - } - if (!mp->name) - return -1; - - s += mp->len; - while (*s && isascii(CharOf(*s)) && isspace(CharOf(*s))) - s++; - if (!*s) - return -1; - - if ((c = decode_keyvalue(&s, False)) != -1) { - mp->value = c; - mp->set = 1; - count++; - TRACE(("...parsed #%d: %s=%#x\n", count, mp->name, c)); - } - } -} - -int -GetBytesAvailable(int fd) -{ - long arg; - ioctl(fd, FIONREAD, (char *) &arg); - return (int) arg; -} - -/* Utility function to try to hide system differences from - everybody who used to call killpg() */ - -int -kill_process_group(int pid, int sig) -{ - return kill(-pid, sig); -} - -int -ptioctl(int fd, int func, void *data) -{ - APIRET rc; - ULONG len; - struct pt_termios pt; - TERMIO_STRUCT *t; - int i; - - switch (func) { - case TCGETA: - rc = DosDevIOCtl(fd, XFREE86_PTY, XTY_TIOCGETA, - NULL, 0, NULL, - (ULONG *) & pt, sizeof(struct pt_termios), &len); - if (rc) - return -1; - t = (TERMIO_STRUCT *) data; - t->c_iflag = pt.c_iflag; - t->c_oflag = pt.c_oflag; - t->c_cflag = pt.c_cflag; - t->c_lflag = pt.c_lflag; - for (i = 0; i < NCC; i++) - t->c_cc[i] = pt.c_cc[i]; - return 0; - case TCSETA: - case TCSETAW: - case TCSETAF: - t = (TERMIO_STRUCT *) data; - pt.c_iflag = t->c_iflag; - pt.c_oflag = t->c_oflag; - pt.c_cflag = t->c_cflag; - pt.c_lflag = t->c_lflag; - - for (i = 0; i < NCC; i++) - pt.c_cc[i] = t->c_cc[i]; - if (func == TCSETA) - i = XTY_TIOCSETA; - else if (func == TCSETAW) - i = XTY_TIOCSETAW; - else - i = XTY_TIOCSETAF; - rc = DosDevIOCtl(fd, XFREE86_PTY, i, - (ULONG *) & pt, sizeof(struct pt_termios), &len, - NULL, 0, NULL); - return (rc) ? -1 : 0; - case TIOCCONS: - return DosDevIOCtl(fd, XFREE86_PTY, XTY_TIOCCONS, - (ULONG *) data, sizeof(ULONG), &len, - NULL, 0, NULL); - case TIOCSWINSZ: - return DosDevIOCtl(fd, XFREE86_PTY, XTY_TIOCSWINSZ, - (ULONG *) data, sizeof(TTYSIZE_STRUCT), &len, - NULL, 0, NULL); - case TIOCGWINSZ: - return DosDevIOCtl(fd, XFREE86_PTY, XTY_TIOCGWINSZ, - NULL, 0, NULL, - (ULONG *) data, sizeof(TTYSIZE_STRUCT), &len); - case XTY_ENADUP: - i = 1; - return DosDevIOCtl(fd, XFREE86_PTY, XTY_ENADUP, - (ULONG *) & i, sizeof(ULONG), &len, - NULL, 0, NULL); - case XTY_TRACE: - i = 2; - return DosDevIOCtl(fd, XFREE86_PTY, XTY_TRACE, - (ULONG *) & i, sizeof(ULONG), &len, - NULL, 0, NULL); - case PTMS_GETPTY: - i = 1; - return DosDevIOCtl(fd, XFREE86_PTY, PTMS_GETPTY, - (ULONG *) & i, sizeof(ULONG), &len, - (UCHAR *) data, 14, &len); - default: - return -1; - } -} diff -Nru xterm-278/package/debian/changelog xterm-297/package/debian/changelog --- xterm-278/package/debian/changelog 2012-01-19 01:40:44.000000000 +0000 +++ xterm-297/package/debian/changelog 2013-08-04 12:58:44.000000000 +0000 @@ -1,3 +1,122 @@ +xterm-dev (297) unstable; urgency=low + + * miscellaneous fixes for old issues + + -- Thomas E. Dickey Sun, 04 Aug 2013 08:58:31 -0400 + +xterm-dev (296) unstable; urgency=low + + * Build-fix for #295 changes + + -- Thomas E. Dickey Tue, 09 Jul 2013 21:20:04 -0400 + +xterm-dev (295) unstable; urgency=low + + * Workaround for problem with ld --as-needed option + + -- Thomas E. Dickey Sat, 06 Jul 2013 21:20:33 -0400 + +xterm-dev (294) unstable; urgency=low + + * Add experimental support for sixel graphics + + -- Thomas E. Dickey Sun, 23 Jun 2013 10:36:52 -0400 + +xterm-dev (293) unstable; urgency=low + + * Miscellaneous fixes. + + -- Thomas E. Dickey Wed, 08 May 2013 18:29:21 -0400 + +xterm-dev (292) unstable; urgency=low + + * Miscellaneous fixes. + + -- Thomas E. Dickey Tue, 26 Mar 2013 19:11:17 -0400 + +xterm-dev (291) unstable; urgency=low + + * Fix a different #282 change (Redhat #874327). + + -- Thomas E. Dickey Tue, 26 Feb 2013 19:09:32 -0500 + +xterm-dev (290) unstable; urgency=low + + * Fix incomplete revert of #282 change. + + -- Thomas E. Dickey Tue, 12 Feb 2013 19:48:21 -0500 + +xterm-dev (289) unstable; urgency=low + + * Miscellaneous fixes. + * Fix regression with XTERM_SHELL feature. + + -- Thomas E. Dickey Sun, 03 Feb 2013 13:59:20 -0500 + +xterm-dev (288) unstable; urgency=low + + * Miscellaneous fixes. + + -- Thomas E. Dickey Mon, 26 Nov 2012 20:53:23 -0500 + +xterm-dev (287) unstable; urgency=low + + * Miscellaneous fixes. + * Redhat #874327, #875305. + + -- Thomas E. Dickey Mon, 19 Nov 2012 04:53:39 -0500 + +xterm-dev (286) unstable; urgency=low + + * Redhat #869959 + + -- Thomas E. Dickey Thu, 25 Oct 2012 06:56:35 -0400 + +xterm-dev (285) unstable; urgency=low + + * Miscellaneous fixes. + + -- Thomas E. Dickey Mon, 15 Oct 2012 06:57:38 -0400 + +xterm-dev (284) unstable; urgency=low + + * fix documentation errata + * fix regression in --enable-regex + + -- Thomas E. Dickey Wed, 10 Oct 2012 18:17:35 -0400 + +xterm-dev (283) unstable; urgency=low + + * Miscellaneous fixes. + + -- Thomas E. Dickey Mon, 01 Oct 2012 20:45:50 -0400 + +xterm-dev (282) unstable; urgency=low + + * Miscellaneous fixes. + + -- Thomas E. Dickey Mon, 20 Aug 2012 17:55:32 -0400 + +xterm-dev (281) unstable; urgency=low + + * fix regression in keyboard configuration. + + -- Thomas E. Dickey Tue, 26 Jun 2012 04:36:36 -0400 + +xterm-dev (280) unstable; urgency=low + + * Add Debian menu-file. + * modify to support icon-theme + * Miscellaneous fixes. + + -- Thomas E. Dickey Fri, 25 May 2012 05:36:50 -0400 + +xterm-dev (279) unstable; urgency=low + + * Miscellaneous fixes. + + -- Thomas E. Dickey Wed, 14 Mar 2012 20:33:27 -0400 + xterm-dev (278) unstable; urgency=low * Fix regression in eightBitInput logic. diff -Nru xterm-278/package/debian/rules xterm-297/package/debian/rules --- xterm-278/package/debian/rules 2011-07-07 09:20:47.000000000 +0000 +++ xterm-297/package/debian/rules 2013-06-23 22:15:34.000000000 +0000 @@ -58,6 +58,7 @@ --libdir=/etc/$(PACKAGE) \ --with-app-class=$(PKG_CLASS) \ --without-xterm-symlink \ + --disable-imake \ --enable-256-color \ --enable-88-color \ --enable-dabbrev \ @@ -71,17 +72,21 @@ --enable-paste64 \ --enable-rectangles \ --enable-sco-fkeys \ + --enable-sixel-graphics \ --enable-tcap-fkeys \ --enable-tcap-query \ --enable-toolbar \ --enable-wide-chars \ --enable-xmc-glitch \ --with-app-defaults=$(PKG_APPDEFAULTS) \ - --with-icondir=\$${prefix}/share/pixmaps \ + --with-icondir=\$${prefix}/share/icons \ + --with-pixmapdir=\$${prefix}/share/pixmaps \ --with-own-terminfo=\$${prefix}/share/terminfo \ + --with-icon-theme \ --with-terminal-type=xterm-new \ --with-utempter \ - ${DEBOP} + --with-icon-name=mini.xterm \ + --with-xpm ${DEBOP} touch configure-stamp @@ -161,6 +166,8 @@ done' ; \ exit 0 ) + dh_icons + # Build architecture-dependent files here. binary-arch: build install dh_testdir diff -Nru xterm-278/package/debian/xterm-dev.menu xterm-297/package/debian/xterm-dev.menu --- xterm-278/package/debian/xterm-dev.menu 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/package/debian/xterm-dev.menu 2012-06-24 13:24:43.000000000 +0000 @@ -0,0 +1,14 @@ +?package(xterm-dev):\ + needs="x11"\ + section="Applications/Terminal Emulators"\ + longtitle="XTerm: terminal emulator for X (development)"\ + title="XTermDev"\ + icon="/usr/share/pixmaps/xterm-dev-color_32x32.xpm"\ + command="xterm" +?package(xterm-dev):\ + needs="x11"\ + section="Applications/Terminal Emulators"\ + longtitle="XTerm: terminal emulator for X with Unicode support (development)"\ + title="XTermDev (Unicode)"\ + icon="/usr/share/pixmaps/xterm-dev-color_32x32.xpm"\ + command="uxterm" diff -Nru xterm-278/package/debian/xterm-xres.sed xterm-297/package/debian/xterm-xres.sed --- xterm-278/package/debian/xterm-xres.sed 2010-10-24 16:48:48.000000000 +0000 +++ xterm-297/package/debian/xterm-xres.sed 2012-08-24 12:31:58.000000000 +0000 @@ -4,5 +4,4 @@ *backarrowKeyIsErase: true\ *ptyInitialErase: true /!*allowWindowOps: false/a\ -*allowWindowOps: true\ -*activeIcon: true +*allowWindowOps: true diff -Nru xterm-278/package/freebsd/Makefile xterm-297/package/freebsd/Makefile --- xterm-278/package/freebsd/Makefile 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/package/freebsd/Makefile 2013-08-04 12:58:44.000000000 +0000 @@ -0,0 +1,98 @@ +# $FreeBSD$ +# This is adapted from the FreeBSD port, installing as "xterm-dev" with +# separate resource- and manpage files. +# copy "xterm-${PORTVERSION}.tgz to the port's distfiles directory +# and "make makesum". + +PORTNAME= xterm +PORTVERSION= 297 +CATEGORIES= x11 +MASTER_SITES= ftp://invisible-island.net/xterm/ \ + CRITICAL +PKGNAMESUFFIX= -dev +EXTRACT_SUFX= .tgz + +MAINTAINER= dickey@invisible-island.net +COMMENT= Terminal emulator for the X Window System (development) + +CONFLICTS= x11iraf-[0-9]* + +USE_XORG= xaw xft +WANT_GNOME= desktopfileutils +GNU_CONFIGURE= yes + +CONFIGURE_ENV+= LIBS="-L${LOCALBASE}/lib" +CONFIGURE_ARGS+= --with-utempter --enable-narrowproto --enable-256-color + +CPPFLAGS+= -I${LOCALBASE}/include + +OPTIONS_DEFINE= WCHAR LUIT DECTERM PCRE GNOME DABBREV TOOLBAR + +TOOLBAR_DESC= Enable support menu/toolbar +DABBREV_DESC= Enable support for dabbrev-expand +DECTERM_DESC= Enable DECterm Locator support +LUIT_DESC= Use LUIT for locale convertion from/to UTF-8 +WCHAR_DESC= Enable wide-character support + +PKG_CLASS= XTermDev + +.include + +CONFIGURE_ARGS+= --program-suffix=${PKGNAMESUFFIX} --with-app-class=${PKG_CLASS} --without-xterm-symlink + +.if ${PORT_OPTIONS:MLUIT} +CONFIGURE_ARGS+= --enable-luit +BUILD_DEPENDS= luit:${PORTSDIR}/x11/luit +.endif + +.if ${PORT_OPTIONS:MWCHAR} +CONFIGURE_ARGS+= --enable-wide-chars +.endif + +.if ${PORT_OPTIONS:MDECTERM} +CONFIGURE_ARGS+= --enable-dec-locator +.endif + +.if ${PORT_OPTIONS:MPCRE} +CONFIGURE_ARGS+= --with-pcre +LIB_DEPENDS= pcre:${PORTSDIR}/devel/pcre +.endif + +.if ${PORT_OPTIONS:MDABBREV} +CONFIGURE_ARGS+= --enable-dabbrev +.endif + +.if ${PORT_OPTIONS:MTOOLBAR} +CONFIGURE_ARGS+= --enable-toolbar +.endif + +.if ${PORT_OPTIONS:MGNOME} +USE_GNOME= desktopfileutils +PLIST_SUB+= GNOME="" +.else +PLIST_SUB+= GNOME="@comment " +.endif + +MAN1= resize${PKGNAMESUFFIX}.1 koi8rxterm${PKGNAMESUFFIX}.1 uxterm${PKGNAMESUFFIX}.1 xterm${PKGNAMESUFFIX}.1 + +.include + +.if ${OSVERSION} < 900004 +LIB_DEPENDS+= utempter:${PORTSDIR}/sysutils/libutempter +.endif + +post-install: +.for f in koi8rxterm resize uxterm xterm + @${CHMOD} ${BINMODE} ${PREFIX}/bin/${f} +.endfor +.if ${PORT_OPTIONS:MGNOME} + @${MKDIR} ${PREFIX}/share/applications/ + @${INSTALL_DATA} ${WRKSRC}/xterm.desktop ${PREFIX}/share/applications/ + @-update-desktop-database +.endif + +.if ${PORT_OPTIONS:MWCHAR} + @${CAT} ${PKGMESSAGE} +.endif + +.include diff -Nru xterm-278/package/freebsd/pkg-descr xterm-297/package/freebsd/pkg-descr --- xterm-278/package/freebsd/pkg-descr 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/package/freebsd/pkg-descr 2004-07-24 00:01:19.000000000 +0000 @@ -0,0 +1,10 @@ +The xterm program is the standard terminal emulator for the X +Window System. It provides DEC VT102/VT220 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. + +WWW: http://invisible-island.net/xterm/ diff -Nru xterm-278/package/freebsd/pkg-message xterm-297/package/freebsd/pkg-message --- xterm-278/package/freebsd/pkg-message 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/package/freebsd/pkg-message 2011-02-24 15:39:09.000000000 +0000 @@ -0,0 +1,10 @@ +================================================================================ +You installed xterm with wide chars support. This introduces some limitations +comparing to the plain single chars version: this version of xterm will use +UTF-8 charset for selection buffers, breaking 8-bit copy/paste support unless +you are using UTF-8 or ISO8859-1 locale. If you want 8-bit charset selections to +work as before, use "eightBitSelectTypes" XTerm resource setting. + +For further information refer to the SELECT/PASTE section of xterm(1) manual +page. +================================================================================ diff -Nru xterm-278/package/freebsd/pkg-plist xterm-297/package/freebsd/pkg-plist --- xterm-278/package/freebsd/pkg-plist 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/package/freebsd/pkg-plist 2012-10-23 22:47:53.000000000 +0000 @@ -0,0 +1,22 @@ +bin/koi8rxterm-dev +bin/resize-dev +bin/uxterm-dev +bin/xterm-dev +lib/X11/app-defaults/KOI8RXTermDev +lib/X11/app-defaults/KOI8RXTermDev-color +lib/X11/app-defaults/UXTermDev +lib/X11/app-defaults/UXTermDev-color +lib/X11/app-defaults/XTermDev +lib/X11/app-defaults/XTermDev-color +share/applications/xterm-dev.desktop +share/pixmaps/filled-xterm-dev_32x32.xpm +share/pixmaps/filled-xterm-dev_48x48.xpm +share/pixmaps/mini.xterm-dev_32x32.xpm +share/pixmaps/mini.xterm-dev_48x48.xpm +share/pixmaps/xterm-dev-color_32x32.xpm +share/pixmaps/xterm-dev-color_48x48.xpm +share/pixmaps/xterm-dev_32x32.xpm +share/pixmaps/xterm-dev_48x48.xpm +@dirrmtry share/applications +%%GNOME%%@exec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true +%%GNOME%%@unexec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true diff -Nru xterm-278/package/xterm.spec xterm-297/package/xterm.spec --- xterm-278/package/xterm.spec 2012-01-12 13:10:21.000000000 +0000 +++ xterm-297/package/xterm.spec 2013-08-04 12:58:44.000000000 +0000 @@ -1,10 +1,14 @@ -# $XTermId: xterm.spec,v 1.20 2012/01/12 13:10:21 tom Exp $ -Summary: A text-based Web browser -Name: xterm-dev -Version: 278 +# $XTermId: xterm.spec,v 1.55 2013/08/04 12:58:44 tom Exp $ +Summary: X terminal emulator (development version) +%global my_middle xterm +%global my_suffix -dev +%global fullname %{my_middle}%{my_suffix} +%global my_class XTermDev +Name: %{fullname} +Version: 297 Release: 1 License: X11 -Group: Applications/Internet +Group: User Interface/X Source: xterm-%{version}.tgz # URL: http://invisible-island.net/xterm/ Provides: x-terminal-emulator @@ -17,32 +21,31 @@ used by DEC VT220 terminals. This package provides four commands: - a) xterm, which is the actual terminal emulator - b) uxterm, which is a wrapper around xterm which sets xterm to use UTF-8 - encoding when the user's locale supports this, - c) koi8rxterm, a wrapper similar to uxterm for locales that use the - KOI8-R character set, and - d) resize. + a) %{fullname}, which is the actual terminal emulator + b) u%{fullname}, which is a wrapper around %{fullname} + which sets %{fullname} to use UTF-8 encoding when + the user's locale supports this, + c) koi8r%{fullname}, a wrapper similar to u%{fullname} + for locales that use the KOI8-R character set, and + d) resize%{my_suffix}. A complete list of control sequences supported by the X terminal emulator -is provided in /usr/share/doc/xterm. +is provided in /usr/share/doc/%{fullname}. -The xterm program uses bitmap images provided by the xbitmaps package. +The %{fullname} program uses bitmap images provided by the xbitmaps package. -Those interested in using koi8rxterm will likely want to install the +Those interested in using koi8r%{fullname} will likely want to install the xfonts-cyrillic package as well. -This package is configured to use "xterm-dev" and "XTermDev" for the program -and its resource class, to avoid conflict with other packages. +This package is configured to use "%{fullname}" and "%{my_class}" +for the program and its resource class, to avoid conflict with other packages. %prep -%define my_suffix -dev -%define my_class XTermDev - -%define desktop_vendor dickey -%define desktop_utils %(if which desktop-file-install 2>&1 >/dev/null ; then echo "yes" ; fi) +%global desktop_vendor dickey +%define desktop_utils %(if which desktop-file-install 2>&1 >/dev/null ; then echo 1 || echo 0 ; fi) +%define icon_theme %(test -d /usr/share/icons/hicolor && echo 1 || echo 0) %define apps_shared %(test -d /usr/share/X11/app-defaults && echo 1 || echo 0) %define apps_syscnf %(test -d /etc/X11/app-defaults && echo 1 || echo 0) @@ -54,7 +57,10 @@ %define _iconsdir %{_datadir}/icons %define _pixmapsdir %{_datadir}/pixmaps -%define my_docdir %{_datadir}/doc/xterm%{my_suffix} +%define my_docdir %{_datadir}/doc/%{fullname} + +# no need for debugging symbols... +%define debug_package %{nil} %setup -q -n xterm-%{version} @@ -70,7 +76,13 @@ --program-suffix=%{my_suffix} \ --without-xterm-symlink \ %endif +%if "%{icon_theme}" + --with-icon-symlink \ + --with-icon-theme \ + --with-icondir=%{_iconsdir} \ +%endif --with-app-class=%{my_class} \ + --disable-imake \ --enable-256-color \ --enable-88-color \ --enable-dabbrev \ @@ -82,18 +94,21 @@ --enable-logging \ --enable-mini-luit \ --enable-paste64 \ - --enable-rectangles \ --enable-sco-fkeys \ + --enable-sixel-graphics \ --enable-tcap-fkeys \ --enable-tcap-query \ --enable-toolbar \ --enable-wide-chars \ --enable-xmc-glitch \ --with-app-defaults=%{_xresdir} \ - --with-icondir=%{_pixmapsdir} \ + --with-pixmapdir=%{_pixmapsdir} \ --with-own-terminfo=%{_datadir}/terminfo \ --with-terminal-type=xterm-new \ - --with-utempter + --with-utempter \ + --with-icon-name=mini.xterm \ + --with-xpm + copy config.status /tmp/ make chmod u+w XTerm.ad @@ -129,7 +144,7 @@ # know that they do not depend on Perl packages. chmod 644 $RPM_BUILD_ROOT%{my_docdir}/vttests/* -%if "%{desktop_utils}" == "yes" +%if "%{desktop_utils}" make install-desktop \ DESKTOP_FLAGS="--vendor='%{desktop_vendor}' --dir $RPM_BUILD_ROOT%{_datadir}/applications" @@ -142,30 +157,67 @@ ) %endif +%post +%if "%{icon_theme}" +touch --no-create %{_iconsdir}/hicolor +if [ -x %{_bindir}/gtk-update-icon-cache ]; then + %{_bindir}/gtk-update-icon-cache %{_iconsdir}/hicolor || : +fi +%endif + +%postun +%if "%{icon_theme}" +touch --no-create %{_iconsdir}/hicolor +if [ -x %{_bindir}/gtk-update-icon-cache ]; then + %{_bindir}/gtk-update-icon-cache %{_iconsdir}/hicolor || : +fi +%endif + %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) -%{_bindir}/koi8rxterm%{my_suffix} -%{_bindir}/xterm%{my_suffix} -%{_bindir}/uxterm%{my_suffix} +%{_bindir}/koi8r%{fullname} +%{_bindir}/%{fullname} +%{_bindir}/u%{fullname} %{_bindir}/resize%{my_suffix} %{_mandir}/*/* %{my_docdir}/* -%{_pixmapsdir}/xterm*.xpm %{_xresdir}/*XTerm* %if "%{install_ti}" == "yes" %{_datadir}/terminfo/* %endif -%if "%{desktop_utils}" == "yes" -%config(missingok) %{_datadir}/applications/%{desktop_vendor}-xterm%{my_suffix}.desktop -%config(missingok) %{_datadir}/applications/%{desktop_vendor}-uxterm%{my_suffix}.desktop +%if "%{desktop_utils}" +%config(missingok) %{_datadir}/applications/%{desktop_vendor}-%{fullname}.desktop +%config(missingok) %{_datadir}/applications/%{desktop_vendor}-u%{fullname}.desktop %endif +%if "%{icon_theme}" +%{_iconsdir}/hicolor/48x48/apps/%{fullname}*.png +%{_iconsdir}/hicolor/scalable/apps/%{fullname}*.svg +%endif +%{_pixmapsdir}/*%{fullname}*.xpm + +# files added by --with-icon-symlink +%if "%{icon_theme}" +%{_iconsdir}/hicolor/xterm.png +%{_iconsdir}/hicolor/xterm.svg +%endif +%{_pixmapsdir}/xterm.xpm + %changelog +* Mon May 27 2013 Thomas E. Dickey +- use --with-icon-symlink + +* Mon Oct 08 2012 Thomas E. Dickey +- added to pixmapsdir + +* Fri Jun 15 2012 Thomas E. Dickey +- modify to support icon theme + * Fri Oct 22 2010 Thomas E. Dickey - initial version. diff -Nru xterm-278/plink.sh xterm-297/plink.sh --- xterm-278/plink.sh 2010-11-28 23:55:35.000000000 +0000 +++ xterm-297/plink.sh 2013-07-07 01:20:48.000000000 +0000 @@ -1,12 +1,12 @@ #!/bin/sh -# $XTermId: plink.sh,v 1.7 2010/11/28 23:55:35 tom Exp $ +# $XTermId: plink.sh,v 1.10 2013/07/07 01:20:48 tom Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 2001-2005,2010 by Thomas E. Dickey -# +# Copyright 2001-2010,2013 by Thomas E. Dickey +# # 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 @@ -14,10 +14,10 @@ # 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. @@ -25,7 +25,7 @@ # 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 @@ -34,8 +34,27 @@ # # Reduce the number of dynamic libraries used to link an executable. LINKIT= +ASNEED=no while test $# != 0 do + if test $ASNEED = no && test -n "$LINKIT" + then + ASNEED=yes + OPT=-Wl,-as-needed + if ( eval $LINKIT $OPT $* >/dev/null 2>/dev/null ) + then + WARNED=`eval $LINKIT $OPT $* 2>&1` + case ".$WARNED" in + *Warning*|*nsupported*|*nrecognized*|*nknown*) + ;; + *) + LINKIT="$LINKIT $OPT $*" + break + ;; + esac + fi + fi + OPT="$1" shift case $OPT in diff -Nru xterm-278/precompose.c xterm-297/precompose.c --- xterm-278/precompose.c 2007-02-05 01:06:36.000000000 +0000 +++ xterm-297/precompose.c 2013-02-03 17:06:01.000000000 +0000 @@ -4,7 +4,7 @@ * DO NOT EDIT BY HAND! This is generated by the script * unicode/make-precompose.sh */ -/* $XTermId: precompose.c,v 1.8 2007/02/05 01:06:36 Thomas.Wolff Exp $ */ +/* $XTermId: precompose.c,v 1.9 2013/02/03 17:06:01 tom Exp $ */ /* $XFree86$ */ #include @@ -1014,6 +1014,11 @@ { 0x30FE, 0x30FD, 0x3099}, { 0xFB2C, 0xFB49, 0x05C1}, { 0xFB2D, 0xFB49, 0x05C2}, +{ 0x1109A, 0x11099, 0x110BA}, +{ 0x1109C, 0x1109B, 0x110BA}, +{ 0x110AB, 0x110A5, 0x110BA}, +{ 0x1112E, 0x11131, 0x11127}, +{ 0x1112F, 0x11132, 0x11127}, { 0x1D15E, 0x1D157, 0x1D165}, { 0x1D15F, 0x1D158, 0x1D165}, { 0x1D160, 0x1D15F, 0x1D16E}, diff -Nru xterm-278/print.c xterm-297/print.c --- xterm-278/print.c 2011-09-11 14:59:36.000000000 +0000 +++ xterm-297/print.c 2013-05-27 00:55:47.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: print.c,v 1.139 2011/09/11 14:59:36 tom Exp $ */ +/* $XTermId: print.c,v 1.150 2013/05/27 00:55:47 tom Exp $ */ /* - * Copyright 1997-2010,2011 by Thomas E. Dickey + * Copyright 1997-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -74,7 +74,7 @@ static void stringToPrinter(XtermWidget /* xw */ , const char * /*str */ ); -void +static void closePrinter(XtermWidget xw GCC_UNUSED) { if (xtermHasPrinter(xw) != 0) { @@ -87,19 +87,22 @@ #endif if (SPS.fp != 0) { - fclose(SPS.fp); + DEBUG_MSG("closePrinter\n"); + pclose(SPS.fp); TRACE(("closed printer, waiting...\n")); #ifdef VMS /* This is a quick hack, really should use spawn and check status or system services and go straight to the queue */ (void) system(pcommand); #else /* VMS */ - while (nonblocking_wait() > 0) -#endif /* VMS */ + while (nonblocking_wait() > 0) { ; + } +#endif /* VMS */ SPS.fp = 0; SPS.isOpen = False; TRACE(("closed printer\n")); + DEBUG_MSG("...closePrinter (done)\n"); } } } @@ -301,6 +304,7 @@ int save_which = screen->whichBuf; int done_which = 0; + DEBUG_MSG("xtermPrintEverything\n"); if (p->print_everything) { if (p->print_everything & 8) { printLines(xw, -screen->savedlines, -(screen->topline + 1), p); @@ -437,6 +441,7 @@ SysError(ERROR_FORK); if (my_pid == 0) { + DEBUG_MSG("charToPrinter: subprocess for printer\n"); TRACE_CLOSE(); close(my_pipe[1]); /* printer is silent */ close(screen->respond); @@ -454,19 +459,39 @@ exit(1); SPS.fp = popen(SPS.printer_command, "w"); - input = fdopen(my_pipe[0], "r"); - while ((c = fgetc(input)) != EOF) { - fputc(c, SPS.fp); - if (isForm(c)) - fflush(SPS.fp); + if (SPS.fp != 0) { + DEBUG_MSG("charToPrinter: opened pipe to printer\n"); + input = fdopen(my_pipe[0], "r"); + clearerr(input); + for (;;) { + if (ferror(input)) { + DEBUG_MSG("charToPrinter: break on ferror\n"); + break; + } else if (feof(input)) { + DEBUG_MSG("charToPrinter: break on feof\n"); + break; + } else if ((c = fgetc(input)) == EOF) { + DEBUG_MSG("charToPrinter: break on EOF\n"); + break; + } + fputc(c, SPS.fp); + if (isForm(c)) + fflush(SPS.fp); + } + DEBUG_MSG("charToPrinter: calling pclose\n"); + pclose(SPS.fp); } - pclose(SPS.fp); exit(0); } else { close(my_pipe[0]); /* won't read from printer */ - SPS.fp = fdopen(my_pipe[1], "w"); - TRACE(("opened printer from pid %d/%d\n", - (int) getpid(), (int) my_pid)); + if ((SPS.fp = fdopen(my_pipe[1], "w")) != 0) { + DEBUG_MSG("charToPrinter: opened printer in parent\n"); + TRACE(("opened printer from pid %d/%d\n", + (int) getpid(), (int) my_pid)); + } else { + TRACE(("failed to open printer:%s\n", strerror(errno))); + DEBUG_MSG("charToPrinter: could not open in parent\n"); + } } } #endif @@ -641,13 +666,37 @@ /* * If there is no printer command, we will ignore printer controls. + * + * If we do have a printer command, we still have to verify that it will + * (perhaps) work if we pass it to popen(). At a minimum, the program + * must exist and be executable. If not, warn and disable the feature. */ Bool xtermHasPrinter(XtermWidget xw) { TScreen *screen = TScreenOf(xw); + Bool result = SPS.printer_checked; - return (strlen(SPS.printer_command) != 0); + if (strlen(SPS.printer_command) != 0 && !result) { + char **argv = x_splitargs(SPS.printer_command); + if (argv) { + if (argv[0]) { + char *myShell = xtermFindShell(argv[0], False); + if (myShell == 0) { + xtermWarning("No program found for printerCommand: %s\n", SPS.printer_command); + SPS.printer_command = x_strdup(""); + } else { + free(myShell); + SPS.printer_checked = True; + result = True; + } + } + x_freeargs(argv); + } + TRACE(("xtermHasPrinter:%d\n", result)); + } + + return result; } #define showPrinterControlMode(mode) \ diff -Nru xterm-278/proto.h xterm-297/proto.h --- xterm-278/proto.h 2003-10-27 01:07:57.000000000 +0000 +++ xterm-297/proto.h 1970-01-01 00:00:00.000000000 +0000 @@ -1,62 +0,0 @@ -/* - * $XTermId: proto.h,v 1.10 2003/10/27 01:07:57 tom Exp $ - * ---------------------------------------------------------------------------- - * this file is part of xterm - * - * Copyright 1996-2008,2003 by Thomas E. Dickey - * - * 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. - * ---------------------------------------------------------------------------- - */ - -#ifndef included_proto_h -#define included_proto_h - -#define PROTO_XT_ACTIONS_ARGS \ - (Widget w, XEvent *event, String *params, Cardinal *num_params) - -#define PROTO_XT_CALLBACK_ARGS \ - (Widget gw, XtPointer closure, XtPointer data) - -#define PROTO_XT_CVT_SELECT_ARGS \ - (Widget w, Atom *selection, Atom *target, Atom *type, XtPointer *value, unsigned long *length, int *format) - -#define PROTO_XT_EV_HANDLER_ARGS \ - (Widget w, XtPointer closure, XEvent *event, Boolean *cont) - -#define PROTO_XT_SEL_CB_ARGS \ - (Widget w, XtPointer client_data, Atom *selection, Atom *type, XtPointer value, unsigned long *length, int *format) - -#ifdef SIGNALRETURNSINT -#define SIGNAL_T int -#define SIGNAL_RETURN return 0 -#else -#define SIGNAL_T void -#define SIGNAL_RETURN return -#endif - -#endif/*included_proto_h*/ diff -Nru xterm-278/ptydata.c xterm-297/ptydata.c --- xterm-278/ptydata.c 2011-09-11 14:59:38.000000000 +0000 +++ xterm-297/ptydata.c 2013-02-03 23:17:07.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: ptydata.c,v 1.101 2011/09/11 14:59:38 tom Exp $ */ +/* $XTermId: ptydata.c,v 1.103 2013/02/03 23:17:07 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2011,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -203,7 +203,7 @@ */ if (size <= 0) { if (save_err == EIO || save_err == 0) - Cleanup(0); + NormalExit(); else if (!E_TEST(save_err)) Panic("input: read returned unexpected error (%d)\n", save_err); size = 0; @@ -211,13 +211,13 @@ #else /* !f*ugly */ if (size < 0) { if (save_err == EIO) - Cleanup(0); + NormalExit(); else if (!E_TEST(save_err)) Panic("input: read returned unexpected error (%d)\n", save_err); size = 0; } else if (size == 0) { -#if defined(__UNIXOS2__) || defined(__FreeBSD__) - Cleanup(0); +#if defined(__FreeBSD__) + NormalExit(); #else Panic("input: read returned zero\n", 0); #endif diff -Nru xterm-278/ptyx.h xterm-297/ptyx.h --- xterm-278/ptyx.h 2012-01-05 23:58:19.000000000 +0000 +++ xterm-297/ptyx.h 2013-09-10 18:10:00.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: ptyx.h,v 1.720 2012/01/05 23:58:19 tom Exp $ */ +/* $XTermId: ptyx.h,v 1.788 2013/09/10 18:10:00 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -67,7 +67,11 @@ #include /* for XtNdieCallback, etc. */ #include /* for standard resource names */ #include /* For Max() and Min(). */ + +#undef bcopy +#undef bzero #include + #include #include #ifdef XRENDERFONT @@ -227,11 +231,7 @@ #ifdef __hpux #define PTYCHAR1 "zyxwvutsrqp" #else /* !__hpux */ -#ifdef __UNIXOS2__ -#define PTYCHAR1 "pq" -#else #define PTYCHAR1 "pqrstuvwxyzPQRSTUVWXYZ" -#endif /* !__UNIXOS2__ */ #endif /* !__hpux */ #endif /* !PTYCHAR1 */ @@ -316,7 +316,7 @@ #define IsEmpty(s) ((s) == 0 || *(s) == '\0') -#define CharOf(n) ((unsigned char)(n)) +#define CharOf(n) ((Char)(n)) typedef struct { int row; @@ -361,10 +361,10 @@ #define ANSI_APC 0x9F #define MIN_DECID 52 /* can emulate VT52 */ -#define MAX_DECID 420 /* ...through VT420 */ +#define MAX_DECID 525 /* ...through VT525 */ #ifndef DFT_DECID -#define DFT_DECID "vt100" /* default VT100 */ +#define DFT_DECID "vt420" /* default VT420 */ #endif #ifndef DFT_KBD_DIALECT @@ -387,15 +387,24 @@ String desc; } OptionHelp; +typedef struct { + int count; /* number of values in params[] */ + int has_subparams; /* true if there are any sub's */ + int is_sub[NPARAM]; /* true for subparam */ + int params[NPARAM]; /* parameter value */ +} PARAMS; + typedef short ParmType; typedef struct { Char a_type; /* CSI, etc., see unparseq() */ Char a_pintro; /* private-mode char, if any */ + const char * a_delim; /* between parameters (;) */ Char a_inters; /* special (before final-char) */ Char a_final; /* final-char */ ParmType a_nparam; /* # of parameters */ ParmType a_param[NPARAM]; /* Parameters */ + Char a_radix[NPARAM]; /* Parameters */ } ANSI; #define TEK_FONT_LARGE 0 @@ -460,6 +469,10 @@ #define OPT_BOX_CHARS 1 /* true if xterm can simulate box-characters */ #endif +#ifndef OPT_BUILTIN_XPMS +#define OPT_BUILTIN_XPMS 0 /* true if all xpm data is compiled-in */ +#endif + #ifndef OPT_BROKEN_OSC #ifdef linux #define OPT_BROKEN_OSC 1 /* man console_codes, 1st paragraph - cf: ECMA-48 */ @@ -504,10 +517,18 @@ #define OPT_DEC_RECTOPS 0 /* true if xterm is configured for VT420 rectangles */ #endif +#ifndef OPT_SIXEL_GRAPHICS +#define OPT_SIXEL_GRAPHICS 0 /* true if xterm supports VT220-style sixel graphics */ +#endif + #ifndef OPT_DEC_SOFTFONT #define OPT_DEC_SOFTFONT 0 /* true if xterm is configured for VT220 softfonts */ #endif +#ifndef OPT_DOUBLE_BUFFER +#define OPT_DOUBLE_BUFFER 0 /* true if using double-buffering */ +#endif + #ifndef OPT_EBCDIC #ifdef __MVS__ #define OPT_EBCDIC 1 @@ -845,13 +866,17 @@ , MOUSE_FG /* mouse foreground */ , MOUSE_BG /* mouse background */ #if OPT_TEK4014 - , TEK_FG /* tektronix foreground */ + , TEK_FG = 5 /* tektronix foreground */ , TEK_BG /* tektronix background */ - , TEK_CURSOR /* tektronix cursor */ #endif #if OPT_HIGHLIGHT_COLOR - , HIGHLIGHT_BG /* highlight background */ - , HIGHLIGHT_FG /* highlight foreground */ + , HIGHLIGHT_BG = 7 /* highlight background */ +#endif +#if OPT_TEK4014 + , TEK_CURSOR = 8 /* tektronix cursor */ +#endif +#if OPT_HIGHLIGHT_COLOR + , HIGHLIGHT_FG = 9 /* highlight foreground */ #endif , NCOLORS /* total number of colors */ } TermColors; @@ -870,6 +895,160 @@ #define IsTitleMode(xw,mode) (((xw)->screen.title_modes & mode) != 0) +#include + +/* + * For readability... + */ +#define nrc_percent 100 +#define nrc_dquote 200 +#define nrc_ampersand 300 +typedef enum { + nrc_ASCII = 0 + ,nrc_British /* vt100 */ + ,nrc_British_Latin_1 /* vt3xx */ + ,nrc_Cyrillic /* vt5xx */ + ,nrc_DEC_Spec_Graphic /* vt100 */ + ,nrc_DEC_Alt_Chars /* vt100 */ + ,nrc_DEC_Alt_Graphics /* vt100 */ + ,nrc_DEC_Supp /* vt2xx */ + ,nrc_DEC_Supp_Graphic /* vt3xx */ + ,nrc_DEC_Technical /* vt3xx */ + ,nrc_Dutch /* vt2xx */ + ,nrc_Finnish /* vt2xx */ + ,nrc_Finnish2 /* vt2xx */ + ,nrc_French /* vt2xx */ + ,nrc_French2 /* vt2xx */ + ,nrc_French_Canadian /* vt2xx */ + ,nrc_French_Canadian2 /* vt3xx */ + ,nrc_German /* vt2xx */ + ,nrc_Greek /* vt5xx */ + ,nrc_Greek_Supp /* vt5xx */ + ,nrc_Hebrew /* vt5xx */ + ,nrc_Hebrew2 /* vt5xx */ + ,nrc_Hebrew_Supp /* vt5xx */ + ,nrc_Italian /* vt2xx */ + ,nrc_Latin_5_Supp /* vt5xx */ + ,nrc_Latin_Cyrillic /* vt5xx */ + ,nrc_Norwegian_Danish /* vt3xx */ + ,nrc_Norwegian_Danish2 /* vt2xx */ + ,nrc_Norwegian_Danish3 /* vt2xx */ + ,nrc_Portugese /* vt3xx */ + ,nrc_Russian /* vt5xx */ + ,nrc_SCS_NRCS /* vt5xx - probably Serbo/Croatian */ + ,nrc_Spanish /* vt2xx */ + ,nrc_Swedish /* vt2xx */ + ,nrc_Swedish2 /* vt2xx */ + ,nrc_Swiss /* vt2xx */ + ,nrc_Turkish /* vt5xx */ + ,nrc_Turkish2 /* vt5xx */ + ,nrc_Unknown +} DECNRCM_codes; + +/* + * Use this enumerated type to check consistency among dpmodes(), savemodes() + * restoremodes() and do_decrpm(). + */ +typedef enum { + srm_DECCKM = 1 + ,srm_DECANM = 2 + ,srm_DECCOLM = 3 + ,srm_DECSCLM = 4 + ,srm_DECSCNM = 5 + ,srm_DECOM = 6 + ,srm_DECAWM = 7 + ,srm_DECARM = 8 + ,srm_X10_MOUSE = SET_X10_MOUSE +#if OPT_TOOLBAR + ,srm_RXVT_TOOLBAR = 10 +#endif +#if OPT_BLINK_CURS + ,srm_ATT610_BLINK = 12 +#endif + ,srm_DECPFF = 18 + ,srm_DECPEX = 19 + ,srm_DECTCEM = 25 + ,srm_RXVT_SCROLLBAR = 30 +#if OPT_SHIFT_FONTS + ,srm_RXVT_FONTSIZE = 35 +#endif +#if OPT_TEK4014 + ,srm_DECTEK = 38 +#endif + ,srm_132COLS = 40 + ,srm_CURSES_HACK = 41 + ,srm_DECNRCM = 42 + ,srm_MARGIN_BELL = 44 + ,srm_REVERSEWRAP = 45 +#ifdef ALLOWLOGGING + ,srm_ALLOWLOGGING = 46 +#endif + ,srm_OPT_ALTBUF_CURSOR = 1049 + ,srm_OPT_ALTBUF = 1047 + ,srm_ALTBUF = 47 + ,srm_DECNKM = 66 + ,srm_DECBKM = 67 + ,srm_DECLRMM = 69 +#if OPT_SIXEL_GRAPHICS + ,srm_DECSDM = 80 /* Sixel Display Mode */ +#endif + ,srm_DECNCSM = 95 + ,srm_VT200_MOUSE = SET_VT200_MOUSE + ,srm_VT200_HIGHLIGHT_MOUSE = SET_VT200_HIGHLIGHT_MOUSE + ,srm_BTN_EVENT_MOUSE = SET_BTN_EVENT_MOUSE + ,srm_ANY_EVENT_MOUSE = SET_ANY_EVENT_MOUSE +#if OPT_FOCUS_EVENT + ,srm_FOCUS_EVENT_MOUSE = SET_FOCUS_EVENT_MOUSE +#endif + ,srm_EXT_MODE_MOUSE = SET_EXT_MODE_MOUSE + ,srm_SGR_EXT_MODE_MOUSE = SET_SGR_EXT_MODE_MOUSE + ,srm_URXVT_EXT_MODE_MOUSE = SET_URXVT_EXT_MODE_MOUSE + ,srm_ALTERNATE_SCROLL = SET_ALTERNATE_SCROLL + ,srm_RXVT_SCROLL_TTY_OUTPUT = 1010 + ,srm_RXVT_SCROLL_TTY_KEYPRESS = 1011 + ,srm_EIGHT_BIT_META = 1034 +#if OPT_NUM_LOCK + ,srm_REAL_NUMLOCK = 1035 + ,srm_META_SENDS_ESC = 1036 +#endif + ,srm_DELETE_IS_DEL = 1037 +#if OPT_NUM_LOCK + ,srm_ALT_SENDS_ESC = 1039 +#endif + ,srm_KEEP_SELECTION = 1040 + ,srm_SELECT_TO_CLIPBOARD = 1041 + ,srm_BELL_IS_URGENT = 1042 + ,srm_POP_ON_BELL = 1043 + ,srm_TITE_INHIBIT = 1048 +#if OPT_TCAP_FKEYS + ,srm_TCAP_FKEYS = 1050 +#endif +#if OPT_SUN_FUNC_KEYS + ,srm_SUN_FKEYS = 1051 +#endif +#if OPT_HP_FUNC_KEYS + ,srm_HP_FKEYS = 1052 +#endif +#if OPT_SCO_FUNC_KEYS + ,srm_SCO_FKEYS = 1053 +#endif + ,srm_LEGACY_FKEYS = 1060 +#if OPT_SUNPC_KBD + ,srm_VT220_FKEYS = 1061 +#endif +#if OPT_SIXEL_GRAPHICS + ,srm_PRIVATE_COLOR_REGISTERS = 1070 +#endif +#if OPT_READLINE + ,srm_BUTTON1_MOVE_POINT = SET_BUTTON1_MOVE_POINT + ,srm_BUTTON2_MOVE_POINT = SET_BUTTON2_MOVE_POINT + ,srm_DBUTTON3_DELETE = SET_DBUTTON3_DELETE + ,srm_PASTE_IN_BRACKET = SET_PASTE_IN_BRACKET + ,srm_PASTE_QUOTE = SET_PASTE_QUOTE + ,srm_PASTE_LITERAL_NL = SET_PASTE_LITERAL_NL +#endif /* OPT_READLINE */ +} DECSET_codes; + /* indices for mapping multiple clicks to selection types */ typedef enum { Select_CHAR=0 @@ -904,6 +1083,15 @@ , esNever } FullscreenOps; +#ifndef NO_ACTIVE_ICON +typedef enum { + eiFalse = 0 + , eiTrue + , eiDefault + , eiLAST +} AIconOps; +#endif + typedef enum { etSetTcap = 1 , etGetTcap @@ -911,7 +1099,7 @@ } TcapOps; typedef enum { - /* 1-21 are chosen to be the same as the control-sequence coding */ + /* 1-23 are chosen to be the same as the control-sequence coding */ ewRestoreWin = 1 , ewMinimizeWin = 2 , ewSetWinPosition = 3 @@ -1334,18 +1522,20 @@ * of widths. */ typedef struct { - Bool mixed; + Bool mixed; Dimension min_width; /* nominal cell width for 0..255 */ Dimension max_width; /* maximum cell width */ } FontMap; +#define KNOWN_MISSING 256 + typedef struct { unsigned chrset; unsigned flags; XFontStruct * fs; char * fn; FontMap map; - Char known_missing[256]; + Char known_missing[KNOWN_MISSING]; } XTermFonts; #if OPT_RENDERFONT @@ -1357,8 +1547,8 @@ } RenderFont; #define DefaultRenderFont(xw) \ - if ((xw)->misc.render_font == erDefault) \ - (xw)->misc.render_font = erFalse + if ((xw)->work.render_font == erDefault) \ + (xw)->work.render_font = erFalse typedef struct { XftFont * font; @@ -1375,6 +1565,9 @@ /* indices into save_modes[] */ typedef enum { + DP_ALTERNATE_SCROLL, + DP_ALT_SENDS_ESC, + DP_BELL_IS_URGENT, DP_CRS_VISIBLE, DP_DECANM, DP_DECARM, @@ -1382,22 +1575,34 @@ DP_DECBKM, DP_DECCKM, DP_DECCOLM, /* IN132COLUMNS */ + DP_DECKPAM, + DP_DECNRCM, DP_DECOM, DP_DECPEX, DP_DECPFF, DP_DECSCLM, DP_DECSCNM, DP_DECTCEM, - DP_DECTEK, + DP_DELETE_IS_DEL, + DP_EIGHT_BIT_META, + DP_KEEP_SELECTION, + DP_KEYBOARD_TYPE, + DP_POP_ON_BELL, DP_PRN_EXTENT, DP_PRN_FORMFEED, + DP_RXVT_SCROLLBAR, + DP_RXVT_SCROLL_TTY_KEYPRESS, + DP_RXVT_SCROLL_TTY_OUTPUT, + DP_SELECT_TO_CLIPBOARD, DP_X_ALTSCRN, DP_X_DECCOLM, + DP_X_EXT_MOUSE, DP_X_LOGGING, + DP_X_LRMM, DP_X_MARGIN, DP_X_MORE, DP_X_MOUSE, - DP_X_EXT_MOUSE, + DP_X_NCSM, DP_X_REVWRAP, DP_X_X10MSE, #if OPT_BLINK_CURS @@ -1406,9 +1611,23 @@ #if OPT_FOCUS_EVENT DP_X_FOCUS, #endif +#if OPT_NUM_LOCK + DP_REAL_NUMLOCK, + DP_META_SENDS_ESC, +#endif +#if OPT_SHIFT_FONTS + DP_RXVT_FONTSIZE, +#endif +#if OPT_SIXEL_GRAPHICS + DP_DECSDM, +#endif +#if OPT_TEK4014 + DP_DECTEK, +#endif #if OPT_TOOLBAR DP_TOOLBAR, #endif + DP_X_PRIVATE_COLOR_REGISTERS, DP_LAST } SaveModes; @@ -1439,6 +1658,7 @@ typedef struct { String resource; Pixel value; + unsigned short red, green, blue; int mode; /* -1=invalid, 0=unset, 1=set */ } ColorRes; #else @@ -1458,6 +1678,7 @@ FILE * fp; /* output file/pipe used */ Boolean isOpen; /* output was opened/tried */ Boolean toFile; /* true when directly to file */ + Boolean printer_checked; /* printer_command is checked */ String printer_command; /* pipe/shell command string */ Boolean printer_autoclose; /* close printer when offline */ Boolean printer_extent; /* print complete page */ @@ -1481,7 +1702,7 @@ unsigned flags; /* VTxxx saves graphics rendition */ Char curgl; Char curgr; - Char gsets[4]; + int gsets[4]; #if OPT_ISO_COLORS int cur_foreground; /* current foreground color */ int cur_background; /* current background color */ @@ -1492,7 +1713,7 @@ } SavedCursor; typedef struct _SaveTitle { - struct _SaveTitle *next; + struct _SaveTitle *next; char *iconName; char *windowName; } SaveTitle; @@ -1530,6 +1751,9 @@ int f_ascent; /* ascent of font in pixels */ int f_descent; /* descent of font in pixels */ SbInfo sb_info; +#if OPT_DOUBLE_BUFFER + Drawable drawable; /* X drawable id */ +#endif #if OPT_TOOLBAR Boolean active; /* true if toolbars are used */ TbInfo tb_info; /* toolbar information */ @@ -1568,6 +1792,26 @@ } TInput; #endif +typedef enum { + CURSOR_BLOCK = 2 + , CURSOR_UNDERLINE = 4 + , CURSOR_BAR = 6 +} XtCursorShape; + +#define isCursorBlock(s) ((s)->cursor_shape == CURSOR_BLOCK) +#define isCursorUnderline(s) ((s)->cursor_shape == CURSOR_UNDERLINE) +#define isCursorBar(s) ((s)->cursor_shape == CURSOR_BAR) + +typedef enum { + DEFAULT_STYLE = 0 + , BLINK_BLOCK + , STEADY_BLOCK + , BLINK_UNDERLINE + , STEADY_UNDERLINE + , BLINK_BAR + , STEADY_BAR +} XtCursorStyle; + typedef struct { /* These parameters apply to both windows */ Display *display; /* X display for screen */ @@ -1617,8 +1861,10 @@ Boolean wide_chars; /* true when 16-bit chars */ Boolean vt100_graphics; /* true to allow vt100-graphics */ Boolean utf8_inparse; /* true to enable UTF-8 parser */ + Boolean normalized_c; /* true to precompose to Form C */ char * utf8_mode_s; /* use UTF-8 decode/encode */ char * utf8_fonts_s; /* use UTF-8 decode/encode */ + int utf8_nrc_mode; /* saved UTF-8 mode for DECNRCM */ int utf8_mode; /* use UTF-8 decode/encode: 0-2 */ int utf8_fonts; /* use UTF-8 decode/encode: 0-2 */ int max_combining; /* maximum # of combining chars */ @@ -1628,6 +1874,7 @@ int unicode_font; /* font uses unicode encoding */ int utf_count; /* state of utf_char */ IChar utf_char; /* in-progress character */ + Boolean char_was_written; int last_written_col; int last_written_row; TypedBuffer(XChar2b); @@ -1688,6 +1935,7 @@ Boolean visualbell; /* visual bell mode */ Boolean poponbell; /* pop on bell mode */ + Boolean allowPasteControls; /* PasteControls mode */ Boolean allowColorOps; /* ColorOps mode */ Boolean allowFontOps; /* FontOps mode */ Boolean allowSendEvents;/* SendEvent mode */ @@ -1716,9 +1964,6 @@ Boolean awaitInput; /* select-timeout mode */ Boolean grabbedKbd; /* keyboard is grabbed */ -#if OPT_MAXIMIZE - Boolean fullscreen; /* window is fullscreen */ -#endif #ifdef ALLOWLOGGING int logging; /* logging mode */ int logfd; /* file descriptor of log */ @@ -1730,6 +1975,7 @@ /* VT window parameters */ Boolean Vshow; /* VT window showing */ VTwin fullVwin; + int needSwap; #ifndef NO_ACTIVE_ICON VTwin iconVwin; VTwin *whichVwin; @@ -1752,8 +1998,9 @@ Boolean fnt_boxes; /* true if font has box-chars */ Boolean force_packed; /* true to override proportional */ #if OPT_BOX_CHARS - Boolean force_box_chars;/* true if we assume that */ + Boolean force_box_chars;/* true if we assume no boxchars */ Boolean force_all_chars;/* true to outline missing chars */ + Boolean assume_all_chars;/* true to allow missing chars */ Boolean allow_packing; /* true to allow packed-fonts */ #endif Dimension fnt_wide; @@ -1773,6 +2020,7 @@ int cursor_state; /* ON, OFF, or BLINKED_OFF */ int cursor_busy; /* do not redraw... */ Boolean cursor_underline; /* true if cursor is in underline mode */ + XtCursorShape cursor_shape; #if OPT_BLINK_CURS Boolean cursor_blink; /* cursor blink enable */ Boolean cursor_blink_res; /* initial cursor blink value */ @@ -1799,6 +2047,8 @@ int max_row; /* bottom row */ int top_marg; /* top line of scrolling region */ int bot_marg; /* bottom line of " " */ + int lft_marg; /* left column of " " */ + int rgt_marg; /* right column of " " */ Widget scrollWidget; /* pointer to scrollbar struct */ /* * Indices used to keep track of the top of the vt100 window and @@ -1838,6 +2088,7 @@ size_t save_len; /* ...and its length */ int scrolllines; /* number of lines to button scroll */ + Boolean alternateScroll; /* scroll-actions become keys */ Boolean scrollttyoutput; /* scroll to bottom on tty output */ Boolean scrollkey; /* scroll to bottom on key */ Boolean cursor_moved; /* scrolling makes cursor move */ @@ -1870,21 +2121,21 @@ int scrolls; /* outstanding scroll count, used only with multiscroll */ SavedCursor sc[SAVED_CURSORS]; /* data for restore cursor */ - unsigned save_modes[DP_LAST]; /* save dec/xterm private modes */ + unsigned int save_modes[DP_LAST]; /* save dec/xterm private modes */ int title_modes; /* control set/get of titles */ SaveTitle *save_title; /* Improved VT100 emulation stuff. */ String keyboard_dialect; /* default keyboard dialect */ - Char gsets[4]; /* G0 through G3. */ + int gsets[4]; /* G0 through G3. */ Char curgl; /* Current GL setting. */ Char curgr; /* Current GR setting. */ Char curss; /* Current single shift. */ String term_id; /* resource for terminal_id */ int terminal_id; /* 100=vt100, 220=vt220, etc. */ int vtXX_level; /* 0=vt52, 1,2,3 = vt100 ... vt320 */ - int ansi_level; /* levels 1,2,3 */ + int ansi_level; /* dpANSI levels 1,2,3 */ int protected_mode; /* 0=off, 1=DEC, 2=ISO */ Boolean always_bold_mode; /* compare normal/bold font */ Boolean always_highlight; /* whether to highlight cursor */ @@ -1910,12 +2161,16 @@ Boolean scroll_dirty; /* scrolling makes screen dirty */ #endif +#if OPT_SIXEL_GRAPHICS + Boolean sixel_scrolling; /* sixel scrolling */ + Boolean privatecolorregisters; /* private color registers for each graphic */ +#endif + #if OPT_VT52_MODE - int vt52_save_level; /* save-area for DECANM */ Char vt52_save_curgl; Char vt52_save_curgr; Char vt52_save_curss; - Char vt52_save_gsets[4]; + int vt52_save_gsets[4]; #endif /* Testing */ #if OPT_XMC_GLITCH @@ -2101,6 +2356,20 @@ #define SCREEN_FLAG(screenp,f) (0) #endif +/* + * After screen-updates, reset the flag that tells us we should do wrapping. + * Likewise, reset (in wide-character mode) the flag that tells us where the + * "previous" character was written. + */ +#if OPT_WIDE_CHARS +#define ResetWrap(screen) \ + (screen)->do_wrap = \ + (screen)->char_was_written = False +#else +#define ResetWrap(screen) \ + (screen)->do_wrap = False +#endif + /* meaning of bits in screen.select flag */ #define INWINDOW 01 /* the mouse is in one of the windows */ #define FOCUS 02 /* one of the windows is the focus window */ @@ -2129,9 +2398,10 @@ } xtermKeyboardType; typedef enum { /* legal values for screen.pointer_mode */ - pNever = 0, - pNoMouse = 1, - pAlways = 2 + pNever = 0 + , pNoMouse = 1 + , pAlways = 2 + , pFocused = 3 } pointerModeTypes; typedef enum { /* legal values for screen.utf8_mode */ @@ -2194,6 +2464,7 @@ typedef struct { + int allow_keys; /* how to handle legacy/vt220 keyboard */ int cursor_keys; /* how to handle cursor-key modifiers */ int function_keys; /* how to handle function-key modifiers */ int keypad_keys; /* how to handle keypad key-modifiers */ @@ -2243,6 +2514,7 @@ Boolean log_on; #endif Boolean login_shell; + Boolean palette_changed; Boolean re_verse; Boolean re_verse0; /* initial value of "-rv" */ XtGravity resizeGravity; @@ -2261,7 +2533,8 @@ Boolean useRight; #endif Boolean titeInhibit; - Boolean tiXtraScroll; + Boolean tiXtraScroll; /* scroll on ti/te */ + Boolean cdXtraScroll; /* scroll on cd (clear-display) */ Boolean appcursorDefault; Boolean appkeypadDefault; #if OPT_INPUT_METHOD @@ -2276,9 +2549,8 @@ TInput inputs[NINPUTWIDGETS]; #endif Boolean dynamicColors; - Boolean shared_ic; #ifndef NO_ACTIVE_ICON - Boolean active_icon; /* use application icon window */ + char *active_icon_s; /* use application icon window */ unsigned icon_border_width; Pixel icon_border_pixel; #endif /* NO_ACTIVE_ICON */ @@ -2294,20 +2566,39 @@ #if OPT_NUM_LOCK Boolean real_NumLock; /* true if we treat NumLock key specially */ Boolean alwaysUseMods; /* true if we always want f-key modifiers */ - unsigned num_lock; /* modifier for Num_Lock */ - unsigned alt_mods; /* modifier for Alt_L or Alt_R */ - unsigned meta_mods; /* modifier for Meta_L or Meta_R */ - unsigned other_mods; /* conflicting modifiers, e.g., Mode_Switch */ #endif #if OPT_RENDERFONT char *face_name; char *face_wide_name; float face_size[NMENUFONTS]; char *render_font_s; - Boolean render_font; #endif } Misc; +typedef struct _Work { + int dummy; +#ifndef NO_ACTIVE_ICON + int active_icon; /* use application icon window */ +#endif /* NO_ACTIVE_ICON */ +#if OPT_MAXIMIZE +#define MAX_EWMH_MODE 3 +#define MAX_EWMH_DATA (1 + OPT_TEK4014) + struct { + int mode; /* fullscreen, etc. */ + Boolean checked[MAX_EWMH_MODE]; + Boolean allowed[MAX_EWMH_MODE]; + } ewmh[MAX_EWMH_DATA]; +#endif +#if OPT_NUM_LOCK + unsigned num_lock; /* modifier for Num_Lock */ + unsigned alt_mods; /* modifier for Alt_L or Alt_R */ + unsigned meta_mods; /* modifier for Meta_L or Meta_R */ +#endif +#if OPT_RENDERFONT + Boolean render_font; +#endif +} Work; + typedef struct {int foo;} XtermClassPart, TekClassPart; typedef struct _XtermClassRec { @@ -2332,11 +2623,12 @@ #endif /* define masks for keyboard.flags */ -#define MODE_KAM xBIT(0) /* keyboard action mode */ +#define MODE_KAM xBIT(0) /* mode 2: keyboard action mode */ #define MODE_DECKPAM xBIT(1) /* keypad application mode */ -#define MODE_DECCKM xBIT(2) /* cursor keys */ -#define MODE_SRM xBIT(3) /* send-receive mode */ -#define MODE_DECBKM xBIT(4) /* backarrow */ +#define MODE_DECCKM xBIT(2) /* private mode 1: cursor keys */ +#define MODE_SRM xBIT(3) /* mode 12: send-receive mode */ +#define MODE_DECBKM xBIT(4) /* private mode 67: backarrow */ +#define MODE_DECSDM xBIT(5) /* private mode 80: sixel scrolling mode */ #define N_MARGINBELL 10 @@ -2369,6 +2661,7 @@ unsigned initflags; /* initial mode flags */ Tabs tabs; /* tabstops of the terminal */ Misc misc; /* miscellaneous parameters */ + Work work; /* workspace (no resources) */ } XtermWidgetRec, *XtermWidget; #if OPT_TEK4014 @@ -2433,6 +2726,8 @@ #define IN132COLUMNS MiscBIT(7) /* true if in 132 column mode */ #define INVISIBLE MiscBIT(8) /* true if writing invisible text */ #define NATIONAL MiscBIT(9) /* true if writing national charset */ +#define LEFT_RIGHT MiscBIT(10) /* true if left/right margin mode */ +#define NOCLEAR_COLM MiscBIT(11) /* true if no clear on DECCOLM change */ /* * Groups of attributes @@ -2507,9 +2802,10 @@ ((screen)->cursorp.col != (screen)->cur_col || \ (screen)->cursorp.row != (screen)->cur_row)) -#define CursorX(screen,col) ((col) * FontWidth(screen) + OriginX(screen)) -#define CursorY(screen,row) ((INX2ROW(screen, row) * FontHeight(screen)) \ - + screen->border) +#define CursorX2(screen,col,fw) ((col) * (int)(fw) + OriginX(screen)) +#define CursorX(screen,col) CursorX2(screen, col, FontWidth(screen)) +#define CursorY2(screen,row) (((row) * FontHeight(screen)) + screen->border) +#define CursorY(screen,row) CursorY2(screen, INX2ROW(screen, row)) /* * These definitions depend on whether xterm supports active-icon. @@ -2544,7 +2840,7 @@ /* * Macro to check if we are iconified; do not use render for that case. */ -#define UsingRenderFont(xw) (((xw)->misc.render_font == True) && !IsIcon(TScreenOf(xw))) +#define UsingRenderFont(xw) (((xw)->work.render_font == True) && !IsIcon(TScreenOf(xw))) /* * These definitions do not depend on whether xterm supports active-icon. @@ -2554,6 +2850,12 @@ #define TWindow(screen) WhichTWin(screen)->window #define TShellWindow XtWindow(SHELL_OF(tekWidget)) +#if OPT_DOUBLE_BUFFER +#define VDrawable(screen) (((screen)->needSwap=1), WhichVWin(screen)->drawable) +#else +#define VDrawable(screen) VWindow(screen) +#endif + #define Width(screen) WhichVWin(screen)->width #define Height(screen) WhichVWin(screen)->height #define FullWidth(screen) WhichVWin(screen)->fullwidth @@ -2598,8 +2900,9 @@ #define AllowTitleOps(w) AllowXtermOps(w, allowTitleOps) +#define SpecialWindowOps(w,name) (!TScreenOf(w)->disallow_win_ops[name]) #define AllowWindowOps(w,name) (AllowXtermOps(w, allowWindowOps) || \ - !TScreenOf(w)->disallow_win_ops[name]) + SpecialWindowOps(w,name)) #if OPT_TOOLBAR #define ToolbarHeight(w) ((resource.toolBar) \ @@ -2702,6 +3005,18 @@ #define TRACE2(p) /*nothing*/ #endif +#if OPT_TRACE && !defined(DEBUG) +#define DEBUG 1 +#endif + +#ifdef DEBUG +#define if_DEBUG(code) if(debug) code +#else +#define if_DEBUG(code) /*nothing*/ +#endif + +#define DEBUG_MSG(text) if_DEBUG({ IGNORE_RC(write(2, text, sizeof(text) - 1)); }) + /* *INDENT-ON* */ #endif /* included_ptyx_h */ diff -Nru xterm-278/resize.c xterm-297/resize.c --- xterm-278/resize.c 2011-09-11 20:19:19.000000000 +0000 +++ xterm-297/resize.c 2013-01-06 19:42:20.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: resize.c,v 1.118 2011/09/11 20:19:19 tom Exp $ */ +/* $XTermId: resize.c,v 1.129 2013/01/06 19:42:20 tom Exp $ */ /* - * Copyright 2003-2010,2011 by Thomas E. Dickey + * Copyright 2003-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -54,17 +54,15 @@ /* resize.c */ -#include #include #include + +#include +#include #include #include #include -#ifdef APOLLO_SR9 -#define CANT_OPEN_DEV_TTY -#endif - #ifndef USE_TERMINFO /* avoid conflict with configure script */ #if defined(__QNX__) || defined(__SCO__) || defined(linux) || defined(__OpenBSD__) || defined(__UNIXWARE__) #define USE_TERMINFO @@ -140,14 +138,13 @@ ESCAPE("7") ESCAPE("[r") ESCAPE("[999;999H") ESCAPE("[6n"), ESCAPE("[18t"), }; -#if defined(USE_STRUCT_TTYSIZE) -#elif defined(USE_STRUCT_WINSIZE) +#if defined(USE_STRUCT_WINSIZE) static const char *getwsize[EMULATIONS] = { /* size in pixels */ 0, ESCAPE("[14t"), }; -#endif /* USE_STRUCT_{TTYSIZE|WINSIZE} */ +#endif /* USE_STRUCT_WINSIZE */ static const char *restore[EMULATIONS] = { ESCAPE("8"), @@ -177,20 +174,54 @@ static int tty; static FILE *ttyfp; -#if defined(USE_STRUCT_TTYSIZE) -#elif defined(USE_STRUCT_WINSIZE) +#if defined(USE_STRUCT_WINSIZE) static const char *wsize[EMULATIONS] = { 0, ESCAPE("[4;%hd;%hdt"), }; -#endif /* USE_STRUCT_{TTYSIZE|WINSIZE} */ +#endif /* USE_STRUCT_WINSIZE */ -static SIGNAL_T onintr(int sig); -static SIGNAL_T resize_timeout(int sig); -static int checkdigits(char *str); -static void Usage(void); -static void readstring(FILE *fp, char *buf, const char *str); +static void +failed(const char *s) +{ + int save = errno; + IGNORE_RC(write(2, myname, strlen(myname))); + IGNORE_RC(write(2, ": ", (size_t) 2)); + errno = save; + perror(s); + exit(EXIT_FAILURE); +} + +/* ARGSUSED */ +static void +onintr(int sig GCC_UNUSED) +{ +#ifdef USE_ANY_SYSV_TERMIO + (void) ioctl(tty, TCSETAW, &tioorig); +#elif defined(USE_TERMIOS) + (void) tcsetattr(tty, TCSADRAIN, &tioorig); +#else /* not USE_TERMIOS */ + (void) ioctl(tty, TIOCSETP, &sgorig); +#endif /* USE_ANY_SYSV_TERMIO/USE_TERMIOS */ + exit(EXIT_FAILURE); +} + +static void +resize_timeout(int sig) +{ + fprintf(stderr, "\n%s: Time out occurred\r\n", myname); + onintr(sig); +} + +static void +Usage(void) +{ + fprintf(stderr, strcmp(myname, sunname) == 0 ? + "Usage: %s [rows cols]\n" : + "Usage: %s [-v] [-u] [-c] [-s [rows cols]]\n", myname); + exit(EXIT_FAILURE); +} #ifdef USE_TERMCAP static void @@ -218,6 +249,58 @@ } #endif /* USE_TERMCAP */ +static int +checkdigits(char *str) +{ + while (*str) { + if (!isdigit(CharOf(*str))) + return (0); + str++; + } + return (1); +} + +static void +readstring(FILE *fp, char *buf, const char *str) +{ + int last, c; +#if !defined(USG) + /* What is the advantage of setitimer() over alarm()? */ + struct itimerval it; +#endif + + signal(SIGALRM, resize_timeout); +#if defined(USG) + alarm(TIMEOUT); +#else + memset((char *) &it, 0, sizeof(struct itimerval)); + it.it_value.tv_sec = TIMEOUT; + setitimer(ITIMER_REAL, &it, (struct itimerval *) NULL); +#endif + if ((c = getc(fp)) == 0233) { /* meta-escape, CSI */ + c = ESCAPE("")[0]; + *buf++ = (char) c; + *buf++ = '['; + } else { + *buf++ = (char) c; + } + if (c != *str) { + fprintf(stderr, "%s: unknown character, exiting.\r\n", myname); + onintr(0); + } + last = str[strlen(str) - 1]; + while ((*buf++ = (char) getc(fp)) != last) { + ; + } +#if defined(USG) + alarm(0); +#else + memset((char *) &it, 0, sizeof(struct itimerval)); + setitimer(ITIMER_REAL, &it, (struct itimerval *) NULL); +#endif + *buf = 0; +} + /* resets termcap string to reflect current screen size */ @@ -231,6 +314,7 @@ int emu = VT100; char *shell; int i; + int rc; int rows, cols; #ifdef USE_ANY_SYSV_TERMIO struct termio tio; @@ -269,6 +353,9 @@ case 'c': /* C shell */ shell_type = SHELL_C; break; + case 'v': + printf("%s\n", xtermVersion()); + exit(EXIT_SUCCESS); default: Usage(); /* Never returns */ } @@ -295,9 +382,11 @@ shell = x_basename(ptr); /* now that we know, what kind is it? */ - for (i = 0; shell_list[i].name; i++) - if (!strcmp(shell_list[i].name, shell)) + for (i = 0; shell_list[i].name; i++) { + if (!strcmp(shell_list[i].name, shell)) { break; + } + } shell_type = shell_list[i].type; } @@ -306,13 +395,14 @@ fprintf(stderr, "%s: Can't set window size under %s emulation\n", myname, emuname[emu]); - exit(1); + exit(EXIT_FAILURE); } - if (!checkdigits(argv[0]) || !checkdigits(argv[1])) + if (!checkdigits(argv[0]) || !checkdigits(argv[1])) { Usage(); /* Never returns */ - } else if (argc != 0) + } + } else if (argc != 0) { Usage(); /* Never returns */ - + } #ifdef CANT_OPEN_DEV_TTY if ((name_of_tty = ttyname(fileno(stderr))) == NULL) #endif @@ -321,32 +411,35 @@ if ((ttyfp = fopen(name_of_tty, "r+")) == NULL) { fprintf(stderr, "%s: can't open terminal %s\n", myname, name_of_tty); - exit(1); + exit(EXIT_FAILURE); } tty = fileno(ttyfp); #ifdef USE_TERMCAP if ((env = x_getenv("TERM")) == 0) { env = DFT_TERMTYPE; - if (SHELL_BOURNE == shell_type) + if (SHELL_BOURNE == shell_type) { setname = "TERM=" DFT_TERMTYPE ";\nexport TERM;\n"; - else + } else { setname = "setenv TERM " DFT_TERMTYPE ";\n"; + } } termcap[0] = 0; /* ...just in case we've accidentally gotten terminfo */ - if (tgetent(termcap, env) <= 0 || termcap[0] == 0) + if (tgetent(termcap, env) <= 0 || termcap[0] == 0) { ok_tcap = 0; + } #endif /* USE_TERMCAP */ #ifdef USE_TERMINFO if (x_getenv("TERM") == 0) { - if (SHELL_BOURNE == shell_type) + if (SHELL_BOURNE == shell_type) { setname = "TERM=" DFT_TERMTYPE ";\nexport TERM;\n"; - else + } else { setname = "setenv TERM " DFT_TERMTYPE ";\n"; + } } #endif /* USE_TERMINFO */ #ifdef USE_ANY_SYSV_TERMIO - ioctl(tty, TCGETA, &tioorig); + rc = ioctl(tty, TCGETA, &tioorig); tio = tioorig; UIntClr(tio.c_iflag, (ICRNL | IUCLC)); UIntClr(tio.c_lflag, (ICANON | ECHO)); @@ -354,7 +447,7 @@ tio.c_cc[VMIN] = 6; tio.c_cc[VTIME] = 1; #elif defined(USE_TERMIOS) - tcgetattr(tty, &tioorig); + rc = tcgetattr(tty, &tioorig); tio = tioorig; UIntClr(tio.c_iflag, ICRNL); UIntClr(tio.c_lflag, (ICANON | ECHO)); @@ -362,23 +455,29 @@ tio.c_cc[VMIN] = 6; tio.c_cc[VTIME] = 1; #else /* not USE_TERMIOS */ - ioctl(tty, TIOCGETP, &sgorig); + rc = ioctl(tty, TIOCGETP, &sgorig); sg = sgorig; sg.sg_flags |= RAW; UIntClr(sg.sg_flags, ECHO); #endif /* USE_ANY_SYSV_TERMIO/USE_TERMIOS */ + if (rc != 0) + failed("get tty settings"); + signal(SIGINT, onintr); signal(SIGQUIT, onintr); signal(SIGTERM, onintr); + #ifdef USE_ANY_SYSV_TERMIO - ioctl(tty, TCSETAW, &tio); + rc = ioctl(tty, TCSETAW, &tio); #elif defined(USE_TERMIOS) - tcsetattr(tty, TCSADRAIN, &tio); + rc = tcsetattr(tty, TCSADRAIN, &tio); #else /* not USE_TERMIOS */ - ioctl(tty, TIOCSETP, &sg); + rc = ioctl(tty, TIOCSETP, &sg); #endif /* USE_ANY_SYSV_TERMIO/USE_TERMIOS */ + if (rc != 0) + failed("set tty settings"); - if (argc == 2) { + if (argc == 2) { /* look for optional parameters of "-s" */ char *tmpbuf = TypeMallocN(char, strlen(setsize[emu]) + strlen(argv[0]) + @@ -401,14 +500,7 @@ } if (restore[emu]) IGNORE_RC(write(tty, restore[emu], strlen(restore[emu]))); -#if defined(USE_STRUCT_TTYSIZE) - /* finally, set the tty's window size */ - if (ioctl(tty, TIOCGSIZE, &ts) != -1) { - TTYSIZE_ROWS(ts) = rows; - TTYSIZE_COLS(ts) = cols; - SET_TTYSIZE(tty, ts); - } -#elif defined(USE_STRUCT_WINSIZE) +#if defined(USE_STRUCT_WINSIZE) /* finally, set the tty's window size */ if (getwsize[emu]) { /* get the window size in pixels */ @@ -434,15 +526,18 @@ TTYSIZE_COLS(ts) = (ttySize_t) cols; SET_TTYSIZE(tty, ts); } -#endif /* USE_STRUCT_{TTYSIZE|WINSIZE} */ +#endif /* USE_STRUCT_WINSIZE */ #ifdef USE_ANY_SYSV_TERMIO - ioctl(tty, TCSETAW, &tioorig); + rc = ioctl(tty, TCSETAW, &tioorig); #elif defined(USE_TERMIOS) - tcsetattr(tty, TCSADRAIN, &tioorig); + rc = tcsetattr(tty, TCSADRAIN, &tioorig); #else /* not USE_TERMIOS */ - ioctl(tty, TIOCSETP, &sgorig); + rc = ioctl(tty, TIOCSETP, &sgorig); #endif /* USE_ANY_SYSV_TERMIO/USE_TERMIOS */ + if (rc != 0) + failed("set tty settings"); + signal(SIGINT, SIG_DFL); signal(SIGQUIT, SIG_DFL); signal(SIGTERM, SIG_DFL); @@ -453,7 +548,7 @@ /* first do columns */ if ((ptr = x_strindex(termcap, "co#")) == NULL) { fprintf(stderr, "%s: No `co#'\n", myname); - exit(1); + exit(EXIT_FAILURE); } i = ptr - termcap + 3; @@ -465,7 +560,7 @@ /* now do lines */ if ((ptr = x_strindex(newtc, "li#")) == NULL) { fprintf(stderr, "%s: No `li#'\n", myname); - exit(1); + exit(EXIT_FAILURE); } i = ptr - newtc + 3; @@ -504,87 +599,5 @@ setname, cols, rows); #endif /* USE_TERMINFO */ } - exit(0); -} - -static int -checkdigits(char *str) -{ - while (*str) { - if (!isdigit(CharOf(*str))) - return (0); - str++; - } - return (1); -} - -static void -readstring(FILE *fp, char *buf, const char *str) -{ - int last, c; -#if !defined(USG) && !defined(__UNIXOS2__) - /* What is the advantage of setitimer() over alarm()? */ - struct itimerval it; -#endif - - signal(SIGALRM, resize_timeout); -#if defined(USG) || defined(__UNIXOS2__) - alarm(TIMEOUT); -#else - memset((char *) &it, 0, sizeof(struct itimerval)); - it.it_value.tv_sec = TIMEOUT; - setitimer(ITIMER_REAL, &it, (struct itimerval *) NULL); -#endif - if ((c = getc(fp)) == 0233) { /* meta-escape, CSI */ - c = ESCAPE("")[0]; - *buf++ = (char) c; - *buf++ = '['; - } else { - *buf++ = (char) c; - } - if (c != *str) { - fprintf(stderr, "%s: unknown character, exiting.\r\n", myname); - onintr(0); - } - last = str[strlen(str) - 1]; - while ((*buf++ = (char) getc(fp)) != last) { - ; - } -#if defined(USG) || defined(__UNIXOS2__) - alarm(0); -#else - memset((char *) &it, 0, sizeof(struct itimerval)); - setitimer(ITIMER_REAL, &it, (struct itimerval *) NULL); -#endif - *buf = 0; -} - -static void -Usage(void) -{ - fprintf(stderr, strcmp(myname, sunname) == 0 ? - "Usage: %s [rows cols]\n" : - "Usage: %s [-u] [-c] [-s [rows cols]]\n", myname); - exit(1); -} - -static SIGNAL_T -resize_timeout(int sig) -{ - fprintf(stderr, "\n%s: Time out occurred\r\n", myname); - onintr(sig); -} - -/* ARGSUSED */ -static SIGNAL_T -onintr(int sig GCC_UNUSED) -{ -#ifdef USE_ANY_SYSV_TERMIO - ioctl(tty, TCSETAW, &tioorig); -#elif defined(USE_TERMIOS) - tcsetattr(tty, TCSADRAIN, &tioorig); -#else /* not USE_TERMIOS */ - ioctl(tty, TIOCSETP, &sgorig); -#endif /* USE_ANY_SYSV_TERMIO/USE_TERMIOS */ - exit(1); + exit(EXIT_SUCCESS); } diff -Nru xterm-278/resize.man xterm-297/resize.man --- xterm-278/resize.man 2011-09-11 19:28:54.000000000 +0000 +++ xterm-297/resize.man 2013-01-06 16:13:44.000000000 +0000 @@ -1,7 +1,42 @@ -.\" $XTermId: resize.man,v 1.20 2011/09/11 19:28:54 tom Exp $ +.\" $XTermId: resize.man,v 1.30 2013/01/06 16:13:44 tom Exp $ +.\" +.\" Copyright 1998-2012,2013 by Thomas E. Dickey +.\" +.\" 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. .\" .\" updated by Thomas E. Dickey for XFree86, 1998-2006. .\" +.ds N Resize +.ds n resize +.\" +.\" Bulleted paragraph +.de bP +.IP \(bu 4 +.. .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds AQ \(aq .el .ds AQ ' @@ -9,18 +44,61 @@ .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' -.TH RESIZE 1 __vendorversion__ +.TH RESIZE 1 "__app_date__" "__app_version__" "X Window System" .SH NAME resize \- set environment and terminal settings to current xterm window size .SH SYNOPSIS -.B resize -[ \fB\-u\fP | \fB\-c\fP ] [ \fB\-s\fP [ \fIrow col\fP ] ] +.B \*n +[ \fB\-v\fP | \fB\-u\fP | \fB\-c\fP ] [ \fB\-s\fP [ \fIrow col\fP ] ] .SH DESCRIPTION -.I Resize +.I \*N prints a shell command for setting the appropriate environment variables to indicate the current size of \fIxterm\fP window from which the command is run. -For this output to take effect, \fIresize\fP must either be evaluated +.PP +.I \*N +determines the command through several steps: +.bP +first, it finds the name of the user's shell program. +It uses the \fBSHELL\fP variable if set, +otherwise it uses the user's data from /etc/passwd. +.bP +then it decides whether to use Bourne shell syntax or C-Shell syntax. +It uses a built-in table of known shells, +which can be overridden by the \fB\-u\fP and \fB\-c\fP options. +.bP +then \fI\*n\fP asks the operating system for the terminal settings. +This is the same information which can be manipulated using \fIstty\fP. +.bP +then \fI\*n\fP asks the terminal for its size in characters. +Depending on whether the "\fB\-s\fP option is given, +\fI\*n\fP uses a different escape sequence to ask for this information. +.bP +at this point, \fI\*n\fP attempts to update the terminal settings +to reflect the terminal window's size in pixels: +.RS +.bP +if the \fB\-s\fP option is used, +\fI\*n\fP then asks the terminal for its size in pixels. +.bP +otherwise, +\fI\*n\fP asks the operating system for the information +and updates that after ensuring that the window's dimensions are +a multiple of the character height and width. +.bP +in either case, the updated terminal settings are done +using a different system call than used for \fIstty\fP. +.RE +.bP +then \fI\*n\fP updates the terminal settings to reflect any altered +values such as its size in rows or columns. +This affects the values shown by \fIstty\fP. +.bP +finally, \fI\*n\fP writes the shell command for setting the +environment variables to the standard output. +.SH EXAMPLES +For \*n's output to take effect, +\fI\*n\fP must either be evaluated as part of the command line (usually done with a shell alias or function) or else redirected to a file which can then be read in. From the C shell (usually @@ -28,7 +106,7 @@ user's \fI.cshrc\fP: .sp .nf - % alias rs \*(AQset noglob; eval \fC\`\fPresize\fC\`\fP\*(AQ + % alias rs \*(AQset noglob; eval \fC\`\fP\*n\fC\`\fP\*(AQ .fi .sp After resizing the window, the user would type: @@ -43,41 +121,45 @@ in with the \*(``.\*('' command: .sp .nf - $ resize > /tmp/out + $ \*n > /tmp/out $ .\0/tmp/out .fi -.PP -.I Resize -determines the user's current shell by first checking if \fB$SHELL\fP -is set, and using that. -Otherwise it determines the user's shell by looking in the password file. -Generally Bourne-shell variants (including \fIksh\fP) -do not modify \fB$SHELL\fP, -so it is possible for \fIresize\fP to be confused if one runs -\fIresize\fP from a Bourne shell spawned from a C shell. .SH OPTIONS -The following options may be used with \fIresize\fP: -.TP 8 -.B \-u -This option indicates that Bourne shell commands should be generated even if -the user's current shell isn't \fI/bin/sh\fP. +The following options may be used with \fI\*n\fP: .TP 8 .B \-c This option indicates that C shell commands should be generated even if the -user's current shell isn't \fI/bin/csh\fP. +user's current shell is not \fI/bin/csh\fP. .TP 8 .B \-s \fR[\fIrows columns\fP] This option indicates that Sun console escape sequences will be used instead of the VT100-style \fIxterm\fP escape codes. If \fIrows\fP and -\fIcolumns\fP are given, \fIresize\fP will ask the \fIxterm\fP to resize -itself. -However, the window manager may choose to disallow the change. +\fIcolumns\fP are given, +\fI\*n\fP will ask the \fIxterm\fP to resize itself using those values. +.IP +Both of the escape sequences used for this option +(first to obtain the window size and +second to modify it) +are subject to \fIxterm\fP's \fBallowWindowOps\fP resource setting. +The window manager may also choose to disallow the change. +.IP +The VT100-style escape sequence used to determine the +screen size always works for VT100-compatible terminals. +VT100s have no corresponding way to modify the screensize. +.TP 8 +.B \-u +This option indicates that Bourne shell commands should be generated even if +the user's current shell is not \fI/bin/sh\fP. +.TP 8 +.B \-v +This causes \fI\*n\fP to print a version number to the standard output, +and then exit. .PP Note that the Sun console escape sequences are recognized by XFree86 \fIxterm\fP and by \fIdtterm\fP. -The \fIresize\fP program may be installed as \fIsunsize\fP, +The \fI\*n\fP program may be installed as \fIsunsize\fP, which causes makes it assume the \fB\-s\fP option. .PP The \fIrows\fP and @@ -92,19 +174,44 @@ user's alias for the command. .SH ENVIRONMENT .TP 15 +SHELL +.I \*N +determines the user's current shell by first checking if \fB$SHELL\fP +is set, and using that. +Otherwise it determines the user's shell by looking in the password file +(/etc/passwd). +Generally Bourne-shell variants (including \fIksh\fP) +do not modify \fB$SHELL\fP, +so it is possible for \fI\*n\fP to be confused if one runs +\fI\*n\fP from a Bourne shell spawned from a C shell. +.TP 15 TERM -set to "__default_termname__" if not already set. +.I \*N +sets this to "__default_termname__" if not already set. .TP 15 TERMCAP -variable set on systems using termcap +.I \*N +sets this variable on systems using termcap, +e.g., when \*n is linked with the \fItermcap\fP library +rather than a \fIterminfo\fP library. +The latter does not provide the complete text for a termcap entry. .TP 15 COLUMNS, LINES -variables set on systems using terminfo +.I \*N +sets these variables on systems using terminfo. +Many applications (including the curses library) +use those variables when set to override their screensize. .SH "SEE ALSO" -csh(1), tset(1), xterm(__mansuffix__) +use_env(3) +.br +csh(1), stty(1), tset(1) +.br +xterm(__mansuffix__) .SH AUTHORS Mark Vandevoorde (MIT-Athena), Edward Moy (Berkeley) .br +Thomas Dickey (invisible-island.net). +.br Copyright (c) 1984, 1985 by X Consortium .br See diff -Nru xterm-278/screen.c xterm-297/screen.c --- xterm-278/screen.c 2011-12-27 10:10:53.000000000 +0000 +++ xterm-297/screen.c 2013-08-14 23:22:53.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: screen.c,v 1.440 2011/12/27 10:10:53 tom Exp $ */ +/* $XTermId: screen.c,v 1.487 2013/08/14 23:22:53 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -58,7 +58,6 @@ #include #include #include -#include #include #include @@ -72,14 +71,20 @@ #include #include +#ifndef _Xconst +#define _Xconst const /* Solaris 7 workaround */ +#endif /* _Xconst */ + +#include + #define inSaveBuf(screen, buf, inx) \ ((buf) == (screen)->saveBuf_index && \ ((inx) < (screen)->savelines || (screen)->savelines == 0)) #define getMinRow(screen) ((xw->flags & ORIGIN) ? (screen)->top_marg : 0) #define getMaxRow(screen) ((xw->flags & ORIGIN) ? (screen)->bot_marg : (screen)->max_row) -#define getMinCol(screen) 0 -#define getMaxCol(screen) ((screen)->max_col) +#define getMinCol(screen) ((xw->flags & ORIGIN) ? (screen)->lft_marg : 0) +#define getMaxCol(screen) ((xw->flags & ORIGIN) ? (screen)->rgt_marg : (screen)->max_col) #define MoveLineData(base, dst, src, len) \ memmove(scrnHeadAddr(screen, base, (unsigned) (dst)), \ @@ -131,7 +136,7 @@ #if OPT_TRACE > 1 static void -traceScrnBuf(const char *tag, TScreen * screen, ScrnBuf sb, unsigned len) +traceScrnBuf(const char *tag, TScreen *screen, ScrnBuf sb, unsigned len) { unsigned j; @@ -151,7 +156,7 @@ #endif static unsigned -scrnHeadSize(TScreen * screen, unsigned count) +scrnHeadSize(TScreen *screen, unsigned count) { unsigned result = SizeOfLineData; @@ -168,7 +173,7 @@ } ScrnBuf -scrnHeadAddr(TScreen * screen, ScrnBuf base, unsigned offset) +scrnHeadAddr(TScreen *screen, ScrnBuf base, unsigned offset) { unsigned size = scrnHeadSize(screen, offset); ScrnBuf result = ScrnBufAddr(base, size); @@ -182,7 +187,7 @@ * Given a block of data, build index to it in the 'base' parameter. */ void -setupLineData(TScreen * screen, ScrnBuf base, Char * data, unsigned nrow, unsigned ncol) +setupLineData(TScreen *screen, ScrnBuf base, Char *data, unsigned nrow, unsigned ncol) { unsigned i; unsigned offset = 0; @@ -244,7 +249,7 @@ * new copy of the screen buffer. */ static void -extractScrnData(TScreen * screen, +extractScrnData(TScreen *screen, ScrnBuf dstPtrs, ScrnBuf srcPtrs, unsigned nrows, @@ -265,7 +270,7 @@ } static ScrnPtr * -allocScrnHead(TScreen * screen, unsigned nrow) +allocScrnHead(TScreen *screen, unsigned nrow) { ScrnPtr *result; unsigned size = scrnHeadSize(screen, 1); @@ -284,7 +289,7 @@ * Return the size of a line's data. */ static unsigned -sizeofScrnRow(TScreen * screen, unsigned ncol) +sizeofScrnRow(TScreen *screen, unsigned ncol) { unsigned result; unsigned sizeAttribs; @@ -317,15 +322,16 @@ } Char * -allocScrnData(TScreen * screen, unsigned nrow, unsigned ncol) +allocScrnData(TScreen *screen, unsigned nrow, unsigned ncol) { Char *result; size_t length; AlignValue(ncol); - length = (nrow * sizeofScrnRow(screen, ncol)); - if ((result = (Char *) calloc(length, sizeof(Char))) == 0) - SysError(ERROR_SCALLOC2); + length = ((nrow + 1) * sizeofScrnRow(screen, ncol)); + if (length == 0 + || (result = (Char *) calloc(length, sizeof(Char))) == 0) + SysError(ERROR_SCALLOC2); TRACE(("allocScrnData %ux%u -> %lu -> %p..%p\n", nrow, ncol, (unsigned long) length, result, result + length - 1)); @@ -346,7 +352,7 @@ * We store it all as pointers, because of alignment considerations. */ ScrnBuf -allocScrnBuf(XtermWidget xw, unsigned nrow, unsigned ncol, Char ** addr) +allocScrnBuf(XtermWidget xw, unsigned nrow, unsigned ncol, Char **addr) { TScreen *screen = TScreenOf(xw); ScrnBuf base = 0; @@ -367,7 +373,7 @@ * Copy line-data from the visible (edit) buffer to the save-lines buffer. */ static void -saveEditBufLines(TScreen * screen, ScrnBuf sb, unsigned n) +saveEditBufLines(TScreen *screen, ScrnBuf sb, unsigned n) { unsigned j; @@ -391,7 +397,7 @@ * Copy line-data from the save-lines buffer to the visible (edit) buffer. */ static void -unsaveEditBufLines(TScreen * screen, ScrnBuf sb, unsigned n) +unsaveEditBufLines(TScreen *screen, ScrnBuf sb, unsigned n) { unsigned j; @@ -402,7 +408,7 @@ #if OPT_FIFO_LINES LineData *src; - if ((screen->saved_fifo - extra) <= 0) { + if (extra > screen->saved_fifo || extra > screen->savelines) { TRACE(("...FIXME: must clear text!\n")); continue; } @@ -424,8 +430,8 @@ */ static int Reallocate(XtermWidget xw, - ScrnBuf * sbuf, - Char ** sbufaddr, + ScrnBuf *sbuf, + Char **sbufaddr, unsigned nrow, unsigned ncol, unsigned oldrow) @@ -518,8 +524,8 @@ */ static void ReallocateBufOffsets(XtermWidget xw, - ScrnBuf * sbuf, - Char ** sbufaddr, + ScrnBuf *sbuf, + Char **sbufaddr, unsigned nrow, unsigned ncol) { @@ -703,6 +709,37 @@ #endif /* + * Copy cells, no side-effects. + */ +void +CopyCells(TScreen *screen, LineData *src, LineData *dst, int col, int len) +{ + if (len > 0) { + int n; + int last = col + len; + + for (n = col; n < last; ++n) { + dst->charData[n] = src->charData[n]; + dst->attribs[n] = src->attribs[n]; + } + + if_OPT_ISO_COLORS(screen, { + for (n = col; n < last; ++n) { + dst->color[n] = src->color[n]; + } + }); + if_OPT_WIDE_CHARS(screen, { + size_t off; + for (n = col; n < last; ++n) { + for_each_combData(off, src) { + dst->combData[off][n] = src->combData[off][n]; + } + } + }); + } +} + +/* * Clear cells, no side-effects. */ void @@ -783,7 +820,7 @@ */ void ScrnWriteText(XtermWidget xw, - IChar * str, + IChar *str, unsigned flags, unsigned cur_fg_bg, unsigned length) @@ -799,7 +836,7 @@ unsigned n; unsigned real_width = visual_width(str, length); - (void) cur_fg_bg; + (void) cur_fg_bg; /* quiet compiler warnings when unused */ if (real_width + (unsigned) screen->cur_col > (unsigned) MaxCols(screen)) { real_width = (unsigned) (MaxCols(screen) - screen->cur_col); @@ -896,10 +933,19 @@ ld->color[screen->cur_col + (int) j] = (CellColor) cur_fg_bg; }); - if_OPT_WIDE_CHARS(screen, { - screen->last_written_col = screen->cur_col + (int) real_width - 1; - screen->last_written_row = screen->cur_row; - }); +#if OPT_WIDE_CHARS + screen->last_written_col = screen->cur_col + (int) real_width - 1; + screen->last_written_row = screen->cur_row; +#endif + + TRACE(("text erasing cur_col=%d cur_row=%d real_width=%d\n", + screen->cur_col, + screen->cur_row, + real_width)); + chararea_clear_displayed_graphics(screen, + screen->cur_col, + screen->cur_row, + (int) real_width, 1); if_OPT_XMC_GLITCH(screen, { Resolve_XMC(xw); @@ -928,7 +974,7 @@ (sb == screen->saveBuf_index) ? "save" : "edit", where, n, size)); - assert(n != 0); + assert((int) n > 0); assert(size != 0); /* save n lines at where */ @@ -971,6 +1017,17 @@ #endif base = ScrnBufAddr(base, jump); } + + TRACE(("clear lines erasing where=%d screen->savelines=%d n=%d screen->max_col=%d\n", + where, + screen->savelines, + n, + screen->max_col)); + chararea_clear_displayed_graphics(screen, + where + screen->savelines, + 0, + screen->max_col + 1, + (int) n); } /* @@ -1028,7 +1085,7 @@ } size_t -ScrnPointers(TScreen * screen, size_t len) +ScrnPointers(TScreen *screen, size_t len) { size_t result = scrnHeadSize(screen, (unsigned) len); @@ -1061,7 +1118,7 @@ assert(last >= (int) n); assert(last >= where); - assert(n != 0); + assert((int) n > 0); assert(size != 0); /* save n lines at bottom */ @@ -1106,7 +1163,7 @@ assert(where >= 0); assert(last >= where + (int) n - 1); - assert(n != 0); + assert((int) n > 0); assert(size != 0); /* move up lines */ @@ -1179,26 +1236,28 @@ ScrnInsertChar(XtermWidget xw, unsigned n) { #define MemMove(data) \ - for (j = last - 1; j >= (col + (int) n); --j) \ + for (j = last; j >= (col + (int) n); --j) \ data[j] = data[j - (int) n] TScreen *screen = TScreenOf(xw); - int last = MaxCols(screen); + int first = ScrnLeftMargin(xw); + int last = ScrnRightMargin(xw); int row = screen->cur_row; int col = screen->cur_col; int j; LineData *ld; - if (last <= (col + (int) n)) { - if (last <= col) - return; + if (col < first || col > last) { + TRACE(("ScrnInsertChar - col %d outside [%d..%d]\n", col, first, last)); + return; + } else if (last <= (col + (int) n)) { n = (unsigned) (last - col); } assert(screen->cur_col >= 0); assert(screen->cur_row >= 0); - assert(n > 0); - assert(last > (int) n); + assert((int) n >= 0); + assert(last >= (int) n); if_OPT_WIDE_CHARS(screen, { int xx = screen->cur_row; @@ -1207,7 +1266,7 @@ if (DamagedCells(screen, n, &kl, (int *) 0, xx, kr) && kr > kl) { ClearCells(xw, 0, (unsigned) (kr - kl + 1), row, kl); } - kr = screen->max_col - (int) n + 1; + kr = last - (int) n + 1; if (DamagedCells(screen, n, &kl, (int *) 0, xx, kr) && kr > kl) { ClearCells(xw, 0, (unsigned) (kr - kl + 1), row, kl); } @@ -1239,25 +1298,27 @@ ScrnDeleteChar(XtermWidget xw, unsigned n) { #define MemMove(data) \ - for (j = col; j < last - (int) n; ++j) \ + for (j = col; j <= last - (int) n; ++j) \ data[j] = data[j + (int) n] TScreen *screen = TScreenOf(xw); - int last = MaxCols(screen); + int first = ScrnLeftMargin(xw); + int last = ScrnRightMargin(xw) + 1; int row = screen->cur_row; int col = screen->cur_col; int j; LineData *ld; - if (last <= (col + (int) n)) { - if (last <= col) - return; + if (col < first || col > last) { + TRACE(("ScrnDeleteChar - col %d outside [%d..%d]\n", col, first, last)); + return; + } else if (last <= (col + (int) n)) { n = (unsigned) (last - col); } assert(screen->cur_col >= 0); assert(screen->cur_row >= 0); - assert(n > 0); + assert((int) n >= 0); assert(last > (int) n); if_OPT_WIDE_CHARS(screen, { @@ -1297,7 +1358,7 @@ * its line-wrapping state. */ void -ShowWrapMarks(XtermWidget xw, int row, LineData * ld) +ShowWrapMarks(XtermWidget xw, int row, LineData *ld) { TScreen *screen = TScreenOf(xw); Boolean set = (Boolean) LineTstWrapped(ld); @@ -1308,7 +1369,7 @@ TRACE2(("ShowWrapMarks %d:%s\n", row, BtoS(set))); - XFillRectangle(screen->display, VWindow(screen), + XFillRectangle(screen->display, VDrawable(screen), getCgsGC(xw, currentWin, cgsId), x, y, (unsigned) screen->border, @@ -1659,6 +1720,12 @@ resetXtermGC(xw, flags, hilite); } + refresh_displayed_graphics(screen, + leftcol, + toprow + screen->topline, + ncols, + nrows); + /* * If we're in color mode, reset the various GC's to the current * screen foreground and background so that other functions (e.g., @@ -1770,7 +1837,6 @@ #ifdef TTYSIZE_STRUCT TTYSIZE_STRUCT ts; #endif - Window tw = VWindow(screen); TRACE(("ScreenResize %dx%d border %d font %dx%d\n", height, width, border, @@ -1783,16 +1849,30 @@ /* clear the right and bottom internal border because of NorthWest gravity might have left junk on the right and bottom edges */ if (width >= (int) FullWidth(screen)) { - XClearArea(screen->display, tw, +#if OPT_DOUBLE_BUFFER + XFillRectangle(screen->display, VDrawable(screen), + ReverseGC(xw, screen), + FullWidth(screen), 0, + width - FullWidth(screen), height); +#else + XClearArea(screen->display, VDrawable(screen), FullWidth(screen), 0, /* right edge */ 0, (unsigned) height, /* from top to bottom */ False); +#endif } if (height >= (int) FullHeight(screen)) { - XClearArea(screen->display, tw, +#if OPT_DOUBLE_BUFFER + XFillRectangle(screen->display, VDrawable(screen), + ReverseGC(xw, screen), + 0, FullHeight(screen), + width, height - FullHeight(screen)); +#else + XClearArea(screen->display, VDrawable(screen), 0, FullHeight(screen), /* bottom */ (unsigned) width, 0, /* all across the bottom */ False); +#endif } } @@ -1809,7 +1889,9 @@ /* update buffers if the screen has changed size */ if (MaxRows(screen) != rows || MaxCols(screen) != cols) { +#if !OPT_SAVE_LINES int whichBuf = 0; +#endif int delta_rows = rows - MaxRows(screen); #if OPT_TRACE int delta_cols = cols - MaxCols(screen); @@ -1979,8 +2061,7 @@ /* free up storage in fifo from the copied lines */ while (unsave_fifo-- > 0) { - deleteScrollback(screen, -1); - screen->saved_fifo--; + deleteScrollback(screen); } #else amount = (screen->savelines - (int) move_down); @@ -2068,13 +2149,16 @@ screen->cursorp.row += move_down_by; ScrollSelection(screen, move_down_by, True); +#if !OPT_SAVE_LINES if (whichBuf) SwitchBufPtrs(screen, whichBuf); /* put the pointers back */ +#endif } } /* adjust scrolling region */ set_tb_margins(screen, 0, screen->max_row); + set_lr_margins(screen, 0, screen->max_col); UIntClr(*flags, ORIGIN); if (screen->cur_row > screen->max_row) @@ -2085,6 +2169,7 @@ screen->fullVwin.height = height - border; screen->fullVwin.width = width - border - screen->fullVwin.sb_info.width; + scroll_displayed_graphics(-move_down_by); } else if (FullHeight(screen) == height && FullWidth(screen) == width) return (0); /* nothing has changed at all */ @@ -2154,7 +2239,7 @@ * nonnull. */ Bool -non_blank_line(TScreen * screen, +non_blank_line(TScreen *screen, int row, int col, int len) @@ -2175,7 +2260,7 @@ } /* - * Rectangle parameters start from one. + * Limit/map rectangle parameters. */ #define minRectRow(screen) (getMinRow(screen) + 1) #define minRectCol(screen) (getMinCol(screen) + 1) @@ -2183,34 +2268,43 @@ #define maxRectCol(screen) (getMaxCol(screen) + 1) static int -limitedParseRow(XtermWidget xw, TScreen * screen, int row) +limitedParseRow(XtermWidget xw, int row) { + TScreen *screen = TScreenOf(xw); int min_row = minRectRow(screen); int max_row = maxRectRow(screen); + if (xw->flags & ORIGIN) + row += screen->top_marg; + if (row < min_row) row = min_row; else if (row > max_row) row = max_row; + return row; } static int -limitedParseCol(XtermWidget xw, TScreen * screen, int col) +limitedParseCol(XtermWidget xw, int col) { + TScreen *screen = TScreenOf(xw); int min_col = minRectCol(screen); int max_col = maxRectCol(screen); - (void) xw; + if (xw->flags & ORIGIN) + col += screen->lft_marg; + if (col < min_col) col = min_col; else if (col > max_col) col = max_col; + return col; } #define LimitedParse(num, func, dft) \ - func(xw, screen, (nparams > num) ? params[num] : dft) + func(xw, (nparams > num) ? params[num] : dft) /* * Copy the rectangle boundaries into a struct, providing default values as @@ -2281,8 +2375,7 @@ TRACE(("filling %d [%d..%d]\n", row, left, left + size)); /* - * Fill attributes, preserving "protected" flag, as well as - * colors if asked. + * Fill attributes, preserving colors. */ for (col = (int) left; col < target->right; ++col) { unsigned temp = ld->attribs[col]; @@ -2290,8 +2383,7 @@ if (!keepColors) { UIntClr(temp, (FG_COLOR | BG_COLOR)); } - temp = attrs | (temp & (FG_COLOR | BG_COLOR | PROTECTED)); - temp |= CHARDRAWN; + temp = attrs | (temp & (FG_COLOR | BG_COLOR)) | CHARDRAWN; ld->attribs[col] = (Char) temp; #if OPT_ISO_COLORS if (attrs & (FG_COLOR | BG_COLOR)) { @@ -2339,6 +2431,9 @@ TRACE(("copying rectangle\n")); + if (nparam > 4) + nparam = 4; + if (validRect(xw, source)) { XTermRect target; xtermParseRect(xw, @@ -2391,6 +2486,13 @@ ld->attribs[col] |= CHARDRAWN; } } +#if OPT_BLINK_TEXT + if (LineHasBlinking(screen, ld)) { + LineSetBlinked(ld); + } else { + LineClrBlinked(ld); + } +#endif } free(cells); @@ -2578,10 +2680,75 @@ False); } } + +/* + * Compute a checksum, ignoring the page number (since we have only one page). + */ +void +xtermCheckRect(XtermWidget xw, + int nparam, + int *params, + int *result) +{ + TScreen *screen = TScreenOf(xw); + XTermRect target; + LineData *ld; + + *result = 0; + if (nparam > 2) { + nparam -= 2; + params += 2; + } + xtermParseRect(xw, nparam, params, &target); + if (validRect(xw, &target)) { + int top = target.top - 1; + int bottom = target.bottom - 1; + int row, col; + + for (row = top; row <= bottom; ++row) { + int left = (target.left - 1); + int right = (target.right - 1); + + ld = getLineData(screen, row); + for (col = left; col <= right; ++col) { + if (ld->attribs[col] & CHARDRAWN) { + *result += (int) ld->charData[col]; + if_OPT_WIDE_CHARS(screen, { + size_t off; + for_each_combData(off, ld) { + *result += (int) ld->combData[off][col]; + } + }) + } + } + } + } +} #endif /* OPT_DEC_RECTOPS */ #if OPT_MAXIMIZE +static _Xconst char * +ewmhProperty(int mode) +{ + _Xconst char *result; + switch (mode) { + default: + result = 0; + break; + case 1: + result = "_NET_WM_STATE_FULLSCREEN"; + break; + case 2: + result = "_NET_WM_STATE_MAXIMIZED_VERT"; + break; + case 3: + result = "_NET_WM_STATE_MAXIMIZED_HORZ"; + break; + } + return result; +} + static void set_resize_increments(XtermWidget xw) { @@ -2629,13 +2796,10 @@ } static void -netwm_fullscreen(XtermWidget xw, int operation) +set_ewmh_hint(Display *dpy, Window window, int operation, _Xconst char *prop) { - TScreen *screen = TScreenOf(xw); XEvent e; - Display *dpy = screen->display; - Window window = VShellWindow(xw); - Atom atom_fullscreen = XInternAtom(dpy, "_NET_WM_STATE_FULLSCREEN", False); + Atom atom_fullscreen = XInternAtom(dpy, prop, False); Atom atom_state = XInternAtom(dpy, "_NET_WM_STATE", False); memset(&e, 0, sizeof(e)); @@ -2652,7 +2816,8 @@ } /* - * Check if the "fullscreen" property is supported on the root window. + * Check if the given property is supported on the root window. + * * The XGetWindowProperty function returns a list of Atom's which corresponds * to the output of xprop. The actual list (ignore the manpage, which refers * to an array of 32-bit values) is constructed by _XRead32, which uses long @@ -2662,11 +2827,9 @@ * window. */ static Boolean -probe_netwm_fullscreen_capability(XtermWidget xw) +probe_netwm(Display *dpy, _Xconst char *propname) { - TScreen *screen = TScreenOf(xw); - Display *dpy = screen->display; - Atom atom_fullscreen = XInternAtom(dpy, "_NET_WM_STATE_FULLSCREEN", False); + Atom atom_fullscreen = XInternAtom(dpy, propname, False); Atom atom_supported = XInternAtom(dpy, "_NET_SUPPORTED", False); Atom actual_type; int actual_format; @@ -2676,37 +2839,36 @@ unsigned long nitems, bytes_after; unsigned char *args; long *ldata; - Boolean netwm_fullscreen_capability = False; - int rc; + Boolean has_capability = False; + Boolean rc; - while (!netwm_fullscreen_capability) { - rc = XGetWindowProperty(dpy, - DefaultRootWindow(dpy), - atom_supported, - long_offset, - long_length, - False, /* do not delete */ - AnyPropertyType, /* req_type */ - &actual_type, /* actual_type_return */ - &actual_format, /* actual_format_return */ - &nitems, /* nitems_return */ - &bytes_after, /* bytes_after_return */ - &args /* prop_return */ + while (!has_capability) { + rc = xtermGetWinProp(dpy, + DefaultRootWindow(dpy), + atom_supported, + long_offset, + long_length, + AnyPropertyType, /* req_type */ + &actual_type, /* actual_type_return */ + &actual_format, /* actual_format_return */ + &nitems, /* nitems_return */ + &bytes_after, /* bytes_after_return */ + &args /* prop_return */ ); - if (rc != Success + if (!rc || actual_type != XA_ATOM) { break; } ldata = (long *) (void *) args; for (i = 0; i < nitems; i++) { if ((Atom) ldata[i] == atom_fullscreen) { - netwm_fullscreen_capability = True; + has_capability = True; break; } } XFree(ldata); - if (!netwm_fullscreen_capability) { + if (!has_capability) { if (bytes_after != 0) { long remaining = (long) (bytes_after / sizeof(long)); if (long_length > remaining) @@ -2718,40 +2880,61 @@ } } - return netwm_fullscreen_capability; + TRACE(("probe_netwm(%s) ->%d\n", propname, has_capability)); + return has_capability; } /* - * Enable/disable fullscreen mode for the xterm widget, if the window manager - * supports that feature. + * Alter fullscreen mode for the xterm widget, if the window manager supports + * that feature. */ void -FullScreen(XtermWidget xw, Bool enabled) +FullScreen(XtermWidget xw, int new_ewmh_mode) { TScreen *screen = TScreenOf(xw); + Display *dpy = screen->display; + _Xconst char *oldprop = ewmhProperty(xw->work.ewmh[0].mode); + _Xconst char *newprop = ewmhProperty(new_ewmh_mode); - static Boolean initialized = False; - static Boolean netwm_fullscreen_capability = False; + int which = 0; + Window window; - TRACE(("FullScreen %s\n", BtoS(enabled))); +#if OPT_TEK4014 + if (TEK4014_ACTIVE(xw)) { + which = 1; + window = TShellWindow; + } else +#endif + window = VShellWindow(xw); + + TRACE(("FullScreen %d:%s\n", new_ewmh_mode, BtoS(new_ewmh_mode))); - if (resource.fullscreen == esNever) { - initialized = True; - netwm_fullscreen_capability = False; - } else if (!initialized) { - initialized = True; - netwm_fullscreen_capability = probe_netwm_fullscreen_capability(xw); + if (new_ewmh_mode < 0 || new_ewmh_mode >= MAX_EWMH_MODE) { + TRACE(("BUG: FullScreen %d\n", new_ewmh_mode)); + return; + } else if (new_ewmh_mode == 0) { + xw->work.ewmh[which].checked[new_ewmh_mode] = True; + xw->work.ewmh[which].allowed[new_ewmh_mode] = True; + } else if (resource.fullscreen == esNever) { + xw->work.ewmh[which].checked[new_ewmh_mode] = True; + xw->work.ewmh[which].allowed[new_ewmh_mode] = False; + } else if (!xw->work.ewmh[which].checked[new_ewmh_mode]) { + xw->work.ewmh[which].checked[new_ewmh_mode] = True; + xw->work.ewmh[which].allowed[new_ewmh_mode] = probe_netwm(dpy, newprop); } - if (netwm_fullscreen_capability) { - if (enabled) { + if (xw->work.ewmh[which].allowed[new_ewmh_mode]) { + if (new_ewmh_mode && !xw->work.ewmh[which].mode) { unset_resize_increments(xw); - netwm_fullscreen(xw, 1); - } else { + set_ewmh_hint(dpy, window, _NET_WM_STATE_ADD, newprop); + } else if (xw->work.ewmh[which].mode && !new_ewmh_mode) { set_resize_increments(xw); - netwm_fullscreen(xw, 0); + set_ewmh_hint(dpy, window, _NET_WM_STATE_REMOVE, oldprop); + } else { + set_ewmh_hint(dpy, window, _NET_WM_STATE_REMOVE, oldprop); + set_ewmh_hint(dpy, window, _NET_WM_STATE_ADD, newprop); } - screen->fullscreen = (Boolean) enabled; + xw->work.ewmh[which].mode = new_ewmh_mode; update_fullscreen(); } else { Bell(xw, XkbBI_MinorError, 100); diff -Nru xterm-278/scrollback.c xterm-297/scrollback.c --- xterm-278/scrollback.c 2011-09-11 14:59:40.000000000 +0000 +++ xterm-297/scrollback.c 2013-04-23 09:57:05.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: scrollback.c,v 1.15 2011/09/11 14:59:40 tom Exp $ */ +/* $XTermId: scrollback.c,v 1.16 2013/04/23 09:57:05 Bertram.Felgenhauer Exp $ */ /* - * Copyright 2009-2010,2011 by Thomas E. Dickey + * Copyright 2009-2011,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -32,7 +32,7 @@ #include -#define REAL_ROW(screen, row) ((row) + 1 + (screen)->saved_fifo) +#define REAL_ROW(screen, row) ((row) + (screen)->saved_fifo) #define ROW2FIFO(screen, row) \ (unsigned) (REAL_ROW(screen, row) % (screen)->savelines) @@ -70,7 +70,6 @@ Char *block; if (screen->saveBuf_index != 0) { - screen->saved_fifo++; TRACE(("addScrollback %lu\n", screen->saved_fifo)); /* first, see which index we'll use */ @@ -90,6 +89,9 @@ free(prior->attribs); prior->attribs = 0; } + if (screen->saved_fifo > 2 * screen->savelines) { + screen->saved_fifo -= screen->savelines; + } } /* allocate the new data */ @@ -101,14 +103,15 @@ TRACE(("...storing new FIFO data in slot %d: %p->%p\n", which, (void *) where, block)); + screen->saved_fifo++; } return (LineData *) where; } void -deleteScrollback(TScreen * screen, int row) +deleteScrollback(TScreen * screen) { - unsigned which = ROW2FIFO(screen, row); + unsigned which = ROW2FIFO(screen, -1); ScrnBuf where = scrnHeadAddr(screen, screen->saveBuf_index, which); LineData *prior = (LineData *) where; /* @@ -121,4 +124,5 @@ free(prior->attribs); prior->attribs = 0; } + screen->saved_fifo--; } diff -Nru xterm-278/scrollbar.c xterm-297/scrollbar.c --- xterm-278/scrollbar.c 2011-09-03 12:13:42.000000000 +0000 +++ xterm-297/scrollbar.c 2013-06-23 21:55:39.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: scrollbar.c,v 1.182 2011/09/03 12:13:42 tom Exp $ */ +/* $XTermId: scrollbar.c,v 1.197 2013/06/23 21:55:39 tom Exp $ */ /* - * Copyright 2000-2010,2011 by Thomas E. Dickey + * Copyright 2000-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -66,17 +66,14 @@ #include #endif -#if defined(HAVE_XKBQUERYEXTENSION) && defined(HAVE_X11_XKBLIB_H) && defined(HAVE_X11_EXTENSIONS_XKB_H) +#if defined(HAVE_XKBQUERYEXTENSION) #include #include -#else -#undef HAVE_XKBQUERYEXTENSION #endif #include #include #include -#include #include /* @@ -176,7 +173,7 @@ xw->hints.height = MaxRows(screen) * FontHeight(screen) + xw->hints.min_height; #if OPT_MAXIMIZE /* assure single-increment resize for fullscreen */ - if (screen->fullscreen) { + if (xw->work.ewmh[0].mode) { xw->hints.width_inc = 1; xw->hints.height_inc = 1; } @@ -190,7 +187,7 @@ #if OPT_MAXIMIZE /* compensate for fullscreen mode */ - if (screen->fullscreen) { + if (xw->work.ewmh[0].mode) { Screen *xscreen = DefaultScreenOfDisplay(xw->screen.display); reqWidth = (Dimension) WidthOfScreen(xscreen); reqHeight = (Dimension) HeightOfScreen(xscreen); @@ -400,14 +397,23 @@ ScrollSelection(screen, i, True); - XClearArea( - screen->display, - VWindow(screen), - OriginX(screen), - OriginY(screen) + refreshtop * FontHeight(screen), - (unsigned) Width(screen), - (unsigned) (lines * FontHeight(screen)), - False); +#if OPT_DOUBLE_BUFFER + XFillRectangle(screen->display, + VDrawable(screen), + ReverseGC(xw, screen), + OriginX(screen), + OriginY(screen) + refreshtop * FontHeight(screen), + (unsigned) Width(screen), + (unsigned) (lines * FontHeight(screen))); +#else + XClearArea(screen->display, + VWindow(screen), + OriginX(screen), + OriginY(screen) + refreshtop * FontHeight(screen), + (unsigned) Width(screen), + (unsigned) (lines * FontHeight(screen)), + False); +#endif ScrnRefresh(xw, refreshtop, 0, lines, MaxCols(screen), False); #if OPT_BLINK_CURS || OPT_BLINK_TEXT @@ -657,12 +663,15 @@ mult = FontHeight(screen); } mult *= atoi(params[0]); + TRACE(("params_to_pixels(%s,%s) = %d\n", params[0], params[1], mult)); break; case 1: mult = atoi(params[0]) * FontHeight(screen); /* lines */ + TRACE(("params_to_pixels(%s) = %d\n", params[0], mult)); break; default: mult = screen->scrolllines * FontHeight(screen); + TRACE(("params_to_pixels() = %d\n", mult)); break; } return mult; @@ -684,6 +693,36 @@ return result; } +static void +AlternateScroll(Widget w, long amount) +{ + XtermWidget xw; + TScreen *screen; + + if ((xw = getXtermWidget(w)) != 0 && + (screen = TScreenOf(xw)) != 0 && + screen->alternateScroll && screen->whichBuf) { + ANSI reply; + + amount /= FontHeight(screen); + memset(&reply, 0, sizeof(reply)); + reply.a_type = ((xw->keyboard.flags & MODE_DECCKM) + ? ANSI_SS3 + : ANSI_CSI); + if (amount > 0) { + reply.a_final = 'B'; + } else { + amount = -amount; + reply.a_final = 'A'; + } + while (amount-- > 0) { + unparseseq(xw, &reply); + } + } else { + ScrollTextUpDownBy(w, (XtPointer) 0, (XtPointer) amount); + } +} + /*ARGSUSED*/ void HandleScrollForward( @@ -695,7 +734,7 @@ long amount; if ((amount = AmountToScroll(xw, params, *nparams)) != 0) { - ScrollTextUpDownBy(xw, (XtPointer) 0, (XtPointer) amount); + AlternateScroll(xw, amount); } } @@ -710,7 +749,7 @@ long amount; if ((amount = -AmountToScroll(xw, params, *nparams)) != 0) { - ScrollTextUpDownBy(xw, (XtPointer) 0, (XtPointer) amount); + AlternateScroll(xw, amount); } } @@ -916,6 +955,7 @@ { if (screen->allowScrollLock) { if (screen->scroll_lock != enable) { + TRACE(("SetScrollLock %s\n", BtoS(enable))); screen->scroll_lock = (Boolean) enable; ShowScrollLock(screen, enable); } @@ -935,19 +975,17 @@ TScreen *screen = TScreenOf(xw); if (screen->allowScrollLock) { - /* - * The default action (used with KeyRelease event) is to cycle the - * state on/off. - */ - if (*param_count == 0) { + + switch (decodeToggle(xw, params, *param_count)) { + case toggleOff: + SetScrollLock(screen, False); + break; + case toggleOn: + SetScrollLock(screen, True); + break; + case toggleAll: SetScrollLock(screen, !screen->scroll_lock); - TRACE(("HandleScrollLock ->%d\n", - screen->scroll_lock)); - } else { - SetScrollLock(screen, atoi(params[0])); - TRACE(("HandleScrollLock(%s) ->%d\n", - params[0], - screen->scroll_lock)); + break; } } } diff -Nru xterm-278/tabs.c xterm-297/tabs.c --- xterm-278/tabs.c 2011-09-11 15:00:38.000000000 +0000 +++ xterm-297/tabs.c 2012-06-10 16:53:59.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: tabs.c,v 1.39 2011/09/11 15:00:38 tom Exp $ */ +/* $XTermId: tabs.c,v 1.43 2012/06/10 16:53:59 tom Exp $ */ /* - * Copyright 2000-2010,2011 by Thomas E. Dickey + * Copyright 2000-2011,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -114,7 +114,7 @@ xtermIndex(xw, 1); set_cur_col(screen, 0); col = 0; - screen->do_wrap = False; + ResetWrap(screen); } for (++col; col < MAX_TABS; ++col) if (TST_TAB(tabs, col)) @@ -149,6 +149,8 @@ int next = TabNext(xw, xw->tabs, screen->cur_col); int max = LineMaxCol(screen, getLineData(screen, screen->cur_row)); + if (IsLeftRightMode(xw)) + max = TScreenOf(xw)->rgt_marg; if (next > max) next = max; set_cur_col(screen, next); @@ -164,8 +166,15 @@ { TScreen *screen = TScreenOf(xw); int saved_column = screen->cur_col; + int next_column = TabPrev(xw->tabs, screen->cur_col); - set_cur_col(screen, TabPrev(xw->tabs, screen->cur_col)); + if (xw->flags & ORIGIN) { + int left = ScrnLeftMargin(xw); + if (next_column < left) + next_column = left; + } + + set_cur_col(screen, next_column); return (screen->cur_col < saved_column); } diff -Nru xterm-278/termcap xterm-297/termcap --- xterm-278/termcap 2011-08-16 23:24:17.000000000 +0000 +++ xterm-297/termcap 2012-06-10 14:30:37.000000000 +0000 @@ -1,11 +1,11 @@ -# $XTermId: termcap,v 1.79 2011/08/16 23:24:17 tom Exp $ +# $XTermId: termcap,v 1.80 2012/06/10 14:30:37 tom Exp $ # # These are termcap entries that correspond to xterm's terminfo file. # The file is formatted using ncurses' "tic -CNx", but is not mechanically # derived from the terminfo. # #------------------------------------------------------------------------------ -# Copyright 1996-2009,2010 by Thomas E. Dickey +# Copyright 1996-2011,2012 by Thomas E. Dickey # # All Rights Reserved # @@ -52,9 +52,9 @@ xf|xterm-new|modern xterm:\ :*6=\EOF:@7=\EOF:F1=\E[23~:F2=\E[24~:K2=\EOE:Km=\E[M:\ :k1=\EOP:k2=\EOQ:k3=\EOR:k4=\EOS:k5=\E[15~:k6=\E[17~:\ - :k7=\E[18~:k8=\E[19~:k9=\E[20~:k;=\E[21~:kH=\EOF:kI=\E[2~:\ - :kN=\E[6~:kP=\E[5~:kd=\EOB:kh=\EOH:kl=\EOD:kr=\EOC:ku=\EOA:\ - :tc=xterm-basic: + :k7=\E[18~:k8=\E[19~:k9=\E[20~:k;=\E[21~:kB=\E[Z:kH=\EOF:\ + :kI=\E[2~:kN=\E[6~:kP=\E[5~:kd=\EOB:kh=\EOH:kl=\EOD:\ + :kr=\EOC:ku=\EOA:tc=xterm-basic: # # This chunk is used for building the VT220/Sun/PC keyboard variants. xb|xterm-basic|modern xterm common:\ @@ -82,8 +82,8 @@ # + uses DEC-style control sequences for the application keypad. # vt|xterm-vt220|xterm emulating vt220:\ - :*6=\E[4~:@7=\E[4~:K2=\EOu:Km=\E[M:kH=\E[4~:kh=\E[1~:\ - :tc=xterm-basic: + :*6=\E[4~:@7=\E[4~:K2=\EOu:Km=\E[M:kB=\E[Z:kH=\E[4~:\ + :kh=\E[1~:tc=xterm-basic: v1|xterm-24|xterms|vs100|24x80 xterm:\ :li#24:tc=xterm-old: diff -Nru xterm-278/terminfo xterm-297/terminfo --- xterm-278/terminfo 2011-08-16 22:27:46.000000000 +0000 +++ xterm-297/terminfo 2012-09-05 00:24:08.000000000 +0000 @@ -1,12 +1,10 @@ -# $XTermId: terminfo,v 1.158 2011/08/16 22:27:46 tom Exp $ -# -# $XFree86: xc/programs/xterm/terminfo,v 3.59 2006/02/13 01:14:59 dickey Exp $ +# $XTermId: terminfo,v 1.161 2012/09/05 00:24:08 tom Exp $ # # Updates/notes/new entries (e.g., xterm-8bit, xterm-16color, xterm-256color) # - Thomas E. Dickey # #------------------------------------------------------------------------------ -# Copyright 1996-2007,2011 by Thomas E. Dickey +# Copyright 1996-2011,2012 by Thomas E. Dickey # # All Rights Reserved # @@ -895,6 +893,7 @@ msgr, xenl, AX, + XT, colors#8, cols#80, it#8, @@ -980,6 +979,7 @@ u8=\E[?1;2c, u9=\E[c, vpa=\E[%i%p1%dd, + E3=\E[3;J, use=xterm+kbs, # # The xterm-new description has all of the features, but is not completely @@ -1252,6 +1252,7 @@ lines#65, use=xterm-old, xterm-bold|xterm with bold instead of underline (X Window System), + sgr=%?%p9%t\016%e\017%;B\E[0%?%p6%t;1%;%?%p2%t;1%;%?%p1%p3%|%t;7%;m, smso=\E[7m, smul=\E[1m, use=xterm-old, @@ -1597,6 +1598,7 @@ npc, xenl, AX, + XT, colors#8, cols#80, it#8, @@ -1766,7 +1768,7 @@ # + added u6, u7, u8, u9 strings for Daniel Weaver's tack program. # + added kmous string for ncurses. # + added khome/kend strings (which conflict with kfnd/kslt, see note). -xterm-r6|xterm-old|xterm X11R6 version, +xterm-r6|xterm X11R6 version, OTbs, am, km, @@ -1858,6 +1860,8 @@ u9=\E[c, use=xterm+kbs, use=xterm+decedit, +xterm-old|antique xterm version, + use=xterm-r6, # # Compatible with the R5 xterm, with the following changes: # + changed 'blink=@', to 'blink@' (the former meant that "@" would start diff -Nru xterm-278/trace.c xterm-297/trace.c --- xterm-278/trace.c 2011-12-27 10:10:53.000000000 +0000 +++ xterm-297/trace.c 2013-09-09 00:15:00.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: trace.c,v 1.133 2011/12/27 10:10:53 tom Exp $ */ +/* $XTermId: trace.c,v 1.149 2013/09/09 00:15:00 tom Exp $ */ /* - * Copyright 1997-2010,2011 by Thomas E. Dickey + * Copyright 1997-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -35,6 +35,7 @@ */ #include /* for definition of GCC_UNUSED */ +#include #if OPT_TRACE @@ -85,6 +86,7 @@ trace_out = trace_who; if (!trace_fp) { + unsigned oldmask = umask(077); char name[BUFSIZ]; #if 0 /* usually I do not want unique names */ int unique; @@ -110,6 +112,7 @@ xtermWarning("Cannot open \"%s\"\n", name); exit(EXIT_FAILURE); } + (void) umask(oldmask); } va_start(ap, fmt); @@ -127,7 +130,6 @@ (void) fflush(stderr); (void) visibleChars(NULL, 0); (void) visibleIChars(NULL, 0); - (void) visibleIChar(NULL, 0); trace_fp = 0; } } @@ -181,7 +183,7 @@ break; default: if (E2A(value) < 32 || (E2A(value) >= 127 && E2A(value) < 160)) - sprintf(dst, "\\%03o", value); + sprintf(dst, "\\%03o", value & 0xff); else sprintf(dst, "%c", CharOf(value)); break; @@ -191,7 +193,7 @@ #if OPT_DEC_CHRSET const char * -visibleChrsetName(unsigned chrset) +visibleDblChrset(unsigned chrset) { const char *result = "?"; switch (chrset) { @@ -212,8 +214,58 @@ } #endif +const char * +visibleScsCode(unsigned chrset) +{ +#define MAP(to,from) case from: result = to; break + const char *result = ""; + switch ((DECNRCM_codes) chrset) { + MAP("B", nrc_ASCII); + MAP("A", nrc_British); + MAP("A", nrc_British_Latin_1); + MAP("&4", nrc_Cyrillic); + MAP("0", nrc_DEC_Spec_Graphic); + MAP("1", nrc_DEC_Alt_Chars); + MAP("2", nrc_DEC_Alt_Graphics); + MAP("<", nrc_DEC_Supp); + MAP("%5", nrc_DEC_Supp_Graphic); + MAP(">", nrc_DEC_Technical); + MAP("4", nrc_Dutch); + MAP("5", nrc_Finnish); + MAP("C", nrc_Finnish2); + MAP("R", nrc_French); + MAP("f", nrc_French2); + MAP("Q", nrc_French_Canadian); + MAP("9", nrc_French_Canadian2); + MAP("K", nrc_German); + MAP("\"?", nrc_Greek); + MAP("F", nrc_Greek_Supp); + MAP("\"4", nrc_Hebrew); + MAP("%=", nrc_Hebrew2); + MAP("H", nrc_Hebrew_Supp); + MAP("Y", nrc_Italian); + MAP("M", nrc_Latin_5_Supp); + MAP("L", nrc_Latin_Cyrillic); + MAP("`", nrc_Norwegian_Danish); + MAP("E", nrc_Norwegian_Danish2); + MAP("6", nrc_Norwegian_Danish3); + MAP("%6", nrc_Portugese); + MAP("&5", nrc_Russian); + MAP("%3", nrc_SCS_NRCS); + MAP("Z", nrc_Spanish); + MAP("7", nrc_Swedish); + MAP("H", nrc_Swedish2); + MAP("=", nrc_Swiss); + MAP("%0", nrc_Turkish); + MAP("%2", nrc_Turkish2); + MAP("", nrc_Unknown); + } +#undef MAP + return result; +} + char * -visibleChars(const Char * buf, unsigned len) +visibleChars(const Char *buf, unsigned len) { static char *result; static unsigned used; @@ -244,7 +296,7 @@ } char * -visibleIChars(IChar * buf, unsigned len) +visibleIChars(IChar *buf, unsigned len) { static char *result; static unsigned used; @@ -280,38 +332,11 @@ } char * -visibleIChar(IChar * buf, unsigned len) +visibleUChar(unsigned chr) { - static char *result; - static unsigned used; - - if (buf != 0) { - unsigned limit = ((len + 1) * 8) + 1; - char *dst; - - if (limit > used) { - used = limit; - result = XtRealloc(result, used); - } - if (result != 0) { - dst = result; - while (len--) { - unsigned value = *buf++; -#if OPT_WIDE_CHARS - if (value > 255) - sprintf(dst, "\\u+%04X", value); - else -#endif - formatAscii(dst, value); - dst += strlen(dst); - } - } - } else if (result != 0) { - free(result); - result = 0; - used = 0; - } - return result; + IChar buf[1]; + buf[0] = chr; + return visibleIChars(buf, 1); } #define CASETYPE(name) case name: result = #name; break @@ -375,6 +400,19 @@ } const char * +visibleNotifyMode(int code) +{ + const char *result = "?"; + switch (code) { + CASETYPE(NotifyNormal); + CASETYPE(NotifyGrab); + CASETYPE(NotifyUngrab); + CASETYPE(NotifyWhileGrabbed); + } + return result; +} + +const char * visibleNotifyDetail(int code) { const char *result = "?"; @@ -392,7 +430,7 @@ } const char * -visibleSelectionTarget(Display * d, Atom a) +visibleSelectionTarget(Display *d, Atom a) { const char *result = "?"; @@ -447,7 +485,7 @@ #define isScrnFlag(flag) ((flag) == LINEWRAPPED) static char * -ScrnText(LineData * ld) +ScrnText(LineData *ld) { return visibleIChars(ld->charData, ld->lineSize); } @@ -461,7 +499,7 @@ ScrnText(ld)) void -LineClrFlag(LineData * ld, int flag) +LineClrFlag(LineData *ld, int flag) { if (ld == 0) { SHOW_BAD_LINE(LineClrFlag, ld); @@ -474,7 +512,7 @@ } void -LineSetFlag(LineData * ld, int flag) +LineSetFlag(LineData *ld, int flag) { if (ld == 0) { SHOW_BAD_LINE(LineSetFlag, ld); @@ -503,6 +541,77 @@ } #endif /* OPT_TRACE_FLAGS */ +/* + * Trace the normal or alternate screen, showing color values up to 16, e.g., + * for debugging with vttest. + */ +void +TraceScreen(XtermWidget xw, int whichBuf) +{ + TScreen *screen = TScreenOf(xw); + int row, col; + + if (screen->editBuf_index[whichBuf]) { + TRACE(("TraceScreen %d:\n", whichBuf)); + for (row = 0; row <= screen->max_row; ++row) { + LineData *ld = getLineData(screen, row); + TRACE((" %3d:", row)); + if (ld != 0) { + for (col = 0; col < ld->lineSize; ++col) { + int ch = (int) ld->charData[col]; + if (ch < ' ') + ch = ' '; + if (ch >= 127) + ch = '#'; + TRACE(("%c", ch)); + } + TRACE((":\n")); + + TRACE((" xx:")); + for (col = 0; col < ld->lineSize; ++col) { + unsigned attrs = ld->attribs[col]; + char ch; + if (attrs & PROTECTED) { + ch = '*'; + } else if (attrs & BLINK) { + ch = 'B'; + } else if (attrs & CHARDRAWN) { + ch = '+'; + } else { + ch = ' '; + } + TRACE(("%c", ch)); + } + TRACE((":\n")); + +#if 0 + TRACE((" fg:")); + for (col = 0; col < ld->lineSize; ++col) { + unsigned fg = extract_fg(xw, ld->color[col], ld->attribs[col]); + if (fg > 15) + fg = 15; + TRACE(("%1x", fg)); + } + TRACE((":\n")); + + TRACE((" bg:")); + for (col = 0; col < ld->lineSize; ++col) { + unsigned bg = extract_bg(xw, ld->color[col], ld->attribs[col]); + if (bg > 15) + bg = 15; + TRACE(("%1x", bg)); + } + TRACE((":\n")); +#endif + } else { + TRACE(("null lineData\n")); + } + } + } else { + TRACE(("TraceScreen %d is nil\n", whichBuf)); + } +} + void TraceFocus(Widget w, XEvent * ev) { @@ -514,7 +623,7 @@ { XFocusChangeEvent *event = (XFocusChangeEvent *) ev; TRACE(("\tdetail: %s\n", visibleNotifyDetail(event->detail))); - TRACE(("\tmode: %d\n", event->mode)); + TRACE(("\tmode: %s\n", visibleNotifyMode(event->mode))); TRACE(("\twindow: %#lx\n", event->window)); } break; @@ -523,7 +632,7 @@ { XCrossingEvent *event = (XCrossingEvent *) ev; TRACE(("\tdetail: %s\n", visibleNotifyDetail(event->detail))); - TRACE(("\tmode: %d\n", event->mode)); + TRACE(("\tmode: %s\n", visibleNotifyMode(event->mode))); TRACE(("\twindow: %#lx\n", event->window)); TRACE(("\tfocus: %d\n", event->focus)); TRACE(("\troot: %#lx\n", event->root)); @@ -660,11 +769,34 @@ */ /* ARGSUSED */ static int -no_error(Display * dpy GCC_UNUSED, XErrorEvent * event GCC_UNUSED) +no_error(Display *dpy GCC_UNUSED, XErrorEvent * event GCC_UNUSED) { return 1; } +const char * +ModifierName(unsigned modifier) +{ + const char *s = ""; + if (modifier & ShiftMask) + s = " Shift"; + else if (modifier & LockMask) + s = " Lock"; + else if (modifier & ControlMask) + s = " Control"; + else if (modifier & Mod1Mask) + s = " Mod1"; + else if (modifier & Mod2Mask) + s = " Mod2"; + else if (modifier & Mod3Mask) + s = " Mod3"; + else if (modifier & Mod4Mask) + s = " Mod4"; + else if (modifier & Mod5Mask) + s = " Mod5"; + return s; +} + void TraceTranslations(const char *name, Widget w) { @@ -696,8 +828,8 @@ TraceResizeRequest(const char *fn, int ln, Widget w, unsigned reqwide, unsigned reqhigh, - Dimension * gotwide, - Dimension * gothigh) + Dimension *gotwide, + Dimension *gothigh) { XtGeometryResult rc; @@ -725,6 +857,7 @@ Trace("XTERM_RESOURCE settings:\n"); XRES_S(icon_geometry); XRES_S(title); + XRES_S(icon_hint); XRES_S(icon_name); XRES_S(term_name); XRES_S(tty_modes); @@ -764,6 +897,7 @@ XRES_B(useInsertMode); #if OPT_ZICONBEEP XRES_I(zIconBeep); + XRES_S(zIconFormat); #endif #if OPT_PTY_HANDSHAKE XRES_B(wait_for_map); diff -Nru xterm-278/trace.h xterm-297/trace.h --- xterm-278/trace.h 2011-09-11 14:56:42.000000000 +0000 +++ xterm-297/trace.h 2013-09-08 00:09:57.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: trace.h,v 1.64 2011/09/11 14:56:42 tom Exp $ */ +/* $XTermId: trace.h,v 1.70 2013/09/08 00:09:57 tom Exp $ */ /* - * Copyright 1997-2010,2011 by Thomas E. Dickey + * Copyright 1997-2011,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -41,7 +41,7 @@ #if OPT_TRACE -extern void Trace ( const char *, ... ) GCC_PRINTFLIKE(1,2); +extern void Trace ( const char *, ... ) GCC_PRINTFLIKE(1,2); #undef TRACE #define TRACE(p) Trace p @@ -56,11 +56,13 @@ #endif extern char * visibleChars (const Char * /* buf */, unsigned /* len */); -extern char * visibleIChar (IChar *, unsigned); extern char * visibleIChars (IChar * /* buf */, unsigned /* len */); -extern const char * visibleChrsetName(unsigned /* chrset */); +extern char * visibleUChar (unsigned); +extern const char * visibleDblChrset(unsigned /* chrset */); extern const char * visibleEventType (int); extern const char * visibleNotifyDetail(int /* code */); +extern const char * visibleNotifyMode (int /* code */); +extern const char * visibleScsCode(unsigned /* chrset */); extern const char * visibleSelectionTarget(Display * /* d */, Atom /* a */); extern const char * visibleXError (int /* code */); @@ -115,6 +117,18 @@ (reqwide), (reqhigh), \ (gotwide), (gothigh)) +extern const char * ModifierName(unsigned /* modifier */); +#define FMT_MODIFIER_NAMES "%s%s%s%s%s%s%s%s" +#define ARG_MODIFIER_NAMES(state) \ + ModifierName(state & ShiftMask), \ + ModifierName(state & LockMask), \ + ModifierName(state & ControlMask), \ + ModifierName(state & Mod1Mask), \ + ModifierName(state & Mod2Mask), \ + ModifierName(state & Mod3Mask), \ + ModifierName(state & Mod4Mask), \ + ModifierName(state & Mod5Mask) + #else #define REQ_RESIZE(w, reqwide, reqhigh, gotwide, gothigh) \ @@ -124,6 +138,8 @@ #endif +extern void TraceScreen(XtermWidget /* xw */, int /* whichBuf */); + /* * The whole wnew->screen struct is zeroed in VTInitialize. Use these macros * where applicable for copying the pieces from the request widget into the @@ -166,4 +182,4 @@ /* *INDENT-ON* */ -#endif /* included_trace_h */ +#endif /* included_trace_h */ diff -Nru xterm-278/util.c xterm-297/util.c --- xterm-278/util.c 2011-12-30 21:56:42.000000000 +0000 +++ xterm-297/util.c 2013-09-10 11:03:58.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: util.c,v 1.554 2011/12/30 21:56:42 tom Exp $ */ +/* $XTermId: util.c,v 1.613 2013/09/10 11:03:58 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -73,6 +73,8 @@ #include #endif +#include + static int handle_translated_exposure(XtermWidget xw, int rect_x, int rect_y, @@ -87,7 +89,9 @@ static void vertical_copy_area(XtermWidget xw, int firstline, int nlines, - int amount); + int amount, + int left, + int right); #if OPT_WIDE_CHARS unsigned first_widechar; @@ -102,7 +106,7 @@ * that we should fill with blanks, return true if filling is needed. */ int -DamagedCells(TScreen * screen, unsigned n, int *klp, int *krp, int row, int col) +DamagedCells(TScreen *screen, unsigned n, int *klp, int *krp, int row, int col) { LineData *ld = getLineData(screen, row); int result = False; @@ -155,7 +159,7 @@ } int -DamagedCurCells(TScreen * screen, unsigned n, int *klp, int *krp) +DamagedCurCells(TScreen *screen, unsigned n, int *klp, int *krp) { return DamagedCells(screen, n, klp, krp, screen->cur_row, screen->cur_col); } @@ -175,72 +179,117 @@ int refreshheight; int scrolltop; int scrollheight; + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); + Boolean full_lines = (Boolean) ((left == 0) && (right == screen->max_col)); if (screen->cursor_state) HideCursor(); + + TRACE(("FlushScroll %s-lines scroll:%d refresh %d\n", + full_lines ? "full" : "partial", + screen->scroll_amt, + screen->refresh_amt)); + if (screen->scroll_amt > 0) { + /* + * Lines will be scrolled "up". + */ refreshheight = screen->refresh_amt; - scrollheight = screen->bot_marg - screen->top_marg - - refreshheight + 1; - if ((refreshtop = screen->bot_marg - refreshheight + 1 + shift) > - (i = screen->max_row - screen->scroll_amt + 1)) + scrollheight = screen->bot_marg - screen->top_marg - refreshheight + 1; + refreshtop = screen->bot_marg - refreshheight + 1 + shift; + i = screen->max_row - screen->scroll_amt + 1; + if (refreshtop > i) { refreshtop = i; + } + + /* + * If this is the normal (not alternate) screen, and the top margin is + * at the top of the screen, then we will shift full lines scrolled out + * of the scrolling region into the saved-lines. + */ if (screen->scrollWidget && !screen->whichBuf + && full_lines && screen->top_marg == 0) { scrolltop = 0; - if ((scrollheight += shift) > i) + scrollheight += shift; + if (scrollheight > i) scrollheight = i; - if ((i = screen->bot_marg - bot) > 0 && - (refreshheight -= i) < screen->scroll_amt) - refreshheight = screen->scroll_amt; - if ((i = screen->savedlines) < screen->savelines) { - if ((i += screen->scroll_amt) > - screen->savelines) + i = screen->bot_marg - bot; + if (i > 0) { + refreshheight -= i; + if (refreshheight < screen->scroll_amt) { + refreshheight = screen->scroll_amt; + } + } + i = screen->savedlines; + if (i < screen->savelines) { + i += screen->scroll_amt; + if (i > screen->savelines) { i = screen->savelines; + } screen->savedlines = i; ScrollBarDrawThumb(screen->scrollWidget); } } else { scrolltop = screen->top_marg + shift; - if ((i = bot - (screen->bot_marg - screen->refresh_amt + - screen->scroll_amt)) > 0) { - if (bot < screen->bot_marg) + i = bot - (screen->bot_marg - screen->refresh_amt + screen->scroll_amt); + if (i > 0) { + if (bot < screen->bot_marg) { refreshheight = screen->scroll_amt + i; + } } else { scrollheight += i; refreshheight = screen->scroll_amt; - if ((i = screen->top_marg + screen->scroll_amt - - 1 - bot) > 0) { + i = screen->top_marg + screen->scroll_amt - 1 - bot; + if (i > 0) { refreshtop += i; refreshheight -= i; } } } } else { + /* + * Lines will be scrolled "down". + */ refreshheight = -screen->refresh_amt; - scrollheight = screen->bot_marg - screen->top_marg - - refreshheight + 1; + scrollheight = screen->bot_marg - screen->top_marg - refreshheight + 1; refreshtop = screen->top_marg + shift; scrolltop = refreshtop + refreshheight; - if ((i = screen->bot_marg - bot) > 0) + i = screen->bot_marg - bot; + if (i > 0) { scrollheight -= i; - if ((i = screen->top_marg + refreshheight - 1 - bot) > 0) + } + i = screen->top_marg + refreshheight - 1 - bot; + if (i > 0) { refreshheight -= i; + } } - scrolling_copy_area(xw, scrolltop + screen->scroll_amt, - scrollheight, screen->scroll_amt); + + vertical_copy_area(xw, + scrolltop + screen->scroll_amt, + scrollheight, + screen->scroll_amt, + left, + right); ScrollSelection(screen, -(screen->scroll_amt), False); screen->scroll_amt = 0; screen->refresh_amt = 0; + if (refreshheight > 0) { ClearCurBackground(xw, - (int) refreshtop * FontHeight(screen) + screen->border, - (int) OriginX(screen), - (unsigned) (refreshheight * FontHeight(screen)), - (unsigned) Width(screen)); - ScrnRefresh(xw, refreshtop, 0, refreshheight, - MaxCols(screen), False); + refreshtop, + left, + (unsigned) refreshheight, + (unsigned) (right + 1 - left), + (unsigned) FontWidth(screen)); + ScrnRefresh(xw, + refreshtop, + 0, + refreshheight, + MaxCols(screen), + False); } return; } @@ -250,22 +299,22 @@ * include the current line. If false, the line is visible and we should * paint it now rather than waiting for the line to become visible. */ -int +static Bool AddToRefresh(XtermWidget xw) { TScreen *screen = TScreenOf(xw); int amount = screen->refresh_amt; int row = screen->cur_row; - int result; + Bool result; if (amount == 0) { - result = 0; + result = False; } else if (amount > 0) { int bottom; if (row == (bottom = screen->bot_marg) - amount) { screen->refresh_amt++; - result = 1; + result = True; } else { result = (row >= bottom - amount + 1 && row <= bottom); } @@ -275,7 +324,7 @@ amount = -amount; if (row == (top = screen->top_marg) + amount) { screen->refresh_amt--; - result = 1; + result = True; } else { result = (row <= top + amount - 1 && row >= top); } @@ -313,7 +362,8 @@ /* * If we're scrolling, leave the selection intact if possible. * If it will bump into one of the extremes of the saved-lines, truncate that. - * If the selection is not contained within the scrolled region, clear it. + * If the selection is not entirely contained within the margins and not + * entirely outside the margins, clear it. */ static void adjustHiliteOnFwdScroll(XtermWidget xw, int amount, Bool all_lines) @@ -323,6 +373,8 @@ ? (screen->bot_marg - screen->savelines) : screen->top_marg); int hi_row = screen->bot_marg; + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); TRACE2(("adjustSelection FWD %s by %d (%s)\n", screen->whichBuf ? "alternate" : "normal", @@ -336,8 +388,19 @@ TRACE2((" margins %d..%d\n", screen->top_marg, screen->bot_marg)); TRACE2((" limits %d..%d\n", lo_row, hi_row)); - if (screen->startH.row >= lo_row - && screen->startH.row - amount < lo_row) { + if ((left > 0 || right < screen->max_col) && + ((screen->startH.row >= lo_row && + screen->startH.row - amount <= hi_row) || + (screen->endH.row >= lo_row && + screen->endH.row - amount <= hi_row))) { + /* + * This could be improved slightly by excluding the special case where + * the selection is on a single line outside left/right margins. + */ + TRACE2(("deselect because selection overlaps with scrolled partial-line\n")); + ScrnDisownSelection(xw); + } else if (screen->startH.row >= lo_row + && screen->startH.row - amount < lo_row) { /* truncate the selection because its start would move out of region */ if (lo_row + amount <= screen->endH.row) { TRACE2(("truncate selection by changing start %d.%d to %d.%d\n", @@ -359,8 +422,10 @@ ScrnDisownSelection(xw); } } else if (screen->startH.row <= hi_row && screen->endH.row > hi_row) { + TRACE2(("deselect because selection straddles top-margin\n")); ScrnDisownSelection(xw); } else if (screen->startH.row < lo_row && screen->endH.row > lo_row) { + TRACE2(("deselect because selection straddles bottom-margin\n")); ScrnDisownSelection(xw); } @@ -429,6 +494,46 @@ } /* + * Move cells in LineData's on the current screen to simulate scrolling by the + * given amount of lines. + */ +static void +scrollInMargins(XtermWidget xw, int amount, int top) +{ + TScreen *screen = TScreenOf(xw); + LineData *src; + LineData *dst; + int row; + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); + int length = right + 1 - left; + + if (amount > 0) { + for (row = top; row <= screen->bot_marg - amount; ++row) { + if ((src = getLineData(screen, row + amount)) != 0 + && (dst = getLineData(screen, row)) != 0) { + CopyCells(screen, src, dst, left, length); + } + } + while (row <= screen->bot_marg) { + ClearCells(xw, 0, (unsigned) length, row, left); + ++row; + } + } else if (amount < 0) { + for (row = screen->bot_marg; row >= top - amount; --row) { + if ((src = getLineData(screen, row + amount)) != 0 + && (dst = getLineData(screen, row)) != 0) { + CopyCells(screen, src, dst, left, length); + } + } + while (row >= top) { + ClearCells(xw, 0, (unsigned) length, row, left); + --row; + } + } +} + +/* * scrolls the screen by amount lines, erases bottom, doesn't alter * cursor position (i.e. cursor moves down amount relative to text). * All done within the scrolling region, of course. @@ -438,13 +543,15 @@ xtermScroll(XtermWidget xw, int amount) { TScreen *screen = TScreenOf(xw); - int i = screen->bot_marg - screen->top_marg + 1; + int i; int shift; int bot; int refreshtop = 0; int refreshheight; int scrolltop; int scrollheight; + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); Boolean scroll_all_lines = (Boolean) (screen->scrollWidget && !screen->whichBuf && screen->top_marg == 0); @@ -457,6 +564,7 @@ if (screen->cursor_state) HideCursor(); + i = screen->bot_marg - screen->top_marg + 1; if (amount > i) amount = i; @@ -541,14 +649,20 @@ screen->scrolls++; } - scrolling_copy_area(xw, scrolltop + amount, scrollheight, amount); + vertical_copy_area(xw, + scrolltop + amount, + scrollheight, + amount, + left, + right); if (refreshheight > 0) { ClearCurBackground(xw, - (int) refreshtop * FontHeight(screen) + screen->border, - (int) OriginX(screen), - (unsigned) (refreshheight * FontHeight(screen)), - (unsigned) Width(screen)); + refreshtop, + left, + (unsigned) refreshheight, + (unsigned) (right + 1 - left), + (unsigned) FontWidth(screen)); if (refreshheight > shift) refreshheight = shift; } @@ -556,7 +670,9 @@ } if (amount > 0) { - if (scroll_all_lines) { + if (left > 0 || right < screen->max_col) { + scrollInMargins(xw, amount, screen->top_marg); + } else if (scroll_all_lines) { ScrnDeleteLine(xw, screen->saveBuf_index, screen->bot_marg + screen->savelines, @@ -571,9 +687,15 @@ } } + scroll_displayed_graphics(amount); + if (refreshheight > 0) { - ScrnRefresh(xw, refreshtop, 0, refreshheight, - MaxCols(screen), False); + ScrnRefresh(xw, + refreshtop, + left, + refreshheight, + right + 1 - left, + False); } screen->cursor_busy -= 1; @@ -598,18 +720,21 @@ xtermColIndex(XtermWidget xw, Bool toLeft) { TScreen *screen = TScreenOf(xw); + int margin; if (toLeft) { - if (screen->cur_col) { + margin = ScrnLeftMargin(xw); + if (screen->cur_col > margin) { CursorBack(xw, 1); - } else { - xtermColScroll(xw, 1, False, 0); + } else if (screen->cur_col == margin) { + xtermColScroll(xw, 1, False, screen->cur_col); } } else { - if (screen->cur_col < screen->max_col) { - CursorForward(screen, 1); - } else { - xtermColScroll(xw, 1, True, 0); + margin = ScrnRightMargin(xw); + if (screen->cur_col < margin) { + CursorForward(xw, 1); + } else if (screen->cur_col == margin) { + xtermColScroll(xw, 1, True, ScrnLeftMargin(xw)); } } } @@ -620,27 +745,44 @@ void xtermColScroll(XtermWidget xw, int amount, Bool toLeft, int at_col) { + TScreen *screen = TScreenOf(xw); + if (amount > 0) { - TScreen *screen = TScreenOf(xw); - int save_row = screen->cur_row; - int save_col = screen->cur_col; - int row; + int min_row; + int max_row; - screen->cur_col = at_col; - if (toLeft) { - for (row = 0; row <= screen->max_row; row++) { - screen->cur_row = row; - ScrnDeleteChar(xw, (unsigned) amount); - } + if (ScrnHaveRowMargins(screen)) { + min_row = screen->top_marg; + max_row = screen->bot_marg; } else { - for (row = 0; row <= screen->max_row; row++) { - screen->cur_row = row; - ScrnInsertChar(xw, (unsigned) amount); + min_row = 0; + max_row = screen->max_row; + } + + if (screen->cur_row >= min_row + && screen->cur_row <= max_row + && screen->cur_col >= screen->lft_marg + && screen->cur_col <= screen->rgt_marg) { + int save_row = screen->cur_row; + int save_col = screen->cur_col; + int row; + + screen->cur_col = at_col; + if (toLeft) { + for (row = min_row; row <= max_row; row++) { + screen->cur_row = row; + ScrnDeleteChar(xw, (unsigned) amount); + } + } else { + for (row = min_row; row <= max_row; row++) { + screen->cur_row = row; + ScrnInsertChar(xw, (unsigned) amount); + } } + screen->cur_row = save_row; + screen->cur_col = save_col; + xtermRepaint(xw); } - screen->cur_row = save_row; - screen->cur_col = save_col; - xtermRepaint(xw); } } @@ -661,6 +803,8 @@ int refreshheight; int scrolltop; int scrollheight; + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); TRACE(("RevScroll count=%d\n", amount)); @@ -692,8 +836,7 @@ shift = INX2ROW(screen, 0); bot = screen->max_row - shift; refreshheight = amount; - scrollheight = screen->bot_marg - screen->top_marg - - refreshheight + 1; + scrollheight = screen->bot_marg - screen->top_marg - refreshheight + 1; refreshtop = screen->top_marg + shift; scrolltop = refreshtop + refreshheight; if ((i = screen->bot_marg - bot) > 0) @@ -709,33 +852,171 @@ screen->scrolls++; } - scrolling_copy_area(xw, scrolltop - amount, scrollheight, -amount); + vertical_copy_area(xw, + scrolltop - amount, + scrollheight, + -amount, + left, + right); if (refreshheight > 0) { ClearCurBackground(xw, - (int) refreshtop * FontHeight(screen) + screen->border, - (int) OriginX(screen), - (unsigned) (refreshheight * FontHeight(screen)), - (unsigned) Width(screen)); + refreshtop, + left, + (unsigned) refreshheight, + (unsigned) (right + 1 - left), + (unsigned) FontWidth(screen)); } } if (amount > 0) { - ScrnInsertLine(xw, - screen->visbuf, - screen->bot_marg, - screen->top_marg, - (unsigned) amount); + if (left > 0 || right < screen->max_col) { + scrollInMargins(xw, -amount, screen->top_marg); + } else { + ScrnInsertLine(xw, + screen->visbuf, + screen->bot_marg, + screen->top_marg, + (unsigned) amount); + } } screen->cursor_busy -= 1; return; } +#if OPT_ZICONBEEP +void +initZIconBeep(void) +{ + if (resource.zIconBeep > 100 || resource.zIconBeep < -100) { + resource.zIconBeep = 0; /* was 100, but I prefer to defaulting off. */ + xtermWarning("a number between -100 and 100 is required for zIconBeep. 0 used by default\n"); + } +} + +static void +setZIconBeep(XtermWidget xw) +{ + TScreen *screen = TScreenOf(xw); + + /* Flag icon name with "***" on window output when iconified. + */ + if (resource.zIconBeep && mapstate == IsUnmapped && !screen->zIconBeep_flagged) { + static char *icon_name; + static Arg args[] = + { + {XtNiconName, (XtArgVal) & icon_name} + }; + + icon_name = NULL; + XtGetValues(toplevel, args, XtNumber(args)); + + if (icon_name != NULL) { + screen->zIconBeep_flagged = True; + ChangeIconName(xw, icon_name); + } + xtermBell(xw, XkbBI_Info, 0); + } + mapstate = -1; +} + +/* + * If warning should be given then give it + */ +Boolean +showZIconBeep(XtermWidget xw, char *name) +{ + Boolean code = False; + + if (resource.zIconBeep && TScreenOf(xw)->zIconBeep_flagged) { + char *format = resource.zIconFormat; + char *newname = CastMallocN(char, strlen(name) + strlen(format) + 1); + if (!newname) { + xtermWarning("malloc failed in showZIconBeep\n"); + } else { + char *marker = strstr(format, "%s"); + char *result = newname; + if (marker != 0) { + size_t skip = (size_t) (marker - format); + if (skip) { + strncpy(result, format, skip); + result += skip; + } + strcpy(result, name); + strcat(result, marker + 2); + } else { + strcpy(result, format); + strcat(result, name); + } + ChangeGroup(xw, XtNiconName, newname); + free(newname); + } + code = True; + } + return code; +} + +/* + * Restore the icon name, resetting the state for zIconBeep. + */ +void +resetZIconBeep(XtermWidget xw) +{ + static char *icon_name; + static Arg args[] = + { + {XtNiconName, (XtArgVal) & icon_name} + }; + TScreen *screen = TScreenOf(xw); + + if (screen->zIconBeep_flagged) { + screen->zIconBeep_flagged = False; + icon_name = NULL; + XtGetValues(toplevel, args, XtNumber(args)); + if (icon_name != NULL) { + char *buf = CastMallocN(char, strlen(icon_name)); + if (buf == NULL) { + screen->zIconBeep_flagged = True; + } else { + char *format = resource.zIconFormat; + char *marker = strstr(format, "%s"); + Boolean found = False; + + if (marker != 0) { + if (marker == format + || !strncmp(icon_name, format, (size_t) (marker - format))) { + found = True; + strcpy(buf, icon_name + (marker - format)); + marker += 2; + if (*marker != '\0') { + size_t len_m = strlen(marker); + size_t len_b = strlen(buf); + if (len_m < len_b + && !strcmp(buf + len_b - len_m, marker)) { + buf[len_b - len_m] = '\0'; + } + } + } + } else if (!strncmp(icon_name, format, strlen(format))) { + strcpy(buf, icon_name + strlen(format)); + found = True; + } + if (found) + ChangeIconName(xw, buf); + free(buf); + } + } + } +} +#else +#define setZIconBeep(xw) /* nothing */ +#endif /* OPT_ZICONBEEP */ + /* * write a string str of length len onto the screen at * the current cursor position. update cursor position. */ void -WriteText(XtermWidget xw, IChar * str, Cardinal len) +WriteText(XtermWidget xw, IChar *str, Cardinal len) { TScreen *screen = TScreenOf(xw); LineData *ld = 0; @@ -750,14 +1031,14 @@ screen->topline, screen->cur_row, screen->cur_col, - len, visibleIChar(str, len))); + len, visibleIChars(str, len))); if (cells + (unsigned) screen->cur_col > (unsigned) MaxCols(screen)) { cells = (unsigned) (MaxCols(screen) - screen->cur_col); } if (ScrnHaveSelection(screen) - && ScrnIsLineInSelection(screen, INX2ROW(screen, screen->cur_row))) { + && ScrnIsRowInSelection(screen, INX2ROW(screen, screen->cur_row))) { ScrnDisownSelection(xw); } @@ -816,28 +1097,8 @@ } ScrnWriteText(xw, str, flags, fg_bg, len); - CursorForward(screen, (int) cells); -#if OPT_ZICONBEEP - /* Flag icon name with "***" on window output when iconified. - */ - if (resource.zIconBeep && mapstate == IsUnmapped && !screen->zIconBeep_flagged) { - static char *icon_name; - static Arg args[] = - { - {XtNiconName, (XtArgVal) & icon_name} - }; - - icon_name = NULL; - XtGetValues(toplevel, args, XtNumber(args)); - - if (icon_name != NULL) { - screen->zIconBeep_flagged = True; - ChangeIconName(xw, icon_name); - } - xtermBell(xw, XkbBI_Info, 0); - } - mapstate = -1; -#endif /* OPT_ZICONBEEP */ + CursorForward(xw, (int) cells); + setZIconBeep(xw); return; } @@ -857,8 +1118,12 @@ int refreshheight; int scrolltop; int scrollheight; + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); - if (!ScrnIsLineInMargins(screen, screen->cur_row)) + if (!ScrnIsRowInMargins(screen, screen->cur_row) + || screen->cur_col < left + || screen->cur_col > right) return; TRACE(("InsertLine count=%d\n", n)); @@ -867,16 +1132,16 @@ HideCursor(); if (ScrnHaveSelection(screen) - && ScrnAreLinesInSelection(screen, - INX2ROW(screen, screen->top_marg), - INX2ROW(screen, screen->cur_row - 1)) - && ScrnAreLinesInSelection(screen, - INX2ROW(screen, screen->cur_row), - INX2ROW(screen, screen->bot_marg))) { + && ScrnAreRowsInSelection(screen, + INX2ROW(screen, screen->top_marg), + INX2ROW(screen, screen->cur_row - 1)) + && ScrnAreRowsInSelection(screen, + INX2ROW(screen, screen->cur_row), + INX2ROW(screen, screen->bot_marg))) { ScrnDisownSelection(xw); } - screen->do_wrap = False; + ResetWrap(screen); if (n > (i = screen->bot_marg - screen->cur_row + 1)) n = i; if (screen->jumpscroll) { @@ -902,21 +1167,26 @@ scrollheight -= i; if ((i = screen->cur_row + refreshheight - 1 - bot) > 0) refreshheight -= i; - vertical_copy_area(xw, scrolltop - n, scrollheight, -n); + vertical_copy_area(xw, scrolltop - n, scrollheight, -n, left, right); if (refreshheight > 0) { ClearCurBackground(xw, - (int) refreshtop * FontHeight(screen) + screen->border, - (int) OriginX(screen), - (unsigned) (refreshheight * FontHeight(screen)), - (unsigned) Width(screen)); + refreshtop, + left, + (unsigned) refreshheight, + (unsigned) (right + 1 - left), + (unsigned) FontWidth(screen)); } } if (n > 0) { - ScrnInsertLine(xw, - screen->visbuf, - screen->bot_marg, - screen->cur_row, - (unsigned) n); + if (left > 0 || right < screen->max_col) { + scrollInMargins(xw, -n, screen->cur_row); + } else { + ScrnInsertLine(xw, + screen->visbuf, + screen->bot_marg, + screen->cur_row, + (unsigned) n); + } } } @@ -935,11 +1205,15 @@ int refreshheight; int scrolltop; int scrollheight; + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); Boolean scroll_all_lines = (Boolean) (screen->scrollWidget && !screen->whichBuf && screen->cur_row == 0); - if (!ScrnIsLineInMargins(screen, screen->cur_row)) + if (!ScrnIsRowInMargins(screen, screen->cur_row) + || screen->cur_col < left + || screen->cur_col > right) return; TRACE(("DeleteLine count=%d\n", n)); @@ -951,13 +1225,13 @@ n = i; } if (ScrnHaveSelection(screen) - && ScrnAreLinesInSelection(screen, - INX2ROW(screen, screen->cur_row), - INX2ROW(screen, screen->cur_row + n - 1))) { + && ScrnAreRowsInSelection(screen, + INX2ROW(screen, screen->cur_row), + INX2ROW(screen, screen->cur_row + n - 1))) { ScrnDisownSelection(xw); } - screen->do_wrap = False; + ResetWrap(screen); if (screen->jumpscroll) { if (screen->scroll_amt >= 0 && screen->cur_row == screen->top_marg) { if (screen->refresh_amt + n > MaxRows(screen)) @@ -972,18 +1246,21 @@ /* adjust screen->buf */ if (n > 0) { - if (scroll_all_lines) + if (left > 0 || right < screen->max_col) { + scrollInMargins(xw, n, screen->cur_row); + } else if (scroll_all_lines) { ScrnDeleteLine(xw, screen->saveBuf_index, screen->bot_marg + screen->savelines, 0, (unsigned) n); - else + } else { ScrnDeleteLine(xw, screen->visbuf, screen->bot_marg, screen->cur_row, (unsigned) n); + } } /* repaint the screen, as needed */ @@ -1014,7 +1291,7 @@ } } } - vertical_copy_area(xw, scrolltop + n, scrollheight, n); + vertical_copy_area(xw, scrolltop + n, scrollheight, n, left, right); if (shift > 0 && refreshheight > 0) { int rows = refreshheight; if (rows > shift) @@ -1025,10 +1302,11 @@ } if (refreshheight > 0) { ClearCurBackground(xw, - (int) refreshtop * FontHeight(screen) + screen->border, - (int) OriginX(screen), - (unsigned) (refreshheight * FontHeight(screen)), - (unsigned) Width(screen)); + refreshtop, + left, + (unsigned) refreshheight, + (unsigned) (right + 1 - left), + (unsigned) FontWidth(screen)); } } } @@ -1043,6 +1321,8 @@ LineData *ld; unsigned limit; int row = INX2ROW(screen, screen->cur_row); + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); if (screen->cursor_state) HideCursor(); @@ -1050,21 +1330,21 @@ TRACE(("InsertChar count=%d\n", n)); if (ScrnHaveSelection(screen) - && ScrnIsLineInSelection(screen, row)) { + && ScrnIsRowInSelection(screen, row)) { ScrnDisownSelection(xw); } - screen->do_wrap = False; + ResetWrap(screen); - assert(screen->cur_col <= screen->max_col); - limit = (unsigned) (MaxCols(screen) - screen->cur_col); + limit = (unsigned) (right + 1 - screen->cur_col); if (n > limit) n = limit; - assert(n != 0); - if (AddToVisible(xw) - && (ld = getLineData(screen, screen->cur_row)) != 0) { - int col = MaxCols(screen) - (int) n; + if (screen->cur_col < left || screen->cur_col > right) { + n = 0; + } else if (AddToVisible(xw) + && (ld = getLineData(screen, screen->cur_row)) != 0) { + int col = right + 1 - (int) n; /* * If we shift part of a multi-column character, fill the rest @@ -1102,13 +1382,16 @@ } ClearCurBackground(xw, - CursorY(screen, screen->cur_row), - LineCursorX(screen, ld, screen->cur_col), - (unsigned) FontHeight(screen), - n * (unsigned) LineFontWidth(screen, ld)); + INX2ROW(screen, screen->cur_row), + screen->cur_col, + 1, + n, + (unsigned) LineFontWidth(screen, ld)); + } + if (n != 0) { + /* adjust screen->buf */ + ScrnInsertChar(xw, n); } - /* adjust screen->buf */ - ScrnInsertChar(xw, n); } /* @@ -1121,6 +1404,8 @@ LineData *ld; unsigned limit; int row = INX2ROW(screen, screen->cur_row); + int left = ScrnLeftMargin(xw); + int right = ScrnRightMargin(xw); if (screen->cursor_state) HideCursor(); @@ -1128,21 +1413,21 @@ TRACE(("DeleteChar count=%d\n", n)); if (ScrnHaveSelection(screen) - && ScrnIsLineInSelection(screen, row)) { + && ScrnIsRowInSelection(screen, row)) { ScrnDisownSelection(xw); } - screen->do_wrap = False; + ResetWrap(screen); - assert(screen->cur_col <= screen->max_col); - limit = (unsigned) (MaxCols(screen) - screen->cur_col); + limit = (unsigned) (right + 1 - screen->cur_col); if (n > limit) n = limit; - assert(n != 0); - if (AddToVisible(xw) - && (ld = getLineData(screen, screen->cur_row)) != 0) { - int col = MaxCols(screen) - (int) n; + if (screen->cur_col < left || screen->cur_col > right) { + n = 0; + } else if (AddToVisible(xw) + && (ld = getLineData(screen, screen->cur_row)) != 0) { + int col = right + 1 - (int) n; /* * If we delete part of a multi-column character, fill the rest @@ -1166,10 +1451,11 @@ -((int) n)); ClearCurBackground(xw, - CursorY(screen, screen->cur_row), - LineCursorX(screen, ld, col), - (unsigned) FontHeight(screen), - n * (unsigned) LineFontWidth(screen, ld)); + INX2ROW(screen, screen->cur_row), + col, + 1, + n, + (unsigned) LineFontWidth(screen, ld)); } if (n != 0) { /* adjust screen->buf */ @@ -1203,11 +1489,18 @@ if ((height = screen->cur_row + top) > screen->max_row) height = screen->max_row + 1; if ((height -= top) > 0) { + chararea_clear_displayed_graphics(screen, + 0, + top, + MaxCols(screen), + height); + ClearCurBackground(xw, - top * FontHeight(screen) + screen->border, - OriginX(screen), - (unsigned) (height * FontHeight(screen)), - (unsigned) (Width(screen))); + top, + 0, + (unsigned) height, + (unsigned) MaxCols(screen), + (unsigned) FontWidth(screen)); } } ClearBufRows(xw, 0, screen->cur_row - 1); @@ -1240,12 +1533,17 @@ if (screen->scroll_amt) FlushScroll(xw); if (++top <= screen->max_row) { + chararea_clear_displayed_graphics(screen, + 0, + top, + MaxCols(screen), + (screen->max_row - top + 1)); ClearCurBackground(xw, - top * FontHeight(screen) + screen->border, - OriginX(screen), - (unsigned) ((screen->max_row - top + 1) - * FontHeight(screen)), - (unsigned) (Width(screen))); + top, + 0, + (unsigned) (screen->max_row - top + 1), + (unsigned) MaxCols(screen), + (unsigned) FontWidth(screen)); } } ClearBufRows(xw, screen->cur_row + 1, screen->max_row); @@ -1269,7 +1567,7 @@ screen->startH.col)); if (ScrnHaveSelection(screen) - && ScrnIsLineInSelection(screen, row)) { + && ScrnIsRowInSelection(screen, row)) { ScrnDisownSelection(xw); } @@ -1322,16 +1620,17 @@ if (screen->cursor_state) HideCursor(); - screen->do_wrap = False; + ResetWrap(screen); if (AddToVisible(xw) && (ld = getLineData(screen, row)) != 0) { ClearCurBackground(xw, - CursorY(screen, row), - LineCursorX(screen, ld, col), - (unsigned) FontHeight(screen), - len * (unsigned) LineFontWidth(screen, ld)); + INX2ROW(screen, row), + col, + 1, + len, + (unsigned) LineFontWidth(screen, ld)); } if (len != 0) { @@ -1410,7 +1709,7 @@ if (screen->show_wrap_marks) { ShowWrapMarks(xw, screen->cur_row, ld); } - screen->do_wrap = False; + ResetWrap(screen); } /* @@ -1461,16 +1760,21 @@ HideCursor(); ScrnDisownSelection(xw); - screen->do_wrap = False; + ResetWrap(screen); if ((top = INX2ROW(screen, 0)) <= screen->max_row) { if (screen->scroll_amt) FlushScroll(xw); + chararea_clear_displayed_graphics(screen, + 0, + top, + MaxCols(screen), + (screen->max_row - top + 1)); ClearCurBackground(xw, - top * FontHeight(screen) + screen->border, - OriginX(screen), - (unsigned) ((screen->max_row - top + 1) - * FontHeight(screen)), - (unsigned) Width(screen)); + top, + 0, + (unsigned) (screen->max_row - top + 1), + (unsigned) MaxCols(screen), + (unsigned) FontWidth(screen)); } ClearBufRows(xw, 0, screen->max_row); } @@ -1575,9 +1879,67 @@ screen->protected_mode = saved_mode; } +static Boolean +screen_has_data(XtermWidget xw) +{ + TScreen *screen = TScreenOf(xw); + Boolean result = False; + LineData *ld; + int row, col; + + for (row = 0; row < screen->max_row; ++row) { + if ((ld = getLineData(screen, row)) != 0) { + for (col = 0; col < screen->max_col; ++col) { + if (ld->attribs[col] & CHARDRAWN) { + result = True; + break; + } + } + } + if (result) + break; + } + return result; +} + +/* + * Like tiXtraScroll, perform a scroll up of the page contents. In this case, + * it happens for the special case when erasing the whole display starting from + * the upper-left corner of the screen. + */ +void +do_cd_xtra_scroll(XtermWidget xw) +{ + TScreen *screen = TScreenOf(xw); + + if (xw->misc.cdXtraScroll + && screen->cur_col == 0 + && screen->cur_row == 0 + && screen_has_data(xw)) { + xtermScroll(xw, screen->max_row); + } +} + +/* + * Scroll the page up (saving it). This is called when doing terminal + * initialization (ti) or exiting from that (te). + */ +void +do_ti_xtra_scroll(XtermWidget xw) +{ + TScreen *screen = TScreenOf(xw); + + if (xw->misc.tiXtraScroll) { + xtermScroll(xw, screen->max_row); + } +} + static void CopyWait(XtermWidget xw) { +#if OPT_DOUBLE_BUFFER + (void) xw; +#else /* !OPT_DOUBLE_BUFFER */ TScreen *screen = TScreenOf(xw); XEvent reply; XEvent *rep = &reply; @@ -1612,6 +1974,7 @@ break; } } +#endif /* OPT_DOUBLE_BUFFER */ } /* @@ -1644,7 +2007,7 @@ screen->copy_dest_y = dest_y; XCopyArea(screen->display, - VWindow(screen), VWindow(screen), + VDrawable(screen), VDrawable(screen), NormalGC(xw, screen), src_x, src_y, width, height, dest_x, dest_y); } @@ -1680,18 +2043,25 @@ vertical_copy_area(XtermWidget xw, int firstline, /* line on screen to start copying at */ int nlines, - int amount) /* number of lines to move up (neg=down) */ + int amount, /* number of lines to move up (neg=down) */ + int left, + int right) { TScreen *screen = TScreenOf(xw); + TRACE(("vertical_copy_area - firstline=%d nlines=%d left=%d right=%d amount=%d\n", + firstline, nlines, left, right, amount)); + if (nlines > 0) { - int src_x = OriginX(screen); + int src_x = CursorX(screen, left); int src_y = firstline * FontHeight(screen) + screen->border; + unsigned int w = (unsigned) ((right + 1 - left) * FontWidth(screen)); + unsigned int h = (unsigned) (nlines * FontHeight(screen)); + int dst_x = src_x; + int dst_y = src_y - amount * FontHeight(screen); + + copy_area(xw, src_x, src_y, w, h, dst_x, dst_y); - copy_area(xw, src_x, src_y, - (unsigned) Width(screen), - (unsigned) (nlines * FontHeight(screen)), - src_x, src_y - amount * FontHeight(screen)); if (screen->show_wrap_marks) { LineData *ld; int row; @@ -1715,7 +2085,7 @@ { if (nlines > 0) { - vertical_copy_area(xw, firstline, nlines, amount); + vertical_copy_area(xw, firstline, nlines, amount, 0, TScreenOf(xw)->max_col); } } @@ -1732,10 +2102,10 @@ #ifndef NO_ACTIVE_ICON if (reply->window == screen->iconVwin.window) { WhichVWin(screen) = &screen->iconVwin; - TRACE(("HandleExposure - icon")); + TRACE(("HandleExposure - icon\n")); } else { WhichVWin(screen) = &screen->fullVwin; - TRACE(("HandleExposure - normal")); + TRACE(("HandleExposure - normal\n")); } TRACE((" event %d,%d %dx%d\n", reply->y, @@ -1822,11 +2192,20 @@ x1 > Width(screen) || y1 > Height(screen))) { set_background(xw, -1); +#if OPT_DOUBLE_BUFFER + XFillRectangle(screen->display, VDrawable(screen), + ReverseGC(xw, screen), + rect_x, + rect_y, + (unsigned) rect_width, + (unsigned) rect_height); +#else XClearArea(screen->display, VWindow(screen), rect_x, rect_y, (unsigned) rect_width, (unsigned) rect_height, False); +#endif } toprow = y0 / FontHeight(screen); if (toprow < 0) @@ -2007,7 +2386,14 @@ TScreen *screen = TScreenOf(xw); TRACE(("xtermClear\n")); +#if OPT_DOUBLE_BUFFER + XFillRectangle(screen->display, VDrawable(screen), + ReverseGC(xw, screen), + 0, 0, + FullWidth(screen), FullHeight(screen)); +#else XClearWindow(screen->display, VWindow(screen)); +#endif } void @@ -2025,13 +2411,13 @@ Boolean isDefaultForeground(const char *name) { - return (Boolean) ! x_strcasecmp(name, XtDefaultForeground); + return (Boolean) !x_strcasecmp(name, XtDefaultForeground); } Boolean isDefaultBackground(const char *name) { - return (Boolean) ! x_strcasecmp(name, XtDefaultBackground); + return (Boolean) !x_strcasecmp(name, XtDefaultBackground); } #if OPT_WIDE_CHARS @@ -2178,7 +2564,7 @@ swapVTwinGCs(xw, &(screen->iconVwin)); #endif /* NO_ACTIVE_ICON */ - xw->misc.re_verse = (Boolean) ! xw->misc.re_verse; + xw->misc.re_verse = (Boolean) !xw->misc.re_verse; if (XtIsRealized((Widget) xw)) { xtermDisplayCursor(xw); @@ -2219,7 +2605,7 @@ } void -recolor_cursor(TScreen * screen, +recolor_cursor(TScreen *screen, Cursor cursor, /* X cursor ID to set */ unsigned long fg, /* pixel indexes to look up */ unsigned long bg) /* pixel indexes to look up */ @@ -2326,7 +2712,7 @@ XftFont * font, int x, int y, - IChar * text, + IChar *text, Cardinal len, Bool really) { @@ -2490,7 +2876,7 @@ IChar eqv = (IChar) AsciiEquivs(ch); if (eqv != (IChar) ch) { - int width = my_wcwidth((int) ch); + int width = my_wcwidth((wchar_t) ch); do { drawXtermText(xw, @@ -2599,7 +2985,7 @@ setCgsFore(xw, currentWin, dstId, bg); setCgsBack(xw, currentWin, dstId, fg); - XFillRectangle(screen->display, VWindow(screen), + XFillRectangle(screen->display, VDrawable(screen), getCgsGC(xw, currentWin, dstId), x, y, len * (Cardinal) FontWidth(screen), @@ -2610,7 +2996,7 @@ #if OPT_TRACE static void -xtermSetClipRectangles(Display * dpy, +xtermSetClipRectangles(Display *dpy, GC gc, int x, int y, @@ -2620,7 +3006,7 @@ { #if 0 TScreen *screen = TScreenOf(term); - Drawable draw = VWindow(screen); + Drawable draw = VDrawable(screen); XSetClipMask(dpy, gc, None); XDrawRectangle(screen->display, draw, gc, @@ -2699,7 +3085,7 @@ XftColor * fg_color, int x, int y, - IChar * text, + IChar *text, Cardinal len) { int ncells = xtermXftWidth(xw, flags, @@ -2738,13 +3124,14 @@ drawXtermText(XtermWidget xw, unsigned flags, GC gc, - int x, - int y, + int start_x, + int start_y, int chrset, - IChar * text, + IChar *text, Cardinal len, int on_wide) { + int x = start_x, y = start_y; TScreen *screen = TScreenOf(xw); Cardinal real_length = len; Cardinal underline_len = 0; @@ -2752,6 +3139,7 @@ the X font, and the width of the default font) */ int font_width = ((flags & DOUBLEWFONT) ? 2 : 1) * screen->fnt_wide; Bool did_ul = False; + XTermFonts *curFont; #if OPT_WIDE_CHARS if (text == 0) @@ -2791,7 +3179,7 @@ rect.width = (unsigned short) ((int) len * font_width); rect.height = (unsigned short) (FontHeight(screen)); - TRACE(("drawing %s\n", visibleChrsetName((unsigned) chrset))); + TRACE(("drawing %s\n", visibleDblChrset((unsigned) chrset))); switch (chrset) { case CSET_DHL_TOP: rect.y = (short) -(fs->ascent / 2); @@ -2879,7 +3267,7 @@ if (!screen->renderDraw) { int scr; - Drawable draw = VWindow(screen); + Drawable draw = VDrawable(screen); Visual *visual; scr = DefaultScreen(dpy); @@ -2958,11 +3346,16 @@ */ if_OPT_WIDE_CHARS(screen, { unsigned part = ucs2dec(ch); - if (xtermIsDecGraphic(part) && - (screen->force_box_chars - || xtermXftMissing(xw, font, ch))) { + if (xtermIsDecGraphic(part)) { + if (screen->force_box_chars + || xtermXftMissing(xw, font, ch)) { + ch = part; + missing = True; + } + } else if (xtermXftMissing(xw, font, ch) + && (part = AsciiEquivs(ch)) != ch) { ch = part; - missing = True; + replace = True; } }); } @@ -3054,14 +3447,20 @@ if ((flags & UNDERLINE) && screen->underline && !did_ul) { if (FontDescent(screen) > 1) y++; - XDrawLine(screen->display, VWindow(screen), gc, + XDrawLine(screen->display, VDrawable(screen), gc, x, y, x + (int) underline_len * FontWidth(screen) - 1, y); } - return x + (int) len *FontWidth(screen); + + x += (int) len *FontWidth(screen); + + return x; } #endif /* OPT_RENDERFONT */ + curFont = ((flags & BOLDATTR(screen)) + ? WhichVFontData(screen, fnts[fBold]) + : WhichVFontData(screen, fnts[fNorm])); /* * If we're asked to display a proportional font, do this with a fixed * pitch. Yes, it's ugly. But we cannot distinguish the use of xterm @@ -3070,9 +3469,6 @@ */ if (!IsIcon(screen) && !(flags & CHARBYCHAR) && screen->fnt_prop) { int adj, width; - XTermFonts *font = ((flags & BOLDATTR(screen)) - ? WhichVFontData(screen, fnts[fBold]) - : WhichVFontData(screen, fnts[fNorm])); while (len--) { int cells = WideCells(*text); @@ -3083,7 +3479,7 @@ continue; } else #endif - if (IsXtermMissingChar(screen, *text, font)) { + if (IsXtermMissingChar(screen, *text, curFont)) { adj = 0; } else #endif @@ -3092,12 +3488,12 @@ XChar2b temp[1]; temp[0].byte2 = LO_BYTE(*text); temp[0].byte1 = HI_BYTE(*text); - width = XTextWidth16(font->fs, temp, 1); + width = XTextWidth16(curFont->fs, temp, 1); } , { char temp[1]; temp[0] = (char) LO_BYTE(*text); - width = XTextWidth(font->fs, temp, 1); + width = XTextWidth(curFont->fs, temp, 1); }); adj = (FontWidth(screen) - width) / 2; if (adj < 0) @@ -3109,20 +3505,31 @@ gc, x + adj, y, chrset, text++, 1, on_wide) - adj; } + return x; } #if OPT_BOX_CHARS - /* If the font is incomplete, draw some substitutions */ + /* + * Draw some substitutions, if needed. The font may not include the + * line-drawing set, or it may be incomplete (in which case we'll draw an + * empty space via xtermDrawBoxChar), or we may be told to force our + * line-drawing. + * + * The empty space is a special case which can be overridden with the + * showMissingGlyphs resource to produce an outline. That is preferable + * to the haphazard treatment of fonts in "modern" (sic) X, which may + * use a thick outline or something like the replacement character. If + * you really want that, you can set assumeAllChars. + */ if (!IsIcon(screen) && !(flags & NOTRANSLATION) - && (!screen->fnt_boxes || screen->force_box_chars)) { + && (!screen->fnt_boxes + || (FontIsIncomplete(curFont) && !screen->assume_all_chars) + || screen->force_box_chars)) { /* Fill in missing box-characters. Find regions without missing characters, and draw them calling ourselves recursively. Draw missing characters via xtermDrawBoxChar(). */ - XTermFonts *font = ((flags & BOLDATTR(screen)) - ? WhichVFontData(screen, fnts[fBold]) - : WhichVFontData(screen, fnts[fNorm])); int last, first = 0; Bool drewBoxes = False; @@ -3143,15 +3550,15 @@ drewBoxes = True; continue; } - ch_width = my_wcwidth((int) ch); + ch_width = my_wcwidth((wchar_t) ch); isMissing = IsXtermMissingChar(screen, ch, ((on_wide || ch_width > 1) && okFont(NormalWFont(screen))) ? WhichVFontData(screen, fnts[fWide]) - : font); + : curFont); #else - isMissing = IsXtermMissingChar(screen, ch, font); + isMissing = IsXtermMissingChar(screen, ch, curFont); ch_width = 1; #endif /* @@ -3163,11 +3570,14 @@ */ if_OPT_WIDE_CHARS(screen, { if (!isMissing - && ch > 255 - && ucs2dec(ch) < 32 && TScreenOf(xw)->force_box_chars) { - ch = ucs2dec(ch); - isMissing = True; + if (ch > 255 + && ucs2dec(ch) < 32) { + ch = ucs2dec(ch); + isMissing = True; + } else if (ch < 32) { + isMissing = True; + } } }); @@ -3179,24 +3589,17 @@ (unsigned) (last - first), on_wide); } #if OPT_WIDE_CHARS - if (ucs_workaround(xw, ch, flags, gc, - x, y, - chrset, on_wide)) { - /* - * if true, we drew at least one cell whether or not it is - * printable - */ - if (ch_width <= 0) - ch_width = 1; - } else -#endif - { - if (ch_width <= 0) - ch_width = 1; - xtermDrawBoxChar(xw, ch, flags, gc, - x, y, - ch_width); + /* + * One way or another, we will draw at least one cell. + */ + if (ch_width <= 0) + ch_width = 1; + if (!ucs_workaround(xw, ch, flags, gc, x, y, chrset, on_wide)) { + xtermDrawBoxChar(xw, ch, flags, gc, x, y, ch_width); } +#else + xtermDrawBoxChar(xw, ch, flags, gc, x, y, ch_width); +#endif x += (ch_width * FontWidth(screen)); first = last + 1; drewBoxes = True; @@ -3242,6 +3645,7 @@ Bool needWide = False; int ascent_adjust = 0; int src, dst; + Bool useBoldFont; BumpTypedBuffer(XChar2b, len); buffer = BfBuf(XChar2b); @@ -3254,7 +3658,7 @@ if (!needWide && !IsIcon(screen) - && ((on_wide || my_wcwidth((int) ch) > 1) + && ((on_wide || my_wcwidth((wchar_t) ch) > 1) && okFont(NormalWFont(screen)))) { needWide = True; } @@ -3301,6 +3705,47 @@ #endif /* OPT_MINI_LUIT */ ++dst; } + + /* + * Check for special case where the bold font lacks glyphs found in the + * normal font, and drop down to normal fonts with overstriking to help + * show the actual characters. + */ + useBoldFont = ((flags & BOLDATTR(screen)) != 0); + if (useBoldFont) { + XTermFonts *norm = 0; + XTermFonts *bold = 0; + Bool noBold, noNorm; + + if (needWide && okFont(BoldWFont(screen))) { + norm = WhichVFontData(screen, fnts[fWide]); + bold = WhichVFontData(screen, fnts[fWBold]); + } else if (okFont(BoldFont(screen))) { + norm = WhichVFontData(screen, fnts[fNorm]); + bold = WhichVFontData(screen, fnts[fBold]); + } else { + useBoldFont = False; + } + + if (useBoldFont && FontIsIncomplete(bold)) { + for (src = 0; src < (int) len; src++) { + IChar ch = text[src]; + + if (ch == HIDDEN_CHAR) + continue; + + noBold = IsXtermMissingChar(screen, ch, bold); + if (noBold) { + noNorm = IsXtermMissingChar(screen, ch, norm); + if (!noNorm) { + useBoldFont = False; + break; + } + } + } + } + } + /* FIXME This is probably wrong. But it works. */ underline_len = len; @@ -3313,17 +3758,14 @@ Pixel bg = getCgsBack(xw, currentWin, gc); if (needWide - && (okFont(NormalWFont(screen)) || okFont(BoldWFont(screen)))) { - if ((flags & BOLDATTR(screen)) != 0 - && okFont(BoldWFont(screen))) { - fntId = fWBold; - cgsId = gcWBold; - } else { - fntId = fWide; - cgsId = gcWide; - } - } else if ((flags & BOLDATTR(screen)) != 0 - && okFont(BoldFont(screen))) { + && useBoldFont + && okFont(BoldWFont(screen))) { + fntId = fWBold; + cgsId = gcWBold; + } else if (needWide) { + fntId = fWide; + cgsId = gcWide; + } else if (useBoldFont) { fntId = fBold; cgsId = gcBold; } else { @@ -3356,19 +3798,19 @@ if (flags & NOBACKGROUND) { XDrawString16(screen->display, - VWindow(screen), gc, + VDrawable(screen), gc, x, y + ascent_adjust, buffer, dst); } else { XDrawImageString16(screen->display, - VWindow(screen), gc, + VDrawable(screen), gc, x, y + ascent_adjust, buffer, dst); } - if ((flags & BOLDATTR(screen)) && screen->enbolden) { + if ((flags & BOLDATTR(screen)) && (screen->enbolden || !useBoldFont)) { beginClipping(screen, gc, (Cardinal) font_width, len); - XDrawString16(screen->display, VWindow(screen), gc, + XDrawString16(screen->display, VDrawable(screen), gc, x + 1, y + ascent_adjust, buffer, dst); @@ -3393,16 +3835,16 @@ #endif if (flags & NOBACKGROUND) { - XDrawString(screen->display, VWindow(screen), gc, + XDrawString(screen->display, VDrawable(screen), gc, x, y, buffer, length); } else { - XDrawImageString(screen->display, VWindow(screen), gc, + XDrawImageString(screen->display, VDrawable(screen), gc, x, y, buffer, length); } underline_len = (Cardinal) length; if ((flags & BOLDATTR(screen)) && screen->enbolden) { beginClipping(screen, gc, font_width, length); - XDrawString(screen->display, VWindow(screen), gc, + XDrawString(screen->display, VDrawable(screen), gc, x + 1, y, buffer, length); endClipping(screen, gc); } @@ -3411,11 +3853,12 @@ if ((flags & UNDERLINE) && screen->underline && !did_ul) { if (FontDescent(screen) > 1) y++; - XDrawLine(screen->display, VWindow(screen), gc, + XDrawLine(screen->display, VDrawable(screen), gc, x, y, (x + (int) underline_len * font_width - 1), y); } - return x + (int) real_length *FontWidth(screen); + x += (int) real_length *FontWidth(screen); + return x; } #if OPT_WIDE_CHARS @@ -3676,18 +4119,36 @@ int top, int left, unsigned height, - unsigned width) + unsigned width, + unsigned fw) { TScreen *screen = TScreenOf(xw); - TRACE(("ClearCurBackground(%d,%d,%d,%d) %d\n", + TRACE(("ClearCurBackground %d,%d %dx%d with %d\n", top, left, height, width, xw->cur_background)); + assert((int) width > 0); + assert((left + (int) width) <= screen->max_col + 1); + assert((int) height <= screen->max_row + 1); + if (VWindow(screen)) { set_background(xw, xw->cur_background); +#if OPT_DOUBLE_BUFFER + XFillRectangle(screen->display, VDrawable(screen), + ReverseGC(xw, screen), + CursorX2(screen, left, fw), + CursorY(screen, top), + (width * fw), + (height * (unsigned) FontHeight(screen))); +#else XClearArea(screen->display, VWindow(screen), - left, top, width, height, False); + CursorX2(screen, left, fw), + CursorY2(screen, top), + (width * fw), + (height * (unsigned) FontHeight(screen)), + False); +#endif set_background(xw, -1); } @@ -3698,11 +4159,10 @@ * Returns a single base character for the given cell. */ unsigned -getXtermCell(TScreen * screen, int row, int col) +getXtermCell(TScreen *screen, int row, int col) { LineData *ld = getLineData(screen, row); - assert(ld && (col < (int) ld->lineSize)); return ((ld && (col < (int) ld->lineSize)) ? ld->charData[col] : (unsigned) ' '); @@ -3712,11 +4172,10 @@ * Sets a single base character for the given cell. */ void -putXtermCell(TScreen * screen, int row, int col, int ch) +putXtermCell(TScreen *screen, int row, int col, int ch) { LineData *ld = getLineData(screen, row); - assert(ld && (col < (int) ld->lineSize)); if (ld && (col < (int) ld->lineSize)) { ld->charData[col] = (CharData) ch; if_OPT_WIDE_CHARS(screen, { @@ -3733,7 +4192,7 @@ * Add a combining character for the given cell */ void -addXtermCombining(TScreen * screen, int row, int col, unsigned ch) +addXtermCombining(TScreen *screen, int row, int col, unsigned ch) { if (ch != 0) { LineData *ld = getLineData(screen, row); @@ -3750,52 +4209,14 @@ } } } -#endif -#ifdef HAVE_CONFIG_H -#ifdef USE_MY_MEMMOVE -void * -my_memmove(void *s1, void *s2, size_t n) +unsigned +getXtermCombining(TScreen *screen, int row, int col, int off) { - if (n != 0) { - char *p1 = (char *) s1; - char *p2 = (char *) s2; - - if ((p1 + n > p2) && (p2 + n > p1)) { - static char *bfr; - static size_t length; - size_t j; - if (length < n) { - length = (n * 3) / 2; - bfr = ((bfr != 0) - ? TypeRealloc(char, length, bfr) - : TypeMallocN(char, length)); - if (bfr == NULL) - SysError(ERROR_MMALLOC); - } - for (j = 0; j < n; j++) - bfr[j] = p2[j]; - p2 = bfr; - } - while (n-- != 0) - p1[n] = p2[n]; - } - return s1; -} -#endif /* USE_MY_MEMMOVE */ - -#ifndef HAVE_STRERROR -char * -my_strerror(int n) -{ - extern char *sys_errlist[]; - extern int sys_nerr; - if (n > 0 && n < sys_nerr) - return sys_errlist[n]; - return "?"; + LineData *ld = getLineData(screen, row); + return ld->combData[off][col]; } #endif -#endif void update_keyboard_type(void) @@ -3951,7 +4372,7 @@ int oops = 0; for (n = 21; n <= 25; ++n) { - int code = (int) dec2ucs((unsigned) n); + wchar_t code = (wchar_t) dec2ucs((unsigned) n); int system_code = wcwidth(code); int intern_code = mk_wcwidth(code); diff -Nru xterm-278/uxterm.desktop xterm-297/uxterm.desktop --- xterm-278/uxterm.desktop 2010-06-15 10:58:13.000000000 +0000 +++ xterm-297/uxterm.desktop 2012-06-24 22:20:29.000000000 +0000 @@ -1,8 +1,8 @@ -# $XTermId: uxterm.desktop,v 1.9 2010/06/15 10:58:13 tom Exp $ +# $XTermId: uxterm.desktop,v 1.13 2012/06/24 22:20:29 tom Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 2006-2007,2010 by Thomas E. Dickey +# Copyright 2006-2010,2012 by Thomas E. Dickey # # All Rights Reserved # @@ -32,6 +32,7 @@ # ----------------------------------------------------------------------------- [Desktop Entry] Name=UXTerm +#GenericName=Terminal Comment=standard terminal emulator for the X window system Exec=uxterm Terminal=false diff -Nru xterm-278/uxterm.man xterm-297/uxterm.man --- xterm-278/uxterm.man 2011-08-16 09:44:32.000000000 +0000 +++ xterm-297/uxterm.man 2013-01-01 00:40:55.000000000 +0000 @@ -1,4 +1,4 @@ -.\" $XTermId: uxterm.man,v 1.4 2011/08/16 09:44:32 tom Exp $ +.\" $XTermId: uxterm.man,v 1.6 2013/01/01 00:40:55 tom Exp $ .\" .\" Copyright 2001, 2004 Branden Robinson .\" @@ -19,22 +19,33 @@ .\" 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" +.\" +.ds N Uxterm +.ds n uxterm +.\" Escape single quotes in literal strings from groff's Unicode transform. +.ie \n(.g .ds AQ \(aq +.el .ds AQ ' +.ie \n(.g .ds `` \(lq +.el .ds `` `` +.ie \n(.g .ds '' \(rq +.el .ds '' '' +.\" +.TH UXTERM 1 "__app_date__" "__app_version__" "X Window System" .SH NAME uxterm \- X terminal emulator for Unicode (UTF-8) environments .SH SYNOPSIS -.B uxterm +.B \*n [ .I xterm-options ] .SH DESCRIPTION -.B uxterm +.B \*n is a wrapper around the .BR xterm(1) -program that invokes the latter program with the \(oqU__default_class__\(cq X resource +program that invokes the latter program with the \*(``U__default_class__\*('' X resource class set. All arguments to -.B uxterm +.B \*n are passed to .B xterm without processing; the @@ -47,29 +58,29 @@ manual page for more information on .IR xterm-options . .PP -The environment's locale settings (see \(lqENVIRONMENT\(rq below) are +The environment's locale settings (see \*(``ENVIRONMENT\*('' below) are used to discern the locale's character set. -If no current locale can be determined, the locale \(oqen_US\(cq (the +If no current locale can be determined, the locale \*(``en_US\*('' (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 +.B \*n will exit with an error and report the output of .BR locale . .PP -.B Note: uxterm +.B Note: \*n may produce unexpected results if the current locale is set to one in which the UTF-8 character encoding is not supported, or if fonts using the ISO 10646-1 character set are not available. -In the Debian system, the \(oqxfonts\-base\(cq package provides the fonts +In the Debian system, the \*(``xfonts\-base\*('' package provides the fonts that -.B uxterm +.B \*n uses by default. To change the fonts -.B uxterm +.B \*n uses, edit the .I __apploaddir__/U__default_class__ file. diff -Nru xterm-278/version.c xterm-297/version.c --- xterm-278/version.c 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/version.c 2013-01-01 12:10:44.000000000 +0000 @@ -0,0 +1,74 @@ +/* $XTermId: version.c,v 1.1 2013/01/01 12:10:44 tom Exp $ */ + +/* + * Copyright 2013 by Thomas E. Dickey + * + * 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. + */ + +#include +#include +#include + +/* + * Returns the version-string used in the "-v' message as well as a few other + * places. It is derived (when possible) from the __vendorversion__ symbol + * that some newer imake configurations define. + */ +char * +xtermVersion(void) +{ + static char vendor_version[] = __vendorversion__; + static char *result; + + if (result == 0) { + char *vendor = vendor_version; + char first[BUFSIZ]; + char second[BUFSIZ]; + + result = CastMallocN(char, strlen(vendor) + 9); + if (result == 0) + result = vendor; + else { + /* some vendors leave trash in this string */ + for (;;) { + if (!strncmp(vendor, "Version ", (size_t) 8)) + vendor += 8; + else if (isspace(CharOf(*vendor))) + ++vendor; + else + break; + } + if (strlen(vendor) < BUFSIZ && + sscanf(vendor, "%[0-9.] %[A-Za-z_0-9.]", first, second) == 2) + sprintf(result, "%s %s(%d)", second, first, XTERM_PATCH); + else + sprintf(result, "%s(%d)", vendor, XTERM_PATCH); + } + } + return result; +} diff -Nru xterm-278/version.h xterm-297/version.h --- xterm-278/version.h 2012-01-12 12:45:36.000000000 +0000 +++ xterm-297/version.h 2013-09-11 00:58:59.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: version.h,v 1.337 2012/01/12 12:45:36 tom Exp $ */ +/* $XTermId: version.h,v 1.372 2013/09/11 00:58:59 tom Exp $ */ /* - * Copyright 1998-2010,2011 by Thomas E. Dickey + * Copyright 1998-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -30,14 +30,21 @@ * authorization. */ +#ifndef included_version_h +#define included_version_h /* * These definitions are used to build the string that's printed in response to * "xterm -version", or embedded in "xterm -help". It usually indicates the - * version of X to which this version of xterm has been built. The number in - * parentheses is my patch number (Thomas E. Dickey). + * version of X to which this version of xterm has been built. The resulting + * number in parentheses is my patch number (Thomas E. Dickey). */ -#define XTERM_PATCH 278 +#define XTERM_PATCH 297 +#define XTERM_DATE 2013-09-10 #ifndef __vendorversion__ #define __vendorversion__ "XTerm" #endif + +extern char *xtermVersion(void); + +#endif /* included_version_h */ diff -Nru xterm-278/vttests/256colors2.pl xterm-297/vttests/256colors2.pl --- xterm-278/vttests/256colors2.pl 2009-10-10 14:45:26.000000000 +0000 +++ xterm-297/vttests/256colors2.pl 2012-09-19 23:32:48.000000000 +0000 @@ -1,9 +1,9 @@ #!/usr/bin/perl -# $XTermId: 256colors2.pl,v 1.10 2009/10/10 14:45:26 tom Exp $ +# $XTermId: 256colors2.pl,v 1.15 2012/09/19 23:32:48 tom Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 1999-2007,2009 by Thomas E. Dickey +# Copyright 1999-2009,2012 by Thomas E. Dickey # Copyright 2002 by Steve Wall # Copyright 1999 by Todd Larason # @@ -41,18 +41,28 @@ use strict; use Getopt::Std; +use Encode 'encode_utf8'; -our ($opt_h, $opt_q, $opt_r); -&getopts('hqr') || die("Usage: $0 [-q] [-r]"); +our ($opt_8, $opt_c, $opt_d, $opt_h, $opt_q, $opt_r, $opt_u); +&getopts('8cdhqru') || die("Usage: $0 [options]"); die("Usage: $0 [options]\n Options: + -8 use 8-bit controls + -c use colons for separating parameter values in SGR 38/48 + -d use rgb values rather than palette index -h display this message -q quieter output by merging all palette initialization -r display the reverse of the usual palette + -u use UTF-8 when emitting 8-bit controls ") if ( $opt_h); +our $cube = 6; +our (@steps); our ($red, $green, $blue); our ($gray, $level, $color); +our ($csi, $osc, $sep, $st); + +our @rgb; sub map_cube($) { my $value = $_[0]; @@ -66,18 +76,61 @@ return $value; } -printf("\x1b]4") if ($opt_q); +sub define_color($$$$) { + my $index = $_[0]; + my $r = $_[1]; + my $g = $_[2]; + my $b = $_[3]; + + printf("%s4", $osc) unless ($opt_q); + printf(";%d;rgb:%2.2x/%2.2x/%2.2x", $index, $r, $g, $b); + printf("%s", $st) unless ($opt_q); + + $rgb[$index] = sprintf "%d%s%d%s%d", $r, $sep, $g, $sep, $b; +} + +sub select_color($) { + my $index = $_[0]; + if ( $opt_d and defined($rgb[$index]) ) { + printf "%s48;2%s%sm ", $csi, $sep, $rgb[$index]; + } else { + printf "%s48;5%s%sm ", $csi, $sep, $index; + } +} + +if ( $opt_8 ) { + $csi = "\x9b"; + $osc = "\x9d"; + $st = "\x9c"; +} else { + $csi = "\x1b["; + $osc = "\x1b]"; + $st = "\x1b\\"; +} + +if ( $opt_c ) { + $sep = ":"; +} else { + $sep = ";"; +} + +if ( $opt_8 and $opt_u ) { + my $lc_ctype=`locale 2>/dev/null | fgrep LC_CTYPE | sed -e 's/^.*=//'`; + if ( $lc_ctype =~ /utf.?8/i ) { + binmode(STDOUT, ":utf8"); + } +} +@steps=(0,95,135,175,215,255); # colors 16-231 are a 6x6x6 color cube -for ($red = 0; $red < 6; $red++) { - for ($green = 0; $green < 6; $green++) { - for ($blue = 0; $blue < 6; $blue++) { - printf("\x1b]4") unless ($opt_q); - printf(";%d;rgb:%2.2x/%2.2x/%2.2x", - 16 + (map_cube($red) * 36) + (map_cube($green) * 6) + map_cube($blue), - ($red ? ($red * 40 + 55) : 0), - ($green ? ($green * 40 + 55) : 0), - ($blue ? ($blue * 40 + 55) : 0)); - printf("\x1b\\") unless ($opt_q); +printf("%s4", $osc) if ($opt_q); +for ($red = 0; $red < $cube; $red++) { + for ($green = 0; $green < $cube; $green++) { + for ($blue = 0; $blue < $cube; $blue++) { + &define_color( + 16 + (map_cube($red) * $cube * $cube) + (map_cube($green) * $cube) + map_cube($blue), + int (@steps[$red]), + int (@steps[$green]), + int (@steps[$blue])); } } } @@ -86,12 +139,9 @@ # black and white for ($gray = 0; $gray < 24; $gray++) { $level = (map_gray($gray) * 10) + 8; - printf("\x1b]4") unless ($opt_q); - printf(";%d;rgb:%2.2x/%2.2x/%2.2x", - 232 + $gray, $level, $level, $level); - printf("\x1b\\") unless ($opt_q); + &define_color(232 + $gray, $level, $level, $level); } -printf("\x1b\\") if ($opt_q); +printf("%s", $st) if ($opt_q); # display the colors @@ -99,23 +149,23 @@ # first the system ones: print "System colors:\n"; for ($color = 0; $color < 8; $color++) { - print "\x1b[48;5;${color}m "; + &select_color($color); } -print "\x1b[0m\n"; +printf "%s0m\n", $csi; for ($color = 8; $color < 16; $color++) { - print "\x1b[48;5;${color}m "; + &select_color($color); } -print "\x1b[0m\n\n"; +printf "%s0m\n\n", $csi; # now the color cube -print "Color cube, 6x6x6:\n"; -for ($green = 0; $green < 6; $green++) { - for ($red = 0; $red < 6; $red++) { - for ($blue = 0; $blue < 6; $blue++) { - $color = 16 + ($red * 36) + ($green * 6) + $blue; - print "\x1b[48;5;${color}m "; +print "Color cube, ${cube}x${cube}x${cube}:\n"; +for ($green = 0; $green < $cube; $green++) { + for ($red = 0; $red < $cube; $red++) { + for ($blue = 0; $blue < $cube; $blue++) { + $color = 16 + ($red * $cube * $cube) + ($green * $cube) + $blue; + &select_color($color); } - print "\x1b[0m "; + printf "%s0m ", $csi; } print "\n"; } @@ -124,6 +174,6 @@ # now the grayscale ramp print "Grayscale ramp:\n"; for ($color = 232; $color < 256; $color++) { - print "\x1b[48;5;${color}m "; + &select_color($color); } -print "\x1b[0m\n"; +printf "%s0m\n", $csi; diff -Nru xterm-278/vttests/88colors2.pl xterm-297/vttests/88colors2.pl --- xterm-278/vttests/88colors2.pl 2009-10-10 14:57:12.000000000 +0000 +++ xterm-297/vttests/88colors2.pl 2012-09-19 23:31:56.000000000 +0000 @@ -1,9 +1,9 @@ #!/usr/bin/perl -# $XTermId: 88colors2.pl,v 1.7 2009/10/10 14:57:12 tom Exp $ +# $XTermId: 88colors2.pl,v 1.11 2012/09/19 23:31:56 tom Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 1999-2007,2009 by Thomas E. Dickey +# Copyright 1999-2009,2012 by Thomas E. Dickey # Copyright 1999 by Steve Wall # # All Rights Reserved @@ -42,19 +42,28 @@ use strict; use Getopt::Std; +use Encode 'encode_utf8'; -our ($opt_h, $opt_q, $opt_r); -&getopts('hqr') || die("Usage: $0 [-q] [-r]"); +our ($opt_8, $opt_c, $opt_d, $opt_h, $opt_q, $opt_r, $opt_u); +&getopts('8cdhqru') || die("Usage: $0 [options]"); die("Usage: $0 [options]\n Options: + -8 use 8-bit controls + -c use colons for separating parameter values in SGR 38/48 + -d use rgb values rather than palette index -h display this message -q quieter output by merging all palette initialization -r display the reverse of the usual palette + -u use UTF-8 when emitting 8-bit controls ") if ( $opt_h); +our $cube = 4; our (@steps); our ($red, $green, $blue); our ($gray, $level, $color); +our ($csi, $osc, $sep, $st); + +our @rgb; sub map_cube($) { my $value = $_[0]; @@ -68,19 +77,61 @@ return $value; } +sub define_color($$$$) { + my $index = $_[0]; + my $r = $_[1]; + my $g = $_[2]; + my $b = $_[3]; + + printf("%s4", $osc) unless ($opt_q); + printf(";%d;rgb:%2.2x/%2.2x/%2.2x", $index, $r, $g, $b); + printf("%s", $st) unless ($opt_q); + + $rgb[$index] = sprintf "%d%s%d%s%d", $r, $sep, $g, $sep, $b; +} + +sub select_color($) { + my $index = $_[0]; + if ( $opt_d and defined($rgb[$index]) ) { + printf "%s48;2%s%sm ", $csi, $sep, $rgb[$index]; + } else { + printf "%s48;5%s%sm ", $csi, $sep, $index; + } +} + +if ( $opt_8 ) { + $csi = "\x9b"; + $osc = "\x9d"; + $st = "\x9c"; +} else { + $csi = "\x1b["; + $osc = "\x1b]"; + $st = "\x1b\\"; +} + +if ( $opt_c ) { + $sep = ":"; +} else { + $sep = ";"; +} + +if ( $opt_8 and $opt_u ) { + my $lc_ctype=`locale 2>/dev/null | fgrep LC_CTYPE | sed -e 's/^.*=//'`; + if ( $lc_ctype =~ /utf.?8/i ) { + binmode(STDOUT, ":utf8"); + } +} # colors 16-79 are a 4x4x4 color cube @steps=(0,139,205,255); -printf("\x1b]4") if ($opt_q); -for ($red = 0; $red < 4; $red++) { - for ($green = 0; $green < 4; $green++) { - for ($blue = 0; $blue < 4; $blue++) { - printf("\x1b]4") unless ($opt_q); - printf(";%d;rgb:%2.2x/%2.2x/%2.2x", - 16 + (map_cube($red) * 16) + (map_cube($green) * 4) + map_cube($blue), +printf("%s4", $osc) if ($opt_q); +for ($red = 0; $red < $cube; $red++) { + for ($green = 0; $green < $cube; $green++) { + for ($blue = 0; $blue < $cube; $blue++) { + &define_color( + 16 + (map_cube($red) * $cube * $cube) + (map_cube($green) * $cube) + map_cube($blue), int (@steps[$red]), int (@steps[$green]), int (@steps[$blue])); - printf("\x1b\\") unless ($opt_q); } } } @@ -90,12 +141,9 @@ for ($gray = 0; $gray < 8; $gray++) { $level = (map_gray($gray) * 23.18181818) + 46.36363636; if( $gray > 0 ) { $level += 23.18181818; } - printf("\x1b]4") unless ($opt_q); - printf(";%d;rgb:%2.2x/%2.2x/%2.2x", - 80 + $gray, int($level), int($level), int($level)); - printf("\x1b\\") unless ($opt_q); + &define_color(80 + $gray, int($level), int($level), int($level)); } -printf("\x1b\\") if ($opt_q); +printf("%s", $st) if ($opt_q); # display the colors @@ -103,23 +151,23 @@ # first the system ones: print "System colors:\n"; for ($color = 0; $color < 8; $color++) { - print "\x1b[48;5;${color}m "; + &select_color($color); } -print "\x1b[0m\n"; +printf "%s0m\n", $csi; for ($color = 8; $color < 16; $color++) { - print "\x1b[48;5;${color}m "; + &select_color($color); } -print "\x1b[0m\n\n"; +printf "%s0m\n\n", $csi; # now the color cube -print "Color cube, 4x4x4:\n"; -for ($green = 0; $green < 4; $green++) { - for ($red = 0; $red < 4; $red++) { - for ($blue = 0; $blue < 4; $blue++) { - $color = 16 + ($red * 16) + ($green * 4) + $blue; - print "\x1b[48;5;${color}m "; +print "Color cube, ${cube}x${cube}x${cube}:\n"; +for ($green = 0; $green < $cube; $green++) { + for ($red = 0; $red < $cube; $red++) { + for ($blue = 0; $blue < $cube; $blue++) { + $color = 16 + ($red * $cube * $cube) + ($green * $cube) + $blue; + &select_color($color); } - print "\x1b[0m "; + printf "%s0m ", $csi; } print "\n"; } @@ -128,6 +176,6 @@ # now the grayscale ramp print "Grayscale ramp:\n"; for ($color = 80; $color < 88; $color++) { - print "\x1b[48;5;${color}m "; + &select_color($color); } -print "\x1b[0m\n"; +printf "%s0m\n", $csi; diff -Nru xterm-278/vttests/query-color.pl xterm-297/vttests/query-color.pl --- xterm-278/vttests/query-color.pl 1970-01-01 00:00:00.000000000 +0000 +++ xterm-297/vttests/query-color.pl 2012-10-22 11:45:58.000000000 +0000 @@ -0,0 +1,168 @@ +#!/usr/bin/perl -w +# $XTermId: query-color.pl,v 1.3 2012/10/22 11:45:58 tom Exp $ +# ----------------------------------------------------------------------------- +# this file is part of xterm +# +# Copyright 2012 by Thomas E. Dickey +# +# 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. +# ----------------------------------------------------------------------------- +# Test the color-query features of xterm using OSC 4. + +# TODO: extend to the OSC 5 colors +# TODO: show result in #rrggbb format. + +use strict; + +use Getopt::Std; +use IO::Handle; + +our ( $opt_s ); +&getopts('s') || die( + "Usage: $0 [options] [color1[-color2]]\n +Options:\n + -s use ^G rather than ST +" +); + +our $ST = $opt_s ? "\007" : "\x1b\\"; + +sub no_reply($) { + open TTY, "+; + close TTY; + system "stty $old"; + if ( defined $reply ) { + die("^C received\n") if ( "$reply" eq "\003" ); + } + return $reply; +} + +sub visible($) { + my $reply = $_[0]; + my $n; + my $result = ""; + for ( $n = 0 ; $n < length($reply) ; ) { + my $c = substr( $reply, $n, 1 ); + if ( $c =~ /[[:print:]]/ ) { + $result .= $c; + } + else { + my $k = ord substr( $reply, $n, 1 ); + if ( ord $k == 0x1b ) { + $result .= "\\E"; + } + elsif ( $k == 0x7f ) { + $result .= "^?"; + } + elsif ( $k == 32 ) { + $result .= "\\s"; + } + elsif ( $k < 32 ) { + $result .= sprintf( "^%c", $k + 64 ); + } + elsif ( $k > 128 ) { + $result .= sprintf( "\\%03o", $k ); + } + else { + $result .= chr($k); + } + } + $n += 1; + } + + return $result; +} + +sub query_color($) { + my $param = $_[0]; + my $reply; + my $n; + my $st = $opt_s ? qr/\007/ : qr/\x1b\\/; + my $op = 4; + my $osc = qr/\x1b]$op/; + my $match = qr/${osc}.*${st}/; + + $reply = get_reply( "\x1b]$op;" . $param . ";?" . $ST ); + + printf "query{%s}%*s", &visible($param), 3 - length($param), " "; + + if ( defined $reply ) { + printf "%2d ", length($reply); + if ( $reply =~ /${match}/ ) { + + $reply =~ s/^${osc}//; + $reply =~ s/^;//; + $reply =~ s/${st}$//; + } + else { + printf "? "; + } + + printf "{%s}", visible($reply); + } + printf "\n"; +} + +sub query_colors($$) { + my $lo = $_[0]; + my $hi = $_[1]; + my $n; + for ( $n = $lo ; $n <= $hi ; ++$n ) { + query_color($n); + } +} + +if ( $#ARGV >= 0 ) { + while ( $#ARGV >= 0 ) { + if ( $ARGV[0] =~ /-/ ) { + my @args = split /-/, $ARGV[0]; + &query_colors ( $args[0], $args[1] ); + } else { + &query_colors ( $ARGV[0], $ARGV[0] ); + } + shift @ARGV; + } +} else { + &query_colors(0,7); +} diff -Nru xterm-278/wcwidth.c xterm-297/wcwidth.c --- xterm-278/wcwidth.c 2009-02-13 19:53:12.000000000 +0000 +++ xterm-297/wcwidth.c 2013-02-03 18:54:31.000000000 +0000 @@ -1,4 +1,4 @@ -/* $XTermId: wcwidth.c,v 1.22 2009/02/13 19:53:12 tom Exp $ */ +/* $XTermId: wcwidth.c,v 1.24 2013/02/03 18:54:31 tom Exp $ */ /* $XFree86: xc/programs/xterm/wcwidth.c,v 1.9 2006/06/19 00:36:52 dickey Exp $ */ @@ -132,54 +132,83 @@ * uniset +cat=Me +cat=Mn +cat=Cf -00AD +1160-11FF +200B c */ static const struct interval combining[] = { - { 0x0300, 0x036F }, { 0x0483, 0x0486 }, { 0x0488, 0x0489 }, - { 0x0591, 0x05BD }, { 0x05BF, 0x05BF }, { 0x05C1, 0x05C2 }, - { 0x05C4, 0x05C5 }, { 0x05C7, 0x05C7 }, { 0x0600, 0x0603 }, - { 0x0610, 0x0615 }, { 0x064B, 0x065E }, { 0x0670, 0x0670 }, - { 0x06D6, 0x06E4 }, { 0x06E7, 0x06E8 }, { 0x06EA, 0x06ED }, + { 0x0300, 0x036F }, { 0x0483, 0x0489 }, { 0x0591, 0x05BD }, + { 0x05BF, 0x05BF }, { 0x05C1, 0x05C2 }, { 0x05C4, 0x05C5 }, + { 0x05C7, 0x05C7 }, { 0x0600, 0x0604 }, { 0x0610, 0x061A }, + { 0x064B, 0x065F }, { 0x0670, 0x0670 }, { 0x06D6, 0x06DD }, + { 0x06DF, 0x06E4 }, { 0x06E7, 0x06E8 }, { 0x06EA, 0x06ED }, { 0x070F, 0x070F }, { 0x0711, 0x0711 }, { 0x0730, 0x074A }, - { 0x07A6, 0x07B0 }, { 0x07EB, 0x07F3 }, { 0x0901, 0x0902 }, - { 0x093C, 0x093C }, { 0x0941, 0x0948 }, { 0x094D, 0x094D }, - { 0x0951, 0x0954 }, { 0x0962, 0x0963 }, { 0x0981, 0x0981 }, - { 0x09BC, 0x09BC }, { 0x09C1, 0x09C4 }, { 0x09CD, 0x09CD }, - { 0x09E2, 0x09E3 }, { 0x0A01, 0x0A02 }, { 0x0A3C, 0x0A3C }, - { 0x0A41, 0x0A42 }, { 0x0A47, 0x0A48 }, { 0x0A4B, 0x0A4D }, - { 0x0A70, 0x0A71 }, { 0x0A81, 0x0A82 }, { 0x0ABC, 0x0ABC }, + { 0x07A6, 0x07B0 }, { 0x07EB, 0x07F3 }, { 0x0816, 0x0819 }, + { 0x081B, 0x0823 }, { 0x0825, 0x0827 }, { 0x0829, 0x082D }, + { 0x0859, 0x085B }, { 0x08E4, 0x08FE }, { 0x0900, 0x0902 }, + { 0x093A, 0x093A }, { 0x093C, 0x093C }, { 0x0941, 0x0948 }, + { 0x094D, 0x094D }, { 0x0951, 0x0957 }, { 0x0962, 0x0963 }, + { 0x0981, 0x0981 }, { 0x09BC, 0x09BC }, { 0x09C1, 0x09C4 }, + { 0x09CD, 0x09CD }, { 0x09E2, 0x09E3 }, { 0x0A01, 0x0A02 }, + { 0x0A3C, 0x0A3C }, { 0x0A41, 0x0A42 }, { 0x0A47, 0x0A48 }, + { 0x0A4B, 0x0A4D }, { 0x0A51, 0x0A51 }, { 0x0A70, 0x0A71 }, + { 0x0A75, 0x0A75 }, { 0x0A81, 0x0A82 }, { 0x0ABC, 0x0ABC }, { 0x0AC1, 0x0AC5 }, { 0x0AC7, 0x0AC8 }, { 0x0ACD, 0x0ACD }, { 0x0AE2, 0x0AE3 }, { 0x0B01, 0x0B01 }, { 0x0B3C, 0x0B3C }, - { 0x0B3F, 0x0B3F }, { 0x0B41, 0x0B43 }, { 0x0B4D, 0x0B4D }, - { 0x0B56, 0x0B56 }, { 0x0B82, 0x0B82 }, { 0x0BC0, 0x0BC0 }, - { 0x0BCD, 0x0BCD }, { 0x0C3E, 0x0C40 }, { 0x0C46, 0x0C48 }, - { 0x0C4A, 0x0C4D }, { 0x0C55, 0x0C56 }, { 0x0CBC, 0x0CBC }, - { 0x0CBF, 0x0CBF }, { 0x0CC6, 0x0CC6 }, { 0x0CCC, 0x0CCD }, - { 0x0CE2, 0x0CE3 }, { 0x0D41, 0x0D43 }, { 0x0D4D, 0x0D4D }, + { 0x0B3F, 0x0B3F }, { 0x0B41, 0x0B44 }, { 0x0B4D, 0x0B4D }, + { 0x0B56, 0x0B56 }, { 0x0B62, 0x0B63 }, { 0x0B82, 0x0B82 }, + { 0x0BC0, 0x0BC0 }, { 0x0BCD, 0x0BCD }, { 0x0C3E, 0x0C40 }, + { 0x0C46, 0x0C48 }, { 0x0C4A, 0x0C4D }, { 0x0C55, 0x0C56 }, + { 0x0C62, 0x0C63 }, { 0x0CBC, 0x0CBC }, { 0x0CBF, 0x0CBF }, + { 0x0CC6, 0x0CC6 }, { 0x0CCC, 0x0CCD }, { 0x0CE2, 0x0CE3 }, + { 0x0D41, 0x0D44 }, { 0x0D4D, 0x0D4D }, { 0x0D62, 0x0D63 }, { 0x0DCA, 0x0DCA }, { 0x0DD2, 0x0DD4 }, { 0x0DD6, 0x0DD6 }, { 0x0E31, 0x0E31 }, { 0x0E34, 0x0E3A }, { 0x0E47, 0x0E4E }, { 0x0EB1, 0x0EB1 }, { 0x0EB4, 0x0EB9 }, { 0x0EBB, 0x0EBC }, { 0x0EC8, 0x0ECD }, { 0x0F18, 0x0F19 }, { 0x0F35, 0x0F35 }, { 0x0F37, 0x0F37 }, { 0x0F39, 0x0F39 }, { 0x0F71, 0x0F7E }, - { 0x0F80, 0x0F84 }, { 0x0F86, 0x0F87 }, { 0x0F90, 0x0F97 }, + { 0x0F80, 0x0F84 }, { 0x0F86, 0x0F87 }, { 0x0F8D, 0x0F97 }, { 0x0F99, 0x0FBC }, { 0x0FC6, 0x0FC6 }, { 0x102D, 0x1030 }, - { 0x1032, 0x1032 }, { 0x1036, 0x1037 }, { 0x1039, 0x1039 }, - { 0x1058, 0x1059 }, { 0x1160, 0x11FF }, { 0x135F, 0x135F }, + { 0x1032, 0x1037 }, { 0x1039, 0x103A }, { 0x103D, 0x103E }, + { 0x1058, 0x1059 }, { 0x105E, 0x1060 }, { 0x1071, 0x1074 }, + { 0x1082, 0x1082 }, { 0x1085, 0x1086 }, { 0x108D, 0x108D }, + { 0x109D, 0x109D }, { 0x1160, 0x11FF }, { 0x135D, 0x135F }, { 0x1712, 0x1714 }, { 0x1732, 0x1734 }, { 0x1752, 0x1753 }, { 0x1772, 0x1773 }, { 0x17B4, 0x17B5 }, { 0x17B7, 0x17BD }, { 0x17C6, 0x17C6 }, { 0x17C9, 0x17D3 }, { 0x17DD, 0x17DD }, { 0x180B, 0x180D }, { 0x18A9, 0x18A9 }, { 0x1920, 0x1922 }, { 0x1927, 0x1928 }, { 0x1932, 0x1932 }, { 0x1939, 0x193B }, - { 0x1A17, 0x1A18 }, { 0x1B00, 0x1B03 }, { 0x1B34, 0x1B34 }, - { 0x1B36, 0x1B3A }, { 0x1B3C, 0x1B3C }, { 0x1B42, 0x1B42 }, - { 0x1B6B, 0x1B73 }, { 0x1DC0, 0x1DCA }, { 0x1DFE, 0x1DFF }, - { 0x200B, 0x200F }, { 0x202A, 0x202E }, { 0x2060, 0x2063 }, - { 0x206A, 0x206F }, { 0x20D0, 0x20EF }, { 0x302A, 0x302F }, - { 0x3099, 0x309A }, { 0xA806, 0xA806 }, { 0xA80B, 0xA80B }, - { 0xA825, 0xA826 }, { 0xFB1E, 0xFB1E }, { 0xFE00, 0xFE0F }, - { 0xFE20, 0xFE23 }, { 0xFEFF, 0xFEFF }, { 0xFFF9, 0xFFFB }, + { 0x1A17, 0x1A18 }, { 0x1A56, 0x1A56 }, { 0x1A58, 0x1A5E }, + { 0x1A60, 0x1A60 }, { 0x1A62, 0x1A62 }, { 0x1A65, 0x1A6C }, + { 0x1A73, 0x1A7C }, { 0x1A7F, 0x1A7F }, { 0x1B00, 0x1B03 }, + { 0x1B34, 0x1B34 }, { 0x1B36, 0x1B3A }, { 0x1B3C, 0x1B3C }, + { 0x1B42, 0x1B42 }, { 0x1B6B, 0x1B73 }, { 0x1B80, 0x1B81 }, + { 0x1BA2, 0x1BA5 }, { 0x1BA8, 0x1BA9 }, { 0x1BAB, 0x1BAB }, + { 0x1BE6, 0x1BE6 }, { 0x1BE8, 0x1BE9 }, { 0x1BED, 0x1BED }, + { 0x1BEF, 0x1BF1 }, { 0x1C2C, 0x1C33 }, { 0x1C36, 0x1C37 }, + { 0x1CD0, 0x1CD2 }, { 0x1CD4, 0x1CE0 }, { 0x1CE2, 0x1CE8 }, + { 0x1CED, 0x1CED }, { 0x1CF4, 0x1CF4 }, { 0x1DC0, 0x1DE6 }, + { 0x1DFC, 0x1DFF }, { 0x200B, 0x200F }, { 0x202A, 0x202E }, + { 0x2060, 0x2064 }, { 0x206A, 0x206F }, { 0x20D0, 0x20F0 }, + { 0x2CEF, 0x2CF1 }, { 0x2D7F, 0x2D7F }, { 0x2DE0, 0x2DFF }, + { 0x302A, 0x302D }, { 0x3099, 0x309A }, { 0xA66F, 0xA672 }, + { 0xA674, 0xA67D }, { 0xA69F, 0xA69F }, { 0xA6F0, 0xA6F1 }, + { 0xA802, 0xA802 }, { 0xA806, 0xA806 }, { 0xA80B, 0xA80B }, + { 0xA825, 0xA826 }, { 0xA8C4, 0xA8C4 }, { 0xA8E0, 0xA8F1 }, + { 0xA926, 0xA92D }, { 0xA947, 0xA951 }, { 0xA980, 0xA982 }, + { 0xA9B3, 0xA9B3 }, { 0xA9B6, 0xA9B9 }, { 0xA9BC, 0xA9BC }, + { 0xAA29, 0xAA2E }, { 0xAA31, 0xAA32 }, { 0xAA35, 0xAA36 }, + { 0xAA43, 0xAA43 }, { 0xAA4C, 0xAA4C }, { 0xAAB0, 0xAAB0 }, + { 0xAAB2, 0xAAB4 }, { 0xAAB7, 0xAAB8 }, { 0xAABE, 0xAABF }, + { 0xAAC1, 0xAAC1 }, { 0xAAEC, 0xAAED }, { 0xAAF6, 0xAAF6 }, + { 0xABE5, 0xABE5 }, { 0xABE8, 0xABE8 }, { 0xABED, 0xABED }, + { 0xFB1E, 0xFB1E }, { 0xFE00, 0xFE0F }, { 0xFE20, 0xFE26 }, + { 0xFEFF, 0xFEFF }, { 0xFFF9, 0xFFFB }, { 0x101FD, 0x101FD }, { 0x10A01, 0x10A03 }, { 0x10A05, 0x10A06 }, { 0x10A0C, 0x10A0F }, - { 0x10A38, 0x10A3A }, { 0x10A3F, 0x10A3F }, { 0x1D167, 0x1D169 }, - { 0x1D173, 0x1D182 }, { 0x1D185, 0x1D18B }, { 0x1D1AA, 0x1D1AD }, - { 0x1D242, 0x1D244 }, { 0xE0001, 0xE0001 }, { 0xE0020, 0xE007F }, - { 0xE0100, 0xE01EF } + { 0x10A38, 0x10A3A }, { 0x10A3F, 0x10A3F }, { 0x11001, 0x11001 }, + { 0x11038, 0x11046 }, { 0x11080, 0x11081 }, { 0x110B3, 0x110B6 }, + { 0x110B9, 0x110BA }, { 0x110BD, 0x110BD }, { 0x11100, 0x11102 }, + { 0x11127, 0x1112B }, { 0x1112D, 0x11134 }, { 0x11180, 0x11181 }, + { 0x111B6, 0x111BE }, { 0x116AB, 0x116AB }, { 0x116AD, 0x116AD }, + { 0x116B0, 0x116B5 }, { 0x116B7, 0x116B7 }, { 0x16F8F, 0x16F92 }, + { 0x1D167, 0x1D169 }, { 0x1D173, 0x1D182 }, { 0x1D185, 0x1D18B }, + { 0x1D1AA, 0x1D1AD }, { 0x1D242, 0x1D244 }, { 0xE0001, 0xE0001 }, + { 0xE0020, 0xE007F }, { 0xE0100, 0xE01EF } }; /* test for 8-bit control characters */ @@ -283,29 +312,34 @@ { 0x2113, 0x2113 }, { 0x2116, 0x2116 }, { 0x2121, 0x2122 }, { 0x2126, 0x2126 }, { 0x212B, 0x212B }, { 0x2153, 0x2154 }, { 0x215B, 0x215E }, { 0x2160, 0x216B }, { 0x2170, 0x2179 }, - { 0x2190, 0x2199 }, { 0x21B8, 0x21B9 }, { 0x21D2, 0x21D2 }, - { 0x21D4, 0x21D4 }, { 0x21E7, 0x21E7 }, { 0x2200, 0x2200 }, - { 0x2202, 0x2203 }, { 0x2207, 0x2208 }, { 0x220B, 0x220B }, - { 0x220F, 0x220F }, { 0x2211, 0x2211 }, { 0x2215, 0x2215 }, - { 0x221A, 0x221A }, { 0x221D, 0x2220 }, { 0x2223, 0x2223 }, - { 0x2225, 0x2225 }, { 0x2227, 0x222C }, { 0x222E, 0x222E }, - { 0x2234, 0x2237 }, { 0x223C, 0x223D }, { 0x2248, 0x2248 }, - { 0x224C, 0x224C }, { 0x2252, 0x2252 }, { 0x2260, 0x2261 }, - { 0x2264, 0x2267 }, { 0x226A, 0x226B }, { 0x226E, 0x226F }, - { 0x2282, 0x2283 }, { 0x2286, 0x2287 }, { 0x2295, 0x2295 }, - { 0x2299, 0x2299 }, { 0x22A5, 0x22A5 }, { 0x22BF, 0x22BF }, - { 0x2312, 0x2312 }, { 0x2460, 0x24E9 }, { 0x24EB, 0x254B }, - { 0x2550, 0x2573 }, { 0x2580, 0x258F }, { 0x2592, 0x2595 }, - { 0x25A0, 0x25A1 }, { 0x25A3, 0x25A9 }, { 0x25B2, 0x25B3 }, - { 0x25B6, 0x25B7 }, { 0x25BC, 0x25BD }, { 0x25C0, 0x25C1 }, - { 0x25C6, 0x25C8 }, { 0x25CB, 0x25CB }, { 0x25CE, 0x25D1 }, - { 0x25E2, 0x25E5 }, { 0x25EF, 0x25EF }, { 0x2605, 0x2606 }, - { 0x2609, 0x2609 }, { 0x260E, 0x260F }, { 0x2614, 0x2615 }, - { 0x261C, 0x261C }, { 0x261E, 0x261E }, { 0x2640, 0x2640 }, - { 0x2642, 0x2642 }, { 0x2660, 0x2661 }, { 0x2663, 0x2665 }, - { 0x2667, 0x266A }, { 0x266C, 0x266D }, { 0x266F, 0x266F }, - { 0x273D, 0x273D }, { 0x2776, 0x277F }, { 0xE000, 0xF8FF }, - { 0xFFFD, 0xFFFD }, { 0xF0000, 0xFFFFD }, { 0x100000, 0x10FFFD } + { 0x2189, 0x2189 }, { 0x2190, 0x2199 }, { 0x21B8, 0x21B9 }, + { 0x21D2, 0x21D2 }, { 0x21D4, 0x21D4 }, { 0x21E7, 0x21E7 }, + { 0x2200, 0x2200 }, { 0x2202, 0x2203 }, { 0x2207, 0x2208 }, + { 0x220B, 0x220B }, { 0x220F, 0x220F }, { 0x2211, 0x2211 }, + { 0x2215, 0x2215 }, { 0x221A, 0x221A }, { 0x221D, 0x2220 }, + { 0x2223, 0x2223 }, { 0x2225, 0x2225 }, { 0x2227, 0x222C }, + { 0x222E, 0x222E }, { 0x2234, 0x2237 }, { 0x223C, 0x223D }, + { 0x2248, 0x2248 }, { 0x224C, 0x224C }, { 0x2252, 0x2252 }, + { 0x2260, 0x2261 }, { 0x2264, 0x2267 }, { 0x226A, 0x226B }, + { 0x226E, 0x226F }, { 0x2282, 0x2283 }, { 0x2286, 0x2287 }, + { 0x2295, 0x2295 }, { 0x2299, 0x2299 }, { 0x22A5, 0x22A5 }, + { 0x22BF, 0x22BF }, { 0x2312, 0x2312 }, { 0x2460, 0x24E9 }, + { 0x24EB, 0x254B }, { 0x2550, 0x2573 }, { 0x2580, 0x258F }, + { 0x2592, 0x2595 }, { 0x25A0, 0x25A1 }, { 0x25A3, 0x25A9 }, + { 0x25B2, 0x25B3 }, { 0x25B6, 0x25B7 }, { 0x25BC, 0x25BD }, + { 0x25C0, 0x25C1 }, { 0x25C6, 0x25C8 }, { 0x25CB, 0x25CB }, + { 0x25CE, 0x25D1 }, { 0x25E2, 0x25E5 }, { 0x25EF, 0x25EF }, + { 0x2605, 0x2606 }, { 0x2609, 0x2609 }, { 0x260E, 0x260F }, + { 0x2614, 0x2615 }, { 0x261C, 0x261C }, { 0x261E, 0x261E }, + { 0x2640, 0x2640 }, { 0x2642, 0x2642 }, { 0x2660, 0x2661 }, + { 0x2663, 0x2665 }, { 0x2667, 0x266A }, { 0x266C, 0x266D }, + { 0x266F, 0x266F }, { 0x269E, 0x269F }, { 0x26BE, 0x26BF }, + { 0x26C4, 0x26CD }, { 0x26CF, 0x26E1 }, { 0x26E3, 0x26E3 }, + { 0x26E8, 0x26FF }, { 0x273D, 0x273D }, { 0x2757, 0x2757 }, + { 0x2776, 0x277F }, { 0x2B55, 0x2B59 }, { 0x3248, 0x324F }, + { 0xE000, 0xF8FF }, { 0xFFFD, 0xFFFD }, { 0x1F100, 0x1F10A }, + { 0x1F110, 0x1F12D }, { 0x1F130, 0x1F169 }, { 0x1F170, 0x1F19A }, + { 0xF0000, 0xFFFFD }, { 0x100000, 0x10FFFD } }; /* binary search in table of non-spacing characters */ diff -Nru xterm-278/xcharmouse.h xterm-297/xcharmouse.h --- xterm-278/xcharmouse.h 2011-12-08 21:54:12.000000000 +0000 +++ xterm-297/xcharmouse.h 2012-09-26 00:39:14.000000000 +0000 @@ -1,4 +1,4 @@ -/* $XTermId: xcharmouse.h,v 1.15 2011/12/08 21:54:12 tom Exp $ */ +/* $XTermId: xcharmouse.h,v 1.17 2012/09/26 00:39:14 tom Exp $ */ /************************************************************ @@ -30,10 +30,12 @@ /* *INDENT-OFF* */ /* - * Macros for dpmodes + * Macros for dpmodes (Thomas Dickey and others): * J. Bacon, acadix@execpc.com, June 1998 * Steve Wall, September 1999 * Ilya Zakharevich, August 2002 + * Ryan Johnson, August 2010 + * Egmont Koblinger, December 2011 */ /* DECSET arguments for turning on mouse reporting modes */ @@ -52,6 +54,8 @@ #define SET_SGR_EXT_MODE_MOUSE 1006 #define SET_URXVT_EXT_MODE_MOUSE 1015 +#define SET_ALTERNATE_SCROLL 1007 /* wheel mouse may send cursor-keys */ + #define SET_BUTTON1_MOVE_POINT 2001 /* click1 emit Esc seq to move point*/ #define SET_BUTTON2_MOVE_POINT 2002 /* press2 emit Esc seq to move point*/ #define SET_DBUTTON3_DELETE 2003 /* Double click-3 deletes */ diff -Nru xterm-278/xstrings.c xterm-297/xstrings.c --- xterm-278/xstrings.c 2011-09-11 20:20:12.000000000 +0000 +++ xterm-297/xstrings.c 2013-02-03 22:11:25.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: xstrings.c,v 1.47 2011/09/11 20:20:12 tom Exp $ */ +/* $XTermId: xstrings.c,v 1.57 2013/02/03 22:11:25 tom Exp $ */ /* - * Copyright 2000-2010,2011 by Thomas E. Dickey + * Copyright 2000-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -64,10 +64,6 @@ char *cp; cp = strrchr(name, '/'); -#ifdef __UNIXOS2__ - if (cp == 0) - cp = strrchr(name, '\\'); -#endif return (cp ? cp + 1 : name); } @@ -141,42 +137,21 @@ char * x_getenv(const char *name) { - return x_strdup(x_nonempty(getenv(name))); + char *result; + result = x_strdup(x_nonempty(getenv(name))); + TRACE2(("getenv(%s) %s\n", name, result)); + return result; } -/* - * Call this with in_out pointing to data filled in by x_getpwnam() or by - * x_getpwnam(). It finds the user's logon name, if possible. As a side - * effect, it updates in_out to fill in possibly more-relevant data, i.e., - * in case there is more than one alias for the same uid. - */ -char * -x_getlogin(uid_t uid, struct passwd *in_out) +static char * +login_alias(char *login_name, uid_t uid, struct passwd *in_out) { - char *login_name = NULL; - -#ifdef HAVE_GETLOGIN - login_name = getlogin(); -#endif - - /* - * Of course getlogin() will fail if we're started from a window-manager, - * since there's no controlling terminal to fuss with. In that case, try - * to get something useful from the user's $LOGNAME or $USER environment - * variables. - */ - if (login_name == NULL) { - login_name = x_getenv("LOGNAME"); - if (login_name == NULL) - login_name = x_getenv("USER"); - } - /* * If the logon-name differs from the value we get by looking in the * password file, check if it does correspond to the same uid. If so, * allow that as an alias for the uid. */ - if (login_name != NULL + if (!IsEmpty(login_name) && strcmp(login_name, in_out->pw_name)) { struct passwd pw2; @@ -184,23 +159,55 @@ uid_t uid2 = pw2.pw_uid; struct passwd pw3; - if (!x_getpwuid(uid, &pw3) - || (uid_t) pw3.pw_uid != uid2) { - login_name = NULL; - } else { + if (x_getpwuid(uid, &pw3) + && ((uid_t) pw3.pw_uid == uid2)) { /* use the other passwd-data including shell */ alloc_pw(in_out, &pw2); + } else { + free(login_name); + login_name = NULL; } - } else { - (void) x_getpwuid(uid, in_out); } } + return login_name; +} + +/* + * Call this with in_out pointing to data filled in by x_getpwnam() or by + * x_getpwnam(). It finds the user's logon name, if possible. As a side + * effect, it updates in_out to fill in possibly more-relevant data, i.e., + * in case there is more than one alias for the same uid. + */ +char * +x_getlogin(uid_t uid, struct passwd *in_out) +{ + char *login_name = NULL; + + login_name = login_alias(x_getenv("LOGNAME"), uid, in_out); + if (IsEmpty(login_name)) { + free(login_name); + login_name = login_alias(x_getenv("USER"), uid, in_out); + } +#ifdef HAVE_GETLOGIN + /* + * Of course getlogin() will fail if we're started from a window-manager, + * since there's no controlling terminal to fuss with. For that reason, we + * tried first to get something useful from the user's $LOGNAME or $USER + * environment variables. + */ + if (IsEmpty(login_name)) { + TRACE2(("...try getlogin\n")); + free(login_name); + login_name = login_alias(x_strdup(getlogin()), uid, in_out); + } +#endif - if (login_name == NULL) - login_name = in_out->pw_name; - if (login_name != NULL) - login_name = x_strdup(login_name); + if (IsEmpty(login_name)) { + free(login_name); + login_name = x_strdup(in_out->pw_name); + } + TRACE2(("x_getloginid ->%s\n", NonNull(login_name))); return login_name; } @@ -214,7 +221,7 @@ struct passwd *ptr = getpwnam(name); Boolean code; - if (OkPasswd(ptr)) { + if (ptr != 0 && OkPasswd(ptr)) { code = True; alloc_pw(result, ptr); } else { @@ -234,13 +241,14 @@ struct passwd *ptr = getpwuid((uid_t) uid); Boolean code; - if (OkPasswd(ptr)) { + if (ptr != 0 && OkPasswd(ptr)) { code = True; alloc_pw(result, ptr); } else { code = False; memset(result, 0, sizeof(*result)); } + TRACE2(("x_getpwuid(%d) %d\n", (int) uid, (int) code)); return code; } @@ -294,6 +302,14 @@ return s; } +static const char * +skip_blanks(const char *s) +{ + while (isspace(CharOf(*s))) + ++s; + return s; +} + /* * Split a command-string into an argv[]-style array. */ @@ -303,38 +319,43 @@ char **result = 0; if (command != 0) { - char *blob = x_strdup(command); + const char *first = skip_blanks(command); + char *blob = x_strdup(first); size_t count; size_t n; int state; int pass; - for (pass = 0; pass < 2; ++pass) { - for (n = count = 0, state = 0; command[n] != '\0'; ++n) { - switch (state) { - case 0: - if (!isspace(CharOf(command[n]))) { - state = 1; - if (pass) - result[count] = blob + n; - ++count; - } else { - blob[n] = '\0'; + if (blob != 0) { + for (pass = 0; pass < 2; ++pass) { + for (n = count = 0, state = 0; first[n] != '\0'; ++n) { + switch (state) { + case 0: + if (!isspace(CharOf(first[n]))) { + state = 1; + if (pass) + result[count] = blob + n; + ++count; + } else { + blob[n] = '\0'; + } + break; + case 1: + if (isspace(CharOf(first[n]))) { + blob[n] = '\0'; + state = 0; + } + break; } - break; - case 1: - if (isspace(CharOf(command[n]))) { - blob[n] = '\0'; - state = 0; + } + if (!pass) { + result = TypeCallocN(char *, count + 1); + if (!result) { + free(blob); + break; } - break; } } - if (!pass) { - result = TypeCallocN(char *, count + 1); - if (!result) - break; - } } } else { result = TypeCalloc(char *); @@ -342,6 +363,19 @@ return result; } +/* + * Free storage allocated by x_splitargs(). + */ +void +x_freeargs(char **argv) +{ + if (argv != 0) { + if (*argv != 0) + free(*argv); + free(argv); + } +} + int x_strcasecmp(const char *s1, const char *s2) { @@ -417,17 +451,19 @@ if (source != 0 && *source != '\0') { char *t = x_strdup(source); - s = t; - d = s; - while (isspace(CharOf(*s))) - ++s; - while ((*d++ = *s++) != '\0') { - ; - } - if (*t != '\0') { - s = t + strlen(t); - while (s != t && isspace(CharOf(s[-1]))) { - *--s = '\0'; + if (t != 0) { + s = t; + d = s; + while (isspace(CharOf(*s))) + ++s; + while ((*d++ = *s++) != '\0') { + ; + } + if (*t != '\0') { + s = t + strlen(t); + while (s != t && isspace(CharOf(s[-1]))) { + *--s = '\0'; + } } } result = t; diff -Nru xterm-278/xstrings.h xterm-297/xstrings.h --- xterm-278/xstrings.h 2011-09-11 20:20:22.000000000 +0000 +++ xterm-297/xstrings.h 2012-11-26 21:55:10.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: xstrings.h,v 1.25 2011/09/11 20:20:22 tom Exp $ */ +/* $XTermId: xstrings.h,v 1.28 2012/11/26 21:55:10 tom Exp $ */ /* - * Copyright 2000-2009,2011 by Thomas E. Dickey + * Copyright 2000-2011,2012 by Thomas E. Dickey * * All Rights Reserved * @@ -59,6 +59,7 @@ extern int x_strncasecmp(const char * /* s1 */, const char * /* s2 */, unsigned /* n */); extern unsigned x_countargv(char ** /* argv */); extern void x_appendargv(char ** /* target */, char ** /* source */); +extern void x_freeargs(char ** /* argv */); /* *INDENT-ON* */ diff -Nru xterm-278/xterm.desktop xterm-297/xterm.desktop --- xterm-278/xterm.desktop 2010-06-15 10:58:13.000000000 +0000 +++ xterm-297/xterm.desktop 2012-06-24 22:20:29.000000000 +0000 @@ -1,8 +1,8 @@ -# $XTermId: xterm.desktop,v 1.10 2010/06/15 10:58:13 tom Exp $ +# $XTermId: xterm.desktop,v 1.14 2012/06/24 22:20:29 tom Exp $ # ----------------------------------------------------------------------------- # this file is part of xterm # -# Copyright 2006-2007,2010 by Thomas E. Dickey +# Copyright 2006-2010,2012 by Thomas E. Dickey # # All Rights Reserved # @@ -32,6 +32,7 @@ # ----------------------------------------------------------------------------- [Desktop Entry] Name=XTerm +#GenericName=Terminal Comment=standard terminal emulator for the X window system Exec=xterm Terminal=false diff -Nru xterm-278/xterm.h xterm-297/xterm.h --- xterm-278/xterm.h 2011-12-27 09:51:07.000000000 +0000 +++ xterm-297/xterm.h 2013-09-10 10:55:04.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: xterm.h,v 1.673 2011/12/27 09:51:07 tom Exp $ */ +/* $XTermId: xterm.h,v 1.722 2013/09/10 10:55:04 tom Exp $ */ /* - * Copyright 1999-2010,2011 by Thomas E. Dickey + * Copyright 1999-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -63,6 +63,7 @@ #define IGNORE_RC(func) (void) func #endif /* gcc workarounds */ +#undef bcopy #include #ifndef HAVE_CONFIG_H @@ -122,7 +123,7 @@ #define HAVE_TCGETATTR 1 #endif -#if defined(__UNIXOS2__) || defined(__SCO__) || defined(__UNIXWARE__) +#if defined(__SCO__) || defined(__UNIXWARE__) #define USE_TERMCAP 1 #endif @@ -283,7 +284,21 @@ /***====================================================================***/ -#include +#define PROTO_XT_ACTIONS_ARGS \ + (Widget w, XEvent *event, String *params, Cardinal *num_params) + +#define PROTO_XT_CALLBACK_ARGS \ + (Widget gw, XtPointer closure, XtPointer data) + +#define PROTO_XT_CVT_SELECT_ARGS \ + (Widget w, Atom *selection, Atom *target, Atom *type, XtPointer *value, unsigned long *length, int *format) + +#define PROTO_XT_EV_HANDLER_ARGS \ + (Widget w, XtPointer closure, XEvent *event, Boolean *cont) + +#define PROTO_XT_SEL_CB_ARGS \ + (Widget w, XtPointer client_data, Atom *selection, Atom *type, XtPointer value, unsigned long *length, int *format) + #include #if (XtSpecificationRelease >= 6) && !defined(NO_XPOLL_H) && !defined(sun) @@ -324,10 +339,6 @@ #include -#if defined(__UNIXOS2__) && !defined(XTERM_MAIN) -#define environ gblenvp /* circumvent a bug */ -#endif - #if !defined(VMS) && !(defined(linux) && defined(__USE_GNU)) && !defined(__hpux) && !defined(_ALL_SOURCE) && !defined(__osf__) extern char **environ; #endif @@ -342,6 +353,7 @@ #define XtNallowC1Printable "allowC1Printable" #define XtNallowColorOps "allowColorOps" #define XtNallowFontOps "allowFontOps" +#define XtNallowPasteControls "allowPasteControls" #define XtNallowScrollLock "allowScrollLock" #define XtNallowSendEvents "allowSendEvents" #define XtNallowTcapOps "allowTcapOps" @@ -349,12 +361,14 @@ #define XtNallowWindowOps "allowWindowOps" #define XtNaltIsNotMeta "altIsNotMeta" #define XtNaltSendsEscape "altSendsEscape" +#define XtNalternateScroll "alternateScroll" #define XtNalwaysBoldMode "alwaysBoldMode" #define XtNalwaysHighlight "alwaysHighlight" #define XtNalwaysUseMods "alwaysUseMods" #define XtNanswerbackString "answerbackString" #define XtNappcursorDefault "appcursorDefault" #define XtNappkeypadDefault "appkeypadDefault" +#define XtNassumeAllChars "assumeAllChars" #define XtNautoWrap "autoWrap" #define XtNawaitInput "awaitInput" #define XtNbackarrowKey "backarrowKey" @@ -369,6 +383,7 @@ #define XtNbrokenStringTerm "brokenStringTerm" #define XtNc132 "c132" #define XtNcacheDoublesize "cacheDoublesize" +#define XtNcdXtraScroll "cdXtraScroll" #define XtNcharClass "charClass" #define XtNcjkWidth "cjkWidth" #define XtNcolorAttrMode "colorAttrMode" @@ -425,6 +440,7 @@ #define XtNhighlightTextColor "highlightTextColor" #define XtNhpLowerleftBugCompat "hpLowerleftBugCompat" #define XtNi18nSelections "i18nSelections" +#define XtNiconHint "iconHint" #define XtNinitialFont "initialFont" #define XtNinternalBorder "internalBorder" #define XtNitalicULMode "italicULMode" @@ -448,6 +464,7 @@ #define XtNmkWidth "mkWidth" #define XtNmodifyCursorKeys "modifyCursorKeys" #define XtNmodifyFunctionKeys "modifyFunctionKeys" +#define XtNmodifyKeyboard "modifyKeyboard" #define XtNmodifyKeypadKeys "modifyKeypadKeys" #define XtNmodifyOtherKeys "modifyOtherKeys" #define XtNmodifyStringKeys "modifyStringKeys" @@ -461,6 +478,7 @@ #define XtNpointerMode "pointerMode" #define XtNpointerShape "pointerShape" #define XtNpopOnBell "popOnBell" +#define XtNprecompose "precompose" #define XtNprintAttributes "printAttributes" #define XtNprinterAutoClose "printerAutoClose" #define XtNprinterCommand "printerCommand" @@ -468,10 +486,11 @@ #define XtNprinterExtent "printerExtent" #define XtNprinterFormFeed "printerFormFeed" #define XtNprinterNewLine "printerNewLine" +#define XtNprivateColorRegisters "privateColorRegisters" #define XtNquietGrab "quietGrab" #define XtNrenderFont "renderFont" #define XtNresizeGravity "resizeGravity" -#define XtNretryInputMethod "retryInputMethod" +#define XtNretryInputMethod "retryInputMethod" #define XtNreverseWrap "reverseWrap" #define XtNrightScrollBar "rightScrollBar" #define XtNsaveLines "saveLines" @@ -488,6 +507,7 @@ #define XtNshowMissingGlyphs "showMissingGlyphs" #define XtNshowWrapMarks "showWrapMarks" #define XtNsignalInhibit "signalInhibit" +#define XtNsixelScrolling "sixelScrolling" #define XtNtekGeometry "tekGeometry" #define XtNtekInhibit "tekInhibit" #define XtNtekSmall "tekSmall" @@ -522,6 +542,7 @@ #define XtCAllowC1Printable "AllowC1Printable" #define XtCAllowColorOps "AllowColorOps" #define XtCAllowFontOps "AllowFontOps" +#define XtCAllowPasteControls "AllowPasteControls" #define XtCAllowScrollLock "AllowScrollLock" #define XtCAllowSendEvents "AllowSendEvents" #define XtCAllowTcapOps "AllowTcapOps" @@ -535,6 +556,7 @@ #define XtCAnswerbackString "AnswerbackString" #define XtCAppcursorDefault "AppcursorDefault" #define XtCAppkeypadDefault "AppkeypadDefault" +#define XtCAssumeAllChars "AssumeAllChars" #define XtCAutoWrap "AutoWrap" #define XtCAwaitInput "AwaitInput" #define XtCBackarrowKey "BackarrowKey" @@ -548,6 +570,7 @@ #define XtCBrokenStringTerm "BrokenStringTerm" #define XtCC132 "C132" #define XtCCacheDoublesize "CacheDoublesize" +#define XtCCdXtraScroll "CdXtraScroll" #define XtCCharClass "CharClass" #define XtCCjkWidth "CjkWidth" #define XtCColorAttrMode "ColorAttrMode" @@ -598,6 +621,7 @@ #define XtCHighlightSelection "HighlightSelection" #define XtCHpLowerleftBugCompat "HpLowerleftBugCompat" #define XtCI18nSelections "I18nSelections" +#define XtCIconHint "IconHint" #define XtCInitialFont "InitialFont" #define XtCJumpScroll "JumpScroll" #define XtCKeepSelection "KeepSelection" @@ -614,11 +638,12 @@ #define XtCMenuBar "MenuBar" #define XtCMenuHeight "MenuHeight" #define XtCMetaSendsEscape "MetaSendsEscape" -#define XtCMkSamplePass "MkSamplePass" -#define XtCMkSampleSize "MkSampleSize" +#define XtCMkSamplePass "MkSamplePass" +#define XtCMkSampleSize "MkSampleSize" #define XtCMkWidth "MkWidth" #define XtCModifyCursorKeys "ModifyCursorKeys" #define XtCModifyFunctionKeys "ModifyFunctionKeys" +#define XtCModifyKeyboard "ModifyKeyboard" #define XtCModifyKeypadKeys "ModifyKeypadKeys" #define XtCModifyOtherKeys "ModifyOtherKeys" #define XtCModifyStringKeys "ModifyStringKeys" @@ -628,6 +653,7 @@ #define XtCOldXtermFKeys "OldXtermFKeys" #define XtCPointerMode "PointerMode" #define XtCPopOnBell "PopOnBell" +#define XtCPrecompose "Precompose" #define XtCPrintAttributes "PrintAttributes" #define XtCPrinterAutoClose "PrinterAutoClose" #define XtCPrinterCommand "PrinterCommand" @@ -635,10 +661,11 @@ #define XtCPrinterExtent "PrinterExtent" #define XtCPrinterFormFeed "PrinterFormFeed" #define XtCPrinterNewLine "PrinterNewLine" +#define XtCPrivateColorRegisters "PrivateColorRegisters" #define XtCQuietGrab "QuietGrab" #define XtCRenderFont "RenderFont" #define XtCResizeGravity "ResizeGravity" -#define XtCRetryInputMethod "RetryInputMethod" +#define XtCRetryInputMethod "RetryInputMethod" #define XtCReverseWrap "ReverseWrap" #define XtCRightScrollBar "RightScrollBar" #define XtCSaveLines "SaveLines" @@ -654,6 +681,7 @@ #define XtCShowMissingGlyphs "ShowMissingGlyphs" #define XtCShowWrapMarks "ShowWrapMarks" #define XtCSignalInhibit "SignalInhibit" +#define XtCSixelScrolling "SixelScrolling" #define XtCTekInhibit "TekInhibit" #define XtCTekSmall "TekSmall" #define XtCTekStartup "TekStartup" @@ -832,6 +860,7 @@ extern void resetCharsets (TScreen * /* screen */); extern void set_max_col(TScreen * /* screen */, int /* cols */); extern void set_max_row(TScreen * /* screen */, int /* rows */); +extern void set_lr_margins (TScreen * /* screen */, int /* left */, int /* right */); extern void set_tb_margins (TScreen * /* screen */, int /* top */, int /* bottom */); extern void unparse_end (XtermWidget /* xw */); extern void unparseputc (XtermWidget /* xw */, int /* c */); @@ -846,6 +875,10 @@ extern void ToggleCursorBlink(TScreen * /* screen */); #endif +#if OPT_BLINK_TEXT +extern Bool LineHasBlinking(TScreen * /* screen */, LineData * /* ld */); +#endif + #if OPT_INPUT_METHOD extern TInput *lookupTInput (XtermWidget /* xw */, Widget /* w */); #endif @@ -860,17 +893,19 @@ #endif /* charsets.c */ -extern unsigned xtermCharSetIn (unsigned /* code */, int /* charset */); +extern unsigned xtermCharSetIn (TScreen * /* screen */, unsigned /* code */, int /* charset */); extern int xtermCharSetOut (XtermWidget /* xw */, IChar * /* buf */, IChar * /* ptr */, int /* charset */); /* cursor.c */ +extern int CursorCol (XtermWidget /* xw */); +extern int CursorRow (XtermWidget /* xw */); extern void AdjustSavedCursor (XtermWidget /* xw */, int /* adjust */); -extern void CarriageReturn (TScreen * /* screen */); -extern void CursorBack (XtermWidget /* xw */, int /* n */); -extern void CursorDown (TScreen * /* screen */, int /* n */); -extern void CursorForward (TScreen * /* screen */, int /* n */); -extern void CursorNextLine (TScreen * /* screen */, int /* count */); -extern void CursorPrevLine (TScreen * /* screen */, int /* count */); +extern void CarriageReturn (XtermWidget /* xw */); +extern void CursorBack (XtermWidget /* xw */, int /* n */); +extern void CursorDown (TScreen * /* screen */, int /* n */); +extern void CursorForward (XtermWidget /* xw */, int /* n */); +extern void CursorNextLine (XtermWidget /* xw */, int /* count */); +extern void CursorPrevLine (XtermWidget /* xw */, int /* count */); extern void CursorRestore (XtermWidget /* xw */); extern void CursorSave (XtermWidget /* xw */); extern void CursorSet (TScreen * /* screen */, int /* row */, int /* col */, unsigned /* flags */); @@ -890,6 +925,7 @@ extern void xterm_DECDHL (XtermWidget /* xw */, Bool /* top */); extern void xterm_DECSWL (XtermWidget /* xw */); extern void xterm_DECDWL (XtermWidget /* xw */); +extern void xterm_ResetDouble(XtermWidget /* xw */); #if OPT_DEC_CHRSET extern int xterm_Double_index(XtermWidget /* xw */, unsigned /* chrset */, unsigned /* flags */); extern GC xterm_DoubleGC(XtermWidget /* xw */, unsigned /* chrset */, unsigned /* flags */, GC /* old_gc */, int * /* inxp */); @@ -916,11 +952,7 @@ extern void restoreCellData(TScreen * /* screen */, CellData * /* data */, Cardinal /* cell */, LineData * /* ld */, int /* column */); /* main.c */ -#ifndef __UNIXOS2__ #define ENVP_ARG /**/ -#else -#define ENVP_ARG , char ** /* envp */ -#endif extern int main (int /* argc */, char ** /* argv */ ENVP_ARG); extern int GetBytesAvailable (int /* fd */); @@ -933,9 +965,7 @@ #define first_map_occurred() /* nothing */ #endif -#ifdef SIGNAL_T -extern SIGNAL_T Exit (int /* n */) GCC_NORETURN; -#endif +extern void Exit (int /* n */) GCC_NORETURN; #ifndef SIG_ATOMIC_T #define SIG_ATOMIC_T int @@ -956,32 +986,37 @@ #define TIMESTAMP_LEN 20 /* length of TIMESTAMP_FMT */ extern Bool AllocateTermColor(XtermWidget, ScrnColors *, int, const char *, Bool); +extern Boolean xtermGetWinAttrs(Display * /* dpy */, Window /* win */, XWindowAttributes * /* attrs */); +extern Boolean xtermGetWinProp(Display * /* dpy */, Window /* win */, Atom /* property */, long /* long_offset */, long /* long_length */, Atom /* req_type */, Atom * /* actual_type_return */, int * /* actual_format_return */, unsigned long * /* nitems_return */, unsigned long * /* bytes_after_return */, unsigned char ** /* prop_return */); extern Cursor make_colored_cursor (unsigned /* cursorindex */, unsigned long /* fg */, unsigned long /* bg */); extern OptionHelp * sortedOpts(OptionHelp *, XrmOptionDescRec *, Cardinal); extern String xtermEnvLocale (void); -extern Widget xtermOpenApplication(XtAppContext * /* app_context_return */, String /* application_class */, XrmOptionDescRec */* options */, Cardinal /* num_options */, int * /* argc_in_out */, String */* argv_in_out */, String * /* fallback_resources */, WidgetClass /* widget_class */, ArgList /* args */, Cardinal /* num_args */); -extern Window WMFrameWindow(XtermWidget /* termw */); +extern Widget xtermOpenApplication (XtAppContext * /* app_context_return */, String /* application_class */, XrmOptionDescRec */* options */, Cardinal /* num_options */, int * /* argc_in_out */, String */* argv_in_out */, String * /* fallback_resources */, WidgetClass /* widget_class */, ArgList /* args */, Cardinal /* num_args */); +extern Window WMFrameWindow (XtermWidget /* termw */); extern XtInputMask xtermAppPending (void); -extern XrmOptionDescRec * sortedOptDescs(XrmOptionDescRec *, Cardinal); -extern XtermWidget getXtermWidget(Widget /* w */); +extern XrmOptionDescRec * sortedOptDescs (XrmOptionDescRec *, Cardinal); +extern XtermWidget getXtermWidget (Widget /* w */); extern char *udk_lookup (int /* keycode */, int * /* len */); extern char *xtermEnvEncoding (void); -extern char *xtermFindShell(char * /* leaf */, Bool /* warning */); -extern char *xtermVersion(void); +extern char *xtermFindShell (char * /* leaf */, Bool /* warning */); extern const char *SysErrorMsg (int /* n */); extern const char *SysReasonMsg (int /* n */); -extern int ResetAnsiColorRequest(XtermWidget, char *, int); +extern Boolean allocateBestRGB(XtermWidget /* xw */, XColor * /* def */); +extern int ResetAnsiColorRequest (XtermWidget, char *, int); extern int XStrCmp (char * /* s1 */, char * /* s2 */); extern int creat_as (uid_t /* uid */, gid_t /* gid */, Bool /* append */, char * /* pathname */, unsigned /* mode */); +extern int getVisualDepth (XtermWidget /* xw */); extern int open_userfile (uid_t /* uid */, gid_t /* gid */, char * /* path */, Bool /* append */); extern int xerror (Display * /* d */, XErrorEvent * /* ev */); extern int xioerror (Display * /* dpy */); -extern int xtermResetIds(TScreen * /* screen */); +extern int xtermClosestColor (XtermWidget /* xw */, int /* red */, int /* green */, int /* blue */); +extern int xtermResetIds (TScreen * /* screen */); extern void Bell (XtermWidget /* xw */, int /* which */, int /* percent */); +extern void ChangeGroup(XtermWidget /* xw */, const char * /* attribute */, char * /* value */); extern void ChangeIconName (XtermWidget /* xw */, char * /* name */); extern void ChangeTitle (XtermWidget /* xw */, char * /* name */); extern void ChangeXprop (char * /* name */); -extern void Cleanup (int /* code */); +extern void Cleanup (int /* code */) GCC_NORETURN; extern void HandleBellPropertyChange PROTO_XT_EV_HANDLER_ARGS; extern void HandleEightBitKeyPressed PROTO_XT_ACTIONS_ARGS; extern void HandleEnterWindow PROTO_XT_EV_HANDLER_ARGS; @@ -991,9 +1026,9 @@ extern void HandleLeaveWindow PROTO_XT_EV_HANDLER_ARGS; extern void HandleSpawnTerminal PROTO_XT_ACTIONS_ARGS; extern void HandleStringEvent PROTO_XT_ACTIONS_ARGS; +extern void NormalExit (void); extern void Panic (const char * /* s */, int /* a */); extern void Redraw (void); -extern void ice_error (IceConn /* iceConn */); extern void ReverseOldColors (void); extern void SysError (int /* i */) GCC_NORETURN; extern void VisualBell (void); @@ -1006,6 +1041,7 @@ extern void end_vt_mode (void); extern void hide_tek_window (void); extern void hide_vt_window (void); +extern void ice_error (IceConn /* iceConn */); extern void reset_decudk (void); extern void set_tek_visibility (Bool /* on */); extern void set_vt_visibility (Bool /* on */); @@ -1016,7 +1052,8 @@ extern void xtermBell(XtermWidget /* xw */, int /* which */, int /* percent */); extern void xtermCopyEnv (char ** /* oldenv */); extern void xtermDisplayCursor (XtermWidget /* xw */); -extern void xtermEmbedWindow(Window /* winToEmbedInfo */); +extern void xtermEmbedWindow (Window /* winToEmbedInfo */); +extern void xtermLoadIcon (XtermWidget /* xw */); extern void xtermPerror (const char * /*fmt*/,...) GCC_PRINTFLIKE(1,2); extern void xtermSetenv (const char * /* var */, const char * /* value */); extern void xtermShowPointer (XtermWidget /* xw */, Bool /* enable */); @@ -1082,7 +1119,6 @@ extern Bool xtermHasPrinter (XtermWidget /* xw */); extern PrinterFlags *getPrinterFlags (XtermWidget /* xw */, String * /* params */, Cardinal * /* param_count */); extern int xtermPrinterControl (XtermWidget /* xw */, int /* chr */); -extern void closePrinter (XtermWidget /* xw */); extern void setPrinterControlMode (XtermWidget /* xw */, int /* mode */); extern void xtermAutoPrint (XtermWidget /* xw */, unsigned /* chr */); extern void xtermMediaControl (XtermWidget /* xw */, int /* param */, int /* private_seq */); @@ -1132,15 +1168,24 @@ #endif /* screen.c */ + +/* + * See http://standards.freedesktop.org/wm-spec/wm-spec-latest.html + */ +#define _NET_WM_STATE_REMOVE 0 /* remove/unset property */ +#define _NET_WM_STATE_ADD 1 /* add/set property */ +#define _NET_WM_STATE_TOGGLE 2 /* toggle property */ + extern Bool non_blank_line (TScreen */* screen */, int /* row */, int /* col */, int /* len */); -extern Char * allocScrnData(TScreen * /* screen */, unsigned /* nrow */, unsigned /* ncol */); +extern Char * allocScrnData (TScreen * /* screen */, unsigned /* nrow */, unsigned /* ncol */); extern ScrnBuf allocScrnBuf (XtermWidget /* xw */, unsigned /* nrow */, unsigned /* ncol */, ScrnPtr * /* addr */); extern ScrnBuf scrnHeadAddr (TScreen * /* screen */, ScrnBuf /* base */, unsigned /* offset */); extern int ScreenResize (XtermWidget /* xw */, int /* width */, int /* height */, unsigned * /* flags */); extern size_t ScrnPointers (TScreen * /* screen */, size_t /* len */); extern void ClearBufRows (XtermWidget /* xw */, int /* first */, int /* last */); extern void ClearCells (XtermWidget /* xw */, int /* flags */, unsigned /* len */, int /* row */, int /* col */); -extern void FullScreen(XtermWidget /* xw */, Bool /* enabled */); +extern void CopyCells (TScreen * /* screen */, LineData * /* src */, LineData * /* dst */, int /* col */, int /* len */); +extern void FullScreen (XtermWidget /* xw */, int /* mode */); extern void ScrnAllocBuf (XtermWidget /* xw */); extern void ScrnClearCells (XtermWidget /* xw */, int /* row */, int /* col */, unsigned /* len */); extern void ScrnDeleteChar (XtermWidget /* xw */, unsigned /* n */); @@ -1184,23 +1229,38 @@ ((screen)->startH.row != (screen)->endH.row \ || (screen)->startH.col != (screen)->endH.col) -#define ScrnAreLinesInSelection(screen, first, last) \ +#define ScrnAreRowsInSelection(screen, first, last) \ ((last) >= (screen)->startH.row && (first) <= (screen)->endH.row) -#define ScrnIsLineInSelection(screen, line) \ +#define ScrnIsRowInSelection(screen, line) \ ((line) >= (screen)->startH.row && (line) <= (screen)->endH.row) -#define ScrnHaveLineMargins(screen) \ +#define ScrnHaveRowMargins(screen) \ ((screen)->top_marg != 0 \ || ((screen)->bot_marg != screen->max_row)) -#define ScrnIsLineInMargins(screen, line) \ +#define ScrnIsRowInMargins(screen, line) \ ((line) >= (screen)->top_marg && (line) <= (screen)->bot_marg) +#define ScrnHaveColMargins(screen) \ + ((screen)->rgt_marg > (screen)->max_col) + +#define ScrnIsColInMargins(screen, col) \ + ((col) >= (screen)->lft_marg && (col) <= (screen)->rgt_marg) + +#define IsLeftRightMode(xw) ((xw)->flags & LEFT_RIGHT) +#define ScrnLeftMargin(xw) (IsLeftRightMode(xw) \ + ? TScreenOf(xw)->lft_marg \ + : 0) +#define ScrnRightMargin(xw) (IsLeftRightMode(xw) \ + ? TScreenOf(xw)->rgt_marg \ + : MaxCols(TScreenOf(xw)) - 1) + #if OPT_DEC_RECTOPS extern void ScrnCopyRectangle (XtermWidget /* xw */, XTermRect *, int, int *); extern void ScrnMarkRectangle (XtermWidget /* xw */, XTermRect *, Bool, int, int *); extern void ScrnWipeRectangle (XtermWidget /* xw */, XTermRect *); +extern void xtermCheckRect(XtermWidget /* xw */, int /* nparam */, int */* params */, int * /* result */); #endif #if OPT_WIDE_CHARS @@ -1210,7 +1270,7 @@ /* scrollback.c */ extern LineData *getScrollback (TScreen * /* screen */, int /* row */); extern LineData *addScrollback (TScreen * /* screen */); -extern void deleteScrollback (TScreen * /* screen */, int /* row */); +extern void deleteScrollback (TScreen * /* screen */); /* scrollbar.c */ extern void DoResizeScreen (XtermWidget /* xw */); @@ -1242,7 +1302,6 @@ extern Boolean isDefaultBackground(const char * /* name */); extern Boolean isDefaultForeground(const char * /* name */); extern GC updatedXtermGC (XtermWidget /* xw */, unsigned /* flags */, unsigned /* fg_bg */, Bool /* hilite */); -extern int AddToRefresh (XtermWidget /* xw */); extern int ClearInLine (XtermWidget /* xw */, int /* row */, int /* col */, unsigned /* len */); extern int HandleExposure (XtermWidget /* xw */, XEvent * /* event */); extern int dimRound (double /* value */); @@ -1262,8 +1321,10 @@ extern void WriteText (XtermWidget /* xw */, IChar * /* str */, Cardinal /* len */); extern void decode_keyboard_type (XtermWidget /* xw */, struct XTERM_RESOURCE * /* rp */); extern void decode_wcwidth (XtermWidget /* xw */); +extern void do_cd_xtra_scroll (XtermWidget /* xw */); extern void do_erase_display (XtermWidget /* xw */, int /* param */, int /* mode */); extern void do_erase_line (XtermWidget /* xw */, int /* param */, int /* mode */); +extern void do_ti_xtra_scroll (XtermWidget /* xw */); extern void getXtermSizeHints (XtermWidget /* xw */); extern void init_keyboard_type (XtermWidget /* xw */, xtermKeyboardType /* type */, Bool /* set */); extern void recolor_cursor (TScreen * /* screen */, Cursor /* cursor */, unsigned long /* fg */, unsigned long /* bg */); @@ -1285,7 +1346,7 @@ extern unsigned extract_fg (XtermWidget /* xw */, unsigned /* color */, unsigned /* flags */); extern unsigned extract_bg (XtermWidget /* xw */, unsigned /* color */, unsigned /* flags */); extern CellColor makeColorPair (int /* fg */, int /* bg */); -extern void ClearCurBackground (XtermWidget /* xw */, int /* top */, int /* left */, unsigned /* height */, unsigned /* width */); +extern void ClearCurBackground (XtermWidget /* xw */, int /* top */, int /* left */, unsigned /* height */, unsigned /* width */, unsigned /* fw */); #define xtermColorPair(xw) makeColorPair(xw->sgr_foreground, xw->sgr_background) @@ -1341,12 +1402,14 @@ #define MapToColorMode(fg, screen, flags) fg -#define ClearDFtBackground(xw, top, left, height, width) \ - ClearCurBackground(xw, top, left, height, width) - -#define ClearCurBackground(xw, top, left, height, width) \ - XClearArea (TScreenOf(xw)->display, VWindow(TScreenOf(xw)), \ - left, top, width, height, False) +#define ClearCurBackground(xw, top, left, height, width, fw) \ + XClearArea (TScreenOf(xw)->display, \ + VDrawable(TScreenOf(xw)), \ + CursorX2(TScreenOf(xw), left, fw), \ + CursorY(TScreenOf(xw), top), \ + width * fw, \ + height * FontHeight(TScreenOf(xw)), \ + False) #define extract_fg(xw, color, flags) (xw)->cur_foreground #define extract_bg(xw, color, flags) (xw)->cur_background @@ -1362,11 +1425,23 @@ #endif /* OPT_ISO_COLORS */ +#if OPT_ZICONBEEP +extern void initZIconBeep(void); +extern void resetZIconBeep(XtermWidget /* xw */); +extern Boolean showZIconBeep(XtermWidget /* xw */, char * /* name */); +#else +#define initZIconBeep() /* nothing */ +#define showZIconBeep(xw, name) False +#endif + #define XTERM_CELL(row,col) getXtermCell(screen, ROW2INX(screen, row), col) extern unsigned getXtermCell (TScreen * /* screen */, int /* row */, int /* col */); +extern unsigned getXtermCombining(TScreen * /* screen */, int /* row */, int /* col */, int /* off */); extern void putXtermCell (TScreen * /* screen */, int /* row */, int /* col */, int /* ch */); +#define IsCellCombined(screen, row, col) (getXtermCombining(screen, row, col, 0) != 0) + #if OPT_HIGHLIGHT_COLOR #define isNotForeground(xw, fg, bg, sel) \ (Boolean) ((sel) != T_COLOR(TScreenOf(xw), TEXT_FG) \ diff -Nru xterm-278/xterm.log.html xterm-297/xterm.log.html --- xterm-278/xterm.log.html 2012-01-19 01:54:00.000000000 +0000 +++ xterm-297/xterm.log.html 2013-09-11 00:58:01.000000000 +0000 @@ -1,9 +1,8 @@ - - - -XTERM - Change Log - - - - -
      -http://invisible-island.net/xterm/
      -Copyright © 1997-2010,2011 by Thomas E. Dickey -
      -

      Contents

      -This file contains a list of the changes that I have made for xterm, -from the notes that I add when submitting a patch. -

      -You should note that other changes have been made as well, by other people, -to fix bugs and correct ifdef's for portability. -Most of these are summarized in the XFree86 CHANGELOG -(found in the unbundled tree, xc/programs/Xserver/hw/xfree86). -Here -is the latest version of this file. - -

      - -

      Patch #278 - 2012/01/18

      -
        -
      • correct initialization for eightBitMeta resource - (FreeBSD #164101). - -
      • make special check for Darwin 9 (and lower) to not - use posix_openpt (report by Christian Ebert). - -
      • minor fixes (adding ".ne" directives) to reduce the cases where - groff's utility for generating images for tables dumps core. - Most versions of groff (I've found 1.19.2 to be the most stable) - dump core when attempting to report that there are too few lines - on a page for a table to be shown. -
      - -

      Patch #277 - 2012/01/07

      -
        -
      • remove special case for ISC pseudo-terminals which attempts to - open the pty in two different ways. - -
      • move call to grantpt before asking utempter to - add a record, to work with kFreeBSD which does not update the - terminal's ownership until this point (Debian #652907). - -
      • document limitation of XIM interface in manpage (Debian #230787). - -
      • cleanup error reporting with new xtermWarning function. - -
      • add configure option --disable-selection-ops to - make the new actions optional. - -
      • add four new actions for making the selection or data directly - copied from the screen (prompted by discussion in Debian #637001, - as well as report by Arjen van Tol): -
          -
        • exec-formatted -
        • exec-selectable -
        • insert-formatted -
        • insert-selectable -
        - -
      • add visualBellLine resource to allow - visualBell to flash only the current line (prompted by - patch by Gertjan Halkes). - -
      • add eightBitMeta resource to control the features - which modify or interpret the eighth bit of a key when the - meta modifier key is pressed (prompted by Debian #326200). - -
      • improve discussion of eightBitInput in the manpage - (prompted by Debian #326200). - -
      • correct logic for alt-sends-escape action, - overlooked when implementing altSendsEscape resource, - which still used eightBitInput resource value. - -
      • add a workaround for XAllocColor(), which does not - actually allocate "a read-only colormap entry corresponding to the - closest RGB value supported by the hardware", but rather a rough - approximation (Debian #650291). - -
      • undo parameter checks for RequestResize() added in - patch #251 and amended in - patch #270, because zeros also are - special cases (report by John S Urban). - -
      • modify some test-scripts to use /bin/echo rather than - the shell's possibly-builtin echo, to work around - broken configuration on Mac OS X, i.e., neither honoring the option - nor flagging an error. - -
      • add SGR 1006, as a better technical solution than SGR 1015: -
          -
        • the responses will not be confused with line-deletion and - scrolling controls. -
        • the button encoding is a little simpler, since it does not - add an unnecessary 32 because the integer parameter does not - have to be represented as a printable character. -
        • the control responses for pressing and releasing a mouse - button differ, allowing an application to tell which button was - released. -
        -

        - Besides these improvements, - in discussion, it was noted that urxvt's implementation of 1005 is - incorrect, relying upon a locale that provides UTF-8 encoding. In - contrast, vttest demonstrates a correct decoding, independent of - locale. - -

      • add support for urxvt SGR 1015 to address shortcoming of - SGR 1005 with luit (patch by Egmont Koblinger). - -
      • add ISO and DEC controls useful for left/right scrolling. - -
      • add some changes for OpenBSD and MirBSD (adapted from patch by - Thorsten Glaser): -
          -
        • disable search for non-Unix96 ptys. -
        • fix a gcc warning in timestamp_filename -
        • modify Imakefile to install xterm setgid to utmp. -
        - -
      • add/use/prefer posix_openpt() for opening - pseudo-terminal. - -
      • modify special errno handling case in ptydata.c from - patch #158 - to allow for the possibility that any platform may have - special cases where "/dev/tty" is absent. - For example, this can happen in a FreeBSD jail - (patch by David Wolfskill). - -
      • add keyboard logic to map shift-tab into XK_ISO_Left_Tab, which is - usually, not always, done by the X keyboard configuration. - -
      • portability fixes for some configure macros: - CF_XOPEN_SOURCE -
      - -

      Patch #276 - 2011/10/10

      -
        -
      • modify clipping limits for TrueType fonts to account for the - scaleHeight resource setting, to work around another - problem due to recent FreeType changes. In this case, the - DejaVu Sans Mono set to pixelsize=13.5 - is truncated because the font descent is reduced by FreeType to - match an incorrect height metric (report by Adam Lee). - -
      • improve recovery when bitmap fonts are not installed, e.g., so - that switching font-sizes works for TrueType fonts. - -
      • modify lookup for XTERM_SHELL feature to allow - relative pathnames. - -
      • modify abbreviation disambiguation check - for command-line parameters to account for -geometry, - whose parameter may begin with "+" or "-" - (report by Scott Bertilson). -
      - -

      Patch #275 - 2011/09/11

      -
        -
      • add ash, zsh to known shells for - resize. - -
      • modify resize - to reuse the logic from xterm - which determines the actual logon-user's shell - if $SHELL is not set. - -
      • revert the unsetenv("SHELL") added in - patch #272. - -
      • an unsetenv("SHELL") added in - patch #272 to help ensure that - luit would get the user's shell consistently - did not work as expected for cases where multiple - names are in the password-file for a given uid. - That was because changes in patch #157 - to handle this situation - did not take into account that repeated calls to - getpwnam and getpwuid - return a pointer to the same static buffer. - Fixed the older logic to work as intended, - by ensuring that the passwd-data from each call is stored - separately (report by Paul Keusemann). - -
      • adjust ifdef's for putenv and unsetenv - in case only one of those is provided on a given platform. - -
      • correct comparison used in ExposeContains macro from - patch #274 - changes, to handle window-dragging (patch by Todd Eigenschink). -
      - -

      Patch #274 - 2011/09/05

      -
        -
      • portability fixes for cygwin: do not define SVR4, - and work around nonstandard header location. - -
      • ifdef'd use of unsetenv - from patch #273 - changes to work with Solaris 9 - (report by Waldemar Rachwal). - -
      • modify logic for XtAppPending to merge adjacent - Expose and ConfigureNotify events - which are redundant (report by Edward McGuire). - -
      • fix an unneeded warning message when -r option - is given. - -
      • remove a few redundant entries from table used for helping - abbreviation-checking of command-line options, makes - -geom work again after - patch #272 changes - as an abbreviation of - -geometry. - -
      • add scaleHeight resource and - command-line option -sh - as workaround for some font-configurations broken by - changes in FreeType 2.4.6 (report by Miroslav Hodak). - -
      • portability fixes for some configure macros: - CF_FUNC_TGETENT, - CF_XOPEN_SOURCE, - CF_X_ATHENA_LIBS. - -
      • add configure option --with-freetype-config to - improve selection over the plethora of configuration options - which freetype has so far provided. - -
      • build-fix for configure --enable-load-vt-fonts when - --enable-widec is not specified. - -
      • build-fixes for suppressing various features, needed after changes - in patches 270, 271 and 272 (report by Brian Lindholm) -
      - -

      Patch #273 - 2011/08/25

      -
        -
      • build-fix for out-of-tree "make docs" rule. - -
      • correct a typo in x_strdup, from - patch #198 - changes. - -
      • correct initialization for -e option, broken in - patch #272 - changes (report by Gabriele Balducci). - -
      • build-fix for out-of-tree builds to address minstall - script changes in - patch #272 - (patch by Thierry Reding). -
      - -

      Patch #272 - 2011/08/24

      -
        -
      • document limitation of Gtk in connection with xterm's - -into option, in the manpage (Ubuntu #806969). - -
      • improve -into by checking for and using the size - of the window within which xterm is embedded, overriding other - clues. - -
      • modify logic for localeFilter resource to allow that - to include command-line options of luit. - -
      • improve -into by checking for invalid window-id, - and allowing hexadecimal/decimal/octal values. - -
      • improve keepSelection, adding the case where the - highlighting is cleared, - overlooked in patch #230 - (patch by Marco Peereboom). - -
      • improve command-line parsing to make abbreviate options work - consistently across xterm-specific versus standard X toolkit - options, and report cases where an abbreviated option happens - to be ambiguous. In particular, -d now works as - an abbreviation for -display. - -
      • fix regression in command-line parsing introduced in - patch #271 changes - for Debian #629358, - (Debian #637910). - -
      • split-out new termcap/terminfo building block - xterm+kbs for configurability. - -
      • modify terminfo file to reflect changes in ncurses - for xterm-16color and xterm-256color. - -
      • modify minstall.sh, etc., to reflect the default - default class, - $TERM and - decTerminalID values. - -
      • reword resize manpage to reflect the fact that - $TERMCAP is not set on all systems (patch by - Alan Coopersmith). - -
      • work around combined Xaw6/Xaw7 package in DragonFlyBSD which - omits the usual symbolic link to the preferred library name. - -
      • further improve build-fix for termcap systems by checking for - some which are only partial implementations, e.g., termcap - 2.08 in CentOS 5.2 -
      - -

      Patch #271 - 2011/07/14

      -
        -
      • omit permissions adjustments to pty on exit except for - pre-Unix98 ptys, since modern implementations handle this - (report by Sean C Farley). - -
      • modify logic for switching fonts between UTF-8 and non-UTF-8 - encoding to not merge the derivable bold-, wide- and widebold - values from the VT100 fonts. Also suppress warning when not - using UTF-8 fonts if wide- and widebold-fonts cannot be derived - or otherwise loaded (report by Werner Scheinast). - -
      • modify menu-creation to suppress entries which will never be used - in the current configuration, rather than simply disabling them. - -
      • add resource printModeImmediate and menu item to - allow print of screen plus saved lines to a file. - -
      • add menu item to allow runtime enable/disable of the - printFileOnXError feature. - -
      • append a timestamp to filename used in - printFileOnXError feature, - and restrict its permissions - (request by Vincent Lefevre). - -
      • add a check when cancelling cursor-blinking, in case the cursor - is blinked off. Fix so that the cursor is repainted without - waiting for other events, e.g., keypress (report by Ailin Nemui). - -
      • add configure --with-app-class option, to simplify - building "xterm-dev" packages with filenames that do not conflict - with conventional "xterm" packages. - -
      • corrected logic flow for DECSCL, which prevented the updated - operating level from being reported via DECRQSS (report by - Ailin Nemui). - -
      • corrected default for brokenStringTerm resource to - match manpage. - -
      • add vttests/dynamic.pl - -
      • add runtime check for locale not supported by X libraries, and - fallback to XA_STRING in this case (request by Bryan Henderson). - -
      • fix a special case in configure script after no FreeType libraries - are found. The script was proceeding to check for a usable - configuration. - -
      • add xterm+tmux building block to terminfo (adapted - from changes proposed by Ailin Nemui and Nicholas Marriott). - -
      • improve discussion of faceName resource in manpage - (adapted from suggestions by Jens Schweikhardt). - -
      • correct mapping of shifted up/down cursor-keys in termcap - function-keys mode, i.e., resource tcapFunctionKeys - (patch by Gertjan Halkes). - -
      • update AIX case in CF_XOPEN_SOURCE configure macro to - add release 7.x. - -
      • modify ifdef's in xterm_io.h for __hpux - to force that to use the hacked SYSV support in that file. - This fixes a problem with a non-blocking socket call (patch - by Paul Lampert). - -
      • improve filtering of desktop category scanning, to exclude XFCE. - -
      • modify configure script to work with systems that have both - ncurses (or other terminfo) as well as a real termcap library, - e.g., Slackware (report by Alan Watts). - -
      • modify configure script to work around special case where user's - environment adds compiler flags to the CC variable - (prompted by report by Paul Lampert). - -
      • amend change for Debian #110226 so that "-h" or "-v" options cause - an exit, rather than simply printing to stdout while the window is - displayed (Debian #629358). - -
      • add response for DECRQSS which gives the setting - for DECSCUSR. - -
      • modify AllocateTermColor() to handle - XtDefaultForeground and - XtDefaultBackground, - which are not recognized by XParseColor. - For example, this fixes the use of OSC 112 - when no explicit cursor color was set (report by Ailin Nemui). - -
      • handle special-case of KeyPress translated to - popup-menu action (Ubuntu #756273). -
      - -

      Patch #270 - 2011/04/26

      -
        -
      • build-fix, e.g., for using imake on platforms which - use the termcap library. - -
      • modify utf8 resource to accept a name. - -
      • mention default for fontWarnings in manpage - (report by Werner Scheinast). - -
      • split "UTF-8" menu entry into "UTF-8 Encoding" and "UTF-8 Fonts" - (prompted by discussion with Werner Scheinast). - -
      • gray-out font-menu entries when a font fails to load, e.g., - a bitmap font is not installed. - -
      • improve behavior when there is no app-defaults file: -
          -
        • set the toolBar resource to false -
        • gray-out the font menu entries where no resource is found. -
        - -
      • add configure option --with-desktop-category - to allow customization of the ".desktop" files. - -
      • build-fix for the install-desktop makefile-rule, - when the source/build directories differ - (patch by Loïc Minier). - -
      • add menu entry and corresponding resource which can be used to - suppress all bold-fonts (discussion with Jan Engelhardt). - -
      • make internal line-size value consistent with allocated sizes of - character and related arrays to ensure that bulk copying of line - data, e.g., in scrolling, accounts for the padding used for pointer - alignment (adapted from patch by Rajesh Mandalemula, also reported - by Ali Bahar). - -
      • widen ifdef for screen-resizing logic - from - patch #176 changes - to send - SIGWINCH to process group to include any - system supporting ioctl(*,TIOCGPGRP,*) - (prompted by linux-specific patch in OpenSUSE rpm package). - -
      • add - printModeOnXError and - printFileOnXError - resources, which allow the user to specify - that xterm will write the contents of its screen to - a file if it is exiting due to an X error - (Debian #280457). - -
      • restore logic that made reverse-video apply to the scrollbar's - foreground/background, broken in - patch #158 - (report by Bryan Ischo). - -
      • amend some of the window operations parameter-checks added in - patch #251 for the push/pop title feature, - to allow the parameters used for window resizing to be -1's, which - makes the corresponding values ignored rather than using the - window's maximum width/height (report by Noah Friedman). - -
      • correct order of initialization for translations vs - fullscreen - resources to enable a special case which omits - the Alt-Enter translation - when fullscreen is disabled (Debian #612978). - -
      • update config.guess, config.sub -
      - -

      Patch #269 - 2011/02/19

      -
        -
      • build-fixes for imake (report by Heiko Berges). - -
      • modify autoconf macro CF_PKG_CONFIG to work with cross-compile - environments (patch by Thierry Reding). - -
      • modify MapToColorMode() to favor bold over underline, - matching the precedence used before - patch #252 - (report/analysis by Nicolas George). - -
      • add omitTranslation resource, which can be used to - suppress the default translations for these features: -
          -
        • fullscreen -
        • scroll-lock -
        • shift-fonts -
        • wheel-mouse -
        - -
      • make the fullscreen feature configurable (Debian #612978) -
          -
        • add it to the configurable list - disallowedWindowOps. - -
        • add command-line option -fullscreen to allow the - feature to be enabled at startup. - -
        • add resource fullscreen to control whether the - feature is active or may be enabled. -
        - -
      • modify probe_netwm_fullscreen_capability for 64-bit - machines. Contrary to XGetWindowProperty manpage, - that function returns 32-bit data packed as long's. - -
      • eliminate copy of name resource, which was otherwise - used only to give the terminal-description name for the tcap-query - feature. Use the actual $TERM value instead, as - derived from termName resource, etc. - -
      • eliminate an old inconsistency with error messages, some used the - -name option, while others used argv[0]. - The latter is now used consistently. - -
      • improve configure check for rpath-hack, to improve builds on - systems where gcc will not search /usr/local/lib, etc. - -
      • build-fix for Xaw3d configuration (report by H Merijn Brand). - -
      • update config.guess, config.sub -
      - -

      Patch #268 - 2011/02/10

      -
        -
      • fix an inconsistency of the "Enable Reverse Video" checkbox in - the VT Options menu. - This also removes a special case - added in patch #217 - which limited the effect of the reverseVideo resource - (Debian #603808). - -
      • amend decoding of misformed UTF-8 sequences to avoid absorbing - valid characters as documented in Unicode 6.0 section 3.9 - (report by Keith Winstein). - -
      • do not set urgency hint when window already has focus - (patch by Dimitrios Christidis). - -
      • amend extended mouse-coordinate mode from - patch #262 changes to include - the Cb button-code, which also may be greater than 127 - (report by Ailin Nemui). - -
      • ensure that underline-cursor is visible when an application happens - to set the background color (report by Christian Weisgerber). - -
      • add feature for - full-screen toggling - using either Alt-Enter - or a menu selection - (integrated patch by Dave Simmons). - -
      • add missing logic to handle reallocation of FIFO index for the - "UTF-8" menu entry (report by David Holland, NetBSD #44344). - -
      • add makefile rules docs-ctlseqs, - docs-xterm, etc. - -
      • correct typo in description of DECRPM in control sequences - document (report by Ailin Nemui). -
      - -

      Patch #267 - 2010/11/20

      -
        -
      • minor formatting changes to ctlseqs.ms to simplify a script which - extracts the feature information. See the results in -Comparing versions, by counting controls in the xterm FAQ. - -
      • add docs-clean makefile rule. - -
      • add copy-selection action (request by - Timo Juhani Lindfors, Debian #588785). - -
      • trim leading/trailing blanks from string used for "Selection" - font-menu data. - -
      • trim leading/trailing blanks from color resource values. - -
      • configure script improvements: -
          -
        • add workaround for removal of X11 dependency from Xt's package - file (report by Robert Hooker). - -
        • add workaround for removal of fontconfig dependency from Xft's - package file (report by Jeremy Huddleston). - -
        • add workaround for removal of Xmu dependency from Xaw's package - file (report by Jeremy Huddleston). - -
        • improve workaround in CF_X_TOOLKIT macro, - checking for other - possible packages where Xt's dependencies may be given. - -
        • prefer ${name:=value} to ${name-value}, - since recent bash changes break legacy support for that feature. -
        -
      - -

      Patch #266 - 2010/10/24

      -
        -
      • add rpm and dpkg scripts, for testing. - -
      • more fixes for Debian #600707 (report by Cyril Brulebois). -
      - -

      Patch #265 - 2010/10/22

      -
        -
      • fix a regression in fontname logic from - patch #263 changes - (Debian #600707, reported by Vincent Lefevre). - -
      • revert modification of any-event/any-button protocol from - patch #263 changes. - It interferes with selection using a - shifted mouse button (reports by Neil Bird, Bram Moolenaar). -
      - -

      Patch #264 - 2010/10/14

      -
        -
      • replace a null-pointer check with check for empty string in - xtermOpenFont, - to eliminate a warning message from - patch #263 changes. - -
      • build-fix for patch #263 when toolbar - is not configured - (patch by Chris Clayton) - (reports by Robby Workman, - David Wood). -
      - -

      Patch #263 - 2010/10/13

      -
        -
      • corrected initialization of "misc" resource values, to ensure that - xterm has allocated a copy of strings which may not have been - malloc'd by the X library (Debian #600129). - -
      • modify handling of any-event/any-button mouse protocol; it - now is active with any combination of key-modifiers. - -
      • add debugging feature showWrapMarks, which marks - lines which xterm knows are wrapped, showing where a double-click - will select past the end of a line. - -
      • build-fix to address change in include-guards for - Xlib.h - in ongoing Xorg edits (patch by Jeremy Huddleston). - -
      • improve pointerMode by continuing to watch for motion - events after mouse tracking is disabled if the pointer is hidden - (Debian #594856). - -
      • further extend initialization for active-icon font to check if - the font was not loaded succesfully, - to retry with font1, - or as even (if TrueType fonts are used) to use a TrueType font. - The retries are to help with cases as in - patch #241 where the bitmap fonts are - not available. - -
      • fix special case of active-icon used when TrueType font is - specified for the xterm window, - from patch #261 change. - In that case, the default font's size was used for layout of the - active icon's window (Debian #591265). -
      - -

      Patch #262 - 2010/8/30

      -
        -
      • fix a case where changing the cursor color via escape sequences - did not immediately update the screen (report by Andreas Wagner). - -
      • implement ANSI and DEC request-mode control sequences. The - latter includes the xterm-specific private modes such as the - mouse mode. The feature is ifdef'd with the rectangle operations - since its decoding overlaps that feature. - -
      • correct typo in ctlseqs.ms for response of OSC 21 (patch by - Kevin Schoedel). - -
      • improve discussion of mouse tracking in ctlseqs.ms - -
      • increase an array limit used in reporting mouse events (report - by Ryan Johnson). - -
      • add extended mouse-coordinates mode, allowing up to 2015x2015 - windows, using UTF-8 encoding (patch by Ryan Johnson). - -
      • modify manpage hyphens to conform with - Debian. -
      - -

      Patch #261 - 2010/6/28

      -
        -
      • fix regression in renderFont logic, from - patch #260 changes - (report by Joseph Quinsey). -
      - -

      Patch #260 - 2010/6/20

      -
        -
      • modify plink.sh to work around problem linking to - recent PCRE libraries. - -
      • extend renderFont resource to allow deferred switch - to TrueType fonts without affecting existing resource settings - (Debian #585620). - -
      • modify configure macro CF_X_TOOLKIT to work around omission of - ICE library from ".pc" file (report by Miroslav Lichvar). - -
      • change configure script default for --enable-broken-st - i.e., the brokenStringTerm feature) - to normally enable it. - If the corresponding resource is enabled, - this feature eliminates an apparent freeze of xterm - when sending mis-encoded data to the screen (Debian #584801). - -
      • document in manpage some actions which were overlooked: -
          -
        • readline-button -
        • scroll-lock -
        • set-8-bit-control -
        - -
      • undo a change to limit-check in ScrnRefresh - in patch #257, - which broke fastScroll feature - (Debian #584841). - -
      • modify handling of - brokenLinuxOSC and - brokenStringTerm - to also sound the bell. - -
      • add control/D and control/Q to controls which will cause early - exit from control string per brokenStringTerm - resource. - -
      • improve documentation of brokenStringTerm resource - in manpage. -
      - -

      Patch #259 - 2010/6/5

      -
        -
      • modify configure check for - luit to include new - aliases for the program - (xterm-filter and - bluit). - -
      • add workaround in xtermClearLEDs() to account for - Xkb's override, making vttest's LED demo reset the scroll - lock. - -
      • filter out client-message events when deciding whether to hide - cursor, e.g., when using SCIM - (patch/report by anonymous user). - -
      • improve description of -bd option in manpage - (report by Guy Daniel Clotilde). - -
      • modify configure checks for PCRE and other libraries to use - pkg-config, if available. - -
      • amend change from patch #252, to take - veryColorColors resource into account when checking - colorBDMode resource for TrueType fonts - (report by anonymous user). - -
      • add vttests/query-fonts.pl script for - demonstrating the OSC 50 font query. - -
      • improve manpage discussion of Scroll Lock feature. - -
      • improve configure macros CF_GCC_VERSION and CF_GCC_WARNINGS. - -
      • fix warnings for "clang --analyze". - -
      • change default for allowScrollLock resource to - false, noting that the supposedly unused key has - been useful for various rebindings (Debian #580946). -
      - -

      Patch #258 - 2010/5/1

      -
        -
      • add pointer-checks in ScrnRefresh to fix a case in - rapid scrolling where an empty record is fetched from the - scrollback FIFO. -
      - -

      Patch #257 - 2010/4/22

      -
        -
      • correct ctlseqs.ms description of OSC 17 and OSC 19 - (patch by Emanuele Giaquinta). - -
      • corrected logic for menuLocale resource; - the setlocale function returns the original locale - only when querying. - -
      • improve filtering of translations resource, narrowing the scope - of the alwaysUseMods to address only the translations - that would cause a key to be sent to the host (report by Andrew - Gaylard). - -
      • change default value of menuLocale resource to "C", - to work around - longstanding Xorg bug. - -
      • modify handling of scrollKey feature to ignore - XON/XOFF keys. - -
      • implement scroll-lock feature. - -
      • revise memory allocation in UTF8toLatin1() to fix an out-of-bounds - index (Mandriva #54531). - -
      • compute value for first wide-character rather than assuming it is - 256, fixes problem with -cjk_width introduced in - patches - 242 and - 249 - (report by Thomas Wolff). - -
      • improve configure script: -
          -
        • corrected check for _XOPEN_SOURCE for OpenSolaris. - -
        • when possible, add rpath option for libraries in unusual places - -
        • add configure option --disable-rpath-hack to - control whether the rpath option can be added. -
        - -
      • modify AllocateTermColor() to separate initialization - from control sequences, - fixing problem from patch #254 changes - where enabling allowSendEvents - resource prevents setting cursor color on command-line - (Debian #572928). - -
      • amend logic from patch #185 to not - reallocate cell-array if processing ESC % G - to switch from UTF-8 if already in ISO-8859-1 character set - (report by Michael Koehne). - -
      • fix to avoid calling XmuInternStrings() with zero - count (report by Johan Bockgård). - -
      • fix build when --disable-ansi-color configure option is used. - -
      • fix build when neither OPT_TCAP_QUERY or OPT_TCAP_FKEYS is defined - (patch by Matthieu Herrb) -
      - -

      Patch #256 - 2010/3/6

      -
        -
      • add TerminalEmulator to desktop category files. - -
      • modify sinstall.sh to ignore the "." appended to - permissions by selinux. - -
      • change app-defaults organization, installing UXTerm-color - and KOI8XTerm-color for consistent behavior regarding - customization: color (prompted by discussion - in Ubuntu #421261). - -
      • fix typo in minstall.sh from - patch #255 changes, - and add case for - /var/run needed for full path of utmp - (report by Julien Cristau). - -
      • minor fix to xterm manpage, remove a comment stating that margin - bell can be changed via the VT Options menu. That was replaced in - patch #225 - -
      • add a "docs" rule to makefile. - -
      • fix initialization of Atom used for XkbBell feature - from patch 243 changes. - Unlike the other calls to XInternAtom(), - in this case the flag telling X to create the Atom was unset - (patch by Chris Adams). -
      - -

      Patch #255 - 2010/1/21

      -
        -
      • rename install.sh to install-sh in case - suffix-rules might interfere. - -
      • extend range for convertToUTF8 function to full - 31-bits, to use with printing, etc. - -
      • improve manpage by checking for actual locations of - utmp/wtmp files (Debian #562640). - -
      • modify configure macro CF_XOPEN_SOURCE to remove -D's before - adding the same name rather than relying on -U's, to reduce - redefinition warnings for some platforms that have conflicting - definitions in headers. - -
      • correct logic used to switch to alternate screen using FIFO-lines - configuration (Debian #565772). - -
      • update config.guess, config.sub -
      - -

      Patch #254 - 2010/1/6

      -
        -
      • add a configure-check to eliminate install-ti - rule from Makefile when the system has no tic (terminfo compiler) - program. This lets one use the install-full - rule more consistently. - -
      • amend change to WriteText() function in - patch #252 to take into account the - colorAttrMode resource - (report by Krzysztof Kotlenga). - -
      • document titleModes resource in manpage, added in - patch #252. - -
      • modify tcap-query table entries for shifted up/down cursor keys - to match ncurses convention. - -
      • improve lookup of termcap-query data, allowing for duplicate - keycodes versus missing entries. - -
      • add control sequence which can be used to modify the terminal - data used for the termcap-keyboard. - -
      • improve portability of tcap-query feature, using terminfo functions - in preference to termcap on systems having terminfo. - -
      • improve font-setting/querying control (OSC 50): -
          -
        • when TrueType font is selected, the TrueType - faceName will be set, rather than the bitmap font. -
        • when TrueType font is selected, querying returns the name of - the TrueType font. -
        • querying a font recognizes the relative-font convention that - setting a font could use. -
        - -
      • add menu-entry for allowColorOps. - -
      • add new resources for fine-tuning menu entries: - allowColorOps, - disallowedColorOps, - disallowedFontOps and - disallowedTcapOps. - -
      • correct logic for disabling the "TrueType Fonts" menu item; it was - not ensuring that the faceName resource value was - non-empty. - -
      • implement VT520-style controls DECSMBV and - DECSWBV for setting the margin- and warning-bell - volume. - -
      • fix a minor error from patch #243 which - made the zIconBeep feature use a minor-error tone rather than an - informational tone. - -
      • add a null-pointer check for the case where renderFont - resource is true, but faceName resource is unset, - used in logic to strip "xft:" prefix from - patch #251 changes - (patch by Michael Riepe). - -
      • add special case to configure CF_XOPEN_SOURCE macro to use extensions - on Darwin (patch by Dennis Preiser). - -
      • improve configure checks for regular expressions header and - library - -
      • update config.guess, config.sub -
      - -

      Patch #253 - 2009/12/10

      -
        -
      • add a null-pointer check in getPrinterFlags() - per changes in patch #252. - -
      • add a null-pointer check, needed in UTF-8 mode for Xft fonts after - changes in patch #252 (patch by Alan - Coopersmith). - -
      • correct size when clearing struct for tek4014 (patch by Jochen - Voss). - -
      • parenthesize expression in MoreRows macro, fixing - a limit check added in patch #251 - (Debian #560039). -
      - -

      Patch #252 - 2009/12/7

      -
        -
      • modify title-querying logic to support retrieval of titles encoded - using UTF-8. - -
      • add new "title-modes" control sequence for controlling whether - window/icon titles can be set or queried using UTF-8, optionally - encoded in a hexadecimal string. - -
      • use mkdir -p rather than mkdirs.sh - (prompted by discussion of mawk by Aleksey Cheusov). - -
      • add appropriate copyright/license notices to the bulk of files - lacking same, and modify to use identical terms in others which - used different wording. The main exceptions are the files - contributed by Markus Kuhn, who appears to prefer public domain - distribution, noting that I have modified/improved several of these - without changing the terms of distribution (request by Jari Aalto). - -
      • add control sequences for resetting the "dynamic" colors to - their default values. - -
      • add control sequences for resetting the "special" colors to - their default values. - -
      • add control sequences for setting the "special" colors such as - colorBD (bold). - -
      • add overlooked case for setting highlight foreground color with - the dynamic-colors control. - -
      • add OSC 104, for resetting ANSI/16/88/256 colors to - default. - -
      • reset ANSI/16/88/256 colors to default in soft/hard reset functions. - -
      • strip "xft:" prefix from faceName and - faceNameDoublesize resource values, - -
      • add DECSCUSR (discussion with Andy Koppe). - -
      • add check/warning on failure to load font, to see if the name looks - like an Xft pattern rather than XLFD. This can happen if someone - happens to modify their X resource settings for programs that read - data from xterm's namespace. - -
      • modify handling of print and - print-everything - actions to allow the various printer flags to be overridden by - supplying parameters. - -
      • add resource printerNewLine (request by Ovidiu - Gheorghioiu). - -
      • minor cleanup, finish using TScreenOf() and - TekScreenOf() macros introduced in - patch #224. - -
      • improve checks in ShowCursor/HideCursor to get the background - color, particularly when highlightReverse resource - is used (reports by Jan Engelhardt, Christian Weisgerber). - -
      • correct checkVeryBoldAttr to omit comparison of - foreground color to special color values used for - color<XX> resources (report by Jan Engelhardt). - -
      • make colorBDMode and colorULMode - resources work with TrueType configuration (report by Jan - Engelhardt). -
      - -

      Patch #251 - 2009/11/11

      -
        -
      • add window-ops controls to push/pop icon and/or window labels on - a stack. - -
      • minor fixes to align termcap file with terminfo. - -
      • add resource disallowedWindowOps, to allow fine-tuning - of features to suppress with the allowWindowOps - resource (prompted by discussion with Bram Moolenaar). - -
      • add makefile rules for resize-manpage to pdf, etc. - -
      • further improve limit-checks in select/paste (Mandriva #54531). -
      - -

      Patch #250 - 2009/10/13

      -
        -
      • add check and error-message for fonts that have no printable - values in the ISO-8859-1 range (Debian #542434). - -
      • some compiler-warning cleanup, in particular workaround for - defective implementation of gcc's attribute warn_unused_result - (report by Bram Moolenaar). - -
      • improve estimate of single-column width for packed TrueType - fonts by ignoring extents for codes 127 and 159. - -
      • improve line-drawing for TrueType fonts which happen to have - defined glyphs which are not line-drawing in 0..31 - by assuming they're not, and just checking the existence of - the Unicode codepoints. This makes it more likely that the - user can override a misconfigured font using the "Line-Drawing - Characters" menu entry. - -
      • limit minimum cell-width for packed font to maximum-advance - reported by Xft. Some fonts are wider than that, even in the - Latin-1 range (Debian #550497). - -
      • add list of direct-contributors in "THANKS" file. - -
      • stylistic changes to this file to help scripted extraction of - list of contributors. - -
      • correct off-by-one in okPosition fix from - patch #249 limit-checks which - prevented double-click selection on the bottom line of the - screen (reports by Rajeev V. Pillai, Debian #550368). - -
      • add -q option to - vttest/256colors2.pl and - vttest/88colors2.pl - to demonstrate bulk initialization of color palette. - -
      • improve the workaround from patch #188 by enabling resources for - the 88-color model. - -
      • document in xterm manpage the limited availability of resources - color16 to color255 as noted in - patch #188 (Ubuntu #438850). -
      - -

      Patch #249 - 2009/10/1

      -
        -
      • change default for allowWindowOps resource to false. - - -
      • add limit-checks for result of visual_width() function, - needed from patch #242 and - exposed by #244 changes (Debian #548321). - -
      • improve limit-checks in select/paste. - -
      • fix a remaining bug from - patch #230 - changes for displaying multi-column - characters in a proportional font (report by Chris Jones). - -
      • add new resource forcePackedFont and menu entry "Packed Font" to - control whether to use the font's minimum (default) or maximum - width when those differ. The workaround which xterm uses to - accommodate proportional fonts is not necessary with certain - fonts such as unifont which happen to store a mixture of - multicolumn glyphs (report by Chris Jones). - -
      • fix an (old) bug which did not restart the timer for blinking text - if the only blinking text was temporarily scrolled out of view, - e.g., using the scrollbar. - -
      • fix an (old) flaw in the delete-line operation where the text which - is scrolled into view while the display is scrolled up was not - repainted. - -
      • improve delete-line and insert-line operations, retaining selection - when the selection does not intersect the deleted/inserted lines. - -
      • fix an (old) off-by-one error when an application cleared above the - cursor position while the display was scrolled up, that would leave - an extra line of text uncleared. - -
      • fix a similar problem where the double-size attribute would not be - reset when clearing the screen while the display was scrolled up. - -
      • fix an indexing error which would occur if an application cleared - a line while the display was scrolled up and was also in UTF-8 mode - (Redhat #524503). - The error was from patch #228 - but more visible after - changes from patch #244. -
      - -

      Patch #248 - 2009/9/11

      -
        -
      • fix an overlooked adjustment for selecting double-width characters - in the narrow-character configuration. - -
      • eliminate uses of XTERM_CELL and - XTERM_CELLC where an appropriate LineData - pointer is available. - -
      • correct expression in okScrnRow macro, making - selections give the length of lines below the visible screen - (report by Stuart Henderson). - -
      • correct logic used to improve performance of missing-glyph check, - which did not handle line-drawing characters (Debian #545220). -
      - -

      Patch #247 - 2009/8/30

      -
        -
      • add ifdef's and check for openpty() on DragonFly (patch by - Alex Hornung). - -
      • correct calculation for size of line's data block, which was - sometimes off-by-one when configured - using --enable-16bit-chars - (report by H Merijn Brand). - -
      • fix indexing error in print-everything feature from - patch #246 (patch by Ovidiu Gheorghioiu). -
      - -

      Patch #246 - 2009/8/16

      -
        -
      • remove obsolete logic for saving/restoring wrapping flags, which - did not work on 64-bit platform. Wrapping flags (stored in the - line-index) are now copied with line-data (Debian #541160). - -
      • modify comments in app-defaults files to avoid problem with - C preprocessor used by xrdb (Debian #541603). - -
      • restore special case in makeColorPair, - needed for colorBDMode resource (Debian #541089). - -
      • correct SetLineFlags() macro, broken in - patch #244 - when recoding to avoid gcc-specific bitfields (Debian #541236). - -
      • modify initialization of screen buffers to ensure that pointers - align to int-boundaries. - This fixes a problem introduced in - patch #244 - where the color- and character-arrays - (stored after the video-attributes in each row) - might be misaligned (report by Rajeev V Pillai). - -
      • add limit-check in ScrnRefresh for handling - saved-lines from the circular buffer which are repainted on a - screen whose width has increased. To improve performance, circular - buffer entries are not resized (report by Rajeev V Pillai). - -
      • correct type for CellColor (a late change in - patch #244 - to avoid gcc-specifc enums made that unsigned - rather than unsigned short, for the 256-color option). - -
      • fix typo in configure option --enable-16bit-chars (report by - Rajeev V. Pillai). -
      - -

      Patch #245 - 2009/8/12

      -
        -
      • correct a special case in saving FIFO-lines from - patch #244. - If the screen was shrunk, xterm used the wrong amount for copying - to FIFO-lines, and then used this amount to adjust the current - row on the screen. That was both a visible defect (Debian #541109) - as well as a potential addressing error (Debian #541132, #541160, - and #541236). - -
      • add clarification in xterm manual about the - various allowXXXOps resources, which - are disabled when the - allowSendEvents resource is active (patch by - Julien Cristau, Debian #531597). -
      - -

      Patch #244 - 2009/8/9

      -
        -
      • refactored storage of saved-lines, providing a configure option - to manage them as a FIFO (actually a circular buffer), improving - performance. - Added configure option --enable-fifo-lines to - enable/disable the new feature (it is enabled by default). - -
      • added fastScroll resource, to amuse - people who measure terminal emulator performance by - cat'ing large files to the screen. - -
      • modify check in readPtyData from return values - to provide exit on zero-bytes read from pty for FreeBSD, or - eliminate high-CPU in "xterm-hold" processing - (discussion with Ulrich Spoerlein, FreeBSD ports/136686). - The check was originally modified to combine negative/zero - values in XFree86-3.1.2E, 1996/05/06. - -
      • add configure option --enable-16bit-chars to - provide wide-characters with 16-bits (rather than the default - 32-bits). - -
      • add retryInputMethod resource to allow configuring - out the retries xterm uses to connect to non-responsive XIM - server, to work around defective X configurations as noted in - NetBSD mailing list. - -
      • make regular-expression selection work for VT100 double-sized - characters. - -
      • improve layout when drawing missing characters in a proportional - font, e.g., as boxes, to take into account whether they are - double-width (report by Guilbert Stabilo on comp.unix.shell). - -
      • add capability for keypad-center (kb2/KA2) to termcap entry for - xterm-new, as well as xterm-8bit, xterm-sun and xterm-vt220 - (FreeBSD conf/136336). - -
      • change default for keepSelection resource to true - (prompted by discussion with David Muir Sharnoff). - -
      • remove a limit-check in ptydata.c, allowing Unicode values past - 64k to be displayed using TrueType fonts (Debian #458432). - -
      • remove a vt52-specific ifdef to allow mapping F1-F4 to PF1-PF4 - when vt52 support is not compiled (report by Olaf 'Rhialto' - Seibert). - -
      • save/restore line-wrapping flags when converting from ISO-8859-1 - encoding to UTF-8 encoding, as well as when resizing screen. - -
      • remove extra adjustment of position in fix for Debian #418324. - -
      • modify default check for mkWidth resource to check - for line-drawing characters, which are categorized as double-width - in Solaris 10 (report by Sebastian Kayser). - -
      • add "print-everything" action (patch by Ovidiu Gheorghioiu). - -
      • start refactoring scrollback data using new getLineData() function. - -
      • demote recent change to Debian #252873 fix to experimental, - ifdef'd out as EXP_BOGUS_FG (Debian #522141). - -
      • work around groff mapping of ASCII quotes using macros (requested - by Reuben Thomas based on Colin Watson advice, fixes Debian #378700). - -
      • correct symbol used for default of allowWindowOps - which was DEF_ALLOW_FONT - rather than DEF_ALLOW_WINDOW - (report by Matthieu Herrb). - -
      • amend fix for tek4014 from patch #243 - to make it only apply to the Tek Options menu. -
      - -

      Patch #243 - 2009/3/28

      -
        -
      • revert change to default for allowTcapOps (request by - Bram Moolenaar). - -
      • reallocate result returned by xtermEnvLocale() to - avoid reference to freed memory after handling - menuLocale resource. - -
      • fix an old (X11R5) bug in tek4014 for switching fontsizes. - -
      • add resource defaultString to make configurable the - use of "#" when pastes of UTF-8 text fail due to limitations in - the current locale settings. - -
      • make the set of selection target Atom's configurable by two new - resources eightBitSelectTypes and - utf8SelectTypes, e.g., to use the TEXT - Atom in preference to UTF8_STRING (discussion with - Stanislav Sedov regarding koi8rxterm and the FreeBSD port). - -
      • modify handling of TARGETS Atom by making it return - exactly the set of targets as those which xterm is currently - providing. - -
      • set MANPAGER and PAGER explicitly to - /bin/cat in minstall.sh to work around /etc/man.conf's - with those variables already set - (report by Марьясин - Семён). -
      • improve error-checking of tcap-query parser. - -
      • add check for keyboard tcap), which ensures that - terminal descriptions containing the same string for - shifted/unshifted keys will be seen by tcap-query as only the - unshifted key. (This would only happen with an incorrect terminal - description). - -
      • fix conversion for input event-state to modifier-parameter which - made tcap-query feature not work with tcapFunctionKeys - (keyboard type tcap). - -
      • add "DEF_ALLOW_XXX" definitions to main.h to allow - overriding the default compiled-in values for - "allowxxx" resources. - -
      • remove check on bell-percentage added in - patch #242, - which disallowed zero/negative values (Redhat Bugzilla #487829). -
      - -

      Patch #242 - 2009/2/15

      -
        -
      • fix configure check for XkbBell and provide - appropriate parameter for it. - -
      • fix a caching problem with double-size fonts versus reverse video - that could cause core dump. - -
      • repair double-size fonts from workaround - used in patch #240. - -
      • add new section to the VT Fonts menu which allows enabling or - disabling the font, termcap (tcap-query), title and window - operations. - -
      • add fontWarnings resource, to control whether to show - warnings on failure to load a font. - -
      • improve warnings for unloadable fonts introduced in - patch #240 - by limiting those to the cases where a font would be specified - directly by a resource setting rather than a derived fontname. - -
      • further amend fix for Debian #252873 - from patch #197 to - treat a blank cell which does not have both foreground and background - colored as a non-colored cell. - This improves a special case where the cursor is on a blank - cell which had foreground color scrolled in - (report by Miroslav Lichvar). -

        - Also add the same logic when hiding cursor, so the outline matches - the in-focus cursor. - -

      • modify internals to reduce places PAIRED_CHARS() is used, making - WriteText() and ScrnWriteText() accept IChar array, as well as - providing a wrapper for drawXtermText(). - -
      • change default XIM font from "*" to "fixed" to improve startup - time in zh_CN.UTF-8 locale (Mike Fabian, SuSE Bugzilla #464930). - -
      • typo in #240 log (Slava Semushin) -
      - -

      Patch #241 - 2009/1/26

      -
        -
      • improve checks for missing bitmap fonts, fallback to "fixed" as - needed to work around broken font-packages (report by Jacek - Luczak). - -
      • fix breakage from patch #240 changes for - xtermAddInput() (patches by Jeff Chua, Julien Cristau). -
      - -

      Patch #240 - 2009/1/25

      -
        -
      • use plink.sh for linking xterm (suggested by Larry - Doolittle). - -
      • add resource descriptions for input method to xterm manpage. - -
      • update configure script; consistently append to $CFLAGS rather - than prepend. - -
      • add install-scripts rule to makefile, to allow - koi8rxterm and uxterm scripts to be altered independently of - install-bin - -
      • add -maximized command-line option and corresponding - resource (prompted by alt.os.linux newsgroup comment). - -
      • modify translations of scrollbar widget using - xtermAddInput() - (see patch #181) to accept the actions - that the vt100 widget accepts, such as shift-insert to perform - a paste operation (request by Martin Zwickel). - -
      • change default for allowTcapsOps resource to false, - since it causes unexpected behavior for vim users with - AltGr. - -
      • update config.guess, config.sub -
      - -

      Patch #239 - 2009/1/8

      -
        -
      • correct a cast in input.c, which broke translation of numeric - keypad codes to pageup, pagedown, etc., on 64-bit platform - (Debian #511138, report by Larry Doolittle). -
      - -

      Patch #238 - 2008/12/30

      -
        -
      • update configure macro CF_XOPEN_SOURCE for AIX 6.x and Mint - platforms. - -
      • reset the screen wrapping-flag at the end of - ClearRight to fix an occasional case where the last - character of a scrolled and wrapped line would be cleared (patch by - Joe Peterson). - -
      • modify to use POSIX coding for comparing resource settings such - as locale, to work with locales such as Turkish - (report by M Vefa Bicakci). - -
      • turn on configure paste64 feature by default - (request by Jean-Philippe Bernardy). - It is runtime enabled/disabled with allowWindowOps. - -
      • turn on configure tcap-query feature by default, - add resource allowTcapOps - to make this runtime enabled/disabled. - -
      • make OSC 3 (change X property, from - patch #110) - subject to allowWindowOps resource. - -
      • make VT220 DSR responses inactive in VT100-mode. - -
      • make DECUDK feature inactive in VT100-mode. - -
      • respond to incorrectly formatted DECRQSS with a - cancel. - -
      • add allowFontOps - resource to allow the fontsize-switching and font query/set - control sequences to be enabled/disabled - (prompted by Debian #510030). - -
      • some code cleanup based on gcc 4.x -Wconversion - warnings in button.c and charproc.c - -
      • modify tcap-query feature to not return data for - shifted cursor-keys when the keyboard type is set to vt220, - since returning the same string for shifted/unshifted keys may - confuse some applications (GenToo #212546). -
      - -

      Patch #237 - 2008/09/14

      -
        -
      • improve usability of TrueType fonts by making the font-size - switching for shifted keypad plus/minus use the - faceSize resources to determine the order of fonts - (when TrueType fonts are used) rather than the bitmap fonts, since - their sizes may not be in the same order (report by H Merijn - Brand) - -
      • remove an optimization of ConfigureNotify events - from patch #236 - which seems to interfere with passing SIGWINCH to - applications (GenToo #233836). - -
      • modify handling of altSendsEscape to reset the - eightBitInput mode, like metaSendsEscape - (patch by Ted Phelps). - -
      • add feature to show the text-cursor as an underline rather than a - box, plus command-line options -uc and - +uc and resource cursorUnderLine to - control the feature (patch by Paul Lampert). - -
      • update config.guess, config.sub -
      -

      Patch #236 - 2008/07/27

      -
        -
      • correct memory reallocation when handling a paste of UTF-8 text - from patch #225 changes - (report/patch by Max Mikhanosha). - -
      • correct allocation of temporary buffer in - xtermFindShell in case the user's $PATH - contains no ":" (report/analysis by Victor Stinner, - Freedesktop.Org Bugzilla #16790). - -
      • modify CF_XOPEN_SOURCE to add case for DragonFly BSD, to fix - new compile problem exposed by fix for fd_mask (patch by - Hasso Tepper). - -
      • add configure-check for ncurses use_extended_names, - (report by Martin Mokrejs). - -
      • correct computation for toolbar height; layout manager already - takes into account borderWidth resource. - -
      • implement VT320-style SCS (select character set) for ISO Latin-1 - supplemental. - -
      • fixes for vt100-style character sets in UTF-8 mode (Ubuntu #230919). - -
      • fix to make luit work with xterm's -ls - option (report/patch by Marius Tolzmann). - -
      • update config.guess, config.sub -
      - -

      Patch #235 - 2008/04/20

      -
        -
      • add control sequences for some of the recent resource/menu - settings: -
          -
        • altSendsEscape (private mode 1039) -
        • keepSelection (private mode 1040) -
        • selectToClipboard (private mode 1041) -
        • bellIsUrgent (private mode 1042) -
        • popOnBell (private mode 1043) -
        - -
      • add resource formatOtherKeys to provide an alternate - escape sequence format for the modifyOtherKeys - resource (request by Paul LeoNerd Evans). - -
      • adjust saved-cursor position if the window is resized while - displaying the alternate screen (Novell #196880, Debian #383384). - -
      • improve pointer-checks to fix a bug exposed by resizing during - initialization under StumpWM window manager - (Fedora Bugzilla #437928). - -
      • modify unselectwindow() to ensure that the mouse - pointer is not hidden after xterm loses focus (report by Jeremy - Huddleston). - -
      • add special check for fd_mask on Mac OS X (report by Jeremy - Huddleston). - -
      • add dylib to autoconf's suffix list used for checking - the result from xmkmf, to work with Mac OS X (report - by Jeremy Huddleston). - -
      • correct initialization of bold- and wide-, wide-bold fonts which - may be set via the utf8Fonts subresource (Debian - #347790). -
      - -

      Patch #234 - 2008/03/02

      -
        -
      • modify sinstall.sh to use POSIX locale to - bypass GNU ls changes to date-format. - -
      • improved/refined changes for closing bitmap font (patch by - Andrea Odetti). - -
      • improve resize computation for situations where the negotiation - fails, by invoking the xterm widget's core-class resize method - (Debian #365602, patch by Jim Paris). - -
      • restore initialization of terminal's VMIN and - VTIME settings, - from patch #232 changes - (patch by Matthieu Herrb). -
      - -

      Patch #233 - 2008/02/24

      -
        -
      • add configure check for ttydefaults.h, include if - needed, e.g., for systems where defining - _POSIX_C_SOURCE, etc., - prevents it from being included via - termios.h (prompted by comments by Robert Delius Royar - and Jeremy Huddleston). - -
      • bug-fixes for bugs.opensolaris.org (patches from Alan Coopersmith) -
        -
        4029911 -
        fix a typo in manpage -
        4045962 -
        xterm doesn't properly set ut_syslen -
        4192572 -
        left-left-right misinterpreted as triple click -
        - -
      • minor optimization to tab-initialization (patch by - Németh Márton). - -
      • fix a case where an incorrect font was freed during initialization - from patch #232 changes (patch by - Andrea Odetti). - -
      • improve comparison used in SameFont function for - GC-caching (Julien Cristau). - -
      • correct macro name used for default CKILL definition - to work with Mac OS X (report by Jeremy Huddleston). -
      - -

      Patch #232 - 2008/01/30

      -
        -
      • corrected logic in a font-cache used for reverse-video (Debian - #404079). - -
      • add control sequence to alter pointerMode at runtime. - -
      • add limit-checks for rectangle operation parameters (report by - Martin Pirker). - -
      • modify minstall.sh to suppress $MANPAGER - and $PAGER environment variables, which may interfere - with redirecting output of man to a shell variable - (report/patch by Zdenek Sekera). - -
      • do not try to hide mouse pointer in the tek4014 window, fixes - broken "-t" option at startup from - patch #230 changes - (report by Robert K. Nelson). - -
      • correct datatype used when drawing tek4014 data using xterm - compiled for wide-characters, on big-endian machines (reports - by Jeremy Huddleston, Harald Hanche-Olsen, Martin Costabel, Merle - Reinhart). - -
      • modify to cache the font-names along with the bitmap font data, - to improve comparison of fonts. - -
      • modify to allow building with configure options - --disable-ansi-color and - --disable-leaks (Debian #459817, report/patch by Németh Márton). - -
      • modify to allow building with configure options - --enable-wide-chars and - --disable-c1-print (Debian #459816, report/patch by Németh Márton). - -
      • add pointerMode resource to control whether and - when the pointer cursor is hidden as the user types. - -
      • simplify initialization of ttyMode- and related characters using - a table. - -
      • modify initialization-logic for stty values that correspond to - ltchars structure and the BSD TIOCSLTC ioctl (susp, dsusp, rprnt - flush, werase, lnext). These were reset to constants for both - termios and legacy interfaces immediately after asking the system - for the existing values since X11R6.1, rather than using them to - provide inherited values. While the legacy interface has some - constraints, e.g., on HPUX, the POSIX or termios interface should - not. Your shell may reset these anyway - (prompted by patch by Ed Schouten). - -
      • improve logic for hiding/displaying pointer-cursor (report by - Mark Brukhartz). - -
      • add limit-checks to tabs.c, increase maximum column for setting - tab-stops from 320 to 1024 (report by Németh Márton). - -
      • correct length, i.e., number of types of selection targets, - computed by ConvertSelection() when not handling - wide characters for the XA_TARGETS() case. - This leaves an extra Atom on the end of the list which is - not handled by - Java applications. - The problem was introduced in patch #151 - (report by David Wood). -
      - -

      Patch #231 - 2008/01/05

      -
        -
      • undo change to getXtermCell() from patch #230 - using PACK_PAIR macro (Debian #459014, analysis by - Caetano Jimenez Carezzato). - -
      • minor documentation fixes (patch by Slava Semushin) - -
      • add makefile actions to install KOI8RXTerm app-defaults file - (patch by Julien Cristau). -
      - -

      Patch #230 - 2007/12/31

      -
        -
      • add quietGrab resource, which when true, suppresses - cursor repainting when NotifyGrab and - NotifyUngrab event types are received during - change of focus (request by Nicolas George). - -
      • do not treat Unicode BIDI control characters as combining - characters (Debian #457634). - -
      • add koi8rxterm, from Debian. - -
      • add manpage for uxterm, from Debian (Ubuntu #128136, - Debian #438645) - -
      • remove ".xpm" suffixes from Icon filenames in desktop files since - it confuses some lookups following the - Icon Theme Specification - (report by Slava Semushin) - -
      • correct width-calculation used for adjusting proportional fonts, - to work with wide-characters (Debian #441354). - -
      • fixes/improvements for double-size characters: -
          -
        • correct old clipping calculation which used total height of - glyphs where ascent was needed. - -
        • if bold font is unavailable, fall back to normal font - -
        • adjust to "work" with Xft (which does not support double-width - single-height characters). - -
        • restore reset of doublesize for a line when it is cleared, - broken in patch #228. -
        - -
      • modify logic for forceBoxChars resource when using - TrueType fonts to be consistent with bitmap fonts - -
      • modify logic for forceBoxChars resource to make the - "Line-Drawing Characters" menu entry use xterm's line-drawing - characters even asked to draw wide line-drawing characters which - are available in the font. - -
      • modify rectangle-support functions to preserve colors when - filling/erasing to match WRQ Reflection behavior - (request by Enzo Toscano). - -
      • add getopt-parsing to tcapquery.pl, including feature to test the - extended cursor/editing keys. - -
      • make missing double-width glyphs display as double-width - (Debian #456236). - -
      • change tcap-fkeys and rectangles - configure options to enable them by default. - -
      • hide the mouse pointer while user is typing (request by Rodolfo - Borges). - -
      • extend configure options - --enable-tcap-query and - --enable-tcap-fkeys to - send cursor- and editing-keypad keys modified according to the - keyboard (or termcap) selection for shift, alt, control, meta. - -
      • modify kdch1 in termcap, e.g., xterm-r6 - to match the terminfo file. - -
      • add -hm option to turn highlightColorMode - on or off. - -
      • add highlightColorMode resource to separate the - new (since patch #225) highlighting with both text- and - background-colors (prompted by report/example by Thomas Wolff). - -
      • add Keep Selection menu entry to turn the - keepSelection resource on/off at runtime. - -
      • add keepSelection resource, which when enabled, - tells xterm to retain the X selection even after it stops - highlighting it (patch by Sergey Vlasov). - -
      • extend the CSI > n sequence to allow - disabling all types of modified-keys that the - CSI > m sequence affects. - -
      • move include for <xtermcap.h> in - resize.c to avoid redefinition of termios - structure on OpenSolaris (report by Rahul Gopinathan Nair). - -
      • extend terminfo building blocks for modified editing keys to - include all six keys. - -
      • synchronize terminfo with ncurses (report by Stephane Chazelas) -
          -
        • equate xterm-xfree86 - and xterm-xf86-v44. -
        • add ncurses extensions OTbs, AX, for termcap conversions. -
        • make old/legacy entries such as - xterm-24, xterm-65 - and aliases xterms, vs100 - inherit from xterm-old. -
        • make xterm-r5 and xterm-r6 the - same, ignoring historical errors in X Consortium's version. -
        - -
      • fix an ifdef in logic for selecting regular - expressions while in a narrow-character locale (Debian #449227). -
      - -

      Patch #229 - 2007/8/12

      -
        -
      • override locale in minstall.sh; - change in patch #226 - does not work in UTF-8 locale (report by Zdenek Sekera). - -
      • undo an incorrect fix for a memory leak - in patch #209 (Debian #435858). -
      - -

      Patch #228 - 2007/7/22

      -
        -
      • modify configure script to permit combining - --with-utempter - and --enable-setuid, e.g., for using xterm with - the utempter library on FreeBSD (report by Andriy Gapon). - -
      • modify "Quit" menu entry to override the -hold - command-line option. - -
      • add a check in the startup error-reporting to avoid writing to - pipe when it has not been opened. In that case, report errors - directly to the standard error. - -
      • add OPT_READLINE definition to xtermcfg.hin, overlooked in - patch #205 - (report by Kalle Olavi Niemitalo). - -
      • modify 88colors2.pl and 256colors2.pl, - adding -r - option to reverse the palettes for the extended colors. - -
      • check for partial overwrite or deletion of multi-column characters - in several cases, e.g., insert-character, delete-character, - etc., - and fill the remainder of the cells used by the multi-column - characters affected with blanks. - -
      • correct character-class codes in wide-character mode for characters - 215, 247 (see also patch #165). - -
      • fix missing assignment for UTF-8 parsing in widget initialization - (Debian #403360). - -
      • correct index expression used to set line-wrapping flag, making - selection from scrollback work consistently (Debian #430121, - report by Vincent Lefevre). - -
      • amend changes to handshake in - patch #226 - to accommodate Solaris, which relies on the extra setting of - the terminal size after I/O initialization. - Do this by adding new resource ptySttySize, - which is false for Linux and MacOS X, i.e., true for - for Solaris and other SVR4 platforms, as well as FreeBSD - (reports by David Wood, Renato Botelho). - -
      • check for X events after cursor-left, and carriage return, - consistent with indexing operations - (comments by Vegard Nossum and Ingo Molnar on a mailing-list). - -
      • initialize the .keyboard structure, - needed for some platforms (such as Solaris) after - patch #227 fixes for keysyms - (patch by David Wood). - -
      • update config.guess, config.sub -
      - -

      Patch #227 - 2007/6/27

      -
        -
      • exclude the Intel compiler from the extra gcc warning options - added in - patch #226. - -
      • modify change for Debian #422521 - from patch #226 - to work with configurations where the X server does not - recognize - the XF86Paste - or SunPaste keysyms (report by Paolo Pumilia). - -
      • fix incorrect free in fix for "Selection" menu entry in - patch #226. -
      - -

      Patch #226 - 2007/6/17

      -
        -
      • add configure check to use -Wno-unknown-pragmas for - Solaris, and a few other new gcc warning options to address - regressions in its warning options. - -
      • add sample desktop and icon files, along with configure options for - manipulating them. - -
      • fix an infinite loop when showing a 2-column character in a - 1-column screen (Debian #426863). - -
      • add XF86Paste and SunPaste to the - default translations (Debian #422521, patch by Bernhard R Link). - -
      • update wcwidth.c (partly based on/prompted by mailing list - comment). - -
      • update/improve keysym2ucs.c based on Unicode 5.0.1d3 and Xorg - 7.1 keysymdef.h file. - -
      • improve gen-pc-fkeys.pl, making it show all of the - building-block terminfo entries used by xterm. - -
      • correct strings used for modifiers applied to F1-F4 in xterm+pcf1 - terminfo entry. - -
      • improve session management by adding the ICE connection number - to the select call rather than waking up once per - second (patch by Miroslav Lichvar). - -
      • add environment variable $XTERM_LOCALE to help - with shell initialization, e.g., to set a specific locale for - xterm on systems where a global locale is set in the shell - startup scripts. - -
      • add resource settings mkSampleSize and - mkSamplePass - to modify the mkWidth added - in patch #201. - In patch #202, - xterm would also check if the system's - wcwidth matched its built-in tables - "well enough" to be used when mkWidth was false, - and if not would use the built-in tables anyway. - These resources allow the user to customize the decision - (prompted by comments by Emanuele Giaquinta) - -
      • modify logic which resets/updates the screensize on the child - process side of the pseudo-terminal to do this only if a - successful handshake was received, e.g., as determined by - the waitForMap resource (prompted by reports - by Emanuele Giaquinta and Bernhard R Link, but see also - patch #177 and - patch #159. - -
      • improve permissions logic when closing pseudo-terminal - (Debian #12261, - patch by Nathanael Nerode, - analysis by Richard Braakman). - -
      • add resource highlightReverse which controls whether - xterm will allow selection highlighting to hide reverse-video - or use the older behavior which inverts the foreground and - background colors when selected text with reverse-video attribute - (report by Adam M Costello, comments by Victor Vaile). - -
      • restore a special case for cursor-color in - ReverseVideo() - lost in rewrite for patch #224 - (report by Adam Sulmicki). - -
      • correct initialization for menu entry for bellIsUrgent - (patch by Emanuele Giaquinta). - -
      • correct length of underlining for double-width Xft fonts - (report by Shidai Liu "Leo"). - -
      • correct clipping for double-width Xft fonts - (report by Shidai Liu "Leo"). - -
      • modify initialization for italicULMode to avoid - XftPatternBuild reusing bold attributes - (report by Shidai Liu "Leo"). - -
      • add a check in case someone tries to call the - popup-menu() action on a menu which is not initialized - (Debian #426364). - -
      • improve CF_IMAKE_CFLAGS to work with Solaris sed (report by Peter - Bray). - -
      • improve guess for X's manpage section in minstall.sh, - (prompted by comment by Miroslav Lichvar). - -
      • modify minstall.sh to handle manpage patch with more - than one dot (patch by Miroslav Lichvar). - -
      • fix configure message for --disable-setgid option (patch by - Miroslav Lichvar). - -
      • add allowTitleOps resource to allow users to prevent - the title- and icon-names from changing (request by John Bashinski). - -
      • fix "spawn-new-terminal" action, for the case where no parameter - is passed to the action (patch by Daniel Colascione). - -
      • fix error-checking on internal font switching for "Selection" - menu entry (Debian #421523). - -
      • amend select/paste change from - patch #225 - by limiting it to non-UTF-8/non-KOI8-R encoding (Debian #420974). - -
      • add workaround for groff ".URL" codes which are not present in - some commonly-used bitmap fonts (Debian #418324). -
      - -

      Patch #225 - 2007/3/24

      -
        -
      • add useClipping resource to allow clipping to be - disabled. - -
      • use XftDrawSetClipRectangles - to work around Xft pixel-trash (report by Reuben Thomas). - -
      • add configure option --enable-tcap-fkeys, and - resource tcapFunctionKeys, which can be used - to tell xterm to use function-key definitions from the termcap - (or terminfo) which it uses to set $TERM on startup. - -
      • add resources altIsNotMeta and - altSendsEscape to allow one to use Alt-keys like the - meta-key even if they are bound to different keycodes (prompted by - discussion with Daniel Jacobowitz). - -
      • revert a change from patch #216 - that unnecessarily made the meta modifier override - the eightBitInput resource if the alt- and - meta-modifiers happened to overlap - (report/patch by Daniel Jacobowitz). - -
      • correct associated font for active icon for colored text - (broken in patch #224). - -
      • correct ifdef's for Darwin (patch by Emanuele Giaquinta). - -
      • add highlightTextColor resource, and options - -selfg, -selbg like xwsh - (adapted from patch by Victor Vaile). - -
      • revise find_closest_color() function to address - concern about borrowing from Tcl/Tk - (request by Dan McNichol). - -
      • add "spawn-new-terminal" action, which can be assigned to key - translation, allowing one to spawn a new copy of xterm using - the current process' working directory (adapted from patch - by Daniel Colascione). - -
      • improve select/paste between UTF-8 and Latin1 xterms by adapting - the translations from patch #185. - Extend that to include Unicode fullwidth forms FF00-FF5E. - Also modify select/paste of DEC line-drawing characters in - Latin1 mode to use ASCII characters. - -
      • add "Enable Bell Urgency" to VT Options menu, removed "Enable - Margin Bell". - -
      • add bellIsUrgent resource to control whether the - Urgency hint is set/reset. - -
      • modify to set Urgency window manager hint on bell, reset it on - Focus-In event (patch by Emanuele Giaquinta). - -
      • add --disable-setgid configure option (request by - Miroslav Lichvar). - -
      • fix a possible infinite loop in last change to - dabbrev-expand() (patch by Emanuele Giaquinta). - -
      • modify initialization to set the pty erase value if the - erase is set in the ttyModes resource. - This overrides the ptyInitialErase setting (request by - Lluís Batlle i Rossell). - -
      • add initialFont resource to xterm widget, like - tek-widget (Debian #299669). - -
      • amend change to boldMode from - patch #223 for Debian #347790. - As noted in Debian #412599, that made xterm - no longer match the documented behavior. - Add new resource alwaysBoldMode - to allow overriding the comparison - between normal/bold fonts when deciding whether to use overstriking - to simulate bold fonts. - -
      • restore background color in ClearCurBackground(), omitted in - changes for patch #223 (report by - Miroslav Lichvar). - -
      • correct logic for repainting double-width TrueType characters - (prompted by test-case for Novell #246573). - -
      • add a check to avoid trying to repeat a multibyte character - (report by Sami Farin). - -
      • modify parameter to XftNameParse() to select wide - face-name as needed, to make -fd option work (patch by - Mike Fabian, Novell #246573). - -
      • correct logic for mouse highlight tracking's abort sequence, - broken in a restructuring modification from - patch #224 - (report by Thomas Wolff). - -
      • revert the simplification of blinking cursor, since that broke - the xor'ing introduced in patch #193 - (report by Thomas Wolff). -
      - -

      Patch #224 - 2007/2/11

      -
        -
      • simplify code for set/reset mode for blinking cursor - (patch by Emanuele Giaquinta). - -
      • modify dabbrev-expand() to restart after the last - match (patch by Emanuele Giaquinta). - -
      • add control sequences for enabling/disabling focus in/out event - reporting (request by Bram Moolenaar). - -
      • improve startup performance of menus by adding resource setting - menuLocale which can be set to override X's - lengthy initialization of fontsets - which are seldom used - for the Xaw popup menus (adapted from patch by - Dave Coffin). - -
      • modify do_precomposition() function and make-compose.sh to handle - 21-bit codes vs the 16-bit codes those were written for, and - fix a few mis-sorted codes - (patch by Thomas Wolff). - -
      • handle special case in -cjk_width - which unexpectedly caused a character's width to change when - a combining character - (patch by Thomas Wolff) - -
      • fix build for GNU/KFreeBSD (Debian #40111). - -
      • consolidate GC creation/updating into a single module to reduce GC - manipulation (prompted by Debian #389476, though a complete fix - would involve optimizing the scrolling behavior). - -
      • fix ifdef of xtermCellWidth(), which broke for a case without - TrueType and without wide-character support (report by Martin - Pirker). - -
      • 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 - (Debian #401726, Redhat Bugzilla #223027). - -
      • allow -cr option to override cursor color when - -ah option is used (Debian #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 (Debian #405043). - -
      • make Selection of VT Fonts work with - selectToClipboard resource. - -
      • correct length calculation for Selection entry of - VT Fonts menu, broken since it ignored the - actual selection length since X11R4. - -
      • fixes for fontsize changes with -fa option (Redhat - Bugzilla #222340). -
      - -

      Patch #223 - 2006/11/30

      -
        -
      • add --enable-rectangles configure option (request by - Martin Pirker). - -
      • correct default value for --with-symlink configure - option. - -
      • fixes configure script macros that use $X_EXTRA_LIBS. - -
      • modify configure script to provide support for pre-package config - versions of Xft aka "FreeType". - -
      • add the Xaw scrollbar translations resource to the xterm manpage, - add an example showing how to change the mouse button assignments - (Debian #382225). - -
      • amend a change from patch #216, - which omitted modifiers for control, meta, etc., if they were - mixed with any other modifiers. The intent of the change was - to avoid confusion with - XK_Mode_switch - and XK_ISO_Level3_Shift; - the check is now done explicitly (report by Daniel Jacobowitz). - -
      • interpret a negative value for modifyCursorKeys - or modifyFunctionKeys resources to disable the - respective features (prompted by Novell #220728). - -
      • amend cell-width computation for FreeType from - patch #217, which did not work - for VT100 line-drawing characters (Debian #399638, GenToo #147111). - -
      • amend a change from patch #216, - which made alt-modifier on a cursor-key send a modifier parameter - (Novell #220728). - -
      • correct an off-by-one that made DECCRA not work (report/patch by - Martin Pirker). - -
      • revert an optimization in SGR_Foreground() and SGR_Background - from patch #209 (Debian #347722, - analysis by Pierre Lombard). - -
      • fix for boldMode (Debian #347790, patch by Tim Pope). - -
      • amend fix for -iconic in - patch #208, - which broke the positioning part of -geom with toolbar - configuration. - -
      • fix to prevent indexing error in regular expressions (patch - by Dennis Schneider). - -
      • 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 (report by - Neil Hoggarth, also Debian #397624). -
      - -

      Patch #222 - 2006/10/17

      -
        -
      • minor optimization for recoloring cursor via dynamic colors. - -
      • fix a bug caused by restructuring of tek4014 widget (report by Paul - Schenkeveld) -
      - -

      Patch #221 - 2006/10/1

      -
        -
      • fix for regular expressions: the code which converted the column - offset within a line did not check properly for the end of a line, - and if allowed to match the whole line, would select the beginning - of the following line. If the following line were empty, in turn - it would select from the next, etc. (report by Sean - Reifschneider). - -
      • minor optimization of color allocation to avoid repainting the - screen if the corresponding color had not been allocated. - -
      • fixes for vttests/256colors.pl (report by Egmont Koblinger). - -
      • add terminfo building block entries for modifiers of the 6-key - editing keypad. - -
      • fix for initialization of tek4014 which broke on QNX 6.1 -
      - -

      Patch #220 - 2006/9/10

      -
        -
      • make "xterm -t -iconic" work as expected, i.e., start in tek4014 - mode, but iconified. -
      - -

      Patch #219 - 2006/9/4

      -
        -
      • some internal restructuring to separate data for vt100 and tek4014 - widgets. - -
      • fix a few cases where form-events would be seen by the vt100 - widget when built with the toolbar configuration. -
      - -

      Patch #218 - 2006/8/27

      -
        -
      • change behavior when encountering an illegal character in a title - string. Rather than reject the string, translate illegal - characters into "?" and use the string (requested by Thomas Wolff). - -
      • improve checks for nonprinting characters in title strings - (report by Samuel Thibault). - -
      • correct typo in menu labels, changing print-redirect - to print-redir, making it follow the manpage and - match the usage for the actions table (report by Samuel Thibault). - -
      • correct a typo that prevents building with some older systems such - as Solaris 2.6 (report by Julian Bridle). -
      - -

      Patch #217 - 2006/8/20

      -
        -
      • minor improvements to FreeType font layout and drawing. - -
      • add a check in the ptyInitialErase logic to ensure that the - termcap was read (Redhat Bugzilla #201246). - -
      • limit changes for reverse-video from - patch #216 to cases where the - reverse-video command-line option is used - (report by Zdenek Sekera). - -
      • correct bitmap-derived pointsizes for TrueType fonts; they should - be proportional to the square root of the area of the bitmap - fonts. - -
      • add resources to specify pointsize of TrueType fonts (request - by Reuben Thomas). - -
      • improve install of terminfo by filtering out harmless messages - related to extended capabilities. At the same time, use ncurses - tic to compile the extended capabilities if possible - (report by Zdenek Sekera). - -
      • update "xterm+pcfkeys" terminfo entry to correspond to - patch #216. -
      - -

      Patch #216 - 2006/8/3

      -
        -
      • improve handling of ConfigureNotify events by checking - if there are further events in the queue which obsolete the current - one (adapted from rxvt 2.7.5). Only the normal normal - (non-toolbar) configuration is addressed in this patch. - -
      • several changes to terminfo: -
          -
        • incorporate some minor changes from ncurses to help keep these - synchronized: -
          -
          2005-02-26 -
          modify sgr/sgr0 in xterm-new to improve tgetent's derived "me". -
          2006-02-18 -
          remove ncv flag from xterm-16color -
          2006-06-24 -
          improve xterm-256color by combining the 16-color - setaf/setab strings with SGR 48, - and cancelling the setf/setb strings. -
          -
        • use extended function-key definitions for xterm-sun, xterm-sco - entries. - -
        • add terminfo building-blocks corresponding to the - modifyFunctionKeys - and modifyCursorKeys resources. -
        - -
      • ifdef'd Sun function-key feature to make it optional, like HP and - SCO. - -
      • extend table for termcap-query feature through F63, and updated - tcapquery.pl to match. - -
      • modify logic for function-key input processing to allow function - key numbers which are constructed by control- and shift-modifiers - to extend beyond X's hardcoded limit of 35. - -
      • add control sequence to set or reset the eightBitInput - resource. - -
      • change default resource modifyFunctionKeys to 2 - to avoid sending SS3 with parameters (report by Kalle Olavi Niemitalo). - -
      • add control sequences for setting and resetting the values of the - modifyCursorKeys, - modifyFunctionKeys and - modifyOtherKeys resources. - -
      • add modifyFunctionKeys resource like - modifyCursorKeys. - Setting this to zero allows one to use the control- and - shift-modifiers to construct function key strings, - for terminals using many function keys, - e.g., for xterm-sun or xterm-sco. - -
      • modify screen responses and function-key logic to reduce the - number of writes made, to make it less likely that an application - would read only part of a function-key in a read operation - (suggested by John E Urbanczyk). - -
      • add combiningChars resource, which allows the user to - specify the maximum number of combining characters that xterm will - store for each cell in wide-character mode (prompted by request by - Markus Kuhn to increase the limit from 2). - -
      • improve logic in metaSendsEscape in case the Alt- - and Meta-keys are mapped to different modifiers. That allows one - to use the Alt-key for shifting in the eightBitInput - and use a Meta-key modifier to prefix the result with an - <ESC>. - -
      • improve modifyCursorKeys logic to prevent it from - modifying codes where eightBitInput or - metaSendsEscape are set - (request by Dan Nicolaescu). - -
      • improve modifyCursorKeys logic to prevent it from - changing the user input when other modifiers such as AltGr are used - (report by Thomas Wolff). - -
      • extend modifyCursorKeys to include the numeric keypad - when in application mode. - -
      • improve -reverse (-rv) option - (patch by Jason Vas Dias, Redhat #189161). - -
      • workaround for color resources on Fedora-5 which made the toolbar - colors inconsistent. - -
      • corrected calls used for --disable-setuid option, - add debugging traces to help diagnose this area. - -
      • modify configure script to ensure that USE_UTMP_SETGID - is defined only if the check for POSIX saved-ids succeeds, or - corresponds to one of the BSD systems known to have a workable - setegid function. - -
      • extend configure check for POSIX saved-ids to include BSD systems - -
      • modify CF_SYSV configure macro to work with gcc on HPUX 10.20, - whose broken - <term.h> relies on including - <termios.h>. - -
      • change order of setuid/setgid ifdef checks in Imakefile to make - it simpler to produce a setgid install, allowing the latter to - override the former (prompted by an XFree86 commit). - -
      • adapt a fix for setgid support from subsequent XFree86 changes - (patch by Emanuele Giaquinta). - -
      • further improve setgid support (patches by Emanuele Giaquinta). -
      - -

      Patch #215 - 2006/6/19 - XFree86 4.6.99.2

      -
        -
      • improve setgid support by exploiting the saved-ids feature on which - it relies (patch by Emanuele Giaquinta). - -
      • make the modifyOtherKeys resource disabled by default - since the intermediate setting altered some common bindings - (report by Emanuele Giaquinta). -
      - -

      Patch #214 - 2006/6/18 - XFree86 4.6.99.2

      -
        -
      • modify makefile rule for ctlseqs.txt to strip backspace/overstrikes, - and add a copy of ctlseqs.txt to the source tarballs (requests by - Bram Moolenaar, Emanuele Giaquinta). - -
      • add modifyOtherKeys resource, analogous to the - modifyCursorKeys resource. This applies to keys that - normally would transmit nothing when a given modifier is applied - (request by Dan Nicolaescu). - -
      • add default to the acceptable values for the - keyboardType resource, allowing the -kt - command-line option to override app-defaults resource settings of - sunKeyboard, etc. - -
      • correct ifdef's for XkbBell() which used the header - file but not the corresponding function in - patch #175 - (report by Zach Beane). - -
      • add xterm manpage to the --with-symlink logic. - -
      • regenerated configure script to omit some debugging artifacts of - the SIGWINCH test. - -
      • fix install-man rule in Makefile.in to - avoid including the $(DESTDIR) value in substitutions - made on the manpages (patch by Emanuele Giaquinta). - -
      • improved fix for cursor deallocation - (Redhat #186935, patch by Jason Vas Dias). - -
      • improve checks for setuid/setgid operation to accommodate limited - resource management in some kernels (GenToo #193238). - -
      • update config.guess, config.sub -
      - -

      Patch #213 - 2006/4/30 - XFree86 4.5.99.905

      -
        -
      • minor optimization to cell layout; will use that to simplify some - logic and allow for more than two combining characters in another - patch. - -
      • add utf8Latin1 resource to make optional the - feature from patch #209 which - allowed ISO-8859-1 fonts to be used in cases - where a wide font was given. This would only - work for the special case where the user normally used Latin-1 - and wanted some wide characters (report by Rostislav Krasny). - -
      • add utf8Title resource to manpage (Novell #52655). - -
      • fix typo in table entry for utf8Title resource which - made it treated as an integer rather than boolean (patch by Mike - Fabian, Novell #52655). -
      - -

      Patch #212 - 2006/4/9 - XFree86 4.5.99.904

      -
        -
      • improve description of forceBoxChars in manpage - (discussion with Joe Wells). - -
      • set checkmark for "Select To Clipboard" menu entry on startup, - from resource setting. - -
      • update manpage to note that *customization:color is - not needed, though it is useful (Redhat #188034). - -
      • add underscore to sample pattern for URL in XTerm.ad - (Redhat #188037). - -
      • modify install rule for manpage to use the configured app-defaults - directory (Redhat #188031). - -
      • add checks in releaseCursorGCs() to ensure GC's are - distinct, needed since memory leak changes for - patch #208 - (Redhat #186935, patch by Jason Vas Dias). - -
      • modify Imakefile definitions to allow - imake to set InstallXtermSetGID. - Add symbol InstGidFlags. - -
      • add configure script check to ensure that SIGWINCH if defined even - when headers undefine this as a side-effect of - _POSIX_C_SOURCE, etc. - -
      • resync with XFree86 CVS -
          -
        • ifdef-out chmod of terminal device for OS/2 (XFree86 #1663, - Frank Giessler). -
        • move new Imakefile chunk which defines - $(CSGIDFLAGS) before DEFINES, - e.g., for IRIX64 (Marc La France). -
        -
      - -

      Patch #211 - 2006/3/19 - XFree86 4.5.99.902

      -
        -
      • modify prefix/suffix transformation in makefile to make - uxterm install properly on Cygwin. - -
      • restore the sizeof-comparison for struct lastlog - added in patch #208, - rendered (mostly) obsolete in patch #210, - since an imake configuration can still turn that code on - (prompted by comment by David Dawes). - -
      • remove feature for FreeBSDArchitecture from - Imakefile which would install xterm using the - utmp group since a standard FreeBSD system has no such - group, though it would support this configuration. FreeBSD - packager uses the configure script, which can make the - appropriate check (prompted by comment by David Dawes). - -
      • fixes for gcc redefinition warnings when built using imake - (reports by David Dawes, Marc La France). -
      - -

      Patch #210 - 2006/3/12 - XFree86 4.5.99.902

      -
        -
      • add configure check for workaround in - patch #208 - for Solaris' inconsistent support for struct lastlog to quiet - compiler warnings - (prompted by David Dawes commit message for XFree86). - -
      • fixes for BASE64 selection manipulation, - e.g., ensure that the string - terminator is written after cut-buffer data (report by Joe Allen). - -
      • add vttests/paste64.pl script to test experimental option for - setting/getting selection data. - -
      • add some error-checking in fontutils.c - (prompted by David Dawes commit message for XFree86). - -
      • change xterm manpage to show the actual color resource names - XtDefaultForeground and - XtDefaultBackground rather than black and white - (prompted by discussion with Emanuele Giaquinta). - -
      • add utf8Title resource and menu entry, allowing the - user to control whether title strings are interpreted as ISO-8859-1 - or UTF-8 encoding (Novell #52655, #113206). - -
      • change order of ifdef's for utempter versus platforms in - Imakefile to ensure a proper value for - InstallXtermSetGID - (prompted by Marc La France commit message for XFree86). - -
      • update the cursor GCs when menu entry for reverse video is toggled. - (Redhat #183993). - -
      • a memory-leak fix for set_cursor_gcs() - in patch #208 broke the - -cm option (Redhat #182382). -
      - -

      Patch #209 - 2006/2/12 - XFree86 4.5.99.22

      -
        -
      • remove setf and setb from - xterm-256color terminfo entry to avoid issues with - applications that ignore the ANSI strings (report by Emanuele - Giaquinta). - -
      • remove obsolete references to "Xorg" to avoid confusion with - "X.org" (prompted by David Dawes commit message for XFree86). - -
      • improve initial layout performance for the toolbar configuration - by precalculating the height of the toolbar. - -
      • remove menu entry for "Enable Curses Emulation" (to make room for - "Select To Clipboard"). - -
      • add resource selectToClipboard, - action set-select and a menu entry to allow - users to switch between PRIMARY and CLIPBOARD for select/paste. - -
      • allow cursor to have the same color as foreground (text), since it - is rendered as reverse (Debian #350664). - -
      • amend change for loading utf8Fonts resource from patch #204 to allow an ISO-8859-1 "normal" - font to be combined with an ISO-10646 font if the latter is given - via the -fw option or its corresponding resource - value (prompted by comment in Novell #49305). - -
      • add TIOCSCTTY ioctl() ifdef'd for - __GNU__ to set the controlling terminal (Debian - #348457). - -
      • add configure option --disable-leaks. - -
      • add a check in Bell to ensure that the VT100 widget - is realized, since it may be called by xtermLoadFont - given an incorrect font resource (Redhat #180450). - -
      • improve initialization of wide-bold font by not using the derived - value when it happens to have few glyphs (report by Mboso Sampson). - -
      • improve dynamic colors by not repainting the screen if only the - cursor color changes (request by Bram Moolenaar). - -
      • fix menu initialization for tek4014 window broken in - patch #206. - -
      • typo in manpage (Debian #351425). - -
      • correct loop logic in dotext to prevent an infinite - loop if a wide character was just at the right margin when wrapping - was disabled (report by Serge van den Boom). - -
      • initialize the saved-cursor data so a restore-cursor operation - without a preceding save-cursor operation will not modify the - foreground color. - -
      • add a new selection feature: regular expressions, and new resources - which specify what happens on multiple mouse clicks: - on2Clicks, - on3Clicks, - on4Clicks and - on5Clicks. - -
      • revert the XTerm.ad change from - patch #208 (Debian #348384). - -
      • fixes for the print-window to make it handle combining - characters in UTF-8 mode. - -
      • 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 (Debian #347415). - -
      • add configure option --with-tty-group to help work - around deficiencies in packager's build environment (Debian - #349142). - -
      • fix typo in configure script option - --disable-narrowproto - (report by David Martínez Moreno). - -
      • amend CF_X_FREETYPE changes for pkg-config check to - ensure that Xft is known to that tool (report and - patch by Emanuele Giaquinta). - -
      • add an ifdef to allow ./configure --disable-active-icon - to work, broken by new code for testing memory leaks in - patch #208 (report by Brian Lindholm). -
      - -

      Patch #208 - 2006/1/3 - XFree86 4.5.99.19

      -
        -
      • add charClass resource to XTerm.ad and - UXTerm.ad which simplifies selecting URLs (prompted - by Kirill Ponomarew). - -
      • modify install rule for uxterm to account for the - --program-prefix, etc., options by invoking the - transformed name of xterm rather than simply "xterm". - -
      • modify configure --with-app-defaults option to allow - --without-app-defaults. - -
      • add configure --with-symlink option to make it simpler - to install successive versions of xterm renamed using - the --program-prefix, etc., options with a symbolic - link pointing to the most recent. - -
      • make -iconic option work with toolbar configuration - (GenToo #113604). - -
      • suppress lastlog feature for 64-bit Solaris - configuration since that platform provides only a 32-bit interface - (report by Peter Bray). - -
      • fix memory reallocation for the "UTF-8" menu entry when xterm is - started using the +u8 option (reported by Jan Willem - Stumpel). - -
      • add a configure check for the actual path of luit, - to work around broken imake configurations. - -
      • add a configure check for pkg-config (Redhat Bugzilla - #173541). - -
      • modify install-rule for uxterm to omit executable - suffix, e.g., for Cygwin. - -
      • modify sinstall.sh to work around quirks in Cygwin - configuration. -
      - -

      Patch #207 - 2005/11/13 - XFree86 4.5.99.16

      -
        -
      • enable lastlogx support for NetBSD (was added, but - not enabled in patch #186). - -
      • work around broken lastlog.h in glibc 2.3.5, which - includes utmp.h. - -
      • revert part of recent XFree86 Imakefile change, restoring the - -I. needed for xmkmf builds of xterm - (XFree86 Bugzilla #1633, - reports by Alexander Pohoyda, - Matthieu Herrb). - -
      • change compiled-in default for printerCommand - resource to an empty string. People who want to use the - printer should be able to read the manual (Debian #311490). - -
      • modify Imakefile to work around old problems in - imake configuration to allow test-builds using - xmkmf on Linux. (This was not noticed since several - releases had broken definitions relating to Xft which were harder - to work around). - -
      • link resize for SCO platforms (Kean Johnston). -
      - -

      Patch #206 - 2005/11/3 - XFree86 4.5.99.15

      -
        -
      • add configure --with-app-defaults option to allow - app-defaults directory for install-rules to be customized. - -
      • remove default translations for dabbrev-expand() - due to conflicts with existing keyboard arrangements. - -
      • remove redundant check for _NET_WM_PID - (report by Emanuele Giaquinta). - -
      • set icon border width explicitly to work around fvwm problem - with active icon resizing (report by Steve Morris, analysis - by Dominik Vogt). - -
      • 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 (Debian #319179). - -
      • add --enable-narrowproto configure option to - accommodate X.org "modular" build (report by Stephan Hermann, - GenToo #17220). - -
      • fix typo in xterm.man description of +wf (patch - by Tobias Stoeckmann). - -
      • add scrollBarBorder resource (request by Floyd L - Davidson). - -
      • modify xterm-new terminfo entry to use capabilities - for shifted scroll forward/reverse as shifted cursor up/down. - -
      • correct updating of checkmark for toolbar entry in popup menu - (report by Emanuele Giaquinta). - -
      • fix ifdef's to allow compiling with toolbar and without tek4014 - (patch by Emanuele Giaquinta). - -
      • use openpty() for Darwin port (patch by Emanuele - Giaquinta). - -
      • fix GenToo #90697 a different way, postponing the logic in - SetupToolbar until the toolbar is actually needed, - i.e., the +tb option is handled as expected. - -
      • revert fix made in patch #203 for GenToo - #90697. That introduced a problem with the control mouse - click-popups, while most of the performance problems can be - resolved by restricting the menu fonts (report by Emanuele - Giaquinta). - -
      • fix a file-descriptor leak when calling openpty() - (OpenBSD system/4561). - -
      • make a special case of resizing work like vt100: a hard reset - also resets the 132/80 mode. The code to support this was - present since X11R5, but not used because the corresponding - initial state of the -132 option was not saved. - -
      • restore window manager hints after XtMakeResizeRequest() - calls. One instance from patch #205 - resulted in the window manager displaying pixels rather than - than characters after selecting a different font size (FreeBSD - ports/87424). - -
      • remove special case for Darwin in CF_XOPEN_SOURCE - (Emanuele Giaquinta). - -
      • modify parsing of control sequence CSI T - to allow scroll-down - to be sent while mouse tracking is enabled (request by - D Hugh Redelmeier). - -
      • correct termcap "me" (mode-end) string so it does not modify the - alternate character set (report by Andrey Chernov). - -
      • correct size-comparison in HandleInterpret() broken in changes - from patch #201 to allocate input - buffer (Debian #334317). - -
      • amend adjustments for scrollbar layout from - patch #204 to make - this apply only to the toolbar configuration. In the non-toolbar - configuration, the resulting scrollbar was shifted by its - borderwidth (report by Matthieu Herrb). - -
      • add select-cursor-extend() action. - -
      • fix some broken href's in xterm.log.html, and typo in the - INSTALL file (report/patch by David Martínez Moreno). - -
      • modify Imakefile to use setgid mode for installing - with Linux, OpenBSD and FreeBSD. - -
      • add configure --with-setuid and --with-reference options to - allow packagers more flexibility in customizing install - permissions. - -
      • generalize and make optional (configure --with-utmp-setgid) - the change made for XFree86 Bugzilla #878 in - patch #205 - (FreeBSD bug report #ports/86663). -
      - -

      Patch #205 - 2005/9/18 - XFree86 4.5.99.12

      -
        -
      • correct a typo in CF_FUNC_TGETENT introduced in patch #198 fix for Gentoo #69926. - -
      • 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 (patch by Bradd W. Szonye). - -
      • add configure option --enable-readline-mouse, which turns on the - experimental OPT_READLINE code (patch by Ilya Zakharevich). - -
      • for FreeBSD, drop setuid privileges after startup - (XFree86 Bugzilla #878, report/patch by Alexander Pohoyda) - -
      • add menu entry (alt-esc) and corresponding action (alt-sends-esc) - to toggle the eightBitInput resource setting. - -
      • generate configure script with autoconf 2.52 (patched) to use - the feature therein which forces the script's locale to POSIX - (Gentoo Bugzilla #105369). - -
      • 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 (Debian #289123, Novell #61153). - -
      • modifications to work with z/OS 1.4 (Paul Giordano). - -
      • improve error-reporting when chown/chmod of the pseudo-terminal - fails, e.g., if a copy of xterm which was designed to work with - old-style pseudo-terminals is not installed setuid or setgid - (report by Jeremy C. Reed). - -
      • patches from Emanuele Giaquinta: -
          -
        • ctlseqs.ms says that primary and secondary DA accept a - nonzero parameter, which is incorrect. Also modify code - to agree with this. - -
        • correct a comment in 88colres.pl - -
        • ctlseqs.ms says that the DEC Set/Reset control sequences for - the backarrow key make it send DEL/BS, respectively, while it's - the opposite. - -
        • update the menu entries for the metaSendsEscape, deleteIsDEL - and numLock resources when changing them with the corresponding - DEC Set/Reset control sequences. -
        - -
      • fixes for configure script: -
          -
        • add special case for QNX, defining _QNX_SOURCE. -
        • check for preprocessors which do not perform -U and -D options - in the given order. -
        • improve macro to determine gcc version -
        • improve check for Intel compiler and related warning options -
        - -
      • update config.guess, config.sub - -
      • improve fix from patch #198 for - Cleanup() by ensuring it is not called from the - SIGCHLD handler (patch by Todd Miller (OpenBSD CVS)). - -
      • eliminate a retry for a better-matching bold font, to work around - recent font server changes. - -
      • fixes for Novell #113277: -
          -
        • specify weight for wide font which may be derived from - normal fontname. -
        • cache the derived wide- and widebolt-fontnames. -
        - -
      • workaround for GenToo Bugzilla #100728. - -
      • add menubar's border width to layout computation. Normally this - is zero, but patterns such as XTerm*borderWidth:1 - would give poor layout for the toolbar configuration. -
      - -

      Patch #204 - 2005/8/4 - XFree86 4.5.99.9

      -
        -
      • 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 (Debian #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: ensure that the scrollbar - border is zero if the vt100 border is zero. - -
      • 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, loads 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 - (Debian #318162, patch by Eugene Konev). - -
      • add checks to ensure vt100 widget is realized when it might be - updated via actions handled from a tek4014-only configuration. -
      - -

      Patch #203 - 2005/7/6 - XFree86 4.5.99.7

      -
        -
      • modify initialization of allowSendEvents and - allowWindowOps to prevent modification with the - editres protocol. - -
      • fix compiler warning for NetBSD by including util.h in main.c - (XFree86 Bugzilla #1596). - -
      • fix to build on Darwin 8.x, which no longer provides - setpgrp() (patch by Min Sik Kim). - -
      • adapted fixes for Legend (SCO) from diffs attached to - Freedesktop.Org Bugzilla #3180. - -
      • fix typo in xterm manpage description of -ls option - (Freedesktop.Org Bugzilla #3543). - -
      • add support for interpreting the underline attribute as an italic - font in Xft mode (patch by Chuck Blake). - -
      • improve initialization of toolbar so that individual pulldown - menus are initialized on demand, as they are in the scenario - where they are invoked as popup menus (GenToo Bugzilla #90697). - -
      • fix logic in find_utmp, which did not reset result - in getutid(), causing an infinite loop in some - conditions (report by Emil Mikulic). - -
      • set the _NET_WM_PID property (GenToo Bugzilla #91008). - -
      • modify ifdef's in ptyx.h and xterm_io.h to build with DragonFly - (patch by Jeroen Ruigrok). - -
      • 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 (patch by Joe Allen). - -
      • add experimental option to allow - applications to get or set the selection data as a BASE64 string - (adapted from patch by Joe Allen). - -
      • fix an off-by-one error parsing -S/nn option - (Debian #311438, report/fix by Peter Chubb). - -
      • fix an initialization bug from - patch #201 that broke logging - (report by Rodney Thayer). - -
      • amend change to command-line processing in - patch #201 to avoid - conflict with -e option (report by Servatius Brandt). - -
      • suppress configure check for _XOPEN_SOURCE on - darwin. - -
      • update config.guess, config.sub -
      - -

      Patch #202 - 2005/5/2 - XFree86 4.5.99.3

      -
        -
      • add extended shift- and control-modifier cursor keys to - "xterm+pcfkeys" terminfo entry to correspond to ncurses 20050430 - patch. - -
      • fix a rare case where text would be written with the wrong colors - because output of scrolled text would reset the colors and the - new text would be written with the same colors (report/testcase - by Thomas Glanzmann). - -
      • rename $CMD variable in plink.sh because - it is a reserved symbol in bash 3.00.16 (report by Ted Taylor). - -
      • add environment variables $XTERM_SHELL and - $XTERM_VERSION - (request by Zdenek Sekera). - -
      • corrected workaround for background color of menubar, which gave - a too-broad expression, coloring the background of the VT100 - widget unless overridden by another resource setting. - -
      • correct an error in the logic which decides when - sched_yield() is run; it would occasionally hang when - contending with other pseudo-terminal applications such as screen - (report by Kirill Ponomarew). - -
      • modify initialization to decide whether to default to built-in - wcwidth() versus system's version based on the - starting locale and whether the system's version is poor quality - (suggested by Bram Moolenaar). - -
      • update table for mk_width() from UnicodeData 4.1.0 - using Markus Kuhn's uniset script. -
      - -

      Patch #201 - 2005/4/21 - XFree86 4.5.99.2

      -
        -
      • improve resource files to show how the menubar and popup menus can - be colored (prompted by report by Joe Wells). - -
      • modify parsing of OSC (and SOS, etc), strings so their contents - are not interpreted as UTF-8. This allows non-ASCII title strings - to be set, provided that the window manager complies (report by - Thomas Wolff). - -
      • improved some of the built-in line-drawing glyphs. - -
      • correct color of "box" character drawn for line-drawing glyph 1 - (report by Nicolas George). - -
      • improve behavior when switching to UTF-8 mode after startup so - xterm will check if the current fonts are already wide - (ISO10646-1). If they are not, xterm will use the - utf8Fonts subresource to load appropriate fonts - (request by Bram Moolenaar). - -
      • modify logic for setting title-string so it applies to the current - widget rather than the vt100 widget. - -
      • modify initialization for wide-bold fontname, to search for one - if none is given (report by Michael Schroeder). - -
      • add resource mkWidth and command-line option - -mk_width to control whether xterm uses the built-in - version of wcwidth(). - -
      • add resource settings for minimum/maximum input buffer size, and - call to sched_yield to improve performance with newer - Linux kernels (adapted from patch by Nicolas George). - -
      • correct computation of width for wide characters with the invisible - attribute (report by Thomas Wolff). - -
      • modify interaction between +u8 and locale - resource to allow the command-line option to override the resource - (requested by Thomas Wolff). - -
      • add a limit check for scrolling margins in a one-line screen, - overlooked in fixes for - patch #198 (Debian #297430). - -
      • correct treatment of iconBorderWidth for resizing - an active-icon, and its description in manpage (Debian #296592). - -
      • modify configure script --disable-imake to use the - script's definitions anyway if it cannot detect imake (prompted - by FreeBSD bug 77408). - -
      • ignore error in the I/O initialization that tries to set the - tty to 7-bit input for the case where eightBitInput - resource is false (Debian #298551). - -
      • modify command-processing to accept an optional parameter that - tells xterm which shell program to use (request by Zdenek Sekera). - -
      • add simpler resource keyboardType which, when set, - overrides the individual keyboard-type resources and eliminates - the possibility of conflict between them. - -
      • add initialization for scoFunctionKeys resource - (report by Rick K). - -
      • correct logic of ReallocateBufOffsets() which did not - copy the content of the old screen buffer to the proper location, - making a repaint clear after switching to wide-character mode - (report by Bram Moolenaar): - -
      • implement the remaining pieces to make xterm allocate cells for - wide-characters when the "UTF-8" menu entry is selected. Also, - load the UTF-8 font when that menu entry is selected, or the escape - sequence for UTF-8 mode is received (report by Bram Moolenaar): - -
      • add command-line options (-tb, +tb) and - resource toolBar to allow menu/toolbar to disabled or - enabled at startup (prompted by reports by Joe Wells). - -
      • correct typo in configure script's --enable-dec-locator option - (report by Bram Moolenaar). -
      - -

      Patch #200 - 2005/2/6 - XFree86 4.4.99.23

      -
        -
      • increase color pairs value for xterm-256color and xterm-88color to - match ncurses, which has an experimental option to support this. - -
      • modify ifdef's to make AIX use termios rather than termio; the - struct sizes for the two were not the same. - -
      • improve CF_WITH_IMAKE_CFLAGS configure macro script for - OSMAJORVERSION and OSMINORVERSION values, e.g., for Tru64 and AIX. - -
      • modify ifdef to define USE_POSIX_TERMIOS for Darwin (patch by Min - Sik Kim). - -
      • modify find_utmp() to initialize the whole utmpx struct (except - ut_id), since that is needed for OSF1 4.0D to prevent an infinite - loop on exit. - -
      • add configure check before adding -D_POSIX_SOURCE since some - platforms predefine it, e.g., cygwin. - -
      • add simplified sed expressions in CF_IMAKE_CFLAGS configure script - macro to ensure value for PROJECTROOT is quoted on Solaris, i.e., - when nested \( and \) are not interpreted - correctly. - -
      • correct DEC rectangle operations to reset state after completing - the operations. - -
      • modify CASE_ST handling in charproc.c to ensure that the parse - state is reset even if xterm is not currently processing an OSC or - other string (patch by Johnny Billquist forwarded by Matthias - Scheler, NetBSD xsrc/29003). - -
      • fix OS/2 build for innotek_libc (patch by David Yeo). - -
      • fix a regression from patch #197 fix for - Debian #277832 which disowned the selection if it was scrolled, - e.g., by the user pressing return at the bottom of the screen - (Debian #291787). - -
      • move the warning/exit for missing $DISPLAY into the error handler - in case -display is given, and the connect fails for - some other reason. -
      - -

      Patch #199 - 2005/1/17 - XFree86 4.4.99.22

      -
        -
      • instead of setting $DISPLAY, check for the unset - variable and warn/exit on this condition (comments by H Merijn - Brand and Bernhard R Link). - -
      • fix a typo in Imakefile from patch #198 - (reports/patches by Stefan Dirsch, Mike Castle). -
      - -

      Patch #198 - 2005/1/13 - XFree86 4.4.99.21

      -
        -
      • set $DISPLAY to ":0" if it is not set. - -
      • add utmpDisplayId resource to allow users to control - whether the display identifier (display number and screen number) - are retained in the connection information recorded in utmp - (discussion with Edoardo Tirtarahardja). - -
      • add bellOnReset resource to allow users to disable - bell which sounds on hard reset since patch - #183 changes to DECSCL (discussion with Danek Duvall). - -
      • improve $WINDOWID for configuration with toolbar by - making it refer to the top-level shell rather than the parent of - the current window. For that case, the parent is a form widget, - which does not have a name, which made the $WINDOWID - not very useful as a parameter for xwininfo - (suggested by Dave Bodenstab). - -
      • fix a typo in WhichVFont() macro - from patch #197 changes - which broke the --disable-active-icon configuration - (report by Ralf S. Engelschall). - -
      • improve some limit checks (Gentoo Bugzilla #75604). - -
      • add --disable-setuid option to configure script (Gentoo Bugzilla - #76543). - -
      • add --disable-full-tgetent option to configure script, allowing one - to ignore a termcap library in favor of ncurses/curses (Gentoo - Bugzilla #69926). - -
      • modify configure script to choose useful warning options for Intel - version 8.0 compiler. - -
      • update config.guess, config.sub - -
      • make active-icon work properly when TrueType fonts are used - (Debian #286068). - -
      • correct change from patch #157 which uses - getlogin() to check for an alias; the storage used for the related - getpwuid() call was overwritten by the data used for comparison - (patch by Per Hedeland). - -
      • correct case of SCS for character set 0 (line-drawing) to allow it - to be selected into GR. - -
      • fix a file-descriptor leak (Redhat Bugzilla #139597). - -
      • modify creat_as() to only fork if xterm is actually - running as setuid and/or setgid. This works around a Cygwin bug - which hangs when logging is enabled and makes xterm a little - faster for systems using interfaces such as utempter (report by - Al Goodman). - -
      • modify Cleanup() to avoid operations such as X calls - that might use unsafe functions when it is called by a signal - handler (report by Michiel Boland). - -
      • fix bugs in patch #191 and in SRM changes - from patch #197 that - broke DECSET 38: switch to Tek4014 emulation (report by Dave - Bodenstab). - -
      • fix for manpage escapes (Marc La France). - -
      • improve on IRIX-specific change for Imakefile in XFree86 CVS versus - resize linking against termcap library to reflect definitions for - USE_TERMCAP in resize.c -
      - -

      Patch #197 - 2004/11/30 - XFree86 4.4.99.19

      -
        -
      • modify configure script to remove empty "-DPROJECTROOT=" definition - which resulted unusable values for luit's default path. - -
      • update precompose.c based on Unicode 4.0.1 - -
      • several minor fixes based on Intel compiler warnings. - -
      • change default translations so a BtnDown which is - not recognized is simply ignored rather than emitting a bell. - That makes it less obtrusive when the user tries to use a mouse - which provides more capabilities than the X mouse driver supports, - e.g., one with a horizontal scroll wheel (Debian #265133). - -
      • note in xterm's manpage that translations is not - specific to xterm (Debian #278897). - -
      • modify uxterm script to use locale program to verify if the - derived locale is installed (Debian #246398). - -
      • correct font handling for active icon when in UTF-8 mode (report - by Paolo Liberatore). - -
      • make active-icon and toolbar configurations work together. - -
      • modify the criteria for disowning primary selection. Previously, - this happened anytime the cursor was moved before the end of the - selection. That would ensure that any insert/delete of char or - line, as well as scrolling, would disown the selection. The - new criteria change this to checking if the operations would - modify the data which is highlighted (Debian #277832). - -
      • reimplement DECALN with functions for vt420 rectangles, - fixes selection for this case. - -
      • implement vt420 rectangle operations. - -
      • add parsing, for debug/test of vt220 soft-fonts. - -
      • add menu entry, actions and escape sequence to allow - enabling/disabling toolbars at runtime. - -
      • improve rendering for Xft, allow it to draw non-linedrawing - characters such as "pi", which were drawn from internal tables - with patch #180 - (Freedesktop.org Bugzilla #1260). - -
      • add configure option --enable-mini-luit, ifdef'd the - mini-luit feature with OPT_MINI_LUIT. - -
      • add mini-luit feature, which supports Latin9 directly rather than - via luit, provided that Unicode fonts are used (Freedesktop.org - Bugzilla #1571, request by Stefan Dirsch, patch by Michael - Schroeder). - -
      • for Linux, if IUTF8 is defined, e.g., on recent 2.6.x kernels, - set the corresponding flag for the slave pty, to enable UTF-8 - interpretation of backspace in cooked mode (Freedesktop.org - Bugzilla #1578, request by Stefan Dirsch). - -
      • modify faceSize resource to use a floating-point - internal value (adapted from patch by Sam Stephenson). - -
      • correct handling selection of tabs over cleared space in UTF-8 - mode. In this special case, xterm represents the whitespace with - a null rather than a space character (Debian #276447). - -
      • amend fix for infinite loop from patch - #192 to check if there is wrapped text to output in a following - iteration (Debian #273202). - -
      • fixes ifdef'd with __INTERIX to allow building with - Interix (Windows Services for UNIX) 3.5 using the xlibs libraries - from freedesktop.org (patch by Min Sik Kim). - -
      • amend solution for Debian #252873, #260471 from patch #194 by making the cursor not - explicitly colored if only the foreground color is set, and the - cursor is on a blank space (Debian #275473). - -
      • correct logic for send/receive mode (SRM) with regard to control - characters. - -
      • fix masking of invisible text in wide-character mode, which did - not work for line-drawing characters. - -
      • incorporate CF_XOPEN_SOURCE into configure script, replacing - CF_GNU_SOURCE. -
      - -

      Patch #196 - 2004/8/15 - XFree86 4.4.99.12

      -
        -
      • add a special case to configure script to ignore NetBSD's - grantpt() which was recently added (but not part of a - release), until someone is able to ensure that xterm can use it - (report by Min Sik Kim). - -
      • clear the buffer returned by getutid(). This fixes an infinite - loop on some platforms introduced in patch - #193 by Debian #256468 fix (report by David Ellement). -
      - -

      Patch #195 - 2004/8/8 - XFree86 4.4.99.11

      -
        -
      • correct length used for blinking text, make the last column blink - (patch by Alexander V Lukyanov). - -
      • start changes to make doublesize characters work with TrueType - fonts (see patch #44). - -
      • trim leading/trailing blanks from color resources as done for - other strings in patch #167. - -
      • fixes for showBlinkAsBold resource (report by - Christoph Berg). -
      - -

      Patch #194 - 2004/7/27 - XFree86 4.4.99.11

      -
        -
      • change clearing operations so foreground color attribute is not - set. Usually this is benign, but in some cases when the cursor - color is not set explicitly, the cursor would show this color - (Debian #252873, #260471). - -
      • add extra state (cursor-moved) to guard against deciding that the - cursor did not require repainting after an indexing operation - that leaves the cursor in the same location on the screen. - -
      • fix a case where a full-screen indexing operation would - not restore the cursor-busy state. - -
      • fix a repainting bug introduced in - patch #180: when using a font - lacking line-drawing characters, a repaint of the screen could - skip horizontally an extra amount after filling in the missing - character (reports by Nicolas George, Hans de Goede, Redhat - Bugzilla #128341). - -
      • rename terminfo fragment "xterm-pc-fkeys" to "xterm+pcfkeys" for - consistency with ncurses. -
      - -

      Patch #193 - 2004/7/19 - XFree86 4.4.99.10

      -
        -
      • fix for wide-character selection from OpenBSD CVS - (report/patch by Matthieu Herrb). - -
      • modify initialization and cleanup of utmp data to also compare - the ut_line member (Debian #256468). - -
      • modify check on focus-change to ignore FocusOut events - generated by XGrabKeyboard. This fixes a case where - the text cursor would act as if focus were lost when selecting the - "Secure Keyboard" menu option. - -
      • add gen-pc-fkeys.pl script, use that to generate - terminfo fragment corresponding to the pc-style function keys. - -
      • fix a case where the checkmark by the "VT220 Keyboard" menu entry - was not set on startup. - -
      • separated two methods for making the cursor blink (menu and - escape sequence) by using the menu as the primary method and - XOR'ing the state of the escape sequence against that. - -
      • modify logic for enabling blinking cursor via escape sequence as - well as the related save/restore operations so this is only - available if the cursorBlink resource was set on - startup. -
      - -

      Patch #192 - 2004/7/12 - XFree86 4.4.99.9

      -
        -
      • change resource settings for color4 and color12, add some discussion - in XTerm-col.ad (Debian #241717). - -
      • add a note in xterm manpage discussing the difference between - alt- and meta-keys, and the way the latter is used in the - eightBitInput resource. - -
      • add a note in xterm manpage regarding possible conflict between - resource settings for xterm.vt100.font and - xterm.vt100.utf8Fonts.font (Debian #254650). - -
      • add compile-time customization of backarrowKeyIsErase - and ptyInitialErase default resource values - (adapted from OpenBSD CVS). - -
      • change parameter of FIONREAD ioctl() call - from long to int - (discussion on tech-x11@netbsd.org regarding LP64 by - John Heasley and Matthias Scheler). - -
      • modify configure script options for Athena widgets to work as - expected for "--without-Xaw3d", etc., (GenToo Bugzilla #53455). - -
      • add case to uxterm to accommodate locales ending with "@euro", - e.g., fr_FR.UTF-8@euro (Debian #255197, report/analysis by - Matthieu Lagouge). - -
      • add special case for VT100 graphic's "box" character (discussion - with Ben Armstrong). - -
      • add missing initialization for bitmap-font sizes needed to make - fonts menu work with TrueType fonts (report by Ben Armstrong). - -
      • save the fontnames for bold fonts that are derived from normal - fonts, or from the boldFont resource, so the same - value is restored when switching with the VT Fonts menu (Debian - #256086). - -
      • fix manpage preprocessing (Marc La France). - -
      • fix typo in manpage's description of character classes (Debian - #257073). - -
      • modify terminfo to accommodate luit, which relies on G1 being used - via an ISO-2022 escape sequence (Debian #254316, analysis by - Juliusz Chroboczek). - -
      • modify Makefile.in rule for ctlseqs.txt to work around groff SGR - misfeature. - -
      • modify XTerm.ad to set saveLines default - to 1024 (Redhat Bugzilla #127132). - -
      • add a limit-check in dotext() to prevent infinite - loop in a corner case of UTF-8 configuration. - -
      • update config.guess, config.sub -
      - -

      Patch #191 - 2004/6/6 - XFree86 4.4.99.7

      -
        -
      • correct options parsing for -into option so it - can be combined with -e (Redhat Bugzilla #124518, - report/patch by James Armstrong). - -
      • fix ifdef's for OPT_COLOR_RES2 - so that the fake resource table introduced in - patch #188 - is not compiled if it is empty. - This happened to work with gcc (report by Joel Konkle-Parker). - -
      • reorganize ptydata.c to use one input buffer shared between - the VTxxx and tek4014 emulators. In the new scheme, UTF-8 - decoding is performed on characters as they are needed by the - state machine rather than on buffers as they are read. - -
      • work around change in quoting of PROJECTROOT symbol when using - configure script, from changes made in - patch #187 for CF_IMAKE_CFLAGS - (GenToo Bugzilla #50982). -
      - -

      Patch #190 - 2004/5/25 - XFree86 4.4.99.6

      -
        -
      • correct state for values in the range 128-159 after translating - from UTF-8: this should be ignored unless the user overrides it - with the allowC1Printable resource (reported by - Simon Strandgaard). - -
      • add configure-script check for nl_langinfo(CODESET), use this to - replace check of environment variables for UTF-8. - -
      • change Makefile.in rules for 256colres.h and 88colres.h so they - are only made if they do not exist. The maintainer-clean rule - will remove these files; they require perl to be made. - -
      • remove check in configure script --enable-toolbar that suppressed - this option when building with Xaw7. - -
      • apply fixes to Tektronix widget used for VT100 widget to make - toolbar work with Xaw7 (XFree86 4.x). -
      - -

      Patch #189 - 2004/5/16 - XFree86 4.4.99.6

      -
        -
      • do not call xim_real_init() if openIm resource is - false (Debian #249025). - -
      • minor improvements to built-in line-drawing. - -
      • fix a few portability issues with dynamic abbreviation support, - i.e., did not compile on Tru64. - -
      • modify constraints in form used to layout toolbar, to work with - newer Xaw in XFree86 4.x. -
      - -

      Patch #188 - 2004/5/12 - XFree86 4.4.99.6

      -
        -
      • correct table entry for DEL in the ground state, which marked it - as a printable character from patch #171 - (report by D Hugh Redelmeier). - -
      • improve fix in patch #186 for failure in - xim_real_init() by adding a sleep. - -
      • fix a typo in os2main.c - (XFree86 Bugzilla #1358, report/patch by Frank Giessler). - -
      • make escape sequence reporting dynamic colors consistent with the - logic that sets it; choosing the opposite color when reverse - video is set (XFree86 Bugzilla #1361, reported by Bradd W Szonye). - -
      • modify initialization of 256- and 88-colors so that colors beyond - 16 are normally not X resources. This works around a hard-coded - limit in Xt which breaks xterm when 256-colors and luit are both - configured (report by Noah Friedman). - -
      • remove ncv from xterm-256color terminfo - entry since it is no longer needed (report by Eli Zaretskii). - -
      • add "erase2" and "eol2" keywords to ttyModes resource, - for recent/current FreeBSD. - -
      • improve ifdef's for utempter library to omit direct calls to - setutent() or getutent() (adapted from - patch by Christian Biere). - -
      • add dynamic abbreviation support like Emacs (patch by Tomasz - Cholewo). This is ifdef'd with OPT_DABBREV, and - enabled via the configure script --enable-dabbrev - option. - -
      • fix problem responding to session management events, e.g., which - would make logging out very slow (patch by Eddy De Greef, Debian - #233883). - -
      • work around a newer bug in toolbar with XFree86 by forcing menus - to be fully initialized at startup. In older versions of XFree86 - and X11R6, it was possible to delay initialization of the menu - contents until it was popped up. (The longstanding bug with - XFree86 4.x layout for toolbar still exists, though). - -
      • modify xtermAddInput to work around core dump on - IRIX64 when initializing scrollbar translations if toolbar is - compiled-in. - -
      • fix some minor conflicts in the 2-character entry names in the - termcap file. -
      - -

      Patch #187 - 2004/4/27 - XFree86 4.4.99.4

      -
        -
      • change xterm version string to use __vendorversion__ - where that is available, and "XTerm" otherwise. - -
      • improve description of utf8 resource in manpage - (Debian #179407). - -
      • modify configure macros CF_IMAKE_CFLAGS and CF_ADD_CFLAGS to - handle -D options that define string values, e.g., - for XVENDORNAME. - -
      • modify configure macro CF_IMAKE_CFLAGS to allow (if - $PATH is set accordingly) to use the - xmkmf script within an X build tree. - -
      • add missing #undef OPT_SESSION_MGT to xtermcfg.hin - to make the configure script's --disable-session-mgt option work. - -
      • update config.guess, config.sub -
      - -

      Patch #186 - 2004/4/18 - XFree86 4.4.99.4

      -
        -
      • change reset on DECSCL to a soft-reset (appears some - DEC manuals have errors). - -
      • add a section to ctlseqs.ms elaborating on normal/alternate screens. - -
      • modify initialization of Acolors[] so that any XtDefaultForeground - or XtDefaultBackground values are translated as in the Tcolors[], - to use the window's foreground/background colors. This affects - the colorBD and similar resources which normally have - no explicit color assigned. - -
      • modify initialization of Tektronix window so that control sequences - setting its color before the window is popped up will apply to - its initial colors. - -
      • add control sequence to set Tektronix window's text-cursor. - -
      • modify initialization of terminal colors, e.g., mouse pointer and - text cursor, to treat XtDefaultForeground and - XtDefaultBackground values as the actual foreground - and background colors of the terminal rather than white and black - (Debian #241717). - -
      • remove an incorrect comparison against PTYCHARLEN in - parsing the -S option (report by Michael B Taylor). - -
      • minor restructuring of terminfo/termcap files, having noted some - packager's customizations which caused the structure to be - confused. - -
      • eliminate an isolated use of MIN/MAX in charproc.c - -
      • replace XtExtdefaultfont and - XtExtdefaultbackground by their more familiar - equivalents - XtDefaultFont and - XtDefaultBackground. - -
      • replace ifdef's using SCO, sco and - SCO325 with __SCO__ - (XFree86 Bugzilla #1301, Kean Johnston). - But ensure that it still builds on platforms where this symbol - is not defined. - -
      • add scoFunctionKeys resource, to match manpage. - -
      • update manpage discussion of menus and related resources. - -
      • enable utmpx support for NetBSD 1.6C and newer (patch by - Matthias Scheler). - -
      • add a note in the manpage discussing xterm's treatment of open - file-descriptors (request by Dan Shearer). - -
      • modify Help() to make "xterm -h" write to standard - output rather than standard error (patch by Bram Moolenaar). - -
      • check for type of failure in xim_real_init() to avoid looping when - the problem is an unsupported input method rather than a failure - to connect to the XIM server. Problem was introduced in - patch #175 (XFree86 Bugzilla #1306). - -
      • modify Imakefile to remove dependency of "install" - target on the xterm executable to make installs from - tree without attempting to rebuild anything (commit by David Dawes, - report/patch from Lee Olsen). - -
      • remove call to ShowCursor from - SetCursorBlink() since that is redundant, - and can cause display glitches if the cursor is already - blinking (XFree86 Bugzilla #1158, patch/report by Andreas Schwab). -
      - -

      Patch #185 - 2004/3/3 - XFree86 4.4

      -
        -
      • fix tcap-query logic for the backspace key (XFree86 Bugzilla #1233, - report/patch by Anton Kovalenko). - -
      • add test-scripts resize.pl and tcapquery.pl - -
      • add translation to ASCII of commonly-used characters that groff - translates to Unicode, when the font in use does not provide the - corresponding glyphs (Debian #219551). - -
      • modify RequestMaximize(), which performs maximize/restore via - control sequences, to account for window-frame (patch by - Jess Thrysoee). - -
      • improve pattern used in uxterm to check for UTF-8 - locale, e.g., for HPUX (patch by H Merijn Brand). - -
      • add -fd option and resource - faceNameDoublesize to specify double-wide fonts with - Xft (adapted from patch by Zarick Lau). - -
      • change a couple of resource classes from "Boolean" to specific - values: freeBoldBox, forceBoxChars. - -
      • add resource showMissingGlyphs to outline places on - the screen where a font lacks the corresponding glyph. - -
      • add resource showBlinkAsBold to control whether - blinking text should be shown as bold or actual blinking text. - -
      • improve logic in ShowCursor() to avoid repainting the cursor when - it is already visible, e.g., in response to the DECTCEM escape - sequence. This also addresses XFree86 Bugzilla #1158. - -
      • implement blinking text, using the timer for blinking cursor. - -
      • modify FreeType support to allow resizing the font, in the same - ways the window can be resized if fixed fonts are used. The - relative font sizes are derived from the fixed font sizes. - -
      • add menu items and corresponding actions for switching on/off - the UTF-8 mode and Xft (TrueType) support. - -
      • add logic to handle switching UTF-8 mode on/off. It worked if - the escape sequences were flushed, but if data was mixed in with - the same write, some were not handled properly (report by - Nicolas George). - -
      • modify to allow turning UTF-8 mode on/off via escape sequence even - if -wc option was not given at startup (patch by Peter - Berg Larsen). - -
      • amend fix for XFree86 Bugzilla #981, adjusting for savedlines value - (report by Tim Adye). - -
      • fix a typo in computing relative font size (Jess Thrysoee). -
      - -

      Patch #184 - 2003/12/31 - XFree86 4.3.99.903

      -
        -
      • improve configure-script checks for FreeType and related libraries, - using xft-config or freetype-config - scripts when available. - -
      • fix configure-script check for SYSV definition by - ensuring whether sys_errlist[] is declared, and by - modifying the test program to include X11/Intrinsic.h - to check that wchar_t is declared consistently (report - by H Merijn Brand). -
      - -

      Patch #183 - 2003/12/26 - XFree86 4.3.99.903

      -
        -
      • correct logic for configurations that may attempt to open both - old/new-style pseudoterminals. In this case, the old-style are - preferred. Logic was broken in patch #145 - (XFree86 Bugzilla #997, report/patch by Kean Johnston). - -
      • modify handling of eightBitInput resource in UTF-8 - mode to translate the value into UTF-8. Otherwise an illegal - UTF-8 code is sent to the application (report by Bram Moolenaar). - -
      • modify uxterm script to interpret help and version - options so xterm does not always create a window when the user - requests this information (Debian #223926). - -
      • add a limit check to ScrnTstWrapped() (XFree86 Bugzilla #981). - -
      • modify DECSCL to perform a hard reset (RIS) as per DEC manuals. - Extended DECSCL to accept parameters for vt4XX and vt5xx terminals. - -
      • correct logic for ANSI conformance level escape sequences, which - were confused with DEC conformance level escape sequences. - -
      • correct state for vt52 shift-in/shift-out, which was not reset - properly after patch #171. - -
      • correct handling of graphics characters for vt52 mode, which did - not display line-drawing characters after G1 fix from - patch #182. - -
      • fixes for configure script to work with current Cygwin headers - and libraries. - -
      • modify Imakefile to put the current directory at the - beginning of the include searchpath (patch by David Dawes). -
      - -

      Patch #182 - 2003/12/2 - XFree86 4.3.99.901

      -
        -
      • correct logic for metaSendsEscape resource to allow - for the meta-right key to be tested. Improve check for meta/alt - modifiers by dropping the assumption that a keysym is associated - with only one modifier, and by ignoring NoSymbol entries in the - xmodmap data (XFree86 Bugzilla #924, patch by David Dawes). - -
      • correct wrapping logic for line-drawing characters written in - non-UTF-8 mode of xterm build for wide-characters (XFree86 Bugzilla - #918, report/patch by Jürgen Keil). - -
      • improve manpage description of resources, in particular the - utf8Fonts class (XFree86 Bugzilla #905). - -
      • add definitions to compile with glibc-based GNU/Hurd, GNU/KFreeBSD - and GNU/KNetBSD (XFree86 Bugzilla #893). - -
      • compiler-warning fixes (patch by Christian Biere). - -
      • add README.i18n (Tomohiro Kubota). - -
      • correct initialization of G1 character set mapping, which used - line-drawing set as a result of confusion between "DEC Supplemental - Graphic" and "DEC Special Graphic" character sets - (see patch #34 regarding DECSTR). - -
      • correct ifdef in main.c for variable utret (patch by - Bernhard Rosenkraenzer). - -
      • document in xterm's manpage how to use XFree86 ":unscaled" keyword - to suppress scaling of bold fonts. - -
      • when deriving bold fontname from normal fontname, use the normal - font's average width to avoid for example selecting 7x13bold - from an 8x13 normal font (Debian #107769). -
      - -

      Patch #181 - 2003/10/26 - XFree86 4.3.99.15

      -
        -
      • implement boldMode for wide-character logic in - drawXtermText() (report by Michael Schroeder). - -
      • modify UXTerm.ad resource file to include - "XTerm-color" rather than "XTerm", in case the latter file contains - no color resource definitions, e.g., after patch #180. - -
      • add action load-vt-fonts() and configure option - --enable-load-vt-fonts which allows users to define - additional sets of VT-fonts which can be loaded at runtime. - -
      • add logic to wide-character support which attempts to load fonts - specified by utf8Fonts subresources at startup. The - subresources have the same names as the fonts which they replace, - e.g., font, font1, etc., so that the - ISO-10646-1 fonts can be specified in the XTerm - app-defaults file (adapted from patch by Tomohiro Kubota). - -
      • improve Set Font escape string handling by making the relative - settings apply to the size of the font, as in shift keypad - plus/minus rather than the menu index. - -
      • simplify parameter passing for the set-vt-font action - and related code. - -
      • cleanup some include-ordering, moving some recently-added hardcoded - stuff into xterm.h where it will not interfere with the configure - script. - -
      • modify xtermAddInput() (see note on augmentation in patch #158) to use the complete set of - default keyboard translations so that one can use shifted pageup, - wheel mouse, etc., while the mouse pointer is over the scrollbar. - (Debian #178812). - -
      • make save/restore mode controls apply to show/blink cursor states. - -
      • add escape sequence to start/stop blinking cursor, which allows - implementing cvvis terminfo capability (request by - Nate Bargmann). - -
      • add indp and rin to terminfo entry. - -
      • fix an out-of-bounds array reference in ScrnRefresh() for wide - characters (report by Dan Harnett, patch by Todd Miller). - This bug dates from patch #141. -
      - -

      Patch #180 - 2003/10/12 - XFree86 4.3.99.15

      -
        -
      • several fixes for rendering using Xft via option -fa: -
          -
        • translate Unicode values, i.e,. from UTF-8 output to xterm, for - line-drawing to xterm's internal code, etc., since TrueType fonts - generally do not have either set of line-drawing glyphs. xterm - can draw these directly (report by Abigail Brady). -
        • pass 16-bit values rather than 8-bit values to - xtermXftDrawString() to allow for wide-characters. -
        • remove spurious check for colorBDMode resource in - logic that does bold fonts. -
        • implement underlining. -
        - -
      • patches by Ilya Zakharevich: -
          -
        • improve drawXtermText() by making the recursive calls - communicate through arguments, and not through saving/restoring - global variables. - -
        • make double-width characters work with -u8 option. - -
        • modify lookup of double-sized fonts by checking for a match - ignoring x/y resolution if the first check fails. -
        - -
      • make height of TrueType fonts match ascent+descent (patch by - Keith Packard). - -
      • correct configure-script check for imake $CFLAGS, which did not - check properly if imake was not available. - -
      • correct install rule in Makefile.in for uxterm, which - was attempting to strip the script (newsgroup posting by Fernan - Aguero). - -
      • correct AF/AB strings in termcap for xterm-256color and - xterm-88color entries (report by Josh Howard). - -
      • update wcwidth.c to incorporate changes from Markus Kuhn's - 2003-05-20 (Unicode 4.0) version of that file. - -
      • modify scroll-back and scroll-forw - actions to accept an adjustment value, e.g., -
        -	      scroll-back(1, page-2)
        - to scroll back by 2 lines less than a page (patch by Greg - Klanderman). - -
      • use color resource setting from Debian package for xterm VT100 widget, - since the choice of blues provides better contrast. - -
      • remove color resources from XTerm.ad, leaving them - only in XTerm-col.ad (prompted by Debian package for - xterm). - -
      • correct configure script option --enable-pty-handshake (report by - Paul Gilmartin). - -
      • add visualBellDelay resource to modify the length of - time used for visual bell, for very slow displays or very fast - computers (reports by Ingo van Lil and Doug Toppin). - -
      • correct logic for initializing dynamic highlight color (patch by - Jess Thrysoee). - -
      • add a check for non-zero size in call to XCopyArea() - to accommodate a Solaris bug. - -
      • correct typo in example for character classes in xterm manpage - (Debian #198910). - -
      • link xterm with bind_on_load option on Darwin to work around a - deadlock in the dynamic loader when a signal is received while - the dynamic loader is looking up symbols (patches by Rob Braun, - Torrey Lyons). - -
      • modify configure script to avoid using "head -1". - -
      • update config.guess, config.sub - -
      • modify ifdef's to work around inclusion of types FcChar32 and - XftCharSpec with FreeType 2.0 (see patch #175). - -
      • modify the predictable version of the generated logfile name (see - patch #171) to append the process-id rather - than a random value. - -
      • resync with XFree86 CVS -
          -
        • Enable SCO function keys in xterm -
        • Make Delete key send DEL by default on SCO in xterm -
        -
      - -

      Patch #179 - 2003/5/21 - XFree86 4.3.99.5

      -
        -
      • modify ifdef's for WTMPX_FILE to allow building on cygwin again. - -
      • change the default of pty-handshaking configure option (and related - default for imake) to assume this feature is needed. - -
      • add ifdef's so configure option for XawPlus library works (patch - by Pavel Roskin). - -
      • add $(MAIN_DEFINES) to the variables checked by the - configure script that may contain information set by imake. This - allows xterm to build/run properly using the configure script on - IRIX64. - -
      • add configure check for ".exe" suffix on cygwin. -
      - -

      Patch #178 - 2003/5/18 - XFree86 4.3.99.5

      -
        -
      • modify default for configure --enable-pty-handshake - option to enable it for Solaris (report by Nelson Beebe). - -
      • modify in_put() function to call - PreeditPosition() only when the cursor's position has - changed. This addresses report by Stefan Baums of high CPU usage - while xterm with chinput are running in the background (patch by - Yong Li). - -
      • improved explanation of -ls conflict with - -e option in xterm manpage (adapted from comments by - Henning Makholm). - -
      • correct comment in terminfo file regarding modifier used for - kDC (Debian #189764, report by Henning Makholm). - -
      • correct/extend some of the keypad description in ctlseqs.ms - (report by Henning Makholm). - -
      • correct keypad-mapping table in input.c so XK_KP_Equal - works (report by Henning Makholm). - -
      • modified to work with CJK double-width (bi-width/monospace) fonts. - They're similar to Roman Czbora and David Starner's gnuunifonts in - that Latin letters and numbers have all the same width which is - exactly the half of the width of East Asian characters. (patch by - Jungshik Shin <jshin@mailaps.org>). - -
      • add configure option --enable-broken-osc and resource - brokenLinuxOSC to accommodate scripts which do not - distinguish between running in the Linux console and running in X. - Linux console recognizes malformed control strings which start - with an OSC, but are fixed-length, with no terminator. - -
      • add configure option --enable-broken-st and resource - brokenStringTerm to allow - user to revert one part of the parsing table corrections from - patch #171. (reports by - Matthias Scheler and - Kirill Ponomarew indicate that someone's - network firmware sends an <escape>X). - -
      • modify configure --disable-imake to provide values - for OSMAJORVERSION, OSMINORVERSION, - FUNCPROTO and NARROWPROTO (report by - Heiko Schlichting). - -
      • correct vttests/16colors.sh, which omitted the - $SUF variable in output strings (patch by Paul - Gilmartin). - -
      • modify shell scripts in vttests directory to attempt - to use named signals in the trap statement, making - this portable to OS/390 (report by Paul Gilmartin). Tested on - SunOS 4.1.4, which implements only numbers. -
      - -

      Patch #177 - 2003/3/23 - XFree86 4.3.0

      -
        -
      • fix definition of USE_HANDSHAKE, must be numeric - (reported by Jens Schleusener). -
      - -

      Patch #176 - 2003/3/22 - XFree86 4.3.0

      -
        -
      • add configure option --enable-pty-handshake to allow - one to compile-in support for the pty handshaking logic, and - resource ptyHandshake to enable or disable it - (suggested by Ian Collier). - -
      • restore USE_HANDSHAKE ifdef removed in - patch #159 - to address Debian #39964. - -
      • move ifdef's for ttysize/winsize into xterm_io.h - -
      • simplify loop on tgetent, check if the successive - entries in the lookup table are the same. That makes xterm do - one less lookup if there is no "xterm" entry in the termcap file - (report by Derek Martin). - -
      • correct manpage discussion of $TERM and - $TERMCAP variables, which omitted the Tektronix - emulation and a note of the final "dumb" fallback. - -
      • broaden ifdef for XRegisterIMInstantiateCallback() - from patch #175 (XIM fix) to exclude - non-XFree86 (report by Nelson Beebe indicates this breaks for - Solaris, IRIX and OSF/1). - -
      • correct resource-size for iconFont (this was added - by X11R6.3). - -
      • improve configure check for XKB bell extension, to work around - inconsistent implementation of this feature (reports by Nelson - Beebe, Kriston Rehberg and David Ellement). - -
      • modify configure-check for tty group to be less - strict in batch mode (report by Nelson Beebe). - -
      • modify to allow building with g++, to use its compiler warnings - (suggested by Nelson Beebe). - -
      • modify dec2ucs[] table to reflect newer codes - available for scanlines 1, 3, 7, 9 (report by Michael Schroeder). - -
      • add configure option for XawPlus library. -
      - -

      Patch #175 - 2003/3/9 - XFree86 4.3.0

      -
        -
      • fix a SIGSEGV which could occur if xterm is connecting to XIM - server, and the XIM server is destroyed (patch by Nam SungHyun). - -
      • modify to use built-in line-drawing characters for Xft fonts - (patch by Andrew Tipton). - -
      • make menu reflect the state of the tekInhibit - resource. - -
      • make signalInhibit resource work, i.e., disable the - menu entries that would send signals to, or exit xterm. This was - probably broken in X11R5 when logging was disabled (report by Sven - Mascheck). - -
      • changed classes of colorBDMode and similar - resources that override colors when a video attribute is - set to ColorAttrMode, to make them distinct - from ColorMode. This avoids an unexpected - rendering of reverse video, for example (report by Paul Fox). - -
      • changed class of veryBoldColors to - VeryBoldColors, since - ColorMode is associated with boolean resources. - -
      • add option -k8 and resource - allowC1Printable to allow users of non-VTxxx - character sets such as KOI-8 to treat the C1 control area - (character codes 128-159) as printable rather than control - characters. - -
      • add a null-pointer check for return-value of ptsname() - in HPUX-specific code (report by David Ellement). - -
      • revise the ifdef's used for XKB bell support. The - code was using a nonstandard call XkbStdBell(). - Changed to use XkbBell() (based on patch by - <derek@signalmarketing.com>). - -
      • add a null-pointer check in xtermLoadFont() in case - there is no wide-bold font (Nam SungHyun). - -
      • change Makefile.in to use autoconf's - bindir, libdir and mandir - variables (report by Nam SungHyun). - -
      • add le to termcap xterm-basic entry. - Though missing from older termcaps for xterm, some applications - check for it (report by Matthias Buelow). - -
      • modify uxterm script to strip modifiers such as "@euro" - from the locale setting before adding ".UTF-8" (Debian #179929). - -
      • modify the remaining places where tek4014 emulation uses - XDefineCursor(), to make it work as originally - implemented, e.g., when switching back to alpha mode. - Added test-screen in vttest to test this feature properly. -
      - -

      Patch #174 - 2003/2/25 - XFree86 4.2.99.903

      -
        -
      • work-around for XFree86 bug which made XDefineCursor() - on a shell-window no longer work. The tek4014 emulation used this. - Use the next lower window (report by Karl Rudolf Bauchspiess). - -
      • add a resource setting allowWindowOps to control - whether the extended window operations should be allowed, e.g., - resize, iconify, report window attributes. This is to accommodate - people who are not capable of using a pager to view log-files. -
      - -

      Patch #173 - 2003/2/6 - XFree86 4.2.99.902

      -
        -
      • reset mouse mode to normal on a full reset. This does not apply - to mouse hilite tracking mode, of course (see ctlseqs.ms). - -
      • add a time-delay at the point where mouse hilite tracking mode - choses to not handle X events, to avoid runaway CPU usage - (report by D Hugh Redelmeier). - -
      • check for illegal character in DECUDK string, quit if detected. -
      - -

      Patch #172 - 2002/12/27 - XFree86 4.2.99.3

      -
        -
      • fixes to make repainting of 256-color example work properly - (reports by Abigail Brady and Scott A Crosby). -
          -
        • set flag in AllocateAnsiColor() to ensure the color - is allocated once only. -
        • fix check in ScrnRefresh, which was comparing - background colors only if the ANSI foreground colors also were set. -
        - -
      • merge Error() calls and some exit() calls - into SysError(), and change that to add the brief - explanation for each error code which is provided in the manpage. - Change a few SysError(), calls to avoid using code 1, to - avoid confusion with exit status from places that do not use - SysError(). - -
      • simplify logic used to open a debug logfile as the standard error. - -
      • modify the -e option so that if it fails, xterm will - check if only one argument follows, e.g., it was quoted, and then - retry using sh -c. - -
      • modify parsing of DECUDK string parameter to allow a comma between - pairs of hexadecimal digits (Ray Neuman <raymond@one.com.au> - reports that "real" terminals accept this; perhaps they simply - ignore unexpected characters). - -
      • fix a few problems with the $TERMCAP string generated - by resize: -
          -
        • for Bourne shell, add an export command. - This was missing as far back as X11R5. -
        • escape exclamation marks, used in xterm's reset string. -
        • translate literal \177\ to "^?". -
        - -
      • improve configure check for tgetent() to work when - $TERMCAP has been set to a specific entry. - -
      • modify minstall.sh to use "%" rather than "@", - to avoid problems with AFS (report by Zdenek Sekera). - -
      • list fatal error codes from error.h in the manpage, - remove unused codes in error.h. - -
      • use more explicit wording for manpage list of color resources, - since at least one user confused the generic names such as "black" - with the names in rgb.txt (the latter are now used). - -
      • minor fix to description of 1003 mouse mode in ctlseqs.ms - (Larry Riedel). -
      - -

      Patch #171 - 2002/12/12 - XFree86 4.2.99.3

      -
        -
      • modify parser tables to improve detection of malformed control - sequences, making xterm behave more like a real DEC terminal - (patch by Paul Williams). - -
      • update comment in input.c to document - Meta as a modifier for escape sequences (patch by D - Roland Walker). - -
      • add ifdef'd code for logging option which adds the hostname and a - timestamp to the generated logfile name. The ifdef's are setup - with the configure script (patch by Nelson Beebe). - -
      • remove xevents() call from the end of - BlinkCursor(), to fix an occasional problem - which caused xterm to pause until a key was pressed. - The reason for this was that there was no check to ensure that - there really were events for xevents() to process. - (patch by Semen A Ustimenko <semenu@FreeBSD.org>). - -
      • remove unused mode-params from open() calls that do - not create a file. - -
      • modify configure script to put new items first on - $CPPFLAGS and $CFLAGS to avoid conflict - with environment's -I and -D options. - -
      • update config.guess, config.sub - -
      • resync with XFree86 CVS -
          -
        • fix va_args glitches for xterm/libfontconfig: 0 == (void*)0 - isn't true for all platforms (Egbert Eich). -
        • initialise ProgramName in xterm's main before referencing it - (#5473, Peter Valchev). -
        • some cleanup of Imakefile ifdef's (Marc La France). -
        -
      - -

      Patch #170 - 2002/10/13 - XFree86 4.2.1

      -
        -
      • correct an off-by-one allocating data for sorted help message. - -
      • modify configure script to check for Xpm library, on which XFree86 - Xaw library depends. - -
      • update config.guess, config.sub -
      - -

      Patch #169 - 2002/10/5 - XFree86 4.2.1

      -
        -
      • modify wording of some options in help message to make them use - -/+ consistently with respect to "on/off" or "off/on". - -
      • sort options list which is displayed in help- and syntax-messages - at runtime to simplify maintenance. - -
      • remove support for Amoeba and Minix (Juliusz Chroboczek noted it - was removed from XFree86 server; there have been no users since - 1996). - -
      • add configure script option --disable-session-mgt - to control whether the session management code should be compiled-in - (request by H Merijn Brand). - -
      • ifdef'd the session-management changes with - OPT_SESSION_MGT, to accommodate X11R5 which predates - the related definitions. - -
      • fix decode_keyvalue(), which did not properly parse - multiple settings as needed for the ttyModes resource, - since it did not skip over the parsed data. - -
      • fix an option-parsing conflict between -class and - -cjk_width (Nam SungHyun) - -
      • add a missing null in XtVaSetValues() call used in - Cleanup() (Nam SungHyun) -
      - -

      Patch #168 - 2002/9/29 - XFree86 4.2.1

      -
        -
      • improve data reported for control sequence that requests window - position by taking into account the window decorations, e.g., - border and title (patch by Jess Thrysoee <jess@thrysoee.dk>). - -
      • add -cjk_width and corresponding resource - cjkWidth (patch by Jungshik Shin - <jshin@mailaps.org>). - -
      • add -into option, for embedding xterm in a Tcl/Tk - application (patch by George Peter Staplin <georgeps@xmission.com>). - -
      • add simple session management (XSM) client capabilities to xterm. - So a session manager such as, e.g., xsm, should be able to respawn or - kill xterms without the help of an SM proxy (like smproxy), which is - a hack and almost always buggy (patch by David Madore). - -
      • fix conflict between ifdef's for OPT_DEC_LOCATOR and - OPT_READLINE in button.c (reported by Ilya Zakharevich). - -
      • fix for inconsistent use of struct utmp versus - struct utmpx introduced in patch #167 - (patches by Paul Gilmartin, Marc La France). - -
      • modify logic for metaSendsEscape to allow it to work - in a setup where the Meta-key is not recognized as a modifier by - the key-translations logic (discussion of eightBitInput with H.J.Lu). - Note however that Vincent Lefevre reported this in January). - -
      • use null pointer values consistently, rather than literal "0", for - ending variable-length argument lists, e.g., for - execlp() (based on patch by Matthieu Herrb). - -
      • correct logic of ChangeAnsiColorRequest(), which would - do a screen repaint after replying to a request for information. - -
      • improve scripts in vttests to work with systems whose shells support - echo -n and have, as does Debian, an unrelated - print utility. - -
      • add vttests/acolors.sh to demonstrate OSC 4, which queries or - sets ANSI colors. - -
      • fixes for ctlseqs.ms (Pavel Roskin, Ilya Zakharevich). - -
      • typos in xterm manpage (Jens Schweikhardt) - -
      • remove a redundant GCC_UNUSED from InitPopup() (Nam SungHyun) -
      - -

      Patch #167 - 2002/8/24 - XFree86 4.2.0

      -
        -
      • correct ifdef's for USE_TERMCAP to match cygwin - configuration. - -
      • fix several places in ctlseqs.ms which had no boxes around the - literal text (report by Ilya Zakharevich). - -
      • extend mouse support for readline, - ifdef'd with OPT_READLINE - (integrated patch from Ilya Zakharevich). - -
      • modify terminfo description to match default for - modifyCursorKeys resource. - -
      • add modifyCursorKeys resource to control how the - shift- and similar modifiers are used to make a cursor escape - sequence. The default makes a modified escape sequence always start - with CSI and puts the modifier as the second parameter, to avoid - confusing applications that would interpret the first parameter as a - repeat count. The original behavior can be obtained by setting the - resource to 0 (newsgroup discussion with Stephen J Turnbull, - Jeffrey Altman). - -
      • correct missing initializations for appdefaultCursor - and appdefaultKeypad resources. - -
      • add configure option --enable-luit and ifdef'd the - luit-related code with OPT_LUIT_PROG. - -
      • modify xterm to invoke luit (integrated patch by Tomohiro Kubota) - -
      • update wcwidth.c to match Markus Kuhn's 2002-05-18 version. - -
      • correct limit-checking in ComputeSelect() to handle - selections that extend off the visible area; rather - than modify the parameters to TrackText(), use - ScrollSelection() to update the highlighting limits. - (reported by Yegappan Lakshmanan and Nelson Beebe, - patch by Alexander V Lukyanov). - -
      • correct manpage description of tiXtraScroll resource - (reported by Tony Finch). - -
      • changes from OpenBSD: -
          -
        • Make xterm setgid utmp to be able to update utmp even - with root privileges revoked. -
        • If not updating utmp, revoke group privileges totally too. -
        - -
      • changes from NetBSD: -
          -
        • Check that the return value from ttyslot() is greater than 0 - before writing the utmp file. - Fixes w's "w: Stale utmp entry: <user> <tty> <pty>" errors. -
        • Use openpty() to deal with new pty naming scheme. -
        - -
      • add print-redir action and menu entry to allow user to - switch terminal in/out of printer controller mode. It appears from - the manual that a real vt220 would not switch back to normal mode, so - another mechanism is used (addresses Debian #37517). - -
      • check if printerCommand resource string is empty, use - this to allow user to disable printer function. - -
      • trim trailing blanks from resource strings. - -
      • check return value from ptsname(), which may return - null for example if someone has changed the permissions of /dev/pts - to zero (Debian #121899). - -
      • modify OS/2 version to use __UNIXOS2__ definition - rather than __EMX__, related cleanup (patch by Holger - Veit). - -
      • used modified indent 2.0 - (patch 20020428) - to reformat most of the C source files, to simplify maintenance. - -
      • fix a couple of places where there were leading tabs on - symbol-definition lines in Imakefile (Marc La France from report by - Tony Finch) - -
      • add imake variable (TraceXTerm) to allow building debug version - (Egbert Eich). -
      - -

      Patch #166 - 2002/03/25 - XFree86 4.2.0

      -
        -
      • correct a bug in selection: double clicking on a word which - was partly scrolled off the screen may select that text (report - by Vincent Lefevre <vincent@vinc17.org>). - -
      • implement veryBoldColors resource to control whether - the corresponding video attribute such as bold is - displayed when using colorBDMode, etc. (request by Josh - Howard <jrh@vicor-nb.com>). - -
      • define escape sequences for function keys F21-F35 (patch by Steve Wall). - -
      • change the colors for the 256-color model, making them less skewed - toward black (patch by Steve Wall). - -
      • add vt100Graphics resource - (see patch #115, - based on discussion with Glenn Maynard). - -
      • ifdef'd Xaw/Xaw3d/neXtaw includes separately to avoid potential - incompatibilities between these flavors of Athena widgets. - -
      • add configure check for XFree86 4.x Xaw library, whose geometry - management is broken, to avoid trying to use it for toolbar - configuration. - -
      • updates to configure script from vile and lynx to allow - configure.in to be compiled with autoconf 2.5x - -
      • add a check for null pointer return by ptsname() - (newsgroup posting from Mike Silva <mikesilva@lucent.com>). - -
      • fill in a few details needed to allow UTF-8 mode to switch on/off - after startup. This requires that wideChars resource be - set. (based on comments in 4 Aug 2001 by Alexey Marinichev - <lyosha@lyosha.2y.net>). - -
      • remove duplicate install rules that make directories, e.g., so installing - manpage will not create app-defaults directory. - -
      • add comment in in do_osc(), reserving cases 30 and 31 - for for Konsole (request by Stephan Binner - <Stephan.Binner@gmx.de>). - -
      • fixes for ctlseqs.ms and xterm.man - (patch by Werner Lemberg <wl@gnu.org>). - -
      • add check for monochrome display, disabling colorMode in that - case (fixes Debian #134130). - -
      • resync with XFree86 CVS -
          -
        • Fix some xterm build warnings on *BSD (patch by David Dawes). -
        • Only use SA_RESTART in xterm when it's available (patch by Frank Liu). -
        • Fix incorrect code in signal handlers in most of the clients, - xterm and xdm not done yet (patch by Matthieu Herrb). -
        -
      - -

      Patch #165 - 2002/01/05 - XFree86 4.1.0

      -
        -
      • modify uxterm script to strip encoding part from - environment variable before adding ".UTF-8" (based on Debian - #125947, but using a more portable solution). - -
      • add an assignment statement in VTInitialize() to make - awaitInput resource work. - -
      • use new macros init_Bres(), etc., in VTInitialize() to add trace of - the initialization of resources. - -
      • modify checks for $LC_ALL, related environment variables to ensure - the resulting strings are nonempty (report by Markus Kuhn). - -
      • add an ifdef in charproc.c for num_ptrs variable in case all - configure options are disabled. - -
      • modify definition of getXtermBackground() to avoid negative array - index warning on Tru64 (report by Jeremie Petit). - -
      • improve fix from patch #165 (still Debian #117184, report by Matt - Zimmerman <mdz@debian.org>) - -
      • correct install rule for uxterm in Makefile.in, to handle the - case where building in a different directory than xterm's source - (patch by Paul Gilmartin). - -
      • documented ANSI.SYS-style cursor save/restore escape sequences - in ctlseqs.ms, which are in xterm since X11R5. - -
      • correct two entries in the default charClass table, which did not - follow the manpage comment about the character number corresponding - to the class (patch by Marc Bevand <bevand_m@epita.fr>). - -
      • fix a couple of typos in comments in the app-defaults files - (David Krause <xfree86@davidkrause.com>). - -
      • resync with XFree86 CVS -
          -
        • update language of copyrights in some files to reflect the fact - that they were reassigned from X Consortium to The Open Group in - 1998. Note that this xterm source is derived from the 1996 - version from X Consortium, does not incorporate changes made by X - Consortium or The Open Group after that date, hence we do not add - The Open Group's 1998 copyright date to related files. - -
        • save/restore errno in signal catcher (patch by Matthieu Herrb). - -
        • modify UXTerm.ad's font5 resource so that xterm can display double - width characters using a font distributed with XFree86 (Tomohiro Kubota). -
        -
      - -

      Patch #164 - 2001/11/13 - XFree86 4.1.0

      -
        -
      • correct a case where ptyInitialErase and - backarrowKeyIsErase resources combine to set - DECBKM mode, but a reset command would not - reset xterm to that state, making the erase character revert to ^H - (Debian #117184) -
      - -

      Patch #163 - 2001/11/04 - XFree86 4.1.0

      -
        -
      • correct ifdef's for __QNX__ and - USE_SYSV_PGRP in main.c call to tcsetpgrp, - which broke bash behavior around patch #140 - (report/patch by Frank Liu <fliu@mail.vipstage.com>). - -
      • modify trace.c to fix missing definition of GCC_UNUSED for - compilers other than gcc when configured for trace code (report/patch - by Paul Gilmartin). - -
      • change format in TraceOptions() to use long rather than int, since - the latter could lose precision on 64-bit machines (report/patch by - Nelson Beebe). - -
      • modify xterm manual page and minstall.sh to allow imake rules - to define location of app-defaults directory (Debian #87611). - -
      • review/update list of conflicting preprocesor symbols to remove - from $CPPFLAGS at the end of the configure script. In particular, - this allows one to configure xterm without the utempter library on - Redhat 7.1 (report/patch by Adam Sulmicki). -
      - -

      Patch #162 - 2001/10/23 - XFree86 4.1.0

      -
        -
      • correct logic that processes -class option, so that - a following -e option is handled (Debian #116297). - -
      • improve options-decoding to allow -version and - -help options to be combined (Debian #110226). - -
      • add a 10 millisecond delay in event loop when processing - -hold option, to avoid using too much CPU time - (Debian #116213). - -
      • prefix final program execution in uxterm with "exec" - to avoid a useless shell hanging around (Christian Weisgerber). -
      - -

      Patch #161 - 2001/10/10 - XFree86 4.1.0

      -
        -
      • modify logic that resets keypad application mode to avoid doing - this if there is no modifier associated with the Num_Lock keysym - (report by John E Davis <davis@space.mit.edu> and Alan W Irwin - <irwin@beluga.phys.uvic.ca>). - -
      • add built-in translation for Control/KP_Separator to KP_Subtract, - to accommodate users who wish to use xmodmap to reassign the top - row of the numeric keypad. - -
      • correct Imakefile install-rule for uxname script - (reported by Nam SungHyun <namsh@lge.com>). - -
      • resync with XFree86 CVS – correct typo in <ncurses/term.h> - ifdef. -
      - -

      Patch #160 - 2001/10/7 - XFree86 4.1.0

      -
        -
      • modify logic in main.c - (see patch #145) to avoid generating the - same identifier, for example, for /dev/tty1 and /dev/pts/1, which - is used to denote an entry in the utmp file (Debian bug report - #84676), A similar fix was also sent by Jerome Borsboom - <borsboom@westbrabant.net> in May, but I overlooked it when - reviewing bug reports. - -
      • add configure check for <ncurses/term.h> to get - rid of hardcoded __CYGWIN__ ifdef in resize.c -

        - NOTE: The CYGWIN port should not be linking resize - with ncurses. It appears that the only reason it is, is because - both the ncurses and termcap ports on that platform are badly - misconfigured (essential pieces have been removed, etc). Checking - for <ncurses/term.h> does not hurt anything, - since there are some correct installations that are set up that - way. - -

      • add a sample uxterm script, which uses the - UXTerm application defaults for UTF-8 environments. - -
      • undo change to xterm application defaults, since this introduced an - unnecessary incompatibility. The intended functionality was - already addressed by the UXTerm - app-defaults file. - -
      • resync with XFree86 CVS -
          -
        • Modified xterm app default to use LFD fontnames instead of old type - (Michael Schroeder). -
        • Fix xterm when XIM is disabled - caused a segfault - (Tomohiro Kubota). -
        -
      - -

      Patch #159 - 2001/9/19 - XFree86 4.1.0

      -
        -
      • remove an ifdef for USE_HANDSHAKE added in patch - #158 from the second TIOCSSIZE ioctl call in the - initialization code. Paul Gilmartin reports that for Solaris 2.6 - (sparc), stty does not show that xterm sets rows and columns unless - the second ioctl is executed. - -
      • correct treatment of empty parameter list for some OSC strings - (report by Sami Farin <sfarin@ratol.fi>). -
      - -

      Patch #158 - 2001/9/8 - XFree86 4.1.0

      -
        -
      • augment key translations for scrollbar widget to ensure that - keystrokes intended for the text area are not lost if the mouse - pointer happens to fall on the scrollbar. This can happen, for - instance, if the user's app-defaults or - .Xdefaults file contains a translations resource, - though it may also happen through unrelated resource settings: - probably a bug in libXt (reported by Paul Fox - <pgf@foxharp.boston.ma.us> and Dmitry Yu. Bolkhovityanov - <D.Yu.Bolkhovityanov@inp.nsk.su>). - -
      • widen ifdef's in xterm.h to define __EXTENSIONS__ on - Solaris, for compilers other than gcc. This was added along - _POSIX_C_SOURCE with in patch - #151, but is not sufficient since Sun's compiler does not define - __STDC__ by default (report by Matthias Scheler - <tron@zhadum.de>). - -
      • modify xterm to obtain the closest matching color if an exact color - is not available, e.g., on 8-bit displays (patch by Steve Wall) - -
      • implement "OverTheSpot" preedit type of XIM input - (patch by Tomohiro Kubota): -
          -
        • This preedit type is a reasonable compromise between - simpleness of implementation and usefulness. "Root" preedit - type is easy to implement but not useful; "OnTheSpot" preedit - type is the best in the point of view of user interface but - very complex. And more, "OverTheSpot" is the preedit type - which the most XIM servers support. Thus, to achieve reasonable - usability, support of "OverTheSpot" preedit type is needed. - -
        • In "OverTheSpot" preedit type, the preedit (preconversion) - string is displayed at the position of the cursor. On the - other hand, it is XIM server's responsibility to display - the preedit string. Thus, it is needed for XIM client (here - XTerm) to inform the XIM server of the cursor position. - And more, to achieve good visual proportion, preedit string - must be written using proper font. Thus, it is XIM client's - responsibility to inform the XIM server of the proper font. - The font must be supplied by "fontset". Fontset is a set of - fonts with charsets which are specified by the current locale. - Since XTerm uses ISO10646 fonts regardless of the current locale, - the fonts for XIM must be prepared separately. It is difficult - to prepare fonts which are similar to XTerm font. Thus, my - patch uses a simple way - the default font is "*" which matches - every fonts and X library will automatically choose fonts with - proper charsets. I added "-fx" command option and "ximFont" - resource to override this default font setting. - -
        • changed the definition of "OverTheSpot" preedit type - from XIMPreeditPosition|XIMStatusArea - to XIMPreeditPosition|XIMStatusNothing. - This matches the behavior of other programs such as - Rxvt, Kterm, Gedit. - -
        • A tiny XIM bugfix is also included. By calling XSetLocaleModifiers() - with parameter of "", it can consier XMODIFIERS environmental - variable which is a standard way for users to specify XIM server - to be used. -
        - -
      • adjust configure script to accommodate repackaging of keysym2ucs.c - as include-file for xutf8.c (patch by Tomohiro Kubota). - -
      • add the UXTerm app-defaults file to makefile install - rules (request by Juliusz Chroboczek). - -
      • correct logic in get_termcap(), which returned false - if the tgetent() call indicated that xterm was linked - with terminfo. Although the $TERMCAP variable cannot be - adjusted in this case, xterm still needs information from this call - to extract data to initialize the erase-mode when the - ptyInitialErase resource is false. - -
      • modify ScrollbarReverseVideo() function to cache the - original border color, so it can restore that when an application - flashes the screen (Bugzilla #38872). - -
      • resync with XFree86 CVS -
          -
        • remove ifdef's for X_NOT_STDC_ENV (patch by David Dawes). -
        • add Cygwin to special errno handling case in ptydata.c (Alan Hourihane) -
        • set screen size earlier in initialization, to address a race - with window manager resizing its clients (Keith Packard). -
        -
      - -

      Patch #157 - 2001/6/18 - XFree86 4.1.0

      -
        -
      • clean up button.c and input.c (patch by Juliusz Chroboczek). The - basic idea is to use a single set of APIs in the XTerm core, and put - a set of workarounds in a separate file. As you will notice, this - drastically simplifies parts of the code; in particular, the only - remaining ifdefs related to the differences between Xutf8 and legacy - systems are related to the selection provider logic. - - This defines two new files, xutf8.h and xutf8.c, provide some - half-hearted but fully portable emulation for the three Xutf8* - functions that XTerm uses. - - Putting these in a separate file will allow people to experiment with - more complex versions without making the core of XTerm more difficult - to maintain. - - The functionality of the emulation is as follows. -
          -
        • Xutf8TextListToTextProperty fully handles XStringstyle and - XUTF8StringStyle. It will only generate STRING for XStdICCTextStyle, - and wil only generate Latin-1 in XCompoundTextStyle (but label it as - COMPOUND_TEXT, as the spec requires). (I have hesitated to make this - function fail for XStdICCTextStyle and XCompoundTextStyle; this might - be a smart thing to do, in the hope that the selection requestor will - try UTF8_STRING afterwards; opinions?) - -
        • Xutf8TextPropertyToTextList fully handles STRING and UTF8_STRING. - It systematically fails for COMPOUND_TEXT. - -
        • Xutf8LookupString will properly handle single-keystroke input for - the keysyms covered by Markus' keysym2ucs function. It will not - handle either compose key input or external input methods. -
        - -
      • add an ifdef for SunXK_F36, used in - xtermcapKeycode() (patch by Mark Waggoner - <waggoner@ichips.intel.com>). - -
      • modify check for login name to try getlogin() and - $LOGNAME, $USER environment variables to detect if the user has - logged in under an alias, i.e., an account with the same user id - but a different name (Debian bug report #70084). - -
      • add resource tiXtraScroll, which can be used to - preserve the screen contents in the scrollback rather than erasing - it when starting a fullscreen application such as vi - (patch by Ken Martin <fletcher@catsreach.org>). - -
      • two patches by Denis Zaitsev <zzz@cd-club.ru>: -
          -
        • added forceBoxChars resource to control the - "line-drawing characters" option. - -
        • added freeBoldBox resource, which, when set true, - suppresses check in same_font_size(), so xterm does - not attempt to ensure that the bold font is the same size as - the normal font. -
        - -
      • change the color class for ANSI colors and similar ones such as - bold-color, etc., to follow the convention that the classname is the - instance name with a leading capital (e.g., color0 and - Color0 rather than color0 and - Foreground). There was little use for Foreground as a - class other than to create occasional confusion and bug reports, most - recently by Nelson Beebe who reports that it disables colors in xterm - but not on Linux, which is probably due to a difference in resource - evaluation order. A configure script option (--disable-color-class) - is provided for anyone who did use the older behavior. - -
      • fix a signal-handling bug. When running xterm with - ksh or similar shell such as bash 2.05, xterm will hang - and not respond to keystrokes after the user types - suspend. Additionally the popup menus do not respond, - so it is not possible to send SIGCONT to the shell. - What is happening is that the shell is sending itself SIGSTOP, and it - is being stopped. Per specification it also means that the operating - system is sending SIGCHLD to parent to the bash (XTERM). - Now the issue is that xterm assumes it cannot happen and it expects - to receive SIGCHLD only upon termination of its children. - This causes a deadlock with xterm waiting for the child to - die, and the child waiting for SIGCONT. - (report/patch by Adam Sulmicki), analysis/testing by Sven Mascheck - <sven.mascheck@student.uni-ulm.de>). - -
      • correct some inconsistent checks for XtReleaseGC() - calls in xtermLoadFont() (patch by Nam SungHyun - <namsh@lge.com>). - -
      • updated wcwidth.c and keysym2ucs.c to versions dated 2001/1/12 - and 2001/4/18, respectively from - http://www.cl.cam.ac.uk/~mgk25/ucs/ - -
      • correction to change from patch #90, - which was intended to - reset the saved cursor position for normal/alternate screens - on a soft reset, but actually wiped out all of the saved cursor - information. Just reset the saved position for the current screen - (report by Michael Schroeder). - -
      • modify ShowCursor() and HideCursor() so that if the cursor points - to the second part of a wide character, make the show/hide operate on - the first position of the wide character (patch by Sven Verdoolaege). - -
      • scrolling in the alternate screen just before switching back to the - main screen can cause extra blank lines to be inserted into the - scrollback buffer (patch by Paul Vojta - <vojta@math.berkeley.edu>). - -
      • resync with XFree86 4.1.0: -
          -
        • Use TermcapLibrary as -lncurses instead of -ltermcap, fixes - problem building xterm/resize on Cygwin/XFree86 (Harold Hunt). -
        • Install xterm.termcap and xterm.terminfo when installing xterm - (Torrey T. Lyons). -
        • Fix some build issues on Cygwin/XFree86 (Suhaib Siddiqi). -
        • Define CBAUD, when it's missing in xterm, on LynxOS - (Stuart Lissaman). -
        -
      - -

      Patch #156 - 2001/4/28 - XFree86 4.0.3

      -
        -
      • change order of selection-target types to make 8-bit xterm prefer - UTF8_STRING to COMPOUND_TEXT (patch by Juliusz Chroboczek). - -
      • document -fa, -fs command-line options - and faceName, faceSize - resources which are used by the freetype library support. - -
      • if configure script finds freetype libraries, but imake definitions - do not have the XRENDERFONT definition, define it anyway. - -
      • modify configure script check for freetype libraries to include - <Xlib.h>, since an older version of the related - headers relies on this (patch by Adam Sulmicki). -
      - -

      Patch #155 - 2001/4/20 - XFree86 4.0.3

      -
        -
      • correct return type of in_put() from patch #153 - changes, which left it not wide enough for UTF-8 (patch by Bruno Haible). -
      - -

      Patch #154 - 2001/4/11 - XFree86 4.0.3

      -
        -
      • undo check for return value from pututline (used for - debugging) since that function does not return a value on Slackware - 3.6. - -
      • correct length in ScreenWrite, when rendering invisible text - (patch by Sven Verdoolaege <skimo@kotnet.org>). - -
      • fixes/improvements for the i18nSelection resource - from patch #153, by Bruno Haible: - -
          -
        • add missing initialization for i18nSelection - resource. - -
        • split-out the non-ICCM aspect of the - i18nSelection resource as a new resource, - brokenSelections. -
        - -
      • add configure check for <time.h> and - <sys/time.h>, to allow for Unixware 7, - which requires both. If the configure script is not used, only - <time.h> will be included as before (report - by Thanh Ma). - -
      • fix redefinition of dup2, getutent, - getutid, getutline and sleep - functions on Unixware 7 (report by Thanh Ma - <Thanh.Ma@casi-rusco.com>) - -
      • add a fall-back definition for __hpux, which is - apparently not defined in some compilers on HPUX 11.0 (reported - by Clint Olsen). - -
      • change VAL_INITIAL_ERASE, which is used as a fallback for the - "kb" termcap string to 8, since that matches the - xterm terminal description (request by Alexander V Lukyanov). - -
      • correct an off-by-one in ClearInLine, which caused - the erase-characters (ECH) control to display incorrectly - (patch by Alexander V Lukyanov). - -
      • correct escape sequences shown in terminfo for shifted editing - keys. The modifier code was for the control key rather than - the shift key. -
      - -

      Patch #153 - 2001/3/29 - XFree86 4.0.3

      -
        -
      • increase PTYCHARLEN to 8 for os390, add some debugging traces - for UTMP functions (patch by Paul Gilmartin). - -
      • correct an misplaced brace in SelectionReceived() - (patch by Bruno Haible). - -
      • correct an assignment dropped in SelectionReceived() - which made it not compile for wide-characters combined with debug - traces. - -
      • correct typo, clarify description of 88- and 256-color controls - (report by Bram Moolenaar). - -
      • correct a typo in ctlseqs.ms which caused DEC Locator control - sequences using single quote "'" display grave "`" instead (reported - by Paul Williams, apparently in patch #114). -
      - -

      Patch #152 - 2001/3/13 - XFree86 4.0.2

      -
        -
      • correct index in inner loop in VTInitI18N() from - patch #151 changes, which resulted in infinite loop under some - conditions (report/analysis by Paul Gilmartin). - -
      • remove spurious "%|" from terminfo sgr capabilities - (report/analysis by Adam M Costello, Debian #89222). - -
      • add shell script to adjust list of dynamic libraries linked by - resize when building with the standalone configure - script. Otherwise it uses the same list as for xterm, which is - excessive. - -
      • fix a few compiler warnings reported by the 20010305 gcc snapshot. -
      - -

      Patch #151 - 2001/3/10 - XFree86 4.0.2

      -
        -
      • alter the behaviour of selections in XTerm (patch by Juliusz Chroboczek). - It is believed to follow the ICCCM + UTF8_STRING to the letter, both - in UTF-8 and in eight-bit mode. From his description: -
          -
        • When compiled against XFree86 4.0.2, the patched XTerm will make - the selection available as COMPOUND_TEXT, STRING or UTF8_STRING in - both modes. It will request selections in the following order: -

          - UTF-8 mode: UTF8_STRING, TEXT, COMPOUND_TEXT, STRING.
          - eight-bit mode: TEXT, COMPOUND_TEXT, UTF8_STRING, STRING. - -

        • When compiled against an earlier version of XFree86 (or compiled with - OPT_UTF8_API=0), it will still obey the ICCCM, but will neither - request nor provide UTF8_STRING in eight-bit mode, and neither TEXT - nor COMPOUND_TEXT in UTF-8 mode. -
        • For compatibility with previous versions of XTerm, a resource - i18nSelections is provided, please see the manpage for - details. However, due to an unexpected combination of ICCCM - extensions by various bits and pieces of the libraries, interacting - with previous versions of XTerm will work in many locales even - without this flag. (Please do not set this resource to true by - default, as this would violate the ICCCM.) -
        - -
      • improved error checking/reporting in VTInitI18N(), ensuring that - lack of input method styles is treated distinctly from a mismatch. - -
      • remove an incorrect ifdef from patch #141 which suppressed - overstriking to simulate bold font when xterm was compiled to support - wide characters (report/analysis by Adam M Costello - <amc@cs.berkeley.edu>, Debian #76404, Debian #77575). - -
      • modify RequestResize() function to save/restore window - manager hints. Its call to XtMakeResizeRequest() had - the undesirable side-effect of clearing window manager hints, e.g., - when switching to 132-columns via DECCOLM escape sequence. Window - manager hints make it simple to resize xterm in terms of character - cells rather than pixels (reports by Christian Weisgerber, - Debian #79939). -

        - This applies to the normal configuration. When built with toolbar - support, the hints are applied to a different widget level (more - work will be needed to make hints work with the toolbar). - -

      • fix a redefinition warning for resize.c on OpenBSD (patch by - Christian Weisgerber). - -
      • change resource corresponding to -T option to match - Xt library's -title, i.e., .title - rather than *title so the command-line options are - interchangeable as documented (Debian bug report #68843). - -
      • add script used from autoconf'd makefile for installing manpages, - since recent XFree86 changing the way section numbers are represented - makes the install dependent on extra scripts. - -
      • add configure check for freetype libraries and configure option - --disable-freetype to override this feature. - -
      • modify some configure script macros to avoid using changequote(), - which has been rendered useless in the latest autoconf alpha 2.49c - -
      • update config.guess, config.sub to 2001-2-13 - -
      • remove redundant/contradictory __CYGWIN__ definitions from resize.c - -
      • correct manpage typo introduced by X11R6.5 resync. -
      - Changes from XFree86 4.0.2: -
        -
      • add definition of _POSIX_C_SOURCE for Solaris to - make this compile with gcc -ansi -pedantic (report - by <mark@zang.com>. -
      - -

      Patch #150 - 2000/12/29 - XFree86 4.0.2

      -
        -
      • move the binding for shifted keypad plus/minus, which invokes the - larger-vt-font() and smaller-vt-font() - actions, respectively, into the translations resource (suggested by - Marius Gedminas <mgedmin@puni.osf.lt>). - -
      • modify configure script to support the - --program-prefix, --program-suffix and - --program-transform-name options (request by Alison - Winters <alison@mirrabooka.com>). - -
      • fixes for wide/combining characters (Robert Brady): -
          -
        • fix a scrolling / combining characters display anomaly - -
        • fix a problem with double-width characters where if the primary - font had no box-drawing characters, the right hand half of - double-width characters was erased (reported by Yao Zhang - <yzhang@sharemedia.com>). - -
        • fix special case of null byte for key handling in UTF-8 locales. -
        - -
      • modify logic that compares sizes of normal and bold fonts to be - more forgiving of the font server's choice of bold font which must - match the normal font's size. Now same_font_size() - compares the height of the fonts rather than individually ascent and - descent, and allows the bold font to be one pixel smaller than the - normal font (addresses a report by Alan Citterman - <alan@mticket.com>, who says that something in patches #146 to - #148 made xterm more likely to overstrike bold fonts, and indirectly - Debian bug report #76404, which reports the opposite). - -
      • make configure script use $CFLAGS and $CPPFLAGS consistently, - including removing a chunk from configure.in which attempted to - save/restore $CPPFLAGS while processing value set by the --x-includes - option, but lost values set in an intervening AC_CHECK_HEADERS. This - change modifies macros CF_ADD_CFLAGS, CF_ANSI_CC_CHECK and - CF_X_TOOLKIT, as well as removing variables IMAKE_CFLAGS and X_CFLAGS - from the generated makefile (the AC_CHECK_HEADERS problem was - reported by Albert Chin-A-Young <china@thewrittenword.com<). - -
      • correct a comparison in SELECTWORD case of ComputeSelect(), which - resulted in a word-selection wrapping past the first column without - checking the first column's character class (reported by Christian - Lacunza <celacunza@netscape.net> - -
      • correct a logic in UTF-8 mode for selecting double-width characters; - a combining character was omitted (patch by Markus Kuhn). - -
      • add feature to pop (raise) window when a bell is received - (patch by Gael Roualland <gael.roualland@dial.oleane.com>). - -
      • add __NetBSD__ and __OpenBSD__ to special-case in xterm_io.h - for USE_POSIX_TERMIOS definition (patch by Christian Weisgerber). - -
      • move special-case HPUX include for <sys/bsdtty.h> to - xterm_io.h to define TIOCSLTC, making HAS_LTCHARS defined for HPUX - 10.20 (report by Bruno Betro). -
      - -

      Patch #149 - 2000/12/6 - XFree86 4.0.1h

      -
        -
      • restructured includes for termios.h, - termio.h and related definitions for main.c, os2main.c, - screen.c and resize.c so they will share equivalent definitions in a - new header xterm_io.h. This is intended to solve some - problems mainly for HPUX which appear to arise from inconsistent - definitions for SIGWINCH- and HAS_LTCHARS-related symbols (reports - by Bruno Betro, Jeremie Petit and Clint Olsen). - -
      • improve usability of double-width fonts by allowing normal fonts - to be given as double-width (from a patch by Fabrice Bellard - <bellard@email.enst.fr>). - -
      • correct a few compiler warnings in TRACE() macros for - signed/unsigned variable differences (reported by Clint Olsen). - -
      • make configure script use $CFLAGS and $CPPFLAGS more consistently, - i.e., by using CF_ADD_CFLAGS in CF_ANSI_CC macro. - -
      • expanded description of environment variables in manual-page. - -
      • modify OPT_TCAP_QUERY feature to always return the termcap or - terminfo capability string in the response, and to read/write the - names in hexadecimal form to allow for the special case of termcap's - k; name (patch by Bram Moolenaar). - -
      • add OPT_SAME_NAME and OPT_TCAP_QUERY to xtermcfg.hin, so the - corresponding configure options work (patch by Bram Moolenaar). - -
      • resync with XFree86 4.0.1g: -
          -
        • Rewrite Xft library for Render extension/core text and font management - Change xterm to use new interface (Keith Packard). -
        -
      - -

      Patch #148 - 2000/10/31 - XFree86 4.0.1d

      -
        -
      • document logfile options in man-page. - -
      • correct spelling of -samename option in help message. - -
      • add configure script option --enable-tcap-query - (request by Bram Moolenaar). - -
      • add a "Co" or "colors" entry to the OPT_TCAP_QUERY feature - (patch by Bram Moolenaar). -
      • patch by Kiyokazu Suto <suto@ks-and-ks.ne.jp>: -
          -
        • add support for bold font for double width characters. - The font name may be specified with the command line option - -fwb or with resource - wideBoldFont (class WideBoldFont). -
        • correct underlining of double width character string, which - was drawn only half width. -
        • correct binary search of precomposed character table, which - may return wrong result when int is just 32 bits. -
        - -
      • some changes to align terminfo with ncurses 5.2: -
          -
        • remove xtermm description, retaining xterm-mono since the former - conflicts with ncurses. -
        • modify initialization and reset strings to avoid putting the - save/restore cursor operations bracketing changes to video - attributes, since the changes could be lost when the cursor is - restored. This affects xterm-r6 and xterm-8bit (the xterm-xfree86 - entry uses the soft-reset feature which resets scrolling margins - and origin mode without requiring us to save/restore the cursor - position). -
        • make a few entries explicitly inherit from xterm-xfree86 rather - than xterm: xterm-rep, xterm-xmc, xterm-nrc -
        - -
      • ensure that sign-extension does not affect ctype - macros by using CharOf() macro to coerce the parameter - to an unsigned char. - -
      • resync with XFree86 4.0.1d: -
          -
        • Add primitive support in xterm for Xft based fonts (Keith Packard). - The changes are ifdef'd with -DXRENDERFONT. -
        -
      - -

      Patch #147 - 2000/10/26 - XFree86 4.0.1c

      -
        -
      • correct implementation of ptyInitialErase: the - value assigned to initial_erase was for the control - terminal, which is correct as far as it goes. But there was no - following test for the pseudo-terminal's erase value, which would - overwrite the default obtained from the control terminal - (reported by Christian Weisgerber <naddy@mips.inka.de>). - -
      • modify check for printable-characters in OSC string to use xterm's - ansi_table rather than isprint() macro, to isolate this check from - locale settings. This fixes a problem using 8-bit characters to - set the title (reported by Ricardas Cepas <rch@richard.eu.org>). - -
      • modify sample scripts to check for printf before print, since the - latter is not as well standardized (e.g., on Linux). - -
      • updated config.sub, config.guess to reflect changes on - subversions.gnu.org -
      - -

      Patch #146 - 2000/9/12 - XFree86 4.0.1c

      -
        -
      • correct two instances overlooked from patch #141 which assumed - UTF-8 mode without checking, causing a core dump in non-UTF-8 mode - (one instance was reported by Tommi Virtanen <tv@debian.org>). - -
      • correct a problem selecting from the scrollback buffer in UTF-8 - mode by changing remaining getXtermCell() calls to XTERM_CELL() as in - the non-UTF-8 cases (report by Markus Kuhn, patch by Robert Brady). -
      - -

      Patch #145 - 2000/9/11 - XFree86 4.0.1c

      -
        -
      • changes for UTF-8 configuration (Robert Brady): -
          -
        • doublewide characters don't lose their accents when the cursor - moves onto or from them (a visual bug) - -
        • fix logic in addXtermCombining, which mean that if the low byte - of a cell's first combining char was 0, a following combining char - would go into combining slot 1, not 2. - -
        • modify logic for cut-buffers so UTF-8 data is first converted - to Latin1. - -
        • collapse surrogates, 0xfffe, 0xffff to UCS_REPL. - -
        • modify to allow xterm to to show combining characters - attached to doublewidth characters. - -
        • correct bug in linewrap with -u8 option (reported by - Andreas Koenig <andreas.koenig@anima.de>). -
        - -
      • several changes to PTY logic (based on request by Tim Ryan - <timryan@nortelnetworks.com>). -
          -
        • modify treatment of -S option to to make it work with - Unix98 PTY's. - -
        • restore sense of IsPts flag in get_pty(), which was - lost in Unix98 changes. - -
        • use new functions my_pty_id() and - my_pty_name() to simplify/fix strings used for utmp, - wtmp identifiers. - -
        • simplify get_pty() function, making it have a single - return point so its inputs/outputs can be identified. -
        - -
      • update config.guess and config.sub and scripts to my 20000819 patch, - adding cases for OS/2 EMX. - -
      • add special case for os390 compiler options to configure script - (patch by Paul Gilmartin) - -
      • fix some unused-variable compiler warnings (reported by - Zdenek Sekera). - -
      • split-out some string functions into xstrings.c, to use them - more consistently among main.c, os2main.c and resize.c - -
      • align termcap/terminfo files, adding entries to make them match. - The termcap entries are necessarily less complete than the terminfo, - to fit within 1023 character per entry. - -
      • add terminfo entry for xterm-sco (SCO function keys). - -
      • modify same_font_name() to properly handle wildcard - introduced in bold_font_name(), making comparison for - different fonts succeed when only the normal font is specified. This - is needed to decide if 1-pixel offset should be used. (reported - in a newsgroup by Bart Oldeman <enbeo@enbeo.resnet.bris.ac.uk>) - -
      • correct preprocessor line for OPT_WIDE_CHARS in drawXtermText() - from patch #141 which resulted in overstriking for bold fonts not - working. - -
      • correct Imakefile from 4.0.1c resync so UTF-8 modules are in - UTF8SRC, UTF8OBJ lists, allowing build without UTF-8 support. -
      - -

      Patch #144 - 2000/8/23 - XFree86 4.0.1b

      -
        -
      • remove a spurious assignment in ScreenWrite() from Robert Brady's - patch which set a null at the "end" of the buffer to be written. - That made the autowrap feature write a blank in the first column for - the non-UTF-8 configuration, rather than the actual character - (reported by Alan Citterman <alan@mticket.com>). -
      - -

      Patch #143 - 2000/8/19 - XFree86 4.0.1b

      -
        -
      • add a check to ensure that -class command-line option - is not confused with -c (reported by Paul Townsend - <aab@aab.cc.purdue.edu>). -
      - -

      Patch #142 - 2000/8/18 - XFree86 4.0.1b

      -
        -
      • correction to precompose scripts, so 0061 + 0300 will now be really - be displayed as 00C0 (patch by Robert Brady - <robert@susu.org.uk>). - -
      • correct macro ClassSelects() in button.c, used to hide ifdef's for - OPT_WIDE_CHARS in patch #141 (reported by Andreas Paul - <paula@informatik.tu-muenchen.de>). - -
      • change wcwidth.h to include stddef.h rather than wchar.h, which is - not present on OpenBSD and FreeBSD (reported by Christian - Weisgerber and Bram Moolenaar). - -
      • newer config.sub and config.guess, from lynx 2.8.4dev.7 -
      - -

      Patch #141 - 2000/8/14 - XFree86 4.0.1b

      -
        -
      • changes for doublewidth and combining characters, from - http://www.ecs.soton.ac.uk/~rwb197/xterm/ - (integrated patch by Robert Brady). - In this context, - doublewidth refers to 16-bit character sets which may have glyphs - occupying two cells. - -
      • add command-line option -class, which allows one - to override xterm's resource class. Also add resource file - UXTerm.ad, which simplifies using xterm for both - 8-bit character sets and UTF-8. - -
      • fixes/improvements to OPT_TCAP_QUERY logic (patches by Bram - Moolenaar, Steve Wall). -
      - -

      Patch #140 - 2000/7/23 - XFree86 4.0.1

      -
        -
      • modify Makefile.in to circumvent GNU make's built-in suffix rule - for ".sh" which confuses install.sh with the "make install" target - (report/patch by Paul Gilmartin). - -
      • implement an experimental control sequence which an application may - use to query the terminal to determine what sequence of characters it - would send for a given function key. This is ifdef'd with - OPT_TCAP_QUERY (request by Bram Moolenaar). - -
      • add /usr/local to search path in CF_X_ATHENA configure macro - to build with Xaw3d on OpenBSD (patch by Christian Weisgerber). - -
      • add missing #undef HAVE_TERMIO_C_ISPEED to - xtermcfg.hin, omitted in patch #133 fix for IRIX 6.5 baudrate (report - by Alain Filbois <Alain.Filbois@loria.fr>). - -
      • correct a few errors in xterm.man: font in filename example for - Tektronix emulation, and description of -nul/+nul command-line - options (report by Eric Fischer <enf@pobox.com>). - -
      • update config.guess and config.sub, from tin and lynx. -
      - -

      Patch #139 - 2000/6/17 - XFree86 4.0d

      -
        -
      • back out change to -name command-line option, - restoring its original behavior (as noted by David Madore, the - correct interpretation of this option is the application instance - rather than the application class). -
      - -

      Patch #138 - 2000/6/15 - XFree86 4.0c

      -
        -
      • workaround for fixed fonts which are generated from Unicode fonts: - they omit glyphs for some xterm's less-used line-drawing characters, - which caused xterm to set a flag telling it to use only its internal - line-drawing characters. Do not set the flag (it can be set from the - popup menu), and xterm will generate only the line-drawing glyphs - which actually are missing. -
        - Otherwise, when used for large fonts, xterm may generate a 2-pixel - wide line, which can leave dots on the screen. - -
      • restore first line of 256colres.pl, omitted in 4.0c diffs. -
      -

      Patch #137 - 2000/6/10 - XFree86 4.0b

      -
        -
      • make command-line -name option work as documented. - Apparently this was lost in X11R5 when coding to use - XtAppInitialize. - -
      • limit numeric parameters of control sequences to 65535 to - simplify checks for numeric overflow. - -
      • change index into UDK list to unsigned to guard against numeric - overflow making the index negative (Taneli Huuskonen - <huuskone@cc.helsinki.fi>). - -
      • change sun function-keys resource name to - sunFunctionKeys to work around redefinition of the - token sun by xrdb on Solaris. Similarly, renamed - resource sun keyboard to sunKeyboard - (Steve Wall). - -
      • change similar resource names for HP and SCO to avoid potential - conflict with xrdb symbols on other systems, as well as for - consistency. - -
      • reorganized the install targets in the autoconf'd Makefile, adding - install-app, install-bin, install-dirs and install-man. The - app-defaults class can be overridden by setting the make variable - 'CLASS', simplifying customization of xterm as a Unicode terminal, - e.g., CLASS=UXTerm. - -
      • add limit checks to ClearInLine(), - ScrnInsertChar(), ScrnDeleteChar() to - correct potential out-of-bounds indexing (prompted by Debian bug - report #64713, which reported a problem with ICH escape sequences). - -
      • updates to config.sub and config.guess - Kevin Buettner <kev@primenet.com> for elf64_ia64 - Bernd Kuemmerlen <bkuemmer@mevis.de> and MacOS X. - -
      • for os390, add check for errno set to - ENODEV on failure to open /dev/tty when there is no controlling - terminal (patch by Paul Gilmartin). - -
      • fixes for building on Digital Unix 4.0 and AIX 4.2 - (patch from H Merijn Brand <h.m.brand@hccnet.nl>). - -
      • modify DECRQSS reply for DECSCL to additionally report if the - terminal is set for 8-bit controls. -
      - -

      Patch #136 - 2000/6/3 - XFree86 4.0b

      -
        -
      • add a resource (limitResize) - limiting resizing via the CSI 4 t and CSI 8 t sequences. - -
      • ignore out-of-bounds resize requests, i.e., where sign-extension - or truncation of the parameters would occur. -
      - -

      Patch #135 - 2000/5/29 - XFree86 4.0b

      -
        -
      • remove code introduced in #134 which made some backgrounds bold. - -
      • minor correction to format of updated $TERMCAP when adding - kb capability for ptyInitialErase logic. - -
      • improved test for SVR4 definition. -
      - -

      Patch #134 - 2000/5/28 - XFree86 4.0b

      -
        -
      • update URL's and mailing addresses, moved to http://dickey.his.com - and dickey@herndon4.his.com - -
      • correct missing quotes in CF_TTY_GROUP configure script macro in - case the script is run in batch mode. - -
      • modify ownership-check of log file to ignore the group ownership. - Otherwise xterm cannot create logfiles in directories with set-gid - permissions. - -
      • simplify the logic that reads termcap data. - -
      • add fallback definition for B9600 in case line speed definition - for 38400 is missing (report by Jack J Woehr <jwoehr@ibm.net>, - for OpenBSD 2.6). - -
      • fix: Set highlightColor, and select a region containing the text - cursor. If the window loses focus, the cursor becomes hollow, with - the region inside the cursor being background/foreground, unlike the - rest of the selection, which is foreground/highlight - (patch by Ross Paterson <ross@soi.city.ac.uk>). - -
      • add configure script tests to define SVR4, SYSV and USE_POSIX_WAIT, - which enables xterm to compile on Solaris 7 and SCO Openserver - without imake, though there are still a few features for the latter - which require sco to be predefined. - -
      • patches from Steve Wall: -
          -
        • add support for two Sun-specific function keys. These keys are - labeled F11 and F12 on Sun Type 5 keyboards, but return SunXK_F36 and - SunXK_F37. Support will only be compiled in if the header file - <X11/Sunkeysym.h> exists and contains the appropriate symbol - definitions. The keycodes for the DEC keycodes were arbitrary unused - codes, but the ones for the Sun keycodes are what cmdtool and - shelltool actually send. - -
        • add colorRV and colorRVMode resources to - allow specifying a color to use for reverse video, similar to the - existing UL, BD, and BL modes. - -
        • add alwaysUseMods resource, to override check if - alt or meta modifiers are used in - translations resource. Revamped the code to calculate - the modifier value, and included Meta if alwaysUseMods is TRUE, using - values 9-16. -
        - -
      • fixes for os390 (Paul Gilmartin): -
          -
        • regularize the definition of CONTROL() and remove an - acknowledged "trial and error" table. - -
        • translate "^?" into A2E(0177) which is the EBCDIC "DEL" - rather than plain 0177 which is the EBCDIC quotation mark. - -
        • modify xtermMissingChar() so that EBCDIC codes 128-159 - are not rendered as blanks by X server running on Solaris, which sees - those as control characters. - -
        • make debugging traces (configure --enable-trace) - work properly with EBCDIC. -
        -
      - -

      Patch #133 - 2000/5/2 - XFree86 4.0a

      -
        -
      • add substitutions in autoconf'd Makefile for CPPFLAGS, LDFLAGS and - AWK (reported by Neil Bird). - -
      • correct uninitialized childstat variable from patch - #131 in creat_as() function, which caused logging to not - work on Solaris, whose waitpid() function does not - initialize its parameter. Add check for EINTR on return from - waitpid() as well (reported by Neil Bird - <neil.bird@rdel.co.uk>). - -
      • remove a redundant check for working setuid() function - introduced in patch #132. Greg Smith reports that this does not work - as intended on os390. - -
      • change line speed from 9600bd to 38400bd, to accommodate people who - mistakenly use $TERM set to vt100, to reduce the effect of - padding associated with this terminal type. - -
      • add configure script check for IRIX 6.5's redefinition of baud - rates associated with struct termio, to correct a - situation where the baud rate was initialized to zero (reported by - Andrew Isaacson <adi@lcse.umn.edu>). - -
      • remove unused configure script check for VDISABLE. -
      - -

      Patch #132 - 2000/4/11 - XFree86 4.0a

      -
        -
      • undo an incorrect change from patch #113 caused the right scrollbar - to be positioned incorrectly when re-enabling it (analysis by - D Roland Walker). - -
      • add ctrlFKeys resource, replacing constant for adjusting - control-F1 to control-F12 to VT220-style F10-F20. The resource - changes the constant 12 to a default value of 10 (request by - Jim Knoble <jmknoble@pobox.com>). - -
      • correct ifdef'ing for conflict between definitions in AIX's - <sys/select.h> and <X11/Xpoll.h> (reported by Clint - Olsen). - -
      • add checks for return-values of getutid(), initgroups() and - setuid() in main.c, as well as modifying ifdef's for __osf__ to - include tty-group and WTMP logic (adapted from patch by Paul Szabo - <psz@maths.usyd.edu.au>) - -
      • modify resize.c to build and work on os390 (uses EBCDIC) - (adapted from patch by Phil Sidler <Phil.Sidler@airborne.com>) - -
      • use Ires(), Bres() and Sres() macros to simplify resource list in - charproc.c - -
      • resync with XFree86 4.0a: -
          -
        • correct a typo in os2main.c (Holger Veit, from 4.0a). -
        -
      - -

      Patch #131 - 2000/3/3 - XFree86 3.9.18b

      -
        -
      • improve logfile security (integrated patch by Branden Robinson) -
          -
        • make the creat_as() function more strict by using - O_EXCL rather than O_APPEND. -
        • fixes to make DEBUG ifdef's compile/run, including making the - debug logfile more unique by appending a timestamp to its name. -
        • include <term.h> in resize.c, to fix a missing-prototype - warning. -
        - -
      • modified creat_as() a little more, retaining the - ability to append to a logfile If the user specifies the name. - Also, check if the opened file (which patch #130 ensures is - owned by the effective user) is not writable by other users. - -
      • use creat_as() logic to make tek4014 screen-copy - more secure (noted by Branden Robinson). - -
      • ifdef'd some of Branden's changes to build/work on older machines. - -
      • correct missing initialization of the .mode flag in - ColorRes struct, from patch #129. This worked on Linux - because malloc() zeroes memory on that platform - (reported by Christian Weisgerber). - -
      • modify logic for deleteIsDEL resource so it has - internally 3 states: unspecified, true and false. If unspecified, - the keyboard type determines whether the Delete key transmits - <ESC>[3~ or \177, and the popup menu - entry reflects the internal state. Otherwise, the popup menu entry - overrides the keyboard type (suggested by Dr Werner Fink, to make it - simpler to set resources that imitate the legacy X11R6 xterm). -
      - -

      Patch #130 - 2000/3/1 - XFree86 3.9.18a

      -
        -
      • modify scroll-forw() and scroll-back() - actions, adding a third parameter which will direct xterm to ignore - the action when mouse reporting is enabled. This is needed for - the wheel mouse to be used to report to the application rather than - scroll the window. - -
      • add menu entry and action to allow disabling xterm's assumption - that the current font contains line-drawing characters if the - font cells 1-31 are nonempty. Some fonts may have other characters - (reported by Bruno Betro <bruno@iami.mi.cnr.it>). - -
      • add a check in creat_as() to ensure that the user - really owns the logfile that has been opened. - -
      • add logic to implement SCO function-keys. (This is really - incomplete, since I intend to revisit this and make xterm able to - emulate scoansi better than just the function-keys). - -
      • add configure script option --enable-sco-fkeys, minor related fixes - (patch by Dr Werner Fink). - -
      • fix typos in ctlseqs.ms (reported by Bram Moolenaar) - -
      • fix typo in sinstall.sh default for $TST_PROG (reported by - Paul Gilmartin <pg@sweng.stortek.com>) -
      - -

      Patch #129 - 2000/2/26 - XFree86 3.9.18a

      -
        -
      • improve initialization of ANSI colors by delaying allocation until - each color is first used. - -
      • remove ifdef that prevented colorBD/colorUL/colorBL resources from - working when 256-color configuration was built (reported by - Todd Larason). - -
      • fix some minor inconsistencies in terminfo (Debian #58530). -
      - -

      Patch #128 - 2000/2/17 - XFree86 3.9.18

      -
        -
      • correct logic for oldXtermFKeys resource, fixes a core - dump when attempting to set it from the command-line (reported by Dr - Werner Fink). -
      • correct ifdef for meta-sends-escap so configure --disable-num-lock - builds. -
      - -

      Patch #127 - 2000/2/12 - XFree86 3.9.17e

      -
        -
      • add resource, popup menu entry and control sequence to allow - changing the Delete key to send either DEL or the VT220-style - Remove escape sequence. - -
      • remove logic for metaSendsEscape that would allow xterm to send - <ESC>[3~ before a function key that would begin - with <ESC>[3~ (request by Christian Weisgerber). - -
      • add missing action and documentation for meta-sends-escape. - -
      • correct a few typos in ctlseqs.ms (incorrect code for Cyan color) -
      - -

      Patch #126 - 2000/2/8 - XFree86 3.9.17c

      -
        -
      • ensure that xterm will automatically activate the UTF-8 mode whenever - the name of the locale environment variable suggests that a UTF-8 - locale is in use (patch by Markus Kuhn). - This will help that by simply setting LC_CTYPE an - entire system can be switched over to UTF-8, without users having to - remember the UTF-8 command line options ("-u8", etc.) of the various - applications. Command line options and X resource entries can still - be used to override this default choice. - -
      • add old function-keys control sequences and popup menu entry, for - compatibility with legacy X11R6 xterm. - -
      • revert translation of editing keypad "Delete" key to legacy \177. - -
      • simplify the color-resource data expressions with macro COLOR_RES, - for later use in restructuring color initialization. - -
      • change encoding of wheel mouse (buttons 4 and 5) to avoid conflict - with legacy mouse modifiers (suggested by Bram Moolenaar). -
      - -

      Patch #125 - 2000/1/31 - XFree86 3.9.17c

      -
        -
      • make this work on OpenVMS - (integrated patch by David Mathog). - -
      • rename some functions, e.g., Index to - xtermIndex so that ports such as VMS which link - externals ignoring case will not have library conflicts (reported by - David Mathog). - -
      • correct logic of do_reversevideo(), which did not - update the corresponding popup menu check mark (reported by David - Mathog, this was a detail overlooked in patch #94). - -
      • change TRACE macro so semicolon is not within definition, making - indent and similar programs work better. - -
      • add depend rule to Makefile.in - -
      • modify logic of boldColors resource to suppress it if an extended - color control has been used, e.g., for 88-color or 256-color mode - (patch by Todd Larason). - -
      • revise logic that handles menus and input translation for keyboard - type so only one can be selected at a time. - -
      • restore kdch1=\177 for the Sun function-key type, and make the - the Delete key send DEL (\177) if the oldXtermFKeys resource is set. - -
      • rephrase logic and ifdef's for POSIX VDISABLE to avoid preprocessor - expression that will not compile on NetBSD/x86 1.4.1 (reported by - Takaaki Nomura <amadeus@yk.rim.or.jp>). - -
      - -

      Patch #124 - 2000/1/27 - XFree86 3.9.17b

      -
        -
      • change coding of editing keypad's "Delete" key to - <escape>[3~, in the default (Sun/PC) keyboard mode. - This makes the terminfo kdch1 capability independent of the - coding of the backarrow key, which sends either backspace (8) - or DEL (127). The reason for doing this (compatibility with - the screen program) outweighs the choice of DEL (127) - which was used in X11R5/X11R6 xterms. The screen - program translates whatever matches kdch1 into <escape>[3~, - even if it happens to be the stty erase character. - -
      • add encoding for control/?, to work around xmodmap or key - translations which may confuse backspace and delete. A control/? - will send DEL (127), and a control/H will of course send backspace - (8). - -
      • add encoding for kcbt to <escape>[Z (fixes Debian #54840). - -
      • minor correction to logic that encodes Sun and DEC function keys - to avoid sending an escape sequence if the key symbol is not found - in xterm's lookup table. - -
      • simplify ifdef's in main.c for POSIX VDISABLE so the "^-" pattern - is more likely to be implemented when imake configures xterm - (fixes Debian #55105). - -
      • change manpage to make it clearer what codes are sent by the - backarrow key. -
      - -

      Patch #123 - 2000/1/22 - XFree86 3.9.17a

      -
        -
      • add a note reserving OSC 51 for use in Emacs shell (request by - Rob Mayoff <mayoff@dqd.com>). - -
      • correct a missing backslash in xterm-vt220 termcap. - -
      • cleanup remaining quoted includes, preferring bracketed form. - -
      • minor configure-script macro updates from tin and vile. - -
      • add configure-script option for using utempter library, adapted - from Redhat 6.1 patch for XFree86 3.3.5 - -
      • resync with XFree86 3.9.17a: -
          -
        • correction to QNX support (Frank Guangxin Liu) -
        • some cosmetic changes that did not correct any reported problems. -
        -
      - -

      Patch #122 - 1999/12/28 - XFree86 3.9.16f

      -
        -
      • move the suggested wheel-mouse button translations into charproc.c - to simplify customization. Correct some minor logic errors in the - support for buttons 4 and 5, used for wheel mice (reported by - Bram Moolenaar). - -
      • implement metaSendsEscape resource, with corresponding - control sequence and menu entry. Like eightBitInput, this - causes xterm to send ESC prefixing the given key, but applies to - all keys and is independent of the 8-bit/7-bit terminal setting. - (requests by Alexander V Lukyanov and Marc Feeley). - -
      • correct potential indexing with negative subscript in udk_lookup(), - (reported by Ian Collier <Ian.Collier@comlab.ox.ac.uk>). - -
      • modify configure script that sets TERMINFO_DIR to use ${prefix} - rather than /usr if the --prefix option was specified (request by - Zdenek Sekera <zs@sgi.com>). - -
      • modify checks for repeat-character control sequence to test the - character class against xterm's state table, rather than the - isprint() macro (patch by Alexander V Lukyanov). - -
      • change several functions to macros to improve speed - -
      • two corrections to simulation of bold font via overstriking: -
          -
        • use clipping to avoid leaving trash at end of the text, and -
        • add brackets so wide-character logic does not fall-through - into the overstriking logic (reported by - Marc Feeley <feeley@IRO.UMontreal.CA>) -
        - -
      • add several entries to termcap file to make it have the same set - of aliases as the terminfo file. - -
      • scale the color values used for xterm-256color terminfo entry to - 0..1000, as expected by ncurses. - -
      • change xterm-r6 terminfo definitions for F1-F4 to match program. - -
      • Add QNX/Neutrino support (Frank Guangxin Liu - <frank@ctcqnx4.ctc.cummins.com>) -
      -

      Patch #121 - 1999/11/14 - XFree86 3.9.16c

      -
        -
      • change label on "Sun/PC Keyboard" popup menu entry to "VT220 - Keyboard", since the checked state corresponds to VT220 rather than - Sun/PC. - -
      • add configure test CF_UTMP_UT_XSTATUS to handle the variants of - utmp exit status (reports by Dave Ellement, Jeremie Petit, Tomas - Vanhala). - -
      • amend treatment of ALT key - (see patch #94) so that if ALT is used - as a modifier in key translations, then no parameter will be sent - in escape sequences for Sun/PC function keys (request by Dr Werner Fink). - -
      • modify default for OPT_I18N_SUPPORT to assume that - XtSetLanguageProc() is available in X11R5. -

        - Caveat: XtSetLanguageProc() was - added fairly late in the X11R5 patches, and some vendors shipped - buggy versions of this function (request by Tomas Vanhala). - -

      • correct configure macro CF_SYSV_UTMP to test-link with functions - consistent with the header, e.g., getutent() for utmp.h and - getutxent() for utmpx.h (reported by Greg Smith). - -
      • modify terminfo entry for xterm-xfree86 to reflect - modifiers for shift and control which (from a patch by Alexander V - Lukyanov). - -
      • modify terminfo entry for xterm-sun to match the - function-key definitions in ncurses. The pageup/pagedown and - related function keys correspond to the Sun keyboard, which does - not necessarily correspond with X's notion of those keys. - -
      • modify treatment of XK_Delete keysym so it transmits parameterized - VT220-style <ESC>[3~ if modifiers (shift, control - alt) are given (request by Alexander V Lukyanov). - -
      • corrected misspelled resource name in command-line option for - HP function keys. -
      - -

      Patch #120 - 1999/10/28 - XFree86 3.9.16c

      -
        -
      • refine the change to SGR_Background() in patch #119, - by not flushing the pending scrolling operation if the background - color is not actually changing. This combination occurs when using - color-ls to display a long listing, since each line ends with an SGR0 - which affects only the foreground color. The unnecessary flushing - made it noticeably slower (reported by D Roland Walker - <walker@pobox.com>). - -
      • remove obsolete documentation about modifiers which can be returned - in mouse tracking mode, and modify logic to ignore modifiers other - than the existing ones, e.g., NumLock (prompted by discussions with - Christian Weisgerber and Brad Pepers <brad@linuxcanada.com>). - -
      • use free bit from obsolete shift-modifier coding of mouse tracking - button events to encode buttons 4 and 5, e.g., for a wheel mouse - (requests by Brad Pepers and Bram Moolenaar). - -
      • correct a place where the ptyInitialErase logic did not set the - backarrowKey state, and modify it further to use tgetstr() rather - than parse the termcap data returned from tgetent() so the - ptyInitialErase logic will work when xterm is linked with a terminfo - library (based on a patch by Dr Werner Fink <werner@suse.de>). - -
      • fix definition of HAVE_UTMP_UT_HOST for ISC configuration - (patch by Michael Rohleder). - -
      • improve configure script's utmp tests (based on reports by Greg - Smith for os390, and David Ellement for HPUX). - -
      • modify sinstall.sh to use uid=0 rather than 'root' to determine if - the installer is privileged. This is needed on some systems since - more than one account may be privileged (report by Greg Smith). - -
      • add an application resource, messages (and a - corresponding -/+mesg option) which controls the initial permission - on the terminal: if messages is set to true (the default), behavior - is as without the patch; if it is set to false (as per -mesg), the - terminal is opened in mode 0600, thus producing the effect of the - mesg n command. This is useful for users who want to - redirect all their messages to one particular xterm: it is more - pleasant to do this with xterm resources than with explicit calls to - the mesg program (patch, description by David Madore - <david.madore@ens.fr>). -
      - -

      Patch #119 - 1999/10/16 - XFree86 3.9.16c

      -
        -
      • add responses (DA and DSR) for DEC locator mode - -
      • add coding for ANSI color to DA response - -
      • implement UTF-8 translation for Media Copy (print) operations. - -
      • implement vt320 control sequences for Print Composed Main Display - and for Print All Pages. The latter directs xterm to print the - current screen as well as the scrollback buffer. - -
      • correct error in _GNU_SOURCE configure test, which left it always - defined. - -
      • add more information, i.e., with strerror for some system calls in - the main program which may fail due to insufficient permissions - (prompted by a problem report for -C by Jeremie Petit - <Jeremie.Petit@digital.com>). - -
      • add workaround for conflict between <X11/Xpoll.h> and - <sys/select.h> on AIX 4.3 (Richard Griswold - <griswold@acm.org>). - -
      • add configure script test to resolve conflict between between - <X11/Xpoll.h> and <sys/select.h> - -
      • modify translation of UTF-8 sequences to reject "overly long" - variations (patch by Markus Kuhn). - -
      • remove utf8controls resource, since Markus' change - removes the corresponding logic. - -
      • correct a case where colors were not rendered properly. This - happened when an application inserted several lines, then changed - colors. If this was done all in one write, then there would be no - intervening refresh, and the new color was applied to the pending - scrolling operation which was awaiting the next refresh (reported - by Stephane Chazelas <Stephane_Chazelas@Raytheon.com>). - -
      - -

      Patch #118 - 1999/10/5 - XFree86 3.9.16b

      -
        -
      • refine configure test for utmp versus utmpx, to build on HP-UX 10.x - (reported by David Ellement). - -
      • move the configure check for const after the check - for ANSI C compiler options, since those may be required to make - it work properly on HP-UX. - -
      • add configure test for defining _GNU_SOURCE - -
      • correction to -hold option, ensure that if data is already - in the output buffer that it will be displayed before closing the - PTY. - -
      • move the configure checks for setuid install of xterm into a script - to avoid installing it setuid'd to a non-root user (reported by - Adam Sulmicki <adam@cfar.umd.edu>). - -
      • correct configure script's check for termcap.h to avoid using - ncurses' version of it on systems that have a working - tgetent() function. This is needed to make - resize work properly. - -
      • fix some typography in ctlseqs.ms description of DEC locator events - (reported by Steve Wall). -
      - -

      Patch #117 - 1999/9/29 - XFree86 3.9.16b

      -
        -
      • change order of tests in configure script for utmp and utmpx - to test utmpx first, to compile on Solaris (reported by - Leena Heino <liinu@uta.fi> - and Patrik Hagglund <patha@ida.liu.se>). - -
      • add a configure test for utmp.ut_xtime, needed for SCO Openserver, - and for lastlog, needed for Redhat 6.0, to refine the utmp/utmpx - auto-configure. - -
      • remove a spurious comma in an #undef (reported by - David Green <greendjf@cvhp152.marconicomms.com> and - David Ellement <ellement@sdd.hp.com> both on HP-UX, whose - compiler does care about syntax). - -
      • change ifdef's using __CYGWIN32__ to __CYGWIN__ (reported by Suhaib - M. Siddiqi <Ssiddiqi@InspirePharm.Com>, who is told that the - next Cygnus release will drop that symbol in their next release). - -
      • minor cleanup of ifdef's for makeColorPair (patch by Steve Wall). - -
      • work around problem observed in XFree86 3.3.5 - (patch by Alexander V Lukyanov, Mozilla #5419). - From the problem report: -
        - xterm consumes cpu when selecting text with mouse (holding - down left mouse button) and when a program working under the - xterm outputs something to stdout. -

        - Easy way to reproduce:
        - while :; do echo aaa; sleep 1; done
        - (while this runs, select text and hold down left mouse button) - watch cpu load.
        - release left mouse button - spinning stops. -

        -
      - -

      Patch #116 - 1999/9/25 - XFree86 3.9.16a

      -
        -
      • modify warning if change-ownership of PTY fails; some - configurations may not happen to have old-style pty's (reported by - Bob Maynard). - -
      • improve check in configure script for group ownership of installed - xterm; some platforms use the -g option of ls to toggle group off - rather than on (reported by Greg Smith). - -
      • minor improvement to toolbar geometry, to make it not resizable. - This still is not satisfactory (but is usable) since the toolbar - overlaps the xterm widget if the window is resized to make it - smaller. It appears that some work is needed for the xterm widget's - geometry management to make it function properly. - -
      • implement configure script tests for utmp, tty group. - -
      • implement -hold option, allowing users to retain the - window after a shell has exited (this is recently an FAQ, but - prompted by a comment by Joachim Plaettner-Hochwarth - <plaettner@aem.umn.edu> in comp.unix.programmer, that the IRIX - winterm provides this option). - -
      • add support for DEC Locator control sequences for xterm - (integrated patch by Steve Wall): -
        -
        -		DECEFR, "Enable Filter Rectangle"
        -		DECELR, "Enable Locator Reports"
        -		DECSLE, "Select Locator Events"
        -		DECRQLP, "Request Locator Position"
        -	  
        - This allows the xterm mouse to be used with applications that use the - DEC Locator sequences, such as VAX Tpu, or SMG$ based applications. - -
      • improve print action (patch by Matthias Baake). From his notes, -
          -
        • Bug 1
          - Underlined text is preceded by ESC [0;2m . This should be ESC [0;4m , - ESC [2m doesn't seem to have any effect. (print.c/send_SGR) - -
        • Bug 2
          - The check for the last non-empty column (while (last > 0) ... in - print.c/printLine) omits the rightmost column of the screen, the loop must - start with last = screen->max_col+1 instead of last = screen->max_col. - -
        • Bug 3
          - Any attributes of the first character (and of all immediately following - characters with the same attributes) are ignored. The variable attr - (print.c/printLine) should be initialized with 0, not with *a & SGR_MASK. -
        -
      - -

      Patch #115 - 1999/9/18 - XFree86 3.9.16a

      -
        -
      • integrated changes by Steve Wall to implement an 88-color model - for systems where 256-colors cannot be allocated. - -
      • when 256-color configuration is compiled, colored bold and - underlining is not available; ifdef'd to avoid possible odd effects - in this case (reported by Steve Wall). - -
      • add resource cacheDoublesize, to limit the caching of font - information for double-sized characters. This addresses a problem - reported by Aryeh Koenigsberg for X terminals with limited font - memory. - -
      • modify treatment of line-drawing characters in UTF-8 mode so that - the Unicode values are used rather than the C0 codes for storing the - translated characters (request by Markus Kuhn). -
      - -

      Patch #114 - 1999/9/15 - XFree86 3.9.16

      -
        - -
      • add configure script checks for Athena headers and libraries under - /usr/contrib to work on HPUX (reported by several people: - David Nixon <djn@csc.liv.ac.uk> - Aryeh Koenigsberg <aryeh.koenigsberg@telrad.co.il> - Johannes Mähner <johanm@camline.com> - Andrew Gaylard <andrew.gaylard@bsw.co.za>). - -
      • add check to configure script if xterm is installed setgid rather - than setuid, since wtmp and utmp may be installed with group-writable - permissions other than root (based on Debian bug report #7112 by Bo - Branten <bosse@ing.umu.se>). - -
      • rewrote logic that removes data from termcap entry, e.g., for - titeInhibit, to make it less likely to remove the wrong data. - -
      • correct logic which checks for missing characters used for line - drawing. The 0 character was tested unnecessarily, leading to - some inefficiency when rendering. - -
      • change termcap capability which is used as input or output of - ptyInitialErase logic from kD to kb. - Christian Weisgerber <naddy@mips.rhein-neckar.de> pointed out - in effect that kD (in terminfo kdch1) should - correspond to the control sequence for dch1, which deletes - from the current position toward the right. - -
      • check for failure to change ownership of the PTY device and warn - when xterm is running setuid'd to root. This was reported to happen - on the FreeBSD/NetBSD/OpenBSD systems as a result of the chflags() - call. - -
      • add xterm-noapp terminfo entry to illustate a nominally - bash-compatible terminal description. -
      - -

      Patch #113 - 1999/8/15 - XFree86 3.9.15b

      -Several fixes. The main one is a first draft of pulldown menus. It's not -complete (I have some minor/annoying geometry problems to correct), but is -usable. Once it's complete I plan to add a menu to support additional -selections that won't fit on the current popup menus. Also, this fits into my -longterm plan to allow configuring with Motif libraries. - -
        -
      • correct error in input conversion for NRC mode (reported by - Stefan Traby <stefan@sime.com>). - -
      • fix initialization of num_lock data in Misc struct (since those - fields of the reference widget aren't initialized), and add logic to - deal with XVision whose NumLock key does not transmit but does alter - keypad state. - -
      • correct a missing return-value in get_pty(), for SCO - -
      • add E2A fix for backspace (patch by Greg Smith), i.e.,
        - #define VAL_INITIAL_ERASE A2E(127) - -
      • correct foreground color within cursor outline when the - window is unfocused (reported by Stephane Chazelas). - -
      • corrected position of scrollbar set in ResizeScrollBar(), which - left it positioned incorrectly if the right scrollbar were enabled - from the popup menu but was not initially enabled. - -

        - I have noticed some additional problems with right-scrollbar on - X11R5 which I will correct later. - -

      • integrate changes by Jean-Claude Michot for QNX from XFree86 3.3.4c - -
      • add resources menuBar/MenuBar, menuHeight/MenuHeight for later - use in toolbar geometry. - -
      • add configure option --enable-toolbar - -
      • add missing definition to make ziconbeep logic not compile-in when - configure script disables it. - -
      • add configure-check for input-method support in X libraries -
      - -

      Patch #112 - 1999/7/17 - XFree86 3.9Pw

      -
        -
      • add null-pointer check to FlushLog(), fixes a core dump when both - -l and -lf options are used when xterm is configured with wide-character - support. - -
      • remove "ISO" case for SD, which was due to a typographical error in - ECMA-48 (reported by Paul Williams <paul@celigne.co.uk> for - vttest). - -
      • add "FILES" section to manpage. - -
      • generate header file to initialize default resources for colors - 16-255. - -
      • fixes for os390 (Greg Smith): -
          -
        • add README.os390 - -
        • use the pty_search() function to find an available pty/tty pair. - -
        • move E2A() call out of getXtermCell() to SaveText() function - so it will be available in all configurations. -
        - -
      • patches by Todd Larason: -
          -
        • enable SGR 48 5 in ISO color mode, not just 256 color mode - -
        • change configure's --disable-256-color option to - --enable-256-color, to match its effect - -
        • fix OSC 4 xx ? (report ansi color) to report a string which can - actually be used to set the color back - -
        • fix OSC 4 xx yy (change ansi color) to not allow setting colors > - 15 in 16 color mode - -
        • simplify the COLOR_ settings a bit in ptyx.h, along with setting - NUM_ANSI_COLORS needed for #1 and #4 above - -
        • correct string-terminator code passed for reference to OSC - responses; when in 7-bit mode, only the final byte of ST was seen. - -
        • Allow multiple color #;name pairs in OSC 4, - and document changes to match. -
        -
      - -

      Patch #111 - 1999/7/10 - XFree86 3.9Pw

      -
        -
      • add control sequences for specifying the RGB value of the ANSI - colors, and for configuring with 256 colors (patch by Todd Larason - <jtl@molehill.org>). I made the default configuration to - 16-colors, because xterm uses the default color map (which has only - 256 colors). - -
      • correct an error in DCS $ q m reporting for colors 8-15 (Todd - Larason). - -
      • add test/demo script for double size characters. Used this to - test/correct display of double size characters that should wrap, - underlined double size characters. - -
      • increased cache size for double size fonts to 8, to allow for both - normal and bold fonts (discussion with Aryeh Koenigsberg - <aryeh.koenigsberg@telrad.co.il>). - -
      • add fixes for port to OS390 aka MVS - (integrated patch from Greg Smith <rys@epaibm.rtpnc.epa.gov>). - OS390 uses EBCDIC rather than ASCII. - -
      • correct an off-by-one in binary search limits in keysym2ucs.c (Markus - Kuhn). - -
      • implement logging for UTF-8 mode. The output is written in UTF-8 form. -
      - -

      Patch #110 - 1999/6/29 - XFree86 3.9Pu

      -
        -
      • If colorMode is enabled by default, compile-in default resources to - match the colors listed in XTerm-col.ad (this should fix a - longstanding FAQ). - -
      • added new OSC 3 ; PROPNAME=VALUE ST escape - sequence to set an arbitrary X property on the top level xterm X11 - window. Omit "=VALUE" to delete the X property (patch by Greg Badros - <gjb@cs.washington.edu>). - -
      • change internal flag used for utf8controls resource - so we allow 31-bit range of characters (suggested by Thomas Wolff). - -
      • add check for 16-bit characters in OSC strings, change them to '?' - (reported by Thomas Wolff). - -
      • modify logic of same_font_name() to avoid trying to interpret both - parameters as wildcard patterns. That does not (cannot) work, and in - some instances the font server will return unresolved wildcards for - the normal or bold fontnames, making them match inadvertently, - triggering the fallback overstrike logic (reported by Tim Adye). -
      - -

      Patch #109 - 1999/6/23 - XFree86 3.9Pt

      -
        -
      • correct range-check from patch #108, which resulted in not being - able to select from the scrollback buffer (reported by Tim Adye - <T.J.Adye@rl.ac.uk>) - -
      • correct "no available ptys" problem with Cygwin B20.1 (patch by Tim - Adye). - -
      • modified install-ti rule in Makefile.in to allow override of the - terminfo directory when doing a "make install", i.e., by assigning - to TERMINFO_DIR (request by Zdenek Sekera <zs@sgi.com>). - -
      • added install-full rule to Makefile.in - -
      • resync mkdirs.sh and install.sh scripts against current autoconf - -
      • implement $(DESTDIR) in Makefile.in, making it simple to install - xterm and associated files into a directory just for packaging a - binary release (suggested by CaT <cat@zip.com.au>). - -
      • change IChar type to unsigned, rather than unsigned short, making - room for a flag to keep with 16-bit characters to prevent them from - being interpreted as C0 or C1 controls (reported by Thomas Wolff). - -
      • correct a typo from patch #107, incorrect array name, in the - filterUTF8 function (patch by Bruno Haible <haible@ilog.fr>) - -
      • add utf8controls resource to specify whether xterm should - interpret 16-bit characters unpacked from UTF-8 form as control - characters if they happen to fall into that range. This behavior - is left unspecified by the Unicode standard (request by Thomas Wolff). - -
      • modify handling of OSC to recover if application sends 16-bit - characters with codes above 255. We cannot display them as is, but - translate out-of-range characters to a '?' (reported by Thomas - Wolff). -
      - -

      Patch #108 - 1999/6/19 - XFree86 3.9Ps

      -
        -
      • add a range-check to LastTextCol(), to guard against indexing - before the beginning of the scrollback buffer. This appears to - happen with certain fonts under X11R5 (reported by Stephane Chazelas - <Stephane_Chazelas@Raytheon.com>). - -
      • implement resource boldMode, to allow disabling the - simulation of bold fonts when the bold and normal fonts are not - different (requested by Will Day <willday@rom.oit.gatech.edu>). - -
      • change the atom "UTF-8" to "UTF8_STRING", and fixes a few bugs in - the UTF-8 selection (patch by Juliusz Chroboczek). - -
      • correct logic of binary-search in keysym2ucs.c (patch by Markus - Kuhn). - -
      • add special interpretation of keysym codes above 0x1000000 as - the corresponding UCS value plus 0x1000000 (patch by Markus Kuhn). -
      - -

      Patch #107 - 1999/6/12 - XFree86 3.9Pq

      -
        -
      • Two changes from Stephen P Wall. - From his description: -
        - The first change is simple - I added ESC[3J to erase the stored lines - above the screen. That's what the changes to util.c and ctlseqs.ms - are. -

        - The second change is to get the blinking cursor working. I took out - the cursorBlinkTime resource, and put in cursorBlink (Boolean), - cursorOnTime (time cursor is on in msecs) and cursorOffTime, and added - a cursorblink item to the vtMenu to enable/disable it. -

        - -
      • improve selection (integrated patch by Juliusz Chroboczek). - From his description: -
        - With this patch, selection conversion works properly: -
        -	ISO 8859-1 xterm -> ISO 8859-1 xterm (transferred as STRING);
        -	ISO 8859-1 xterm -> UTF-8 xterm (transferred as STRING);
        -	UTF-8 xterm -> ISO 8859-1 xterm (transferred as STRING);
        -	UTF-8 xterm -> UTF-8 xterm (transferred as UTF-8).
        +
        +
        +
        +
        +  
        +
        +  XTERM - Change Log
        +  
        +  
        +  
        +
        +
        +
        +  
        + +

        Copyright © 1997-2012,2013 by Thomas E. Dickey

        +
        + +

        Contents

        + +

        Here is + the latest version of this file.

        + +

        It began as a list of the changes that I made for xterm, using + the notes that I added when submitting a patch. You should note + that other changes were made as well, by other people, to fix + bugs and correct ifdef's for portability. Until mid-2006, most of + these were summarized in the XFree86 + CHANGELOG).

        + + + +

        Patch #297 - + 2013/09/10

        + +
          +
        • modify check for missing cells in bitmap font to work + around terminus 10646 encoding, which is mostly missing, add + assumeAllChars resource to provide the older + behavior.
        • + +
        • modify macros used to check for missing cells in bitmap + fonts to pick up a long-overlooked improvement made to xfd in + XFree86.
        • + +
        • improve workaround for groff versus ASCII-equivalents; + patch #185 had overlooked Xft + configuration (reported by anonymous user on Arch Linux + forum).
        • + +
        • review/extend DECNRCM support (prompted by + report by Hayaki Saito asking about the two "A" codes). + +
            +
          • make pasting of DECNRCM data work by translating the + pasted data into the selected encoding.
          • + +
          • limit mode changes to VT220 and up.
          • + +
          • ignore SCS for National Replacement Characters if + DECNRCM is not set.
          • + +
          • add tables and logic to decode SCS controls ending with + "%" and one additional character. This expects the parsing + of SCS to VT320.
          • + +
          • also added parsing for SCS of DEC Supplemental and DEC + Technical, which are for VT2xx and VT3xx respectively.
          • + +
          • implement VT220 Multinational character set "GR" aka + "DEC Supplemental Graphic".
          • + +
          • DEC Technical character set based on vt100.net + description.
          • + +
          • implement Portuguese NRC.
          • + +
          • provide for temporarily switching to/from NRC mode from + UTF-8 mode when DECNRCM is set or reset.
          • +
          +
        • + +
        • minor fix to assert's found while testing examples from + ttdoda's + slrm-test1.txt.
        • + +
        • modify DECLRMM to not update the cursor + position (report by Iwamoto Kouichi forwarded by Hayaki + Saito).
        • + +
        • modify cursor-position report to take origin-mode into + account (report by Hayaki Saito, see also iTerm2 pull + request 129).
        • + +
        • correct off-by-one comparison in when handling + carriage-return at left margin (patch by Iwamoto Kouichi, + forwarded by Hayaki Saito).
        • + +
        • improve handling of faceName resource when a + "size=" property is embedded in it, by using that size to + replace the default faceSize resource. This lets + xterm honor the other faceSize resources (report by Jens + Schweikhardt).
        • + +
        • improve OSC 52 selection-data by setting its timestamp + to correspond to the most-recent event received by xterm, to + ensure that calls to XtOwnSelect succeed even if + the selection is manipulated solely through the keyboard + (prompted by patch by Richard Tollerton).
        • + +
        • change configure-script defaults for "luit" and + "wide-chars" options to match the values used in the imake + configuration, to lessen user surprise if they are accustomed + to building xterm using imake(report by Andries E + Brouwer).
        • + +
        • improve the imake-related configuration's check if xterm is + started in a locale that uses UTF-8 encoding. Before, this + checked the locale settings only for "UTF-8", now it checks + ignoring case for "UTF-8" and "UTF-8" (report by Andries E + Brouwer).
        • +
        + +

        Patch #296 - + 2013/07/10

        + +
          +
        • improve experimental sixel feature (patch by Ross + Combs).
        • + +
        • modify delimiter in configure macro used to add a library + after a given library to avoid confusion with -Wl + pass-through options to linker (NetBSD #48031).
        • + +
        • fix quoting in expression used to trim extra libraries from + patch #295 changes (report by Thomas + Klausner).
        • +
        + +

        Patch #295 - + 2013/07/06

        + +
          +
        • adjust order of libraries to work around incomplete symbol + resolution when using --as-needed option + (ArchLinux #36047).
        • + +
        • minor fix for plink.sh, for IRIX64.
        • +
        + +

        Patch #294 - + 2013/07/05

        + +
          +
        • add note in ctlseqs.ms for CPR response pointing out a + potential point of confusion with the string sent by a modified + F1 key (suggested by Bram Moolenaar).
        • + +
        • improve plink.sh by checking if the linker + supports the --as-needed option (suggested by + David Philippi).
        • + +
        • improve clearing for private mode 1049 when switching to + the alternate screen (Debian #711758).
        • + +
        • amend fix from patch #292 by + removing now-unneeded chunk which introduced problem in + selection (Debian #714527).
        • + +
        • add definition to optionally override compiled-in class for + xterm from makefile, needed for test-packages.
        • + +
        • add configure option + --enable-sixel-graphics
        • + +
        • add experimental support for sixel graphics (patch by Ross + Combs).
        • +
        + +

        Patch #293 - + 2013/05/27

        + +
          +
        • modify sample xterm.spec to use newer icon
        • + +
        • add configure option --with-icon-symlink to + work around systems which map icon requests for to a single + "xterm" icon, but neglect to install the icon needed for window + decorations (report by H Merijn Brand).
        • + +
        • improve parameterizing of sample xterm.spec
        • + +
        • amend fix for printer from patch + #280, removing a reset of the signal handler for + SIGCHLD (report by Joe Julian).
        • + +
        • set environment variable XTERM_FILTER if a + locale-filter is used.
        • + +
        • enable DEBUG logic when + --enable-trace configure option is given.
        • + +
        • improve description of initialFont, + set-vt-font and set-tex-text in + manpage (Debian #707899).
        • + +
        • fix regression from patch #292; + selecting a word that ended at the right margin without + wrapping would not select the last cell (report by Christian + Weisgerber).
        • +
        + +

        Patch #292 - + 2013/04/25

        + +
          +
        • add limit-check when double-click selects a word; if the + saved-lines were scrolled back and the word selected wrapped at + the screen's lower right corner, an assertion was triggered + (patch by Taketo Kabe).
        • + +
        • correct limit-check in unsaveEditBufLines, + fixing a case where enlarging the terminal size could show a + blank line where there actually is available text (patch by + Bertram Felgenhauer).
        • + +
        • add PasteControls feature to + allowWindowOps which by default disallows pasting + control characters other than formatting such as carriage + return (discussion with Hayaki Saito).
        • + +
        • fix typo in ctlseqs.ms for DECRQM response (patch by + Emanuele Giaquinta).
        • + +
        • update default shown in configure --help + message for --with-terminal-id option (patch by + Andres Perera).
        • + +
        • rename script/preprocessor variables used for substituting + the backarrowKey default value for consistency + (patch by Andres Perera).
        • + +
        • set umask to 077 before creating debugging-trace + files.
        • + +
        • add configure option --disable-openpty to + control whether openpty() may be used in preference to + posix_openpt().
        • + +
        • improve workaround from patch #279 + for BSD systems which do not complete initialization until both + sides of the pseudoterminal are opened, by preferring openpty() + function over posix_openpt() when available (report by + Christian Weisgerber).
        • +
        + +

        Patch #291 - + 2013/02/26

        + +
          +
        • add validity check for xterm widget parameter to + AlternateScroll function, needed to handle wheel + mouse events in the scrollbar area since patch #282 changes which introduced + alternateScroll feature (Redhat #874327).
        • +
        + +

        Patch #290 - + 2013/02/12

        + +
          +
        • revert of patch #282 change was + incomplete (report by Jim Reisert).
        • + +
        • fix typo in manpage (report by Vincent Lefevre).
        • +
        + +

        Patch #289 - + 2013/02/08

        + +
          +
        • revert the patch #282 change which + restored "lost" text after shrinking/growing the screen size. + If the screen was updated between the two resizing operations, + unexpected text might be shown at the end (report/testcase by + Joe Peterson).
        • + +
        • reverse the arrow-keys sent for + alternateScroll to match the usage in browsers + (suggested by Dieter Roelants).
        • + +
        • modify mouse reports to consistently indicate motion events + whether or not a button is pressed. Old behavior (since + patch #127 modified encoding for wheel + mouse) showed only that the button was released if no button + had been pressed (report by Andy Koppe).
        • + +
        • correct and improve behavior for SGR 1006 mouse protocol on + button release in any-event mode. Initial implementation in + patch #277 left internal state showing + the last button pressed when reporting motion events. It now + keeps track of all buttons which have been pressed and + released, showing the lowest remaining button by number in the + response (reports by Hayaki Saito, Andy Koppe).
        • + +
        • fix inconsistency between TermColors and + OscTextColors enums which interchanged values for + tektronix cursor color and highlight foreground in control + sequences in patch #225 (report/patch + by Peder Stray).
        • + +
        • fix inconsistent use of noreturn-attribute in + Exit function which interfered with clang + --analyze.
        • + +
        • remove incorrect free used in computation of + XTERM_SHELL variable, from Coverity fixes in + patch #288 (FreeBSD #175782).
        • + +
        • add --with-valgrind option to configure script + for consistency with my other programs.
        • + +
        • update table of ambiguous width characters in wcwidth.c + based on Unicode 6.2.0
        • + +
        • update table of combining characters in wcwidth.c based on + Unicode 6.2.0
        • + +
        • update precompose.c based on Unicode 6.2.0
        • +
        + +

        Patch #288 - + 2013/01/09

        + +
          +
        • fix a special case in ShowCursor where the + foreground and background colors of the current position are + the same. In that case, choose the further of the window's + foreground and background colors for the cursor color.
        • + +
        • modify alternateScroll feature added in + patch #282 to use either + CSI or SS3 according to the cursor + keys application mode setting, to simplify using it in vi, etc. + (suggested by Dietar Roelants).
        • + +
        • revise manpage for resize to clarify the + changes which resize may make to the terminal + settings as well as to the terminal itself.
        • + +
        • remove code such as struct ttysize, used for + SunOS 3 and 4.
        • + +
        • modify configure script and makefile to check for + groff and suppress groff-specific rules if groff + is not found.
        • + +
        • modify ctlseqs.ms and makefile to work around bugs in + grohtml which cause ".png" files to be truncated + when producing html documentation.
        • + +
        • modify suffix rules for "make docs" to make the names of + the generated ".png" files predictable, helping to work around + longstanding problems with this feature of groff—none of + its releases work for all of xterm's tables..
        • + +
        • correct typo in ctlseqs.ms for DECIC and DECDC; the + character preceding the final "~" is an ASCII + single-quote "'" rather than a space (report by + Paul LeoNerd Evans).
        • + +
        • update CF_GCC_VERSION macro, handling both Debian and + Darwin.
        • + +
        • improve configure script checks for the + --with-desktop-category option. After patch #280 changes, if no value was given for + this option, and no existing desktop files found for + comparison, the incorrect "auto" value was passed into the + generated desktop file (report by Julien Cristau).
        • + +
        • modify sample build-scripts to disable check for + imake due to code-rot in Xorg.
        • + +
        • add -v command-line option to + resize, reporting the same version string as + xterm and the two shell-wrappers.
        • + +
        • make name-transformation apply to other occurrences of + resize, other manpages.
        • + +
        • special-case the name-transformation in xterm's manpage in + the NAME section so that the result works with + makewhatis (report by Julien Cristau).
        • + +
        • modify install-rules for manpages to put each program's + respective transformed name into the header rather than + xterm's.
        • + +
        • remove deprecated files: proto.h, os2main.c
        • + +
        • minor fixes based on Coverity scan, including: + +
            +
          • correct caching of Atom value for the font menu's + "Selection" entry.
          • + +
          • ensure that utmp/utmpx calls do not depend upon + trailing nulls in the ut_id and + ut_line values.
          • +
          +
        • +
        + +

        Patch #287 - + 2012/11/25

        + +
          +
        • fix a case where in_put() loop could continue when it has + found an X event rather than the pty, causing the pty-read to + be delayed (patch by Balazs Kezes).
        • + +
        • add option to pointerMode resource and + corresponding control sequences to allow text-cursor to remain + hidden if the pointer leaves/enters the window via accelerator + keys. Ordinary motion within the window restores the pointer + (prompted by patch by Balazs Kezes).
        • + +
        • remove special case of modifiers for the + Mode_switch and XK_ISO_Level3_Shift + from patch #223. Verified that the + conflict which this was intended to resolve does not happen for + normal compose- or modeswitch-handling (prompted by patch by + Balazs Kezes, Debian #638694).
        • + +
        • modify the handling of focus-change events to ignore those + whose detail is NotifyPointer, since those are + sent in addition to focus-change events directed to the old/new + windows having focus. In particular, this prevents the + urgency-hint from being reset inadvertantly (prompted by patch + by Balazs Kezes).
        • + +
        • modify description of iconName in manpage to + make it clearer that this resource does not specify the + filename of an icon (discussion with Ian Collier).
        • + +
        • modify iconHint resource to allow suppressing + the built-in icon by setting this to "none" (discussion with + Ian Collier).
        • + +
        • make -iconic option work with the toolbar + configuration.
        • + +
        • correct initialization of window manager hints used to set + the icon-pixmap. That detail from patch + #282 overwrote state used to control the + -iconic command-line option (report by Ian + Collier).
        • + +
        • fix paste64 feature for the case where the selection comes + from the current terminal. The selection callback can happen + after the reply is partly built, making it necessary to flush + the reply-buffer to keep things in the proper order (report by + Ailin Nemui).
        • + +
        • reject command-line options which are longer than the + options in xterm's table, to avoid mismatches (Redhat + #875305).
        • + +
        • correct attribution for patch #282 + changes.
        • +
        + +

        Patch #286 - + 2012/10/29

        + +
          +
        • fix minstall.in to work with "make docs" rule, + so that patch number appears in the corresponding generated + documentation.
        • + +
        • modify minstall.in to keep the name shown in + the heading consistent with any renaming, e.g., for + test-builds.
        • + +
        • check for misconfigured printerCommand + resource on the first use, warn and disable it if it does not + specify an executable command (Debian #691642).
        • + +
        • improve check for window-manager name needed to establish + usable default for activeIcon resource. This works around a + scenario where gdm does incomplete cleanup, + leaving window properties that refer to windows which no longer + exist (Redhat #869959).
        • +
        + +

        Patch #285 - + 2012/10/23

        + +
          +
        • add/adapt FreeBSD ports files for test-building.
        • + +
        • modify minstall.sh to use the patch-number and + date in the manpage footer.
        • + +
        • add check for failure to allocate the fg/bg colors at + startup, e.g., misconfiguration. Work around by setting both to + the default colors (suggested by Scott Bertilson).
        • + +
        • amend change for patch #280 which + added modifyKeyboard, to make + modifyOtherKeys work (report by Ailin Nemui).
        • + +
        • add query-colors.pl example for + OSC 4.
        • + +
        • correct mis-applied fix for minstall.sh (report by Miroslav + Lichvar).
        • +
        + +

        Patch #284 - + 2012/10/14

        + +
          +
        • amend configurability changes for icons from patch #283, moving the new functionality to + the iconHint resource to avoid conflict with + existing uses of the iconName resource in the + Shell widget (report by Emanuel Haupt).
        • + +
        • fix documentation errata reported by Miroslav Lichvar: + +
            +
          • correct manpage default for allowTcapOps + (see patch #243
          • + +
          • modify documentation for configure + --enable-backarrow-key to match the script + (see patch #280).
          • + +
          • fix typo in minstall.sh in patch #283, which made the leading-cap + "Xterm" become "xterm" (patch by Miroslav).
          • +
          +
        • + +
        • fix two typos in configure.in from patch #283 changes; one broke the + --regex configure option (report by H Merijn + Brand).
        • +
        + +

        Patch #283 - + 2012/10/09

        + +
          +
        • modify makefile and script to generate appropriate renaming + s/xterm/xterm-dev/ for test-package's manpage.
        • + +
        • improve makefile rules for installing/uninstalling pixmap + files, to include the newer mini- and filled- variants.
        • + +
        • clarify change in manpage regarding patch #282 change to always set a + window-decoration icon, even if iconName is not + set.
        • + +
        • add a fourth flavor of window-decoration icons, + "filled-xterm" for a monochrome xterm with filled + interior.
        • + +
        • use shape-mask to improve contrast of the window-decoration + icons.
        • + +
        • minor changes to icon colors to improve contrast on + bright-mud backgrounds.
        • + +
        • drop configure checks for memmove versus bcopy, and + strerror function; all currently tested platforms support + these.
        • + +
        • cleanup configure macros, as done in byacc 20121003.
        • + +
        • improve configurability of the built-in icon selectable via + the iconName resource.
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #282 - + 2012/09/28

        + +
          +
        • improve configure check for + XkbKeycodeToKeysym, fixing a regression on some + older systems in the patch #280 + changes.
        • + +
        • add clarification in manpage for + alwaysBoldMode and veryBoldColors + resources (prompted by Derek Martin question about using the + former with TrueType fonts).
        • + +
        • add alternateScroll resource and corresponding + control sequences which modify the scroll-forw and + scroll-back actions: when the alternate screen is + displayed, wheel mouse up/down will send cursor keys (Debian + #683942).
        • + +
        • improve rendering for the case when a Unicode character is + absent in the bold font but present in the normal font by + temporarily falling back to the normal font (Debian #359006, + Debian #408666).
        • + +
        • provide configure option + --enable-double-buffer and ifdef's to allow + comparisons with/without double-buffering. The default uses + normal buffering.
        • + +
        • add feature to optionally scroll current page before + clearing, controlled by resource setting + cdXtraScroll (prompted by patch by Balazs + Kezes):
        • + +
        • integrated patches from Arch Linux forum posting (patches + by Balazs Kezes): + +
            +
          • modify reallocation limit of line-data when resizing + screen so that "lost" text will be restored if the screen + is first shrunk and then grown.
          • + +
          • modify output to use double-buffering to reduce + flicker.
          • +
          +
        • + +
        • modify scroll-lock action to handle + on/off/toggle keywords like other actions. Previously the + optional parameter was interpreted as an integer.
        • + +
        • extend DECSCUSR to provide a way to set the + cursor to a vertical bar (patch by Paul Bolle).
        • + +
        • add -8, -c, -d and + -u options to 88colors2.pl and + 256colors2.pl scripts. No current terminal + emulator recognizes C1 controls while handling UTF-8 + encoding—see notes in patch #119 + and patch #109 regarding + utf8controls—but the -u and + -8 options are useful for demonstrating this + point.
        • + +
        • improve speed when changing color palettes using OSC + controls by deferring repaint while followup controls might be + additional color palette changes.
        • + +
        • modify SGR 38 and + SGR 48 to accept RGB index, matching the + closest entry in xterm's palette.
        • + +
        • extend SGR 38 and + SGR 48 to accept colon as parameter separator + (request by Paul LeoNerd Evans).
        • + +
        • modify fullscreen action to allow it to toggle + the full-screen mode rather than only set or unset it (prompted + by Eeri Kask's suggestion to support + _NET_WM_TOGGLE). This implementation does not yet + use _NET_WM_TOGGLE.
        • + +
        • add support for _NET_WM_STATE_MAXIMIZED_VERT + and _NET_WM_STATE_MAXIMIZED_HORZ EWMH properties + (suggested by Eeri Kask).
        • + +
        • make fullscreen mode work with the tek4014 window. This + change makes only the currently active window to be changed to + fullscreen rather than changing both windows.
        • + +
        • modify TekClear function to discard pending + output before clearing the tek4014 display (patch by Kevin + Ryde).
        • + +
        • fix deleteIsDEL feature, broken in patch #280 changes (report by Mike Thornburg, + forwarded by Jeremy Huddleston).
        • + +
        • fix a special case of wrapping double-width characters + (report/test-case by Ken Winstein).
        • + +
        • add E3 extended capability to + xterm-basic to match ncurses 20120728 + patch.
        • + +
        • fix incorrect transformation of row-parameter for + ClearCurBackground in patch + #279 which caused incorrect painting in some scrolling + scenarios (report by Chuck Silvers).
        • + +
        • fix typo in manpage description of +maximized + option (Paul Maier).
        • + +
        • change default for configure option + --with-xpm, turning it on unless requested + otherwise.
        • + +
        • add configure option --with-icon-name which + can be used to override the default icon used in + icon-themes.
        • + +
        • extend activeIcon resource to provide + default value which tells xterm to determine the + window manager's name and automatically enable the feature for + fvwm and window maker. The explicit true/false values can be + used to override this behavior.
        • + +
        • add "mini" xterm icon, which scales better than the + standard xterm icon, e.g., for the gnome/kde "panel" + feature.
        • + +
        • extend iconName resource to search for icon + named according to resource value and use that if found. If not + found, use compiled-in pixmap. Both set the WM_ICON_NAME + property which is used by various window managers, usually for + window decoration.
        • + +
        • updated autoconf patch, adding support for --datarootdir, + which changes the default location of manpages.
        • + +
        • further improved autoconf macros for configuring icons, + from vile 9.8h
        • +
        + +

        Patch #281 - + 2012/06/26

        + +
          +
        • remove "$(srcdir)/" from install-icon rule to fix builds + when --srcdir configuration option is used.
        • + +
        • fix for configure script's search for icon file when it is + not found in the current directory, e.g., when building out of + tree (patch by Thierry Reding).
        • + +
        • undo the XK_Home / XK_End change from patch #280 which broke the non-VT220 keyboard + for those keys (report by H Merijn Brand).
        • +
        + +

        Patch #280 - + 2012/06/24

        + +
          +
        • add configure check to work around warning from + desktop-file-install for "Encoding", noting that it emits + deprecation warnings without providing its version + information.
        • + +
        • add configure option --with-icon-theme to tell + xterm whether to install into an icon theme, defaulting to + "hicolor" (Redhat #755206, Redhat #799614 and Redhat + #804279).
        • + +
        • change --with-icondir to look for "icons" + directory rather than "pixmaps" by default. Add new option + --with-pixmapdir to allow these two uses to be + installed concurrently.
        • + +
        • modify configure options --with-app-defaults + and --with-icondir to accept "auto" as value to + look for existing directory from well-known locations.
        • + +
        • add missing codes for secondary DA response which tell the + type of terminal as in the primary DA response.
        • + +
        • update primary DA response for VT420 to include user + windows and horizontal scrolling.
        • + +
        • add modifyKeyboard resource to support + keypad-modifier changes per request by Thomas Wolff.
        • + +
        • add XK_Home / XK_End to editing-keypad checks
        • + +
        • add back-tab key kB to termcap entries to + match the terminfo.
        • + +
        • update terminfo to match corresponding entries in ncurses, + e.g., add XT and adjust sgr string + for xterm-bold entry.
        • + +
        • add configure options to predefine the most commonly + customized resources for terminal-settings, use those to + substitute into the manpage the corresponding compiled-in + values: altSendsEscape, backarrowKey, + backarrowKeyIsErase, deleteIsDEL, + metaSendsEscape (Redhat #819588).
        • + +
        • change default emulation level to VT420 (discussion with + Ailin Nemui).
        • + +
        • improve logic for DECSCL; patch + 279 partly enforced limitation of this to higher-level + emulations. This patch finishes that change.
        • + +
        • improve check for base of combining characters, preventing + combination when cursor movement has intervened. Mosh's webpage + gives two different examples of this, with other causes + ascribed to the behavior.
        • + +
        • modify IL/DL to set cursor to first column on row for + better VT102/VT220 compatibility (prompted by code review of + mosh).
        • + +
        • separate state-table entries for DECSC/DECRC from the + ANSI.SYS save/restore cursor, since the latter conflicts with + DECSLRM when DECLRMM is enabled since patch #279 (report/analysis by Ailin + Nemui).
        • + +
        • fixes to avoid using SIGCHLD handler of main + program in printer's subprocess (report by Joe Julian).
        • + +
        • correct restore-parameter for mouse-modes from patch #279 changes.
        • + +
        • add null-pointer checks to input-method caching added in + patch #277 to fix a problem in the + exposure code, when deselecting a window (report by Kriston + Rehberg).
        • + +
        • unset DESKTOP_STARTUP_ID environment variable + to lessen confusion on the part of GTK applications which use + the variable without checking it (report by John Little).
        • +
        + +

        Patch #279 - + 2012/05/10

        + +
          +
        • fill in missing cases in the save/restore modes feature + (report by Thomas Wolff).
        • + +
        • add check to ensure that combining characters are + precomposed in the order given (report/analysis by Andries E + Brouwer).
        • + +
        • improve workability check for posix_openpt(), to take into + account BSD systems which do not complete initialization until + both sides of the pseudoterminal are opened (report by + Christian Weisgerber).
        • + +
        • amend fix for Debian #650291 in patch + #277 changes to account for different data returned by + vnc4server (Debian #670638).
        • + +
        • add check in DECCRA operation to make copies of blinking + text also blink by updating a line-level flag.
        • + +
        • modify rectangle operations to work with DECOM.
        • + +
        • modify DECSERA to use the current protected state rather + than preserving it.
        • + +
        • add precompose resource to allow storing + character data in Normalized Form D as described in http://unicode.org/reports/tr15/ + (report/discussion with Andries E Brouwer).
        • + +
        • modify CBT, other ISO-6429 controls which are used by VT520 + to work with DECOM.
        • + +
        • add HPR and VPR controls, ISO 6429 cursor movement used in + VT520.
        • + +
        • remove "linux" restriction for IUTF8 ifdef in main.c + (prompted by Matthew Dempsky posting on + mailing.openbsd.tech).
        • + +
        • implement the remaining VT420-level device status + reports.
        • + +
        • change DECXCPR to return page 1, rather than 0.
        • + +
        • improve VT-level checks on reporting functions, such as + DECXCPR.
        • + +
        • change limit on decTerminalID to 525.
        • + +
        • fixes to improve vttest vt52 screen when running as a + VT420: + +
            +
          • add checks for some VT2xx and up controls for + consistency: DECSCL, S1C8T, S1C7T.
          • + +
          • modify DECRQSS return for DECSCL to only return that + when running as VT2xx and up.
          • + +
          • when exiting from VT52-mode, resume in VT100 level + rather than the level before starting VT52-mode.
          • +
          +
        • + +
        • implement DECLRMM, DECSLRMM and DECNCSM (prompted by + discussions with Ailin Nemui and Paul LeoNerd Evans). This + modifies several controls to obey top/bottom and left/right + margins.
        • + +
        • correct macro definition used for testing modes used in + ANSI/DEC request-mode controls introduced in patch #262.
        • + +
        • modify x_getlogin to check $LOGNAME and $USER + before fallback to getlogin, so that user's choice + for these variables can be carried forward to the xterm process + (Debian #611487).
        • + +
        • document DECSCUSR response for DECRQSS in ctlseqs.ms
        • + +
        • add zIconTitleFormat resource to allow + customizing the "*** " prefixed to the icon title when the + zIconBeep feature is activated (request by Thomas + Adam).
        • + +
        • modify DECSCUSR to update the same internal variable as + RM/SM 12, and document in manpage the two variables used for + controlling blinking cursor (report by Paul LeoNerd + Evans).
        • + +
        • correct response data for DECSCUSR in reply for DECRQSS + response, which had inverted the blink-value (reports by Ailin + Nemui, Paul LeoNerd Evans).
        • + +
        • add a null-pointer check in OkPasswd macro to + fix a problem in resize with Fedora 17 and a + serial console (report/patch by Daniel Drake).
        • + +
        • add workaround for Mac OS X, which loses the window size of + a pseudo-terminal when the tty device is opened + (report/analysis by Egmont Koblinger).
        • + +
        • updated configure check for workable + posix_openpt versus grantpt, from + luit fixes.
        • + +
        • modify DECIC/DECDC/DECBI/DECFI implemented in patch #277 to enable them only in VT4xx mode + and up (report by Ailin Nemui).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #278 - + 2012/01/18

        + +
          +
        • correct initialization for eightBitMeta + resource (FreeBSD #164101).
        • + +
        • make special check for Darwin 9 (and lower) to not + use posix_openpt (report by Christian Ebert).
        • + +
        • minor fixes (adding ".ne" directives) to reduce the cases + where groff's utility for generating images for tables dumps + core. Most versions of groff (I've found 1.19.2 to be the most + stable) dump core when attempting to report that there are too + few lines on a page for a table to be shown.
        • +
        + +

        Patch #277 - + 2012/01/07

        + +
          +
        • remove special case for ISC pseudo-terminals which attempts + to open the pty in two different ways.
        • + +
        • move call to grantpt before asking utempter to + add a record, to work with kFreeBSD which does not update the + terminal's ownership until this point (Debian #652907).
        • + +
        • document limitation of XIM interface in manpage (Debian + #230787).
        • + +
        • cleanup error reporting with new xtermWarning + function.
        • + +
        • add configure option --disable-selection-ops + to make the new actions optional.
        • + +
        • add four new actions for making the selection or data + directly copied from the screen (prompted by discussion in + Debian #637001, as well as report by Arjen van Tol): + +
            +
          • exec-formatted
          • + +
          • exec-selectable
          • + +
          • insert-formatted
          • + +
          • insert-selectable
          • +
          +
        • + +
        • add visualBellLine resource to allow + visualBell to flash only the current line + (prompted by patch by Gertjan Halkes).
        • + +
        • add eightBitMeta resource to control the + features which modify or interpret the eighth bit of a key when + the meta modifier key is pressed (prompted by Debian + #326200).
        • + +
        • improve discussion of eightBitInput in the + manpage (prompted by Debian #326200).
        • + +
        • correct logic for alt-sends-escape action, + overlooked when implementing altSendsEscape + resource, which still used eightBitInput resource + value.
        • + +
        • add a workaround for XAllocColor(), which does + not actually allocate "a read-only colormap entry corresponding + to the closest RGB value supported by the hardware", but rather + a rough approximation (Debian #650291).
        • + +
        • undo parameter checks for RequestResize() + added in patch #251 and amended in + patch #270, because zeros also are + special cases (report by John S Urban).
        • + +
        • modify some test-scripts to use /bin/echo + rather than the shell's possibly-builtin echo, to + work around broken configuration on Mac OS X, i.e., neither + honoring the option nor flagging an error.
        • + +
        • add SGR 1006, as a better technical solution than SGR 1015: + +
            +
          • the responses will not be confused with line-deletion + and scrolling controls.
          • + +
          • the button encoding is a little simpler, since it does + not add an unnecessary 32 because the integer parameter + does not have to be represented as a printable + character.
          • + +
          • the control responses for pressing and releasing a + mouse button differ, allowing an application to tell which + button was released.
          • +
          + +

          Besides these improvements, in discussion, it was noted + that urxvt's implementation of 1005 is incorrect, relying + upon a locale that provides UTF-8 encoding. In contrast, + vttest demonstrates a correct decoding, independent of + locale.

          +
        • + +
        • add support for urxvt SGR 1015 to address shortcoming of + SGR 1005 with luit (patch by Egmont Koblinger).
        • + +
        • add ISO and DEC controls useful for left/right + scrolling.
        • + +
        • add some changes for OpenBSD and MirBSD (adapted from patch + by Thorsten Glaser): + +
            +
          • disable search for non-Unix96 ptys.
          • + +
          • fix a gcc warning in + timestamp_filename
          • + +
          • modify Imakefile to install xterm setgid + to utmp.
          • +
          +
        • + +
        • add/use/prefer posix_openpt() for opening + pseudo-terminal.
        • + +
        • modify special errno handling case in ptydata.c from + patch #158 to allow for the + possibility that any platform may have special cases where + "/dev/tty" is absent. For example, this can happen in a FreeBSD + jail (patch by David Wolfskill).
        • + +
        • add keyboard logic to map shift-tab into XK_ISO_Left_Tab, + which is usually, not always, done by the X keyboard + configuration.
        • + +
        • portability fixes for some configure macros: + CF_XOPEN_SOURCE
        • +
        + +

        Patch #276 - + 2011/10/10

        + +
          +
        • modify clipping limits for TrueType fonts to account for + the scaleHeight resource setting, to work around + another problem due to recent FreeType changes. In this case, + the DejaVu Sans Mono set to pixelsize=13.5 is + truncated because the font descent is reduced by FreeType to + match an incorrect height metric (report by Adam Lee).
        • + +
        • improve recovery when bitmap fonts are not installed, e.g., + so that switching font-sizes works for TrueType fonts.
        • + +
        • modify lookup for XTERM_SHELL feature to allow + relative pathnames.
        • + +
        • modify abbreviation disambiguation check for command-line + parameters to account for -geometry, whose + parameter may begin with "+" or "-" (report by Scott + Bertilson).
        • +
        + +

        Patch #275 - + 2011/09/11

        + +
          +
        • add ash, zsh to known shells for + resize.
        • + +
        • modify resize to reuse the logic from + xterm which determines the actual logon-user's + shell if $SHELL is not set.
        • + +
        • revert the unsetenv("SHELL") added in patch #272.
        • + +
        • an unsetenv("SHELL") added in patch #272 to help ensure that + luit would get the user's shell consistently did + not work as expected for cases where multiple names are in the + password-file for a given uid. That was because changes in + patch #157 to handle this situation + did not take into account that repeated calls to + getpwnam and getpwuid return a + pointer to the same static buffer. Fixed the older logic to + work as intended, by ensuring that the passwd-data from each + call is stored separately (report by Paul Keusemann).
        • + +
        • adjust ifdef's for putenv and + unsetenv in case only one of those is provided on + a given platform.
        • + +
        • correct comparison used in ExposeContains + macro from patch #274 changes, to + handle window-dragging (patch by Todd Eigenschink).
        • +
        + +

        Patch #274 - + 2011/09/05

        + +
          +
        • portability fixes for cygwin: do not define + SVR4, and work around nonstandard header + location.
        • + +
        • ifdef'd use of unsetenv from patch #273 changes to work with Solaris 9 + (report by Waldemar Rachwal).
        • + +
        • modify logic for XtAppPending to merge + adjacent Expose and ConfigureNotify + events which are redundant (report by Edward McGuire).
        • + +
        • fix an unneeded warning message when -r option + is given.
        • + +
        • remove a few redundant entries from table used for helping + abbreviation-checking of command-line options, makes + -geom work again after patch + #272 changes as an abbreviation of + -geometry.
        • + +
        • add scaleHeight resource and command-line + option -sh as workaround for some + font-configurations broken by changes in FreeType 2.4.6 (report + by Miroslav Hodak).
        • + +
        • portability fixes for some configure macros: + CF_FUNC_TGETENT, CF_XOPEN_SOURCE, + CF_X_ATHENA_LIBS.
        • + +
        • add configure option --with-freetype-config to + improve selection over the plethora of configuration options + which freetype has so far provided.
        • + +
        • build-fix for configure --enable-load-vt-fonts + when --enable-widec is not specified.
        • + +
        • build-fixes for suppressing various features, needed after + changes in patches 270, 271 and 272 (report by Brian + Lindholm)
        • +
        + +

        Patch #273 - + 2011/08/25

        + +
          +
        • build-fix for out-of-tree "make docs" rule.
        • + +
        • correct a typo in x_strdup, from patch #198 changes.
        • + +
        • correct initialization for -e option, broken + in patch #272 changes (report by + Gabriele Balducci).
        • + +
        • build-fix for out-of-tree builds to address + minstall script changes in patch #272 (patch by Thierry Reding).
        • +
        + +

        Patch #272 - + 2011/08/24

        + +
          +
        • document limitation of Gtk in connection with + xterm's -into option, in the manpage (Ubuntu + #806969).
        • + +
        • improve -into by checking for and using the + size of the window within which xterm is embedded, overriding + other clues.
        • + +
        • modify logic for localeFilter resource to + allow that to include command-line options of luit.
        • + +
        • improve -into by checking for invalid + window-id, and allowing hexadecimal/decimal/octal values.
        • + +
        • improve keepSelection, adding the case where + the highlighting is cleared, overlooked in patch #230 (patch by Marco Peereboom).
        • + +
        • improve command-line parsing to make abbreviate options + work consistently across xterm-specific versus standard X + toolkit options, and report cases where an abbreviated option + happens to be ambiguous. In particular, -d now + works as an abbreviation for -display.
        • + +
        • fix regression in command-line parsing introduced in + patch #271 changes for Debian #629358, + (Debian #637910).
        • + +
        • split-out new termcap/terminfo building block + xterm+kbs for configurability.
        • + +
        • modify terminfo file to reflect changes in + ncurses for xterm-16color and + xterm-256color.
        • + +
        • modify minstall.sh, etc., to reflect the + default default class, $TERM and + decTerminalID values.
        • + +
        • reword resize manpage to reflect the fact that + $TERMCAP is not set on all systems (patch by Alan + Coopersmith).
        • + +
        • work around combined Xaw6/Xaw7 package in DragonFlyBSD + which omits the usual symbolic link to the preferred library + name.
        • + +
        • further improve build-fix for termcap systems by checking + for some which are only partial implementations, e.g., termcap + 2.08 in CentOS 5.2
        • +
        + +

        Patch #271 - + 2011/07/14

        + +
          +
        • omit permissions adjustments to pty on exit except for + pre-Unix98 ptys, since modern implementations handle this + (report by Sean C Farley).
        • + +
        • modify logic for switching fonts between UTF-8 and + non-UTF-8 encoding to not merge the derivable bold-, wide- and + widebold values from the VT100 fonts. Also suppress warning + when not using UTF-8 fonts if wide- and widebold-fonts cannot + be derived or otherwise loaded (report by Werner + Scheinast).
        • + +
        • modify menu-creation to suppress entries which will never + be used in the current configuration, rather than simply + disabling them.
        • + +
        • add resource printModeImmediate and menu item + to allow print of screen plus saved lines to a file.
        • + +
        • add menu item to allow runtime enable/disable of the + printFileOnXError feature.
        • + +
        • append a timestamp to filename used in + printFileOnXError feature, and restrict its + permissions (request by Vincent Lefevre).
        • + +
        • add a check when cancelling cursor-blinking, in case the + cursor is blinked off. Fix so that the cursor is repainted + without waiting for other events, e.g., keypress (report by + Ailin Nemui).
        • + +
        • add configure --with-app-class option, to + simplify building "xterm-dev" packages with filenames that do + not conflict with conventional "xterm" packages.
        • + +
        • corrected logic flow for DECSCL, which prevented the + updated operating level from being reported via DECRQSS (report + by Ailin Nemui).
        • + +
        • corrected default for brokenStringTerm + resource to match manpage.
        • + +
        • add vttests/dynamic.pl
        • + +
        • add runtime check for locale not supported by X libraries, + and fallback to XA_STRING in this case (request by Bryan + Henderson).
        • + +
        • fix a special case in configure script after no FreeType + libraries are found. The script was proceeding to check for a + usable configuration.
        • + +
        • add xterm+tmux building block to terminfo + (adapted from changes proposed by Ailin Nemui and Nicholas + Marriott).
        • + +
        • improve discussion of faceName resource in + manpage (adapted from suggestions by Jens Schweikhardt).
        • + +
        • correct mapping of shifted up/down cursor-keys in termcap + function-keys mode, i.e., resource + tcapFunctionKeys (patch by Gertjan Halkes).
        • + +
        • update AIX case in CF_XOPEN_SOURCE configure + macro to add release 7.x.
        • + +
        • modify ifdef's in xterm_io.h for + __hpux to force that to use the hacked SYSV + support in that file. This fixes a problem with a non-blocking + socket call (patch by Paul Lampert).
        • + +
        • improve filtering of desktop category scanning, to exclude + XFCE.
        • + +
        • modify configure script to work with systems that have both + ncurses (or other terminfo) as well as a real termcap library, + e.g., Slackware (report by Andrew Watts).
        • + +
        • modify configure script to work around special case where + user's environment adds compiler flags to the CC + variable (prompted by report by Paul Lampert).
        • + +
        • amend change for Debian #110226 so that "-h" or "-v" + options cause an exit, rather than simply printing to stdout + while the window is displayed (Debian #629358).
        • + +
        • add response for DECRQSS which gives the + setting for DECSCUSR.
        • + +
        • modify AllocateTermColor() to handle + XtDefaultForeground and + XtDefaultBackground, which are not recognized by + XParseColor. For example, this fixes the use of + OSC 112 when no explicit cursor color was set (report by + Ailin Nemui).
        • + +
        • handle special-case of KeyPress translated to + popup-menu action (Ubuntu #756273).
        • +
        + +

        Patch #270 - + 2011/04/26

        + +
          +
        • build-fix, e.g., for using imake on platforms + which use the termcap library.
        • + +
        • modify utf8 resource to accept a name.
        • + +
        • mention default for fontWarnings in manpage + (report by Werner Scheinast).
        • + +
        • split "UTF-8" menu entry into "UTF-8 Encoding" and "UTF-8 + Fonts" (prompted by discussion with Werner Scheinast).
        • + +
        • gray-out font-menu entries when a font fails to load, e.g., + a bitmap font is not installed.
        • + +
        • improve behavior when there is no app-defaults file: + +
            +
          • set the toolBar resource to false
          • + +
          • gray-out the font menu entries where no resource is + found.
          • +
          +
        • + +
        • add configure option --with-desktop-category + to allow customization of the ".desktop" files.
        • + +
        • build-fix for the install-desktop + makefile-rule, when the source/build directories differ (patch + by Loïc Minier).
        • + +
        • add menu entry and corresponding resource which can be used + to suppress all bold-fonts (discussion with Jan + Engelhardt).
        • + +
        • make internal line-size value consistent with allocated + sizes of character and related arrays to ensure that bulk + copying of line data, e.g., in scrolling, accounts for the + padding used for pointer alignment (adapted from patch by + Rajesh Mandalemula, also reported by Ali Bahar).
        • + +
        • widen ifdef for screen-resizing logic from patch #176 changes to send + SIGWINCH to process group to include any system + supporting ioctl(*,TIOCGPGRP,*) (prompted by + linux-specific patch in OpenSUSE rpm package).
        • + +
        • add printModeOnXError and + printFileOnXError resources, which allow the user + to specify that xterm will write the contents of its screen to + a file if it is exiting due to an X error (Debian + #280457).
        • + +
        • restore logic that made reverse-video apply to the + scrollbar's foreground/background, broken in patch #158 (report by Bryan Ischo).
        • + +
        • amend some of the window operations parameter-checks added + in patch #251 for the push/pop title + feature, to allow the parameters used for window resizing to be + -1's, which makes the corresponding values ignored rather than + using the window's maximum width/height (report by Noah + Friedman).
        • + +
        • correct order of initialization for + translations vs fullscreen resources + to enable a special case which omits the Alt-Enter translation + when fullscreen is disabled (Debian #612978).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #269 - + 2011/02/19

        + +
          +
        • build-fixes for imake (report by Heiko + Berges).
        • + +
        • modify autoconf macro CF_PKG_CONFIG to work with + cross-compile environments (patch by Thierry Reding).
        • + +
        • modify MapToColorMode() to favor bold over + underline, matching the precedence used before patch #252 (report/analysis by Nicolas + George).
        • + +
        • add omitTranslation resource, which can be + used to suppress the default translations for these features: + +
            +
          • fullscreen
          • + +
          • scroll-lock
          • + +
          • shift-fonts
          • + +
          • wheel-mouse
          • +
          +
        • + +
        • make the fullscreen feature configurable (Debian #612978) + +
            +
          • add it to the configurable list + disallowedWindowOps.
          • + +
          • add command-line option -fullscreen to + allow the feature to be enabled at startup.
          • + +
          • add resource fullscreen to control whether + the feature is active or may be enabled.
          • +
          +
        • + +
        • modify probe_netwm_fullscreen_capability for + 64-bit machines. Contrary to XGetWindowProperty + manpage, that function returns 32-bit data packed as + long's.
        • + +
        • eliminate copy of name resource, which was + otherwise used only to give the terminal-description name for + the tcap-query feature. Use the actual $TERM value + instead, as derived from termName resource, + etc.
        • + +
        • eliminate an old inconsistency with error messages, some + used the -name option, while others used + argv[0]. The latter is now used consistently.
        • + +
        • improve configure check for rpath-hack, to improve builds + on systems where gcc will not search /usr/local/lib, etc.
        • + +
        • build-fix for Xaw3d configuration (report by H Merijn + Brand).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #268 - + 2011/02/10

        + +
          +
        • fix an inconsistency of the "Enable Reverse Video" checkbox + in the VT Options menu. This also removes a special case added + in patch #217 which limited the effect + of the reverseVideo resource (Debian + #603808).
        • + +
        • amend decoding of misformed UTF-8 sequences to avoid + absorbing valid characters as documented in Unicode 6.0 section + 3.9 (report by Keith Winstein).
        • + +
        • do not set urgency hint when window already has focus + (patch by Dimitrios Christidis).
        • + +
        • amend extended mouse-coordinate mode from patch #262 changes to include the Cb + button-code, which also may be greater than 127 (report by + Ailin Nemui).
        • + +
        • ensure that underline-cursor is visible when an application + happens to set the background color (report by Christian + Weisgerber).
        • + +
        • add feature for + full-screen toggling using either Alt-Enter or a menu + selection (integrated patch by Dave Simmons).
        • + +
        • add missing logic to handle reallocation of FIFO index for + the "UTF-8" menu entry (report by David Holland, NetBSD + #44344).
        • + +
        • add makefile rules docs-ctlseqs, + docs-xterm, etc.
        • + +
        • correct typo in description of DECRPM in control sequences + document (report by Ailin Nemui).
        • +
        + +

        Patch #267 - + 2010/11/20

        + +
          +
        • minor formatting changes to ctlseqs.ms to simplify a script + which extracts the feature information. See the results in + + Comparing versions, by counting controls in the xterm + FAQ.
        • + +
        • add docs-clean makefile rule.
        • + +
        • add copy-selection action (request by Timo + Juhani Lindfors, Debian #588785).
        • + +
        • trim leading/trailing blanks from string used for + "Selection" font-menu data.
        • + +
        • trim leading/trailing blanks from color resource + values.
        • + +
        • configure script improvements: + +
            +
          • add workaround for removal of X11 dependency from Xt's + package file (report by Robert Hooker).
          • + +
          • add workaround for removal of fontconfig dependency + from Xft's package file (report by Jeremy Huddleston).
          • + +
          • add workaround for removal of Xmu dependency from Xaw's + package file (report by Jeremy Huddleston).
          • + +
          • improve workaround in CF_X_TOOLKIT macro, + checking for other possible packages where Xt's + dependencies may be given.
          • + +
          • prefer ${name:=value} to + ${name-value}, since recent bash changes break + legacy support for that feature.
          • +
          +
        • +
        + +

        Patch #266 - + 2010/10/24

        + +
          +
        • add rpm and dpkg scripts, for testing.
        • + +
        • more fixes for Debian #600707 (report by Cyril + Brulebois).
        • +
        + +

        Patch #265 - + 2010/10/22

        + +
          +
        • fix a regression in fontname logic from patch #263 changes (Debian #600707, reported + by Vincent Lefevre).
        • + +
        • revert modification of any-event/any-button protocol from + patch #263 changes. It interferes with + selection using a shifted mouse button (reports by Neil Bird, + Bram Moolenaar).
        • +
        + +

        Patch #264 - + 2010/10/14

        + +
          +
        • replace a null-pointer check with check for empty string in + xtermOpenFont, to eliminate a warning message from + patch #263 changes.
        • + +
        • build-fix for patch #263 when + toolbar is not configured (patch by Chris Clayton) (reports by + Robby Workman, David Wood).
        • +
        + +

        Patch #263 - + 2010/10/13

        + +
          +
        • corrected initialization of "misc" resource values, to + ensure that xterm has allocated a copy of strings which may not + have been malloc'd by the X library (Debian #600129).
        • + +
        • modify handling of any-event/any-button mouse protocol; it + now is active with any combination of key-modifiers.
        • + +
        • add debugging feature showWrapMarks, which + marks lines which xterm knows are wrapped, showing where a + double-click will select past the end of a line.
        • + +
        • build-fix to address change in include-guards for + Xlib.h in ongoing Xorg edits (patch by Jeremy + Huddleston).
        • + +
        • improve pointerMode by continuing to watch for + motion events after mouse tracking is disabled if the pointer + is hidden (Debian #594856).
        • + +
        • further extend initialization for active-icon font to check + if the font was not loaded succesfully, to retry with + font1, or as even (if TrueType fonts are used) to + use a TrueType font. The retries are to help with cases as in + patch #241 where the bitmap fonts are + not available.
        • + +
        • fix special case of active-icon used when TrueType font is + specified for the xterm window, from patch + #261 change. In that case, the default font's size was used + for layout of the active icon's window (Debian #591265).
        • +
        + +

        Patch #262 - + 2010/8/30

        + +
          +
        • fix a case where changing the cursor color via escape + sequences did not immediately update the screen (report by + Andreas Wagner).
        • + +
        • implement ANSI and DEC request-mode control sequences. The + latter includes the xterm-specific private modes such as the + mouse mode. The feature is ifdef'd with the rectangle + operations since its decoding overlaps that feature.
        • + +
        • correct typo in ctlseqs.ms for response of OSC 21 (patch by + Kevin Schoedel).
        • + +
        • improve discussion of mouse tracking in ctlseqs.ms
        • + +
        • increase an array limit used in reporting mouse events + (report by Ryan Johnson).
        • + +
        • add extended mouse-coordinates mode, allowing up to + 2015x2015 windows, using UTF-8 encoding (patch by Ryan + Johnson).
        • + +
        • modify manpage hyphens to conform with + Debian.
        • +
        + +

        Patch #261 - + 2010/6/28

        + +
          +
        • fix regression in renderFont logic, from + patch #260 changes (report by Joseph + Quinsey).
        • +
        + +

        Patch #260 - + 2010/6/20

        + +
          +
        • modify plink.sh to work around problem linking + to recent PCRE libraries.
        • + +
        • extend renderFont resource to allow deferred + switch to TrueType fonts without affecting existing resource + settings (Debian #585620).
        • + +
        • modify configure macro CF_X_TOOLKIT to work around omission + of ICE library from ".pc" file (report by Miroslav + Lichvar).
        • + +
        • change configure script default for + --enable-broken-st i.e., the + brokenStringTerm feature) to normally enable it. + If the corresponding resource is enabled, this feature + eliminates an apparent freeze of xterm when sending mis-encoded + data to the screen (Debian #584801).
        • + +
        • document in manpage some actions which were overlooked: + +
            +
          • readline-button
          • + +
          • scroll-lock
          • + +
          • set-8-bit-control
          • +
          +
        • + +
        • undo a change to limit-check in ScrnRefresh in + patch #257, which broke + fastScroll feature (Debian #584841).
        • + +
        • modify handling of brokenLinuxOSC and + brokenStringTerm to also sound the bell.
        • + +
        • add control/D and control/Q to controls which will cause + early exit from control string per + brokenStringTerm resource.
        • + +
        • improve documentation of brokenStringTerm + resource in manpage.
        • +
        + +

        Patch #259 - + 2010/6/5

        + +
          +
        • modify configure check for luit to include new + aliases for the program (xterm-filter and + bluit).
        • + +
        • add workaround in xtermClearLEDs() to account + for Xkb's override, making vttest's LED demo reset the scroll + lock.
        • + +
        • filter out client-message events when deciding whether to + hide cursor, e.g., when using SCIM (patch/report by anonymous + user).
        • + +
        • improve description of -bd option in manpage + (report by Guy Daniel Clotilde).
        • + +
        • modify configure checks for PCRE and other libraries to use + pkg-config, if available.
        • + +
        • amend change from patch #252, to + take veryColorColors resource into account when + checking colorBDMode resource for TrueType fonts + (report by anonymous user).
        • + +
        • add vttests/query-fonts.pl script for + demonstrating the OSC 50 font query.
        • + +
        • improve manpage discussion of Scroll Lock feature.
        • + +
        • improve configure macros CF_GCC_VERSION and + CF_GCC_WARNINGS.
        • + +
        • fix warnings for "clang --analyze".
        • + +
        • change default for allowScrollLock resource to + false, noting that the supposedly unused key has + been useful for various rebindings (Debian #580946).
        • +
        + +

        Patch #258 - + 2010/5/1

        + +
          +
        • add pointer-checks in ScrnRefresh to fix a + case in rapid scrolling where an empty record is fetched from + the scrollback FIFO.
        • +
        + +

        Patch #257 - + 2010/4/22

        + +
          +
        • correct ctlseqs.ms description of OSC 17 and OSC 19 (patch + by Emanuele Giaquinta).
        • + +
        • corrected logic for menuLocale resource; the + setlocale function returns the original locale + only when querying.
        • + +
        • improve filtering of translations resource, narrowing the + scope of the alwaysUseMods to address only the + translations that would cause a key to be sent to the host + (report by Andrew Gaylard).
        • + +
        • change default value of menuLocale resource to + "C", to work around longstanding Xorg + bug.
        • + +
        • modify handling of scrollKey feature to ignore + XON/XOFF keys.
        • + +
        • implement scroll-lock feature.
        • + +
        • revise memory allocation in UTF8toLatin1() to fix an + out-of-bounds index (Mandriva #54531).
        • + +
        • compute value for first wide-character rather than assuming + it is 256, fixes problem with -cjk_width + introduced in patches 242 and 249 (report by Thomas Wolff).
        • + +
        • improve configure script: + +
            +
          • corrected check for _XOPEN_SOURCE for + OpenSolaris.
          • + +
          • when possible, add rpath option for libraries in + unusual places
          • + +
          • add configure option --disable-rpath-hack + to control whether the rpath option can be added.
          • +
          +
        • + +
        • modify AllocateTermColor() to separate + initialization from control sequences, fixing problem from + patch #254 changes where enabling + allowSendEvents resource prevents setting cursor + color on command-line (Debian #572928).
        • + +
        • amend logic from patch #185 to not + reallocate cell-array if processing + ESC % G to switch from UTF-8 if already + in ISO-8859-1 character set (report by Michael Koehne).
        • + +
        • fix to avoid calling XmuInternStrings() with + zero count (report by Johan Bockgård).
        • + +
        • fix build when --disable-ansi-color configure option is + used.
        • + +
        • fix build when neither OPT_TCAP_QUERY or OPT_TCAP_FKEYS is + defined (patch by Matthieu Herrb)
        • +
        + +

        Patch #256 - + 2010/3/6

        + +
          +
        • add TerminalEmulator to desktop category files.
        • + +
        • modify sinstall.sh to ignore the "." appended + to permissions by selinux.
        • + +
        • change app-defaults organization, installing UXTerm-color + and KOI8XTerm-color for consistent behavior regarding + customization: color (prompted by discussion + in Ubuntu #421261).
        • + +
        • fix typo in minstall.sh from patch #255 changes, and add case for + /var/run needed for full path of utmp (report by + Julien Cristau).
        • + +
        • minor fix to xterm manpage, remove a comment stating that + margin bell can be changed via the VT Options menu. That was + replaced in patch #225
        • + +
        • add a "docs" rule to makefile.
        • + +
        • fix initialization of Atom used for XkbBell + feature from patch 243 changes. Unlike + the other calls to XInternAtom(), in this case the + flag telling X to create the Atom was unset (patch by Chris + Adams).
        • +
        + +

        Patch #255 - + 2010/1/21

        + +
          +
        • rename install.sh to install-sh + in case suffix-rules might interfere.
        • + +
        • extend range for convertToUTF8 function to + full 31-bits, to use with printing, etc.
        • + +
        • improve manpage by checking for actual locations of + utmp/wtmp files (Debian #562640).
        • + +
        • modify configure macro CF_XOPEN_SOURCE to remove -D's + before adding the same name rather than relying on -U's, to + reduce redefinition warnings for some platforms that have + conflicting definitions in headers.
        • + +
        • correct logic used to switch to alternate screen using + FIFO-lines configuration (Debian #565772).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #254 - + 2010/1/6

        + +
          +
        • add a configure-check to eliminate install-ti + rule from Makefile when the system has no tic (terminfo + compiler) program. This lets one use the + install-full rule more consistently.
        • + +
        • amend change to WriteText() function in patch #252 to take into account the + colorAttrMode resource (report by Krzysztof + Kotlenga).
        • + +
        • document titleModes resource in manpage, added + in patch #252.
        • + +
        • modify tcap-query table entries for shifted up/down cursor + keys to match ncurses convention.
        • + +
        • improve lookup of termcap-query data, allowing for + duplicate keycodes versus missing entries.
        • + +
        • add control sequence which can be used to modify the + terminal data used for the termcap-keyboard.
        • + +
        • improve portability of tcap-query feature, using terminfo + functions in preference to termcap on systems having + terminfo.
        • + +
        • improve font-setting/querying control + (OSC 50): + +
            +
          • when TrueType font is selected, the TrueType + faceName will be set, rather than the bitmap + font.
          • + +
          • when TrueType font is selected, querying returns the + name of the TrueType font.
          • + +
          • querying a font recognizes the relative-font convention + that setting a font could use.
          • +
          +
        • + +
        • add menu-entry for allowColorOps.
        • + +
        • add new resources for fine-tuning menu entries: + allowColorOps, disallowedColorOps, + disallowedFontOps and + disallowedTcapOps.
        • + +
        • correct logic for disabling the "TrueType Fonts" menu item; + it was not ensuring that the faceName resource + value was non-empty.
        • + +
        • implement VT520-style controls DECSMBV and + DECSWBV for setting the margin- and warning-bell + volume.
        • + +
        • fix a minor error from patch #243 + which made the zIconBeep feature use a minor-error tone rather + than an informational tone.
        • + +
        • add a null-pointer check for the case where + renderFont resource is true, but + faceName resource is unset, used in logic to strip + "xft:" prefix from patch #251 changes + (patch by Michael Riepe).
        • + +
        • add special case to configure CF_XOPEN_SOURCE macro to use + extensions on Darwin (patch by Dennis Preiser).
        • + +
        • improve configure checks for regular expressions header and + library
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #253 - + 2009/12/10

        + +
          +
        • add a null-pointer check in getPrinterFlags() + per changes in patch #252.
        • + +
        • add a null-pointer check, needed in UTF-8 mode for Xft + fonts after changes in patch #252 + (patch by Alan Coopersmith).
        • + +
        • correct size when clearing struct for tek4014 (patch by + Jochen Voss).
        • + +
        • parenthesize expression in MoreRows macro, + fixing a limit check added in patch + #251 (Debian #560039).
        • +
        + +

        Patch #252 - + 2009/12/7

        + +
          +
        • modify title-querying logic to support retrieval of titles + encoded using UTF-8.
        • + +
        • add new "title-modes" control sequence for controlling + whether window/icon titles can be set or queried using UTF-8, + optionally encoded in a hexadecimal string.
        • + +
        • use mkdir -p rather than + mkdirs.sh (prompted by discussion of mawk by + Aleksey Cheusov).
        • + +
        • add appropriate copyright/license notices to the bulk of + files lacking same, and modify to use identical terms in others + which used different wording. The main exceptions are the files + contributed by Markus Kuhn, who appears to prefer public domain + distribution, noting that I have modified/improved several of + these without changing the terms of distribution (request by + Jari Aalto).
        • + +
        • add control sequences for resetting the "dynamic" colors to + their default values.
        • + +
        • add control sequences for resetting the "special" colors to + their default values.
        • + +
        • add control sequences for setting the "special" colors such + as colorBD (bold).
        • + +
        • add overlooked case for setting highlight foreground color + with the dynamic-colors control.
        • + +
        • add OSC 104, for resetting ANSI/16/88/256 + colors to default.
        • + +
        • reset ANSI/16/88/256 colors to default in soft/hard reset + functions.
        • + +
        • strip "xft:" prefix from faceName and + faceNameDoublesize resource values,
        • + +
        • add DECSCUSR (discussion with Andy + Koppe).
        • + +
        • add check/warning on failure to load font, to see if the + name looks like an Xft pattern rather than XLFD. This can + happen if someone happens to modify their X resource settings + for programs that read data from xterm's namespace.
        • + +
        • modify handling of print and + print-everything actions to allow the various + printer flags to be overridden by supplying parameters.
        • + +
        • add resource printerNewLine (request by Ovidiu + Gheorghioiu).
        • + +
        • minor cleanup, finish using TScreenOf() and + TekScreenOf() macros introduced in patch #224.
        • + +
        • improve checks in ShowCursor/HideCursor to get the + background color, particularly when + highlightReverse resource is used (reports by Jan + Engelhardt, Christian Weisgerber).
        • + +
        • correct checkVeryBoldAttr to omit comparison + of foreground color to special color values used for + color<XX> resources (report by Jan + Engelhardt).
        • + +
        • make colorBDMode and colorULMode + resources work with TrueType configuration (report by Jan + Engelhardt).
        • +
        + +

        Patch #251 - + 2009/11/11

        + +
          +
        • add window-ops controls to push/pop icon and/or window + labels on a stack.
        • + +
        • minor fixes to align termcap file with terminfo.
        • + +
        • add resource disallowedWindowOps, to allow + fine-tuning of features to suppress with the + allowWindowOps resource (prompted by discussion + with Bram Moolenaar).
        • + +
        • add makefile rules for resize-manpage to pdf, etc.
        • + +
        • further improve limit-checks in select/paste (Mandriva + #54531).
        • +
        + +

        Patch #250 - + 2009/10/13

        + +
          +
        • add check and error-message for fonts that have no + printable values in the ISO-8859-1 range (Debian #542434).
        • + +
        • some compiler-warning cleanup, in particular workaround for + defective implementation of gcc's attribute warn_unused_result + (report by Bram Moolenaar).
        • + +
        • improve estimate of single-column width for packed TrueType + fonts by ignoring extents for codes 127 and 159.
        • + +
        • improve line-drawing for TrueType fonts which happen to + have defined glyphs which are not line-drawing in + 0..31 by assuming they're not, and just checking the existence + of the Unicode codepoints. This makes it more likely that the + user can override a misconfigured font using the "Line-Drawing + Characters" menu entry.
        • + +
        • limit minimum cell-width for packed font to maximum-advance + reported by Xft. Some fonts are wider than that, even in the + Latin-1 range (Debian #550497).
        • + +
        • add list of direct-contributors in "THANKS" file.
        • + +
        • stylistic changes to this file to help scripted extraction + of list of contributors.
        • + +
        • correct off-by-one in okPosition fix from + patch #249 limit-checks which + prevented double-click selection on the bottom line of the + screen (reports by Rajeev V. Pillai, Debian #550368).
        • + +
        • add -q option to + vttest/256colors2.pl and + vttest/88colors2.pl to demonstrate bulk + initialization of color palette.
        • + +
        • improve the workaround from patch #188 by enabling + resources for the 88-color model.
        • + +
        • document in xterm manpage the limited availability of + resources color16 to color255 as + noted in patch #188 (Ubuntu + #438850).
        • +
        + +

        Patch #249 - + 2009/10/1

        + +
          +
        • change default for allowWindowOps resource to + false. +
        • + +
        • add limit-checks for result of visual_width() function, + needed from patch #242 and exposed by + #244 changes (Debian #548321).
        • + +
        • improve limit-checks in select/paste.
        • + +
        • fix a remaining bug from patch + #230 changes for displaying multi-column characters in a + proportional font (report by Chris Jones).
        • + +
        • add new resource forcePackedFont and menu entry "Packed + Font" to control whether to use the font's minimum (default) or + maximum width when those differ. The workaround which xterm + uses to accommodate proportional fonts is not necessary with + certain fonts such as unifont which happen to store a mixture + of multicolumn glyphs (report by Chris Jones).
        • + +
        • fix an (old) bug which did not restart the timer for + blinking text if the only blinking text was temporarily + scrolled out of view, e.g., using the scrollbar.
        • + +
        • fix an (old) flaw in the delete-line operation where the + text which is scrolled into view while the display is scrolled + up was not repainted.
        • + +
        • improve delete-line and insert-line operations, retaining + selection when the selection does not intersect the + deleted/inserted lines.
        • + +
        • fix an (old) off-by-one error when an application cleared + above the cursor position while the display was scrolled up, + that would leave an extra line of text uncleared.
        • + +
        • fix a similar problem where the double-size attribute would + not be reset when clearing the screen while the display was + scrolled up.
        • + +
        • fix an indexing error which would occur if an application + cleared a line while the display was scrolled up and was also + in UTF-8 mode (Redhat #524503). The error was from patch #228 but more visible after changes from + patch #244.
        • +
        + +

        Patch #248 - + 2009/9/11

        + +
          +
        • fix an overlooked adjustment for selecting double-width + characters in the narrow-character configuration.
        • + +
        • eliminate uses of XTERM_CELL and + XTERM_CELLC where an appropriate + LineData pointer is available.
        • + +
        • correct expression in okScrnRow macro, making + selections give the length of lines below the visible screen + (report by Stuart Henderson).
        • + +
        • correct logic used to improve performance of missing-glyph + check, which did not handle line-drawing characters (Debian + #545220).
        • +
        + +

        Patch #247 - + 2009/8/30

        + +
          +
        • add ifdef's and check for openpty() on DragonFly (patch by + Alex Hornung).
        • + +
        • correct calculation for size of line's data block, which + was sometimes off-by-one when configured using + --enable-16bit-chars (report by H Merijn + Brand).
        • + +
        • fix indexing error in print-everything feature from + patch #246 (patch by Ovidiu + Gheorghioiu).
        • +
        + +

        Patch #246 - + 2009/8/16

        + +
          +
        • remove obsolete logic for saving/restoring wrapping flags, + which did not work on 64-bit platform. Wrapping flags (stored + in the line-index) are now copied with line-data (Debian + #541160).
        • + +
        • modify comments in app-defaults files to avoid problem with + C preprocessor used by xrdb (Debian #541603).
        • + +
        • restore special case in makeColorPair, needed + for colorBDMode resource (Debian #541089).
        • + +
        • correct SetLineFlags() macro, broken in + patch #244 when recoding to avoid + gcc-specific bitfields (Debian #541236).
        • + +
        • modify initialization of screen buffers to ensure that + pointers align to int-boundaries. This fixes a problem + introduced in patch #244 where the + color- and character-arrays (stored after the video-attributes + in each row) might be misaligned (report by Rajeev V + Pillai).
        • + +
        • add limit-check in ScrnRefresh for handling + saved-lines from the circular buffer which are repainted on a + screen whose width has increased. To improve performance, + circular buffer entries are not resized (report by Rajeev V + Pillai).
        • + +
        • correct type for CellColor (a late change in + patch #244 to avoid gcc-specifc enums + made that unsigned rather than unsigned short, for the + 256-color option).
        • + +
        • fix typo in configure option --enable-16bit-chars (report + by Rajeev V. Pillai).
        • +
        + +

        Patch #245 - + 2009/8/12

        + +
          +
        • correct a special case in saving FIFO-lines from patch #244. If the screen was shrunk, xterm + used the wrong amount for copying to FIFO-lines, and then used + this amount to adjust the current row on the screen. That was + both a visible defect (Debian #541109) as well as a potential + addressing error (Debian #541132, Debian #541160, and Debian + #541236).
        • + +
        • add clarification in xterm manual about the various + allowXXXOps resources, which are disabled + when the allowSendEvents resource is active (patch + by Julien Cristau, Debian #531597).
        • +
        + +

        Patch #244 - + 2009/8/9

        + +
          +
        • refactored storage of saved-lines, providing a configure + option to manage them as a FIFO (actually a circular buffer), + improving performance. Added configure option + --enable-fifo-lines to enable/disable the new + feature (it is enabled by default).
        • + +
        • added fastScroll resource, to amuse people who + measure terminal emulator performance by cat'ing + large files to the screen.
        • + +
        • modify check in readPtyData from return values + to provide exit on zero-bytes read from pty for FreeBSD, or + eliminate high-CPU in "xterm-hold" processing (discussion with + Ulrich Spoerlein, FreeBSD ports/136686). The check was + originally modified to combine negative/zero values in + XFree86-3.1.2E, 1996/05/06.
        • + +
        • add configure option --enable-16bit-chars to + provide wide-characters with 16-bits (rather than the default + 32-bits).
        • + +
        • add retryInputMethod resource to allow + configuring out the retries xterm uses to connect to + non-responsive XIM server, to work around defective X + configurations as noted in + NetBSD mailing list.
        • + +
        • make regular-expression selection work for VT100 + double-sized characters.
        • + +
        • improve layout when drawing missing characters in a + proportional font, e.g., as boxes, to take into account whether + they are double-width (report by Guilbert Stabilo on + comp.unix.shell).
        • + +
        • add capability for keypad-center (kb2/KA2) to termcap entry + for xterm-new, as well as xterm-8bit, xterm-sun and xterm-vt220 + (FreeBSD conf/136336).
        • + +
        • change default for keepSelection resource to + true (prompted by discussion with David Muir Sharnoff).
        • + +
        • remove a limit-check in ptydata.c, allowing Unicode values + past 64k to be displayed using TrueType fonts (Debian + #458432).
        • + +
        • remove a vt52-specific ifdef to allow mapping F1-F4 to + PF1-PF4 when vt52 support is not compiled (report by Olaf + 'Rhialto' Seibert).
        • + +
        • save/restore line-wrapping flags when converting from + ISO-8859-1 encoding to UTF-8 encoding, as well as when resizing + screen.
        • + +
        • remove extra adjustment of position in fix for Debian + #418324.
        • + +
        • modify default check for mkWidth resource to + check for line-drawing characters, which are categorized as + double-width in Solaris 10 (report by Sebastian Kayser).
        • + +
        • add "print-everything" action (patch by Ovidiu + Gheorghioiu).
        • + +
        • start refactoring scrollback data using new getLineData() + function.
        • + +
        • demote recent change to Debian #252873 fix to experimental, + ifdef'd out as EXP_BOGUS_FG (Debian #522141).
        • + +
        • work around groff mapping of ASCII quotes using macros + (requested by Reuben Thomas based on Colin Watson advice, fixes + Debian #378700).
        • + +
        • correct symbol used for default of + allowWindowOps which was + DEF_ALLOW_FONT rather than + DEF_ALLOW_WINDOW (report by Matthieu Herrb).
        • + +
        • amend fix for tek4014 from patch + #243 to make it only apply to the Tek Options menu.
        • +
        + +

        Patch #243 - + 2009/3/28

        + +
          +
        • revert change to default for allowTcapOps + (request by Bram Moolenaar).
        • + +
        • reallocate result returned by xtermEnvLocale() + to avoid reference to freed memory after handling + menuLocale resource.
        • + +
        • fix an old (X11R5) bug in tek4014 for switching + fontsizes.
        • + +
        • add resource defaultString to make + configurable the use of "#" when pastes of UTF-8 text fail due + to limitations in the current locale settings.
        • + +
        • make the set of selection target Atom's configurable by two + new resources eightBitSelectTypes and + utf8SelectTypes, e.g., to use the + TEXT Atom in preference to + UTF8_STRING (discussion with Stanislav Sedov + regarding koi8rxterm and the FreeBSD port).
        • + +
        • modify handling of TARGETS Atom by making it + return exactly the set of targets as those which xterm is + currently providing.
        • + +
        • set MANPAGER and PAGER explicitly + to /bin/cat in minstall.sh to work around + /etc/man.conf's with those variables already set (report by + Марьясин + Семён).
        • + +
        • improve error-checking of tcap-query parser.
        • + +
        • add check for keyboard tcap), which ensures + that terminal descriptions containing the same string for + shifted/unshifted keys will be seen by tcap-query as only the + unshifted key. (This would only happen with an incorrect + terminal description).
        • + +
        • fix conversion for input event-state to modifier-parameter + which made tcap-query feature not work with + tcapFunctionKeys (keyboard type + tcap).
        • + +
        • add "DEF_ALLOW_XXX" definitions to main.h to allow + overriding the default compiled-in values for + "allowxxx" resources.
        • + +
        • remove check on bell-percentage added in patch #242, which disallowed zero/negative + values (Redhat Bugzilla #487829).
        • +
        + +

        Patch #242 - + 2009/2/15

        + +
          +
        • fix configure check for XkbBell and provide + appropriate parameter for it.
        • + +
        • fix a caching problem with double-size fonts versus reverse + video that could cause core dump.
        • + +
        • repair double-size fonts from workaround used in patch #240.
        • + +
        • add new section to the VT Fonts menu which allows enabling + or disabling the font, termcap (tcap-query), title and window + operations.
        • + +
        • add fontWarnings resource, to control whether + to show warnings on failure to load a font.
        • + +
        • improve warnings for unloadable fonts introduced in + patch #240 by limiting those to the + cases where a font would be specified directly by a resource + setting rather than a derived fontname.
        • + +
        • further amend fix for Debian #252873 from patch #197 to treat a blank cell which does + not have both foreground and background colored as a + non-colored cell. This improves a special case where the cursor + is on a blank cell which had foreground color scrolled in + (report by Miroslav Lichvar). + +

          Also add the same logic when hiding cursor, so the outline + matches the in-focus cursor.

          +
        • + +
        • modify internals to reduce places PAIRED_CHARS() is used, + making WriteText() and ScrnWriteText() accept IChar array, as + well as providing a wrapper for drawXtermText().
        • + +
        • change default XIM font from "*" to "fixed" to improve + startup time in zh_CN.UTF-8 locale (Mike Fabian, SuSE Bugzilla + #464930).
        • + +
        • typo in #240 log (Slava Semushin)
        • +
        + +

        Patch #241 - + 2009/1/26

        + +
          +
        • improve checks for missing bitmap fonts, fallback to + "fixed" as needed to work around broken font-packages (report + by Jacek Luczak).
        • + +
        • fix breakage from patch #240 + changes for xtermAddInput() (patches by Jeff Chua, + Julien Cristau).
        • +
        + +

        Patch #240 - + 2009/1/25

        + +
          +
        • use plink.sh for linking xterm (suggested by + Larry Doolittle).
        • + +
        • add resource descriptions for input method to xterm + manpage.
        • + +
        • update configure script; consistently append to $CFLAGS + rather than prepend.
        • + +
        • add install-scripts rule to makefile, to allow + koi8rxterm and uxterm scripts to be altered independently of + install-bin
        • + +
        • add -maximized command-line option and + corresponding resource (prompted by alt.os.linux newsgroup + comment).
        • + +
        • modify translations of scrollbar widget using + xtermAddInput() (see patch + #181) to accept the actions that the vt100 widget accepts, + such as shift-insert to perform a paste operation (request by + Martin Zwickel).
        • + +
        • change default for allowTcapsOps resource to + false, since it causes unexpected behavior for vim users with + AltGr.
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #239 - + 2009/1/8

        + +
          +
        • correct a cast in input.c, which broke translation of + numeric keypad codes to pageup, pagedown, etc., on 64-bit + platform (Debian #511138, report by Larry Doolittle).
        • +
        + +

        Patch #238 - + 2008/12/30

        + +
          +
        • update configure macro CF_XOPEN_SOURCE for AIX 6.x and Mint + platforms.
        • + +
        • reset the screen wrapping-flag at the end of + ClearRight to fix an occasional case where the + last character of a scrolled and wrapped line would be cleared + (patch by Joe Peterson).
        • + +
        • modify to use POSIX coding for comparing resource settings + such as locale, to work with locales such as + Turkish (report by M Vefa Bicakci).
        • + +
        • turn on configure paste64 feature by default + (request by Jean-Philippe Bernardy). It is runtime + enabled/disabled with allowWindowOps.
        • + +
        • turn on configure tcap-query feature by + default, add resource allowTcapOps to make this + runtime enabled/disabled.
        • + +
        • make OSC 3 (change X property, from patch #110) subject to + allowWindowOps resource.
        • + +
        • make VT220 DSR responses inactive in + VT100-mode.
        • + +
        • make DECUDK feature inactive in + VT100-mode.
        • + +
        • respond to incorrectly formatted DECRQSS with + a cancel.
        • + +
        • add allowFontOps resource to allow the + fontsize-switching and font query/set control sequences to be + enabled/disabled (prompted by Debian #510030).
        • + +
        • some code cleanup based on gcc 4.x + -Wconversion warnings in button.c and + charproc.c
        • + +
        • modify tcap-query feature to not return data + for shifted cursor-keys when the keyboard type is set to vt220, + since returning the same string for shifted/unshifted keys may + confuse some applications (GenToo #212546).
        • +
        + +

        Patch #237 - + 2008/09/14

        + +
          +
        • improve usability of TrueType fonts by making the font-size + switching for shifted keypad plus/minus use the + faceSize resources to determine the order of fonts + (when TrueType fonts are used) rather than the bitmap fonts, + since their sizes may not be in the same order (report by H + Merijn Brand)
        • + +
        • remove an optimization of ConfigureNotify + events from patch #236 which seems to + interfere with passing SIGWINCH to applications + (GenToo #233836).
        • + +
        • modify handling of altSendsEscape to reset the + eightBitInput mode, like + metaSendsEscape (patch by Ted Phelps).
        • + +
        • add feature to show the text-cursor as an underline rather + than a box, plus command-line options -uc and + +uc and resource cursorUnderLine to + control the feature (patch by Paul Lampert).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #236 - + 2008/07/27

        + +
          +
        • correct memory reallocation when handling a paste of UTF-8 + text from patch #225 changes + (report/patch by Max Mikhanosha).
        • + +
        • correct allocation of temporary buffer in + xtermFindShell in case the user's + $PATH contains no ":" (report/analysis by Victor + Stinner, Freedesktop.Org Bugzilla #16790).
        • + +
        • modify CF_XOPEN_SOURCE to add case for DragonFly BSD, to + fix new compile problem exposed by fix for fd_mask (patch by + Hasso Tepper).
        • + +
        • add configure-check for ncurses + use_extended_names, (report by Martin + Mokrejs).
        • + +
        • correct computation for toolbar height; layout manager + already takes into account borderWidth + resource.
        • + +
        • implement VT320-style SCS (select character set) for ISO + Latin-1 supplemental.
        • + +
        • fixes for vt100-style character sets in UTF-8 mode (Ubuntu + #230919).
        • + +
        • fix to make luit work with xterm's + -ls option (report/patch by Marius Tolzmann).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #235 - + 2008/04/20

        + +
          +
        • add control sequences for some of the recent resource/menu + settings: + +
            +
          • altSendsEscape (private mode 1039)
          • + +
          • keepSelection (private mode 1040)
          • + +
          • selectToClipboard (private mode 1041)
          • + +
          • bellIsUrgent (private mode 1042)
          • + +
          • popOnBell (private mode 1043)
          • +
          +
        • + +
        • add resource formatOtherKeys to provide an + alternate escape sequence format for the + modifyOtherKeys resource (request by Paul LeoNerd + Evans).
        • + +
        • adjust saved-cursor position if the window is resized while + displaying the alternate screen (Novell #196880, Debian + #383384).
        • + +
        • improve pointer-checks to fix a bug exposed by resizing + during initialization under StumpWM window manager (Fedora + Bugzilla #437928).
        • + +
        • modify unselectwindow() to ensure that the + mouse pointer is not hidden after xterm loses focus (report by + Jeremy Huddleston).
        • + +
        • add special check for fd_mask on Mac OS X (report by Jeremy + Huddleston).
        • + +
        • add dylib to autoconf's suffix list used for + checking the result from xmkmf, to work with Mac + OS X (report by Jeremy Huddleston).
        • + +
        • correct initialization of bold- and wide-, wide-bold fonts + which may be set via the utf8Fonts subresource + (Debian #347790).
        • +
        + +

        Patch #234 - + 2008/03/02

        + +
          +
        • modify sinstall.sh to use POSIX locale to + bypass GNU ls changes to date-format.
        • + +
        • improved/refined changes for closing bitmap font (patch by + Andrea Odetti).
        • + +
        • improve resize computation for situations where the + negotiation fails, by invoking the xterm widget's core-class + resize method (Debian #365602, patch by Jim Paris).
        • + +
        • restore initialization of terminal's VMIN and + VTIME settings, from patch + #232 changes (patch by Matthieu Herrb).
        • +
        + +

        Patch #233 - + 2008/02/24

        + +
          +
        • add configure check for ttydefaults.h, include + if needed, e.g., for systems where defining + _POSIX_C_SOURCE, etc., prevents it from being + included via termios.h (prompted by comments by + Robert Delius Royar and Jeremy Huddleston).
        • + +
        • bug-fixes for bugs.opensolaris.org (patches from Alan + Coopersmith) + +
          +
          4029911
          + +
          fix a typo in manpage
          + +
          4045962
          + +
          xterm doesn't properly set ut_syslen
          + +
          4192572
          + +
          left-left-right misinterpreted as triple click
          +
          +
        • + +
        • minor optimization to tab-initialization (patch by + Németh Márton).
        • + +
        • fix a case where an incorrect font was freed during + initialization from patch #232 changes + (patch by Andrea Odetti).
        • + +
        • improve comparison used in SameFont function + for GC-caching (Julien Cristau).
        • + +
        • correct macro name used for default CKILL + definition to work with Mac OS X (report by Jeremy + Huddleston).
        • +
        + +

        Patch #232 - + 2008/01/30

        + +
          +
        • corrected logic in a font-cache used for reverse-video + (Debian #404079).
        • + +
        • add control sequence to alter pointerMode at + runtime.
        • + +
        • add limit-checks for rectangle operation parameters (report + by Martin Pirker).
        • + +
        • modify minstall.sh to suppress + $MANPAGER and $PAGER environment + variables, which may interfere with redirecting output of + man to a shell variable (report/patch by Zdenek + Sekera).
        • + +
        • do not try to hide mouse pointer in the tek4014 window, + fixes broken "-t" option at startup from patch #230 changes (report by Robert K. + Nelson).
        • + +
        • correct datatype used when drawing tek4014 data using xterm + compiled for wide-characters, on big-endian machines (reports + by Jeremy Huddleston, Harald Hanche-Olsen, Martin Costabel, + Merle Reinhart).
        • + +
        • modify to cache the font-names along with the bitmap font + data, to improve comparison of fonts.
        • + +
        • modify to allow building with configure options + --disable-ansi-color and + --disable-leaks (Debian #459817, report/patch by + Németh Márton).
        • + +
        • modify to allow building with configure options + --enable-wide-chars and + --disable-c1-print (Debian #459816, report/patch + by Németh Márton).
        • + +
        • add pointerMode resource to control whether + and when the pointer cursor is hidden as the user types.
        • + +
        • simplify initialization of ttyMode- and related characters + using a table.
        • + +
        • modify initialization-logic for stty values that correspond + to ltchars structure and the BSD TIOCSLTC ioctl (susp, dsusp, + rprnt flush, werase, lnext). These were reset to constants for + both termios and legacy interfaces immediately after asking the + system for the existing values since X11R6.1, rather than using + them to provide inherited values. While the legacy interface + has some constraints, e.g., on HPUX, the POSIX or termios + interface should not. Your shell may reset these anyway + (prompted by patch by Ed Schouten).
        • + +
        • improve logic for hiding/displaying pointer-cursor (report + by Mark Brukhartz).
        • + +
        • add limit-checks to tabs.c, increase maximum column for + setting tab-stops from 320 to 1024 (report by Németh + Márton).
        • + +
        • correct length, i.e., number of types of selection targets, + computed by ConvertSelection() when not handling + wide characters for the XA_TARGETS() case. This + leaves an extra Atom on the end of the list which is not + handled by Java + applications. The problem was introduced in patch #151 (report by David Wood).
        • +
        + +

        Patch #231 - + 2008/01/05

        + +
          +
        • undo change to getXtermCell() from patch #230 + using PACK_PAIR macro (Debian #459014, analysis by + Caetano Jimenez Carezzato).
        • + +
        • minor documentation fixes (patch by Slava Semushin)
        • + +
        • add makefile actions to install KOI8RXTerm app-defaults + file (patch by Julien Cristau).
        • +
        + +

        Patch #230 - + 2007/12/31

        + +
          +
        • add quietGrab resource, which when true, + suppresses cursor repainting when NotifyGrab and + NotifyUngrab event types are received during + change of focus (request by Nicolas George).
        • + +
        • do not treat Unicode BIDI control characters as combining + characters (Debian #457634).
        • + +
        • add koi8rxterm, from Debian.
        • + +
        • add manpage for uxterm, from Debian (Ubuntu + #128136, Debian #438645)
        • + +
        • remove ".xpm" suffixes from Icon filenames in desktop files + since it confuses some lookups following the + Icon Theme Specification (report by Slava Semushin)
        • + +
        • correct width-calculation used for adjusting proportional + fonts, to work with wide-characters (Debian #441354).
        • + +
        • fixes/improvements for double-size characters: + +
            +
          • correct old clipping calculation which used total + height of glyphs where ascent was needed.
          • + +
          • if bold font is unavailable, fall back to normal + font
          • + +
          • adjust to "work" with Xft (which does not support + double-width single-height characters).
          • + +
          • restore reset of doublesize for a line when it is + cleared, broken in patch + #228.
          • +
          +
        • + +
        • modify logic for forceBoxChars resource when + using TrueType fonts to be consistent with bitmap fonts
        • + +
        • modify logic for forceBoxChars resource to + make the "Line-Drawing Characters" menu entry use xterm's + line-drawing characters even asked to draw wide line-drawing + characters which are available in the font.
        • + +
        • modify rectangle-support functions to preserve colors when + filling/erasing to match WRQ Reflection behavior (request by + Enzo Toscano).
        • + +
        • add getopt-parsing to tcapquery.pl, including feature to + test the extended cursor/editing keys.
        • + +
        • make missing double-width glyphs display as double-width + (Debian #456236).
        • + +
        • change tcap-fkeys and rectangles + configure options to enable them by default.
        • + +
        • hide the mouse pointer while user is typing (request by + Rodolfo Borges).
        • + +
        • extend configure options --enable-tcap-query + and --enable-tcap-fkeys to send cursor- and + editing-keypad keys modified according to the keyboard (or + termcap) selection for shift, alt, control, meta.
        • + +
        • modify kdch1 in termcap, e.g., + xterm-r6 to match the terminfo file.
        • + +
        • add -hm option to turn + highlightColorMode on or off.
        • + +
        • add highlightColorMode resource to separate + the new (since patch #225) + highlighting with both text- and background-colors (prompted by + report/example by Thomas Wolff).
        • + +
        • add Keep Selection menu entry to turn the + keepSelection resource on/off at runtime.
        • + +
        • add keepSelection resource, which when + enabled, tells xterm to retain the X selection even after it + stops highlighting it (patch by Sergey Vlasov).
        • + +
        • extend the CSI > n sequence to + allow disabling all types of modified-keys that the + CSI > m sequence affects.
        • + +
        • move include for <xtermcap.h> in + resize.c to avoid redefinition of + termios structure on OpenSolaris (report by Rahul + Gopinathan Nair).
        • + +
        • extend terminfo building blocks for modified editing keys + to include all six keys.
        • + +
        • synchronize terminfo with ncurses (report by Stephane + Chazelas) + +
            +
          • equate xterm-xfree86 and + xterm-xf86-v44.
          • + +
          • add ncurses extensions OTbs, AX, for termcap + conversions.
          • + +
          • make old/legacy entries such as xterm-24, + xterm-65 and aliases xterms, + vs100 inherit from + xterm-old.
          • + +
          • make xterm-r5 and xterm-r6 + the same, ignoring historical errors in X Consortium's + version.
          • +
          +
        • + +
        • fix an ifdef in logic for selecting regular expressions + while in a narrow-character locale (Debian #449227).
        • +
        + +

        Patch #229 - + 2007/8/12

        + +
          +
        • override locale in minstall.sh; change in patch #226 does not work in UTF-8 locale + (report by Zdenek Sekera).
        • + +
        • undo an incorrect fix for a memory leak in patch #209 (Debian #435858).
        • +
        + +

        Patch #228 - + 2007/7/22

        + +
          +
        • modify configure script to permit combining + --with-utempter and --enable-setuid, + e.g., for using xterm with the utempter library on FreeBSD + (report by Andriy Gapon).
        • + +
        • modify "Quit" menu entry to override the -hold + command-line option.
        • + +
        • add a check in the startup error-reporting to avoid writing + to pipe when it has not been opened. In that case, report + errors directly to the standard error.
        • + +
        • add OPT_READLINE definition to xtermcfg.hin, overlooked in + patch #205 (report by Kalle Olavi + Niemitalo).
        • + +
        • modify 88colors2.pl and + 256colors2.pl, adding -r option to + reverse the palettes for the extended colors.
        • + +
        • check for partial overwrite or deletion of multi-column + characters in several cases, e.g., insert-character, + delete-character, etc., and fill the remainder of the cells + used by the multi-column characters affected with blanks.
        • + +
        • correct character-class codes in wide-character mode for + characters 215, 247 (see also patch + #165).
        • + +
        • fix missing assignment for UTF-8 parsing in widget + initialization (Debian #403360).
        • + +
        • correct index expression used to set line-wrapping flag, + making selection from scrollback work consistently (Debian + #430121, report by Vincent Lefevre).
        • + +
        • amend changes to handshake in patch + #226 to accommodate Solaris, which relies on the extra + setting of the terminal size after I/O initialization. Do this + by adding new resource ptySttySize, which is false + for Linux and MacOS X, i.e., true for for Solaris and other + SVR4 platforms, as well as FreeBSD (reports by David Wood, + Renato Botelho).
        • + +
        • check for X events after cursor-left, and carriage return, + consistent with indexing operations (comments by Vegard Nossum + and Ingo Molnar on a mailing-list).
        • + +
        • initialize the .keyboard structure, needed for + some platforms (such as Solaris) after patch #227 fixes for keysyms (patch by David + Wood).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #227 - + 2007/6/27

        + +
          +
        • exclude the Intel compiler from the extra gcc warning + options added in patch #226.
        • + +
        • modify change for Debian #422521 from patch #226 to work with configurations where + the X server does not recognize the XF86Paste or + SunPaste keysyms (report by Paolo Pumilia).
        • + +
        • fix incorrect free in fix for "Selection" menu entry in + patch #226.
        • +
        + +

        Patch #226 - + 2007/6/17

        + +
          +
        • add configure check to use + -Wno-unknown-pragmas for Solaris, and a few other + new gcc warning options to address regressions in its warning + options.
        • + +
        • add sample desktop and icon files, along with configure + options for manipulating them.
        • + +
        • fix an infinite loop when showing a 2-column character in a + 1-column screen (Debian #426863).
        • + +
        • add XF86Paste and SunPaste to the + default translations (Debian #422521, patch by Bernhard R + Link).
        • + +
        • update wcwidth.c (partly based on/prompted by mailing list + comment).
        • + +
        • update/improve keysym2ucs.c based on Unicode 5.0.1d3 and + Xorg 7.1 keysymdef.h file.
        • + +
        • improve gen-pc-fkeys.pl, making it show all of + the building-block terminfo entries used by xterm.
        • + +
        • correct strings used for modifiers applied to F1-F4 in + xterm+pcf1 terminfo entry.
        • + +
        • improve session management by adding the ICE connection + number to the select call rather than waking up + once per second (patch by Miroslav Lichvar).
        • + +
        • add environment variable $XTERM_LOCALE to help + with shell initialization, e.g., to set a specific locale for + xterm on systems where a global locale is set in the shell + startup scripts.
        • + +
        • add resource settings mkSampleSize and + mkSamplePass to modify the mkWidth + added in patch #201. In patch #202, xterm would also check if the + system's wcwidth matched its built-in tables "well + enough" to be used when mkWidth was false, and if + not would use the built-in tables anyway. These resources allow + the user to customize the decision (prompted by comments by + Emanuele Giaquinta)
        • + +
        • modify logic which resets/updates the screensize on the + child process side of the pseudo-terminal to do this only if a + successful handshake was received, e.g., as determined by the + waitForMap resource (prompted by reports by + Emanuele Giaquinta and Bernhard R Link, but see also patch #177 and patch + #159.
        • + +
        • improve permissions logic when closing pseudo-terminal + (Debian #12261, patch by Nathanael Nerode, analysis by Richard + Braakman).
        • + +
        • add resource highlightReverse which controls + whether xterm will allow selection highlighting to hide + reverse-video or use the older behavior which inverts the + foreground and background colors when selected text with + reverse-video attribute (report by Adam M Costello, comments by + Victor Vaile).
        • + +
        • restore a special case for cursor-color in + ReverseVideo() lost in rewrite for patch #224 (report by Adam Sulmicki).
        • + +
        • correct initialization for menu entry for + bellIsUrgent (patch by Emanuele Giaquinta).
        • + +
        • correct length of underlining for double-width Xft fonts + (report by Shidai Liu "Leo").
        • + +
        • correct clipping for double-width Xft fonts (report by + Shidai Liu "Leo").
        • + +
        • modify initialization for italicULMode to + avoid XftPatternBuild reusing bold attributes + (report by Shidai Liu "Leo").
        • + +
        • add a check in case someone tries to call the + popup-menu() action on a menu which is not + initialized (Debian #426364).
        • + +
        • improve CF_IMAKE_CFLAGS to work with Solaris sed (report by + Peter Bray).
        • + +
        • improve guess for X's manpage section in + minstall.sh, (prompted by comment by Miroslav + Lichvar).
        • + +
        • modify minstall.sh to handle manpage patch + with more than one dot (patch by Miroslav Lichvar).
        • + +
        • fix configure message for --disable-setgid option (patch by + Miroslav Lichvar).
        • + +
        • add allowTitleOps resource to allow users to + prevent the title- and icon-names from changing (request by + John Bashinski).
        • + +
        • fix "spawn-new-terminal" action, for the case where no + parameter is passed to the action (patch by Daniel + Colascione).
        • + +
        • fix error-checking on internal font switching for + "Selection" menu entry (Debian #421523).
        • + +
        • amend select/paste change from patch + #225 by limiting it to non-UTF-8/non-KOI8-R encoding + (Debian #420974).
        • + +
        • add workaround for groff ".URL" codes which are not present + in some commonly-used bitmap fonts (Debian #418324).
        • +
        + +

        Patch #225 - + 2007/3/24

        + +
          +
        • add useClipping resource to allow clipping to + be disabled.
        • + +
        • use XftDrawSetClipRectangles to work around + Xft pixel-trash (report by Reuben Thomas).
        • + +
        • add configure option --enable-tcap-fkeys, and + resource tcapFunctionKeys, which can be used to + tell xterm to use function-key definitions from the termcap (or + terminfo) which it uses to set $TERM on startup.
        • + +
        • add resources altIsNotMeta and + altSendsEscape to allow one to use Alt-keys like + the meta-key even if they are bound to different keycodes + (prompted by discussion with Daniel Jacobowitz).
        • + +
        • revert a change from patch #216 + that unnecessarily made the meta modifier override the + eightBitInput resource if the alt- and + meta-modifiers happened to overlap (report/patch by Daniel + Jacobowitz).
        • + +
        • correct associated font for active icon for colored text + (broken in patch #224).
        • + +
        • correct ifdef's for Darwin (patch by Emanuele + Giaquinta).
        • + +
        • add highlightTextColor resource, and options + -selfg, -selbg like xwsh + (adapted from patch by Victor Vaile).
        • + +
        • revise find_closest_color() function to + address concern about borrowing from Tcl/Tk + (request by Dan McNichol).
        • + +
        • add "spawn-new-terminal" action, which can be assigned to + key translation, allowing one to spawn a new copy of xterm + using the current process' working directory (adapted from + patch by Daniel Colascione).
        • + +
        • improve select/paste between UTF-8 and Latin1 xterms by + adapting the translations from patch + #185. Extend that to include Unicode fullwidth forms + FF00-FF5E. Also modify select/paste of DEC line-drawing + characters in Latin1 mode to use ASCII characters.
        • + +
        • add "Enable Bell Urgency" to VT Options menu, removed + "Enable Margin Bell".
        • + +
        • add bellIsUrgent resource to control whether + the Urgency hint is set/reset.
        • + +
        • modify to set Urgency window manager hint on bell, reset it + on Focus-In event (patch by Emanuele Giaquinta).
        • + +
        • add --disable-setgid configure option (request + by Miroslav Lichvar).
        • + +
        • fix a possible infinite loop in last change to + dabbrev-expand() (patch by Emanuele + Giaquinta).
        • + +
        • modify initialization to set the pty erase value if the + erase is set in the ttyModes + resource. This overrides the ptyInitialErase + setting (request by Lluís Batlle i Rossell).
        • + +
        • add initialFont resource to xterm widget, like + tek-widget (Debian #299669).
        • + +
        • amend change to boldMode from patch #223 for Debian #347790. As noted in + Debian #412599, that made xterm no longer match the documented + behavior. Add new resource alwaysBoldMode to allow + overriding the comparison between normal/bold fonts when + deciding whether to use overstriking to simulate bold + fonts.
        • + +
        • restore background color in ClearCurBackground(), omitted + in changes for patch #223 (report by + Miroslav Lichvar).
        • + +
        • correct logic for repainting double-width TrueType + characters (prompted by test-case for Novell #246573).
        • + +
        • add a check to avoid trying to repeat a multibyte character + (report by Sami Farin).
        • + +
        • modify parameter to XftNameParse() to select + wide face-name as needed, to make -fd option work + (patch by Mike Fabian, Novell #246573).
        • + +
        • correct logic for mouse highlight tracking's abort + sequence, broken in a restructuring modification from patch #224 (report by Thomas Wolff).
        • + +
        • revert the simplification of blinking cursor, since that + broke the xor'ing introduced in patch + #193 (report by Thomas Wolff).
        • +
        + +

        Patch #224 - + 2007/2/11

        + +
          +
        • simplify code for set/reset mode for blinking cursor (patch + by Emanuele Giaquinta).
        • + +
        • modify dabbrev-expand() to restart after the + last match (patch by Emanuele Giaquinta).
        • + +
        • add control sequences for enabling/disabling focus in/out + event reporting (request by Bram Moolenaar).
        • + +
        • improve startup performance of menus by adding resource + setting menuLocale which can be set to override + X's lengthy initialization of fontsets - which are seldom used + for the Xaw popup menus (adapted from patch by + Dave Coffin).
        • + +
        • modify do_precomposition() function and make-compose.sh to + handle 21-bit codes vs the 16-bit codes those were written for, + and fix a few mis-sorted codes (patch by Thomas Wolff).
        • + +
        • handle special case in -cjk_width which + unexpectedly caused a character's width to change when a + combining character (patch by Thomas Wolff)
        • + +
        • fix build for GNU/KFreeBSD (Debian #40111).
        • + +
        • consolidate GC creation/updating into a single module to + reduce GC manipulation (prompted by Debian #389476, though a + complete fix would involve optimizing the scrolling + behavior).
        • + +
        • fix ifdef of xtermCellWidth(), which broke for a case + without TrueType and without wide-character support (report by + Martin Pirker).
        • + +
        • 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 (Debian #401726, + Redhat Bugzilla #223027).
        • + +
        • allow -cr option to override cursor color when + -ah option is used (Debian #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 (Debian #405043).
        • + +
        • make Selection of VT Fonts + work with selectToClipboard resource.
        • + +
        • correct length calculation for Selection entry + of VT Fonts menu, broken since it ignored the + actual selection length since X11R4.
        • + +
        • fixes for fontsize changes with -fa option + (Redhat Bugzilla #222340).
        • +
        + +

        Patch #223 - + 2006/11/30

        + +
          +
        • add --enable-rectangles configure option + (request by Martin Pirker).
        • + +
        • correct default value for --with-symlink + configure option.
        • + +
        • fixes configure script macros that use + $X_EXTRA_LIBS.
        • + +
        • modify configure script to provide support for pre-package + config versions of Xft aka "FreeType".
        • + +
        • add the Xaw scrollbar translations resource to the xterm + manpage, add an example showing how to change the mouse button + assignments (Debian #382225).
        • + +
        • amend a change from patch #216, + which omitted modifiers for control, meta, etc., if they were + mixed with any other modifiers. The intent of the change was to + avoid confusion with XK_Mode_switch and + XK_ISO_Level3_Shift; the check is now done + explicitly (report by Daniel Jacobowitz).
        • + +
        • interpret a negative value for + modifyCursorKeys or + modifyFunctionKeys resources to disable the + respective features (prompted by Novell #220728).
        • + +
        • amend cell-width computation for FreeType from patch #217, which did not work for VT100 + line-drawing characters (Debian #399638, GenToo #147111).
        • + +
        • amend a change from patch #216, + which made alt-modifier on a cursor-key send a modifier + parameter (Novell #220728).
        • + +
        • correct an off-by-one that made DECCRA not work + (report/patch by Martin Pirker).
        • + +
        • revert an optimization in SGR_Foreground() and + SGR_Background from patch #209 (Debian + #347722, analysis by Pierre Lombard).
        • + +
        • fix for boldMode (Debian #347790, patch by Tim + Pope).
        • + +
        • amend fix for -iconic in patch #208, which broke the positioning part + of -geom with toolbar configuration.
        • + +
        • fix to prevent indexing error in regular expressions (patch + by Dennis Schneider).
        • + +
        • 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 + (report by Neil Hoggarth, also Debian #397624).
        • +
        + +

        Patch #222 - + 2006/10/17

        + +
          +
        • minor optimization for recoloring cursor via dynamic + colors.
        • + +
        • fix a bug caused by restructuring of tek4014 widget (report + by Paul Schenkeveld)
        • +
        + +

        Patch #221 - + 2006/10/1

        + +
          +
        • fix for regular expressions: the code which converted the + column offset within a line did not check properly for the end + of a line, and if allowed to match the whole line, would select + the beginning of the following line. If the following line were + empty, in turn it would select from the next, etc. (report by + Sean Reifschneider).
        • + +
        • minor optimization of color allocation to avoid repainting + the screen if the corresponding color had not been + allocated.
        • + +
        • fixes for vttests/256colors.pl (report by Egmont + Koblinger).
        • + +
        • add terminfo building block entries for modifiers of the + 6-key editing keypad.
        • + +
        • fix for initialization of tek4014 which broke on QNX + 6.1
        • +
        + +

        Patch #220 - + 2006/9/10

        + +
          +
        • make "xterm -t -iconic" work as expected, i.e., start in + tek4014 mode, but iconified.
        • +
        + +

        Patch #219 - + 2006/9/4

        + +
          +
        • some internal restructuring to separate data for vt100 and + tek4014 widgets.
        • + +
        • fix a few cases where form-events would be seen by the + vt100 widget when built with the toolbar configuration.
        • +
        + +

        Patch #218 - + 2006/8/27

        + +
          +
        • change behavior when encountering an illegal character in a + title string. Rather than reject the string, translate illegal + characters into "?" and use the string (requested by Thomas + Wolff).
        • + +
        • improve checks for nonprinting characters in title strings + (report by Samuel Thibault).
        • + +
        • correct typo in menu labels, changing + print-redirect to print-redir, making + it follow the manpage and match the usage for the actions table + (report by Samuel Thibault).
        • + +
        • correct a typo that prevents building with some older + systems such as Solaris 2.6 (report by Julian Bridle).
        • +
        + +

        Patch #217 - + 2006/8/20

        + +
          +
        • minor improvements to FreeType font layout and + drawing.
        • + +
        • add a check in the ptyInitialErase logic to ensure that the + termcap was read (Redhat Bugzilla #201246).
        • + +
        • limit changes for reverse-video from patch #216 to cases where the reverse-video + command-line option is used (report by Zdenek Sekera).
        • + +
        • correct bitmap-derived pointsizes for TrueType fonts; they + should be proportional to the square root of the area of the + bitmap fonts.
        • + +
        • add resources to specify pointsize of TrueType fonts + (request by Reuben Thomas).
        • + +
        • improve install of terminfo by filtering out harmless + messages related to extended capabilities. At the same time, + use ncurses tic to compile the extended capabilities if + possible (report by Zdenek Sekera).
        • + +
        • update "xterm+pcfkeys" terminfo entry to correspond to + patch #216.
        • +
        + +

        Patch #216 - + 2006/8/3

        + +
          +
        • improve handling of ConfigureNotify events by + checking if there are further events in the queue which + obsolete the current one (adapted from rxvt 2.7.5). Only the + normal normal (non-toolbar) configuration is addressed in this + patch.
        • + +
        • several changes to terminfo: + +
            +
          • incorporate some minor changes from ncurses to help + keep these synchronized: + +
            +
            2005-02-26
            + +
            modify sgr/sgr0 in xterm-new to improve tgetent's + derived "me".
            + +
            2006-02-18
            + +
            remove ncv flag from xterm-16color
            + +
            2006-06-24
            + +
            improve xterm-256color by combining the 16-color + setaf/setab strings with SGR 48, and cancelling the + setf/setb strings.
            +
            +
          • + +
          • use extended function-key definitions for xterm-sun, + xterm-sco entries.
          • + +
          • add terminfo building-blocks corresponding to the + modifyFunctionKeys and + modifyCursorKeys resources.
          • +
          +
        • + +
        • ifdef'd Sun function-key feature to make it optional, like + HP and SCO.
        • + +
        • extend table for termcap-query feature through F63, and + updated tcapquery.pl to match.
        • + +
        • modify logic for function-key input processing to allow + function key numbers which are constructed by control- and + shift-modifiers to extend beyond X's hardcoded limit of + 35.
        • + +
        • add control sequence to set or reset the + eightBitInput resource.
        • + +
        • change default resource modifyFunctionKeys to + 2 to avoid sending SS3 with parameters (report by Kalle Olavi + Niemitalo).
        • + +
        • add control sequences for setting and resetting the values + of the modifyCursorKeys, + modifyFunctionKeys and + modifyOtherKeys resources.
        • + +
        • add modifyFunctionKeys resource like + modifyCursorKeys. Setting this to zero allows one + to use the control- and shift-modifiers to construct function + key strings, for terminals using many function keys, e.g., for + xterm-sun or xterm-sco.
        • + +
        • modify screen responses and function-key logic to reduce + the number of writes made, to make it less likely that an + application would read only part of a function-key in a read + operation (suggested by John E Urbanczyk).
        • + +
        • add combiningChars resource, which allows the + user to specify the maximum number of combining characters that + xterm will store for each cell in wide-character mode (prompted + by request by Markus Kuhn to increase the limit from 2).
        • + +
        • improve logic in metaSendsEscape in case the + Alt- and Meta-keys are mapped to different modifiers. That + allows one to use the Alt-key for shifting in the + eightBitInput and use a Meta-key modifier to + prefix the result with an <ESC>.
        • + +
        • improve modifyCursorKeys logic to prevent it + from modifying codes where eightBitInput or + metaSendsEscape are set (request by Dan + Nicolaescu).
        • + +
        • improve modifyCursorKeys logic to prevent it + from changing the user input when other modifiers such as AltGr + are used (report by Thomas Wolff).
        • + +
        • extend modifyCursorKeys to include the numeric + keypad when in application mode.
        • + +
        • improve -reverse (-rv) option + (patch by Jason Vas Dias, Redhat #189161).
        • + +
        • workaround for color resources on Fedora-5 which made the + toolbar colors inconsistent.
        • + +
        • corrected calls used for --disable-setuid + option, add debugging traces to help diagnose this area.
        • + +
        • modify configure script to ensure that + USE_UTMP_SETGID is defined only if the check for + POSIX saved-ids succeeds, or corresponds to one of the BSD + systems known to have a workable setegid + function.
        • + +
        • extend configure check for POSIX saved-ids to include BSD + systems
        • + +
        • modify CF_SYSV configure macro to work with gcc on HPUX + 10.20, whose broken <term.h> relies on + including <termios.h>.
        • + +
        • change order of setuid/setgid ifdef checks in Imakefile to + make it simpler to produce a setgid install, allowing the + latter to override the former (prompted by an XFree86 + commit).
        • + +
        • adapt a fix for setgid support from subsequent XFree86 + changes (patch by Emanuele Giaquinta).
        • + +
        • further improve setgid support (patches by Emanuele + Giaquinta).
        • +
        + +

        Patch #215 - 2006/6/19 - + XFree86 4.6.99.2

        + +
          +
        • improve setgid support by exploiting the saved-ids feature + on which it relies (patch by Emanuele Giaquinta).
        • + +
        • make the modifyOtherKeys resource disabled by + default since the intermediate setting altered some common + bindings (report by Emanuele Giaquinta).
        • +
        + +

        Patch #214 - 2006/6/18 - + XFree86 4.6.99.2

        + +
          +
        • modify makefile rule for ctlseqs.txt to strip + backspace/overstrikes, and add a copy of ctlseqs.txt to the + source tarballs (requests by Bram Moolenaar, Emanuele + Giaquinta).
        • + +
        • add modifyOtherKeys resource, analogous to the + modifyCursorKeys resource. This applies to keys + that normally would transmit nothing when a given modifier is + applied (request by Dan Nicolaescu).
        • + +
        • add default to the acceptable values for the + keyboardType resource, allowing the + -kt command-line option to override app-defaults + resource settings of sunKeyboard, etc.
        • + +
        • correct ifdef's for XkbBell() which used the + header file but not the corresponding function in patch #175 (report by Zach Beane).
        • + +
        • add xterm manpage to the --with-symlink + logic.
        • + +
        • regenerated configure script to omit some debugging + artifacts of the SIGWINCH test.
        • + +
        • fix install-man rule in + Makefile.in to avoid including the + $(DESTDIR) value in substitutions made on the + manpages (patch by Emanuele Giaquinta).
        • + +
        • improved fix for cursor deallocation (Redhat #186935, patch + by Jason Vas Dias).
        • + +
        • improve checks for setuid/setgid operation to accommodate + limited resource management in some kernels (GenToo + #193238).
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #213 - 2006/4/30 - + XFree86 4.5.99.905

        + +
          +
        • minor optimization to cell layout; will use that to + simplify some logic and allow for more than two combining + characters in another patch.
        • + +
        • add utf8Latin1 resource to make optional the + feature from patch #209 which allowed + ISO-8859-1 fonts to be used in cases where a wide font was + given. This would only work for the special case where the user + normally used Latin-1 and wanted some wide characters (report + by Rostislav Krasny).
        • + +
        • add utf8Title resource to manpage (Novell + #52655).
        • + +
        • fix typo in table entry for utf8Title resource + which made it treated as an integer rather than boolean (patch + by Mike Fabian, Novell #52655).
        • +
        + +

        Patch #212 - 2006/4/9 - + XFree86 4.5.99.904

        + +
          +
        • improve description of forceBoxChars in + manpage (discussion with Joe Wells).
        • + +
        • set checkmark for "Select To Clipboard" menu entry on + startup, from resource setting.
        • + +
        • update manpage to note that + *customization:color is not needed, though it is + useful (Redhat #188034).
        • + +
        • add underscore to sample pattern for URL in + XTerm.ad (Redhat #188037).
        • + +
        • modify install rule for manpage to use the configured + app-defaults directory (Redhat #188031).
        • + +
        • add checks in releaseCursorGCs() to ensure + GC's are distinct, needed since memory leak changes for + patch #208 (Redhat #186935, patch by + Jason Vas Dias).
        • + +
        • modify Imakefile definitions to allow + imake to set InstallXtermSetGID. Add + symbol InstGidFlags.
        • + +
        • add configure script check to ensure that SIGWINCH if + defined even when headers undefine this as a side-effect of + _POSIX_C_SOURCE, etc.
        • + +
        • resync with XFree86 CVS + +
            +
          • ifdef-out chmod of terminal device for OS/2 (XFree86 + #1663, Frank Giessler).
          • + +
          • move new Imakefile chunk which defines + $(CSGIDFLAGS) before DEFINES, e.g., for IRIX64 + (Marc La France).
          • +
          +
        • +
        + +

        Patch #211 - 2006/3/19 - + XFree86 4.5.99.902

        + +
          +
        • modify prefix/suffix transformation in makefile to make + uxterm install properly on Cygwin.
        • + +
        • restore the sizeof-comparison for struct + lastlog added in patch #208, + rendered (mostly) obsolete in patch + #210, since an imake configuration can still turn that code + on (prompted by comment by David Dawes).
        • + +
        • remove feature for FreeBSDArchitecture from + Imakefile which would install xterm using the + utmp group since a standard FreeBSD system has no + such group, though it would support this configuration. FreeBSD + packager uses the configure script, which can make + the appropriate check (prompted by comment by David + Dawes).
        • + +
        • fixes for gcc redefinition warnings when built using imake + (reports by David Dawes, Marc La France).
        • +
        + +

        Patch #210 - 2006/3/12 - + XFree86 4.5.99.902

        + +
          +
        • add configure check for workaround in patch #208 for Solaris' inconsistent support + for struct lastlog to quiet compiler warnings (prompted by + David Dawes commit message for XFree86).
        • + +
        • fixes for BASE64 selection manipulation, e.g., ensure that + the string terminator is written after cut-buffer data (report + by Joe Allen).
        • + +
        • add vttests/paste64.pl script to test experimental option + for setting/getting selection data.
        • + +
        • add some error-checking in fontutils.c (prompted by David + Dawes commit message for XFree86).
        • + +
        • change xterm manpage to show the actual color resource + names XtDefaultForeground and + XtDefaultBackground rather than black and white + (prompted by discussion with Emanuele Giaquinta).
        • + +
        • add utf8Title resource and menu entry, + allowing the user to control whether title strings are + interpreted as ISO-8859-1 or UTF-8 encoding (Novell #52655, + Novell #113206).
        • + +
        • change order of ifdef's for utempter versus platforms in + Imakefile to ensure a proper value for + InstallXtermSetGID (prompted by Marc La France + commit message for XFree86).
        • + +
        • update the cursor GCs when menu entry for reverse video is + toggled. (Redhat #183993).
        • + +
        • a memory-leak fix for set_cursor_gcs() in + patch #208 broke the -cm + option (Redhat #182382).
        • +
        + +

        Patch #209 - 2006/2/12 - + XFree86 4.5.99.22

        + +
          +
        • remove setf and setb from + xterm-256color terminfo entry to avoid issues with + applications that ignore the ANSI strings (report by Emanuele + Giaquinta).
        • + +
        • remove obsolete references to "Xorg" to avoid confusion + with "X.org" (prompted by David Dawes commit message for + XFree86).
        • + +
        • improve initial layout performance for the toolbar + configuration by precalculating the height of the toolbar.
        • + +
        • remove menu entry for "Enable Curses Emulation" (to make + room for "Select To Clipboard").
        • + +
        • add resource selectToClipboard, action + set-select and a menu entry to allow users to + switch between PRIMARY and CLIPBOARD for select/paste.
        • + +
        • allow cursor to have the same color as foreground (text), + since it is rendered as reverse (Debian #350664).
        • + +
        • amend change for loading utf8Fonts resource + from patch #204 to allow an ISO-8859-1 + "normal" font to be combined with an ISO-10646 font if the + latter is given via the -fw option or its + corresponding resource value (prompted by comment in Novell + #49305).
        • + +
        • add TIOCSCTTY ioctl() ifdef'd for + __GNU__ to set the controlling terminal (Debian + #348457).
        • + +
        • add configure option --disable-leaks.
        • + +
        • add a check in Bell to ensure that the VT100 + widget is realized, since it may be called by + xtermLoadFont given an incorrect font resource + (Redhat #180450).
        • + +
        • improve initialization of wide-bold font by not using the + derived value when it happens to have few glyphs (report by + Mboso Sampson).
        • + +
        • improve dynamic colors by not repainting the screen if only + the cursor color changes (request by Bram Moolenaar).
        • + +
        • fix menu initialization for tek4014 window broken in + patch #206.
        • + +
        • typo in manpage (Debian #351425).
        • + +
        • correct loop logic in dotext to prevent an + infinite loop if a wide character was just at the right margin + when wrapping was disabled (report by Serge van den Boom).
        • + +
        • initialize the saved-cursor data so a restore-cursor + operation without a preceding save-cursor operation will not + modify the foreground color.
        • + +
        • add a new selection feature: regular expressions, and new + resources which specify what happens on multiple mouse clicks: + on2Clicks, on3Clicks, + on4Clicks and on5Clicks.
        • + +
        • revert the XTerm.ad change from patch #208 (Debian #348384).
        • + +
        • fixes for the print-window to make it handle combining + characters in UTF-8 mode.
        • + +
        • 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 (Debian + #347415).
        • + +
        • add configure option --with-tty-group to help + work around deficiencies in packager's build environment + (Debian #349142).
        • + +
        • fix typo in configure script option + --disable-narrowproto (report by David + Martínez Moreno).
        • + +
        • amend CF_X_FREETYPE changes for pkg-config + check to ensure that Xft is known to that tool + (report and patch by Emanuele Giaquinta).
        • + +
        • add an ifdef to allow ./configure + --disable-active-icon to work, broken by new code for + testing memory leaks in patch #208 + (report by Brian Lindholm).
        • +
        + +

        Patch #208 - 2006/1/3 - + XFree86 4.5.99.19

        + +
          +
        • add charClass resource to + XTerm.ad and UXTerm.ad which + simplifies selecting URLs (prompted by Kirill Ponomarew).
        • + +
        • modify install rule for uxterm to account for + the --program-prefix, etc., options by invoking + the transformed name of xterm rather than simply "xterm".
        • + +
        • modify configure --with-app-defaults option to + allow --without-app-defaults.
        • + +
        • add configure --with-symlink option to make it + simpler to install successive versions of xterm + renamed using the --program-prefix, etc., options + with a symbolic link pointing to the most recent.
        • + +
        • make -iconic option work with toolbar + configuration (GenToo #113604).
        • + +
        • suppress lastlog feature for 64-bit Solaris + configuration since that platform provides only a 32-bit + interface (report by Peter Bray).
        • + +
        • fix memory reallocation for the "UTF-8" menu entry when + xterm is started using the +u8 option (reported by + Jan Willem Stumpel).
        • + +
        • add a configure check for the actual path of + luit, to work around broken imake + configurations.
        • + +
        • add a configure check for pkg-config (Redhat + Bugzilla #173541).
        • + +
        • modify install-rule for uxterm to omit + executable suffix, e.g., for Cygwin.
        • + +
        • modify sinstall.sh to work around quirks in + Cygwin configuration.
        • +
        + +

        Patch #207 - 2005/11/13 - + XFree86 4.5.99.16

        + +
          +
        • enable lastlogx support for NetBSD (was added, + but not enabled in patch #186).
        • + +
        • work around broken lastlog.h in glibc 2.3.5, + which includes utmp.h.
        • + +
        • revert part of recent XFree86 Imakefile change, restoring + the -I. needed for xmkmf builds of + xterm (XFree86 Bugzilla #1633, reports by Alexander Pohoyda, + Matthieu Herrb).
        • + +
        • change compiled-in default for printerCommand + resource to an empty string. People who want to use the printer + should be able to read the manual (Debian #311490).
        • + +
        • modify Imakefile to work around old problems + in imake configuration to allow test-builds using + xmkmf on Linux. (This was not noticed since + several releases had broken definitions relating to Xft which + were harder to work around).
        • + +
        • link resize for SCO platforms (Kean + Johnston).
        • +
        + +

        Patch #206 - 2005/11/3 - + XFree86 4.5.99.15

        + +
          +
        • add configure --with-app-defaults option to + allow app-defaults directory for install-rules to be + customized.
        • + +
        • remove default translations for + dabbrev-expand() due to conflicts with existing + keyboard arrangements.
        • + +
        • remove redundant check for _NET_WM_PID (report + by Emanuele Giaquinta).
        • + +
        • set icon border width explicitly to work around fvwm + problem with active icon resizing (report by Steve Morris, + analysis by Dominik Vogt).
        • + +
        • 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 (Debian #319179).
        • + +
        • add --enable-narrowproto configure option to + accommodate X.org "modular" build (report by Stephan Hermann, + GenToo #17220).
        • + +
        • fix typo in xterm.man description of +wf + (patch by Tobias Stoeckmann).
        • + +
        • add scrollBarBorder resource (request by Floyd + L Davidson).
        • + +
        • modify xterm-new terminfo entry to use + capabilities for shifted scroll forward/reverse as shifted + cursor up/down.
        • + +
        • correct updating of checkmark for toolbar entry in popup + menu (report by Emanuele Giaquinta).
        • + +
        • fix ifdef's to allow compiling with toolbar and without + tek4014 (patch by Emanuele Giaquinta).
        • + +
        • use openpty() for Darwin port (patch by + Emanuele Giaquinta).
        • + +
        • fix GenToo #90697 a different way, postponing the logic in + SetupToolbar until the toolbar is actually needed, + i.e., the +tb option is handled as expected.
        • + +
        • revert fix made in patch #203 for + GenToo #90697. That introduced a problem with the control mouse + click-popups, while most of the performance problems can be + resolved by restricting the menu fonts (report by Emanuele + Giaquinta).
        • + +
        • fix a file-descriptor leak when calling + openpty() (OpenBSD system/4561).
        • + +
        • make a special case of resizing work like vt100: a hard + reset also resets the 132/80 mode. The code to support this was + present since X11R5, but not used because the corresponding + initial state of the -132 option was not + saved.
        • + +
        • restore window manager hints after + XtMakeResizeRequest() calls. One instance from + patch #205 resulted in the window + manager displaying pixels rather than than characters after + selecting a different font size (FreeBSD ports/87424).
        • + +
        • remove special case for Darwin in CF_XOPEN_SOURCE (Emanuele + Giaquinta).
        • + +
        • modify parsing of control sequence CSI T + to allow scroll-down to be sent while mouse tracking is enabled + (request by D Hugh Redelmeier).
        • + +
        • correct termcap "me" (mode-end) string so it does not + modify the alternate character set (report by Andrey + Chernov).
        • + +
        • correct size-comparison in HandleInterpret() broken in + changes from patch #201 to allocate + input buffer (Debian #334317).
        • + +
        • amend adjustments for scrollbar layout from patch #204 to make this apply only to the + toolbar configuration. In the non-toolbar configuration, the + resulting scrollbar was shifted by its borderwidth (report by + Matthieu Herrb).
        • + +
        • add select-cursor-extend() action.
        • + +
        • fix some broken href's in xterm.log.html, and typo in the + INSTALL file (report/patch by David Martínez + Moreno).
        • + +
        • modify Imakefile to use setgid mode for + installing with Linux, OpenBSD and FreeBSD.
        • + +
        • add configure --with-setuid and --with-reference options to + allow packagers more flexibility in customizing install + permissions.
        • + +
        • generalize and make optional (configure --with-utmp-setgid) + the change made for XFree86 Bugzilla #878 in patch #205 (FreeBSD bug report + #ports/86663).
        • +
        + +

        Patch #205 - 2005/9/18 - + XFree86 4.5.99.12

        + +
          +
        • correct a typo in CF_FUNC_TGETENT introduced in patch #198 fix for Gentoo #69926.
        • + +
        • 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 (patch by Bradd W. + Szonye).
        • + +
        • add configure option --enable-readline-mouse, which turns + on the experimental OPT_READLINE code (patch by Ilya + Zakharevich).
        • + +
        • for FreeBSD, drop setuid privileges after startup (XFree86 + Bugzilla #878, report/patch by Alexander Pohoyda)
        • + +
        • add menu entry (alt-esc) and corresponding action + (alt-sends-esc) to toggle the eightBitInput + resource setting.
        • + +
        • generate configure script with autoconf 2.52 (patched) to + use the feature therein which forces the script's locale to + POSIX (Gentoo Bugzilla #105369).
        • + +
        • 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 (Debian #289123, Novell + #61153).
        • + +
        • modifications to work with z/OS 1.4 (Paul Giordano).
        • + +
        • improve error-reporting when chown/chmod of the + pseudo-terminal fails, e.g., if a copy of xterm which was + designed to work with old-style pseudo-terminals is not + installed setuid or setgid (report by Jeremy C. Reed).
        • + +
        • patches from Emanuele Giaquinta: + +
            +
          • ctlseqs.ms says that primary and secondary DA accept a + nonzero parameter, which is incorrect. Also modify code to + agree with this.
          • + +
          • correct a comment in 88colres.pl
          • + +
          • ctlseqs.ms says that the DEC Set/Reset control + sequences for the backarrow key make it send DEL/BS, + respectively, while it's the opposite.
          • + +
          • update the menu entries for the metaSendsEscape, + deleteIsDEL and numLock resources when changing them with + the corresponding DEC Set/Reset control sequences.
          • +
          +
        • + +
        • fixes for configure script: + +
            +
          • add special case for QNX, defining _QNX_SOURCE.
          • + +
          • check for preprocessors which do not perform -U and -D + options in the given order.
          • + +
          • improve macro to determine gcc version
          • + +
          • improve check for Intel compiler and related warning + options
          • +
          +
        • + +
        • update config.guess, config.sub
        • + +
        • improve fix from patch #198 for + Cleanup() by ensuring it is not called from the + SIGCHLD handler (patch by Todd Miller (OpenBSD CVS)).
        • + +
        • eliminate a retry for a better-matching bold font, to work + around recent font server changes.
        • + +
        • fixes for Novell #113277: + +
            +
          • specify weight for wide font which may be derived from + normal fontname.
          • + +
          • cache the derived wide- and widebolt-fontnames.
          • +
          +
        • + +
        • workaround for GenToo Bugzilla #100728.
        • + +
        • add menubar's border width to layout computation. Normally + this is zero, but patterns such as + XTerm*borderWidth:1 would give poor layout for the + toolbar configuration.
        • +
        + +

        Patch #204 - 2005/8/4 - + XFree86 4.5.99.9

        + +
          +
        • 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 (Debian #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 #90717, Gentoo #91967).
        • + +
        • minor improvements to scrollbar layout: ensure that the + scrollbar border is zero if the vt100 border is zero.
        • + +
        • 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, loads 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 (Debian #318162, patch by Eugene Konev).
        • + +
        • add checks to ensure vt100 widget is realized when it might + be updated via actions handled from a tek4014-only + configuration.
        • +
        + +

        Patch #203 - 2005/7/6 - + XFree86 4.5.99.7

        + +
          +
        • modify initialization of allowSendEvents and + allowWindowOps to prevent modification with the + editres protocol.
        • + +
        • fix compiler warning for NetBSD by including util.h in + main.c (XFree86 Bugzilla #1596).
        • + +
        • fix to build on Darwin 8.x, which no longer provides + setpgrp() (patch by Min Sik Kim).
        • + +
        • adapted fixes for Legend (SCO) from diffs attached to + Freedesktop.Org Bugzilla #3180.
        • + +
        • fix typo in xterm manpage description of -ls + option (Freedesktop.Org Bugzilla #3543).
        • + +
        • add support for interpreting the underline attribute as an + italic font in Xft mode (patch by Chuck Blake).
        • + +
        • improve initialization of toolbar so that individual + pulldown menus are initialized on demand, as they are in the + scenario where they are invoked as popup menus (GenToo Bugzilla + #90697).
        • + +
        • fix logic in find_utmp, which did not reset + result in getutid(), causing an infinite loop in + some conditions (report by Emil Mikulic).
        • + +
        • set the _NET_WM_PID property (GenToo Bugzilla + #91008).
        • + +
        • modify ifdef's in ptyx.h and xterm_io.h to build with + DragonFly (patch by Jeroen Ruigrok).
        • + +
        • 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 (patch by Joe Allen).
        • + +
        • add experimental option to allow applications to get or set + the selection data as a BASE64 string (adapted from patch by + Joe Allen).
        • + +
        • fix an off-by-one error parsing -S/nn option + (Debian #311438, report/fix by Peter Chubb).
        • + +
        • fix an initialization bug from patch + #201 that broke logging (report by Rodney Thayer).
        • + +
        • amend change to command-line processing in patch #201 to avoid conflict with + -e option (report by Servatius Brandt).
        • + +
        • suppress configure check for _XOPEN_SOURCE on + darwin.
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #202 - 2005/5/2 - + XFree86 4.5.99.3

        + +
          +
        • add extended shift- and control-modifier cursor keys to + "xterm+pcfkeys" terminfo entry to correspond to ncurses + 20050430 patch.
        • + +
        • fix a rare case where text would be written with the wrong + colors because output of scrolled text would reset the colors + and the new text would be written with the same colors + (report/testcase by Thomas Glanzmann).
        • + +
        • rename $CMD variable in plink.sh + because it is a reserved symbol in bash 3.00.16 (report by Ted + Taylor).
        • + +
        • add environment variables $XTERM_SHELL and + $XTERM_VERSION (request by Zdenek Sekera).
        • + +
        • corrected workaround for background color of menubar, which + gave a too-broad expression, coloring the background of the + VT100 widget unless overridden by another resource + setting.
        • + +
        • correct an error in the logic which decides when + sched_yield() is run; it would occasionally hang + when contending with other pseudo-terminal applications such as + screen (report by Kirill Ponomarew).
        • + +
        • modify initialization to decide whether to default to + built-in wcwidth() versus system's version based + on the starting locale and whether the system's version is poor + quality (suggested by Bram Moolenaar).
        • + +
        • update table for mk_width() from UnicodeData + 4.1.0 using Markus Kuhn's uniset script.
        • +
        + +

        Patch #201 - 2005/4/21 - + XFree86 4.5.99.2

        + +
          +
        • improve resource files to show how the menubar and popup + menus can be colored (prompted by report by Joe Wells).
        • + +
        • modify parsing of OSC (and SOS, etc), strings so their + contents are not interpreted as UTF-8. This allows non-ASCII + title strings to be set, provided that the window manager + complies (report by Thomas Wolff).
        • + +
        • improved some of the built-in line-drawing glyphs.
        • + +
        • correct color of "box" character drawn for line-drawing + glyph 1 (report by Nicolas George).
        • + +
        • improve behavior when switching to UTF-8 mode after startup + so xterm will check if the current fonts are already wide + (ISO10646-1). If they are not, xterm will use the + utf8Fonts subresource to load appropriate fonts + (request by Bram Moolenaar).
        • + +
        • modify logic for setting title-string so it applies to the + current widget rather than the vt100 widget.
        • + +
        • modify initialization for wide-bold fontname, to search for + one if none is given (report by Michael Schroeder).
        • + +
        • add resource mkWidth and command-line option + -mk_width to control whether xterm uses the + built-in version of wcwidth().
        • + +
        • add resource settings for minimum/maximum input buffer + size, and call to sched_yield to improve + performance with newer Linux kernels (adapted from patch by + Nicolas George).
        • + +
        • correct computation of width for wide characters with the + invisible attribute (report by Thomas Wolff).
        • + +
        • modify interaction between +u8 and + locale resource to allow the command-line option + to override the resource (requested by Thomas Wolff).
        • + +
        • add a limit check for scrolling margins in a one-line + screen, overlooked in fixes for patch + #198 (Debian #297430).
        • + +
        • correct treatment of iconBorderWidth for + resizing an active-icon, and its description in manpage (Debian + #296592).
        • + +
        • modify configure script --disable-imake to use + the script's definitions anyway if it cannot detect imake + (prompted by FreeBSD bug 77408).
        • + +
        • ignore error in the I/O initialization that tries to set + the tty to 7-bit input for the case where + eightBitInput resource is false (Debian + #298551).
        • + +
        • modify command-processing to accept an optional parameter + that tells xterm which shell program to use (request by Zdenek + Sekera).
        • + +
        • add simpler resource keyboardType which, when + set, overrides the individual keyboard-type resources and + eliminates the possibility of conflict between them.
        • + +
        • add initialization for scoFunctionKeys + resource (report by Rick K).
        • + +
        • correct logic of ReallocateBufOffsets() which + did not copy the content of the old screen buffer to the proper + location, making a repaint clear after switching to + wide-character mode (report by Bram Moolenaar):
        • + +
        • implement the remaining pieces to make xterm allocate cells + for wide-characters when the "UTF-8" menu entry is selected. + Also, load the UTF-8 font when that menu entry is selected, or + the escape sequence for UTF-8 mode is received (report by Bram + Moolenaar):
        • + +
        • add command-line options (-tb, + +tb) and resource toolBar to allow + menu/toolbar to disabled or enabled at startup (prompted by + reports by Joe Wells).
        • + +
        • correct typo in configure script's --enable-dec-locator + option (report by Bram Moolenaar).
        • +
        + +

        Patch #200 - 2005/2/6 - + XFree86 4.4.99.23

        + +
          +
        • increase color pairs value for xterm-256color and + xterm-88color to match ncurses, which has an experimental + option to support this.
        • + +
        • modify ifdef's to make AIX use termios rather than termio; + the struct sizes for the two were not the same.
        • + +
        • improve CF_WITH_IMAKE_CFLAGS configure macro script for + OSMAJORVERSION and OSMINORVERSION values, e.g., for Tru64 and + AIX.
        • + +
        • modify ifdef to define USE_POSIX_TERMIOS for Darwin (patch + by Min Sik Kim).
        • + +
        • modify find_utmp() to initialize the whole utmpx struct + (except ut_id), since that is needed for OSF1 4.0D to prevent + an infinite loop on exit.
        • + +
        • add configure check before adding -D_POSIX_SOURCE since + some platforms predefine it, e.g., cygwin.
        • + +
        • add simplified sed expressions in CF_IMAKE_CFLAGS configure + script macro to ensure value for PROJECTROOT is quoted on + Solaris, i.e., when nested \( and \) + are not interpreted correctly.
        • + +
        • correct DEC rectangle operations to reset state after + completing the operations.
        • + +
        • modify CASE_ST handling in charproc.c to ensure that the + parse state is reset even if xterm is not currently processing + an OSC or other string (patch by Johnny Billquist forwarded by + Matthias Scheler, NetBSD xsrc/29003).
        • + +
        • fix OS/2 build for innotek_libc (patch by David Yeo).
        • + +
        • fix a regression from patch #197 + fix for Debian #277832 which disowned the selection if it was + scrolled, e.g., by the user pressing return at the bottom of + the screen (Debian #291787).
        • + +
        • move the warning/exit for missing $DISPLAY into the error + handler in case -display is given, and the connect + fails for some other reason.
        • +
        + +

        Patch #199 - 2005/1/17 - + XFree86 4.4.99.22

        + +
          +
        • instead of setting $DISPLAY, check for the + unset variable and warn/exit on this condition (comments by H + Merijn Brand and Bernhard R Link).
        • + +
        • fix a typo in Imakefile from patch + #198 (reports/patches by Stefan Dirsch, Mike Castle).
        • +
        + +

        Patch #198 - 2005/1/13 - + XFree86 4.4.99.21

        + +
          +
        • set $DISPLAY to ":0" if it is not set.
        • + +
        • add utmpDisplayId resource to allow users to + control whether the display identifier (display number and + screen number) are retained in the connection information + recorded in utmp (discussion with Edoardo Tirtarahardja).
        • + +
        • add bellOnReset resource to allow users to + disable bell which sounds on hard reset since patch #183 changes to DECSCL (discussion with + Danek Duvall).
        • + +
        • improve $WINDOWID for configuration with + toolbar by making it refer to the top-level shell rather than + the parent of the current window. For that case, the parent is + a form widget, which does not have a name, which made the + $WINDOWID not very useful as a parameter for + xwininfo (suggested by Dave Bodenstab).
        • + +
        • fix a typo in WhichVFont() macro from patch #197 changes which broke the + --disable-active-icon configuration (report by Ralf S. + Engelschall).
        • + +
        • improve some limit checks (Gentoo Bugzilla #75604).
        • + +
        • add --disable-setuid option to configure script (Gentoo + Bugzilla #76543).
        • + +
        • add --disable-full-tgetent option to configure script, + allowing one to ignore a termcap library in favor of + ncurses/curses (Gentoo Bugzilla #69926).
        • + +
        • modify configure script to choose useful warning options + for Intel version 8.0 compiler.
        • + +
        • update config.guess, config.sub
        • + +
        • make active-icon work properly when TrueType fonts are used + (Debian #286068).
        • + +
        • correct change from patch #157 + which uses getlogin() to check for an alias; the storage used + for the related getpwuid() call was overwritten by the data + used for comparison (patch by Per Hedeland).
        • + +
        • correct case of SCS for character set 0 (line-drawing) to + allow it to be selected into GR.
        • + +
        • fix a file-descriptor leak (Redhat Bugzilla #139597).
        • + +
        • modify creat_as() to only fork if xterm is + actually running as setuid and/or setgid. This works around a + Cygwin bug which hangs when logging is enabled and makes xterm + a little faster for systems using interfaces such as utempter + (report by Al Goodman).
        • + +
        • modify Cleanup() to avoid operations such as X + calls that might use unsafe functions when it is called by a + signal handler (report by Michiel Boland).
        • + +
        • fix bugs in patch #191 and in SRM + changes from patch #197 that broke + DECSET 38: switch to Tek4014 emulation (report by Dave + Bodenstab).
        • + +
        • fix for manpage escapes (Marc La France).
        • + +
        • improve on IRIX-specific change for Imakefile in XFree86 + CVS versus resize linking against termcap library to reflect + definitions for USE_TERMCAP in resize.c
        • +
        + +

        Patch #197 - 2004/11/30 - + XFree86 4.4.99.19

        + +
          +
        • modify configure script to remove empty "-DPROJECTROOT=" + definition which resulted unusable values for luit's default + path.
        • + +
        • update precompose.c based on Unicode 4.0.1
        • + +
        • several minor fixes based on Intel compiler warnings.
        • + +
        • change default translations so a BtnDown which + is not recognized is simply ignored rather than emitting a + bell. That makes it less obtrusive when the user tries to use a + mouse which provides more capabilities than the X mouse driver + supports, e.g., one with a horizontal scroll wheel (Debian + #265133).
        • + +
        • note in xterm's manpage that translations is + not specific to xterm (Debian #278897).
        • + +
        • modify uxterm script to use locale program to verify if the + derived locale is installed (Debian #246398).
        • + +
        • correct font handling for active icon when in UTF-8 mode + (report by Paolo Liberatore).
        • + +
        • make active-icon and toolbar configurations work + together.
        • + +
        • modify the criteria for disowning primary selection. + Previously, this happened anytime the cursor was moved before + the end of the selection. That would ensure that any + insert/delete of char or line, as well as scrolling, would + disown the selection. The new criteria change this to checking + if the operations would modify the data which is highlighted + (Debian #277832).
        • + +
        • reimplement DECALN with functions for vt420 + rectangles, fixes selection for this case.
        • + +
        • implement vt420 rectangle operations.
        • + +
        • add parsing, for debug/test of vt220 soft-fonts.
        • + +
        • add menu entry, actions and escape sequence to allow + enabling/disabling toolbars at runtime.
        • + +
        • improve rendering for Xft, allow it to draw non-linedrawing + characters such as "pi", which were drawn from internal tables + with patch #180 (Freedesktop.org + Bugzilla #1260).
        • + +
        • add configure option --enable-mini-luit, + ifdef'd the mini-luit feature with + OPT_MINI_LUIT.
        • + +
        • add mini-luit feature, which supports Latin9 directly + rather than via luit, provided that Unicode fonts are used + (Freedesktop.org Bugzilla #1571, request by Stefan Dirsch, + patch by Michael Schroeder).
        • + +
        • for Linux, if IUTF8 is defined, e.g., on recent 2.6.x + kernels, set the corresponding flag for the slave pty, to + enable UTF-8 interpretation of backspace in cooked mode + (Freedesktop.org Bugzilla #1578, request by Stefan + Dirsch).
        • + +
        • modify faceSize resource to use a + floating-point internal value (adapted from patch by Sam + Stephenson).
        • + +
        • correct handling selection of tabs over cleared space in + UTF-8 mode. In this special case, xterm represents the + whitespace with a null rather than a space character (Debian + #276447).
        • + +
        • amend fix for infinite loop from patch + #192 to check if there is wrapped text to output in a + following iteration (Debian #273202).
        • + +
        • fixes ifdef'd with __INTERIX to allow building + with Interix (Windows Services for UNIX) 3.5 using the xlibs + libraries from freedesktop.org (patch by Min Sik Kim).
        • + +
        • amend solution for Debian #252873, Debian #260471 from + patch #194 by making the cursor not + explicitly colored if only the foreground color is set, and the + cursor is on a blank space (Debian #275473).
        • + +
        • correct logic for send/receive mode (SRM) with regard to + control characters.
        • + +
        • fix masking of invisible text in wide-character mode, which + did not work for line-drawing characters.
        • + +
        • incorporate CF_XOPEN_SOURCE into configure script, + replacing CF_GNU_SOURCE.
        • +
        + +

        Patch #196 - 2004/8/15 - + XFree86 4.4.99.12

        + +
          +
        • add a special case to configure script to ignore NetBSD's + grantpt() which was recently added (but not part + of a release), until someone is able to ensure that xterm can + use it (report by Min Sik Kim).
        • + +
        • clear the buffer returned by getutid(). This fixes an + infinite loop on some platforms introduced in patch #193 by Debian #256468 fix (report by + David Ellement).
        • +
        + +

        Patch #195 - 2004/8/8 - + XFree86 4.4.99.11

        + +
          +
        • correct length used for blinking text, make the last column + blink (patch by Alexander V Lukyanov).
        • + +
        • start changes to make doublesize characters work with + TrueType fonts (see patch #44).
        • + +
        • trim leading/trailing blanks from color resources as done + for other strings in patch #167.
        • + +
        • fixes for showBlinkAsBold resource (report by + Christoph Berg).
        • +
        + +

        Patch #194 - 2004/7/27 - + XFree86 4.4.99.11

        + +
          +
        • change clearing operations so foreground color attribute is + not set. Usually this is benign, but in some cases when the + cursor color is not set explicitly, the cursor would show this + color (Debian #252873, Debian #260471).
        • + +
        • add extra state (cursor-moved) to guard against deciding + that the cursor did not require repainting after an indexing + operation that leaves the cursor in the same location on the + screen.
        • + +
        • fix a case where a full-screen indexing operation would not + restore the cursor-busy state.
        • + +
        • fix a repainting bug introduced in patch #180: when using a font lacking + line-drawing characters, a repaint of the screen could skip + horizontally an extra amount after filling in the missing + character (reports by Nicolas George, Hans de Goede, Redhat + Bugzilla #128341).
        • + +
        • rename terminfo fragment "xterm-pc-fkeys" to + "xterm+pcfkeys" for consistency with ncurses.
        • +
        + +

        Patch #193 - 2004/7/19 - + XFree86 4.4.99.10

        + +
          +
        • fix for wide-character selection from OpenBSD CVS + (report/patch by Matthieu Herrb).
        • + +
        • modify initialization and cleanup of utmp data to also + compare the ut_line member (Debian #256468).
        • + +
        • modify check on focus-change to ignore + FocusOut events generated by + XGrabKeyboard. This fixes a case where the text + cursor would act as if focus were lost when selecting the + "Secure Keyboard" menu option.
        • + +
        • add gen-pc-fkeys.pl script, use that to + generate terminfo fragment corresponding to the pc-style + function keys.
        • + +
        • fix a case where the checkmark by the "VT220 Keyboard" menu + entry was not set on startup.
        • + +
        • separated two methods for making the cursor blink (menu and + escape sequence) by using the menu as the primary method and + XOR'ing the state of the escape sequence against that.
        • + +
        • modify logic for enabling blinking cursor via escape + sequence as well as the related save/restore operations so this + is only available if the cursorBlink resource was + set on startup.
        • +
        + +

        Patch #192 - 2004/7/12 - + XFree86 4.4.99.9

        + +
          +
        • change resource settings for color4 and color12, add some + discussion in XTerm-col.ad (Debian #241717).
        • + +
        • add a note in xterm manpage discussing the difference + between alt- and meta-keys, and the way the latter is used in + the eightBitInput resource.
        • + +
        • add a note in xterm manpage regarding possible conflict + between resource settings for xterm.vt100.font and + xterm.vt100.utf8Fonts.font (Debian #254650).
        • + +
        • add compile-time customization of + backarrowKeyIsErase and + ptyInitialErase default resource values (adapted + from OpenBSD CVS).
        • + +
        • change parameter of FIONREAD + ioctl() call from long to int (discussion on + tech-x11@netbsd.org regarding LP64 by John Heasley and Matthias + Scheler).
        • + +
        • modify configure script options for Athena widgets to work + as expected for "--without-Xaw3d", etc., (GenToo Bugzilla + #53455).
        • + +
        • add case to uxterm to accommodate locales ending with + "@euro", e.g., fr_FR.UTF-8@euro (Debian #255197, + report/analysis by Matthieu Lagouge).
        • + +
        • add special case for VT100 graphic's "box" character + (discussion with Ben Armstrong).
        • + +
        • add missing initialization for bitmap-font sizes needed to + make fonts menu work with TrueType fonts (report by Ben + Armstrong).
        • + +
        • save the fontnames for bold fonts that are derived from + normal fonts, or from the boldFont resource, so + the same value is restored when switching with the VT Fonts + menu (Debian #256086).
        • + +
        • fix manpage preprocessing (Marc La France).
        • + +
        • fix typo in manpage's description of character classes + (Debian #257073).
        • + +
        • modify terminfo to accommodate luit, which relies on G1 + being used via an ISO-2022 escape sequence (Debian #254316, + analysis by Juliusz Chroboczek).
        • + +
        • modify Makefile.in rule for ctlseqs.txt to work around + groff SGR misfeature.
        • + +
        • modify XTerm.ad to set saveLines + default to 1024 (Redhat Bugzilla #127132).
        • + +
        • add a limit-check in dotext() to prevent + infinite loop in a corner case of UTF-8 configuration.
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #191 - 2004/6/6 - + XFree86 4.4.99.7

        + +
          +
        • correct options parsing for -into option so it + can be combined with -e (Redhat Bugzilla #124518, + report/patch by James Armstrong).
        • + +
        • fix ifdef's for OPT_COLOR_RES2 so that the + fake resource table introduced in patch + #188 is not compiled if it is empty. This happened to work + with gcc (report by Joel Konkle-Parker).
        • + +
        • reorganize ptydata.c to use one input buffer shared between + the VTxxx and tek4014 emulators. In the new scheme, UTF-8 + decoding is performed on characters as they are needed by the + state machine rather than on buffers as they are read.
        • + +
        • work around change in quoting of PROJECTROOT symbol when + using configure script, from changes made in patch #187 for CF_IMAKE_CFLAGS (GenToo + Bugzilla #50982).
        • +
        + +

        Patch #190 - 2004/5/25 - + XFree86 4.4.99.6

        + +
          +
        • correct state for values in the range 128-159 after + translating from UTF-8: this should be ignored unless the user + overrides it with the allowC1Printable resource + (reported by Simon Strandgaard).
        • + +
        • add configure-script check for nl_langinfo(CODESET), use + this to replace check of environment variables for UTF-8.
        • + +
        • change Makefile.in rules for 256colres.h and 88colres.h so + they are only made if they do not exist. The maintainer-clean + rule will remove these files; they require perl to be + made.
        • + +
        • remove check in configure script --enable-toolbar that + suppressed this option when building with Xaw7.
        • + +
        • apply fixes to Tektronix widget used for VT100 widget to + make toolbar work with Xaw7 (XFree86 4.x).
        • +
        + +

        Patch #189 - 2004/5/16 - + XFree86 4.4.99.6

        + +
          +
        • do not call xim_real_init() if openIm resource + is false (Debian #249025).
        • + +
        • minor improvements to built-in line-drawing.
        • + +
        • fix a few portability issues with dynamic abbreviation + support, i.e., did not compile on Tru64.
        • + +
        • modify constraints in form used to layout toolbar, to work + with newer Xaw in XFree86 4.x.
        • +
        + +

        Patch #188 - 2004/5/12 - + XFree86 4.4.99.6

        + +
          +
        • correct table entry for DEL in the ground state, which + marked it as a printable character from patch #171 (report by D Hugh Redelmeier).
        • + +
        • improve fix in patch #186 for + failure in xim_real_init() by adding a sleep.
        • + +
        • fix a typo in os2main.c (XFree86 Bugzilla #1358, + report/patch by Frank Giessler).
        • + +
        • make escape sequence reporting dynamic colors consistent + with the logic that sets it; choosing the opposite color when + reverse video is set (XFree86 Bugzilla #1361, reported by Bradd + W Szonye).
        • + +
        • modify initialization of 256- and 88-colors so that colors + beyond 16 are normally not X resources. This works around a + hard-coded limit in Xt which breaks xterm when 256-colors and + luit are both configured (report by Noah Friedman).
        • + +
        • remove ncv from xterm-256color + terminfo entry since it is no longer needed (report by Eli + Zaretskii).
        • + +
        • add "erase2" and "eol2" keywords to ttyModes + resource, for recent/current FreeBSD.
        • + +
        • improve ifdef's for utempter library to omit direct calls + to setutent() or getutent() (adapted + from patch by Christian Biere).
        • + +
        • add dynamic abbreviation support like Emacs (patch by + Tomasz Cholewo). This is ifdef'd with OPT_DABBREV, + and enabled via the configure script + --enable-dabbrev option.
        • + +
        • fix problem responding to session management events, e.g., + which would make logging out very slow (patch by Eddy De Greef, + Debian #233883).
        • + +
        • work around a newer bug in toolbar with XFree86 by forcing + menus to be fully initialized at startup. In older versions of + XFree86 and X11R6, it was possible to delay initialization of + the menu contents until it was popped up. (The longstanding bug + with XFree86 4.x layout for toolbar still exists, though).
        • + +
        • modify xtermAddInput to work around core dump + on IRIX64 when initializing scrollbar translations if toolbar + is compiled-in.
        • + +
        • fix some minor conflicts in the 2-character entry names in + the termcap file.
        • +
        + +

        Patch #187 - 2004/4/27 - + XFree86 4.4.99.4

        + +
          +
        • change xterm version string to use + __vendorversion__ where that is available, and + "XTerm" otherwise.
        • + +
        • improve description of utf8 resource in + manpage (Debian #179407).
        • + +
        • modify configure macros CF_IMAKE_CFLAGS and CF_ADD_CFLAGS + to handle -D options that define string values, + e.g., for XVENDORNAME.
        • + +
        • modify configure macro CF_IMAKE_CFLAGS to allow (if + $PATH is set accordingly) to use the + xmkmf script within an X build tree.
        • + +
        • add missing #undef OPT_SESSION_MGT to + xtermcfg.hin to make the configure script's + --disable-session-mgt option work.
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #186 - 2004/4/18 - + XFree86 4.4.99.4

        + +
          +
        • change reset on DECSCL to a soft-reset + (appears some DEC manuals have errors).
        • + +
        • add a section to ctlseqs.ms elaborating on normal/alternate + screens.
        • + +
        • modify initialization of Acolors[] so that any + XtDefaultForeground or XtDefaultBackground values are + translated as in the Tcolors[], to use the window's + foreground/background colors. This affects the + colorBD and similar resources which normally have + no explicit color assigned.
        • + +
        • modify initialization of Tektronix window so that control + sequences setting its color before the window is popped up will + apply to its initial colors.
        • + +
        • add control sequence to set Tektronix window's + text-cursor.
        • + +
        • modify initialization of terminal colors, e.g., mouse + pointer and text cursor, to treat + XtDefaultForeground and + XtDefaultBackground values as the actual + foreground and background colors of the terminal rather than + white and black (Debian #241717).
        • + +
        • remove an incorrect comparison against + PTYCHARLEN in parsing the -S option + (report by Michael B Taylor).
        • + +
        • minor restructuring of terminfo/termcap files, having noted + some packager's customizations which caused the structure to be + confused.
        • + +
        • eliminate an isolated use of MIN/MAX in charproc.c
        • + +
        • replace XtExtdefaultfont and + XtExtdefaultbackground by their more familiar + equivalents XtDefaultFont and + XtDefaultBackground.
        • + +
        • replace ifdef's using SCO, sco + and SCO325 with __SCO__ (XFree86 + Bugzilla #1301, Kean Johnston). But ensure that it still builds + on platforms where this symbol is not defined.
        • + +
        • add scoFunctionKeys resource, to match + manpage.
        • + +
        • update manpage discussion of menus and related + resources.
        • + +
        • enable utmpx support for NetBSD 1.6C and newer (patch by + Matthias Scheler).
        • + +
        • add a note in the manpage discussing xterm's treatment of + open file-descriptors (request by Dan Shearer).
        • + +
        • modify Help() to make "xterm -h" write to + standard output rather than standard error (patch by Bram + Moolenaar).
        • + +
        • check for type of failure in xim_real_init() to avoid + looping when the problem is an unsupported input method rather + than a failure to connect to the XIM server. Problem was + introduced in patch #175 (XFree86 + Bugzilla #1306).
        • + +
        • modify Imakefile to remove dependency of + "install" target on the xterm executable to make + installs from tree without attempting to rebuild anything + (commit by David Dawes, report/patch from Lee Olsen).
        • + +
        • remove call to ShowCursor from + SetCursorBlink() since that is redundant, and can + cause display glitches if the cursor is already blinking + (XFree86 Bugzilla #1158, patch/report by Andreas Schwab).
        • +
        + +

        Patch #185 - 2004/3/3 - + XFree86 4.4

        + +
          +
        • fix tcap-query logic for the backspace key (XFree86 + Bugzilla #1233, report/patch by Anton Kovalenko).
        • + +
        • add test-scripts resize.pl and tcapquery.pl
        • + +
        • add translation to ASCII of commonly-used characters that + groff translates to Unicode, when the font in use does not + provide the corresponding glyphs (Debian #219551).
        • + +
        • modify RequestMaximize(), which performs maximize/restore + via control sequences, to account for window-frame (patch by + Jess Thrysoee).
        • + +
        • improve pattern used in uxterm to check for + UTF-8 locale, e.g., for HPUX (patch by H Merijn Brand).
        • + +
        • add -fd option and resource + faceNameDoublesize to specify double-wide fonts + with Xft (adapted from patch by Zarick Lau).
        • + +
        • change a couple of resource classes from "Boolean" to + specific values: freeBoldBox, + forceBoxChars.
        • + +
        • add resource showMissingGlyphs to outline + places on the screen where a font lacks the corresponding + glyph.
        • + +
        • add resource showBlinkAsBold to control + whether blinking text should be shown as bold or actual + blinking text.
        • + +
        • improve logic in ShowCursor() to avoid repainting the + cursor when it is already visible, e.g., in response to the + DECTCEM escape sequence. This also addresses XFree86 Bugzilla + #1158.
        • + +
        • implement blinking text, using the timer for blinking + cursor.
        • + +
        • modify FreeType support to allow resizing the font, in the + same ways the window can be resized if fixed fonts are used. + The relative font sizes are derived from the fixed font + sizes.
        • + +
        • add menu items and corresponding actions for switching + on/off the UTF-8 mode and Xft (TrueType) support.
        • + +
        • add logic to handle switching UTF-8 mode on/off. It worked + if the escape sequences were flushed, but if data was mixed in + with the same write, some were not handled properly (report by + Nicolas George).
        • + +
        • modify to allow turning UTF-8 mode on/off via escape + sequence even if -wc option was not given at + startup (patch by Peter Berg Larsen).
        • + +
        • amend fix for XFree86 Bugzilla #981, adjusting for + savedlines value (report by Tim Adye).
        • + +
        • fix a typo in computing relative font size (Jess + Thrysoee).
        • +
        + +

        Patch #184 - 2003/12/31 - + XFree86 4.3.99.903

        + +
          +
        • improve configure-script checks for FreeType and related + libraries, using xft-config or + freetype-config scripts when available.
        • + +
        • fix configure-script check for SYSV definition + by ensuring whether sys_errlist[] is declared, and + by modifying the test program to include + X11/Intrinsic.h to check that wchar_t + is declared consistently (report by H Merijn Brand).
        • +
        + +

        Patch #183 - 2003/12/26 - + XFree86 4.3.99.903

        + +
          +
        • correct logic for configurations that may attempt to open + both old/new-style pseudoterminals. In this case, the old-style + are preferred. Logic was broken in patch + #145 (XFree86 Bugzilla #997, report/patch by Kean + Johnston).
        • + +
        • modify handling of eightBitInput resource in + UTF-8 mode to translate the value into UTF-8. Otherwise an + illegal UTF-8 code is sent to the application (report by Bram + Moolenaar).
        • + +
        • modify uxterm script to interpret help and + version options so xterm does not always create a window when + the user requests this information (Debian #223926).
        • + +
        • add a limit check to ScrnTstWrapped() (XFree86 Bugzilla + #981).
        • + +
        • modify DECSCL to perform a hard reset (RIS) as per DEC + manuals. Extended DECSCL to accept parameters for vt4XX and + vt5xx terminals.
        • + +
        • correct logic for ANSI conformance level escape sequences, + which were confused with DEC conformance level escape + sequences.
        • + +
        • correct state for vt52 shift-in/shift-out, which was not + reset properly after patch #171.
        • + +
        • correct handling of graphics characters for vt52 mode, + which did not display line-drawing characters after G1 fix from + patch #182.
        • + +
        • fixes for configure script to work with current Cygwin + headers and libraries.
        • + +
        • modify Imakefile to put the current directory + at the beginning of the include searchpath (patch by David + Dawes).
        • +
        + +

        Patch #182 - 2003/12/2 - + XFree86 4.3.99.901

        + +
          +
        • correct logic for metaSendsEscape resource to + allow for the meta-right key to be tested. Improve check for + meta/alt modifiers by dropping the assumption that a keysym is + associated with only one modifier, and by ignoring NoSymbol + entries in the xmodmap data (XFree86 Bugzilla #924, patch by + David Dawes).
        • + +
        • correct wrapping logic for line-drawing characters written + in non-UTF-8 mode of xterm build for wide-characters (XFree86 + Bugzilla #918, report/patch by Jürgen Keil).
        • + +
        • improve manpage description of resources, in particular the + utf8Fonts class (XFree86 Bugzilla #905).
        • + +
        • add definitions to compile with glibc-based GNU/Hurd, + GNU/KFreeBSD and GNU/KNetBSD (XFree86 Bugzilla #893).
        • + +
        • compiler-warning fixes (patch by Christian Biere).
        • + +
        • add README.i18n (Tomohiro Kubota).
        • + +
        • correct initialization of G1 character set mapping, which + used line-drawing set as a result of confusion between "DEC + Supplemental Graphic" and "DEC Special Graphic" character sets + (see patch #34 regarding DECSTR).
        • + +
        • correct ifdef in main.c for variable utret (patch by + Bernhard Rosenkraenzer).
        • + +
        • document in xterm's manpage how to use XFree86 ":unscaled" + keyword to suppress scaling of bold fonts.
        • + +
        • when deriving bold fontname from normal fontname, use the + normal font's average width to avoid for example selecting + 7x13bold from an 8x13 normal font (Debian #107769).
        • +
        + +

        Patch #181 - 2003/10/26 - + XFree86 4.3.99.15

        + +
          +
        • implement boldMode for wide-character logic in + drawXtermText() (report by Michael + Schroeder).
        • + +
        • modify UXTerm.ad resource file to include + "XTerm-color" rather than "XTerm", in case the latter file + contains no color resource definitions, e.g., after patch #180.
        • + +
        • add action load-vt-fonts() and configure + option --enable-load-vt-fonts which allows users + to define additional sets of VT-fonts which can be loaded at + runtime.
        • + +
        • add logic to wide-character support which attempts to load + fonts specified by utf8Fonts subresources at + startup. The subresources have the same names as the fonts + which they replace, e.g., font, + font1, etc., so that the ISO-10646-1 fonts can be + specified in the XTerm app-defaults file (adapted + from patch by Tomohiro Kubota).
        • + +
        • improve Set Font escape string handling by making the + relative settings apply to the size of the font, as in shift + keypad plus/minus rather than the menu index.
        • + +
        • simplify parameter passing for the set-vt-font + action and related code.
        • + +
        • cleanup some include-ordering, moving some recently-added + hardcoded stuff into xterm.h where it will not interfere with + the configure script.
        • + +
        • modify xtermAddInput() (see note on + augmentation in patch #158) to use the + complete set of default keyboard translations so that one can + use shifted pageup, wheel mouse, etc., while the mouse pointer + is over the scrollbar. (Debian #178812).
        • + +
        • make save/restore mode controls apply to show/blink cursor + states.
        • + +
        • add escape sequence to start/stop blinking cursor, which + allows implementing cvvis terminfo capability + (request by Nate Bargmann).
        • + +
        • add indp and rin to terminfo + entry.
        • + +
        • fix an out-of-bounds array reference in ScrnRefresh() for + wide characters (report by Dan Harnett, patch by Todd Miller). + This bug dates from patch #141.
        • +
        + +

        Patch #180 - 2003/10/12 - + XFree86 4.3.99.15

        + +
          +
        • several fixes for rendering using Xft via option + -fa: + +
            +
          • translate Unicode values, i.e,. from UTF-8 output to + xterm, for line-drawing to xterm's internal code, etc., + since TrueType fonts generally do not have either set of + line-drawing glyphs. xterm can draw these directly (report + by Abigail Brady).
          • + +
          • pass 16-bit values rather than 8-bit values to + xtermXftDrawString() to allow for wide-characters.
          • + +
          • remove spurious check for colorBDMode + resource in logic that does bold fonts.
          • + +
          • implement underlining.
          • +
          +
        • + +
        • patches by Ilya Zakharevich: + +
            +
          • improve drawXtermText() by making the recursive calls + communicate through arguments, and not through + saving/restoring global variables.
          • + +
          • make double-width characters work with -u8 + option.
          • + +
          • modify lookup of double-sized fonts by checking for a + match ignoring x/y resolution if the first check + fails.
          • +
          +
        • + +
        • make height of TrueType fonts match ascent+descent (patch + by Keith Packard).
        • + +
        • correct configure-script check for imake $CFLAGS, which did + not check properly if imake was not available.
        • + +
        • correct install rule in Makefile.in for + uxterm, which was attempting to strip the script + (newsgroup posting by Fernan Aguero).
        • + +
        • correct AF/AB strings in termcap for xterm-256color and + xterm-88color entries (report by Josh Howard).
        • + +
        • update wcwidth.c to incorporate changes from Markus Kuhn's + 2003-05-20 (Unicode 4.0) version of that file.
        • + +
        • modify scroll-back and + scroll-forw actions to accept an adjustment value, + e.g., +
          +              scroll-back(1, page-2)
          +
          to scroll back by 2 lines less than a page (patch by Greg +Klanderman). +
        • + +
        • use color resource setting from Debian package for xterm + VT100 widget, since the choice of blues provides better + contrast.
        • + +
        • remove color resources from XTerm.ad, leaving + them only in XTerm-col.ad (prompted by Debian + package for xterm).
        • + +
        • correct configure script option --enable-pty-handshake + (report by Paul Gilmartin).
        • + +
        • add visualBellDelay resource to modify the + length of time used for visual bell, for very slow displays or + very fast computers (reports by Ingo van Lil and Doug + Toppin).
        • + +
        • correct logic for initializing dynamic highlight color + (patch by Jess Thrysoee).
        • + +
        • add a check for non-zero size in call to + XCopyArea() to accommodate a Solaris bug.
        • + +
        • correct typo in example for character classes in xterm + manpage (Debian #198910).
        • + +
        • link xterm with bind_on_load option on Darwin to work + around a deadlock in the dynamic loader when a signal is + received while the dynamic loader is looking up symbols + (patches by Rob Braun, Torrey Lyons).
        • + +
        • modify configure script to avoid using "head -1".
        • + +
        • update config.guess, config.sub
        • + +
        • modify ifdef's to work around inclusion of types FcChar32 + and XftCharSpec with FreeType 2.0 (see patch #175).
        • + +
        • modify the predictable version of the generated logfile + name (see patch #171) to append the + process-id rather than a random value.
        • + +
        • resync with XFree86 CVS + +
            +
          • Enable SCO function keys in xterm
          • + +
          • Make Delete key send DEL by default on SCO in + xterm
          • +
          +
        • +
        + +

        Patch #179 - 2003/5/21 - + XFree86 4.3.99.5

        + +
          +
        • modify ifdef's for WTMPX_FILE to allow building on cygwin + again.
        • + +
        • change the default of pty-handshaking configure option (and + related default for imake) to assume this feature is + needed.
        • + +
        • add ifdef's so configure option for XawPlus library works + (patch by Pavel Roskin).
        • + +
        • add $(MAIN_DEFINES) to the variables checked + by the configure script that may contain information set by + imake. This allows xterm to build/run properly using the + configure script on IRIX64.
        • + +
        • add configure check for ".exe" suffix on cygwin.
        • +
        + +

        Patch #178 - 2003/5/18 - + XFree86 4.3.99.5

        + +
          +
        • modify default for configure + --enable-pty-handshake option to enable it for + Solaris (report by Nelson Beebe).
        • + +
        • modify in_put() function to call + PreeditPosition() only when the cursor's position + has changed. This addresses report by Stefan Baums of high CPU + usage while xterm with chinput are running in the background + (patch by Yong Li).
        • + +
        • improved explanation of -ls conflict with + -e option in xterm manpage (adapted from comments + by Henning Makholm).
        • + +
        • correct comment in terminfo file regarding modifier used + for kDC (Debian #189764, report by Henning + Makholm).
        • + +
        • correct/extend some of the keypad description in ctlseqs.ms + (report by Henning Makholm).
        • + +
        • correct keypad-mapping table in input.c so + XK_KP_Equal works (report by Henning + Makholm).
        • + +
        • modified to work with CJK double-width (bi-width/monospace) + fonts. They're similar to Roman Czbora and David Starner's + gnuunifonts in that Latin letters and numbers have all the same + width which is exactly the half of the width of East Asian + characters. (patch by Jungshik Shin + <jshin@mailaps.org>).
        • + +
        • add configure option --enable-broken-osc and + resource brokenLinuxOSC to accommodate scripts + which do not distinguish between running in the Linux console + and running in X. Linux console recognizes malformed control + strings which start with an OSC, but are + fixed-length, with no terminator.
        • + +
        • add configure option --enable-broken-st and + resource brokenStringTerm to allow user to revert + one part of the parsing table corrections from patch #171. (reports by Matthias Scheler and + Kirill Ponomarew indicate that someone's network firmware sends + an <escape>X).
        • + +
        • modify configure --disable-imake to provide + values for OSMAJORVERSION, + OSMINORVERSION, FUNCPROTO and + NARROWPROTO (report by Heiko Schlichting).
        • + +
        • correct vttests/16colors.sh, which omitted the + $SUF variable in output strings (patch by Paul + Gilmartin).
        • + +
        • modify shell scripts in vttests directory to + attempt to use named signals in the trap + statement, making this portable to OS/390 (report by Paul + Gilmartin). Tested on SunOS 4.1.4, which implements only + numbers.
        • +
        + +

        Patch #177 - 2003/3/23 - + XFree86 4.3.0

        + +
          +
        • fix definition of USE_HANDSHAKE, must be + numeric (reported by Jens Schleusener).
        • +
        + +

        Patch #176 - 2003/3/22 - + XFree86 4.3.0

        + +
          +
        • add configure option --enable-pty-handshake to + allow one to compile-in support for the pty handshaking logic, + and resource ptyHandshake to enable or disable it + (suggested by Ian Collier).
        • + +
        • restore USE_HANDSHAKE ifdef removed in + patch #159 to address Debian + #39964.
        • + +
        • move ifdef's for ttysize/winsize into xterm_io.h
        • + +
        • simplify loop on tgetent, check if the + successive entries in the lookup table are the same. That makes + xterm do one less lookup if there is no "xterm" entry in the + termcap file (report by Derek Martin).
        • + +
        • correct manpage discussion of $TERM and + $TERMCAP variables, which omitted the Tektronix + emulation and a note of the final "dumb" fallback.
        • + +
        • broaden ifdef for + XRegisterIMInstantiateCallback() from patch #175 (XIM fix) to exclude non-XFree86 + (report by Nelson Beebe indicates this breaks for Solaris, IRIX + and OSF/1).
        • + +
        • correct resource-size for iconFont (this was + added by X11R6.3).
        • + +
        • improve configure check for XKB bell extension, to work + around inconsistent implementation of this feature (reports by + Nelson Beebe, Kriston Rehberg and David Ellement).
        • + +
        • modify configure-check for tty group to be + less strict in batch mode (report by Nelson Beebe).
        • + +
        • modify to allow building with g++, to use its compiler + warnings (suggested by Nelson Beebe).
        • + +
        • modify dec2ucs[] table to reflect newer codes + available for scanlines 1, 3, 7, 9 (report by Michael + Schroeder).
        • + +
        • add configure option for XawPlus library.
        • +
        + +

        Patch #175 - 2003/3/9 - + XFree86 4.3.0

        + +
          +
        • fix a SIGSEGV which could occur if xterm is connecting to + XIM server, and the XIM server is destroyed (patch by Nam + SungHyun).
        • + +
        • modify to use built-in line-drawing characters for Xft + fonts (patch by Andrew Tipton).
        • + +
        • make menu reflect the state of the tekInhibit + resource.
        • + +
        • make signalInhibit resource work, i.e., + disable the menu entries that would send signals to, or exit + xterm. This was probably broken in X11R5 when logging was + disabled (report by Sven Mascheck).
        • + +
        • changed classes of colorBDMode and similar + resources that override colors when a video attribute is set to + ColorAttrMode, to make them distinct from + ColorMode. This avoids an unexpected rendering of + reverse video, for example (report by Paul Fox).
        • + +
        • changed class of veryBoldColors to + VeryBoldColors, since ColorMode is + associated with boolean resources.
        • + +
        • add option -k8 and resource + allowC1Printable to allow users of non-VTxxx + character sets such as KOI-8 to treat the C1 control area + (character codes 128-159) as printable rather than control + characters.
        • + +
        • add a null-pointer check for return-value of + ptsname() in HPUX-specific code (report by David + Ellement).
        • + +
        • revise the ifdef's used for XKB bell support. + The code was using a nonstandard call + XkbStdBell(). Changed to use + XkbBell() (based on patch by + <derek@signalmarketing.com>).
        • + +
        • add a null-pointer check in xtermLoadFont() in + case there is no wide-bold font (Nam SungHyun).
        • + +
        • change Makefile.in to use autoconf's + bindir, libdir and + mandir variables (report by Nam SungHyun).
        • + +
        • add le to termcap xterm-basic + entry. Though missing from older termcaps for xterm, some + applications check for it (report by Matthias Buelow).
        • + +
        • modify uxterm script to strip modifiers such + as "@euro" from the locale setting before adding ".UTF-8" + (Debian #179929).
        • + +
        • modify the remaining places where tek4014 emulation uses + XDefineCursor(), to make it work as originally + implemented, e.g., when switching back to alpha mode. Added + test-screen in vttest to test this feature properly.
        • +
        + +

        Patch #174 - 2003/2/25 - + XFree86 4.2.99.903

        + +
          +
        • work-around for XFree86 bug which made + XDefineCursor() on a shell-window no longer work. + The tek4014 emulation used this. Use the next lower window + (report by Karl Rudolf Bauchspiess).
        • + +
        • add a resource setting allowWindowOps to + control whether the extended window operations should be + allowed, e.g., resize, iconify, report window attributes. This + is to accommodate people who are not capable of using a pager + to view log-files.
        • +
        + +

        Patch #173 - 2003/2/6 - + XFree86 4.2.99.902

        + +
          +
        • reset mouse mode to normal on a full reset. This does not + apply to mouse hilite tracking mode, of course (see + ctlseqs.ms).
        • + +
        • add a time-delay at the point where mouse hilite tracking + mode choses to not handle X events, to avoid runaway CPU usage + (report by D Hugh Redelmeier).
        • + +
        • check for illegal character in DECUDK string, quit if + detected.
        • +
        + +

        Patch #172 - 2002/12/27 - + XFree86 4.2.99.3

        + +
          +
        • fixes to make repainting of 256-color example work properly + (reports by Abigail Brady and Scott A Crosby). + +
            +
          • set flag in AllocateAnsiColor() to ensure + the color is allocated once only.
          • + +
          • fix check in ScrnRefresh, which was + comparing background colors only if the ANSI foreground + colors also were set.
          • +
          +
        • + +
        • merge Error() calls and some + exit() calls into SysError(), and + change that to add the brief explanation for each error code + which is provided in the manpage. Change a few + SysError(), calls to avoid using code 1, to avoid + confusion with exit status from places that do not use + SysError().
        • + +
        • simplify logic used to open a debug logfile as the standard + error.
        • + +
        • modify the -e option so that if it fails, + xterm will check if only one argument follows, e.g., it was + quoted, and then retry using sh -c.
        • + +
        • modify parsing of DECUDK string parameter to allow a comma + between pairs of hexadecimal digits (Ray Neuman + <raymond@one.com.au> reports that "real" terminals accept + this; perhaps they simply ignore unexpected characters).
        • + +
        • fix a few problems with the $TERMCAP string + generated by resize: + +
            +
          • for Bourne shell, add an export command. + This was missing as far back as X11R5.
          • + +
          • escape exclamation marks, used in xterm's reset + string.
          • + +
          • translate literal \177\ to "^?".
          • +
          +
        • + +
        • improve configure check for tgetent() to work + when $TERMCAP has been set to a specific + entry.
        • + +
        • modify minstall.sh to use "%" rather than "@", + to avoid problems with AFS (report by Zdenek Sekera).
        • + +
        • list fatal error codes from error.h in the + manpage, remove unused codes in error.h.
        • + +
        • use more explicit wording for manpage list of color + resources, since at least one user confused the generic names + such as "black" with the names in rgb.txt (the latter are now + used).
        • + +
        • minor fix to description of 1003 mouse mode in ctlseqs.ms + (Larry Riedel).
        • +
        + +

        Patch #171 - 2002/12/12 - + XFree86 4.2.99.3

        + +
          +
        • modify parser tables to improve detection of malformed + control sequences, making xterm behave more like a real DEC + terminal (patch by Paul Williams).
        • + +
        • update comment in input.c to document + Meta as a modifier for escape sequences (patch by + D Roland Walker).
        • + +
        • add ifdef'd code for logging option which adds the hostname + and a timestamp to the generated logfile name. The ifdef's are + setup with the configure script (patch by Nelson Beebe).
        • + +
        • remove xevents() call from the end of + BlinkCursor(), to fix an occasional problem which + caused xterm to pause until a key was pressed. The reason for + this was that there was no check to ensure that there really + were events for xevents() to process. (patch by + Semen A Ustimenko <semenu@FreeBSD.org>).
        • + +
        • remove unused mode-params from open() calls + that do not create a file.
        • + +
        • modify configure script to put new items first on + $CPPFLAGS and $CFLAGS to avoid + conflict with environment's -I and -D + options.
        • + +
        • update config.guess, config.sub
        • + +
        • resync with XFree86 CVS + +
            +
          • fix va_args glitches for xterm/libfontconfig: 0 == + (void*)0 isn't true for all platforms (Egbert Eich).
          • + +
          • initialise ProgramName in xterm's main before + referencing it (XFree86 #5473, Peter Valchev).
          • + +
          • some cleanup of Imakefile ifdef's (Marc La + France).
          • +
          +
        • +
        + +

        Patch #170 - 2002/10/13 - + XFree86 4.2.1

        + +
          +
        • correct an off-by-one allocating data for sorted help + message.
        • + +
        • modify configure script to check for Xpm library, on which + XFree86 Xaw library depends.
        • + +
        • update config.guess, config.sub
        • +
        + +

        Patch #169 - 2002/10/5 - + XFree86 4.2.1

        + +
          +
        • modify wording of some options in help message to make them + use -/+ consistently with respect to "on/off" or + "off/on".
        • + +
        • sort options list which is displayed in help- and + syntax-messages at runtime to simplify maintenance.
        • + +
        • remove support for Amoeba and Minix (Juliusz Chroboczek + noted it was removed from XFree86 server; there have been no + users since 1996).
        • + +
        • add configure script option + --disable-session-mgt to control whether the + session management code should be compiled-in (request by H + Merijn Brand).
        • + +
        • ifdef'd the session-management changes with + OPT_SESSION_MGT, to accommodate X11R5 which + predates the related definitions.
        • + +
        • fix decode_keyvalue(), which did not properly + parse multiple settings as needed for the ttyModes + resource, since it did not skip over the parsed data.
        • + +
        • fix an option-parsing conflict between -class + and -cjk_width (Nam SungHyun)
        • + +
        • add a missing null in XtVaSetValues() call + used in Cleanup() (Nam SungHyun)
        • +
        + +

        Patch #168 - 2002/9/29 - + XFree86 4.2.1

        + +
          +
        • improve data reported for control sequence that requests + window position by taking into account the window decorations, + e.g., border and title (patch by Jess Thrysoee + <jess@thrysoee.dk>).
        • + +
        • add -cjk_width and corresponding resource + cjkWidth (patch by Jungshik Shin + <jshin@mailaps.org>).
        • + +
        • add -into option, for embedding xterm in a + Tcl/Tk application (patch by George Peter Staplin + <georgeps@xmission.com>).
        • + +
        • add simple session management (XSM) client capabilities to + xterm. So a session manager such as, e.g., xsm, should be able + to respawn or kill xterms without the help of an SM proxy (like + smproxy), which is a hack and almost always buggy (patch by + David Madore).
        • + +
        • fix conflict between ifdef's for + OPT_DEC_LOCATOR and OPT_READLINE in + button.c (reported by Ilya Zakharevich).
        • + +
        • fix for inconsistent use of struct utmp versus + struct utmpx introduced in patch #167 (patches by Paul Gilmartin, Marc La + France).
        • + +
        • modify logic for metaSendsEscape to allow it + to work in a setup where the Meta-key is not recognized as a + modifier by the key-translations logic (discussion of + eightBitInput with H.J.Lu). Note however that Vincent Lefevre + reported this in January).
        • + +
        • use null pointer values consistently, rather than literal + "0", for ending variable-length argument lists, e.g., for + execlp() (based on patch by Matthieu Herrb).
        • + +
        • correct logic of ChangeAnsiColorRequest(), + which would do a screen repaint after replying to a request for + information.
        • + +
        • improve scripts in vttests to work with systems whose + shells support echo -n and have, as does Debian, + an unrelated print utility.
        • + +
        • add vttests/acolors.sh to demonstrate OSC 4, which queries + or sets ANSI colors.
        • + +
        • fixes for ctlseqs.ms (Pavel Roskin, Ilya Zakharevich).
        • + +
        • typos in xterm manpage (Jens Schweikhardt)
        • + +
        • remove a redundant GCC_UNUSED from InitPopup() (Nam + SungHyun)
        • +
        + +

        Patch #167 - 2002/8/24 - + XFree86 4.2.0

        + +
          +
        • correct ifdef's for USE_TERMCAP to match + cygwin configuration.
        • + +
        • fix several places in ctlseqs.ms which had no boxes around + the literal text (report by Ilya Zakharevich).
        • + +
        • extend mouse support for readline, ifdef'd with + OPT_READLINE (integrated patch from Ilya Zakharevich).
        • + +
        • modify terminfo description to match default for + modifyCursorKeys resource.
        • + +
        • add modifyCursorKeys resource to control how + the shift- and similar modifiers are used to make a cursor + escape sequence. The default makes a modified escape sequence + always start with CSI and puts the modifier as the second + parameter, to avoid confusing applications that would interpret + the first parameter as a repeat count. The original behavior + can be obtained by setting the resource to 0 (newsgroup + discussion with Stephen J Turnbull, Jeffrey Altman).
        • + +
        • correct missing initializations for + appdefaultCursor and appdefaultKeypad + resources.
        • + +
        • add configure option --enable-luit and ifdef'd + the luit-related code with OPT_LUIT_PROG.
        • + +
        • modify xterm to invoke luit (integrated patch by Tomohiro + Kubota)
        • + +
        • update wcwidth.c to match Markus Kuhn's 2002-05-18 + version.
        • + +
        • correct limit-checking in ComputeSelect() to + handle selections that extend off the visible area; rather than + modify the parameters to TrackText(), use + ScrollSelection() to update the highlighting + limits. (reported by Yegappan Lakshmanan and Nelson Beebe, + patch by Alexander V Lukyanov).
        • + +
        • correct manpage description of tiXtraScroll + resource (reported by Tony Finch).
        • + +
        • changes from OpenBSD: + +
            +
          • Make xterm setgid utmp to be able to update utmp even + with root privileges revoked.
          • + +
          • If not updating utmp, revoke group privileges totally + too.
          • +
          +
        • + +
        • changes from NetBSD: + +
            +
          • Check that the return value from ttyslot() is greater + than 0 before writing the utmp file. Fixes w's "w: Stale + utmp entry: <user> <tty> <pty>" + errors.
          • + +
          • Use openpty() to deal with new pty naming scheme.
          • +
          +
        • + +
        • add print-redir action and menu entry to allow + user to switch terminal in/out of printer controller mode. It + appears from the manual that a real vt220 would not switch back + to normal mode, so another mechanism is used (addresses Debian + #37517).
        • + +
        • check if printerCommand resource string is + empty, use this to allow user to disable printer function.
        • + +
        • trim trailing blanks from resource strings.
        • + +
        • check return value from ptsname(), which may + return null for example if someone has changed the permissions + of /dev/pts to zero (Debian #121899).
        • + +
        • modify OS/2 version to use __UNIXOS2__ + definition rather than __EMX__, related cleanup + (patch by Holger Veit).
        • + +
        • used modified indent 2.0 (patch 20020428) to + reformat most of the C source files, to simplify + maintenance.
        • + +
        • fix a couple of places where there were leading tabs on + symbol-definition lines in Imakefile (Marc La France from + report by Tony Finch)
        • + +
        • add imake variable (TraceXTerm) to allow building debug + version (Egbert Eich).
        • +
        + +

        Patch #166 - 2002/3/25 - + XFree86 4.2.0

        + +
          +
        • correct a bug in selection: double clicking on a word which + was partly scrolled off the screen may select that text (report + by Vincent Lefevre <vincent@vinc17.org>).
        • + +
        • implement veryBoldColors resource to control + whether the corresponding video attribute such as + bold is displayed when using + colorBDMode, etc. (request by Josh Howard + <jrh@vicor-nb.com>).
        • + +
        • define escape sequences for function keys F21-F35 (patch by + Steve Wall).
        • + +
        • change the colors for the 256-color model, making them less + skewed toward black (patch by Steve Wall).
        • + +
        • add vt100Graphics resource (see patch #115, based on discussion with Glenn + Maynard).
        • + +
        • ifdef'd Xaw/Xaw3d/neXtaw includes separately to avoid + potential incompatibilities between these flavors of Athena + widgets.
        • + +
        • add configure check for XFree86 4.x Xaw library, whose + geometry management is broken, to avoid trying to use it for + toolbar configuration.
        • + +
        • updates to configure script from vile and lynx to allow + configure.in to be compiled with autoconf 2.5x
        • + +
        • add a check for null pointer return by + ptsname() (newsgroup posting from Mike Silva + <mikesilva@lucent.com>).
        • + +
        • fill in a few details needed to allow UTF-8 mode to switch + on/off after startup. This requires that wideChars + resource be set. (based on comments in 4 Aug 2001 by Alexey + Marinichev <lyosha@lyosha.2y.net>).
        • + +
        • remove duplicate install rules that make directories, e.g., + so installing manpage will not create app-defaults + directory.
        • + +
        • add comment in in do_osc(), reserving cases 30 + and 31 for for Konsole (request by Stephan Binner + <Stephan.Binner@gmx.de>).
        • + +
        • fixes for ctlseqs.ms and xterm.man (patch by Werner Lemberg + <wl@gnu.org>).
        • + +
        • add check for monochrome display, disabling colorMode in + that case (fixes Debian #134130).
        • + +
        • resync with XFree86 CVS + +
            +
          • Fix some xterm build warnings on *BSD (patch by David + Dawes).
          • + +
          • Only use SA_RESTART in xterm when it's available (patch + by Frank Liu).
          • + +
          • Fix incorrect code in signal handlers in most of the + clients, xterm and xdm not done yet (patch by Matthieu + Herrb).
          • +
          +
        • +
        + +

        Patch #165 - 2002/1/5 - + XFree86 4.1.0

        + +
          +
        • modify uxterm script to strip encoding part + from environment variable before adding ".UTF-8" (based on + Debian #125947, but using a more portable solution).
        • + +
        • add an assignment statement in VTInitialize() to make + awaitInput resource work.
        • + +
        • use new macros init_Bres(), etc., in VTInitialize() to add + trace of the initialization of resources.
        • + +
        • modify checks for $LC_ALL, related environment variables to + ensure the resulting strings are nonempty (report by Markus + Kuhn).
        • + +
        • add an ifdef in charproc.c for num_ptrs variable in case + all configure options are disabled.
        • + +
        • modify definition of getXtermBackground() to avoid negative + array index warning on Tru64 (report by Jeremie Petit).
        • + +
        • improve fix from patch #165 (still Debian #117184, report + by Matt Zimmerman <mdz@debian.org>)
        • + +
        • correct install rule for uxterm in Makefile.in, to handle + the case where building in a different directory than xterm's + source (patch by Paul Gilmartin).
        • + +
        • documented ANSI.SYS-style cursor save/restore escape + sequences in ctlseqs.ms, which are in xterm since X11R5.
        • + +
        • correct two entries in the default charClass table, which + did not follow the manpage comment about the character number + corresponding to the class (patch by Marc Bevand + <bevand_m@epita.fr>).
        • + +
        • fix a couple of typos in comments in the app-defaults files + (David Krause <xfree86@davidkrause.com>).
        • + +
        • resync with XFree86 CVS + +
            +
          • update language of copyrights in some files to reflect + the fact that they were reassigned from X Consortium to The + Open Group in 1998. Note that this xterm source is derived + from the 1996 version from X Consortium, does not + incorporate changes made by X Consortium or The Open Group + after that date, hence we do not add The Open Group's 1998 + copyright date to related files.
          • + +
          • save/restore errno in signal catcher + (patch by Matthieu Herrb).
          • + +
          • modify UXTerm.ad's font5 resource so that xterm can + display double width characters using a font distributed + with XFree86 (Tomohiro Kubota).
          • +
          +
        • +
        + +

        Patch #164 - 2001/11/13 - + XFree86 4.1.0

        + +
          +
        • correct a case where ptyInitialErase and + backarrowKeyIsErase resources combine to set + DECBKM mode, but a reset command + would not reset xterm to that state, making the erase character + revert to ^H (Debian #117184)
        • +
        + +

        Patch #163 - 2001/11/04 - + XFree86 4.1.0

        + +
          +
        • correct ifdef's for __QNX__ and + USE_SYSV_PGRP in main.c call to + tcsetpgrp, which broke bash behavior around + patch #140 (report/patch by Frank Liu + <fliu@mail.vipstage.com>).
        • + +
        • modify trace.c to fix missing definition of GCC_UNUSED for + compilers other than gcc when configured for trace code + (report/patch by Paul Gilmartin).
        • + +
        • change format in TraceOptions() to use long rather than + int, since the latter could lose precision on 64-bit machines + (report/patch by Nelson Beebe).
        • + +
        • modify xterm manual page and minstall.sh to allow imake + rules to define location of app-defaults directory (Debian + #87611).
        • + +
        • review/update list of conflicting preprocesor symbols to + remove from $CPPFLAGS at the end of the configure script. In + particular, this allows one to configure xterm without the + utempter library on Redhat 7.1 (report/patch by Adam + Sulmicki).
        • +
        + +

        Patch #162 - 2001/10/23 - + XFree86 4.1.0

        + +
          +
        • correct logic that processes -class option, so + that a following -e option is handled (Debian + #116297).
        • + +
        • improve options-decoding to allow -version and + -help options to be combined (Debian + #110226).
        • + +
        • add a 10 millisecond delay in event loop when processing + -hold option, to avoid using too much CPU time + (Debian #116213).
        • + +
        • prefix final program execution in uxterm with + "exec" to avoid a useless shell hanging around (Christian + Weisgerber).
        • +
        + +

        Patch #161 - 2001/10/10 - + XFree86 4.1.0

        + +
          +
        • modify logic that resets keypad application mode to avoid + doing this if there is no modifier associated with the Num_Lock + keysym (report by John E Davis <davis@space.mit.edu> and + Alan W Irwin <irwin@beluga.phys.uvic.ca>).
        • + +
        • add built-in translation for Control/KP_Separator to + KP_Subtract, to accommodate users who wish to use xmodmap to + reassign the top row of the numeric keypad.
        • + +
        • correct Imakefile install-rule for uxname + script (reported by Nam SungHyun <namsh@lge.com>).
        • + +
        • resync with XFree86 CVS – correct typo in + <ncurses/term.h> ifdef.
        • +
        + +

        Patch #160 - 2001/10/7 - + XFree86 4.1.0

        + +
          +
        • modify logic in main.c (see patch + #145) to avoid generating the same identifier, for example, + for /dev/tty1 and /dev/pts/1, which is used to denote an entry + in the utmp file (Debian bug report #84676), A similar fix was + also sent by Jerome Borsboom <borsboom@westbrabant.net> + in May, but I overlooked it when reviewing bug reports.
        • + +
        • add configure check for <ncurses/term.h> + to get rid of hardcoded __CYGWIN__ ifdef in + resize.c + +

          NOTE: The CYGWIN port should not be linking + resize with ncurses. It appears that the only + reason it is, is because both the ncurses and termcap ports + on that platform are badly misconfigured (essential pieces + have been removed, etc). Checking for + <ncurses/term.h> does not hurt anything, + since there are some correct installations that are set up + that way.

          +
        • + +
        • add a sample uxterm script, which uses the + UXTerm application defaults for UTF-8 + environments.
        • + +
        • undo change to xterm application defaults, since this + introduced an unnecessary incompatibility. The intended + functionality was already addressed by the UXTerm app-defaults file.
        • + +
        • resync with XFree86 CVS + +
            +
          • Modified xterm app default to use LFD fontnames instead + of old type (Michael Schroeder).
          • + +
          • Fix xterm when XIM is disabled - caused a segfault + (Tomohiro Kubota).
          • +
          +
        • +
        + +

        Patch #159 - 2001/9/19 - + XFree86 4.1.0

        + +
          +
        • remove an ifdef for USE_HANDSHAKE added in + patch #158 from the second TIOCSSIZE ioctl call in + the initialization code. Paul Gilmartin reports that for + Solaris 2.6 (sparc), stty does not show that xterm sets rows + and columns unless the second ioctl is executed.
        • + +
        • correct treatment of empty parameter list for some OSC + strings (report by Sami Farin <sfarin@ratol.fi>).
        • +
        + +

        Patch #158 - 2001/9/8 - + XFree86 4.1.0

        + +
          +
        • augment key translations for scrollbar widget to ensure + that keystrokes intended for the text area are not lost if the + mouse pointer happens to fall on the scrollbar. This can + happen, for instance, if the user's app-defaults + or .Xdefaults file contains a translations + resource, though it may also happen through unrelated resource + settings: probably a bug in libXt (reported by Paul Fox + <pgf@foxharp.boston.ma.us> and Dmitry Yu. Bolkhovityanov + <D.Yu.Bolkhovityanov@inp.nsk.su>).
        • + +
        • widen ifdef's in xterm.h to define + __EXTENSIONS__ on Solaris, for compilers other + than gcc. This was added along _POSIX_C_SOURCE + with in patch #151, but is not + sufficient since Sun's compiler does not define + __STDC__ by default (report by Matthias Scheler + <tron@zhadum.de>).
        • + +
        • modify xterm to obtain the closest matching color if an + exact color is not available, e.g., on 8-bit displays (patch by + Steve Wall)
        • + +
        • implement "OverTheSpot" preedit type of XIM input (patch by + Tomohiro Kubota): + +
            +
          • This preedit type is a reasonable compromise between + simpleness of implementation and usefulness. "Root" preedit + type is easy to implement but not useful; "OnTheSpot" + preedit type is the best in the point of view of user + interface but very complex. And more, "OverTheSpot" is the + preedit type which the most XIM servers support. Thus, to + achieve reasonable usability, support of "OverTheSpot" + preedit type is needed.
          • + +
          • In "OverTheSpot" preedit type, the preedit + (preconversion) string is displayed at the position of the + cursor. On the other hand, it is XIM server's + responsibility to display the preedit string. Thus, it is + needed for XIM client (here XTerm) to inform the XIM server + of the cursor position. And more, to achieve good visual + proportion, preedit string must be written using proper + font. Thus, it is XIM client's responsibility to inform the + XIM server of the proper font. The font must be supplied by + "fontset". Fontset is a set of fonts with charsets which + are specified by the current locale. Since XTerm uses + ISO10646 fonts regardless of the current locale, the fonts + for XIM must be prepared separately. It is difficult to + prepare fonts which are similar to XTerm font. Thus, my + patch uses a simple way - the default font is "*" which + matches every fonts and X library will automatically choose + fonts with proper charsets. I added "-fx" command option + and "ximFont" resource to override this default font + setting.
          • + +
          • changed the definition of "OverTheSpot" preedit type + from XIMPreeditPosition|XIMStatusArea to + XIMPreeditPosition|XIMStatusNothing. This matches the + behavior of other programs such as Rxvt, Kterm, Gedit.
          • + +
          • A tiny XIM bugfix is also included. By calling + XSetLocaleModifiers() with parameter of "", it can consier + XMODIFIERS environmental variable which is a standard way + for users to specify XIM server to be used.
          • +
          +
        • + +
        • adjust configure script to accommodate repackaging of + keysym2ucs.c as include-file for xutf8.c (patch by Tomohiro + Kubota).
        • + +
        • add the UXTerm app-defaults file to makefile + install rules (request by Juliusz Chroboczek).
        • + +
        • correct logic in get_termcap(), which returned + false if the tgetent() call indicated that xterm + was linked with terminfo. Although the $TERMCAP + variable cannot be adjusted in this case, xterm still needs + information from this call to extract data to initialize the + erase-mode when the ptyInitialErase resource is + false.
        • + +
        • modify ScrollbarReverseVideo() function to + cache the original border color, so it can restore that when an + application flashes the screen (Bugzilla #38872).
        • + +
        • resync with XFree86 CVS + +
            +
          • remove ifdef's for X_NOT_STDC_ENV (patch by David + Dawes).
          • + +
          • add Cygwin to special errno handling case in ptydata.c + (Alan Hourihane)
          • + +
          • set screen size earlier in initialization, to address a + race with window manager resizing its clients (Keith + Packard).
          • +
          +
        • +
        + +

        Patch #157 - 2001/6/18 - + XFree86 4.1.0

        + +
          +
        • clean up button.c and input.c (patch by Juliusz + Chroboczek). The basic idea is to use a single set of APIs in + the XTerm core, and put a set of workarounds in a separate + file. As you will notice, this drastically simplifies parts of + the code; in particular, the only remaining ifdefs related to + the differences between Xutf8 and legacy systems are related to + the selection provider logic. This defines two new files, + xutf8.h and xutf8.c, provide some half-hearted but fully + portable emulation for the three Xutf8* functions that XTerm + uses. Putting these in a separate file will allow people to + experiment with more complex versions without making the core + of XTerm more difficult to maintain. The functionality of the + emulation is as follows. + +
            +
          • Xutf8TextListToTextProperty fully handles XStringstyle + and XUTF8StringStyle. It will only generate STRING for + XStdICCTextStyle, and wil only generate Latin-1 in + XCompoundTextStyle (but label it as COMPOUND_TEXT, as the + spec requires). (I have hesitated to make this function + fail for XStdICCTextStyle and XCompoundTextStyle; this + might be a smart thing to do, in the hope that the + selection requestor will try UTF8_STRING afterwards; + opinions?)
          • + +
          • Xutf8TextPropertyToTextList fully handles STRING and + UTF8_STRING. It systematically fails for + COMPOUND_TEXT.
          • + +
          • Xutf8LookupString will properly handle single-keystroke + input for the keysyms covered by Markus' keysym2ucs + function. It will not handle either compose key input or + external input methods.
          • +
          +
        • + +
        • add an ifdef for SunXK_F36, used in + xtermcapKeycode() (patch by Mark Waggoner + <waggoner@ichips.intel.com>).
        • + +
        • modify check for login name to try getlogin() + and $LOGNAME, $USER environment variables to detect if the user + has logged in under an alias, i.e., an account with the same + user id but a different name (Debian bug report #70084).
        • + +
        • add resource tiXtraScroll, which can be used + to preserve the screen contents in the scrollback rather than + erasing it when starting a fullscreen application such as + vi (patch by Ken Martin + <fletcher@catsreach.org>).
        • + +
        • two patches by Denis Zaitsev <zzz@cd-club.ru>: + +
            +
          • added forceBoxChars resource to control + the "line-drawing characters" option.
          • + +
          • added freeBoldBox resource, which, when + set true, suppresses check in + same_font_size(), so xterm does not attempt to + ensure that the bold font is the same size as the normal + font.
          • +
          +
        • + +
        • change the color class for ANSI colors and similar ones + such as bold-color, etc., to follow the convention that the + classname is the instance name with a leading capital (e.g., + color0 and Color0 rather than + color0 and Foreground). There was + little use for Foreground as a class other than to create + occasional confusion and bug reports, most recently by Nelson + Beebe who reports that it disables colors in xterm but not on + Linux, which is probably due to a difference in resource + evaluation order. A configure script option + (--disable-color-class) is provided for anyone who did use the + older behavior.
        • + +
        • fix a signal-handling bug. When running xterm with + ksh or similar shell such as bash 2.05, xterm will + hang and not respond to keystrokes after the user types + suspend. Additionally the popup menus do not + respond, so it is not possible to send SIGCONT to the shell. + What is happening is that the shell is sending itself SIGSTOP, + and it is being stopped. Per specification it also means that + the operating system is sending SIGCHLD to parent to the bash + (XTERM). Now the issue is that xterm assumes it cannot happen + and it expects to receive SIGCHLD only upon + termination of its children. This causes a deadlock + with xterm waiting for the child to die, and the child waiting + for SIGCONT. (report/patch by Adam Sulmicki), analysis/testing + by Sven Mascheck + <sven.mascheck@student.uni-ulm.de>).
        • + +
        • correct some inconsistent checks for + XtReleaseGC() calls in + xtermLoadFont() (patch by Nam SungHyun + <namsh@lge.com>).
        • + +
        • updated wcwidth.c and keysym2ucs.c to versions dated + 2001/1/12 and 2001/4/18, respectively from + http://www.cl.cam.ac.uk/~mgk25/ucs/
        • + +
        • correction to change from patch + #90, which was intended to reset the saved cursor position + for normal/alternate screens on a soft reset, but actually + wiped out all of the saved cursor information. Just reset the + saved position for the current screen (report by Michael + Schroeder).
        • + +
        • modify ShowCursor() and HideCursor() so that if the cursor + points to the second part of a wide character, make the + show/hide operate on the first position of the wide character + (patch by Sven Verdoolaege).
        • + +
        • scrolling in the alternate screen just before switching + back to the main screen can cause extra blank lines to be + inserted into the scrollback buffer (patch by Paul Vojta + <vojta@math.berkeley.edu>).
        • + +
        • resync with XFree86 4.1.0: + +
            +
          • Use TermcapLibrary as -lncurses instead of -ltermcap, + fixes problem building xterm/resize on Cygwin/XFree86 + (Harold Hunt).
          • + +
          • Install xterm.termcap and xterm.terminfo when + installing xterm (Torrey T. Lyons).
          • + +
          • Fix some build issues on Cygwin/XFree86 (Suhaib + Siddiqi).
          • + +
          • Define CBAUD, when it's missing in xterm, on LynxOS + (Stuart Lissaman).
          • +
          +
        • +
        + +

        Patch #156 - 2001/4/28 - + XFree86 4.0.3

        + +
          +
        • change order of selection-target types to make 8-bit xterm + prefer UTF8_STRING to COMPOUND_TEXT (patch by Juliusz + Chroboczek).
        • + +
        • document -fa, -fs command-line + options and faceName, faceSize + resources which are used by the freetype library support.
        • + +
        • if configure script finds freetype libraries, but imake + definitions do not have the XRENDERFONT definition, define it + anyway.
        • + +
        • modify configure script check for freetype libraries to + include <Xlib.h>, since an older version of + the related headers relies on this (patch by Adam + Sulmicki).
        • +
        + +

        Patch #155 - 2001/4/20 - + XFree86 4.0.3

        + +
          +
        • correct return type of in_put() from patch #153 changes, which left it not wide + enough for UTF-8 (patch by Bruno Haible).
        • +
        + +

        Patch #154 - 2001/4/11 - + XFree86 4.0.3

        + +
          +
        • undo check for return value from pututline + (used for debugging) since that function does not return a + value on Slackware 3.6.
        • + +
        • correct length in ScreenWrite, when rendering invisible + text (patch by Sven Verdoolaege <skimo@kotnet.org>).
        • + +
        • fixes/improvements for the i18nSelection + resource from patch #153, by Bruno Haible: + +
            +
          • add missing initialization for + i18nSelection resource.
          • + +
          • split-out the non-ICCM aspect of the + i18nSelection resource as a new resource, + brokenSelections.
          • +
          +
        • + +
        • add configure check for <time.h> and + <sys/time.h>, to allow for Unixware 7, + which requires both. If the configure script is not used, only + <time.h> will be included as before (report + by Thanh Ma).
        • + +
        • fix redefinition of dup2, + getutent, getutid, + getutline and sleep functions on + Unixware 7 (report by Thanh Ma + <Thanh.Ma@casi-rusco.com>)
        • + +
        • add a fall-back definition for __hpux, which + is apparently not defined in some compilers on HPUX 11.0 + (reported by Clint Olsen).
        • + +
        • change VAL_INITIAL_ERASE, which is used as a fallback for + the "kb" termcap string to 8, since that matches + the xterm terminal description (request by Alexander V + Lukyanov).
        • + +
        • correct an off-by-one in ClearInLine, which + caused the erase-characters (ECH) control to display + incorrectly (patch by Alexander V Lukyanov).
        • + +
        • correct escape sequences shown in terminfo for shifted + editing keys. The modifier code was for the control key rather + than the shift key.
        • +
        + +

        Patch #153 - 2001/3/29 - + XFree86 4.0.3

        + +
          +
        • increase PTYCHARLEN to 8 for os390, add some debugging + traces for UTMP functions (patch by Paul Gilmartin).
        • + +
        • correct an misplaced brace in + SelectionReceived() (patch by Bruno Haible).
        • + +
        • correct an assignment dropped in + SelectionReceived() which made it not compile for + wide-characters combined with debug traces.
        • + +
        • correct typo, clarify description of 88- and 256-color + controls (report by Bram Moolenaar).
        • + +
        • correct a typo in ctlseqs.ms which caused DEC Locator + control sequences using single quote "'" display grave "`" + instead (reported by Paul Williams, apparently in patch + #114).
        • +
        + +

        Patch #152 - 2001/3/13 - + XFree86 4.0.2

        + +
          +
        • correct index in inner loop in VTInitI18N() + from patch #151 changes, which resulted in infinite loop under + some conditions (report/analysis by Paul Gilmartin).
        • + +
        • remove spurious "%|" from terminfo sgr capabilities + (report/analysis by Adam M Costello, Debian #89222).
        • + +
        • add shell script to adjust list of dynamic libraries linked + by resize when building with the standalone + configure script. Otherwise it uses the same list as for xterm, + which is excessive.
        • + +
        • fix a few compiler warnings reported by the 20010305 gcc + snapshot.
        • +
        + +

        Patch #151 - 2001/3/10 - + XFree86 4.0.2

        + +
          +
        • alter the behaviour of selections in XTerm (patch by + Juliusz Chroboczek). It is believed to follow the ICCCM + + UTF8_STRING to the letter, both in UTF-8 and in eight-bit mode. + From his description: + +
            +
          • When compiled against XFree86 4.0.2, the patched XTerm + will make the selection available as COMPOUND_TEXT, STRING + or UTF8_STRING in both modes. It will request selections in + the following order: + +

            UTF-8 mode: UTF8_STRING, TEXT, COMPOUND_TEXT, + STRING.
            + eight-bit mode: TEXT, COMPOUND_TEXT, UTF8_STRING, + STRING.

            +
          • + +
          • When compiled against an earlier version of XFree86 (or + compiled with OPT_UTF8_API=0), it will still obey the + ICCCM, but will neither request nor provide UTF8_STRING in + eight-bit mode, and neither TEXT nor COMPOUND_TEXT in UTF-8 + mode.
          • + +
          • For compatibility with previous versions of XTerm, a + resource i18nSelections is provided, please + see the manpage for details. However, due to an unexpected + combination of ICCCM extensions by various bits and pieces + of the libraries, interacting with previous versions of + XTerm will work in many locales even without this flag. + (Please do not set this resource to true by default, as + this would violate the ICCCM.)
          • +
          +
        • + +
        • improved error checking/reporting in VTInitI18N(), ensuring + that lack of input method styles is treated distinctly from a + mismatch.
        • + +
        • remove an incorrect ifdef from patch #141 which suppressed + overstriking to simulate bold font when xterm was compiled to + support wide characters (report/analysis by Adam M Costello + <amc@cs.berkeley.edu>, Debian #76404, Debian + #77575).
        • + +
        • modify RequestResize() function to + save/restore window manager hints. Its call to + XtMakeResizeRequest() had the undesirable + side-effect of clearing window manager hints, e.g., when + switching to 132-columns via DECCOLM escape sequence. Window + manager hints make it simple to resize xterm in terms of + character cells rather than pixels (reports by Christian + Weisgerber, Debian #79939). + +

          This applies to the normal configuration. When built with + toolbar support, the hints are applied to a different widget + level (more work will be needed to make hints work with the + toolbar).

          +
        • + +
        • fix a redefinition warning for resize.c on OpenBSD (patch + by Christian Weisgerber).
        • + +
        • change resource corresponding to -T option to + match Xt library's -title, i.e., + .title rather than *title so the + command-line options are interchangeable as documented (Debian + bug report #68843).
        • + +
        • add script used from autoconf'd makefile for installing + manpages, since recent XFree86 changing the way section numbers + are represented makes the install dependent on extra + scripts.
        • + +
        • add configure check for freetype libraries and configure + option --disable-freetype to override this feature.
        • + +
        • modify some configure script macros to avoid using + changequote(), which has been rendered useless in the latest + autoconf alpha 2.49c
        • + +
        • update config.guess, config.sub to 2001-2-13
        • + +
        • remove redundant/contradictory __CYGWIN__ definitions from + resize.c
        • + +
        • correct manpage typo introduced by X11R6.5 resync.
        • +
        + +

        Changes from XFree86 4.0.2:

        + +
          +
        • add definition of _POSIX_C_SOURCE for Solaris + to make this compile with gcc -ansi -pedantic + (report by <mark@zang.com>.
        • +
        + +

        Patch #150 - 2000/12/29 - + XFree86 4.0.2

        + +
          +
        • move the binding for shifted keypad plus/minus, which + invokes the larger-vt-font() and + smaller-vt-font() actions, respectively, into the + translations resource (suggested by Marius Gedminas + <mgedmin@puni.osf.lt>).
        • + +
        • modify configure script to support the + --program-prefix, --program-suffix + and --program-transform-name options (request by + Alison Winters <alison@mirrabooka.com>).
        • + +
        • fixes for wide/combining characters (Robert Brady): + +
            +
          • fix a scrolling / combining characters display + anomaly
          • + +
          • fix a problem with double-width characters where if the + primary font had no box-drawing characters, the right hand + half of double-width characters was erased (reported by Yao + Zhang <yzhang@sharemedia.com>).
          • + +
          • fix special case of null byte for key handling in UTF-8 + locales.
          • +
          +
        • + +
        • modify logic that compares sizes of normal and bold fonts + to be more forgiving of the font server's choice of bold font + which must match the normal font's size. Now + same_font_size() compares the height of the fonts + rather than individually ascent and descent, and allows the + bold font to be one pixel smaller than the normal font + (addresses a report by Alan Citterman <alan@mticket.com>, + who says that something in patches #146 to #148 made xterm more + likely to overstrike bold fonts, and indirectly Debian bug + report #76404, which reports the opposite).
        • + +
        • make configure script use $CFLAGS and $CPPFLAGS + consistently, including removing a chunk from configure.in + which attempted to save/restore $CPPFLAGS while processing + value set by the --x-includes option, but lost values set in an + intervening AC_CHECK_HEADERS. This change modifies macros + CF_ADD_CFLAGS, CF_ANSI_CC_CHECK and CF_X_TOOLKIT, as well as + removing variables IMAKE_CFLAGS and X_CFLAGS from the generated + makefile (the AC_CHECK_HEADERS problem was reported by Albert + Chin-A-Young <china@thewrittenword.com<).
        • + +
        • correct a comparison in SELECTWORD case of ComputeSelect(), + which resulted in a word-selection wrapping past the first + column without checking the first column's character class + (reported by Christian Lacunza + <celacunza@netscape.net>
        • + +
        • correct a logic in UTF-8 mode for selecting double-width + characters; a combining character was omitted (patch by Markus + Kuhn).
        • + +
        • add feature to pop (raise) window when a bell is received + (patch by Gael Roualland + <gael.roualland@dial.oleane.com>).
        • + +
        • add __NetBSD__ and __OpenBSD__ to special-case in + xterm_io.h for USE_POSIX_TERMIOS definition (patch by Christian + Weisgerber).
        • + +
        • move special-case HPUX include for <sys/bsdtty.h> to + xterm_io.h to define TIOCSLTC, making HAS_LTCHARS defined for + HPUX 10.20 (report by Bruno Betro).
        • +
        + +

        Patch #149 - 2000/12/6 - + XFree86 4.0.1h

        + +
          +
        • restructured includes for termios.h, + termio.h and related definitions for main.c, + os2main.c, screen.c and resize.c so they will share equivalent + definitions in a new header xterm_io.h. This is + intended to solve some problems mainly for HPUX which appear to + arise from inconsistent definitions for SIGWINCH- and + HAS_LTCHARS-related symbols (reports by Bruno Betro, Jeremie + Petit and Clint Olsen).
        • + +
        • improve usability of double-width fonts by allowing normal + fonts to be given as double-width (from a patch by Fabrice + Bellard <bellard@email.enst.fr>).
        • + +
        • correct a few compiler warnings in TRACE() macros for + signed/unsigned variable differences (reported by Clint + Olsen).
        • + +
        • make configure script use $CFLAGS and $CPPFLAGS more + consistently, i.e., by using CF_ADD_CFLAGS in CF_ANSI_CC + macro.
        • + +
        • expanded description of environment variables in + manual-page.
        • + +
        • modify OPT_TCAP_QUERY feature to always return the termcap + or terminfo capability string in the response, and to + read/write the names in hexadecimal form to allow for the + special case of termcap's k; name (patch by Bram + Moolenaar).
        • + +
        • add OPT_SAME_NAME and OPT_TCAP_QUERY to xtermcfg.hin, so + the corresponding configure options work (patch by Bram + Moolenaar).
        • + +
        • resync with XFree86 4.0.1g: + +
            +
          • Rewrite Xft library for Render extension/core text and + font management Change xterm to use new interface (Keith + Packard).
          • +
          +
        • +
        + +

        Patch #148 - 2000/10/31 - + XFree86 4.0.1d

        + +
          +
        • document logfile options in man-page.
        • + +
        • correct spelling of -samename option in help + message.
        • + +
        • add configure script option + --enable-tcap-query (request by Bram + Moolenaar).
        • + +
        • add a "Co" or "colors" entry to the OPT_TCAP_QUERY feature + (patch by Bram Moolenaar).
        • + +
        • patch by Kiyokazu Suto <suto@ks-and-ks.ne.jp>: + +
            +
          • add support for bold font for double width characters. + The font name may be specified with the command line option + -fwb or with resource + wideBoldFont (class + WideBoldFont).
          • + +
          • correct underlining of double width character string, + which was drawn only half width.
          • + +
          • correct binary search of precomposed character table, + which may return wrong result when int is just + 32 bits.
          • +
          +
        • + +
        • some changes to align terminfo with ncurses 5.2: + +
            +
          • remove xtermm description, retaining xterm-mono since + the former conflicts with ncurses.
          • + +
          • modify initialization and reset strings to avoid + putting the save/restore cursor operations bracketing + changes to video attributes, since the changes could be + lost when the cursor is restored. This affects xterm-r6 and + xterm-8bit (the xterm-xfree86 entry uses the soft-reset + feature which resets scrolling margins and origin mode + without requiring us to save/restore the cursor + position).
          • + +
          • make a few entries explicitly inherit from + xterm-xfree86 rather than xterm: xterm-rep, xterm-xmc, + xterm-nrc
          • +
          +
        • + +
        • ensure that sign-extension does not affect + ctype macros by using CharOf() macro + to coerce the parameter to an unsigned char.
        • + +
        • resync with XFree86 4.0.1d: + +
            +
          • Add primitive support in xterm for Xft based fonts + (Keith Packard). The changes are ifdef'd with + -DXRENDERFONT.
          • +
          +
        • +
        + +

        Patch #147 - 2000/10/26 - + XFree86 4.0.1c

        + +
          +
        • correct implementation of ptyInitialErase: the + value assigned to initial_erase was for the + control terminal, which is correct as far as it goes. But there + was no following test for the pseudo-terminal's erase value, + which would overwrite the default obtained from the control + terminal (reported by Christian Weisgerber + <naddy@mips.inka.de>).
        • + +
        • modify check for printable-characters in OSC string to use + xterm's ansi_table rather than isprint() macro, to isolate this + check from locale settings. This fixes a problem using 8-bit + characters to set the title (reported by Ricardas Cepas + <rch@richard.eu.org>).
        • + +
        • modify sample scripts to check for printf before print, + since the latter is not as well standardized (e.g., on + Linux).
        • + +
        • updated config.sub, config.guess to reflect changes on + subversions.gnu.org
        • +
        + +

        Patch #146 - 2000/9/12 - + XFree86 4.0.1c

        + +
          +
        • correct two instances overlooked from patch #141 which + assumed UTF-8 mode without checking, causing a core dump in + non-UTF-8 mode (one instance was reported by Tommi Virtanen + <tv@debian.org>).
        • + +
        • correct a problem selecting from the scrollback buffer in + UTF-8 mode by changing remaining getXtermCell() calls to + XTERM_CELL() as in the non-UTF-8 cases (report by Markus Kuhn, + patch by Robert Brady).
        • +
        + +

        Patch #145 - 2000/9/11 - + XFree86 4.0.1c

        + +
          +
        • changes for UTF-8 configuration (Robert Brady): + +
            +
          • doublewide characters don't lose their accents when the + cursor moves onto or from them (a visual bug)
          • + +
          • fix logic in addXtermCombining, which mean that if the + low byte of a cell's first combining char was 0, a + following combining char would go into combining slot 1, + not 2.
          • + +
          • modify logic for cut-buffers so UTF-8 data is first + converted to Latin1.
          • + +
          • collapse surrogates, 0xfffe, 0xffff to UCS_REPL.
          • + +
          • modify to allow xterm to to show combining characters + attached to doublewidth characters.
          • + +
          • correct bug in linewrap with -u8 option (reported by + Andreas Koenig <andreas.koenig@anima.de>).
          • +
          +
        • + +
        • several changes to PTY logic (based on request by Tim Ryan + <timryan@nortelnetworks.com>). + +
            +
          • modify treatment of -S option to to make + it work with Unix98 PTY's.
          • + +
          • restore sense of IsPts flag in get_pty(), + which was lost in Unix98 changes.
          • + +
          • use new functions my_pty_id() and + my_pty_name() to simplify/fix strings used for + utmp, wtmp identifiers.
          • + +
          • simplify get_pty() function, making it + have a single return point so its inputs/outputs can be + identified.
          • +
          +
        • + +
        • update config.guess and config.sub and scripts to my + 20000819 patch, adding cases for OS/2 EMX.
        • + +
        • add special case for os390 compiler options to configure + script (patch by Paul Gilmartin)
        • + +
        • fix some unused-variable compiler warnings (reported by + Zdenek Sekera).
        • + +
        • split-out some string functions into xstrings.c, to use + them more consistently among main.c, os2main.c and + resize.c
        • + +
        • align termcap/terminfo files, adding entries to make them + match. The termcap entries are necessarily less complete than + the terminfo, to fit within 1023 character per entry.
        • + +
        • add terminfo entry for xterm-sco (SCO function keys).
        • + +
        • modify same_font_name() to properly handle + wildcard introduced in bold_font_name(), making + comparison for different fonts succeed when only the normal + font is specified. This is needed to decide if 1-pixel offset + should be used. (reported in a newsgroup by Bart Oldeman + <enbeo@enbeo.resnet.bris.ac.uk>)
        • + +
        • correct preprocessor line for OPT_WIDE_CHARS in + drawXtermText() from patch #141 which resulted in overstriking + for bold fonts not working.
        • + +
        • correct Imakefile from 4.0.1c resync so UTF-8 modules are + in UTF8SRC, UTF8OBJ lists, allowing build without UTF-8 + support.
        • +
        + +

        Patch #144 - 2000/8/23 - + XFree86 4.0.1b

        + +
          +
        • remove a spurious assignment in ScreenWrite() from Robert + Brady's patch which set a null at the "end" of the buffer to be + written. That made the autowrap feature write a blank in the + first column for the non-UTF-8 configuration, rather than the + actual character (reported by Alan Citterman + <alan@mticket.com>).
        • +
        + +

        Patch #143 - 2000/8/19 - + XFree86 4.0.1b

        + +
          +
        • add a check to ensure that -class command-line + option is not confused with -c (reported by Paul + Townsend <aab@aab.cc.purdue.edu>).
        • +
        + +

        Patch #142 - 2000/8/18 - + XFree86 4.0.1b

        + +
          +
        • correction to precompose scripts, so 0061 + 0300 will now + be really be displayed as 00C0 (patch by Robert Brady + <robert@susu.org.uk>).
        • + +
        • correct macro ClassSelects() in button.c, used to hide + ifdef's for OPT_WIDE_CHARS in patch #141 (reported by Andreas + Paul <paula@informatik.tu-muenchen.de>).
        • + +
        • change wcwidth.h to include stddef.h rather than wchar.h, + which is not present on OpenBSD and FreeBSD (reported by + Christian Weisgerber and Bram Moolenaar).
        • + +
        • newer config.sub and config.guess, from lynx + 2.8.4dev.7
        • +
        + +

        Patch #141 - 2000/8/14 - + XFree86 4.0.1b

        + +
          +
        • changes for doublewidth and combining characters, from + http://www.ecs.soton.ac.uk/~rwb197/xterm/ (integrated patch by + Robert Brady). In this context, doublewidth refers to 16-bit + character sets which may have glyphs occupying two cells.
        • + +
        • add command-line option -class, which allows + one to override xterm's resource class. Also add resource file + UXTerm.ad, which simplifies using xterm for both + 8-bit character sets and UTF-8.
        • + +
        • fixes/improvements to OPT_TCAP_QUERY logic (patches by Bram + Moolenaar, Steve Wall).
        • +
        + +

        Patch #140 - 2000/7/23 - + XFree86 4.0.1

        + +
          +
        • modify Makefile.in to circumvent GNU make's built-in suffix + rule for ".sh" which confuses install.sh with the "make + install" target (report/patch by Paul Gilmartin).
        • + +
        • implement an experimental control sequence which an + application may use to query the terminal to determine what + sequence of characters it would send for a given function key. + This is ifdef'd with OPT_TCAP_QUERY (request by Bram + Moolenaar).
        • + +
        • add /usr/local to search path in CF_X_ATHENA configure + macro to build with Xaw3d on OpenBSD (patch by Christian + Weisgerber).
        • + +
        • add missing #undef HAVE_TERMIO_C_ISPEED to + xtermcfg.hin, omitted in patch #133 fix for IRIX 6.5 baudrate + (report by Alain Filbois <Alain.Filbois@loria.fr>).
        • + +
        • correct a few errors in xterm.man: font in filename example + for Tektronix emulation, and description of -nul/+nul + command-line options (report by Eric Fischer + <enf@pobox.com>).
        • + +
        • update config.guess and config.sub, from tin and lynx.
        • +
        + +

        Patch #139 - 2000/6/17 - + XFree86 4.0d

        + +
          +
        • back out change to -name command-line option, + restoring its original behavior (as noted by David Madore, the + correct interpretation of this option is the application + instance rather than the application class).
        • +
        + +

        Patch #138 - 2000/6/15 - + XFree86 4.0c

        + +
          +
        • workaround for fixed fonts which are generated from Unicode + fonts: they omit glyphs for some xterm's less-used line-drawing + characters, which caused xterm to set a flag telling it to use + only its internal line-drawing characters. Do not set the flag + (it can be set from the popup menu), and xterm will generate + only the line-drawing glyphs which actually are missing.
          + Otherwise, when used for large fonts, xterm may generate a + 2-pixel wide line, which can leave dots on the screen.
        • + +
        • restore first line of 256colres.pl, omitted in 4.0c + diffs.
        • +
        + +

        Patch #137 - 2000/6/10 - + XFree86 4.0b

        + +
          +
        • make command-line -name option work as + documented. Apparently this was lost in X11R5 when coding to + use XtAppInitialize.
        • + +
        • limit numeric parameters of control sequences to 65535 to + simplify checks for numeric overflow.
        • + +
        • change index into UDK list to unsigned to guard against + numeric overflow making the index negative (Taneli Huuskonen + <huuskone@cc.helsinki.fi>).
        • + +
        • change sun function-keys resource name to + sunFunctionKeys to work around redefinition of the + token sun by xrdb on Solaris. Similarly, renamed + resource sun keyboard to + sunKeyboard (Steve Wall).
        • + +
        • change similar resource names for HP and SCO to avoid + potential conflict with xrdb symbols on other systems, as well + as for consistency.
        • + +
        • reorganized the install targets in the autoconf'd Makefile, + adding install-app, install-bin, install-dirs and install-man. + The app-defaults class can be overridden by setting the make + variable 'CLASS', simplifying customization of xterm as a + Unicode terminal, e.g., CLASS=UXTerm.
        • + +
        • add limit checks to ClearInLine(), + ScrnInsertChar(), ScrnDeleteChar() to + correct potential out-of-bounds indexing (prompted by Debian + bug report #64713, which reported a problem with ICH escape + sequences).
        • + +
        • updates to config.sub and config.guess Kevin Buettner + <kev@primenet.com> for elf64_ia64 Bernd Kuemmerlen + <bkuemmer@mevis.de> and MacOS X.
        • + +
        • for os390, add check for errno set to ENODEV on failure to + open /dev/tty when there is no controlling terminal (patch by + Paul Gilmartin).
        • + +
        • fixes for building on Digital Unix 4.0 and AIX 4.2 (patch + from H Merijn Brand <h.m.brand@hccnet.nl>).
        • + +
        • modify DECRQSS reply for DECSCL to additionally report if + the terminal is set for 8-bit controls.
        • +
        + +

        Patch #136 - 2000/6/3 - + XFree86 4.0b

        + +
          +
        • add a resource (limitResize) limiting resizing + via the CSI 4 t and CSI 8 t sequences.
        • + +
        • ignore out-of-bounds resize requests, i.e., where + sign-extension or truncation of the parameters would + occur.
        • +
        + +

        Patch #135 - 2000/5/29 - + XFree86 4.0b

        + +
          +
        • remove code introduced in #134 which made some backgrounds + bold.
        • + +
        • minor correction to format of updated $TERMCAP when adding + kb capability for ptyInitialErase + logic.
        • + +
        • improved test for SVR4 definition.
        • +
        + +

        Patch #134 - 2000/5/28 - + XFree86 4.0b

        + +
          +
        • update URL's and mailing addresses, moved to + http://dickey.his.com and dickey@herndon4.his.com
        • + +
        • correct missing quotes in CF_TTY_GROUP configure script + macro in case the script is run in batch mode.
        • + +
        • modify ownership-check of log file to ignore the group + ownership. Otherwise xterm cannot create logfiles in + directories with set-gid permissions.
        • + +
        • simplify the logic that reads termcap data.
        • + +
        • add fallback definition for B9600 in case line speed + definition for 38400 is missing (report by Jack J Woehr + <jwoehr@ibm.net>, for OpenBSD 2.6).
        • + +
        • fix: Set highlightColor, and select a region containing the + text cursor. If the window loses focus, the cursor becomes + hollow, with the region inside the cursor being + background/foreground, unlike the rest of the selection, which + is foreground/highlight (patch by Ross Paterson + <ross@soi.city.ac.uk>).
        • + +
        • add configure script tests to define SVR4, SYSV and + USE_POSIX_WAIT, which enables xterm to compile on Solaris 7 and + SCO Openserver without imake, though there are still a few + features for the latter which require sco to be + predefined.
        • + +
        • patches from Steve Wall: + +
            +
          • add support for two Sun-specific function keys. These + keys are labeled F11 and F12 on Sun Type 5 keyboards, but + return SunXK_F36 and SunXK_F37. Support will only be + compiled in if the header file <X11/Sunkeysym.h> + exists and contains the appropriate symbol definitions. The + keycodes for the DEC keycodes were arbitrary unused codes, + but the ones for the Sun keycodes are what cmdtool and + shelltool actually send.
          • + +
          • add colorRV and colorRVMode + resources to allow specifying a color to use for reverse + video, similar to the existing UL, BD, and BL modes.
          • + +
          • add alwaysUseMods resource, to override + check if alt or meta modifiers + are used in translations resource. Revamped + the code to calculate the modifier value, and included Meta + if alwaysUseMods is TRUE, using values 9-16.
          • +
          +
        • + +
        • fixes for os390 (Paul Gilmartin): + +
            +
          • regularize the definition of CONTROL() and remove an + acknowledged "trial and error" table.
          • + +
          • translate "^?" into A2E(0177) which is the EBCDIC "DEL" + rather than plain 0177 which is the EBCDIC quotation + mark.
          • + +
          • modify xtermMissingChar() so that EBCDIC + codes 128-159 are not rendered as blanks by X server + running on Solaris, which sees those as control + characters.
          • + +
          • make debugging traces (configure --enable-trace) work + properly with EBCDIC.
          • +
          +
        • +
        + +

        Patch #133 - 2000/5/2 - + XFree86 4.0a

        + +
          +
        • add substitutions in autoconf'd Makefile for CPPFLAGS, + LDFLAGS and AWK (reported by Neil Bird).
        • + +
        • correct uninitialized childstat variable from + patch #131 in creat_as() function, which caused + logging to not work on Solaris, whose waitpid() + function does not initialize its parameter. Add check for EINTR + on return from waitpid() as well (reported by Neil + Bird <neil.bird@rdel.co.uk>).
        • + +
        • remove a redundant check for working setuid() + function introduced in patch #132. Greg Smith reports that this + does not work as intended on os390.
        • + +
        • change line speed from 9600bd to 38400bd, to accommodate + people who mistakenly use $TERM set to vt100, to + reduce the effect of padding associated with this terminal + type.
        • + +
        • add configure script check for IRIX 6.5's redefinition of + baud rates associated with struct termio, to + correct a situation where the baud rate was initialized to zero + (reported by Andrew Isaacson <adi@lcse.umn.edu>).
        • + +
        • remove unused configure script check for VDISABLE.
        • +
        + +

        Patch #132 - 2000/4/11 - + XFree86 4.0a

        + +
          +
        • undo an incorrect change from patch #113 caused the right + scrollbar to be positioned incorrectly when re-enabling it + (analysis by D Roland Walker).
        • + +
        • add ctrlFKeys resource, replacing constant for adjusting + control-F1 to control-F12 to VT220-style F10-F20. The resource + changes the constant 12 to a default value of 10 (request by + Jim Knoble <jmknoble@pobox.com>).
        • + +
        • correct ifdef'ing for conflict between definitions in AIX's + <sys/select.h> and <X11/Xpoll.h> (reported by Clint + Olsen).
        • + +
        • add checks for return-values of getutid(), initgroups() and + setuid() in main.c, as well as modifying ifdef's for __osf__ to + include tty-group and WTMP logic (adapted from patch by Paul + Szabo <psz@maths.usyd.edu.au>)
        • + +
        • modify resize.c to build and work on os390 (uses EBCDIC) + (adapted from patch by Phil Sidler + <Phil.Sidler@airborne.com>)
        • + +
        • use Ires(), Bres() and Sres() macros to simplify resource + list in charproc.c
        • + +
        • resync with XFree86 4.0a: + +
            +
          • correct a typo in os2main.c (Holger Veit, from + 4.0a).
          • +
          +
        • +
        + +

        Patch #131 - 2000/3/3 - + XFree86 3.9.18b

        + +
          +
        • improve logfile security (integrated patch by Branden + Robinson) + +
            +
          • make the creat_as() function more strict + by using O_EXCL rather than O_APPEND.
          • + +
          • fixes to make DEBUG ifdef's compile/run, including + making the debug logfile more unique by appending a + timestamp to its name.
          • + +
          • include <term.h> in resize.c, to fix a + missing-prototype warning.
          • +
          +
        • + +
        • modified creat_as() a little more, retaining + the ability to append to a logfile If the user specifies the + name. Also, check if the opened file (which patch #130 ensures + is owned by the effective user) is not writable by other + users.
        • + +
        • use creat_as() logic to make tek4014 + screen-copy more secure (noted by Branden Robinson).
        • + +
        • ifdef'd some of Branden's changes to build/work on older + machines.
        • + +
        • correct missing initialization of the .mode + flag in ColorRes struct, from patch #129. This + worked on Linux because malloc() zeroes memory on + that platform (reported by Christian Weisgerber).
        • + +
        • modify logic for deleteIsDEL resource so it + has internally 3 states: unspecified, true and false. If + unspecified, the keyboard type determines whether the Delete + key transmits <ESC>[3~ or \177, + and the popup menu entry reflects the internal state. + Otherwise, the popup menu entry overrides the keyboard type + (suggested by Dr Werner Fink, to make it simpler to set + resources that imitate the legacy X11R6 xterm).
        • +
        + +

        Patch #130 - 2000/3/1 - + XFree86 3.9.18a

        + +
          +
        • modify scroll-forw() and + scroll-back() actions, adding a third parameter + which will direct xterm to ignore the action when mouse + reporting is enabled. This is needed for the wheel mouse to be + used to report to the application rather than scroll the + window.
        • + +
        • add menu entry and action to allow disabling xterm's + assumption that the current font contains line-drawing + characters if the font cells 1-31 are nonempty. Some fonts may + have other characters (reported by Bruno Betro + <bruno@iami.mi.cnr.it>).
        • + +
        • add a check in creat_as() to ensure that the + user really owns the logfile that has been opened.
        • + +
        • add logic to implement SCO function-keys. (This is really + incomplete, since I intend to revisit this and make xterm able + to emulate scoansi better than just the function-keys).
        • + +
        • add configure script option --enable-sco-fkeys, minor + related fixes (patch by Dr Werner Fink).
        • + +
        • fix typos in ctlseqs.ms (reported by Bram Moolenaar)
        • + +
        • fix typo in sinstall.sh default for $TST_PROG (reported by + Paul Gilmartin <pg@sweng.stortek.com>)
        • +
        + +

        Patch #129 - 2000/2/26 - + XFree86 3.9.18a

        + +
          +
        • improve initialization of ANSI colors by delaying + allocation until each color is first used.
        • + +
        • remove ifdef that prevented colorBD/colorUL/colorBL + resources from working when 256-color configuration was built + (reported by Todd Larason).
        • + +
        • fix some minor inconsistencies in terminfo (Debian + #58530).
        • +
        + +

        Patch #128 - 2000/2/17 - + XFree86 3.9.18

        + +
          +
        • correct logic for oldXtermFKeys resource, + fixes a core dump when attempting to set it from the + command-line (reported by Dr Werner Fink).
        • + +
        • correct ifdef for meta-sends-escap so configure + --disable-num-lock builds.
        • +
        + +

        Patch #127 - 2000/2/12 - + XFree86 3.9.17e

        + +
          +
        • add resource, popup menu entry and control sequence to + allow changing the Delete key to send either DEL or the + VT220-style Remove escape sequence.
        • + +
        • remove logic for metaSendsEscape that would allow xterm to + send <ESC>[3~ before a function key that + would begin with <ESC>[3~ (request by + Christian Weisgerber).
        • + +
        • add missing action and documentation for + meta-sends-escape.
        • + +
        • correct a few typos in ctlseqs.ms (incorrect code for Cyan + color)
        • +
        + +

        Patch #126 - 2000/2/8 - + XFree86 3.9.17c

        + +
          +
        • ensure that xterm will automatically activate the UTF-8 + mode whenever the name of the locale environment variable + suggests that a UTF-8 locale is in use (patch by Markus Kuhn). + This will help that by simply setting LC_CTYPE an entire system + can be switched over to UTF-8, without users having to remember + the UTF-8 command line options ("-u8", etc.) of the various + applications. Command line options and X resource entries can + still be used to override this default choice.
        • + +
        • add old function-keys control sequences and popup menu + entry, for compatibility with legacy X11R6 xterm.
        • + +
        • revert translation of editing keypad "Delete" key to legacy + \177.
        • + +
        • simplify the color-resource data expressions with macro + COLOR_RES, for later use in restructuring color + initialization.
        • + +
        • change encoding of wheel mouse (buttons 4 and 5) to avoid + conflict with legacy mouse modifiers (suggested by Bram + Moolenaar).
        • +
        + +

        Patch #125 - 2000/1/31 - + XFree86 3.9.17c

        + +
          +
        • make this work on OpenVMS (integrated patch by David + Mathog).
        • + +
        • rename some functions, e.g., Index to + xtermIndex so that ports such as VMS which link + externals ignoring case will not have library conflicts + (reported by David Mathog).
        • + +
        • correct logic of do_reversevideo(), which did + not update the corresponding popup menu check mark (reported by + David Mathog, this was a detail overlooked in patch #94).
        • + +
        • change TRACE macro so semicolon is not within definition, + making indent and similar programs work better.
        • + +
        • add depend rule to Makefile.in
        • + +
        • modify logic of boldColors resource to suppress it if an + extended color control has been used, e.g., for 88-color or + 256-color mode (patch by Todd Larason).
        • + +
        • revise logic that handles menus and input translation for + keyboard type so only one can be selected at a time.
        • + +
        • restore kdch1=\177 for the Sun function-key type, and make + the the Delete key send DEL (\177) if the oldXtermFKeys + resource is set.
        • + +
        • rephrase logic and ifdef's for POSIX VDISABLE to avoid + preprocessor expression that will not compile on NetBSD/x86 + 1.4.1 (reported by Takaaki Nomura + <amadeus@yk.rim.or.jp>).
        • +
        + +

        Patch #124 - 2000/1/27 - + XFree86 3.9.17b

        + +
          +
        • change coding of editing keypad's "Delete" key to + <escape>[3~, in the default (Sun/PC) keyboard mode. This + makes the terminfo kdch1 capability independent of the coding + of the backarrow key, which sends either backspace (8) or DEL + (127). The reason for doing this (compatibility with the + screen program) outweighs the choice of DEL (127) + which was used in X11R5/X11R6 xterms. The screen + program translates whatever matches kdch1 into + <escape>[3~, even if it happens to be the stty erase + character.
        • + +
        • add encoding for control/?, to work around xmodmap or key + translations which may confuse backspace and delete. A + control/? will send DEL (127), and a control/H will of course + send backspace (8).
        • + +
        • add encoding for kcbt to <escape>[Z (fixes Debian + #54840).
        • + +
        • minor correction to logic that encodes Sun and DEC function + keys to avoid sending an escape sequence if the key symbol is + not found in xterm's lookup table.
        • + +
        • simplify ifdef's in main.c for POSIX VDISABLE so the "^-" + pattern is more likely to be implemented when imake + configures xterm (fixes Debian #55105).
        • + +
        • change manpage to make it clearer what codes are sent by + the backarrow key.
        • +
        + +

        Patch #123 - 2000/1/22 - + XFree86 3.9.17a

        + +
          +
        • add a note reserving OSC 51 for use in Emacs shell (request + by Rob Mayoff <mayoff@dqd.com>).
        • + +
        • correct a missing backslash in xterm-vt220 termcap.
        • + +
        • cleanup remaining quoted includes, preferring bracketed + form.
        • + +
        • minor configure-script macro updates from tin and + vile.
        • + +
        • add configure-script option for using utempter library, + adapted from Redhat 6.1 patch for XFree86 3.3.5
        • + +
        • resync with XFree86 3.9.17a: + +
            +
          • correction to QNX support (Frank Guangxin Liu)
          • + +
          • some cosmetic changes that did not correct any reported + problems.
          • +
          +
        • +
        + +

        Patch #122 - 1999/12/28 - + XFree86 3.9.16f

        + +
          +
        • move the suggested wheel-mouse button translations into + charproc.c to simplify customization. Correct some minor logic + errors in the support for buttons 4 and 5, used for wheel mice + (reported by Bram Moolenaar).
        • + +
        • implement metaSendsEscape resource, with + corresponding control sequence and menu entry. Like + eightBitInput, this causes xterm to send ESC prefixing + the given key, but applies to all keys and is independent of + the 8-bit/7-bit terminal setting. (requests by Alexander V + Lukyanov and Marc Feeley).
        • + +
        • correct potential indexing with negative subscript in + udk_lookup(), (reported by Ian Collier + <Ian.Collier@comlab.ox.ac.uk>).
        • + +
        • modify configure script that sets TERMINFO_DIR to use + ${prefix} rather than /usr if the --prefix option was specified + (request by Zdenek Sekera <zs@sgi.com>).
        • + +
        • modify checks for repeat-character control sequence to test + the character class against xterm's state table, rather than + the isprint() macro (patch by Alexander V Lukyanov).
        • + +
        • change several functions to macros to improve speed
        • + +
        • two corrections to simulation of bold font via + overstriking: + +
            +
          • use clipping to avoid leaving trash at end of the text, + and
          • + +
          • add brackets so wide-character logic does not + fall-through into the overstriking logic (reported by Marc + Feeley <feeley@IRO.UMontreal.CA>)
          • +
          +
        • + +
        • add several entries to termcap file to make it have the + same set of aliases as the terminfo file.
        • + +
        • scale the color values used for xterm-256color terminfo + entry to 0..1000, as expected by ncurses.
        • + +
        • change xterm-r6 terminfo definitions for F1-F4 to match + program.
        • + +
        • Add QNX/Neutrino support (Frank Guangxin Liu + <frank@ctcqnx4.ctc.cummins.com>)
        • +
        + +

        Patch #121 - 1999/11/14 - + XFree86 3.9.16c

        + +
          +
        • change label on "Sun/PC Keyboard" popup menu entry to + "VT220 Keyboard", since the checked state corresponds to VT220 + rather than Sun/PC.
        • + +
        • add configure test CF_UTMP_UT_XSTATUS to handle the + variants of utmp exit status (reports by Dave Ellement, Jeremie + Petit, Tomas Vanhala).
        • + +
        • amend treatment of ALT key (see patch + #94) so that if ALT is used as a modifier in key + translations, then no parameter will be sent in escape + sequences for Sun/PC function keys (request by Dr Werner + Fink).
        • + +
        • modify default for OPT_I18N_SUPPORT to assume that + XtSetLanguageProc() is available in X11R5. + +

          Caveat: XtSetLanguageProc() was added fairly + late in the X11R5 patches, and some vendors shipped buggy + versions of this function (request by Tomas Vanhala).

          +
        • + +
        • correct configure macro CF_SYSV_UTMP to test-link with + functions consistent with the header, e.g., getutent() for + utmp.h and getutxent() for utmpx.h (reported by Greg + Smith).
        • + +
        • modify terminfo entry for xterm-xfree86 to + reflect modifiers for shift and control (from a patch by + Alexander V Lukyanov).
        • + +
        • modify terminfo entry for xterm-sun to match + the function-key definitions in ncurses. The pageup/pagedown + and related function keys correspond to the Sun keyboard, which + does not necessarily correspond with X's notion of those + keys.
        • + +
        • modify treatment of XK_Delete keysym so it transmits + parameterized VT220-style <ESC>[3~ if + modifiers (shift, control alt) are given (request by Alexander + V Lukyanov).
        • + +
        • corrected misspelled resource name in command-line option + for HP function keys.
        • +
        + +

        Patch #120 - 1999/10/28 - + XFree86 3.9.16c

        + +
          +
        • refine the change to SGR_Background() in patch + #119, by not flushing the pending scrolling operation if the + background color is not actually changing. This combination + occurs when using color-ls to display a long listing, since + each line ends with an SGR0 which affects only the foreground + color. The unnecessary flushing made it noticeably slower + (reported by D Roland Walker <walker@pobox.com>).
        • + +
        • remove obsolete documentation about modifiers which can be + returned in mouse tracking mode, and modify logic to ignore + modifiers other than the existing ones, e.g., NumLock (prompted + by discussions with Christian Weisgerber and Brad Pepers + <brad@linuxcanada.com>).
        • + +
        • use free bit from obsolete shift-modifier coding of mouse + tracking button events to encode buttons 4 and 5, e.g., for a + wheel mouse (requests by Brad Pepers and Bram Moolenaar).
        • + +
        • correct a place where the ptyInitialErase logic did not set + the backarrowKey state, and modify it further to use tgetstr() + rather than parse the termcap data returned from tgetent() so + the ptyInitialErase logic will work when xterm is linked with a + terminfo library (based on a patch by Dr Werner Fink + <werner@suse.de>).
        • + +
        • fix definition of HAVE_UTMP_UT_HOST for ISC configuration + (patch by Michael Rohleder).
        • + +
        • improve configure script's utmp tests (based on reports by + Greg Smith for os390, and David Ellement for HPUX).
        • + +
        • modify sinstall.sh to use uid=0 rather than 'root' to + determine if the installer is privileged. This is needed on + some systems since more than one account may be privileged + (report by Greg Smith).
        • + +
        • add an application resource, messages (and a + corresponding -/+mesg option) which controls the initial + permission on the terminal: if messages is set to true (the + default), behavior is as without the patch; if it is set to + false (as per -mesg), the terminal is opened in mode 0600, thus + producing the effect of the mesg n command. This + is useful for users who want to redirect all their messages to + one particular xterm: it is more pleasant to do this with xterm + resources than with explicit calls to the mesg + program (patch, description by David Madore + <david.madore@ens.fr>).
        • +
        + +

        Patch #119 - 1999/10/16 - + XFree86 3.9.16c

        + +
          +
        • add responses (DA and DSR) for DEC locator mode
        • + +
        • add coding for ANSI color to DA response
        • + +
        • implement UTF-8 translation for Media Copy (print) + operations.
        • + +
        • implement vt320 control sequences for Print Composed Main + Display and for Print All Pages. The latter directs xterm to + print the current screen as well as the scrollback buffer.
        • + +
        • correct error in _GNU_SOURCE configure test, which left it + always defined.
        • + +
        • add more information, i.e., with strerror for some system + calls in the main program which may fail due to insufficient + permissions (prompted by a problem report for -C + by Jeremie Petit <Jeremie.Petit@digital.com>).
        • + +
        • add workaround for conflict between <X11/Xpoll.h> and + <sys/select.h> on AIX 4.3 (Richard Griswold + <griswold@acm.org>).
        • + +
        • add configure script test to resolve conflict between + between <X11/Xpoll.h> and <sys/select.h>
        • + +
        • modify translation of UTF-8 sequences to reject "overly + long" variations (patch by Markus Kuhn).
        • + +
        • remove utf8controls resource, since Markus' + change removes the corresponding logic.
        • + +
        • correct a case where colors were not rendered properly. + This happened when an application inserted several lines, then + changed colors. If this was done all in one write, then there + would be no intervening refresh, and the new color was applied + to the pending scrolling operation which was awaiting the next + refresh (reported by Stephane Chazelas + <Stephane_Chazelas@Raytheon.com>).
        • +
        + +

        Patch #118 - 1999/10/5 - + XFree86 3.9.16b

        + +
          +
        • refine configure test for utmp versus utmpx, to build on + HP-UX 10.x (reported by David Ellement).
        • + +
        • move the configure check for const after the + check for ANSI C compiler options, since those may be required + to make it work properly on HP-UX.
        • + +
        • add configure test for defining + _GNU_SOURCE
        • + +
        • correction to -hold option, ensure that if data is + already in the output buffer that it will be displayed before + closing the PTY.
        • + +
        • move the configure checks for setuid install of xterm into + a script to avoid installing it setuid'd to a non-root user + (reported by Adam Sulmicki <adam@cfar.umd.edu>).
        • + +
        • correct configure script's check for termcap.h to avoid + using ncurses' version of it on systems that have a working + tgetent() function. This is needed to make + resize work properly.
        • + +
        • fix some typography in ctlseqs.ms description of DEC + locator events (reported by Steve Wall).
        • +
        + +

        Patch #117 - 1999/9/29 - + XFree86 3.9.16b

        + +
          +
        • change order of tests in configure script for utmp and + utmpx to test utmpx first, to compile on Solaris (reported by + Leena Heino <liinu@uta.fi> and Patrik Hagglund + <patha@ida.liu.se>).
        • + +
        • add a configure test for utmp.ut_xtime, needed for SCO + Openserver, and for lastlog, needed for Redhat 6.0, to refine + the utmp/utmpx auto-configure.
        • + +
        • remove a spurious comma in an #undef (reported by David + Green <greendjf@cvhp152.marconicomms.com> and David + Ellement <ellement@sdd.hp.com> both on HP-UX, whose + compiler does care about syntax).
        • + +
        • change ifdef's using __CYGWIN32__ to __CYGWIN__ (reported + by Suhaib M. Siddiqi <Ssiddiqi@InspirePharm.Com>, who is + told that the next Cygnus release will drop that symbol in + their next release).
        • + +
        • minor cleanup of ifdef's for makeColorPair (patch by Steve + Wall).
        • + +
        • work around problem observed in XFree86 3.3.5 (patch by + Alexander V Lukyanov, Redhat #5419). From the problem report: + +
          +

          xterm consumes cpu when selecting text with mouse + (holding down left mouse button) and when a program working + under the xterm outputs something to stdout.

          + +

          Easy way to reproduce:
          + while :; do echo aaa; sleep 1; done
          + (while this runs, select text and hold down left mouse + button) watch cpu load.
          + release left mouse button - spinning stops.

          +
          +
        • +
        + +

        Patch #116 - 1999/9/25 - + XFree86 3.9.16a

        + +
          +
        • modify warning if change-ownership of PTY fails; some + configurations may not happen to have old-style pty's (reported + by Bob Maynard).
        • + +
        • improve check in configure script for group ownership of + installed xterm; some platforms use the -g option of ls to + toggle group off rather than on (reported by Greg Smith).
        • + +
        • minor improvement to toolbar geometry, to make it not + resizable. This still is not satisfactory (but is usable) since + the toolbar overlaps the xterm widget if the window is resized + to make it smaller. It appears that some work is needed for the + xterm widget's geometry management to make it function + properly.
        • + +
        • implement configure script tests for utmp, tty group.
        • + +
        • implement -hold option, allowing users to retain + the window after a shell has exited (this is recently an FAQ, + but prompted by a comment by Joachim Plaettner-Hochwarth + <plaettner@aem.umn.edu> in comp.unix.programmer, that the + IRIX winterm provides this option).
        • + +
        • add support for DEC Locator control sequences for xterm + (integrated patch by Steve Wall): +
          +                DECEFR, "Enable Filter Rectangle"
          +                DECELR, "Enable Locator Reports"
          +                DECSLE, "Select Locator Events"
          +                DECRQLP, "Request Locator Position"
          +
          + +

          This allows the xterm mouse to be used with applications + that use the DEC Locator sequences, such as VAX Tpu, or SMG$ + based applications.

          +
        • + +
        • improve print action (patch by Matthias Baake). From his + notes, + +
            +
          • Bug 1
            + Underlined text is preceded by ESC [0;2m . This should + be ESC [0;4m , ESC [2m doesn't seem to have + any effect. (print.c/send_SGR)
          • + +
          • Bug 2
            + The check for the last non-empty column (while (last > + 0) ... in print.c/printLine) omits the rightmost column of + the screen, the loop must start with last = + screen->max_col+1 instead of last = + screen->max_col.
          • + +
          • Bug 3
            + Any attributes of the first character (and of all + immediately following characters with the same attributes) + are ignored. The variable attr (print.c/printLine) should + be initialized with 0, not with *a & SGR_MASK.
          • +
          +
        • +
        + +

        Patch #115 - 1999/9/18 - + XFree86 3.9.16a

        + +
          +
        • integrated changes by Steve Wall to implement an 88-color + model for systems where 256-colors cannot be allocated.
        • + +
        • when 256-color configuration is compiled, colored bold and + underlining is not available; ifdef'd to avoid possible odd + effects in this case (reported by Steve Wall).
        • + +
        • add resource cacheDoublesize, to limit the caching + of font information for double-sized characters. This addresses + a problem reported by Aryeh Koenigsberg for X terminals with + limited font memory.
        • + +
        • modify treatment of line-drawing characters in UTF-8 mode + so that the Unicode values are used rather than the C0 codes + for storing the translated characters (request by Markus + Kuhn).
        • +
        + +

        Patch #114 - 1999/9/15 - + XFree86 3.9.16

        + +
          +
        • add configure script checks for Athena headers and + libraries under /usr/contrib to work on HPUX (reported by + several people: David Nixon <djn@csc.liv.ac.uk> Aryeh + Koenigsberg <aryeh.koenigsberg@telrad.co.il> Johannes + Mähner <johanm@camline.com> Andrew Gaylard + <andrew.gaylard@bsw.co.za>).
        • + +
        • add check to configure script if xterm is installed setgid + rather than setuid, since wtmp and utmp may be installed with + group-writable permissions other than root (based on Debian bug + report #7112 by Bo Branten <bosse@ing.umu.se>).
        • + +
        • rewrote logic that removes data from termcap entry, e.g., + for titeInhibit, to make it less likely to remove the wrong + data.
        • + +
        • correct logic which checks for missing characters used for + line drawing. The 0 character was tested unnecessarily, leading + to some inefficiency when rendering.
        • + +
        • change termcap capability which is used as input or output + of ptyInitialErase logic from kD to kb. + Christian Weisgerber <naddy@mips.rhein-neckar.de> pointed + out in effect that kD (in terminfo kdch1) + should correspond to the control sequence for dch1, + which deletes from the current position toward the right.
        • + +
        • check for failure to change ownership of the PTY device and + warn when xterm is running setuid'd to root. This was reported + to happen on the FreeBSD/NetBSD/OpenBSD systems as a result of + the chflags() call.
        • + +
        • add xterm-noapp terminfo entry to illustate a nominally + bash-compatible terminal description.
        • +
        + +

        Patch #113 - 1999/8/15 - + XFree86 3.9.15b

        + +

        Several fixes. The main one is a first draft of pulldown + menus. It's not complete (I have some minor/annoying geometry + problems to correct), but is usable. Once it's complete I plan to + add a menu to support additional selections that won't fit on the + current popup menus. Also, this fits into my longterm plan to + allow configuring with Motif libraries.

        + +
          +
        • correct error in input conversion for NRC mode (reported by + Stefan Traby <stefan@sime.com>).
        • + +
        • fix initialization of num_lock data in Misc struct (since + those fields of the reference widget aren't initialized), and + add logic to deal with XVision whose NumLock key does not + transmit but does alter keypad state.
        • + +
        • correct a missing return-value in get_pty(), for SCO
        • + +
        • add E2A fix for backspace (patch by Greg Smith), i.e.,
          + #define VAL_INITIAL_ERASE A2E(127)
        • + +
        • correct foreground color within cursor outline when the + window is unfocused (reported by Stephane Chazelas).
        • + +
        • corrected position of scrollbar set in ResizeScrollBar(), + which left it positioned incorrectly if the right scrollbar + were enabled from the popup menu but was not initially enabled. + +

          I have noticed some additional problems with + right-scrollbar on X11R5 which I will correct later.

          +
        • + +
        • integrate changes by Jean-Claude Michot for QNX from + XFree86 3.3.4c
        • + +
        • add resources menuBar/MenuBar, menuHeight/MenuHeight for + later use in toolbar geometry.
        • + +
        • add configure option --enable-toolbar
        • + +
        • add missing definition to make ziconbeep logic not + compile-in when configure script disables it.
        • + +
        • add configure-check for input-method support in X + libraries
        • +
        + +

        Patch #112 - 1999/7/17 - + XFree86 3.9Pw

        + +
          +
        • add null-pointer check to FlushLog(), fixes a core dump + when both -l and -lf options are used when xterm is configured + with wide-character support.
        • + +
        • remove "ISO" case for SD, which was due to a typographical + error in ECMA-48 (reported by Paul Williams + <paul@celigne.co.uk> for vttest).
        • + +
        • add "FILES" section to manpage.
        • + +
        • generate header file to initialize default resources for + colors 16-255.
        • + +
        • fixes for os390 (Greg Smith): + +
            +
          • add README.os390
          • + +
          • use the pty_search() function to find an available + pty/tty pair.
          • + +
          • move E2A() call out of getXtermCell() to SaveText() + function so it will be available in all + configurations.
          • +
          +
        • + +
        • patches by Todd Larason: + +
            +
          • enable SGR 48 5 in ISO color mode, not just 256 color + mode
          • + +
          • change configure's --disable-256-color option to + --enable-256-color, to match its effect
          • + +
          • fix OSC 4 xx ? (report ansi color) to report a string + which can actually be used to set the color back
          • + +
          • fix OSC 4 xx yy (change ansi color) to not allow + setting colors > 15 in 16 color mode
          • + +
          • simplify the COLOR_ settings a bit in ptyx.h, along + with setting NUM_ANSI_COLORS needed for #1 and #4 + above
          • + +
          • correct string-terminator code passed for reference to + OSC responses; when in 7-bit mode, only the final byte of + ST was seen.
          • + +
          • Allow multiple color #;name pairs in OSC 4, and + document changes to match.
          • +
          +
        • +
        + +

        Patch #111 - 1999/7/10 - + XFree86 3.9Pw

        + +
          +
        • add control sequences for specifying the RGB value of the + ANSI colors, and for configuring with 256 colors (patch by Todd + Larason <jtl@molehill.org>). I made the default + configuration to 16-colors, because xterm uses the default + color map (which has only 256 colors).
        • + +
        • correct an error in DCS $ q m reporting for colors 8-15 + (Todd Larason).
        • + +
        • add test/demo script for double size characters. Used this + to test/correct display of double size characters that should + wrap, underlined double size characters.
        • + +
        • increased cache size for double size fonts to 8, to allow + for both normal and bold fonts (discussion with Aryeh + Koenigsberg <aryeh.koenigsberg@telrad.co.il>).
        • + +
        • add fixes for port to OS390 aka MVS (integrated patch from + Greg Smith <rys@epaibm.rtpnc.epa.gov>). OS390 uses EBCDIC + rather than ASCII.
        • + +
        • correct an off-by-one in binary search limits in + keysym2ucs.c (Markus Kuhn).
        • + +
        • implement logging for UTF-8 mode. The output is written in + UTF-8 form.
        • +
        + +

        Patch #110 - 1999/6/29 - + XFree86 3.9Pu

        + +
          +
        • If colorMode is enabled by default, compile-in default + resources to match the colors listed in XTerm-col.ad (this + should fix a longstanding FAQ).
        • + +
        • added new OSC 3 ; PROPNAME=VALUE ST + escape sequence to set an arbitrary X property on the top level + xterm X11 window. Omit "=VALUE" to delete the X property (patch + by Greg Badros <gjb@cs.washington.edu>).
        • + +
        • change internal flag used for utf8controls + resource so we allow 31-bit range of characters (suggested by + Thomas Wolff).
        • + +
        • add check for 16-bit characters in OSC strings, change them + to '?' (reported by Thomas Wolff).
        • + +
        • modify logic of same_font_name() to avoid trying to + interpret both parameters as wildcard patterns. That does not + (cannot) work, and in some instances the font server will + return unresolved wildcards for the normal or bold fontnames, + making them match inadvertently, triggering the fallback + overstrike logic (reported by Tim Adye).
        • +
        + +

        Patch #109 - 1999/6/23 - + XFree86 3.9Pt

        + +
          +
        • correct range-check from patch #108, which resulted in not + being able to select from the scrollback buffer (reported by + Tim Adye <T.J.Adye@rl.ac.uk>)
        • + +
        • correct "no available ptys" problem with Cygwin B20.1 + (patch by Tim Adye).
        • + +
        • modified install-ti rule in Makefile.in to allow override + of the terminfo directory when doing a "make install", i.e., by + assigning to TERMINFO_DIR (request by Zdenek Sekera + <zs@sgi.com>).
        • + +
        • added install-full rule to Makefile.in
        • + +
        • resync mkdirs.sh and install.sh scripts against current + autoconf
        • + +
        • implement $(DESTDIR) in Makefile.in, making it simple to + install xterm and associated files into a directory just for + packaging a binary release (suggested by CaT + <cat@zip.com.au>).
        • + +
        • change IChar type to unsigned, rather than unsigned short, + making room for a flag to keep with 16-bit characters to + prevent them from being interpreted as C0 or C1 controls + (reported by Thomas Wolff).
        • + +
        • correct a typo from patch #107, incorrect array name, in + the filterUTF8 function (patch by Bruno Haible + <haible@ilog.fr>)
        • + +
        • add utf8controls resource to specify whether xterm + should interpret 16-bit characters unpacked from UTF-8 form as + control characters if they happen to fall into that range. This + behavior is left unspecified by the Unicode standard (request + by Thomas Wolff).
        • + +
        • modify handling of OSC to recover if application sends + 16-bit characters with codes above 255. We cannot display them + as is, but translate out-of-range characters to a '?' (reported + by Thomas Wolff).
        • +
        + +

        Patch #108 - 1999/6/19 - + XFree86 3.9Ps

        + +
          +
        • add a range-check to LastTextCol(), to guard against + indexing before the beginning of the scrollback buffer. This + appears to happen with certain fonts under X11R5 (reported by + Stephane Chazelas <Stephane_Chazelas@Raytheon.com>).
        • + +
        • implement resource boldMode, to allow disabling + the simulation of bold fonts when the bold and normal fonts are + not different (requested by Will Day + <willday@rom.oit.gatech.edu>).
        • + +
        • change the atom "UTF-8" to "UTF8_STRING", and fixes a few + bugs in the UTF-8 selection (patch by Juliusz Chroboczek).
        • + +
        • correct logic of binary-search in keysym2ucs.c (patch by + Markus Kuhn).
        • + +
        • add special interpretation of keysym codes above 0x1000000 + as the corresponding UCS value plus 0x1000000 (patch by Markus + Kuhn).
        • +
        + +

        Patch #107 - 1999/6/12 - + XFree86 3.9Pq

        + +
          +
        • Two changes from Stephen P Wall. From his description: + +
          +

          The first change is simple - I added ESC[3J to erase the + stored lines above the screen. That's what the changes to + util.c and ctlseqs.ms are.

          + +

          The second change is to get the blinking cursor working. + I took out the cursorBlinkTime resource, and put in + cursorBlink (Boolean), cursorOnTime (time cursor is on in + msecs) and cursorOffTime, and added a cursorblink item to + the vtMenu to enable/disable it.

          +
          +
        • + +
        • improve selection (integrated patch by Juliusz Chroboczek). + From his description: + +
          +

          With this patch, selection conversion works + properly:

          +
          +        ISO 8859-1 xterm -> ISO 8859-1 xterm (transferred as STRING);
          +        ISO 8859-1 xterm -> UTF-8 xterm (transferred as STRING);
          +        UTF-8 xterm -> ISO 8859-1 xterm (transferred as STRING);
          +        UTF-8 xterm -> UTF-8 xterm (transferred as UTF-8).
          +
          + +

          It will not work properly if one xterm is in, say, ISO + 8859-2. Actually, for this case xterm breaks the ICCCM + routinely (sending ISO 8859-2 data as STRING), so I + wouldn't worry too much about it. I have not changed the + behaviour in eight-bit mode in any way.

          +
          +
        • +
        + +

        Patch #106 - 1999/6/9 - + XFree86 3.9Pq

        + +
          +
        • remove duplicate fix for OpenBSD in resize.c
        • + +
        • correct logic in ScreenWrite, which did not reset the high + bytes of 16-bit characters when overwriting them with a 8-bit + character string (reported by Thomas Wolff).
        • + +
        • provide limited support for input of UTF-8 16-bit data by a + lookup table (integrated patch by Markus Kuhn).
        • + +
        • correct check in non_blank_line to ensure we're in + wide-character mode before looking at the high bytes, for + InsertChar.
        • +
        + +

        Patch #105 - 1999/6/5 - + XFree86 3.9Pp

        + +
          +
        • implement new resource trimSelection, which allows + xterm to trim trailing blanks from selected lines. This does + not affect the highlighting. (reported by several people using + mutt, including Hans Morten Kind <edphk@uib.no>, + Jeremy <jeremy@exit109.com> and (Michael Fuller + <msf@mds.rmit.edu.au>).
        • + +
        • include term.h in resize for OpenBSD (patch by Matthieu + Herrb).
        • + +
        • correct logic for UTF-8 in functions that hide and show the + cursor; it was displaying a space whenever the low byte of the + character at the cursor position was zero (reported by Thomas + Wolff <Thomas.Wolff@icn.siemens.de>).
        • +
        + +

        Patch #104 - 1999/5/30 - + XFree86 3.9Pn

        + +

        This is a resync patch against XFree86 3.9Pn, reflecting + changes which were submitted by Branden Robinson, who worked with + Wichert Akkerman <wichert@cs.leidenuniv.nl> to set up + ifdef's to handle GNU libc 2.1, and use getpt() which lets xterm + avoid having to know the actual PTY name.

        + +

        I have also added a few fixes for signed/unsigned mismatches, + and corrected a problem in the configure script (the UTF-8 code + was always configured since the Imakefile defines this).

        + +

        Patch #103 - 1999/5/14 - + XFree86 3.9Pm

        + +
          +
        • correct selection logic: I omitted an offset that accounts + for the distance into the scrollback buffer when rewriting this + for patch #101. Also fixed a similar problem for selecting + double size characters from the scrollback buffer (first was + reported by D Roland Walker <walker@pobox.com>).
        • + +
        • improved support for Unix98 PTY's, using patch in Debian + bug report #35650, by J.H.M. Dassen + <jdassen@wi.leidenuniv.nl>. From the patch description: + +
          +
            +
          • No longer links xterm against libutil on a glibc2.1 + system. libutil is a compatibility library and should + only be used when necessary. Rather than having get_pty() + use openpty() from this compatibility library, use the + real UNIX98 pty support in get_pty() (open()ing the + master pty, through getpt() if available (glibc + extension)). Use openpty() only under glibc2.0.
          • + +
          • GNU libc2 is not Linux-specific; already it runs on + the Hurd. It provides the UNIX98 pty functions (plus the + getpt() extension), regardless of the underlying OS. + Changed two constructs to look for GNU libc2 only, not + GNU libc2 on Linux.
          • +
          +
          +
        • + +
        • improve font configuration, by checking if the user's + resource settings for normal and bold fonts give the same font + sizes (fixes problem reported by Peter Waltenberg + <peterw@dascom.com>).
        • +
        + +

        Patch #102 - 1999/5/12 - + XFree86 3.9Pm

        + +
          +
        • revert change to openpty call in patch #101; this causes + xterm to fail on DEC-Alpha OSF/1 4.0B (reported by H Merijn + Brand).
        • + +
        • modify print.c to move include of stdio.h after the + autoconf'd xtermcfg.h since HP's ANSI C compiler otherwise sees + inconsistent prototype for getopt, probably due to problem with + const (reported by H Merijn Brand).
        • +
        + +

        Patch #101 - 1999/5/10 - + XFree86 3.9Pm

        + +
          +
        • moved includes and definitions for 'select' from data.h to + xterm.h to fix problem introduced by prototype for getPtyData, + part of UTF-8 changes (reported by Jens Schleusener + <Jens.Schleusener@dlr.de>)
        • + +
        • added "Meta <Btn2Down>:clear-saved-lines()" default + translation (patch by H Merijn Brand)
        • + +
        • fixes to configure script and ifdef's in main.c to build on + a HP9000/D390 (hppa-2.0w) running HP-UX 11.00 (64 bit) with + egcs 1.1.2 and HP's ANSI C compiler (patch by H Merijn Brand + <PROCURA_BV@CompuServe.com>)
        • + +
        • add more parentheses in ifdef's (patch by Bob + Maynard).
        • + +
        • eliminate conflicting definitions for USE_TERMINFO in + resize.c (reported by Jeremy Buhler).
        • + +
        • change openpty call to pass NULL rather than ttydev + parameter, since that was used only to estimate the length of + the corresponding data, and may not really be long enough + (reported by Andreas Jaeger)
        • + +
        • update description in xterm manpage for character class + table, which said it handles only 7-bit codes.
        • + +
        • correct a typo in ScrnDeleteChar() which made it not clear + the high byte of wide-character data.
        • + +
        • add logic to convert selection to UTF-8 form when + appropriate. This makes select/paste "work", but further work + is needed to make UTF-8 recognized as a locale in Xlib.
        • + +
        • correct right-limit check when selecting double-width + characters.
        • + +
        • change default answerback response to an empty string.
        • +
        + +

        Patch #100 - 1999/5/3 - + XFree86 3.9Pl

        + +
          +
        • Correct a typo in the default resource value for + backarrowKeyIsErase: it was always true (reported by Bram + Moolenaar).
        • + +
        • improve configure script's test if the installed xterm is + setuid, in case that is a symbolic link.
        • + +
        • correct "install-ti" rule in Makefile.in, by not setting a + blank $TERMINFO value. That is interpreted as "." by ncurses' + tic.
        • +
        + +

        Patch #99 - 1999/5/2 - + XFree86 3.9Pk

        + +
          +
        • correct logic that computes num_ptrs count of the number of + indices into the screen buffer. This is the maximum of the + colors and character-set indices; was incorrect in patch + #97.
        • + +
        • correct argument type for sigsetjmp, incidental change in + patch #96's Unix88 PTY patch (reported by Bram Moolenaar).
        • + +
        • correct description of secondary DA in ctlseqs.ms (reported + by Bram Moolenaar).
        • + +
        • decouple the backarrowKey and ptyInitialErase resources by + adding a new resource backarrowKeyIsErase, to accommodate + people using applications which have hardcoded tests for + characters 8 and 127 rather than relying on the stty + settings.
        • + +
        • modify the UTF-8 decoder so that all possible illegal UTF-8 + sequences are properly represented by U+FFFD. This should be + very helpful for developers of code that output UTF-8 strings + for debugging. See the file utf-8-test.txt in + http://www.cl.cam.ac.uk/~mgk25/download/ucs-fonts.tar.gz for a + demonstration text that contains numerous illegal UTF-8 values. + (patch by Markus Kuhn).
        • + +
        • correct a place in ScrnRefresh where I was filling the high + byte of a wide character with a space rather than a null + (reported by Markus Kuhn).
        • +
        + +

        Patch #98 - 1999/4/26 - + XFree86 3.9Pk

        + +
          +
        • correct data manipulation in unparseputc(), broken for + little-endian machines by patch #97's UTF-8 changes. This meant + that keyboard input on SunOS did not work, though Linux i386 + was fine.
        • + +
        • modify initialization for backarrowKey and logic for + initial-erase to prevent the initial-erase from overriding an + explicitly set backarrowKey resource (reported by Vikas + Agnihotri).
        • + +
        • add a missing null-pointer check in ScrnRefresh, for the + wide-characters configuration.
        • +
        + +

        Patch #97 - 1999/4/25 - + XFree86 3.9Pk

        + +
          +
        • add configure script test for -lutil, needed for openpty + call when configuring xterm for Glibc-2.1 and Unix98 PTY's + (first reported by Martin Lorentz" + <m.lorentz@w12.link-goe.de>).
        • + +
        • completely parenthesize ifdef expressions for Glibc + (suggested by Bob Maynard).
        • + +
        • add initial-erase options (-ie, +ie) to help message + (reported by Vikas Agnihotri).
        • + +
        • remove duplicate definition of USE_USG_PTYS (reported by + Jeremy Buhler).
        • + +
        • change termcap kD and terminfo kdch1 to a + DEL (\177). I overlooked this when separating the styles of + keyboard with the sunKeyboard resources in patch #94, + so that it normally matches the value of the stty erase + character: + +
            +
          • Reported by Jae Gangemi + <jgangemi@ccf.rutgers.edu>, this caused emacs to not + process the DEL properly, combining it with succeeding + characters.
          • + +
          • This does not appear to be related to a problem which I + have found with screen, which translates the stty + erase into the termcap kD or terminfo + kdch1 value (depending on how it is linked) if the + $TERMCAP variable is set when screen is + invoked.
          • +
          +
        • + +
        • add command-line options for enabling UTF-8 mode: -u8 and + +u8. The more obvious -utf8 and +utf8 would conflict with + xterm's -ut and +ut (utmp) options. The UTF-8 changes were + requested by Markus Kuhn <Markus.Kuhn@cl.cam.ac.uk>. This + patch does not complete UTF-8 implementation, but makes it + usable, i.e., display and refresh work, and I am able to + display the test cases which Markus provides. More work is + needed to complete this feature: + +
            +
          • the control sequences for switching in/out of UTF-8 + mode are partly implemented (don't use them). Similarly, + the switching between vt100 and tek4014 emulations when + UTF-8 mode is enabled will not work properly. + +

            You must use the -u8 command line option to use this + feature, as well as compile with the OPT_WIDE_CHARS + definition.

            +
          • + +
          • cut/paste only copies 8-bit characters.
          • + +
          • logging is disabled in the wide-character + configuration
          • + +
          • printing only writes 8-bit characters.
          • + +
          • input only does 8-bit characters. This is the area that + I know least about.
          • +
          +
        • +
        + +

        Patch #96 - 1999/4/19 - + XFree86 3.9Pj

        + +
          +
        • modify Makefile.in to work with configure script's --srcdir + option. (patch by Jeremy Buhler + <jbuhler@cs.washington.edu>)
        • + +
        • add checks for 'echo -n' equivalent for 8colors.sh and + 16colors.sh scripts (reported by Vikas Agnihotri).
        • + +
        • improve logic that looks for bold fonts to allow for + wildcards in the specification for normal fonts, and to ensure + that if a bold font is specified as normal, that xterm will + simulate a bold version of that using a one-pixel offset + overstrike (reported by Henrik Harmsen + <harmsen@erv.ericsson.se>).
        • + +
        • correct horizontal spacing of double width line-drawing + characters that xterm simulates.
        • + +
        • improve support for Unix98 PTY's, using patch in Debian bug + report #35650, by Topi Miettinen + <Topi.Miettinen@medialab.sonera.fi>. Andreas Jaeger says + this also corrects a permissions problem reported by + cat@zip.net.au
        • + +
        • modify initial-erase logic to ensure that + ttyModes resource overrides it.
        • +
        + +

        Patch #95 - 1999/4/5 - + XFree86 3.9Ph

        + +
          +
        • modify primary DA response to allow a '1' parameter.
        • + +
        • add printer and national replacement character sets to + VT220 primary DA response.
        • + +
        • document primary and secondary DA responses in + ctlseqs.ms
        • + +
        • use the patch number (e.g., 95) in the secondary DA + response, providing user applications a means of determining + the version of xterm for feature comparison (request by Bram + Moolenaar).
        • + +
        • make xterm respond to secondary DA when the decTerminalID + is set for VT100.
        • + +
        • limit user-defined keys (DECUDK) to VT220-style keyboard + when sunKeyBoard resource is true.
        • + +
        • modify ifdef's for Linux-2.2.x with Glibc-2.1 to work with + Glibc-2.1 and no Unix98 PTY support (patch from Andreas Jaeger + <aj@arthur.rhein-neckar.de>)
        • + +
        • add optional feature (resource and command-line options) to + make xterm use the PTY's sense of erase character on startup, + rather than requiring it to be \177, or set the PTY's erase + character to match xterm's configuration. Note that while + $TERMCAP is modified to reflect the actual configuration, the + terminfo kdch1 string is not (request by Dirk H Hohndel + <hohndel@suse.de>)
        • + +
        • improve scripts in vttests to work with newer shells that + do not use 'echo -n'.
        • + +
        • add fonts.sh example script
        • + +
        • correct inequality in handling of "#1" font + specification.
        • + +
        • correct call to XGetWMNormalHints() used for computing + maximum screen size; the size hints may not have been set.
        • + +
        • begin implementation of support for wide-characters + (configure option --enable-wide-chars defines OPT_WIDE_CHARS, + invoke xterm with -wc option to activate this feature). This + patch optionally widens internal data structures, invokes the + 16-bit text output rather than the 8-bit version and adds some + tables.
        • +
        + +

        Patch #94 - 1999/3/27 - + XFree86 3.9Pf

        + +
          +
        • further fixes for terminfo: ka1, ka3, etc., differ between + the default xterm-xfree86 and xterm-vt220 entries.
        • + +
        • change default (with sunKeyboard resource false) behavior + of the editing keypad "Delete" to send a 127, like xterm-r6. + The VT220-style <ESC>[3~ is sent when + sunKeyboard is true (reported by Tomas Vanhala).
        • + +
        • add parameters to function keys to indicate if shift, + control or alt are set. The codes are based on a description of + a DEC VT510 with a PC keyboard, from Jeffrey Altman + <jaltman@watsun.cc.columbia.edu>.
        • + +
        • add control sequence 1035, set-num-lock action and num-lock + menu entry to control the use of the NumLock and Alt keys for + the Sun/PC and VT220 keyboard extensions.
        • + +
        • implement DECSET/DECRST numeric keypad (DECNKM) mode.
        • + +
        • modify terminfo and termcap to use recommended "X Window" + or "X11" names rather than "X Windows" (reported by Tomas + Vanhala).
        • + +
        • suppress translation of shifted keypad "+" when sunKeyboard + is true.
        • + +
        • workaround unexpected behavior (perhaps bug) in + XmbLookupString, which returns trash in the string buffer for + numlock and control-key combined with keypad-keys.
        • + +
        • modify ScrollBarReverseVideo() to keep scrollbar border + visible when reverse video is toggled.
        • + +
        • correct missing case for parameter 17 (set highlight color) + in dynamic colors control sequences.
        • + +
        • extend dynamic colors control sequences to allow users to + determine the colors and font which are currently active.
        • + +
        • minor tweak to OSC responses, to use BEL if the application + used that to end the request, rather than ST. This works better + with shell scripts, which may not handle an + <ESC>backslash very well.
        • + +
        • separate menu settings for reverse video from that done + under program control.
        • + +
        • corrected ifdef's for menus, which did not allow tek4014 to + be suppressed properly (reported by Clint Olsen).
        • + +
        • changes for Linux-2.2.x with GLibc-2.1 and /dev/ptmx + support (integrated patch from Pavel Roskin): + +
            +
          • main.c and resize.c were using different rules to + determine whether ATT should be defined (actually + USE_USG_PTYS is more apt).
          • + +
          • copy definitions from main.c to resize.c to prevent + sys/stream.h and sys/ptem.h from inclusion when SYSV is not + defined
          • + +
          • define CNUL if not already defined like other + variables.
          • + +
          • /dev/tty does exist in Linux, but it doesn't mean, it + should be used. Therefore EACCES is now an acceptable + result.
          • + +
          • ifdef'd several calls such as ioctl (ptyfd, + I_PUSH, "ptem") to build on Linux (I_PUSH is not + defined when sys/stropts.h is not included).
          • +
          +
        • + +
        • initialize second "ltc" variable in main.c (reported by + David Dawes).
        • + +
        • provide definition for USE_USG_PTYS in screen.c
        • + +
        • add resource-files to install rule in standalone + Makefile.in
        • + +
        • add sample scripts to illustrate titlebar controls, + resizing and colors.
        • +
        + +

        Patch #93 - 1999/3/14 - + XFree86 3.9Pd

        + +

        Here are several fixes and minor enhancements. The chief ones + are the fixes for NumLock mode and reverse video, since we had + become used to working around the problems.

        + +
          +
        • remove kfnd/kll/kslt strings from terminfo, because curses + applications do not necessarily return khome/kend pairs + (reported by Vikas Agnihotri).
        • + +
        • implement NumLock resource which overrides the keyboard + tables for the special case of keypad keys. This is a problem + introduced in xterm by X11R6 changes, i.e., an ambiguity which + in effect discarded vt100 keypad support.
        • + +
        • modify Sun/PC keyboard mode to extend this (emulation of + DEC vt100 keypad) to the remainder of the numeric keypad. Now, + the default operating mode of xterm uses the keyboard tables + as-is (except if the NumLock mode overrides), but provides good + vt100 keypad compatibility if the Sun/PC keyboard menu item is + checked.
        • + +
        • separate command-line settings for reverse video from that + done under program control. This is a problem which was + introduced by X11R6. Though correct, most users are + confused by allowing the reset command to undo the effect of + the command-line -rv option.
        • + +
        • add description of function keys, keypad and cursor keys to + ctlseqs.ms
        • + +
        • add terminfo entries for xterm-vt52, xterm-sun and + xterm-hp
        • + +
        • correct typo (missing case value) for DECSET 35, + enable/disable shifted keypad action and a few compiler + warnings (reported by Zdenek Sekera <zs@sgi.com>).
        • + +
        • correct reporting of color values 8-15 in DECRQSS (reported + by Vikas Agnihotri).
        • + +
        • modify parsing of ttyModes resource to recognize "^-" as + "undef" (requested by Tomas Vanhala).
        • + +
        • integrate/extend changes to add iconify/maximize actions + (from Edward S. Arthur <eda@ultranet.com>).
        • + +
        • add control sequences for maximizing/restoring window, and + for reporting maximum screen size.
        • + +
        • add 'interpret' action, to support local function-key + interpretation. Used properly, this makes most of the + specialized actions of xterm redundant.
        • + +
        • add control sequence private modes 1051, 1052 and 1052, for + setting the Sun and HP function key modes, and for setting the + Sun/PC keyboard mode.
        • + +
        • add configure option --disable-maximize
        • + +
        • add configure option --disable-num-lcok
        • + +
        • extend descriptions of configure script options in + INSTALL.
        • +
        + +

        Patch #92 - 1999/2/5 - + XFree86 3.9Nz

        + +
          +
        • increase buffer size for tgetent (i.e., termcap) to 1500. + This fixes a problem where screen is built using + ncurses or GNU termcap and xterm is built using the + standard termcap interface. The former does not limit the + termcap size, while the latter is assumed to be no longer than + 1023 characters. The screen program's termcap entry is + about 1200 characters long.
        • + +
        • change update_menu_item() to a function, to simplify + debugging. This also reduces the executable by 4Kb.
        • + +
        • add control sequences for DECSET 30, 1010, 1011 like rxvt + (enable or disable some features that were only settable via + resources or command line arguments).
        • + +
        • add control sequence for DECSET 35, which enables/disables + the shifted keypad functions.
        • + +
        • add support for switching font sizes, by stepping through + the font menu using shifted keypad plus and minus.
        • + +
        • correct missing initialization of tekInhibit and tekSmall + resources.
        • + +
        • correct ifdef's in charproc.c for XtNgeometry and + XtCGeometry (reported by Bram Moolenaar).
        • +
        + +

        Patch #91 - 1999/1/21 - + XFree86 3.9Nw

        + +
          +
        • Implement logic to translate input characters which are + mapped when in vt220 National Replacement Character mode + (requested by Tomas Vanhala).
        • + +
        • Resync configure scripts with my patches to autoconf + 2.13
        • + +
        • Change order of -lXmu and -lXext to accommodate cygwin32 + (reported by Vikas Agnihotri).
        • + +
        • Add "-ti" option to set terminal emulation level from + command line rather than via resource.
        • + +
        • Simplify some of the preprocessor logic using #elif.
        • +
        + +

        Patch #90 - 1998/12/13 - + XFree86 3.9Nq

        + +

        This implements several small fixes and enhancements. The + chief one implements fallback support for line drawing characters + with fonts that do not include those characters. But I + implemented that last.

        + +
          +
        • If any of the glyphs in positions 0-31 (used by xterm to + implement the VT100 alternate character set) are zero-sized + (i.e., missing), xterm will reserve a normal space for the + glyph when drawing. I implemented a simple stroke-drawing + function to draw the line-drawing characters and a couple of + the other (simpler) characters such as diamond. (This was + suggested by Vikas Agnihotri).
        • + +
        • Modify the computation of doublesize characters to work + around font servers which shift the scaled characters up/down + or do not give the correct width.
        • + +
        • Add popup menu item and corresponding resource settings to + disable the font-scaling logic for doublesize characters to + work around (older) font servers which simply do not draw the + fonts scaled to the size that they said they would. I see this + problem on a SunOS system running X11R5; the X11R6 servers seem + well behaved.
        • + +
        • Implement new escape sequence, private mode 1049, which + combines the switch to/from alternate screen mode with screen + clearing and cursor save/restore. Unlike the existing escape + sequence, this clears the alternate screen when switching to it + rather than when switching to the normal screen, thus retaining + the alternate screen contents for select/paste operations. + +

          When I implemented the popup menu entry to toggle between + the normal and alternate screens, I considered only pasting + from the normal screen to the alternate; this improvement + allows either direction.

          +
        • + +
        • Changed the termcap and terminfo for xterm-xfree86 and + xterm-8bit to use the new 1049 private mode.
        • + +
        • Modify the logic which switches between normal and + alternate screens so that the save/restore cursor operations + apply only to the current screen. That means that applications + which use the terminfo smcur/rmcur or termcap ti/te + capabilities will restore the cursor to the original position + on the normal screen rather than to the most recent place where + a save-cursor operation was performed. + +

          I note that a real VT100 terminal would not behave in this + way, but it is a moot point since the VT100 does not + implement alternate screen, and therefore the save/restore + cursor sequence would not be used in this context. I reviewed + the logic which switches between normal and alternate screens + based on some recent newsgroup postings as well as a proposed + patch in the Debian group which attempts to do this (the + patch has a bug, however, so I did not use it).

          +
        • + +
        • Add popup menu entry for toggling the titeInhibit + resource.
        • + +
        • Add new resource answerbackString, which overrides the + default "xterm" returned by xterm when responding to an ENQ + (control/E) character (request by Rajesh Vaidheeswarran + <rv@fore.com>).
        • + +
        • Add new resource keyboardDialect for setting the NRC + display character set (request by Tomas Vanhala, who notes that + I should add logic to translate the keyboard as well).
        • + +
        • Add new command-line option and corresponding resources for + making xterm generate escape sequences compatible with HP + terminals. Like the existing Sun escape sequences, this is + available as a popup menu item. It is enabled by the configure + script with the option --enable-hp-fkeys (requested by Toni + Mueller <sales@oeko.net>).
        • + +
        • Add configure script option --disable-boxchars to disable + the fallback support for line drawing characters.
        • + +
        • Fix ifdef's for configure script --disable-ansi-color, and + reviewed all configure options to ensure that all can be + enabled/disabled appropriately.
        • + +
        • Update config.guess and config.sub, from Lynx.
        • +
        + +

        Patch #89 - 1998/11/20 - + XFree86 3.9Nm

        + +

        This patch completes the implementation of double-sized + character support for the VT100 emulation, and fixes a few minor + bugs:

        + +
          +
        • corrected the cursor position in HideCursor, which did not + multiply the column by two when in doublesize mode. This bug, + which did not appear in normal use, dates back to my original + changes to partly implement + double-sized characters. I noticed it when cat'ing a typescript + from vttest's double-sized character test.
        • + +
        • ensure that the current line is repainted when switching + between single and double width characters.
        • + +
        • reduce the number of bits used for double-sized character + coding from 3 to 2, to make more room for soft-font codes.
        • + +
        • copy newer ifdef's from the XFree86 3.3.3 release's main.c, + which address details of glibc and powerpc.
        • + +
        • moved definition of DECL_ERRNO in xterm.h to match XFree86 + 3.3.3
        • + +
        • modify resize to remove the ifdef on SVr4 that + suppressed printing the script for $LINES and $COLUMNS. + Solaris' resize utility does this; suppressing the behavior is + unnecessary.
        • +
        + +

        I tested the double-sized characters using vttest and the + xfsft patch. These fonts worked reasonably well:

        +
        +        -bitstream-courier-medium-r-normal--0-0-0-0-m-0-iso8859-1
        +        9x15
        +
        + +

        The iso8859 font does not include box characters, of course, + but looks good.

        + +

        Patch #88 - 1998/10/31 - + XFree86 3.9Nk and 3.3.2h

        + +

        This refines my #85 patch by checking for a case where the + font server returns a bold font that does not quite correspond to + the normal font. When I asked for a bold version of the 6x12 + font, the font server returned a near equivalent where the ascent + and descent values did not match, causing xterm to leave lines + across the display. This patch makes xterm reject that type of + mismatch, falling back to the old font behavior.

        + +

        Patch #87 - 1998/10/21 - + XFree86 3.9Nj and 3.3.2f

        + +

        This corrects a problem reported by Stefan Dalibor. My table + entries for the printerExtent and + printerFormFeed resources used the wrong types for + sizeof, causing the printer to not work properly on some + platforms because the printAttributes resource was + overwritten (e.g., Digital Unix with DEC Alpha).

        + +

        I reviewed all of the resource table entries and fixed a + potential problem with resizeGravity, which was typed as + int rather than XtGravity.

        + +

        Patch #86 - 1998/10/14 - + XFree86 3.9Nj and 3.3.2e

        + +

        A small fix: when switching to/from the continuous mouse + reporting mode, the event mask was incorrect if xterm was built + under X11R5 because the original data was saved under an ifdef + for active-icon.

        + +

        Patch #85 - 1998/10/12 - + XFree86 3.9Nj and 3.3.2e

        + +

        Some cleanup (I noticed the pixel droppings a few months ago + after getting a new 17" monitor):

        + +
          +
        • split-out the functions that load/reload fonts for xterm as + new file fontutils.c to extend them to support automatic + loading of bold font corresponding to the normal font. Adapted + logic from EMU 1.3 for this purpose. This fixes most + occurrences of pixel droppings from bold characters.
        • + +
        • modified by renaming variables and adding casts to permit + compile with g++.
        • + +
        • modify headers so they can all be compiled without order + dependencies, and use bracketed rather than quoting includes to + allow compile from separate directory.
        • + +
        • renamed xtermm terminfo entry to xterm-mono, to avoid + conflict with Solaris entry now in ncurses.
        • +
        + +

        Patch #84 - 1998/10/9 - + XFree86 3.9Ni and 3.3.2e

        + +

        Several small fixes and enhancements, including a patch from + Bjorn Helgaas:

        + +
          +
        • correct initialization of TERMCAP environment variable, + which was frequently set to garbage on non-Linux systems + because "termcap" and "newtc" contained random data from the + stack.
        • + +
        • remove the LINEWRAPPED attribute from lines as they are + cleared. Previously, the attribute was set but never + cleared.
        • + +
        • make word and line selections work even when lines are + wrapped by xterm. Previously, selections were limited to one + screen line.
        • +
        + +

        as well as

        + +
          +
        • modify logic for line-wrapping to reset the associated flag + if the application deletes a character. This fixes a problem + reported by Bjorn Helgaas where word/line selection would still + wrap even after deleting characters from the first line.
        • + +
        • add kll/kH capabilities to xterm-xfree86 entries in termcap + and terminfo (request by Michael Schroeder).
        • + +
        • shorten descriptions in termcap to make resolved entries + all shorter than 1023 character limit.
        • + +
        • use DECSTR control sequence to shorten initialization and + reset strings in xterm-xfree86 termcap and terminfo.
        • + +
        • use rmul/smul and rmir/smir in xterm-r5 terminfo to match + termcap.
        • + +
        • correct typos in initialization and reset strings in + xterm-r5 termcap and terminfo.
        • + +
        • disable special translations of key symbols (the backarrow + key, the editing keypad and the keypad "+") when a modifier + other than shift, control or numlock is used. This makes xterm + handle the meta key as expected by people using emacs (reported + by Pete Harlan <harlan@pointofchoice.com> in + linux.debian.user newsgroup).
        • +
        + +

        Resync #83 - 1998/10/7 - + XFree86 3.3.2e

        + +

        Merge changes through patch #83 with the 3.3.2e version.

        + +

        This follows a change from XFree86 CVS which adds checks for + non-null return from malloc (patch by Matthieu Herrb).

        + +

        Patch #83 - 1998/8/25 - + XFree86 3.9Nb

        + +

        Several small fixes and enhancements:

        + +
          +
        • add configure test to infer if xterm should be installed + setuid based on previously installed xterm (reported by Stephen + Marley and Stefan Dalibor).
        • + +
        • implement quasi-continuous mouse reporting (integrated + patch by Jason Bacon).
        • + +
        • correct control sequences transmitted by function keys F1 + to F4 when sunFunctionKeys resource is true (it was still using + the VT100 control sequences).
        • + +
        • modify handling of backarrow key so that the control + modifier toggles the backspace/delete interpretation set by the + backarrowKey resource.
        • + +
        • limit the row and column values used to report mouse + position.
        • +
        + +

        From resync with XFree86 3.9Nb:

        + +
          +
        • add support for the VSTATUS control character (patch by + Robert Earl <rearl@teleport.com>).
        • +
        + +

        Patch #82 - 1998/7/15 - + XFree86 3.9Aj

        + +

        Bug fix for patch #81:

        + +
          +
        • remove an #undef for NBBY, which caused compile problem on + FreeBSD (reported by David Dawes).
        • +
        + +

        Patch #81 - 1998/7/14 - + XFree86 3.9Aj

        + +

        More bug fixes:

        + +
          +
        • fix conflicting ifdef's for TIOCSLTC when building with + Linux on AXP aka DEC Alpha (reported by Robin Cutshaw).
        • + +
        • correction to patch #79, move assignment for + *utptr->ut_user = 0; back into non-SVR4 ifdef in main.c, + since this clobbers username on Solaris 2.5.1 (analysis by Will + Day <willday@rom.oit.gatech.edu>).
        • + +
        • corrected khome/kend in xterm-8bit terminfo + description.
        • + +
        • improve cursor color by making it always the reverse of + fg/bg unless the cursorColor resource is set, i.e., to + something other than the default foreground (reported by Vikas + Agnihotri and Bram Moolenaar).
        • + +
        • minor fixes for compiler warnings, including a syntax error + in the AMOEBA ifdef's.
        • +
        + +

        From resync with XFree86 3.9Aj:

        + +
          +
        • correction to patch #73, supply missing #else for fallback + definitions of size_t, time_t (Robin Cutshaw + <robin@intercore.com>).
        • +
        + +

        Patch #80 - 1998/6/29 - + XFree86 3.9Ai

        + +

        This fixes a couple of items leftover or introduced by patch + 79:

        + +
          +
        • take out the logic that suppresses editing-keypad in vt100 + mode (those keys are too valuable to give up for a fine point + of emulation).
        • + +
        • corrected a couple of places in terminfo where I missed + using the vt220-style editing-keypad codes for Find/Select + (mapped to Home/End).
        • + +
        • checked termcap file against terminfo, fix several places + where it was inconsistent.
        • +
        + +

        Patch #79 - 1998/6/28 - + XFree86 3.9Ai

        + +

        This patch fixes several small bugs:

        + +
          +
        • use X_EXTRA_LIBS in standalone Makefile.in (patch by Tomas + Vanhala).
        • + +
        • add new resource 'oldXtermFKeys' which provides backward + compatibility for F1-F4 control sequences with TOG's + xterm.
        • + +
        • determine the server's default foreground/background Pixel + values, needed if the -flipPixels X server option is used + (reported by David Dawes).
        • + +
        • correct logic for F1-F4 function keys so that they generate + VT100 compatible escape sequences in VT220 mode, since that is + what the numeric keypad is supposed to do (reported by Ron + Johnson, Jr. <ronjohn@communique.net>).
        • + +
        • modify logic for editing keypad to work more like VT220: + don't pass those codes in VT100-mode unless oldXtermFKeys mode + is set.
        • + +
        • correct an interaction with the editing-keypad logic that + prevented backarrow key from sending a 127 for the delete key + (the 'remove' escape sequence was being sent instead).
        • + +
        • use return-value from getuid() rather than the parameter, + to work on systems which do not update the latter (patch by + Kevin Buhr <buhr@mozart.stat.wisc.edu>)
        • + +
        • correct scrollbar border color when toggling to/from secure + keyboard mode (patch by Jeff Uphoff + <juphoff@tarsier.cv.nrao.edu>)
        • + +
        • modifications to terminfo file: + +
            +
          • rename description to xterm-xfree86, adding an entry + 'xterm' which is derived from xterm-xfree86 to simplify + customization.
          • + +
          • change string for kdch1 from \177 to \E[3~, to address + complaints from Debian developers. (This applies to the key + labeled "Delete", and does not affect the backarrow + key).
          • + +
          • add user-strings u6, u7, u8, u9 to entries to make them + work with Daniel Weaver's "tack" program.
          • + +
          • modify xterm-24, xterm-bold, xterm-boldso entries to + disentangle them from explicit dependency upon + xterm-xfree86.
          • + +
          • add generic 'xterm-color' entry.
          • + +
          • minor corrections to xterm-xfree86, xterm-8bit, + xterm-r5 and xterm-r6 entries.
          • +
          +
        • +
        + +

        Patch #78 - 1998/6/3 - + XFree86 3.9Ah and 3.3.2

        + +

        Again, most of the bulk of this patch is for ANSI conversion. + I used the IRIX compiler's -wlint option to find the remaining + functions that use K&R syntax (since gcc does not do this + properly). Also, I changed the logic in the print code slightly + to close unwanted files before opening a pipe to the printer. + This may help in some configurations where the line printer hangs + until xterm closes the pipe.

        + +

        Patch #77 - 1998/5/26 - + XFree86 3.9Ah and 3.3.2

        + +

        Most of the bulk of this patch is to convert the extended C + (K&R functions with prototypes) to ANSI. I verified that on + Linux by comparing object files, to ensure that I did not, for + example, interchange parameters in the function declarations.

        + +

        The rest of the patch fixes several minor bugs, and adds a few + features:

        + +
          +
        • back-out my use of ncurses "captoinfo -f" option + (if/then/else/endif) formatting, since ncurses did not + correctly filter embedded newlines in terminfo capability + strings until _after_ ncurses 4.1, thus corrupting + setf/setb/sgr strings (reported by Darren Hiebert and + others).
        • + +
        • document SGR 8, 28 (invisible/visible), add corresponding + capabilities to terminfo description. + +

          I would also add the 'prot protected capability, but the + control sequences for that would not be recognized or + properly ignored by the older xterm programs.

          +
        • + +
        • modify ChangeGroup to not suppress a null-resource, but + treat it as an empty string (recommended by Stefan + Dalibor).
        • + +
        • add printerAutoClose resource to control whether printer is + closed when going offline. More than one person reports + problems (on Solaris 2.6 and Digital Unix 4.0) getting the + printer to proceed unless xterm exits; I think that it is a + problem flushing the pipe. Closing it ought to flush it.
        • + +
        • adapt TOG fix-3 to in HandleKeymapChange and VTInitI18N + (but adapt XtStackAlloc/XtStackFree for clarity, as well as + fixing memory leak).
        • + +
        • change calls on FillCurBackground to ClearCurBackground, in + effect using XClearArea rather than XFillRectangle when + clearing as a side-effect of scrolling and insertion (patch by + Alexander V Lukyanov)
        • + +
        • correct some places where insert/delete did not _move_ the + color attributes, using memmove (patch by Alexander V Lukyanov + <lav@long.yar.ru>)
        • + +
        • add ifdef's for __CYGWIN32__, for port to cygnus version + B19.1 (patch by Andrew Sumner + <andrew_sumner@hotmail.com>).
        • + +
        • remove #define for hpux that turned on USE_SYSV_ENVVARS, + since this causes some applications (such as 'less') to get + incorrect $LINES and $COLUMNS values (reported by Clint + Olsen).
        • + +
        • modify behavior for HP-UX, to set the "reserved" process + group controls to _POSIX_VDISABLE so the TIOCSLTC ioctl does + not produce an error (patch by Ben Yoshino + <ben@wiliki.eng.hawaii.edu>).
        • + +
        • correct length of underlining, reducing it by one pixel to + avoid leaving a dot when the application does not clear the + whole screen I noticed this only recently myself (and other + people as well); it depends on the font chosen. A 6x10 font + shows it, but the other fonts from XTerm.ad do not. I also see + a similar problem with the emulation of bold fonts. (patch by + Sergei Laskavy <Laskavy@cs.msu.su>).
        • + +
        • add include for Xos.h to xterm.h, to ensure proper + definitions (reported by Holger Veit).
        • + +
        • update config.guess to recognize Unixware 2.1 and 7 (patch + by Mike Hopkirk <hops@sco.com>).
        • +
        + +

        Patch #76 - 1998/5/8 - + XFree86 3.9Ah and 3.3.2

        + +

        A fix for the print-window function, and some minor + cleanup:

        + +
          +
        • modify logic that closes pipe in the print-window function + to not use pclose, which does not work on all systems, since I + did not open the pipe with popen (reported by Stefan + Dalibor).
        • + +
        • correct name of $(EXTRA_LOAD_FLAGS) imake variable + (reported by Stefan Dalibor).
        • + +
        • guard logic in ChangeGroup() function against null pointer + (reported by Stefan Dalibor).
        • + +
        • ensure that menu entry for toggling sunKeyboard resource is + initialized (reported by Branden Robinson + <branden@purdue.edu>).
        • + +
        • gcc unused-variable warnings (reported by Bernd Ernesti + <bernd@arresum.inka.de>)
        • + +
        • rename global variable 'buffer' to 'VTbuffer'
        • +
        + +

        Patch #75 - 1998/5/7 - + XFree86 3.9Ah and 3.3.2

        + +

        This incorporates fixes from several people, as well as some + improvements that I made based on feedback from users:

        + +
          +
        • add option to standalone configure script, + "--with-own-terminfo-dir", which causes xterm to pass a + predefined value of $TERMINFO to the application. Also use this + value in install rule "make install-ti", for the standalone + configure script. (patch & feedback from Tor Lillqvist + <tml@hemuli.tte.vtt.fi>)
        • + +
        • change ifdef's for "hpux" to "__hpux" (patch by Tor + Lillqvist). The imake configuration uses the former, but the + latter is predefined by HP's compilers.
        • + +
        • define USE_SYSV_ENVVARS for HP-UX, curses does not use + $TERMCAP (patch by Tor Lillqvist).
        • + +
        • on HP-UX, use the /dev/ptym/clone device to allocate PTY's. + Works both on HP-UX 9 and 10. (patch by Tor Lillqvist).
        • + +
        • modify configure script to obtain the $(EXTRA_LOADFLAGS) + value from imake, needed for compiling under DEC OSF/1 + (reported by Stefan Dalibor)
        • + +
        • modify print-window action so that the printer is closed + after printing a window, unless the printer was already opened + (i.e., by an application running in the window). This makes the + printing complete without having to exit xterm, since not all + systems treat fflush through a pipe very well (reported by + Stefan Dalibor)
        • + +
        • modify printing code so that the ^M's are not printed if + the printAttribute resource is set to zero (request by Stefan + Dalibor).
        • + +
        • correct typo in xterm.man, for the default value of + printAttribute (reported by Stefan Dalibor).
        • + +
        • correct printing code so that the alternate character set + is printed, like other attributes, with escape sequences.
        • + +
        • correct termcap description, removing spurious 'm' + character from the 'op' capability (reported by Greg Woods + <woods@weird.com>).
        • + +
        • correct trace code so that the initial timestamp is + set.
        • + +
        • correct/modify utmp data for the Linux glibc 2 + configuration, so that the ut_line member is set before using + it to update wtmp (patch by Bill Nottingham + <wen1@cec.wustl.edu>).
        • +
        + +

        Patch #74 - 1998/4/27 - + XFree86 3.9Ag and 3.3.2

        + +

        This corrects a couple of recent bugs and adds a new + resource:

        + +
          +
        • modify definition of TRACE_CHILD so that it does not + conflict with ifdef's for USE_USG_PTYS in main.c (reported by + Vikas Agnihotri <VikasA@att.com> and Stefan + Dalibor).
        • + +
        • correct ownership of file (actually pipe) written by the + print controls. When undoing the setuid changes in patch #69, I + overlooked this. Now xterm forks a process which resets setuid + and routes the printer data as the real user.
        • + +
        • add a new resource, "printAttributes", which controls + whether color attributes (or any attributes) are sent to the + printer.
        • +
        + +

        Patch #73 - 1998/4/25 - + XFree86 3.9Ag and 3.3.2

        + +

        This patch does the following:

        + +
          +
        • implements a print-window facility for xterm. Though useful + in itself, I added it as part of some debugging which I am + doing. (Occasionally during an exposure event xterm fails to + restore the proper colors for highlighted text, and printing + the screen will show the internal states nicely). + +

          The print facility now also displays the color + information. (I will probably make this a resource).

          +
        • + +
        • modified the xterm-16color terminfo description to use the + setaf and setab strings, which is a little more efficient + (requested by Stephen Marley).
        • + +
        • reduced some clutter of the ifdef/includes (e.g., stdlib.h, + unistd.h, errno) making the configure script test for these. + +

          I removed the symbols Size_t and Time_t, since they no + longer serve a useful purpose.

          +
        • + +
        • added some debugging traces to show the initial screen + size, and the success/failure of the ioctl calls pass handle + window resizing events to the application (for Clint Olsen). + +

          I also modified the trace code to produce two files since + some of the information is produced by the child process. So + now they are Trace-parent.out and Trace-child.out

          +
        • + +
        • updated configure test for ANSI compiler options to handle + a special case for HP-UX 10.x (reported by Clint Olsen).
        • +
        + +

        Patch #72 - 1998/4/17 - + XFree86 3.9Ag and 3.3.2

        + +

        This is a patch from Chris Siebenmann + <cks@hawkwind.utcs.toronto.edu>, which I have cleaned up a + little, and integrated into the configure script.

        + +

        From his description:

        + +
        +

        This set of patches is the latest incarnation of patches + originally written by Ian! D Allen, then of the University of + Waterloo and now of who knows where; I have been carrying them + forward from xterm to xterm ever since about X11R4. What they + do is add an option so that when an iconified xterm receives + output it prepends '*** ' to its icon title and (optionally) + beeps the bell; deiconifying the xterm removes the '*** '. Over + the years I've found this to be incredibly convenient for + monitoring all sorts of low-activity things.

        +
        + +

        Patch #71 - 1998/4/12 - + XFree86 3.9Ag and 3.3.2

        + +

        This patch is a slightly modified version of one by Richard + Braakman, which prevents buffer overflow in the input-method and + preedit-type parsing in xterm. I changed a couple of details to + make the code more maintainable, and looked for similar things - + copying into a fixed-size buffer (found none, though I did spot + an unused variable).

        + +

        Patch #70 - 1998/3/29 - + XFree86 3.9Af and 3.3.2

        + +

        This patch corrects some minor bugs in xterm, and fills in + some more details in the VT220 emulation:

        + +
          +
        • modify Imakefile to use SpecialCObjectRule for menu and + data modules, making xterm build properly if logging is enabled + (patch by Scott Sewall <scott@iprg.nokia.com>).
        • + +
        • restore "ich" capability to terminfo entries, since Michael + Schroeder points out that "ich1" is the one which is the + problem in Solaris vi.
        • + +
        • correct color of cursor, which would disappear on + inverse-video since the initialization did not compare the + cursor color against both foreground and background (reported + by Olivier Calle).
        • + +
        • correct abbreviation-test for -version and -help options, + making command-line option -vb work (reported by Stefan + Dalibor).
        • + +
        • correct a dependency between ifdef's for OPT_I18N_SUPPORT + and OPT_INPUT_METHOD (reported by Stefan Dalibor).
        • + +
        • split-out character-set translations as new module + charsets.c, to implement VT220 national replacement character + sets (a mode where some of the characters are displayed as + specific European glyphs). This relies on xterm using an ISO + 8859-1 font (approach suggested by Kenneth R. Robinette + <zkrr01@mailbox.neosoft.com>).
        • + +
        • correct a missing increment, which made SS2 and SS3 + controls repeat the shifted character.
        • + +
        • add xterm-nrc to terminfo to illustrate the VT220 national + replacement character sets.
        • + +
        • reformat terminfo using new ncurses tic option "-f", which + makes if/then/else/endif expressions easier to read.
        • +
        + +

        Patch #69 - 1998/3/16 - + XFree86 3.9Ad and 3.3.2

        + +

        This corrects the problem in xterm with utmp, reported by + Olivier Calle <olivier@tc.fluke.com> as well as some other + people after the XFree86 3.3.2 release.

        + +

        The error was introduced by my patch #53 in XFree86 3.9r + (October 1997).

        + +

        The correction removes the reset of setuid/setgid before the + main event loop, and solves the problem which I had worked around + in a different manner: for some reason, the particular waitpid() + call in creat_as() hangs, does not return when the child process + exits. I changed the ifdef's to force the Linux configuration to + use wait() instead. This call appears to work properly on other + platforms such as SunOS and Solaris.

        + +

        I also added tests in the standalone configure script to check + for the existence of waitpid().

        + +

        Patch #68 - 1998/3/4 - + XFree86 3.9Ad and 3.3.1z

        + +

        This corrects another problem with the logic for + highlightColor resource. As reported by David Dawes:

        + +
        +

        I've just noticed a problem with with the "inverse" control + sequence (ESC[7m) with the 3.3.2 xterm. What it does is sets + the background black, and the text the usual foreground colour + rather than simply swapping the foreground/background.

        +
        + +

        This appears to be because when I added logic to check that + the highlightColor was distinct from foreground and background + colors, I did not add a further check to see that it was not + black (I would make an explicit check for the resource not being + set, but see nothing definite in the headers that would let me + reference an explicitly-undefined Pixel value, though there are + some implications in xpm.h). But this should work.

        + +

        Patch #67 - 1998/2/23 - + XFree86 3.9Ad and 3.3.1e

        + +

        This patch does the following:

        + +
          +
        • improve test for highlightColor so that xterm does not + attempt to use that unless it is different from the foreground + and background colors (reported by Stefan Dalibor + <Stefan.Dalibor@informatik.uni-erlangen.de>. + +

          I could not reproduce this until I noticed that the -rev + option exposed it nicely.

          +
        • + +
        • remove ich and ich1 from xterm and xterm-8bit terminfo + descriptions. SVr4 terminfo documents that you must not combine + these with smir/rmir, but ncurses allows it, opening a hole. + Solaris 2.6 vi does not work properly if it is using a terminfo + description when these are combined, since it was written to + accommodate old terminals that required it (reported by Stephen + Marley).
        • + +
        • restore 1-pixel overlap of scrollbar border with left edge + of window (reported by Jim Burmeister + <jimb@metrolink.com>).
        • + +
        • add a configure option, --enable-logfile-exec, which allows + the user to specify a pipe for logfile. This defines + ALLOWLOGFILEEXEC.
        • + +
        • makes the ALLOWLOGFILEEXEC code compile & run, if + configured.
        • + +
        • minor documentation nits.
        • +
        + +

        Patch #66 - 1998/2/16 - + XFree86 3.9Ad and 3.3.1d

        + +

        This fixes the problem reported with failure to build the + resize program (BSDI, OSF/1) due to not having + <termcap.h>, by changing the ifdef to one that would be set + only if the file exists (not currently specified, except by the + standalone configure script). We do not really need to include + <termcap.h> to build, but only for a clean compile, since + it may declare the tgetent() prototype. I also updated the + man-page for resize, since I had recently noticed that + it can be used to resize xterm using the "Sun" control + sequences option.

        + +

        Patch #65 - 1998/2/14 - + XFree86 3.9Ad and 3.3.1c

        + +

        This is a small patch to xterm's 8-bit terminal description. I + noticed while testing ncurses that I had specified the wrong + (VT100-style) codes for the F1-F4. Xterm only uses VT220-style + function keys in 8-bit mode.

        + +

        Patch #64 - 1998/2/8 - + XFree86 3.9Ad

        + +

        This fixes the following problems with xterm:

        + +
          +
        • save/restore the ANSI foreground and background colors with + the other visible attributes in the save-cursor and + restore-cursor operations. This works around a problem with + vim, which apparently assumed that switching between the normal + and alternate screens resets the colors (reported by Jim Battle + <jb@chromatic.com>). + +

          It would be nice to implement save/restore cursor as a + stack (and solve this type of problem completely), but that + would lead to incompatibility with applications which assume + they are running with a VT100 or VT220.

          +
        • + +
        • corrects behavior of a restore-cursor operation which does + not follow a save-cursor (it is supposed to set the character + sets to a known initial state).
        • + +
        • extends the sunKeyboard resource (and menu toggle) to + modify the home, end and delete keys on a Sun or PC editing + keypad, making them generate codes compatible with DEC VT220's + Find, Select and Remove keys.
        • + +
        • corrects a length in checking command-line options, which + caused the "-help" message to not work when X was not + running.
        • + +
        • add some detail to the man-page (requested by Jason Bacon + <acadix@execpc.com>)
        • + +
        • modify the standalone configure script to ignore the broken + nsl and socket libraries on IRIX 6.2 (the ones on 5.2 also are + broken, so this change just widens the check for the system + version number).
        • +
        + +

        Patch #63 - 1998/2/5 - + XFree86 3.9Ad

        + +

        This is another patch from Bjorn Helgaas + <helgaas@rsn.hp.com>, which I've reviewed (and learned + some). Following are his notes:

        + +

        I poked around some more and finally got xterm-62 to build and + run cleanly on HP-UX 10.20. Here are the patches. They look sort + of ugly, so here's a little explanation:

        + +
          +
        • aclocal.m4: Removed side effects from the AC_CACHE_VAL + commands in CF_FUNC_TGETENT. Previously, LIBS was set inside + AC_CACHE_VAL, which worked fine the first time configure was + run, but failed if there were cached values.
        • + +
        • aclocal.m4: Added temporary setting of LIBS before + AC_TRY_LINK in CF_FUNC_TGETENT. Previously, the last value set + by the AC_TRY_RUN loop was used, so only -lcurses was + checked.
        • + +
        • configure.in: Added temporary setting of CPPFLAGS before + AC_CHECK_HEADERS for X11 files. Previously + <X11/DECkeysym.h> and <X11/Xpoll.h> were found only + if they were in the compiler's default include directories, + even if `--x-includes=DIR' had been used or AC_PATH_XTRA had + found them elsewhere.
        • +
        + +

        The problem on HP-UX was that we were linking with -lcurses + rather than -ltermcap due to the second bullet above, and + apparently something in HP-UX curses is broken. This seems very + strange, because the only thing used is tgetent, which should + affect any tty/pty configuration, but I lost interest in tracking + down the exact problem.

        + +

        Patch #62 - 1998/1/23 - + XFree86 3.9Ac

        + +

        This is a patch mostly by Bjorn Helgaas + <helgaas@dhc.net> (I added the os2main.c change, and a + little of the documentation). From Bjorn's description:

        + +
          +
        • If you use the "-hc <color>" option or set the + "highlightColor" resource, text is highlighted by changing only + the background color, rather than using reverse video. I find + this easier to read, especially when selecting multi-colored + text, and it is similar to the way Netscape shows + selections.
        • + +
        • Most of the code changes are under "#if + OPT_HIGHLIGHT_COLOR". The principal exception is in screen.c, + where I added a couple calls to resetXtermGC(). This seems like + it could be a bug even without the color highlighting changes + (though I don't pretend to understand all the logic).
        • +
        + +

        Patch #61 - 1998/1/17 - + XFree86 3.9Ac

        + +

        This patch modifies the reset behavior of xterm slightly:

        + +
          +
        • change the terminfo entry so that rs1 (one of the strings + used by the 'reset' program) does a hard reset rather than + switching character sets. This is more in accord with other + terminal descriptions.
        • + +
        • modifies the treatment of hard reset by the xterm program + to reset the saved lines.
        • + +
        • corrects hard reset by also resetting user-defined keys, + i.e., DECUDK.
        • +
        + +

        Patch #60 - 1998/1/10 - + XFree86 3.9Ab

        + +

        This fixes some minor bugs and adds new functionality:

        + +
          +
        • add support for blinking text. + +
            +
          • This does not actually cause the text to flash, but + text with the blink attribute can be displayed in color, + using new resources colorBL and colorBLMode.
          • + +
          • If colors are not used, the blinking text will be + displayed as before (just like bold). The main purpose of + this is to make applications work properly when they assume + the emulator supports blinking text.
          • + +
          • I did this by moving the per-cell LINEWRAPPED flag to a + per-line flag, to make room for the new BLINK flag. There + were no per-line flags, so this changes a lot of + logic.
          • +
          +
        • + +
        • corrected missing save-cursor logic in the handling of SGR + 1048 (the new control sequence I added in patch #54, + 1997/10/17). Reported by Darren Hiebert.
        • + +
        • flush the output of the transparent printing after each + line Reported by Tomas Vanhala + <vanhala@ling.helsinki.fi>.
        • + +
        • correct the modes that are affected by save/restore cursor + by adding WRAPAROUND and PROTECTED.
        • + +
        • corrected placement of one of the XSync calls that I added + in patch #51, 1997/9/15, which had the side-effect of writing + on the window border when the xterm was resizing from 132 to 80 + columns.
        • + +
        • work around an incompatibility of the XKB definition used + in xterm versus that symbol from IRIX 6.2's imake definitions + (by adjusting the standalone configure script).
        • +
        + +

        Patch #59 - 1998/1/5 - + XFree86 3.9Ab

        + +

        My last patch has an off-by-one error in the comparison for + argc. Douglas Kosovic <douglask@dstc.edu.au> showed me + where (he got a core dump). Also, I think this explains Clint + Olsen's problem, but the symptoms were more subtle (EINVAL for a + system call if the -display option is omitted).

        + +

        Patch #58 - 1998/1/3 - + XFree86 3.9Ab

        + +

        This patch does the following:

        + +
          +
        • implement logic to permit xterm to work with proportional + fonts. + +
            +
          • Thomas Wolff <Thomas.Wolff@sietec.de> requested + this (but it isn't exactly what he's asking for - that's a + more involved task).
          • + +
          • I chose to do this by rendering the characters on a + fixed pitch, because it would not be useful for existing + applications to display varying numbers of characters on + each line.
          • + +
          • Except that this forces the display to be wider, it + works reasonably well. A couple of special cases (reverse + + colorBD, for example) do not display with proper colors, + since the inter-character gaps are painted with the + background.
          • +
          +
        • + +
        • added a version number to the program (several people have + requested this).
        • + +
        • make the -version and -help options interpreted before the + program attempts to open the display.
        • + +
        • minor reorganization of the man-page (ordered the options, + resources and translations alphabetically - and eliminated some + duplication).
        • + +
        • corrected a misspelled filename in Makefile.in, and added a + lint rule.
        • + +
        • updated the configure script to correct behavior when it + cannot find imake, as well as to fix the IRIX+gcc build + (conflict with /usr/include).
        • + +
        • regenerated the configure script with a newer patch to + autoconf that fixes a problem with environment space vs the + configure --help message.
        • +
        + +

        Patch #57 - 1997/12/26 - + XFree86 3.9Aa

        + +

        This patch is mostly concerned with the standalone configure + script; a few minor corrections are added:

        + +
          +
        • add configure option --disable-tek4014, to allow xterm to + be built without the tek4014 emulation.
        • + +
        • add configure option --with-terminal-type, to allow xterm + to be compiled with default $TERM value other than "xterm" + (e.g., "xterm-16color") -- requested by Stephen Marley + <stephen@memex.com>.
        • + +
        • fix a typo in the configure --help message -- reported by + Darren Hiebert <darren@hmi.com>.
        • + +
        • review diffs between main.c and os2main.c, to make them + more alike. (applies some minor bug-fixes to OS/2's + version).
        • + +
        • add missing quotes in memmove/bcopy configure test
        • +
        + +

        Patch #56 - 1997/11/28 - + XFree86 3.9x

        + +

        This patch is based on analysis by Arfst Ludwig + <arfst@luxor.IN-Berlin.DE>, who reported:

        + +
        +

        Setting the following resources xterm (all current versions) + receives a segmentation fault on <Btn2Up> after + scrolling:

        +
        +          *XTerm*VT100*translations:    #override \
        +              ~Shift~Ctrl<Btn2Up>: insert-selection(PRIMARY, CUT_BUFFER0)\n\
        +              Shift~Ctrl<Btn2Up>:  insert-selection(CLIPBOARD, CUT_BUFFER1)\n\
        +              ~Shift<BtnUp>:       select-end(PRIMARY, CUT_BUFFER0)\n\
        +              Shift<BtnUp>:        select-end(CLIPBOARD, CUT_BUFFER1)
        +
        + +

        (The above resources intention is to be able to paste the + latest selection even if the xterm was cleared.)

        + +

        And here is how it works (and a fix!): The widget given to + the action handler as first argument is not guaranteed to be a + XtermWidget (it can be the ScrollbarWidget). Instead of + accessing the widget's member directly XtDisplay gives the + required pointer in a safe way.

        +
        + +

        I noticed that this was not the only instance (by reading the + code, and testing with his example), and extended the solution to + check the widget-class to ensure that it is indeed xterm's widget + class before attempting to use it in the context of + translations.

        + +

        Patch #55 - 1997/11/25 - + XFree86 3.9x

        + +

        This fixes the segmentation violation noted by Rogier Wolff + about a month ago. He'd set xterm to 400 (rows) by 150 columns, + which broke because there were limited buffers (200 rows) used + for juggling data when adding or deleting lines and for switching + between alternate and normal screens. I replaced this by an + allocated buffer.

        + +

        The bug is simple to test if you set titeInhibit false.

        + +

        Patch #54 - 1997/10/17 - + XFree86 3.9s

        + +

        This patch does the following:

        + +
          +
        • correct a minor placement problem with the right + scrollbar.
        • + +
        • implement a new set of control sequences for switching + between the normal and alternate VT100 screens. These work + around the older sequences limitation that required + modification of the runtime $TERMCAP to cooperate with the + titeInhibit resource (that can't work with terminfo). I do this + by moving all of the functionality of the rmcur terminfo + capability into the control sequences.
        • + +
        • implement the alternate-screen menu entry
        • +
        + +

        Patch #53 - 1997/10/12 - + XFree86 3.9r

        + +

        This patch adds a fix and implements a new feature (as well as + some minor typos):

        + +
          +
        • JCHANDRA@Inf.COM (JCHANDRA) noted that there was still a + problem with the wait call with the logging option. It hung + when the logfile was opened as a command-line option. I fixed + this by moving the StartLogging() call down past the place + where I'd reset the setuid mode. So the logfile is opened as + the real user, without having to fork.
        • + +
        • improve Rohleder's changes by renaming the command-line + options and reducing the number of ifdef's.
        • + +
        • implement right-scrollbars for xterm (patch by Michael + Rohleder <michael.rohleder@stadt-frankfurt.de>).
        • +
        + +

        Patch #52 - 1997/9/29 - + XFree86 3.9q

        + +

        This patch addresses bugs and requests reported by

        + +
          +
        • Bob Maynard <rmaynard@montana.com>,
        • + +
        • Clint Olsen <olsenc@ichips.intel.com>,
        • + +
        • JCHANDRA@Inf.COM (JCHANDRA),
        • + +
        • Michael Schroeder + <Michael.Schroeder@informatik.uni-erlangen.de>,
        • + +
        • Pablo Ariel Kohan <pablo@memco.co.il>
        • +
        + +

        Some of the changes are interrelated (it was an unusually busy + week).

        + +
          +
        • change the default resource value for colorMode to true, + matching the Xterm.ad file.
        • + +
        • correct behavior of 'ech' control, making the default and 0 + parameters erase one character rather than to the end of line + (reported by Michael Schroeder).
        • + +
        • add resource boldColors, command-line options +pc and -pc + and configure-script option to specify behavior of xterm's + mapping bold colors 0 through 7 to colors 8 through 15. + (request by Pablo Ariel Kohan).
        • + +
        • add resource colorAttrMode to specify whether colorULMode + and colorBDMode can override the ANSI colors (report by Clint + Olsen).
        • + +
        • correct a conflict between colorULMode/colorBDMode versus + ANSI colors, where exposure events would occasionally pick up + the former (e.g., colorBD) rather than ANSI colors. Testing the + colorAttrMode made this apparent, though it has been in the + code since 3.2A (patch #35 in Jan 1997).
        • + +
        • correct two problems with the optional logging support. On + Linux at least, the waitpid call in creat_as hangs when the + logging is toggled from the popup menu. Also, the mktemp + template has the wrong number of X's (since X11R5!). Fixed the + waitpid problem by exploiting the fact that the setuid behavior + is reset before the popup menus are available. (reported by + Jayachandran C.).
        • + +
        • add configure script options for building with the Xaw3d + and neXtaw libraries.
        • + +
        • correct CF_IMAKE_CFLAGS standalone configure script macro, + so that it will pick up $(ALLDEFINES) rather than + $(STD_DEFINES). This is needed to make scrollbars work on + Linux, since that uses narrow prototypes. (reported by Bob + Maynard).
        • + +
        • various minor updates to configure-script macros.
        • +
        + +

        Patch #51 - 1997/9/15 - + XFree86 3.9p

        + +

        Most of this patch is related to the standalone configure + script, though there are fixes/enhancements as well:

        + +
          +
        • add a new resource sunKeyboard, with associated + command-line option and menu-toggle that allows using a normal + Sun or PC keyboard to generated the complete DEC-style function + keys and keypad.
        • + +
        • correct a reversed foreground/background test in the + control sequence that replies with the current SGR + settings.
        • + +
        • correct, by invoking XSync, a display problem that caused + the program to not properly update newly exposed areas when a + font change or 80/132 resize request was not completely + accepted.
        • + +
        • restructured autoconf macros (I made a library of all of + the macros across the complicated configure scripts I'm working + on).
        • + +
        • use the autoconf config.guess and config.sub scripts to + better identify the host-os.
        • + +
        • improve the configure script that uses 'imake' as a + fallback for definitions.
        • + +
        • correct several instances of unsigned/signed mixed + expressions.
        • +
        + +

        I've tested the configure script on Linux, SunOS 4.1.3, + Solaris 2.5.1, IRIX 5.2 and 6.2, AIX 3.2.5 and CLIX 3.1 (all but + the last run properly as well).

        + +

        Patch #50 - 1997/8/22 - + XFree86 3.9m

        + +

        This is a collection of small fixes, and a couple of minor + enhancements:

        + +
          +
        • plug a security hole in the implementation of Media Copy + (print) by invoking setuid just before the main loop.
        • + +
        • add an ifdef'd include for <sys/termio.h> for HP-UX, + which allows the program to process SIGWINCH events (this is a + bug in X11R6.3)
        • + +
        • add state-table entries for VT52 emulation to enter/exit + keypad application mode.
        • + +
        • disable the popup-menu entry for 8-bit controls when the + terminal-id is less than 200 (e.g., VT52 or VT100).
        • + +
        • ensure that the popup-menu entry for 8-bit controls is + updated when the application enables/disables this mode, + including the response to a full-reset.
        • + +
        • implement VT300 DECBKM feature: set interpretation of the + backarrow key to either backspace or delete. The initial + setting is via resource; it can also be modified in the main + popup menu.
        • + +
        • implement VTxxx KAM (ISO AM), which allows a keyboard to be + locked (i.e., the terminal discards input).
        • + +
        • implement VTxxx SRM, which is used to control local echoing + of input on the terminal.
        • + +
        • add terminfo and termcap entries for xterm-8bit, a + variation of the xterm description that uses 8-bit control + characters.
        • + +
        • add fallback definitions for Imakefile to allow it to work + on some X11R5 systems that have no SpecialCObjectRule or + ProgramTargetName macros.
        • + +
        • add .c.o and .c.i rules to standalone Makefile.in
        • + +
        • correct order of -lXmu and -lXext in standalone configure + script.
        • + +
        • add configure script options to allow selective disabling + of active-icon, input-method and i18n code (mainly for users + with X11R5 or an incomplete X11R6 configuration).
        • + +
        • change menu-indices from #define's to enum values, thereby + making it work better with the ifdef's for logging and + active-icon (the X11R6.3 active-icon code is incorrectly + ifdef'd; this corrects an error introduced by incorporating + that code).
        • + +
        • correct minor compile errors in the configuration where + active-icon is not used.
        • + +
        • add configure option to suppress echoing of long compiler + commands
        • + +
        • correct spelling of decTerminalID in configure script help + message
        • + +
        • use gcc __attribute__((unused)) to quiet warnings about + unused parameters when compiling with -W (to make it simpler to + find the real problems).
        • +
        + +

        Patch #49 - 1997/8/10 - + XFree86 3.9k

        + +

        This patch implements the VT100/VT220 Media Copy (i.e., + print-screen) control sequences.

        + +

        Patch #48 - 1997/7/26 - + XFree86 3.9j

        + +

        This patch does the following (all but the first affect only + the standalone configure script):

        + +
          +
        • minor correction to positioning of underlines for small + (e.g., 5x8) font size. + +

          The existing behavior allowed underlines to be drawn + outside the character-cell, so they weren't cleared properly + under some circumstances.

          +
        • + +
        • adds more special-case tokens to the standalone configure + script's imake-option filter (e.g., "&&", since a "make + -n main.o" on my IRIX system uses that shell construct).
        • + +
        • adds a '--enable-logging' option for the standalone + configure script.
        • + +
        • adds check and ifdef's for the standalone configure script + to allow for building on platforms with X11R6, which lacks + Xpoll.h (introduced in X11R6.1).
        • +
        + +

        Patch #47 - 1997/7/13 - + XFree86 3.9i

        + +

        This patch does the following

        + +
          +
        • corrects an indexing error in the doublesize character + logic (button.c) that caused core dump (this was reported by J. + Wunsch).
        • + +
        • corrects the logic of ShowCursor when it is painting in a + doublesize cell (charproc.c).
        • + +
        • corrects, according to vttest, the behavior when switching + to doublesize characters and back again (doublechr.c).
        • + +
        • adds cbt (back_tab) to the terminfo description (this was + something that I'd overlooked as applicable to curses + optimization last summer).
        • + +
        • corrects, for the standalone xmc test, the logic for + disabling xmc.
        • +
        + +

        Patch #46 - 1997/7/4 - + XFree86 3.9h

        + +

        This is a patch to provide test-support for some work I'm + doing on ncurses. It does not modify the normal configuration of + xterm; the code is compiled if the standalone configure option + "--enable-xmc-glitch" is specified.

        + +

        Patch #45 - 1997/7/2 - + XFree86 3.9h

        + +

        This fixes the problem reported with xterm's cursor color + versus the background (the second chunk in this patch) and also + removes some duplicate initialization of the cursor GC's. If the + cursor color at startup is the same as the background, then xterm + will use the reverse GC, ignoring the setting of the colorMode + resource.

        + +

        Patch #44 - 1997/6/22 - + XFree86 3.9g

        + +

        This implements the first part of the VT100 doublesize + characters for xterm, as well as fixing a handful of bugs:

        + +
          +
        • the doublesize character support uses the normal font + (using scaled fonts will be another patch) with blanks to + simulate doublesize characters. This patch does most of the + global changes that'll be required. I've hidden most of the + details in macros and ifdef's so it's easy to configure out + (part of the patch is a configure option for that + purpose).
        • + +
        • corrected limits in DeleteChar() function -- it's always + ignored the size of the left border and scrollbar. I noticed + this when working on the doublesize characters since the glitch + was doubled in size (i.e., it wrapped some garbage around the + right margin).
        • + +
        • corrected 'memmove()' logic, for standalone builds (it + referenced a malloc wrapper from my development library).
        • + +
        • add a check for HideCursor() to prevent repeated screen + updates (which can cause a spurious cursor glitch to appear, + e.g., during scrolling). I noticed this with the 3.2A version + (but only a few weeks ago, when I started working on this + patch).
        • +
        + +

        Patch #43 - 1997/6/10 - + XFree86 3.9d

        + +

        Here's a fix for two problems:

        + +
          +
        • modify handling of tgetent results in xterm and resize + programs to make them tolerant of missing termcap file, or + unknown terminal name. In this scheme, an explicit "-tn" option + will succeed, overriding the fallback list.
        • + +
        • a nit in the configure script (log extra information to + help diagnose which case of the test-compile of tgetent was + used).
        • +
        + +

        Patch #42 - 1997/6/8 - + XFree86 3.2Xl

        + +

        Bram Moolenaar reported that the cursor color changed + unexpectedly while scrolling. The cause was that it used the same + GC's as the logic that draws the ANSI colors. The bug only + appears if the cursorColor resource isn't set, and has been + present since the initial implementation early last year. (The + same bug also appears in rxvt ;-). Here's a fix.

        + +

        Patch #41 - 1997/5/28 - + XFree86 3.2Xl

        + +

        Some nits found by Darren Hiebert (missing part of + install-rule, incorrect assignment for --enable-color-mode + option).

        + +

        Patch #40 - 1997/5/26 - + XFree86 3.2Xl

        + +

        Patch for the configure script's logic for obtaining imake + predefined symbols.

        + +

        Patch #39 - 1997/5/24 - + XFree86 3.2Xl

        + +

        This patch does the following:

        + +
          +
        • integrate the 16-color change for 'xterm'
        • + +
        • minor fixes/clarification of tgetent in terminfo vs termcap + to 'resize'
        • +
        + +

        (both changes also modify the configure script)

        + +

        Patch #38 - 1997/5/22 - + XFree86 3.2Xh

        + +

        This implements a simple configuration script with autoconf + (to which I'll add more options later). It does the + following:

        + +
          +
        • configures xterm to build with X11R5 (at least on SunOS + 4.1, Solaris 2.4, possibly IRIX - sorry network was down today, + but I did test an earlier version yesterday).
        • + +
        • enables/disables the configuration ifdef's for ANSI color + and VT52 emulation.
        • +
        + +

        It does not make tests for the things that imake does (that's + another project), instead it uses a hybrid of the autoconf tests + for libraries and adds imake's compiler options (which are + necessary in some cases to get main.c to compile).

        + +

        Patch #37 - 1997/5/7 - + XFree86 3.9a

        + +

        This corrects a minor, but annoying error in the vt220 + emulation: the DECUDK is only supposed to be interpreted for + _shifted_ function keys.

        + +

        Patch #36 - 1997/1/16 - + XFree86 3.2r

        + +

        This corrects something that I overlooked in patch #27 + (21-aug-1996), which is that when trimming the region to be + repainted for the highlightSelection resource of xterm, I still + have to paint the background past the highlighted region. This + only happens when I first do a selection in a window that's + partly off-screen, then move the window on-screen.

        + +

        Patch #35 - 1997/1/7 - + XFree86 3.2o

        + +

        This patch does the following:

        + +
          +
        • combines the coding for foreground and background colors + into a single byte, reducing the memory required to store + saved-lines in color. (I'll take back that byte in a following + patch to use to ensure the character-set, so there's no + long-term decrease in memory use).
        • + +
        • modifies the PF1-PF4 coding in termcap/terminfo. Because + xterm is still by default emulating vt100, the function key + codes are vt100-compatible (I overlooked this in patch #31). I + also reformatted the whole terminfo file into a single-column, + for consistency.
        • + +
        • adds an interim xterm-vt220 description to accommodate the + old and new styles of function-keys (though probably it'd be + better to drop the old-style altogether).
        • +
        + +

        Patch #34 - 1997/1/5 - + XFree86 3.2o

        + +

        This patch does the following:

        + +
          +
        • implement DECSTR (soft terminal reset). The biggest diff is + due to adding another state table (note that there's only one + useful state here, but it's only 256 bytes rather than 1k as it + would have been before I reduced the size of state + entries).
        • + +
        • some minor tidying up (e.g., signed/unsigned use bitcpy, + MODE_DECCKM, resetColor, resetCharsets). More is done in patch + #35.
        • +
        + +

        I got the description of DECSTR from a vt420 user's manual. + I'll do some testing with vttest to ensure that there's nothing + else to do than what was documented.

        + +

        Patch #33 - 1996/11/24 - + XFree86 3.2

        + +

        This adds to the reset-fix by Matthieu Herrb + <Mathieu.Herrb@mipnet.fr> a small change to make xterm able + to output 8-bit characters in VT100 mode. Applications that run + on real VT100's don't do that anyway, and this feature should be + removed sometime after finishing off the VT220 emulation (VT220's + can do 8-bit characters). That would be a good time to change the + default terminal-id to 220.

        + +

        Patch #32 - 1996/11/21 - + XFree86 3.2

        + +

        This implements the REP (repeat) control for xterm. That isn't + part of the DEC VTxxx series, but is defined in ISO 6429. (Note + that the base xterm terminal description is not changed + -- I added a variant, "xterm-rep").

        + +

        Patch #31 - 1996/11/16 - + XFree86 3.2

        + +

        This implements vt52 emulation in xterm (ifdef'd so it can be + removed). I've been using it for testing for the past month or + so.

        + +

        Patch #30 - 1996/11/16 - + XFree86 3.2

        + +

        From bug-report by <auroux@clipper.ens.fr> (Denis + Auroux), missing reset to ground state. I checked through the + rest of that table and found another, in the + unimplemented MC (screen print).

        + +

        Patch #29 - 1996/9/15 - + XFree86 3.1.2Gb

        + +

        This patch does the following:

        + +
          +
        • corrects the restoration of color for bold/underline color + mode
        • + +
        • adds a resource 'decTerminalID' to control the reporting + level of xterm (e.g., VT100, VT220).
        • + +
        • uses the new resource to implement/correct the DA1, DA2 and + DECRPTUI reports.
        • + +
        • change valid-response code in DECRQSS from 0 to 1 (the + manual says 0, but the VT420 terminal I've been testing on says + 1).
        • +
        + +

        All of these changes are based on vttest 2.6

        + +

        (Most of the volume in the patch is to add 2 more state tables + for parsing the 2nd/3rd device-attribute controls).

        + +

        Patch #28 - 1996/8/31 - + XFree86 3.1.2F

        + +

        This patch corrects the following reported by Roland Rosenfeld + <roland@spinnaker.rhein.de>:

        + +
          +
        • handle SGR 22, 24 and 25 in combination with colorUL and + colorBD resources. Also noted & fixed reset of colored + underline/bold with SGR 0.
        • + +
        • a typo in the termcap (missing '['), from 3.1.2Dj (my + error)
        • +
        + +

        Roland also complained that he couldn't use box characters + with

        +
        +        -adobe-courier-bold-r-normal--12-120-75-75-m-70-iso8859-1
        +
        + +

        but that's a known xterm limitation (the box characters must + be part of the font, in the first 32 locations).

        + +

        Patch #27 - 1996/8/21 - + XFree86 3.1.2Ek

        + +

        This patch fixes one of my long-term gripes: xterm's selection + doesn't clearly show what's being selected (as per David's + request, it's controlled by a resource, which defaults to the + older behavior).

        + +

        Patch #26 - 1996/8/20 - + XFree86 3.1.2Ei

        + +

        Here's a patch to fix a problem with xterm's cut/paste and + another to modify the appearance of the highlighting while + selecting. (The changes are independent, so you can see if the + change to screen.c is desirable).

        + +

        Patch #25 - 1996/8/18 - + XFree86 3.1.2Ei

        + +

        Here's a correction for two minor bugs that I picked up in + testing, plus some lint (from Solaris 2.5) where NULL was used + incorrectly:

        + +
          +
        • make the second alternate font the same as the first + (that's what vt420 and dtterm do)
        • + +
        • corrected DECSCL report when DECSCL hasn't been set (i.e., + don't return a '60').
        • +
        + +

        Patch #24 - 1996/8/11 - + XFree86 3.1.2Ee

        + +

        This patch does several things. In effect, xterm can (I think) + do a reasonably good job of emulating vt220 and vt320 terminals + (as well as it was doing vt100, at any rate ;-).

        + +

        It does NOT do:

        + +
          +
        • soft fonts
        • + +
        • rigel or sixel graphics
        • +
        + +

        Anyway, I:

        + +
          +
        • added ECH, CPL, CNL, SU, SD, CBT, CHT controls
        • + +
        • added popup-menu for switching between DEC and Sun function + keys. (corrected alignment err wrt logging entry at that + point).
        • + +
        • make xterm recognize both 8-bit and 7-bit controls + (including popup menu for switching modes).
        • + +
        • add user-definable function keys (aka DECUDK)
        • + +
        • support concealed text
        • + +
        • support protected text (both ISO compatible and DEC + compatible - that's not the same thing, btw), with SPA, EPA, + DECSCA, DECSED, DECSEL controls.
        • + +
        • implement DECSCL.
        • +
        + +

        I'll be continuing to test this patch for a while, but don't + expect to add any new functionality (it passes all of the current + tests I've built in vttest, but I need to make more tests)..

        + +

        Patch #23 - 1996/7/31 - + XFree86 3.1.2Ec

        + +

        This removes the blinking cursor I added last week (for + performance reasons). Time-permitting, I'll revisit this after + 3.2 is released (there will be more work after XFree86 + 3.2, I assume).

        + +

        Patch #22 - 1996/7/26 - + XFree86 3.1.2Ec

        + +

        I looked more closely at my "double-negative" and realized + that I had been confused by the default color scheme (black on + white) in combination with reverse video. However, I did see that + the original_fg and original_bg data weren't really used - so I + removed that logic.

        + +

        Also:

        + +
          +
        • during initialization, check if ANSI colors are set with + non fg/bg values, disable color mode if not. This makes xterm + tolerant of applications that allocate the whole color + map.
        • + +
        • implemented blinking cursor (default is off)
        • +
        + +

        Patch #21 - 1996/7/24 - + XFree86 3.1.2Ec

        + +

        This patch does the following:

        + +
          +
        • fixes some minor typography in the control-sequences + documentation (it didn't occur to me til I'd sent the last + patch that I could use ghostview for previewing the troff + output ;-)
        • + +
        • adjusts the shell's background color in ReverseVideo so + that flicker in resizing is reduced
        • + +
        • adds an ifdef OPT_ISO_COLORS to allow configuring xterm + without the ISO color support (saves a lot of memory)
        • + +
        • used that ifdef to isolate/modify logic so that if the user + doesn't have the colorMode enabled, then ISO color support is + disabled (saving memory). + +

          (If anyone needs numbers, I had savedLines set to 2000, + and found a reduction from ~700k to ~400k of allocated + memory, according to Purify).

          +
        • +
        + +

        Patch #20 - 1996/7/24 - + XFree86 3.1.2Ec

        + +

        This documents the changes in control sequences for window + operations that I added in my previous patch. I'm testing another + patch that allows the user to use less memory if colors aren't + needed.

        + +

        Patch #19 - 1996/7/21 - + XFree86 3.1.2Ec

        + +

        This patch does the following:

        + +
          +
        • fixes the core dump that I reported on IRIX 5.2 (in main.c) + +

          (it's worth noting that this bug exists in X11R6.1, so I'd + like to assume that someone's already submitted a fix to X + Consortium...)

          +
        • + +
        • change the interpretation of zero rows or columns in a + resize-window request to use the root window's size (looking + more carefully at dtterm, that seems to be what it does).
        • + +
        • change some memmove calls to memcpy for slightly better + performance. also, a couple of memset calls to bzero, since + Quantify says bzero runs 20% faster, I assume because there's + one less argument.
        • + +
        • interpret character sets 1 and 2 (so that vttest gives a + reasonable result) Both rxvt and dtterm do something + equivalent.
        • + +
        • fix a minor memory leak in the logic that retrieves the + window or icon names (Purify found this for me while I ran + vttest).
        • +
        + +

        Patch #18 - 1996/7/18 - + XFree86 3.1.2Ec

        + +

        This implements the following:

        + +
          +
        • escape sequences that act like the CDE dtterm's window + operations (though I have implemented the default width and + height -- I've seen a rather buggy dtterm running that seems to + treat width=0 or height=0 literally -- maybe that's a feature, + not a bug?)
        • + +
        • minor tweak to the screen-repainting when resizing (I still + cannot entirely get rid of flicker).
        • + +
        • still more fixes to terminfo & termcap (I corrected my + error for the hpa code and added some other stuff by comparing + to ncurses' description and rxvt's).
        • + +
        • a tweak to the changes by Michael Rohleder for the color + translation
        • + +
        • re-order attribute codes to allow later implementation of + protected fields (dtterm supposedly does this; it's probably + more useful than blinking or invisible text -- that uses up all + of the available bits without changing the attribute scheme + radically).
        • +
        + +

        Patch #17 - 1996/7/2 - + XFree86 3.1.2Eb

        + +

        This patch implements for xterm several minor features from + ISO 6429 which are useful for terminfo applications. The HPA and + VPA control sequences allow cursor movement along a row or + column, cutting down a little on the characters transmitted. The + other codes allow resetting specific graphic rendition attributes + without modifying the other attributes. (now if someone just had + time to implement blinking cursors...)

        + +

        Patch #16 - 1996/6/25 - + XFree86 3.1.2Ea

        + +

        Adam Tla/lka <atlka@pg.gda.pl> told me a couple of weeks + ago that I'd missed some of the background coloring in xterm. I + investigated, and found that while I'd picked up on the + clear-to-bottom and clear-to-end-of-line operations, I'd + overlooked the insert/delete lines. Just so I wouldn't overlook + any more of these, I updated a copy of vttest to test ISO colors + and bce (background color erase). This patch introduces a new + function, ClearCurBackground, whose calls replace the direct + XClearArea calls that I'd overlooked. (There's also a few + compiler warnings fixed, etc ;-)

        + +

        Patch #15 - 1996/5/29 - + XFree86 3.1.2E

        + +

        This fixes the problem reported by David Dawes, by making the + 50msec select timeout for the Xaw3d arrow scrollbar a resource. + (I made it a boolean for a variety of reasons -- to make it a + number, you'd need an additional resource, to avoid breaking the + logic).

        + +

        Patch #14 - 1996/5/12 - + XFree86 3.1.2Dj

        + +

        This patch brings the termcap and terminfo descriptions for + xterm up to date. I made the following changes:

        + +
          +
        • reformatted the terminfo description in a single-column + (this is ok for terminfo, and will simplify future patches -- + can't do that for termcap, since it would impact buffer + requirements on some systems).
        • + +
        • omitted obsolete features in termcap to save a little space + (bs, pt)
        • + +
        • added color capabilities to termcap (ut, Co, NC, op, AB, + AF)
        • + +
        • corrected some capabilities (vi, ve)
        • + +
        • added 'st' (set tab)
        • + +
        • reduced function keys in termcap for 'xterm' to 12 because + color capabilities makes that description larger than 1023 + characters.
        • + +
        • created new termcap name 'xtermm' (monochrome) to match the + terminfo list, and make that description have 20 function + keys.
        • + +
        • added corresponding color capabilities to terminfo (bce, + colors, pairs, op, ncv, setab, setaf)
        • + +
        • corrected corresponding capabilities in terminfo (civis, + cnorm, rmcup, smcup)
        • + +
        • added capabilities (el1, hts)
        • + +
        • in both, corrected home/end keys to match the code + correction made by Thomas Mueller in 3.1.2Bk + +

          => (I'm still considering modifying the code & + description to match the rxvt program).

          +
        • +
        + +

        Patch #13 - 1996/4/23 - + XFree86 3.1.2Df

        + +

        This corrects my earlier changes for colors - the inner border + of the xterm was getting painted with the wrong color, since I'd + moved the call to set the background into the logic that tracks + SGR information.

        + +

        Patch #12 - 1996/3/16 - + XFree86 3.1.2Dc

        + +

        This corrects a memory leak in xterm that happens whenever one + switches fonts.

        + +

        Patch #11 - 1996/3/5 - + XFree86 3.1.2Db

        + +

        This patch corrects the behavior of the ANSI colors in xterm + when reverse video is used, as well as some other lesser + sins:

        + +
          +
        • button.c + +
            +
          • (compiler warnings: shadowing of 'time', redundant + cast)
          • +
          +
        • + +
        • charproc.c + +
            +
          • renamed screen.colors[] array to screen.Acolors[] to + more easily distinguish the non-ANSI colors from the ANSI + colors.
          • + +
          • moved logic of SGR_Save() into VTInitialize, getting + rid of local private variables original_fg and + original_bg.
          • + +
          • moved some logic into getXtermForeground and + getXtermBackground from SGR_Foreground, SGR_Background, + etc.
          • + +
          • corrected misleading 'row' to 'col' in case for CUF, + CUB sequences.
          • +
          +
        • + +
        • ctlseqs.ms
        • + +
        • xterm.man + +
            +
          • (correct a misconception which I'd added that the + color0 through color6 resource values apply to non-ANSI + colors)
          • +
          +
        • + +
        • ptyx.h + +
            +
          • added original_fg, original_bg to TScreen + structure.
          • +
          +
        • + +
        • scrollbar.c + +
            +
          • (compiler warnings: redundant cast)
          • +
          +
        • + +
        • util.c + +
            +
          • new functions getXtermForeground and getXtermBackground + replace the macros GET_FG and GET_BG, with the added + functionality of checking for the reverse-video status of + xterm.
          • + +
          • in ReverseVideo, swap the SGR foreground and background + colors also.
          • +
          +
        • +
        + +

        Patch #10 - 1996/2/14 - + XFree86 3.1.2Cd

        + +

        I observed an occasional glitch in the xterm's color behavior; + a clear to end of line would get a color that had been used in a + program that supposedly reset colors. I traced this down to the + way xterm was modifying colors of GC's on the fly; it didn't + restore the original color of the GC, even though it would later + be used in functions (such as ClearRight) that assumed (my error) + that the GC would have the current foreground or background + color.

        + +

        I fixed this by resetting the GC's colors with a new function + 'resetXtermGC()', and direct calls on + SGR_Foreground/SGR_Background, as appropriate and using a new + function 'updatedXtermGC()' to encapsulate the logic that + modifies the GC's color. (I also removed some commented-out code + that was trying to do this -- the problem was a little more + obscure).

        + +

        Patch #9 - 1996/2/10 - + XFree86 3.1.2Cb

        + +

        This patch fixes the remaining problems that I had making + xterm run with x11r5, as well as a couple of other bugs. It + follows my patch from yesterday, that added ifdef's for some of + the input-method resources.

        + +
          +
        • corrected ifdef's that suppress the input-method code + (doesn't exist in my x11r5, and xterm works adequately without + it).
        • + +
        • corrected fallback definition for 'Select()' macro (oops: + I'd copied the wrong text...)
        • + +
        • moved the declarations for the fd_set variables to + data.[ch]
        • + +
        • corrected an ifdef in resize.c (sunos 4.x doesn't have + termcap.h)
        • + +
        • corrected (in main.c) some unused/orphaned variables.
        • +
        + +

        Patch #8 - 1996/2/9 - + XFree86 3.1.2Cb

        + +

        This is mostly a documentation patch for xterm. It describes + the color control sequences in more detail, and documents some + other features of xterm that aren't described elsewhere.

        + +

        I've also added a couple of ifdef's to fix (part of) the + problem that I'm working on (making the program work properly on + x11r5, where I'm doing memory testing -- I have a "good" version + from mid-January, but my resync version doesn't work properly on + x11r5). I'm not done with that yet.

        + +

        Patch #7 - 1996/1/28 - + XFree86 3.1.2n

        + +

        I did a (clean) build of 3.1.2n on Linux 1.2.13 (ELF). I've + got an S3 card.

        + +

        This fixes the following in the 3.1.2n xterm:

        + +
          +
        • initialize cur_foreground, cur_background in charproc.c + (Purify told me they weren't initialized).
        • + +
        • add interpretation of codes 39, 49, to reset background and + foreground to default value (I'm told that ISO 6429 does this; + but I don't have a written reference -- yet -- can anyone help + here?). Anyway, rxvt does it, and it'll solve my remaining + color management problems.
        • + +
        • shadowing of 'time' in menu.c
        • + +
        • 'Cardinal' vs 'int' in scrollbar.c
        • + +
        • several changes to permit compile with X11R5 (the system + that I've got Purify on won't be upgraded to X11R6 for a long + time).
        • +
        + +

        I built this version (with a minor nit that I'll patch soon) + on SunOS 4.1.3 so that I can test it some more with Purify.

        + +

        btw: the changes made in Xpoll.h won't work on some + older systems, because fd_set isn't a defined type (I've got one + machine at least that this applies to).

        + +

        Patch #6 - 1996/1/8

        + +

        This patch does all of the SGR foreground/background fixes + (i.e., clearing the screen after an SGR color is set causes that + color to be used in the foreground and/or background). If the + FG_COLOR and/or BG_COLOR flags aren't set, then the xterm + foreground and background default to the window's values. This + usage is consistent with various types of hardware (especially + the IBM PC), and is also used in rxvt.

        + +
          +
        • charproc.c: + +
            +
          • add/use new macros GET_FG, GET_BG - n/c.
          • + +
          • add/use new functions SGR_Foreground() and + SGR_Background() to set corresponding colors in GC's, and + to retain sense of "original" colors. + +

            => This makes redundant some of the corresponding + logic in HideCursor to set the foreground and background, + but I left it in since it may be fixing an + unrelated requirement.

            +
          • + +
          • set GC's in LoadNewFont() according to whether the SGR + fg/bg colors are active. + +

            => This fixes some glitches in the accompanying + resize, that leaves parts of the window in the original + background color.

            +
          • +
          +
        • + +
        • screen.c: + +
            +
          • modified ClearBufRows() to use the SGR fg/bg colors if + they're set.
          • + +
          • added function ScrnClearLines(), used this to replace + portions of ScrnInsertLine() and ScrnDeleteLine(). The new + function uses the SGR fg/bg colors if they're set. + +

            => Otherwise, selection after an index or reverse + index will paint the wrong colors.

            +
          • + +
          • modified ScrnDeleteChar() and ScrnInsertChar() to use + SGR fg/bg colors.
          • +
          +
        • + +
        • util.c: + +
            +
          • modified ClearRight() so that if either of the SGR + fg/bg colors is set, we don't bzero the attributes and + color arrays, but instead fill them with the appropriate + codes.
          • + +
          • modified ClearLeft to use SGR fg/bg colors.
          • +
          +
        • +
        + +

        Patch #5 - 1996/1/7

        + +

        This patch modifies the object code, by replacing indexing + expressions with temporary variables with the full indexing + expression. At first glance, this seems inefficient (it did to me + ;-), until remembering comments made in the compilers newsgroups + that trying to "help" the compiler doesn't really work that well. + A good optimizing compiler can do a better job than the + programmer can. (There's a moral in the use of 'register' + variables also, but I won't fix those...).

        + +

        Anyway, the revised code generates a smaller object...

        + +
          +
        • charproc.c: + +
            +
          • recode index expressions in ShowCursor() and + HideCursor() using SCRN_BUF_xxxxS macros - changes + object.
          • + +
          • replace constant '4' by MAX_PTRS - n/c.
          • +
          +
        • + +
        • ptyx.h: + +
            +
          • defined the SCRN_BUF_xxxxS macros in terms of BUF_xxxxS + macros, to pick up references to ScrnBuf data directly, and + added MAX_PTRS symbol to pick up those '4' constants strewn + about the code - n/c.
          • +
          +
        • + +
        • screen.c: + +
            +
          • recode index expressions in ScreenWrite() using + SCRN_BUF_xxxxS macros - changes object.
          • + +
          • replace constant '4' by MAX_PTRS - n/c.
          • + +
          • use macros BUF_CHARS, BUF_ATTRS - n/c.
          • + +
          • cast calloc to 'Char *' to fix compiler warning on IRIX + - n/c
          • +
          +
        • + +
        • scrollbar.c: + +
            +
          • replace constant '4' by MAX_PTRS - n/c.
          • + +
          • cast calloc to 'Char *' to fix compiler warning on IRIX + - n/c
          • +
          +
        • +
        + +

        Patch #4 - 1996/1/7

        + +

        When setting up for this phase, I saw that you'd corrected the + bug that I found in ClearLeft. I decided to make this series of + patches anyway, since readability never hurt (and there's the + potential for finding another bug while reviewing this set).

        + +
          +
        • button.c: + +
            +
          • use SCRN_BUF_xxxxS macros - n/c
          • +
          +
        • + +
        • charproc.c: + +
            +
          • use SCRN_BUF_xxxxS macros - n/c
          • +
          +
        • + +
        • ptyx.h: + +
            +
          • added four macros: SCRN_BUF_CHARS, SCRN_BUF_ATTRS, + SCRN_BUF_FORES, SCRN_BUF_BACKS to represent the four arrays + that are derived from screen->buf.
          • +
          +
        • + +
        • screen.c: + +
            +
          • use SCRN_BUF_xxxxS macros - n/c
          • +
          +
        • + +
        • util.c: + +
            +
          • use SCRN_BUF_xxxxS macros - n/c
          • +
          +
        • +
        + +

        Patch #3 - 1996/1/7

        + +

        This is my third (and final cleanup) patch for xterm. It gets + rid of the unused stuff, and converts several functions to static + (thereby reducing their scope).

        + +

        At this point, the only compile warnings I've got (on Linux) + are those about the select arguments (int vs fd_set type), and a + missing declaration for waitpid. Those both are hard to get right + without autoconfigure.

        + +

        The next patches will address the functional changes...

        + +
          +
        • Tekproc.c: + +
            +
          • changed several functions to 'static' that aren't used + outside this module -- changes object
          • +
          +
        • + +
        • charproc.c: + +
            +
          • changed several functions to 'static' that aren't used + outside this module -- changes object
          • + +
          • deleted unused function unparsefputs -- changes + object.
          • +
          +
        • + +
        • main.c: + +
            +
          • changed several functions to 'static' that aren't used + outside this module -- changes object
          • + +
          • ifdef'd out unused function 'consolepr()' -- changes + object
          • + +
          • removed unused variable 'dummy_tio' -- changes + object
          • + +
          • moved variable 'discipline' to quiet unused-warning -- + changes object
          • +
          +
        • + +
        • main.h: + +
            +
          • deleted unused definition of DEFBORDERWIDTH - n/c
          • +
          +
        • + +
        • misc.c: + +
            +
          • changed several functions to 'static' that aren't used + outside this module -- changes object
          • + +
          • provide dummy return statements for xerror and xioerror + to quiet compiler warnings -- changes object
          • +
          +
        • + +
        • ptyx.h: + +
            +
          • change sbuf_address and abuf_address to 'Char *' - + n/c
          • +
          +
        • + +
        • resize.c: + +
            +
          • changed several functions to 'static' that aren't used + outside this module -- changes object
          • +
          +
        • + +
        • screen.c: + +
            +
          • remove unnecessary 'Char **' casts - n/c
          • +
          +
        • + +
        • util.c: + +
            +
          • changed several functions to 'static' that aren't used + outside this module -- changes object
          • +
          +
        • +
        + +

        Patch #2 - 1996/1/7

        + +

        This is my second patch to xterm. It corrects most of the gcc + warnings (except for some that are due to X header files ;-). I + compared objects to keep track of the changes that don't affect + the object code (n/c) versus those that do.

        + +

        At this point, I'm compiling (fairly) clean with gcc + options

        +
        +        -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Wnested-externs
         
        - It will not work properly if one xterm is in, say, ISO 8859-2. - Actually, for this case xterm breaks the ICCCM routinely (sending ISO - 8859-2 data as STRING), so I wouldn't worry too much about it. I have - not changed the behaviour in eight-bit mode in any way. -
        -
      - -

      Patch #106 - 1999/6/9 - XFree86 3.9Pq

      -
        -
      • remove duplicate fix for OpenBSD in resize.c - -
      • correct logic in ScreenWrite, which did not reset the high bytes - of 16-bit characters when overwriting them with a 8-bit character - string (reported by Thomas Wolff). - -
      • provide limited support for - input of UTF-8 16-bit data by a lookup table - (integrated patch by Markus Kuhn). - -
      • correct check in non_blank_line to ensure we're in wide-character - mode before looking at the high bytes, for InsertChar. -
      -

      Patch #105 - 1999/6/5 - XFree86 3.9Pp

      -
        -
      • implement new resource trimSelection, which allows xterm - to trim trailing blanks from selected lines. This does not affect - the highlighting. (reported by several people using mutt, - including - Hans Morten Kind <edphk@uib.no>, - Jeremy <jeremy@exit109.com> - and (Michael Fuller <msf@mds.rmit.edu.au>). - -
      • include term.h in resize for OpenBSD (patch by Matthieu Herrb). - -
      • correct logic for UTF-8 in functions that hide and show the cursor; - it was displaying a space whenever the low byte of the character at - the cursor position was zero (reported by Thomas Wolff - <Thomas.Wolff@icn.siemens.de>). -
      - -

      Patch #104 - 1999/5/30 - XFree86 3.9Pn

      -This is a resync patch against XFree86 3.9Pn, reflecting changes which were -submitted by Branden Robinson, who worked with -Wichert Akkerman <wichert@cs.leidenuniv.nl> -to set up ifdef's to handle GNU libc 2.1, -and use getpt() which lets xterm avoid having to know the actual PTY name. -

      -I have also added a few fixes for signed/unsigned mismatches, and corrected -a problem in the configure script (the UTF-8 code was always configured since -the Imakefile defines this). - -

      Patch #103 - 1999/5/14 - XFree86 3.9Pm

      -
        -
      • correct selection logic: I omitted an offset that accounts for - the distance into the scrollback buffer when rewriting this for - patch #101. Also fixed a similar problem for selecting double - size characters from the scrollback buffer (first was reported - by D Roland Walker <walker@pobox.com>). - -
      • improved support for Unix98 PTY's, using patch in Debian bug report - #35650, by J.H.M. Dassen <jdassen@wi.leidenuniv.nl>. From - the patch description: -
        -
          -
        • No longer links xterm against libutil on a glibc2.1 system. - libutil is a compatibility library and should only be used when - necessary. Rather than having get_pty() use openpty() from this - compatibility library, use the real UNIX98 pty support in get_pty() - (open()ing the master pty, through getpt() if available (glibc - extension)). Use openpty() only under glibc2.0. -
        • GNU libc2 is not Linux-specific; already it runs on the Hurd. It - provides the UNIX98 pty functions (plus the getpt() extension), - regardless of the underlying OS. Changed two constructs to look for - GNU libc2 only, not GNU libc2 on Linux. -
        -
        - -
      • improve font configuration, by checking if the user's resource - settings for normal and bold fonts give the same font sizes - (fixes problem reported by Peter Waltenberg <peterw@dascom.com>). -
      - -

      Patch #102 - 1999/5/12 - XFree86 3.9Pm

      -
        -
      • revert change to openpty call in patch #101; this causes xterm to - fail on DEC-Alpha OSF/1 4.0B (reported by H Merijn Brand). - -
      • modify print.c to move include of stdio.h after the autoconf'd - xtermcfg.h since HP's ANSI C compiler otherwise sees inconsistent - prototype for getopt, probably due to problem with const (reported by - H Merijn Brand). -
      - -

      Patch #101 - 1999/5/10 - XFree86 3.9Pm

      -
        -
      • moved includes and definitions for 'select' from data.h to xterm.h - to fix problem introduced by prototype for getPtyData, part of UTF-8 - changes (reported by Jens Schleusener <Jens.Schleusener@dlr.de>) - -
      • added "Meta <Btn2Down>:clear-saved-lines()" default - translation (patch by H Merijn Brand) - -
      • fixes to configure script and ifdef's in main.c to build on a - HP9000/D390 (hppa-2.0w) running HP-UX 11.00 (64 bit) with egcs 1.1.2 - and HP's ANSI C compiler (patch by H Merijn Brand - <PROCURA_BV@CompuServe.com>) - -
      • add more parentheses in ifdef's (patch by Bob Maynard). - -
      • eliminate conflicting definitions for USE_TERMINFO in resize.c - (reported by Jeremy Buhler). - -
      • change openpty call to pass NULL rather than ttydev parameter, - since that was used only to estimate the length of the - corresponding data, and may not really be long enough - (reported by Andreas Jaeger) - -
      • update description in xterm manpage for character class table, - which said it handles only 7-bit codes. - -
      • correct a typo in ScrnDeleteChar() which made it not clear the - high byte of wide-character data. - -
      • add logic to convert selection to UTF-8 form when appropriate. - This makes select/paste "work", but further work is needed to - make UTF-8 recognized as a locale in Xlib. - -
      • correct right-limit check when selecting double-width characters. - -
      • change default answerback response to an empty string. -
      - -

      Patch #100 - 1999/5/3 - XFree86 3.9Pl

      -
        -
      • Correct a typo in the default resource value for - backarrowKeyIsErase: it was always true (reported by Bram - Moolenaar). - -
      • improve configure script's test if the installed xterm is setuid, - in case that is a symbolic link. - -
      • correct "install-ti" rule in Makefile.in, by not setting a blank - $TERMINFO value. That is interpreted as "." by ncurses' tic. -
      - -

      Patch #99 - 1999/5/2 - XFree86 3.9Pk

      -
        -
      • correct logic that computes num_ptrs count of the number of indices - into the screen buffer. This is the maximum of the colors and - character-set indices; was incorrect in patch #97. - -
      • correct argument type for sigsetjmp, incidental change in patch - #96's Unix88 PTY patch (reported by Bram Moolenaar). - -
      • correct description of secondary DA in ctlseqs.ms (reported by Bram - Moolenaar). - -
      • decouple the backarrowKey and ptyInitialErase resources by - adding a new resource backarrowKeyIsErase, to accommodate people - using applications which have hardcoded tests for characters 8 and - 127 rather than relying on the stty settings. - -
      • modify the UTF-8 decoder so that all possible illegal UTF-8 - sequences are properly represented by U+FFFD. This should be very - helpful for developers of code that output UTF-8 strings for - debugging. See the file utf-8-test.txt in - http://www.cl.cam.ac.uk/~mgk25/download/ucs-fonts.tar.gz for a - demonstration text that contains numerous illegal UTF-8 values. - (patch by Markus Kuhn). - -
      • correct a place in ScrnRefresh where I was filling the high byte of - a wide character with a space rather than a null (reported by Markus - Kuhn). -
      - -

      Patch #98 - 1999/4/26 - XFree86 3.9Pk

      -
        -
      • correct data manipulation in unparseputc(), broken for - little-endian machines by patch #97's UTF-8 changes. This meant that - keyboard input on SunOS did not work, though Linux i386 was fine. - -
      • modify initialization for backarrowKey and logic for initial-erase - to prevent the initial-erase from overriding an explicitly set - backarrowKey resource (reported by Vikas Agnihotri). - -
      • add a missing null-pointer check in ScrnRefresh, for the - wide-characters configuration. -
      - -

      Patch #97 - 1999/4/25 - XFree86 3.9Pk

      -
        -
      • add configure script test for -lutil, needed for openpty call when - configuring xterm for Glibc-2.1 and Unix98 PTY's (first reported by - Martin Lorentz" <m.lorentz@w12.link-goe.de>). - -
      • completely parenthesize ifdef expressions for Glibc (suggested by - Bob Maynard). - -
      • add initial-erase options (-ie, +ie) to help message (reported by - Vikas Agnihotri). - -
      • remove duplicate definition of USE_USG_PTYS (reported by Jeremy - Buhler). - -
      • change termcap kD and terminfo kdch1 to a DEL - (\177). - I overlooked this when separating the styles of keyboard with - the sunKeyboard resources in patch #94, so that it normally - matches the value of the stty erase character: -
          -
        • Reported by Jae Gangemi <jgangemi@ccf.rutgers.edu>, - this caused emacs to not process the DEL properly, combining it - with succeeding characters. -
        • This does not appear to be related to a problem which I have - found with screen, which translates the stty erase into - the termcap kD or terminfo kdch1 value - (depending on how it is linked) - if the $TERMCAP variable is set when screen is invoked. -
        - -
      • add command-line options for enabling UTF-8 mode: -u8 and +u8. - The more obvious -utf8 and +utf8 would conflict with xterm's - -ut and +ut (utmp) options. - - The UTF-8 changes were requested by Markus Kuhn - <Markus.Kuhn@cl.cam.ac.uk>. This patch does not complete UTF-8 - implementation, but makes it usable, i.e., display and refresh work, - and I am able to display the test cases which Markus provides. - More work is needed to complete this feature: -
          -
        • the control sequences for switching in/out of UTF-8 mode are - partly implemented (don't use them). Similarly, the switching - between vt100 and tek4014 emulations when UTF-8 mode is enabled - will not work properly. -

          - You must use the -u8 command line option - to use this feature, as well as compile with the OPT_WIDE_CHARS - definition. -

        • cut/paste only copies 8-bit characters. -
        • logging is disabled in the wide-character configuration -
        • printing only writes 8-bit characters. -
        • input only does 8-bit characters. This is the area that I know - least about. -
        -
      - -

      Patch #96 - 1999/4/19 - XFree86 3.9Pj

      -
        -
      • modify Makefile.in to work with configure script's --srcdir option. - (patch by Jeremy Buhler <jbuhler@cs.washington.edu>) - -
      • add checks for 'echo -n' equivalent for 8colors.sh and 16colors.sh - scripts (reported by Vikas Agnihotri). - -
      • improve logic that looks for bold fonts to allow for wildcards - in the specification for normal fonts, and to ensure that if - a bold font is specified as normal, that xterm will simulate a - bold version of that using a one-pixel offset overstrike - (reported by Henrik Harmsen <harmsen@erv.ericsson.se>). - -
      • correct horizontal spacing of double width line-drawing characters - that xterm simulates. - -
      • improve support for Unix98 PTY's, using patch in Debian bug report - #35650, by Topi Miettinen <Topi.Miettinen@medialab.sonera.fi>. - Andreas Jaeger says this also corrects a permissions problem - reported by cat@zip.net.au - -
      • modify initial-erase logic to ensure that ttyModes - resource overrides it. -
      - -

      Patch #95 - 1999/4/5 - XFree86 3.9Ph

      -
        -
      • modify primary DA response to allow a '1' parameter. - -
      • add printer and national replacement character sets to VT220 - primary DA response. - -
      • document primary and secondary DA responses in ctlseqs.ms - -
      • use the patch number (e.g., 95) in the secondary DA response, - providing user applications a means of determining the version - of xterm for feature comparison (request by Bram Moolenaar). - -
      • make xterm respond to secondary DA when the decTerminalID - is set for VT100. - -
      • limit user-defined keys (DECUDK) to VT220-style keyboard - when sunKeyBoard resource is true. - -
      • modify ifdef's for Linux-2.2.x with Glibc-2.1 to work with - Glibc-2.1 and no Unix98 PTY support (patch from Andreas Jaeger - <aj@arthur.rhein-neckar.de>) - -
      • add optional feature (resource and command-line options) to make - xterm use the PTY's sense of erase character on startup, rather than - requiring it to be \177, or set the PTY's erase character to match - xterm's configuration. Note that while $TERMCAP is modified to - reflect the actual configuration, the terminfo kdch1 string is not - (request by Dirk H Hohndel <hohndel@suse.de>) - -
      • improve scripts in vttests to work with newer shells that do not - use 'echo -n'. - -
      • add fonts.sh example script - -
      • correct inequality in handling of "#1" font specification. - -
      • correct call to XGetWMNormalHints() used for computing maximum - screen size; the size hints may not have been set. - -
      • begin implementation of support for wide-characters (configure - option --enable-wide-chars defines OPT_WIDE_CHARS, invoke xterm with - -wc option to activate this feature). This patch optionally widens - internal data structures, invokes the 16-bit text output rather than - the 8-bit version and adds some tables. - -
      -

      Patch #94 - 1999/3/27 - XFree86 3.9Pf

      -
        -
      • further fixes for terminfo: ka1, ka3, etc., differ between the - default xterm-xfree86 and xterm-vt220 entries. - -
      • change default (with sunKeyboard resource false) behavior of - the editing keypad "Delete" to send a 127, like xterm-r6. - The VT220-style <ESC>[3~ is sent when - sunKeyboard is true (reported by Tomas Vanhala). - -
      • add parameters to function keys to indicate if shift, control - or alt are set. The codes are based on a description of - a DEC VT510 with a PC keyboard, from Jeffrey Altman - <jaltman@watsun.cc.columbia.edu>. - -
      • add control sequence 1035, set-num-lock action and num-lock - menu entry to control the use of the NumLock and Alt keys for - the Sun/PC and VT220 keyboard extensions. - -
      • implement DECSET/DECRST numeric keypad (DECNKM) mode. - -
      • modify terminfo and termcap to use recommended "X Window" or "X11" - names rather than "X Windows" (reported by Tomas Vanhala). - -
      • suppress translation of shifted keypad "+" when sunKeyboard - is true. - -
      • workaround unexpected behavior (perhaps bug) in XmbLookupString, - which returns trash in the string buffer for numlock and control-key - combined with keypad-keys. - -
      • modify ScrollBarReverseVideo() to keep scrollbar border visible - when reverse video is toggled. - -
      • correct missing case for parameter 17 (set highlight color) in - dynamic colors control sequences. - -
      • extend dynamic colors control sequences to allow users to - determine the colors and font which are currently active. - -
      • minor tweak to OSC responses, to use BEL if the application used - that to end the request, rather than ST. This works better with - shell scripts, which may not handle an - <ESC>backslash very well. - -
      • separate menu settings for reverse video from that done under - program control. - -
      • corrected ifdef's for menus, which did not allow tek4014 to - be suppressed properly (reported by Clint Olsen). - -
      • changes for Linux-2.2.x with GLibc-2.1 and - /dev/ptmx support (integrated patch from Pavel Roskin): -
          -
        • main.c and resize.c were using different rules to determine - whether ATT should be defined (actually USE_USG_PTYS is more - apt). - -
        • copy definitions from main.c to resize.c to prevent - sys/stream.h and sys/ptem.h from inclusion when SYSV is not - defined - -
        • define CNUL if not already defined like other variables. - -
        • /dev/tty does exist in Linux, but it doesn't mean, it - should be used. Therefore EACCES is now an acceptable - result. - -
        • ifdef'd several calls such as ioctl (ptyfd, I_PUSH, - "ptem") to build on Linux (I_PUSH is not defined when - sys/stropts.h is not included). -
        - -
      • initialize second "ltc" variable in main.c (reported by David - Dawes). - -
      • provide definition for USE_USG_PTYS in screen.c - -
      • add resource-files to install rule in standalone Makefile.in - -
      • add sample scripts to illustrate titlebar controls, resizing - and colors. -
      - -

      Patch #93 - 1999/3/14 - XFree86 3.9Pd

      -Here are several fixes and minor enhancements. The chief ones -are the fixes for NumLock mode and reverse video, since we had become -used to working around the problems. -
        -
      • remove kfnd/kll/kslt strings from terminfo, because curses - applications do not necessarily return khome/kend pairs - (reported by Vikas Agnihotri). - -
      • implement NumLock resource which overrides the keyboard tables for the - special case of keypad keys. This is a problem introduced in xterm - by X11R6 changes, i.e., an ambiguity which in effect discarded vt100 - keypad support. - -
      • modify Sun/PC keyboard mode to extend this (emulation of DEC vt100 - keypad) to the remainder of the numeric keypad. Now, the default - operating mode of xterm uses the keyboard tables as-is (except if - the NumLock mode overrides), but provides good vt100 keypad compatibility - if the Sun/PC keyboard menu item is checked. - -
      • separate command-line settings for reverse video from that done - under program control. This is a problem which was introduced by - X11R6. Though correct, most users are confused by allowing - the reset command to undo the effect of the command-line -rv - option. - -
      • add description of function keys, keypad and cursor keys to ctlseqs.ms - -
      • add terminfo entries for xterm-vt52, xterm-sun and xterm-hp - -
      • correct typo (missing case value) for DECSET 35, enable/disable - shifted keypad action and a few compiler warnings (reported by Zdenek - Sekera <zs@sgi.com>). - -
      • correct reporting of color values 8-15 in DECRQSS (reported by - Vikas Agnihotri). - -
      • modify parsing of ttyModes resource to recognize "^-" as "undef" - (requested by Tomas Vanhala). - -
      • integrate/extend changes to add iconify/maximize actions - (from Edward S. Arthur <eda@ultranet.com>). - -
      • add control sequences for maximizing/restoring window, and - for reporting maximum screen size. - -
      • add 'interpret' action, to support local function-key interpretation. - Used properly, this makes most of the specialized actions of xterm - redundant. - -
      • add control sequence private modes 1051, 1052 and 1052, for - setting the Sun and HP function key modes, and for setting the - Sun/PC keyboard mode. - -
      • add configure option --disable-maximize - -
      • add configure option --disable-num-lcok - -
      • extend descriptions of configure script options in INSTALL. -
      - -

      Patch #92 - 1999/2/5 - XFree86 3.9Nz

      -
        -
      • increase buffer size for tgetent (i.e., termcap) to 1500. This - fixes a problem where screen is built using ncurses or - GNU termcap and xterm is built using the standard termcap - interface. The former does not limit the termcap size, while the - latter is assumed to be no longer than 1023 characters. The - screen program's termcap entry is about 1200 characters - long. - -
      • change update_menu_item() to a function, to simplify debugging. - This also reduces the executable by 4Kb. - -
      • add control sequences for DECSET 30, 1010, 1011 like rxvt (enable - or disable some features that were only settable via resources or - command line arguments). - -
      • add control sequence for DECSET 35, which enables/disables the - shifted keypad functions. - -
      • add support for switching font sizes, by stepping through the - font menu using shifted keypad plus and minus. - -
      • correct missing initialization of tekInhibit and tekSmall resources. - -
      • correct ifdef's in charproc.c for XtNgeometry and XtCGeometry - (reported by Bram Moolenaar). -
      - -

      Patch #91 - 1999/1/21 - XFree86 3.9Nw

      -
        -
      • Implement logic to translate input characters which are mapped - when in vt220 National Replacement Character mode (requested by - Tomas Vanhala). - -
      • Resync configure scripts with my patches to autoconf 2.13 - -
      • Change order of -lXmu and -lXext to accommodate cygwin32 - (reported by Vikas Agnihotri). - -
      • Add "-ti" option to set terminal emulation level from command - line rather than via resource. - -
      • Simplify some of the preprocessor logic using #elif. -
      - -

      Patch #90 - 1998/12/13 - XFree86 3.9Nq

      -This implements several small fixes and enhancements. The chief one implements -fallback support for line drawing characters with fonts that do not include -those characters. But I implemented that last. - -
        -
      • If any of the glyphs in positions 0-31 (used by xterm to implement - the VT100 alternate character set) are zero-sized (i.e., missing), - xterm will reserve a normal space for the glyph when drawing. I - implemented a simple stroke-drawing function to draw the line-drawing - characters and a couple of the other (simpler) characters such as - diamond. (This was suggested by Vikas Agnihotri). - -
      • Modify the computation of doublesize characters to work around font - servers which shift the scaled characters up/down or do not give the - correct width. - -
      • Add popup menu item and corresponding resource settings to disable - the font-scaling logic for doublesize characters to work around - (older) font servers which simply do not draw the fonts scaled to the - size that they said they would. I see this problem on a SunOS system - running X11R5; the X11R6 servers seem well behaved. - -
      • Implement new escape sequence, private mode 1049, which combines - the switch to/from alternate screen mode with screen clearing and - cursor save/restore. Unlike the existing escape sequence, this - clears the alternate screen when switching to it rather than when - switching to the normal screen, thus retaining the alternate screen - contents for select/paste operations. - -

        When I implemented the popup menu entry to toggle between the normal - and alternate screens, I considered only pasting from the normal - screen to the alternate; this improvement allows either direction. - -

      • Changed the termcap and terminfo for xterm-xfree86 and xterm-8bit - to use the new 1049 private mode. - -
      • Modify the logic which switches between normal and alternate - screens so that the save/restore cursor operations apply only to the - current screen. That means that applications which use the terminfo - smcur/rmcur or termcap ti/te capabilities will restore the cursor to - the original position on the normal screen rather than to the most - recent place where a save-cursor operation was performed. - -

        I note that a real VT100 terminal would not behave in this way, - but it is a moot point since the VT100 does not implement alternate - screen, and therefore the save/restore cursor sequence would not be - used in this context. I reviewed the logic which switches between - normal and alternate screens based on some recent newsgroup postings - as well as a proposed patch in the Debian group which attempts to - do this (the patch has a bug, however, so I did not use it). - -

      • Add popup menu entry for toggling the titeInhibit resource. - -
      • Add new resource answerbackString, which overrides the default - "xterm" returned by xterm when responding to an ENQ (control/E) - character (request by Rajesh Vaidheeswarran <rv@fore.com>). - -
      • Add new resource keyboardDialect for setting the NRC display - character set (request by Tomas Vanhala, who notes that I should - add logic to translate the keyboard as well). - -
      • Add new command-line option and corresponding resources for making - xterm generate escape sequences compatible with HP terminals. Like - the existing Sun escape sequences, this is available as a popup menu - item. It is enabled by the configure script with the option - --enable-hp-fkeys (requested by Toni Mueller <sales@oeko.net>). - -
      • Add configure script option --disable-boxchars to disable the - fallback support for line drawing characters. - -
      • Fix ifdef's for configure script --disable-ansi-color, and reviewed - all configure options to ensure that all can be enabled/disabled - appropriately. - -
      • Update config.guess and config.sub, from Lynx. -
      - -

      Patch #89 - 1998/11/20 - XFree86 3.9Nm

      -This patch completes the implementation of double-sized character support -for the VT100 emulation, and fixes a few minor bugs: - -
        -
      • corrected the cursor position in HideCursor, which did not multiply -the column by two when in doublesize mode. -This bug, which did not appear in normal use, -dates back to my original changes to partly implement -double-sized characters. -I noticed it when cat'ing a typescript from vttest's double-sized character -test. -
      • ensure that the current line is repainted when switching between -single and double width characters. -
      • reduce the number of bits used for double-sized character coding -from 3 to 2, to make more room for soft-font codes. -
      • copy newer ifdef's from the XFree86 3.3.3 release's main.c, -which address details of glibc and powerpc. -
      • moved definition of DECL_ERRNO in xterm.h to match XFree86 3.3.3 -
      • modify resize to remove the ifdef on SVr4 that suppressed -printing the script for $LINES and $COLUMNS. -Solaris' resize utility does this; suppressing the behavior is unnecessary. -
      -I tested the double-sized characters using vttest and the xfsft patch. -These fonts worked reasonably well: -
      -	-bitstream-courier-medium-r-normal--0-0-0-0-m-0-iso8859-1
      -	9x15
      +
      +  

      (I also compiled with -Wshadow, but while that found some + things that I wanted to find, there's far too many warnings from + the X headers to be usable in this context).

      + +

      The changes:

      + +
        +
      • Tekproc.c: + +
          +
        • parenthesized expression to avoid gcc warning -- + n/c.
        • + +
        • corrected nested-extern declaration for Bool + waiting_for_initial_map; ourTopLevelShellArgs, and + number_ourTopLevelShellArgs - n/c
        • +
        +
      • + +
      • charproc.c: + +
          +
        • corrected potentially-unintialized variables 'scstype', + 'xim', and 'input_style' -- changes object.
        • + +
        • adjusted logic of VTparse so that gcc won't warn about + setjmp clobbering parsestate -- changes object.
        • + +
        • corrected initialization of 'scstype', which could have + been clobbered by setjmp/longjmp - changes object.
        • + +
        • corrected nested-extern declaration of 'term', + 'ProgramName' - n/c
        • +
        +
      • + +
      • cursor.c: + +
          +
        • corrected nested-extern declaration of 'term' -- + n/c
        • + +
        • renamed 'term' parameters to avoid gcc -Wshadow warning + - n/c
        • +
        +
      • + +
      • input.c: + +
          +
        • change interface of StringInput to assume size_t (i.e., + unsigned) nbytes -- changes object.
        • + +
        • change interface of funcvalue, and sunfuncvalue to use + 'KeySym' type instead of 'int' - changes object.
        • +
        +
      • + +
      • main.c: + +
          +
        • moved definitions of SIGNAL_T, SIGNAL_RETURN to proto.h + - n/c
        • + +
        • corrected missing params of 'do_hangup()' -- changes + object (note: the missing params were not used).
        • + +
        • corrected missing param of 'Error()' -- changes + object
        • + +
        • corrected nested-extern 'environ' - n/c
        • + +
        • adjusted assignments to 'tty_got_hung' and 'no_dev_tty' + so that gcc can see they won't be clobbered by the longjmp + - changes object.
        • + +
        • use Size_t type - n/c.
        • +
        +
      • + +
      • menu.c: + +
          +
        • removed redundant prototype for 'do_hangup()' -- + n/c.
        • + +
        • renamed 'time' parameters to avoid gcc -Wshadow warning + - n/c
        • +
        +
      • + +
      • menu.h: + +
          +
        • renamed 'time' parameters to avoid gcc -Wshadow warning + - n/c
        • +
        +
      • + +
      • misc.c: + +
          +
        • corrected definition of 'HandleFocusChange()' -- + changes object
        • + +
        • cast parameters in call to 'TekExpose()' -- n/c
        • + +
        • corrected nested-extern declarations of 'term', + 'toplevel', ProgramName, and 'environ' -- n/c.
        • + +
        • use Size_t type - n/c.
        • +
        +
      • + +
      • proto.h: + +
          +
        • moved definition of SIGNAL_T (and SIGNAL_RETURN) here + from main.c, resize.c to allow use of this symbol in + prototypes (mostly in xterm.h).
        • + +
        • added definition 'Size_t' to use as corrected type for + strncpy, malloc sizes - n/c.
        • +
        +
      • + +
      • resize.c: + +
          +
        • moved SIGNAL_T definition to proto.h -- n/c.
        • + +
        • use Size_t type - n/c.
        • +
        +
      • + +
      • screen.c: + +
          +
        • use Size_t type - n/c.
        • +
        +
      • + +
      • tabs.c: + +
          +
        • corrected nested-extern declaration of 'term' -- + n/c
        • +
        +
      • + +
      • util.c: + +
          +
        • corrected/supplied parameters to 'TekExpose()' -- + changes object (note: 'TekExpose()' doesn't use its + parameters).
        • + +
        • corrected nested-extern declaration of + 'waiting_for_initial_map' -- n/c.
        • + +
        • renamed 'term' parameters to avoid gcc -Wshadow warning + - n/c
        • +
        +
      • + +
      • xterm.h: + +
          +
        • prototype 'do_hangup()', 'HandleFocusChange()', + 'TekExpose()', 'Error()', 'Exit()' - forces changes in + various places.
        • + +
        • adjusted prototypes that pass 'Boolean' arguments to + use 'int' (this is the "correct" ANSI approach to extended + compiles; it's worth mentioning that gcc doesn't meet the + ANSI spec here). I used gcc -Wconversion to find these, but + there's a lot of unrelated warnings that are due to setting + NARROWPROTO in the config - n/c.
        • + +
        • renamed 'term' parameters to avoid gcc -Wshadow warning + - n/c
        • +
        +
      • +
      + +

      Patch #1 - 1996/1/6

      + +

      This is my first cleanup patch for xterm. It addresses all of + the gcc warnings for -Wall, -Wmissing-prototypes and + -Wstrict-prototypes that I can change without modifying the + object code. (I'm compiling this with gcc 2.7.0 for an aout + target, which makes it simple to compare objects. When I do + ELF-only, I've got a tool that compares that sort of thing as + well).

      + +

      Briefly, this patch adds (and uses) two header files in the + xterm directory:

      +
      +        proto.h
      +        xterm.h
       
      -The iso8859 font does not include box characters, of course, but looks good. -

      Patch #88 - 1998/10/31 - XFree86 3.9Nk and 3.3.2h

      -This refines my #85 patch by checking for a case where the font server -returns a bold font that does not quite correspond to the normal font. -When I asked for a bold version of the 6x12 font, the font server -returned a near equivalent where the ascent and descent values did not -match, causing xterm to leave lines across the display. -This patch makes xterm reject that type of mismatch, falling back to the -old font behavior. - -

      Patch #87 - 1998/10/21 - XFree86 3.9Nj and 3.3.2f

      -This corrects a problem reported by Stefan Dalibor. My table entries for the -printerExtent and printerFormFeed resources used the wrong -types for sizeof, causing the printer to not work properly on some platforms -because the printAttributes resource was overwritten (e.g., Digital Unix with DEC Alpha). -

      -I reviewed all of the resource table entries and fixed a potential problem with -resizeGravity, which was typed as int rather than -XtGravity. - -

      Patch #86 - 1998/10/14 - XFree86 3.9Nj and 3.3.2e

      -A small fix: when switching to/from the continuous mouse reporting mode, -the event mask was incorrect if xterm was built under X11R5 because the -original data was saved under an ifdef for active-icon. - -

      Patch #85 - 1998/10/12 - XFree86 3.9Nj and 3.3.2e

      -Some cleanup (I noticed the pixel droppings a few months ago after getting a -new 17" monitor): -
        -
      • split-out the functions that load/reload fonts for xterm as new - file fontutils.c to extend them to support automatic loading of - bold font corresponding to the normal font. Adapted logic from - EMU 1.3 for this purpose. This fixes most occurrences of pixel - droppings from bold characters. - -
      • modified by renaming variables and adding casts to permit compile - with g++. - -
      • modify headers so they can all be compiled without order - dependencies, and use bracketed rather than quoting includes to allow - compile from separate directory. - -
      • renamed xtermm terminfo entry to xterm-mono, to avoid conflict with - Solaris entry now in ncurses. -
      - -

      Patch #84 - 1998/10/9 - XFree86 3.9Ni and 3.3.2e

      -Several small fixes and enhancements, including a patch from -Bjorn Helgaas: -
        -
      • correct initialization of TERMCAP environment variable, which - was frequently set to garbage on non-Linux systems because - "termcap" and "newtc" contained random data from the stack. - -
      • remove the LINEWRAPPED attribute from lines as they are cleared. - Previously, the attribute was set but never cleared. - -
      • make word and line selections work even when lines are wrapped - by xterm. Previously, selections were limited to one screen line. -
      -as well as -
        -
      • modify logic for line-wrapping to reset the associated flag if - the application deletes a character. This fixes a problem reported - by Bjorn Helgaas where word/line selection would still wrap even - after deleting characters from the first line. -
      • add kll/kH capabilities to xterm-xfree86 entries in termcap and - terminfo (request by Michael Schroeder). -
      • shorten descriptions in termcap to make resolved entries all - shorter than 1023 character limit. -
      • use DECSTR control sequence to shorten initialization and reset - strings in xterm-xfree86 termcap and terminfo. -
      • use rmul/smul and rmir/smir in xterm-r5 terminfo to match termcap. -
      • correct typos in initialization and reset strings in xterm-r5 - termcap and terminfo. -
      • disable special translations of key symbols (the backarrow key, - the editing keypad and the keypad "+") when a modifier other than - shift, control or numlock is used. This makes xterm handle the meta - key as expected by people using emacs (reported by Pete Harlan - <harlan@pointofchoice.com> in linux.debian.user newsgroup). -
      - -

      Resync #83 - 1998/10/7 - XFree86 3.3.2e

      - -Merge changes through patch #83 with the 3.3.2e version. -

      -This follows a change from XFree86 CVS which adds checks for non-null -return from malloc (patch by Matthieu Herrb). - -

      Patch #83 - 1998/8/25 - XFree86 3.9Nb

      -Several small fixes and enhancements: -
        -
      • add configure test to infer if xterm should be installed setuid - based on previously installed xterm (reported by Stephen Marley - and Stefan Dalibor). - -
      • implement quasi-continuous mouse reporting - (integrated patch by Jason Bacon). - -
      • correct control sequences transmitted by function keys F1 to F4 - when sunFunctionKeys resource is true (it was still using the - VT100 control sequences). - -
      • modify handling of backarrow key so that the control modifier - toggles the backspace/delete interpretation set by the - backarrowKey resource. - -
      • limit the row and column values used to report mouse position. -
      - -From resync with XFree86 3.9Nb: -
        -
      • add support for the VSTATUS control character (patch by - Robert Earl <rearl@teleport.com>). -
      - -

      Patch #82 - 1998/7/15 - XFree86 3.9Aj

      -Bug fix for patch #81: -
        -
      • remove an #undef for NBBY, which caused compile problem on FreeBSD - (reported by David Dawes). -
      - -

      Patch #81 - 1998/7/14 - XFree86 3.9Aj

      -More bug fixes: -
        -
      • fix conflicting ifdef's for TIOCSLTC when building with Linux on - AXP aka DEC Alpha (reported by Robin Cutshaw). - -
      • correction to patch #79, move assignment for *utptr->ut_user = 0; - back into non-SVR4 ifdef in main.c, since this clobbers username on - Solaris 2.5.1 (analysis by Will Day - <willday@rom.oit.gatech.edu>). - -
      • corrected khome/kend in xterm-8bit terminfo description. - -
      • improve cursor color by making it always the reverse of fg/bg - unless the cursorColor resource is set, i.e., to something other than - the default foreground (reported by Vikas Agnihotri and Bram - Moolenaar). - -
      • minor fixes for compiler warnings, including a syntax error in - the AMOEBA ifdef's. -
      -From resync with XFree86 3.9Aj: -
        -
      • correction to patch #73, supply missing #else for fallback definitions - of size_t, time_t (Robin Cutshaw <robin@intercore.com>). -
      - -

      Patch #80 - 1998/6/29 - XFree86 3.9Ai

      -This fixes a couple of items leftover or introduced by patch 79: -
        -
      • take out the logic that suppresses editing-keypad in vt100 mode - (those keys are too valuable to give up for a fine point of - emulation). - -
      • corrected a couple of places in terminfo where I missed using the - vt220-style editing-keypad codes for Find/Select (mapped to Home/End). - -
      • checked termcap file against terminfo, fix several places where it - was inconsistent. -
      - -

      Patch #79 - 1998/6/28 - XFree86 3.9Ai

      - -This patch fixes several small bugs: -
        -
      • use X_EXTRA_LIBS in standalone Makefile.in (patch by Tomas Vanhala). - -
      • add new resource 'oldXtermFKeys' which provides backward compatibility - for F1-F4 control sequences with TOG's xterm. - -
      • determine the server's default foreground/background Pixel values, - needed if the -flipPixels X server option is used (reported by - David Dawes). - -
      • correct logic for F1-F4 function keys so that they generate VT100 - compatible escape sequences in VT220 mode, since that is what the - numeric keypad is supposed to do (reported by Ron Johnson, Jr. - <ronjohn@communique.net>). - -
      • modify logic for editing keypad to work more like VT220: don't - pass those codes in VT100-mode unless oldXtermFKeys mode is set. - -
      • correct an interaction with the editing-keypad logic that prevented - backarrow key from sending a 127 for the delete key (the 'remove' - escape sequence was being sent instead). - -
      • use return-value from getuid() rather than the parameter, to work on - systems which do not update the latter (patch by Kevin Buhr - <buhr@mozart.stat.wisc.edu>) - -
      • correct scrollbar border color when toggling to/from secure keyboard - mode (patch by Jeff Uphoff <juphoff@tarsier.cv.nrao.edu>) - -
      • modifications to terminfo file: -
          -
        • rename description to xterm-xfree86, adding an entry 'xterm' - which is derived from xterm-xfree86 to simplify customization. - -
        • change string for kdch1 from \177 to \E[3~, to address complaints - from Debian developers. (This applies to the key labeled "Delete", - and does not affect the backarrow key). - -
        • add user-strings u6, u7, u8, u9 to entries to make them work with - Daniel Weaver's "tack" program. - -
        • modify xterm-24, xterm-bold, xterm-boldso entries to disentangle them from - explicit dependency upon xterm-xfree86. - -
        • add generic 'xterm-color' entry. - -
        • minor corrections to xterm-xfree86, xterm-8bit, xterm-r5 and - xterm-r6 entries. -
        -
      - -

      Patch #78 - 1998/6/3 - XFree86 3.9Ah and 3.3.2

      - -Again, most of the bulk of this patch is for ANSI conversion. I used the -IRIX compiler's -wlint option to find the remaining functions that use -K&R syntax (since gcc does not do this properly). - -Also, I changed the logic in the print code slightly to close unwanted files -before opening a pipe to the printer. This may help in some configurations -where the line printer hangs until xterm closes the pipe. - -

      Patch #77 - 1998/5/26 - XFree86 3.9Ah and 3.3.2

      - -Most of the bulk of this patch is to convert the extended C (K&R functions -with prototypes) to ANSI. I verified that on Linux by comparing object -files, to ensure that I did not, for example, interchange parameters in -the function declarations. -

      -The rest of the patch fixes several minor bugs, and adds a few features: -

        -
      • back-out my use of ncurses "captoinfo -f" option (if/then/else/endif) - formatting, since ncurses did not correctly filter embedded newlines - in terminfo capability strings until _after_ ncurses 4.1, thus - corrupting setf/setb/sgr strings (reported by Darren Hiebert and - others). - -
      • document SGR 8, 28 (invisible/visible), add corresponding - capabilities to terminfo description. -

        - I would also add the 'prot protected capability, but the control - sequences for that would not be recognized or properly ignored by the - older xterm programs. - -

      • modify ChangeGroup to not suppress a null-resource, but treat it as an - empty string (recommended by Stefan Dalibor). - -
      • add printerAutoClose resource to control whether printer is closed - when going offline. More than one person reports problems (on - Solaris 2.6 and Digital Unix 4.0) getting the printer to proceed - unless xterm exits; I think that it is a problem flushing the pipe. - Closing it ought to flush it. - -
      • adapt TOG fix-3 to in HandleKeymapChange and VTInitI18N (but adapt - XtStackAlloc/XtStackFree for clarity, as well as fixing memory leak). - -
      • change calls on FillCurBackground to ClearCurBackground, in effect - using XClearArea rather than XFillRectangle when clearing as a - side-effect of scrolling and insertion (patch by Alexander V - Lukyanov) - -
      • correct some places where insert/delete did not _move_ the color - attributes, using memmove (patch by Alexander V Lukyanov - <lav@long.yar.ru>) - -
      • add ifdef's for __CYGWIN32__, for port to cygnus version B19.1 - (patch by Andrew Sumner <andrew_sumner@hotmail.com>). - -
      • remove #define for hpux that turned on USE_SYSV_ENVVARS, since this - causes some applications (such as 'less') to get incorrect $LINES and - $COLUMNS values (reported by Clint Olsen). - -
      • modify behavior for HP-UX, to set the "reserved" process group - controls to _POSIX_VDISABLE so the TIOCSLTC ioctl does not produce an - error (patch by Ben Yoshino <ben@wiliki.eng.hawaii.edu>). - -
      • correct length of underlining, reducing it by one pixel to avoid - leaving a dot when the application does not clear the whole screen - I noticed this only recently myself (and other people as well); it - depends on the font chosen. A 6x10 font shows it, but the other - fonts from XTerm.ad do not. I also see a similar problem with the - emulation of bold fonts. - (patch by Sergei Laskavy <Laskavy@cs.msu.su>). - -
      • add include for Xos.h to xterm.h, to ensure proper definitions - (reported by Holger Veit). - -
      • update config.guess to recognize Unixware 2.1 and 7 (patch by - Mike Hopkirk <hops@sco.com>). -
      - -

      Patch #76 - 1998/5/8 - XFree86 3.9Ah and 3.3.2

      - -A fix for the print-window function, and some minor cleanup: -
        -
      • modify logic that closes pipe in the print-window function to not use - pclose, which does not work on all systems, since I did not open the - pipe with popen (reported by Stefan Dalibor). - -
      • correct name of $(EXTRA_LOAD_FLAGS) imake variable (reported - by Stefan Dalibor). - -
      • guard logic in ChangeGroup() function against null pointer - (reported by Stefan Dalibor). - -
      • ensure that menu entry for toggling sunKeyboard resource is - initialized (reported by Branden Robinson <branden@purdue.edu>). - -
      • gcc unused-variable warnings (reported by Bernd Ernesti - <bernd@arresum.inka.de>) - -
      • rename global variable 'buffer' to 'VTbuffer' -
      - -

      Patch #75 - 1998/5/7 - XFree86 3.9Ah and 3.3.2

      - -This incorporates fixes from several people, as well as some improvements -that I made based on feedback from users: -
        -
      • add option to standalone configure script, "--with-own-terminfo-dir", - which causes xterm to pass a predefined value of $TERMINFO to the - application. Also use this value in install rule "make install-ti", - for the standalone configure script. - - (patch & feedback from Tor Lillqvist <tml@hemuli.tte.vtt.fi>) - -
      • change ifdef's for "hpux" to "__hpux" (patch by Tor Lillqvist). The - imake configuration uses the former, but the latter is predefined by - HP's compilers. - -
      • define USE_SYSV_ENVVARS for HP-UX, curses does not use $TERMCAP (patch - by Tor Lillqvist). - -
      • on HP-UX, use the /dev/ptym/clone device to allocate PTY's. Works - both on HP-UX 9 and 10. (patch by Tor Lillqvist). - -
      • modify configure script to obtain the $(EXTRA_LOADFLAGS) value from - imake, needed for compiling under DEC OSF/1 (reported by - Stefan Dalibor) - -
      • modify print-window action so that the printer is closed after - printing a window, unless the printer was already opened (i.e., - by an application running in the window). This makes the printing - complete without having to exit xterm, since not all systems treat - fflush through a pipe very well (reported by Stefan Dalibor) - -
      • modify printing code so that the ^M's are not printed if the - printAttribute resource is set to zero (request by Stefan Dalibor). - -
      • correct typo in xterm.man, for the default value of printAttribute - (reported by Stefan Dalibor). - -
      • correct printing code so that the alternate character set is - printed, like other attributes, with escape sequences. - -
      • correct termcap description, removing spurious 'm' character from - the 'op' capability (reported by Greg Woods <woods@weird.com>). - -
      • correct trace code so that the initial timestamp is set. - -
      • correct/modify utmp data for the Linux glibc 2 configuration, - so that the ut_line member is set before using it to update wtmp - (patch by Bill Nottingham <wen1@cec.wustl.edu>). -
      - -

      Patch #74 - 1998/4/27 - XFree86 3.9Ag and 3.3.2

      - -This corrects a couple of recent bugs and adds a new resource: -
        -
      • modify definition of TRACE_CHILD so that it does not conflict with - ifdef's for USE_USG_PTYS in main.c (reported by Vikas Agnihotri - <VikasA@att.com> and Stefan Dalibor). - -
      • correct ownership of file (actually pipe) written by the print - controls. When undoing the setuid changes in patch #69, I overlooked - this. Now xterm forks a process which resets setuid and routes the - printer data as the real user. - -
      • add a new resource, "printAttributes", which controls whether - color attributes (or any attributes) are sent to the printer. -
      - -

      Patch #73 - 1998/4/25 - XFree86 3.9Ag and 3.3.2

      - -This patch does the following: -
        -
      • implements a print-window facility for xterm. Though useful in - itself, I added it as part of some debugging which I am doing. - (Occasionally during an exposure event xterm fails to restore the - proper colors for highlighted text, and printing the screen will - show the internal states nicely). -

        - The print facility now also displays the color information. - (I will probably make this a resource). - -

      • modified the xterm-16color terminfo description to use the setaf and - setab strings, which is a little more efficient (requested by Stephen - Marley). - -
      • reduced some clutter of the ifdef/includes (e.g., stdlib.h, unistd.h, - errno) making the configure script test for these. -

        - I removed the symbols Size_t and Time_t, since they no longer serve - a useful purpose. - -

      • added some debugging traces to show the initial screen size, - and the success/failure of the ioctl calls pass handle window - resizing events to the application (for Clint Olsen). -

        - I also modified the trace code to produce two files since some - of the information is produced by the child process. So now - they are Trace-parent.out and Trace-child.out - -

      • updated configure test for ANSI compiler options to handle a - special case for HP-UX 10.x (reported by Clint Olsen). -
      - -

      Patch #72 - 1998/4/17 - XFree86 3.9Ag and 3.3.2

      - -This is a patch from Chris Siebenmann <cks@hawkwind.utcs.toronto.edu>, -which I have cleaned up a little, and integrated into the configure script. -

      -From his description: -

      - This set of patches is the latest incarnation of patches originally -written by Ian! D Allen, then of the University of Waterloo and now of -who knows where; I have been carrying them forward from xterm to xterm -ever since about X11R4. What they do is add an option so that when an -iconified xterm receives output it prepends '*** ' to its icon title -and (optionally) beeps the bell; deiconifying the xterm removes the -'*** '. Over the years I've found this to be incredibly convenient for -monitoring all sorts of low-activity things. -
      - -

      Patch #71 - 1998/4/12 - XFree86 3.9Ag and 3.3.2

      - -This patch is a slightly modified version of one by Richard Braakman, which -prevents buffer overflow in the input-method and preedit-type parsing in xterm. -I changed a couple of details to make the code more maintainable, and looked -for similar things - copying into a fixed-size buffer (found none, though I did -spot an unused variable). - -

      Patch #70 - 1998/3/29 - XFree86 3.9Af and 3.3.2

      - -This patch corrects some minor bugs in xterm, and fills in some more details -in the VT220 emulation: -
        -
      • modify Imakefile to use SpecialCObjectRule for menu and data modules, - making xterm build properly if logging is enabled - (patch by Scott Sewall <scott@iprg.nokia.com>). - -
      • restore "ich" capability to terminfo entries, since - Michael Schroeder points out that "ich1" - is the one which is the problem in Solaris vi. - -
      • correct color of cursor, which would disappear on inverse-video - since the initialization did not compare the cursor color against - both foreground and background (reported by Olivier Calle). - -
      • correct abbreviation-test for -version and -help options, making - command-line option -vb work (reported by Stefan Dalibor). - -
      • correct a dependency between ifdef's for OPT_I18N_SUPPORT and - OPT_INPUT_METHOD (reported by Stefan Dalibor). - -
      • split-out character-set translations as new module charsets.c, to - implement VT220 national replacement character sets (a mode where - some of the characters are displayed as specific European glyphs). - This relies on xterm using an ISO 8859-1 font (approach suggested by - Kenneth R. Robinette <zkrr01@mailbox.neosoft.com>). - -
      • correct a missing increment, which made SS2 and SS3 controls - repeat the shifted character. - -
      • add xterm-nrc to terminfo to illustrate the VT220 national - replacement character sets. - -
      • reformat terminfo using new ncurses tic option "-f", which makes - if/then/else/endif expressions easier to read. -
      - -

      Patch #69 - 1998/3/16 - XFree86 3.9Ad and 3.3.2

      - -This corrects the problem in xterm with utmp, reported by Olivier Calle -<olivier@tc.fluke.com> -as well as some other people after the XFree86 3.3.2 release. -

      -The error was introduced by my patch #53 in XFree86 3.9r (October 1997). -

      -The correction removes the reset of setuid/setgid before the main event loop, -and solves the problem which I had worked around in a different manner: for -some reason, the particular waitpid() call in creat_as() hangs, does not -return when the child process exits. I changed the ifdef's to force the Linux -configuration to use wait() instead. This call appears to work properly on -other platforms such as SunOS and Solaris. -

      -I also added tests in the standalone configure script to check for the -existence of waitpid(). - -

      Patch #68 - 1998/3/4 - XFree86 3.9Ad and 3.3.1z

      - -This corrects another problem with the logic for highlightColor resource. -As reported by David Dawes: -
      - I've just noticed a problem with with the "inverse" control sequence - (ESC[7m) with the 3.3.2 xterm. What it does is sets the background - black, and the text the usual foreground colour rather than simply - swapping the foreground/background. - -
      -This appears to be because when I added logic to check that the highlightColor -was distinct from foreground and background colors, I did not add a further -check to see that it was not black (I would make an explicit check for the -resource not being set, but see nothing definite in the headers that would let -me reference an explicitly-undefined Pixel value, though there are some -implications in xpm.h). But this should work. - -

      Patch #67 - 1998/2/23 - XFree86 3.9Ad and 3.3.1e

      - -This patch does the following: -
        -
      • improve test for highlightColor so that xterm does not attempt to - use that unless it is different from the foreground and background - colors (reported by Stefan Dalibor - <Stefan.Dalibor@informatik.uni-erlangen.de>. -

        - I could not reproduce this until I noticed that the -rev option - exposed it nicely. - -

      • remove ich and ich1 from xterm and xterm-8bit terminfo descriptions. - SVr4 terminfo documents that you must not combine these with - smir/rmir, but ncurses allows it, opening a hole. Solaris 2.6 vi - does not work properly if it is using a terminfo description when - these are combined, since it was written to accommodate old terminals - that required it (reported by Stephen Marley). - -
      • restore 1-pixel overlap of scrollbar border with left edge of window - (reported by Jim Burmeister <jimb@metrolink.com>). - -
      • add a configure option, --enable-logfile-exec, which allows the - user to specify a pipe for logfile. This defines ALLOWLOGFILEEXEC. - -
      • makes the ALLOWLOGFILEEXEC code compile & run, if configured. - -
      • minor documentation nits. -
      - -

      Patch #66 - 1998/2/16 - XFree86 3.9Ad and 3.3.1d

      - -This fixes the problem reported with failure to build the resize -program (BSDI, OSF/1) due to not having <termcap.h>, by changing the -ifdef to one that would be set only if the file exists (not currently -specified, except by the standalone configure script). We do not really need -to include <termcap.h> to build, but only for a clean compile, since it -may declare the tgetent() prototype. - -I also updated the man-page for resize, since I had recently noticed -that it can be used to resize xterm using the "Sun" control sequences -option. - -

      Patch #65 - 1998/2/14 - XFree86 3.9Ad and 3.3.1c

      - -This is a small patch to xterm's 8-bit terminal description. I noticed -while testing ncurses that I had specified the wrong (VT100-style) codes -for the F1-F4. Xterm only uses VT220-style function keys in 8-bit mode. - -

      Patch #64 - 1998/2/8 - XFree86 3.9Ad

      - -This fixes the following problems with xterm: -
        -
      • save/restore the ANSI foreground and background colors with the other - visible attributes in the save-cursor and restore-cursor operations. - This works around a problem with vim, which apparently assumed that - switching between the normal and alternate screens resets the colors - (reported by Jim Battle <jb@chromatic.com>). -

        - It would be nice to implement save/restore cursor as a stack (and - solve this type of problem completely), but that would lead to - incompatibility with applications which assume they are running with a - VT100 or VT220. - -

      • corrects behavior of a restore-cursor operation which does not - follow a save-cursor (it is supposed to set the character sets - to a known initial state). - -
      • extends the sunKeyboard resource (and menu toggle) to modify the - home, end and delete keys on a Sun or PC editing keypad, making them - generate codes compatible with DEC VT220's Find, Select and Remove - keys. - -
      • corrects a length in checking command-line options, which caused the - "-help" message to not work when X was not running. - -
      • add some detail to the man-page (requested by Jason Bacon - <acadix@execpc.com>) - -
      • modify the standalone configure script to ignore the broken nsl and - socket libraries on IRIX 6.2 (the ones on 5.2 also are broken, so - this change just widens the check for the system version number). -
      - -

      Patch #63 - 1998/2/5 - XFree86 3.9Ad

      - -This is another patch from Bjorn Helgaas <helgaas@rsn.hp.com>, which I've -reviewed (and learned some). Following are his notes: -

      -I poked around some more and finally got xterm-62 to build and run -cleanly on HP-UX 10.20. Here are the patches. They look sort of -ugly, so here's a little explanation: -

        -
      • aclocal.m4: Removed side effects from the AC_CACHE_VAL - commands in CF_FUNC_TGETENT. Previously, LIBS was set inside - AC_CACHE_VAL, which worked fine the first time configure was - run, but failed if there were cached values. - -
      • aclocal.m4: Added temporary setting of LIBS before - AC_TRY_LINK in CF_FUNC_TGETENT. Previously, the last value set - by the AC_TRY_RUN loop was used, so only -lcurses was checked. - -
      • configure.in: Added temporary setting of CPPFLAGS before - AC_CHECK_HEADERS for X11 files. Previously <X11/DECkeysym.h> - and <X11/Xpoll.h> were found only if they were in the compiler's - default include directories, even if `--x-includes=DIR' had been - used or AC_PATH_XTRA had found them elsewhere. -
      -The problem on HP-UX was that we were linking with -lcurses rather than --ltermcap due to the second bullet above, and apparently something in -HP-UX curses is broken. This seems very strange, because the only thing -used is tgetent, which should affect any tty/pty configuration, but I -lost interest in tracking down the exact problem. - -

      Patch #62 - 1998/1/23 - XFree86 3.9Ac

      - -This is a patch mostly by Bjorn Helgaas <helgaas@dhc.net> (I added the -os2main.c change, and a little of the documentation). From Bjorn's -description: -
        -
      • If you use the "-hc <color>" option or set the "highlightColor" - resource, text is highlighted by changing only the background color, - rather than using reverse video. I find this easier to read, - especially when selecting multi-colored text, and it is similar to - the way Netscape shows selections. - -
      • Most of the code changes are under "#if OPT_HIGHLIGHT_COLOR". The - principal exception is in screen.c, where I added a couple calls to - resetXtermGC(). This seems like it could be a bug even without - the color highlighting changes (though I don't pretend to understand - all the logic). -
      - -

      Patch #61 - 1998/1/17 - XFree86 3.9Ac

      - -This patch modifies the reset behavior of xterm slightly: -
        -
      • change the terminfo entry so that rs1 (one of the strings used by - the 'reset' program) does a hard reset rather than switching - character sets. This is more in accord with other terminal - descriptions. - -
      • modifies the treatment of hard reset by the xterm program to - reset the saved lines. - -
      • corrects hard reset by also resetting user-defined keys, i.e., DECUDK. -
      - -

      Patch #60 - 1998/1/10 - XFree86 3.9Ab

      - -This fixes some minor bugs and adds new functionality: -
        -
      • add support for blinking text. -
          -
        • This does not actually cause the - text to flash, but text with the blink attribute can be displayed - in color, using new resources colorBL and colorBLMode. - -
        • If colors are not used, the blinking text will be displayed as - before (just like bold). The main purpose of this is to make - applications work properly when they assume the emulator supports - blinking text. - -
        • I did this by moving the per-cell LINEWRAPPED flag to a per-line - flag, to make room for the new BLINK flag. There were no per-line - flags, so this changes a lot of logic. -
        - -
      • corrected missing save-cursor logic in the handling of SGR 1048 - (the new control sequence I added in patch #54, 1997/10/17). - Reported by Darren Hiebert. - -
      • flush the output of the transparent printing after each line - Reported by Tomas Vanhala <vanhala@ling.helsinki.fi>. - -
      • correct the modes that are affected by save/restore cursor by adding - WRAPAROUND and PROTECTED. - -
      • corrected placement of one of the XSync calls that I added in patch - #51, 1997/9/15, which had the side-effect of writing on the window - border when the xterm was resizing from 132 to 80 columns. - -
      • work around an incompatibility of the XKB definition used in xterm - versus that symbol from IRIX 6.2's imake definitions (by adjusting - the standalone configure script). -
      - -

      Patch #59 - 1998/1/5 - XFree86 3.9Ab

      - -My last patch has an off-by-one error in the comparison for argc. Douglas -Kosovic <douglask@dstc.edu.au> showed me where (he got a core dump). -Also, I think this explains Clint Olsen's problem, but the symptoms were more -subtle (EINVAL for a system call if the -display option is omitted). - -

      Patch #58 - 1998/1/3 - XFree86 3.9Ab

      - -This patch does the following: -
        -
      • implement logic to permit xterm to work with proportional fonts. -
          -
        • Thomas Wolff - <Thomas.Wolff@sietec.de> - requested this (but it isn't exactly what he's asking - for - that's a more involved task). - -
        • I chose to do this by rendering the characters on a fixed pitch, - because it would not be useful for existing applications to display - varying numbers of characters on each line. - -
        • Except that this forces the display to be wider, it works reasonably - well. A couple of special cases (reverse + colorBD, for example) - do not display with proper colors, since the inter-character gaps - are painted with the background. -
        - -
      • added a version number to the program (several people have requested - this). - -
      • make the -version and -help options interpreted before the program - attempts to open the display. - -
      • minor reorganization of the man-page (ordered the options, resources - and translations alphabetically - and eliminated some duplication). - -
      • corrected a misspelled filename in Makefile.in, and added a lint - rule. - -
      • updated the configure script to correct behavior when it cannot - find imake, as well as to fix the IRIX+gcc build (conflict with - /usr/include). - -
      • regenerated the configure script with a newer patch to autoconf - that fixes a problem with environment space vs the configure --help - message. -
      -

      Patch #57 - 1997/12/26 - XFree86 3.9Aa

      - -This patch is mostly concerned with the standalone configure script; a few -minor corrections are added: -
        -
      • add configure option --disable-tek4014, to allow xterm to be built - without the tek4014 emulation. - -
      • add configure option --with-terminal-type, to allow xterm to be - compiled with default $TERM value other than "xterm" (e.g., - "xterm-16color") -- requested by Stephen Marley <stephen@memex.com>. - -
      • fix a typo in the configure --help message -- reported by Darren - Hiebert <darren@hmi.com>. - -
      • review diffs between main.c and os2main.c, to make them more alike. - (applies some minor bug-fixes to OS/2's version). - -
      • add missing quotes in memmove/bcopy configure test -
      - - -

      Patch #56 - 1997/11/28 - XFree86 3.9x

      - -This patch is based on analysis by Arfst Ludwig <arfst@luxor.IN-Berlin.DE>, -who reported: -
      - Setting the following resources xterm (all current versions) receives a - segmentation fault on <Btn2Up> after scrolling: -
      -
      -	  *XTerm*VT100*translations:    #override \
      -	      ~Shift~Ctrl<Btn2Up>: insert-selection(PRIMARY, CUT_BUFFER0)\n\
      -	      Shift~Ctrl<Btn2Up>:  insert-selection(CLIPBOARD, CUT_BUFFER1)\n\
      -	      ~Shift<BtnUp>:       select-end(PRIMARY, CUT_BUFFER0)\n\
      -	      Shift<BtnUp>:        select-end(CLIPBOARD, CUT_BUFFER1)
      -
      - (The above resources intention is to be able to paste the latest - selection even if the xterm was cleared.) -

      - And here is how it works (and a fix!): The widget given to the action - handler as first argument is not guaranteed to be a XtermWidget (it can - be the ScrollbarWidget). Instead of accessing the widget's member - directly XtDisplay gives the required pointer in a safe way. -

      -I noticed that this was not the only instance (by reading the code, and testing -with his example), and extended the solution to check the widget-class to -ensure that it is indeed xterm's widget class before attempting to use it in -the context of translations. - -

      Patch #55 - 1997/11/25 - XFree86 3.9x

      - -This fixes the segmentation violation noted by Rogier Wolff about a month -ago. He'd set xterm to 400 (rows) by 150 columns, which broke because there -were limited buffers (200 rows) used for juggling data when adding or deleting -lines and for switching between alternate and normal screens. I replaced this -by an allocated buffer. -

      -The bug is simple to test if you set titeInhibit false. - -

      Patch #54 - 1997/10/17 - XFree86 3.9s

      - -This patch does the following: -
        -
      • correct a minor placement problem with the right scrollbar. - -
      • implement a new set of control sequences for switching between the - normal and alternate VT100 screens. These work around the older - sequences limitation that required modification of the runtime - $TERMCAP to cooperate with the titeInhibit resource (that can't work - with terminfo). I do this by moving all of the functionality of the - rmcur terminfo capability into the control sequences. - -
      • implement the alternate-screen menu entry -
      - -

      Patch #53 - 1997/10/12 - XFree86 3.9r

      - -This patch adds a fix and implements a new feature (as well as some minor -typos): -
        -
      • JCHANDRA@Inf.COM (JCHANDRA) noted that there was still a problem - with the wait call with the logging option. It hung when the logfile - was opened as a command-line option. I fixed this by moving the - StartLogging() call down past the place where I'd reset the setuid - mode. So the logfile is opened as the real user, without having - to fork. - -
      • improve Rohleder's changes by - renaming the command-line options and reducing the number of ifdef's. - -
      • implement right-scrollbars for xterm - (patch by Michael Rohleder <michael.rohleder@stadt-frankfurt.de>). -
      - -

      Patch #52 - 1997/9/29 - XFree86 3.9q

      - -This patch addresses bugs and requests reported by -
        -
      • Bob Maynard <rmaynard@montana.com>, -
      • Clint Olsen <olsenc@ichips.intel.com>, -
      • JCHANDRA@Inf.COM (JCHANDRA), -
      • Michael Schroeder <Michael.Schroeder@informatik.uni-erlangen.de>, -
      • Pablo Ariel Kohan <pablo@memco.co.il> -
      - -Some of the changes are interrelated (it was an unusually busy week). -
        - -
      • change the default resource value for colorMode to true, matching - the Xterm.ad file. - -
      • correct behavior of 'ech' control, making the default and 0 - parameters erase one character rather than to the end of line - (reported by Michael Schroeder). - -
      • add resource boldColors, command-line options +pc and -pc and - configure-script option to specify behavior of xterm's mapping bold - colors 0 through 7 to colors 8 through 15. - (request by Pablo Ariel Kohan). - -
      • add resource colorAttrMode to specify whether colorULMode and - colorBDMode can override the ANSI colors - (report by Clint Olsen). - -
      • correct a conflict between colorULMode/colorBDMode versus ANSI - colors, where exposure events would occasionally pick up the - former (e.g., colorBD) rather than ANSI colors. Testing the - colorAttrMode made this apparent, though it has been in the - code since 3.2A (patch #35 in Jan 1997). - -
      • correct two problems with the optional logging support. On Linux - at least, the waitpid call in creat_as hangs when the logging is - toggled from the popup menu. Also, the mktemp template has the wrong - number of X's (since X11R5!). Fixed the waitpid problem by - exploiting the fact that the setuid behavior is reset before the - popup menus are available. - (reported by Jayachandran C.). - -
      • add configure script options for building with the Xaw3d and neXtaw - libraries. - -
      • correct CF_IMAKE_CFLAGS standalone configure script macro, so that it - will pick up $(ALLDEFINES) rather than $(STD_DEFINES). This is - needed to make scrollbars work on Linux, since that uses narrow - prototypes. - (reported by Bob Maynard). - -
      • various minor updates to configure-script macros. -
      - -

      Patch #51 - 1997/9/15 - XFree86 3.9p

      - -Most of this patch is related to the standalone configure script, though -there are fixes/enhancements as well: -
        -
      • add a new resource sunKeyboard, with associated command-line - option and menu-toggle that allows using a normal Sun or PC - keyboard to generated the complete DEC-style function keys - and keypad. - -
      • correct a reversed foreground/background test in the control - sequence that replies with the current SGR settings. - -
      • correct, by invoking XSync, a display problem that caused the - program to not properly update newly exposed areas when a font - change or 80/132 resize request was not completely accepted. - -
      • restructured autoconf macros (I made a library of all of the - macros across the complicated configure scripts I'm working on). - -
      • use the autoconf config.guess and config.sub scripts to better - identify the host-os. - -
      • improve the configure script that uses 'imake' as a fallback for - definitions. - -
      • correct several instances of unsigned/signed mixed expressions. -
      - -I've tested the configure script on Linux, SunOS 4.1.3, Solaris 2.5.1, -IRIX 5.2 and 6.2, AIX 3.2.5 and CLIX 3.1 (all but the last run properly -as well). - -

      Patch #50 - 1997/8/22 - XFree86 3.9m

      - -This is a collection of small fixes, and a couple of minor enhancements: -
        -
      • plug a security hole in the implementation of Media Copy (print) - by invoking setuid just before the main loop. - -
      • add an ifdef'd include for <sys/termio.h> for HP-UX, which allows - the program to process SIGWINCH events (this is a bug in X11R6.3) - -
      • add state-table entries for VT52 emulation to enter/exit keypad - application mode. - -
      • disable the popup-menu entry for 8-bit controls when the terminal-id - is less than 200 (e.g., VT52 or VT100). - -
      • ensure that the popup-menu entry for 8-bit controls is updated when - the application enables/disables this mode, including the response - to a full-reset. - -
      • implement VT300 DECBKM feature: set interpretation of the backarrow - key to either backspace or delete. The initial setting is via - resource; it can also be modified in the main popup menu. - -
      • implement VTxxx KAM (ISO AM), which allows a keyboard to be locked - (i.e., the terminal discards input). - -
      • implement VTxxx SRM, which is used to control local echoing of - input on the terminal. - -
      • add terminfo and termcap entries for xterm-8bit, a variation of - the xterm description that uses 8-bit control characters. - -
      • add fallback definitions for Imakefile to allow it to work on some - X11R5 systems that have no SpecialCObjectRule or ProgramTargetName - macros. - -
      • add .c.o and .c.i rules to standalone Makefile.in - -
      • correct order of -lXmu and -lXext in standalone configure script. - -
      • add configure script options to allow selective disabling of - active-icon, input-method and i18n code (mainly for users with X11R5 - or an incomplete X11R6 configuration). - -
      • change menu-indices from #define's to enum values, thereby making - it work better with the ifdef's for logging and active-icon (the - X11R6.3 active-icon code is incorrectly ifdef'd; this corrects an - error introduced by incorporating that code). - -
      • correct minor compile errors in the configuration where active-icon - is not used. - -
      • add configure option to suppress echoing of long compiler commands - -
      • correct spelling of decTerminalID in configure script help message - -
      • use gcc __attribute__((unused)) to quiet warnings about unused - parameters when compiling with -W (to make it simpler to find the - real problems). -
      - -

      Patch #49 - 1997/8/10 - XFree86 3.9k

      - -This patch implements the VT100/VT220 Media Copy (i.e., print-screen) control -sequences. - -

      Patch #48 - 1997/7/26 - XFree86 3.9j

      - -This patch does the following (all but the first affect only the standalone -configure script): -
        -
      • minor correction to positioning of underlines for small (e.g., 5x8) - font size. -

        - The existing behavior allowed underlines to be drawn outside the - character-cell, so they weren't cleared properly under some - circumstances. - -

      • adds more special-case tokens to the standalone configure script's - imake-option filter (e.g., "&&", since a "make -n main.o" on my IRIX - system uses that shell construct). - -
      • adds a '--enable-logging' option for the standalone configure script. - -
      • adds check and ifdef's for the standalone configure script to allow - for building on platforms with X11R6, which lacks Xpoll.h (introduced - in X11R6.1). -
      - -

      Patch #47 - 1997/7/13 - XFree86 3.9i

      - -This patch does the following -
        -
      • corrects an indexing error in the doublesize character logic - (button.c) that caused core dump (this was reported by J. Wunsch). -
      • corrects the logic of ShowCursor when it is painting in a doublesize - cell (charproc.c). -
      • corrects, according to vttest, the behavior when switching to - doublesize characters and back again (doublechr.c). -
      • adds cbt (back_tab) to the terminfo description (this was something - that I'd overlooked as applicable to curses optimization last - summer). -
      • corrects, for the standalone xmc test, the logic for disabling xmc. -
      - -

      Patch #46 - 1997/7/4 - XFree86 3.9h

      - -This is a patch to provide test-support for some work I'm doing on ncurses. It -does not modify the normal configuration of xterm; the code is compiled if the -standalone configure option "--enable-xmc-glitch" is specified. - -

      Patch #45 - 1997/7/2 - XFree86 3.9h

      - -This fixes the problem reported with xterm's cursor color versus the background -(the second chunk in this patch) and also removes some duplicate initialization -of the cursor GC's. If the cursor color at startup is the same as the -background, then xterm will use the reverse GC, ignoring the setting of the -colorMode resource. - -

      Patch #44 - 1997/6/22 - XFree86 3.9g

      - -This implements the first part of the VT100 doublesize characters for xterm, -as well as fixing a handful of bugs: -
        -
      • the doublesize character support uses the normal font (using scaled - fonts will be another patch) with blanks to simulate doublesize - characters. This patch does most of the global changes that'll be - required. I've hidden most of the details in macros and ifdef's so - it's easy to configure out (part of the patch is a configure option - for that purpose). - -
      • corrected limits in DeleteChar() function -- it's always ignored the - size of the left border and scrollbar. I noticed this when working - on the doublesize characters since the glitch was doubled in size - (i.e., it wrapped some garbage around the right margin). - -
      • corrected 'memmove()' logic, for standalone builds (it referenced a - malloc wrapper from my development library). - -
      • add a check for HideCursor() to prevent repeated screen updates - (which can cause a spurious cursor glitch to appear, e.g., during - scrolling). I noticed this with the 3.2A version (but only a few - weeks ago, when I started working on this patch). -
      - -

      Patch #43 - 1997/6/10 - XFree86 3.9d

      - -Here's a fix for two problems: -
        -
      • modify handling of tgetent results in xterm and resize programs to - make them tolerant of missing termcap file, or unknown terminal name. - In this scheme, an explicit "-tn" option will succeed, overriding - the fallback list. - -
      • a nit in the configure script (log extra information to help diagnose - which case of the test-compile of tgetent was used). -
      - -

      Patch #42 - 1997/6/8 - XFree86 3.2Xl

      - -Bram Moolenaar reported that the cursor color changed unexpectedly while -scrolling. The cause was that it used the same GC's as the logic that draws -the ANSI colors. The bug only appears if the cursorColor resource isn't set, -and has been present since the initial implementation early last year. (The -same bug also appears in rxvt ;-). Here's a fix. - -

      Patch #41 - 1997/5/28 - XFree86 3.2Xl

      - -Some nits found by Darren Hiebert (missing part of install-rule, incorrect -assignment for --enable-color-mode option). - -

      Patch #40 - 1997/5/26 - XFree86 3.2Xl

      - -Patch for the configure script's logic for obtaining imake predefined -symbols. - -

      Patch #39 - 1997/5/24 - XFree86 3.2Xl

      - -This patch does the following: -
        -
      • integrate the 16-color change for 'xterm' - -
      • minor fixes/clarification of tgetent in terminfo vs termcap to - 'resize' -
      - -(both changes also modify the configure script) - -

      Patch #38 - 1997/5/22 - XFree86 3.2Xh

      - -This implements a simple configuration script with autoconf (to which I'll -add more options later). It does the following: -
        -
      • configures xterm to build with X11R5 (at least on SunOS 4.1, Solaris - 2.4, possibly IRIX - sorry network was down today, but I did test - an earlier version yesterday). - -
      • enables/disables the configuration ifdef's for ANSI color and VT52 - emulation. -
      -It does not make tests for the things that imake does (that's another project), -instead it uses a hybrid of the autoconf tests for libraries and adds imake's -compiler options (which are necessary in some cases to get main.c to compile). - -

      Patch #37 - 1997/5/7 - XFree86 3.9a

      - -This corrects a minor, but annoying error in the vt220 emulation: the DECUDK -is only supposed to be interpreted for _shifted_ function keys. - -

      Patch #36 - 1997/1/16 - XFree86 3.2r

      - -This corrects something that I overlooked in patch #27 (21-aug-1996), which is -that when trimming the region to be repainted for the highlightSelection -resource of xterm, I still have to paint the background past the highlighted -region. This only happens when I first do a selection in a window that's -partly off-screen, then move the window on-screen. - -

      Patch #35 - 1997/1/7 - XFree86 3.2o

      - -This patch does the following: -
        -
      • combines the coding for foreground and background colors into a - single byte, reducing the memory required to store saved-lines in - color. (I'll take back that byte in a following patch to use to - ensure the character-set, so there's no long-term decrease in memory - use). - -
      • modifies the PF1-PF4 coding in termcap/terminfo. Because xterm is - still by default emulating vt100, the function key codes are - vt100-compatible (I overlooked this in patch #31). - - I also reformatted the whole terminfo file into a single-column, - for consistency. - -
      • adds an interim xterm-vt220 description to accommodate the old and new - styles of function-keys (though probably it'd be better to drop the - old-style altogether). -
      - -

      Patch #34 - 1997/1/5 - XFree86 3.2o

      - -This patch does the following: -
        -
      • implement DECSTR (soft terminal reset). The biggest diff is due to - adding another state table (note that there's only one useful state - here, but it's only 256 bytes rather than 1k as it would have been - before I reduced the size of state entries). - -
      • some minor tidying up (e.g., signed/unsigned use bitcpy, MODE_DECCKM, - resetColor, resetCharsets). More is done in patch #35. -
      - -I got the description of DECSTR from a vt420 user's manual. I'll do some -testing with vttest to ensure that there's nothing else to do than what was -documented. - -

      Patch #33 - 1996/11/24 - XFree86 3.2

      - -This adds to the reset-fix by Matthieu Herrb <Mathieu.Herrb@mipnet.fr> a -small change to make xterm able to output 8-bit characters in VT100 mode. - -Applications that run on real VT100's don't do that anyway, and this feature -should be removed sometime after finishing off the VT220 emulation (VT220's can -do 8-bit characters). That would be a good time to change the default -terminal-id to 220. - -

      Patch #32 - 1996/11/21 - XFree86 3.2

      - -This implements the REP (repeat) control for xterm. That isn't part of the DEC -VTxxx series, but is defined in ISO 6429. (Note that the base xterm terminal -description is not changed -- I added a variant, "xterm-rep"). - -

      Patch #31 - 1996/11/16 - XFree86 3.2

      - -This implements vt52 emulation in xterm (ifdef'd so it can be removed). -I've been using it for testing for the past month or so. - -

      Patch #30 - 1996/11/16 - XFree86 3.2

      - -From bug-report by <auroux@clipper.ens.fr> (Denis Auroux), missing reset to -ground state. I checked through the rest of that table and found another, -in the unimplemented MC (screen print). - -

      Patch #29 - 1996/9/15 - XFree86 3.1.2Gb

      - -This patch does the following: -
        -
      • corrects the restoration of color for bold/underline color mode - -
      • adds a resource 'decTerminalID' to control the reporting level of - xterm (e.g., VT100, VT220). - -
      • uses the new resource to implement/correct the DA1, DA2 and - DECRPTUI reports. - -
      • change valid-response code in DECRQSS from 0 to 1 (the manual says 0, - but the VT420 terminal I've been testing on says 1). -
      - -All of these changes are based on vttest 2.6 -

      -(Most of the volume in the patch is to add 2 more state tables for parsing -the 2nd/3rd device-attribute controls). - -

      Patch #28 - 1996/8/31 - XFree86 3.1.2F

      - -This patch corrects the following reported by Roland Rosenfeld -<roland@spinnaker.rhein.de>: -
        -
      • handle SGR 22, 24 and 25 in combination with colorUL and colorBD - resources. Also noted & fixed reset of colored underline/bold - with SGR 0. - -
      • a typo in the termcap (missing '['), from 3.1.2Dj (my error) -
      - -Roland also complained that he couldn't use box characters with -
      -	-adobe-courier-bold-r-normal--12-120-75-75-m-70-iso8859-1
      -
      -but that's a known xterm limitation (the box characters must be part of the -font, in the first 32 locations). - -

      Patch #27 - 1996/8/21 - XFree86 3.1.2Ek

      - -This patch fixes one of my long-term gripes: xterm's selection doesn't clearly -show what's being selected (as per David's request, it's controlled by a -resource, which defaults to the older behavior). - -

      Patch #26 - 1996/8/20 - XFree86 3.1.2Ei

      - -Here's a patch to fix a problem with xterm's cut/paste and another to modify -the appearance of the highlighting while selecting. (The changes are -independent, so you can see if the change to screen.c is desirable). - -

      Patch #25 - 1996/8/18 - XFree86 3.1.2Ei

      - -Here's a correction for two minor bugs that I picked up in testing, plus -some lint (from Solaris 2.5) where NULL was used incorrectly: -
        -
      • make the second alternate font the same as the first (that's what - vt420 and dtterm do) - -
      • corrected DECSCL report when DECSCL hasn't been set (i.e., don't - return a '60'). -
      - -

      Patch #24 - 1996/8/11 - XFree86 3.1.2Ee

      - -This patch does several things. In effect, xterm can (I think) do a reasonably -good job of emulating vt220 and vt320 terminals (as well as it was doing -vt100, at any rate ;-). -

      -It does NOT do: -

        -
      • soft fonts - -
      • rigel or sixel graphics -
      -

      -Anyway, I: -

        - -
      • added ECH, CPL, CNL, SU, SD, CBT, CHT controls - -
      • added popup-menu for switching between DEC and Sun function keys. - (corrected alignment err wrt logging entry at that point). - -
      • make xterm recognize both 8-bit and 7-bit controls (including - popup menu for switching modes). - -
      • add user-definable function keys (aka DECUDK) - -
      • support concealed text - -
      • support protected text (both ISO compatible and DEC compatible - - that's not the same thing, btw), with SPA, EPA, DECSCA, DECSED, - DECSEL controls. - -
      • implement DECSCL. -
      -

      -I'll be continuing to test this patch for a while, but don't expect to add any -new functionality (it passes all of the current tests I've built in vttest, but -I need to make more tests).. - -

      Patch #23 - 1996/7/31 - XFree86 3.1.2Ec

      - -This removes the blinking cursor I added last week (for performance reasons). -Time-permitting, I'll revisit this after 3.2 is released (there will be more -work after XFree86 3.2, I assume). - -

      Patch #22 - 1996/7/26 - XFree86 3.1.2Ec

      - -I looked more closely at my "double-negative" and realized that I had been -confused by the default color scheme (black on white) in combination with -reverse video. However, I did see that the original_fg and original_bg data -weren't really used - so I removed that logic. -

      -Also: -

        -
      • during initialization, check if ANSI colors are set with non fg/bg - values, disable color mode if not. This makes xterm tolerant of - applications that allocate the whole color map. - -
      • implemented blinking cursor (default is off) -
      - -

      Patch #21 - 1996/7/24 - XFree86 3.1.2Ec

      - -This patch does the following: -
        -
      • fixes some minor typography in the control-sequences documentation - (it didn't occur to me til I'd sent the last patch that I could use - ghostview for previewing the troff output ;-) - -
      • adjusts the shell's background color in ReverseVideo so that flicker - in resizing is reduced - -
      • adds an ifdef OPT_ISO_COLORS to allow configuring xterm without - the ISO color support (saves a lot of memory) - -
      • used that ifdef to isolate/modify logic so that if the user doesn't - have the colorMode enabled, then ISO color support is disabled (saving - memory). -

        - (If anyone needs numbers, I had savedLines set to 2000, and found - a reduction from ~700k to ~400k of allocated memory, according to - Purify). -

      - -

      Patch #20 - 1996/7/24 - XFree86 3.1.2Ec

      - -This documents the changes in control sequences for window operations that -I added in my previous patch. I'm testing another patch that allows the -user to use less memory if colors aren't needed. - -

      Patch #19 - 1996/7/21 - XFree86 3.1.2Ec

      - -This patch does the following: -
        -
      • fixes the core dump that I reported on IRIX 5.2 (in main.c) -

        - (it's worth noting that this bug exists in X11R6.1, so I'd like - to assume that someone's already submitted a fix to X Consortium...) - -

      • change the interpretation of zero rows or columns in a resize-window - request to use the root window's size (looking more carefully at - dtterm, that seems to be what it does). - -
      • change some memmove calls to memcpy for slightly better performance. - also, a couple of memset calls to bzero, since Quantify says bzero runs - 20% faster, I assume because there's one less argument. - -
      • interpret character sets 1 and 2 (so that vttest gives a reasonable - result) Both rxvt and dtterm do something equivalent. - -
      • fix a minor memory leak in the logic that retrieves the window or - icon names (Purify found this for me while I ran vttest). -
      - -

      Patch #18 - 1996/7/18 - XFree86 3.1.2Ec

      - -This implements the following: -
        -
      • escape sequences that act like the CDE dtterm's window operations - (though I have implemented the default width and height -- I've seen - a rather buggy dtterm running that seems to treat width=0 or height=0 - literally -- maybe that's a feature, not a bug?) - -
      • minor tweak to the screen-repainting when resizing (I still cannot - entirely get rid of flicker). - -
      • still more fixes to terminfo & termcap (I corrected my error for - the hpa code and added some other stuff by comparing to ncurses' - description and rxvt's). - -
      • a tweak to the changes by Michael Rohleder for the color translation - -
      • re-order attribute codes to allow later implementation of protected - fields (dtterm supposedly does this; it's probably more useful than - blinking or invisible text -- that uses up all of the available bits - without changing the attribute scheme radically). -
      - -

      Patch #17 - 1996/7/2 - XFree86 3.1.2Eb

      - -This patch implements for xterm several minor features from ISO 6429 which are -useful for terminfo applications. The HPA and VPA control sequences allow -cursor movement along a row or column, cutting down a little on the characters -transmitted. The other codes allow resetting specific graphic rendition -attributes without modifying the other attributes. - -(now if someone just had time to implement blinking cursors...) - -

      Patch #16 - 1996/6/25 - XFree86 3.1.2Ea

      - -Adam Tla/lka <atlka@pg.gda.pl> told me a couple of weeks ago that I'd missed -some of the background coloring in xterm. I investigated, and found that while -I'd picked up on the clear-to-bottom and clear-to-end-of-line operations, I'd -overlooked the insert/delete lines. Just so I wouldn't overlook any more of -these, I updated a copy of vttest to test ISO colors and bce (background color -erase). This patch introduces a new function, ClearCurBackground, whose calls -replace the direct XClearArea calls that I'd overlooked. - -(There's also a few compiler warnings fixed, etc ;-) - -

      Patch #15 - 1996/5/29 - XFree86 3.1.2E

      - -This fixes the problem reported by David Dawes, by making the 50msec select -timeout for the Xaw3d arrow scrollbar a resource. (I made it a boolean for a -variety of reasons -- to make it a number, you'd need an additional resource, -to avoid breaking the logic). - -

      Patch #14 - 1996/5/12 - XFree86 3.1.2Dj

      - -This patch brings the termcap and terminfo descriptions for xterm up to date. -I made the following changes: -
        -
      • reformatted the terminfo description in a single-column (this is ok - for terminfo, and will simplify future patches -- can't do that for - termcap, since it would impact buffer requirements on some systems). - -
      • omitted obsolete features in termcap to save a little space (bs, pt) - -
      • added color capabilities to termcap (ut, Co, NC, op, AB, AF) - -
      • corrected some capabilities (vi, ve) - -
      • added 'st' (set tab) - -
      • reduced function keys in termcap for 'xterm' to 12 because color - capabilities makes that description larger than 1023 characters. - -
      • created new termcap name 'xtermm' (monochrome) to match the terminfo - list, and make that description have 20 function keys. - -
      • added corresponding color capabilities to terminfo (bce, colors, - pairs, op, ncv, setab, setaf) - -
      • corrected corresponding capabilities in terminfo (civis, cnorm, - rmcup, smcup) - -
      • added capabilities (el1, hts) - -
      • in both, corrected home/end keys to match the code correction made - by Thomas Mueller in 3.1.2Bk - -

        => (I'm still considering modifying the code & description to match - the rxvt program). -

      - -

      Patch #13 - 1996/4/23 - XFree86 3.1.2Df

      - -This corrects my earlier changes for colors - the inner border of the xterm was -getting painted with the wrong color, since I'd moved the call to set the -background into the logic that tracks SGR information. - -

      Patch #12 - 1996/3/16 - XFree86 3.1.2Dc

      - -This corrects a memory leak in xterm that happens whenever one switches fonts. - -

      Patch #11 - 1996/3/5 - XFree86 3.1.2Db

      - -This patch corrects the behavior of the ANSI colors in xterm when reverse -video is used, as well as some other lesser sins: -
        -
      • button.c -
          -
        • (compiler warnings: shadowing of 'time', redundant cast) -
        - -
      • charproc.c -
          -
        • renamed screen.colors[] array to screen.Acolors[] to more - easily distinguish the non-ANSI colors from the ANSI colors. - -
        • moved logic of SGR_Save() into VTInitialize, getting rid of - local private variables original_fg and original_bg. - -
        • moved some logic into getXtermForeground and getXtermBackground - from SGR_Foreground, SGR_Background, etc. - -
        • corrected misleading 'row' to 'col' in case for CUF, CUB - sequences. -
        - -
      • ctlseqs.ms -
      • xterm.man -
          -
        • (correct a misconception which I'd added that the color0 - through color6 resource values apply to non-ANSI colors) -
        - -
      • ptyx.h -
          -
        • added original_fg, original_bg to TScreen structure. -
        - -
      • scrollbar.c -
          -
        • (compiler warnings: redundant cast) -
        - -
      • util.c -
          -
        • new functions getXtermForeground and getXtermBackground replace - the macros GET_FG and GET_BG, with the added functionality of - checking for the reverse-video status of xterm. - -
        • in ReverseVideo, swap the SGR foreground and background colors - also. -
        -
      - -

      Patch #10 - 1996/2/14 - XFree86 3.1.2Cd

      - -I observed an occasional glitch in the xterm's color behavior; a clear to end -of line would get a color that had been used in a program that supposedly reset -colors. I traced this down to the way xterm was modifying colors of GC's on -the fly; it didn't restore the original color of the GC, even though it would -later be used in functions (such as ClearRight) that assumed (my error) that -the GC would have the current foreground or background color. -

      -I fixed this by resetting the GC's colors with a new function 'resetXtermGC()', -and direct calls on SGR_Foreground/SGR_Background, as appropriate and using a -new function 'updatedXtermGC()' to encapsulate the logic that modifies the GC's -color. (I also removed some commented-out code that was trying to do this -- -the problem was a little more obscure). - -

      Patch #9 - 1996/2/10 - XFree86 3.1.2Cb

      - -This patch fixes the remaining problems that I had making xterm run with x11r5, -as well as a couple of other bugs. It follows my patch from yesterday, that -added ifdef's for some of the input-method resources. -
        -
      • corrected ifdef's that suppress the input-method code (doesn't - exist in my x11r5, and xterm works adequately without it). - -
      • corrected fallback definition for 'Select()' macro (oops: I'd - copied the wrong text...) - -
      • moved the declarations for the fd_set variables to data.[ch] - -
      • corrected an ifdef in resize.c (sunos 4.x doesn't have termcap.h) - -
      • corrected (in main.c) some unused/orphaned variables. -
      - -

      Patch #8 - 1996/2/9 - XFree86 3.1.2Cb

      - -This is mostly a documentation patch for xterm. It describes the color control -sequences in more detail, and documents some other features of xterm that -aren't described elsewhere. -

      -I've also added a couple of ifdef's to fix (part of) the problem that I'm -working on (making the program work properly on x11r5, where I'm doing memory -testing -- I have a "good" version from mid-January, but my resync version -doesn't work properly on x11r5). I'm not done with that yet. - -

      Patch #7 - 1996/1/28 - XFree86 3.1.2n

      - -I did a (clean) build of 3.1.2n on Linux 1.2.13 (ELF). I've got an S3 card. -

      -This fixes the following in the 3.1.2n xterm: -

        -
      • initialize cur_foreground, cur_background in charproc.c (Purify - told me they weren't initialized). - -
      • add interpretation of codes 39, 49, to reset background and - foreground to default value (I'm told that ISO 6429 does this; but I - don't have a written reference -- yet -- can anyone help here?). - Anyway, rxvt does it, and it'll solve my remaining color management - problems. - -
      • shadowing of 'time' in menu.c - -
      • 'Cardinal' vs 'int' in scrollbar.c - -
      • several changes to permit compile with X11R5 (the system that I've - got Purify on won't be upgraded to X11R6 for a long time). -
      -

      -I built this version (with a minor nit that I'll patch soon) on SunOS 4.1.3 so -that I can test it some more with Purify. -

      -btw: -the changes made in Xpoll.h won't work on some older systems, because - fd_set isn't a defined type (I've got one machine at least that this - applies to). - -

      Patch #6 - 1996/1/8

      - -This patch does all of the SGR foreground/background fixes (i.e., clearing the -screen after an SGR color is set causes that color to be used in the foreground -and/or background). If the FG_COLOR and/or BG_COLOR flags aren't set, then the -xterm foreground and background default to the window's values. This usage is -consistent with various types of hardware (especially the IBM PC), and is also -used in rxvt. -
        -
      • charproc.c: -
          -
        • add/use new macros GET_FG, GET_BG - n/c. - -
        • add/use new functions SGR_Foreground() and SGR_Background() - to set corresponding colors in GC's, and to retain sense of - "original" colors. - -

          - => This makes redundant some of the corresponding logic - in HideCursor to set the foreground and background, - but I left it in since it may be fixing an unrelated - requirement. - -

        • set GC's in LoadNewFont() according to whether the SGR fg/bg - colors are active. - -

          - => This fixes some glitches in the accompanying resize, - that leaves parts of the window in the original - background color. -

        - -
      • screen.c: -
          -
        • modified ClearBufRows() to use the SGR fg/bg colors if - they're set. - -
        • added function ScrnClearLines(), used this to replace - portions of ScrnInsertLine() and ScrnDeleteLine(). - The new function uses the SGR fg/bg colors if they're - set. - -

          - => Otherwise, selection after an index or reverse index will - paint the wrong colors. - -

        • modified ScrnDeleteChar() and ScrnInsertChar() - to use SGR fg/bg colors. -
        - -
      • util.c: -
          -
        • modified ClearRight() so that if either of the SGR fg/bg - colors is set, we don't bzero the attributes and color - arrays, but instead fill them with the appropriate codes. - -
        • modified ClearLeft to use SGR fg/bg colors. -
        -
      - -

      Patch #5 - 1996/1/7

      - -This patch modifies the object code, by replacing indexing expressions with -temporary variables with the full indexing expression. At first glance, this -seems inefficient (it did to me ;-), until remembering comments made in the -compilers newsgroups that trying to "help" the compiler doesn't really work -that well. A good optimizing compiler can do a better job than the programmer -can. (There's a moral in the use of 'register' variables also, but I won't fix -those...). -

      -Anyway, the revised code generates a smaller object... -

        -
      • charproc.c: -
          -
        • recode index expressions in ShowCursor() and HideCursor() - using SCRN_BUF_xxxxS macros - changes object. - -
        • replace constant '4' by MAX_PTRS - n/c. -
        - -
      • ptyx.h: -
          -
        • defined the SCRN_BUF_xxxxS macros in terms of BUF_xxxxS - macros, to pick up references to ScrnBuf data directly, and - added MAX_PTRS symbol to pick up those '4' constants strewn - about the code - n/c. -
        - -
      • screen.c: -
          -
        • recode index expressions in ScreenWrite() using - SCRN_BUF_xxxxS macros - changes object. - -
        • replace constant '4' by MAX_PTRS - n/c. - -
        • use macros BUF_CHARS, BUF_ATTRS - n/c. - -
        • cast calloc to 'Char *' to fix compiler warning on IRIX - n/c -
        - -
      • scrollbar.c: -
          -
        • replace constant '4' by MAX_PTRS - n/c. - -
        • cast calloc to 'Char *' to fix compiler warning on IRIX - n/c -
        -
      - -

      Patch #4 - 1996/1/7

      -When setting up for this phase, I saw that you'd corrected the bug that I found -in ClearLeft. I decided to make this series of patches anyway, since -readability never hurt (and there's the potential for finding another bug while -reviewing this set). -
        -
      • button.c: -
          -
        • use SCRN_BUF_xxxxS macros - n/c -
        -
      • charproc.c: -
          -
        • use SCRN_BUF_xxxxS macros - n/c -
        -
      • ptyx.h: -
          -
        • added four macros: SCRN_BUF_CHARS, SCRN_BUF_ATTRS, - SCRN_BUF_FORES, SCRN_BUF_BACKS to represent the four - arrays that are derived from screen->buf. -
        -
      • screen.c: -
          -
        • use SCRN_BUF_xxxxS macros - n/c -
        -
      • util.c: -
          -
        • use SCRN_BUF_xxxxS macros - n/c -
        -
      -

      Patch #3 - 1996/1/7

      - -This is my third (and final cleanup) patch for xterm. It gets rid of the -unused stuff, and converts several functions to static (thereby reducing their -scope). -

      -At this point, the only compile warnings I've got (on Linux) are those about -the select arguments (int vs fd_set type), and a missing declaration for -waitpid. Those both are hard to get right without autoconfigure. -

      -The next patches will address the functional changes... -

        -
      • Tekproc.c: -
          -
        • changed several functions to 'static' that aren't used -outside this module -- changes object -
        -
      • charproc.c: -
          -
        • changed several functions to 'static' that aren't used -outside this module -- changes object -
        • deleted unused function unparsefputs -- changes object. -
        -
      • main.c: -
          -
        • changed several functions to 'static' that aren't used -outside this module -- changes object -
        • ifdef'd out unused function 'consolepr()' -- changes object -
        • removed unused variable 'dummy_tio' -- changes object -
        • moved variable 'discipline' to quiet unused-warning -- changes object -
        -
      • main.h: -
          -
        • deleted unused definition of DEFBORDERWIDTH - n/c -
        -
      • misc.c: -
          -
        • changed several functions to 'static' that aren't used -outside this module -- changes object -
        • provide dummy return statements for xerror and xioerror to -quiet compiler warnings -- changes object -
        -
      • ptyx.h: -
          -
        • change sbuf_address and abuf_address to 'Char *' - n/c -
        -
      • resize.c: -
          -
        • changed several functions to 'static' that aren't used outside this module --- changes object -
        -
      • screen.c: -
          -
        • remove unnecessary 'Char **' casts - n/c -
        -
      • util.c: -
          -
        • changed several functions to 'static' that aren't used outside this module --- changes object -
        -
      -

      Patch #2 - 1996/1/7

      -This is my second patch to xterm. It corrects most of the gcc warnings (except -for some that are due to X header files ;-). I compared objects to keep track -of the changes that don't affect the object code (n/c) versus those that do. -

      -At this point, I'm compiling (fairly) clean with gcc options -

      -	-Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Wnested-externs
      -
      -(I also compiled with -Wshadow, but while that found some things that I wanted -to find, there's far too many warnings from the X headers to be usable in this -context). -

      -The changes: -

        -
      • Tekproc.c: -
          -
        • parenthesized expression to avoid gcc warning -- n/c. - -
        • corrected nested-extern declaration for Bool - waiting_for_initial_map; ourTopLevelShellArgs, and - number_ourTopLevelShellArgs - n/c - -
        -
      • charproc.c: -
          -
        • corrected potentially-unintialized variables 'scstype', 'xim', - and 'input_style' -- changes object. - -
        • adjusted logic of VTparse so that gcc won't warn about setjmp - clobbering parsestate -- changes object. - -
        • corrected initialization of 'scstype', which could have been - clobbered by setjmp/longjmp - changes object. - -
        • corrected nested-extern declaration of 'term', 'ProgramName' - - n/c -
        - -
      • cursor.c: -
          -
        • corrected nested-extern declaration of 'term' -- n/c - -
        • renamed 'term' parameters to avoid gcc -Wshadow warning - n/c -
        - -
      • input.c: -
          -
        • change interface of StringInput to assume size_t (i.e., - unsigned) nbytes -- changes object. - -
        • change interface of funcvalue, and sunfuncvalue to use - 'KeySym' type instead of 'int' - changes object. -
        - -
      • main.c: -
          -
        • moved definitions of SIGNAL_T, SIGNAL_RETURN to proto.h - n/c - -
        • corrected missing params of 'do_hangup()' -- changes object - (note: the missing params were not used). - -
        • corrected missing param of 'Error()' -- changes object - -
        • corrected nested-extern 'environ' - n/c - -
        • adjusted assignments to 'tty_got_hung' and 'no_dev_tty' so - that gcc can see they won't be clobbered by the longjmp - - changes object. - -
        • use Size_t type - n/c. -
        - -
      • menu.c: -
          -
        • removed redundant prototype for 'do_hangup()' -- n/c. - -
        • renamed 'time' parameters to avoid gcc -Wshadow warning - n/c -
        - -
      • menu.h: -
          -
        • renamed 'time' parameters to avoid gcc -Wshadow warning - n/c -
        - -
      • misc.c: -
          -
        • corrected definition of 'HandleFocusChange()' -- changes - object - -
        • cast parameters in call to 'TekExpose()' -- n/c - -
        • corrected nested-extern declarations of 'term', 'toplevel', - ProgramName, and 'environ' -- n/c. - -
        • use Size_t type - n/c. -
        - -
      • proto.h: -
          -
        • moved definition of SIGNAL_T (and SIGNAL_RETURN) here from - main.c, resize.c to allow use of this symbol in prototypes - (mostly in xterm.h). - -
        • added definition 'Size_t' to use as corrected type for - strncpy, malloc sizes - n/c. -
        - -
      • resize.c: -
          -
        • moved SIGNAL_T definition to proto.h -- n/c. - -
        • use Size_t type - n/c. -
        - -
      • screen.c: -
          -
        • use Size_t type - n/c. -
        - -
      • tabs.c: -
          -
        • corrected nested-extern declaration of 'term' -- n/c -
        - -
      • util.c: -
          -
        • corrected/supplied parameters to 'TekExpose()' -- changes - object (note: 'TekExpose()' doesn't use its parameters). - -
        • corrected nested-extern declaration of - 'waiting_for_initial_map' -- n/c. - -
        • renamed 'term' parameters to avoid gcc -Wshadow warning - n/c -
        - -
      • xterm.h: -
          -
        • prototype 'do_hangup()', 'HandleFocusChange()', - 'TekExpose()', 'Error()', 'Exit()' - forces changes in - various places. - -
        • adjusted prototypes that pass 'Boolean' arguments to use - 'int' (this is the "correct" ANSI approach to extended - compiles; it's worth mentioning that gcc doesn't meet the - ANSI spec here). I used gcc -Wconversion to find these, but - there's a lot of unrelated warnings that are due to setting - NARROWPROTO in the config - n/c. - -
        • renamed 'term' parameters to avoid gcc -Wshadow warning - n/c -
        -
      -

      Patch #1 - 1996/1/6

      -This is my first cleanup patch for xterm. It addresses all of the gcc warnings -for -Wall, -Wmissing-prototypes and -Wstrict-prototypes that I can change -without modifying the object code. (I'm compiling this with gcc 2.7.0 for an -aout target, which makes it simple to compare objects. When I do ELF-only, -I've got a tool that compares that sort of thing as well). -

      -Briefly, this patch adds (and uses) two header files in the xterm directory: -

      -	proto.h
      -	xterm.h
      -
      -I expect this to be the biggest patch by far. However (barring a misplaced -prototype), it shouldn't break anything, since the intent of the patch is to -provide missing declarations. - - +

      I expect this to be the biggest patch by far. However (barring + a misplaced prototype), it shouldn't break anything, since the + intent of the patch is to provide missing declarations.

      + + diff -Nru xterm-278/xterm.man xterm-297/xterm.man --- xterm-278/xterm.man 2012-01-08 18:21:15.000000000 +0000 +++ xterm-297/xterm.man 2013-09-10 11:30:33.000000000 +0000 @@ -1,7 +1,7 @@ '\" t -.\" $XTermId: xterm.man,v 1.522 2012/01/08 18:21:15 tom Exp $ +.\" $XTermId: xterm.man,v 1.570 2013/09/10 11:30:33 tom Exp $ .\" -.\" Copyright 1996-2010,2011 by Thomas E. Dickey +.\" Copyright 1996-2012,2013 by Thomas E. Dickey .\" .\" All Rights Reserved .\" @@ -56,6 +56,9 @@ .\" .\" updated by Thomas E. Dickey for XFree86, July 1996 - February 2006. .\" +.ds N Xterm +.ds n xterm +.\" .\" Bulleted paragraph .de bP .IP \(bu 4 @@ -71,7 +74,6 @@ .de NE .fi .ft P -.sp .in -4 .. .\" Escape single quotes in literal strings from groff's Unicode transform. @@ -81,20 +83,21 @@ .el .ds `` `` .ie \n(.g .ds '' \(rq .el .ds '' '' -.TH XTERM 1 __vendorversion__ +.TH XTERM 1 "__app_date__" "__app_version__" "X Window System" .SH NAME xterm \- terminal emulator for X .SH SYNOPSIS -.B xterm +.B \*n [\-\fItoolkitoption\fP ...] [\-\fIoption\fP ...] [\fIshell\fP] .SH DESCRIPTION -The \fIxterm\fP program is a terminal emulator for the X Window System. -It provides DEC VT102/VT220 (VTxxx) and Tektronix 4014 -compatible terminals for programs that cannot -use the window system directly. +The \fI\*n\fP program is a terminal emulator for the X Window System. +It provides DEC VT102/VT220 and selected features from higher-level +terminals such as VT320/VT420/VT520 (VTxxx). +It also provides Tektronix 4014 emulation +for programs that cannot 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), \fIxterm\fP will use the facilities to notify programs +derived from 4.3bsd), \fI\*n\fP will use the facilities to notify programs running in the window whenever it is resized. . .PP @@ -122,7 +125,7 @@ The VT220 emulation does not support soft fonts, it is otherwise complete. .IR Termcap (5) entries that work with -.I xterm +.I \*n include an optional platform-specific entry (\*(``__default_termname__\*(''), \*(``xterm\*('', @@ -130,18 +133,18 @@ \*(``vt100\*('', \*(``ansi\*('' and \*(``dumb\*(''. -.I xterm +.I \*n automatically searches the termcap file in this order for these entries and then sets the \*(``TERM\*('' and the \*(``TERMCAP\*('' environment variables. You may also use \*(``vt220\*('', but must set the terminal emulation level with the \fBdecTerminalID\fP resource. -(The \*(``TERMCAP\*('' environment variable is not set if \fIxterm\fP is linked +(The \*(``TERMCAP\*('' environment variable is not set if \fI\*n\fP is linked against a terminfo library, since the requisite information is not provided by the termcap emulation of terminfo libraries). . .PP Many of the special -.I xterm +.I \*n features may be modified under program control through a set of escape sequences different from the standard VT102 escape sequences. @@ -155,7 +158,7 @@ Four different font sizes and five different lines types are supported. There is no write-through or defocused mode support. The Tektronix text and graphics commands are recorded internally by -.I xterm +.I \*n and may be written to a file by sending the COPY escape sequence (or through the .B Tektronix @@ -171,13 +174,13 @@ .I ss are the year, month, day, hour, minute and second when the COPY was performed (the file is created in the directory -.I xterm +.I \*n is started in, or the home directory for a login -.IR xterm ). +.IR \*n ). . .PP Not all of the features described in this manual are necessarily available in -this version of \fIxterm\fP. +this version of \fI\*n\fP. Some (e.g., the non-VT220 extensions) are available only if they were compiled in, though the most commonly-used are in the default configuration. @@ -201,7 +204,7 @@ The .IR termcap (5) entry for -.I xterm +.I \*n allows the visual editor .IR vi (1) to switch to the alternate screen for editing and to restore the screen @@ -213,7 +216,7 @@ In either VT102 or Tektronix mode, there are escape sequences to change the name of the windows. Additionally, in VT102 mode, -\fIxterm\fP implements the window-manipulation control +\fI\*n\fP implements the window-manipulation control sequences from \fIdtterm\fP, such as resizing the window, setting its location on the screen. . @@ -226,7 +229,7 @@ . . .SH OPTIONS -The \fIxterm\fP terminal emulator +The \fI\*n\fP terminal emulator accepts the standard X Toolkit command line options as well as many application-specific options. If the option begins with a @@ -234,79 +237,80 @@ instead of a .RB ` \- ', the option is restored to its default value. -The \fB\-version\fP and \fB\-help\fP options are interpreted even if \fIxterm\fP +The \fB\-version\fP and \fB\-help\fP options are interpreted even if \fI\*n\fP cannot open the display, and are useful for testing and configuration scripts. Along with \fB\-class\fP, they are checked before other options. .TP 8 .B \-version -This causes \fIxterm\fP to print a version number to the standard output, +This causes \fI\*n\fP to print a version number to the standard output, and then exit. .TP 8 .B \-help -This causes \fIxterm\fP to print out a verbose message describing its options, +This causes \fI\*n\fP to print out a verbose message describing its options, one per line. The message is written to the standard output. -After printing the message, \fIxterm\fP exits. -\fIXterm\fP generates this message, sorting it and noting whether +After printing the message, \fI\*n\fP exits. +\fI\*N\fP generates this message, sorting it and noting whether a \*(``\fB\-\fR\fIoption\fP\*('' or a \*(``\fB+\fR\fIoption\fP\*('' turns the feature on or off, since some features historically have been one or the other. -\fIXterm\fP generates a concise help message (multiple options per line) +\fI\*N\fP generates a concise help message (multiple options per line) when an unknown option is used, e.g., .NS -\fBxterm \-z\fP +\fB\*n \-z\fP .NE +.PP If the logic for a particular option such as logging is not compiled -into \fIxterm\fP, the help text for that option also is not displayed +into \fI\*n\fP, the help text for that option also is not displayed by the \fB\-help\fP option. . .PP One parameter (after all options) may be given. -That overrides \fIxterm\fP's built-in choice of shell program. -Normally \fIxterm\fP checks the SHELL variable. -If that is not set, \fIxterm\fP tries to use the shell program specified +That overrides \fI\*n\fP's built-in choice of shell program. +Normally \fI\*n\fP checks the SHELL variable. +If that is not set, \fI\*n\fP tries to use the shell program specified in the password file. -If that is not set, \fIxterm\fP uses \fI/bin/sh\fP. +If that is not set, \fI\*n\fP uses \fI/bin/sh\fP. If the parameter is not a relative path, i.e., beginning with \*(``./\*('' or \*(``../\*('', -\fIxterm\fP looks for the file in the user's PATH. +\fI\*n\fP looks for the file in the user's PATH. In either case, it constructs an absolute path. The \fB\-e\fP option cannot be used with this parameter since it uses all parameters following the option. .PP The other options are used to control the appearance and behavior. -Not all options are necessarily configured into your copy of \fIxterm\fP: +Not all options are necessarily configured into your copy of \fI\*n\fP: .TP 8 .B \-132 Normally, the VT102 DECCOLM escape sequence that switches between 80 and 132 column mode is ignored. This option causes the DECCOLM escape sequence to be recognized, and the -.I xterm +.I \*n window will resize appropriately. .TP 8 .B \-ah This option indicates that -.I xterm +.I \*n should always highlight the text cursor. By default, -.I xterm +.I \*n will display a hollow text cursor whenever the focus is lost or the pointer leaves the window. .TP 8 .B +ah This option indicates that -.I xterm +.I \*n should do text cursor highlighting based on focus. .TP 8 .B \-ai This option disables active icon support if that feature was compiled -into \fIxterm\fP. +into \fI\*n\fP. This is equivalent to setting the \fIvt100\fP resource \fBactiveIcon\fP to \*(``false\*(''. .TP 8 .B +ai This option enables active icon support if that feature was compiled -into \fIxterm\fP. +into \fI\*n\fP. This is equivalent to setting the \fIvt100\fP resource \fBactiveIcon\fP to \*(``true\*(''. .TP 8 @@ -381,7 +385,7 @@ Reset the \fBcjkWidth\fP resource. .TP 8 .BI \-class " string" -This option allows you to override \fIxterm\fP's resource class. +This option allows you to override \fI\*n\fP's resource class. Normally it is \*(``__default_class__\*('', but can be set to another class such as \*(``U__default_class__\*('' to override selected resources. .TP 8 @@ -409,7 +413,7 @@ It sets the \fIcursorColor\fP resource according to the parameter. .TP 8 .B \-cu -This option indicates that \fIxterm\fP should work around a bug in the +This option indicates that \fI\*n\fP should work around a bug in the .IR more (1) program that causes it to incorrectly display lines that are exactly the width of the window and @@ -421,7 +425,7 @@ cursor motion package. .TP 8 .B +cu -This option indicates that \fIxterm\fP should not work around the +This option indicates that \fI\*n\fP should not work around the .IR more (1) bug mentioned above. .TP 8 @@ -441,14 +445,14 @@ .TP 8 .BI \-e " program \fP[ \fIarguments \fP.\|.\|. ]\fI" This option specifies the program (and its command line arguments) to be -run in the \fIxterm\fP window. +run in the \fI\*n\fP window. It also sets the window title and icon name to be the basename of the program being executed if neither \fI\-T\fP nor \fI\-n\fP are given on the command line. \fBThis must be the last option on the command line.\fP .TP 8 .BI \-en " encoding" -This option determines the encoding on which \fIxterm\fP runs. +This option determines the encoding on which \fI\*n\fP runs. It sets the \fBlocale\fR resource. Encodings other than UTF-8 are supported by using \fIluit\fR. The \fB\-lc\fR option should be used instead of \fB\-en\fR for @@ -466,7 +470,7 @@ .TP 8 .BI \-fa " pattern" This option sets the pattern for fonts selected from the FreeType -library if support for that library was compiled into \fIxterm\fP. +library if support for that library was compiled into \fI\*n\fP. This corresponds to the \fBfaceName\fP resource. When a CJK double-width font is specified, you also need to turn @@ -477,50 +481,50 @@ initially active. .TP 8 .BI \-fbb -This option indicates that \fIxterm\fP should compare normal and bold fonts bounding +This option indicates that \fI\*n\fP should compare normal and bold fonts bounding boxes to ensure they are compatible. It sets the \fBfreeBoldBox\fP resource to \*(``false\*(''. .TP 8 .BI +fbb -This option indicates that \fIxterm\fP should not compare normal and bold fonts bounding +This option indicates that \fI\*n\fP should not compare normal and bold fonts bounding boxes to ensure they are compatible. It sets the \fBfreeBoldBox\fP resource to \*(``true\*(''. .TP 8 .BI \-fbx -This option indicates that \fIxterm\fP should not assume that the +This option indicates that \fI\*n\fP should not assume that the normal and bold fonts have VT100 line-drawing characters. -If any are missing, \fIxterm\fP will draw the characters directly. +If any are missing, \fI\*n\fP will draw the characters directly. It sets the \fBforceBoxChars\fP resource to \*(``false\*(''. .TP 8 .BI +fbx -This option indicates that \fIxterm\fP should assume that the +This option indicates that \fI\*n\fP should assume that the normal and bold fonts have VT100 line-drawing characters. It sets the \fBforceBoxChars\fP resource to \*(``true\*(''. .TP 8 .BI \-fd " pattern" This option sets the pattern for double-width fonts selected from the FreeType -library if support for that library was compiled into \fIxterm\fP. +library if support for that library was compiled into \fI\*n\fP. This corresponds to the \fBfaceNameDoublesize\fP resource. .TP 8 .BI \-fi " font" This option sets the font for active icons if that feature was compiled -into \fIxterm\fP. +into \fI\*n\fP. .IP See also the discussion of the \fBiconFont\fP resource. .TP 8 .BI \-fs " size" This option sets the pointsize for fonts selected from the FreeType -library if support for that library was compiled into \fIxterm\fP. +library if support for that library was compiled into \fI\*n\fP. This corresponds to the \fBfaceSize\fP resource. .TP 8 .BI \-fullscreen -This option indicates that \fIxterm\fP should ask the window manager to +This option indicates that \fI\*n\fP should ask the window manager to let it use the full-screen for display, e.g., without window decorations. It sets the \fBfullscreen\fP resource to \*(``true\*(''. .TP 8 .BI +fullscreen -This option indicates that \fIxterm\fP should not ask the window manager to +This option indicates that \fI\*n\fP should not ask the window manager to let it use the full-screen for display. It sets the \fBfullscreen\fP resource to \*(``false\*(''. .TP 8 @@ -562,26 +566,26 @@ It sets the \fBhpFunctionKeys\fP resource to \*(``false\*(''. .TP 8 .BI \-hm -Tells \fIxterm\fP to use +Tells \fI\*n\fP to use \fBhighlightTextColor\fP and \fBhighlightColor\fP to override the reversed foreground/background colors in a selection. It sets the \fBhighlightColorMode\fP resource to \*(``true\*(''. .TP 8 .BI +hm -Tells \fIxterm\fP not to use +Tells \fI\*n\fP not to use \fBhighlightTextColor\fP and \fBhighlightColor\fP to override the reversed foreground/background colors in a selection. It sets the \fBhighlightColorMode\fP resource to \*(``false\*(''. .TP 8 .BI \-hold Turn on the \fBhold\fP resource, i.e., -\fIxterm\fP will not immediately destroy its window when the shell command completes. +\fI\*n\fP will not immediately destroy its window when the shell command completes. It will wait until you use the window manager to destroy/kill the window, or if you use the menu entries that send a signal, e.g., HUP or KILL. .TP 8 .BI +hold Turn off the \fBhold\fP resource, i.e., -\fIxterm\fP will immediately destroy its window when the shell command completes. +\fI\*n\fP will immediately destroy its window when the shell command completes. .TP 8 .B \-ie Turn on the \fBptyInitialErase\fP resource, i.e., @@ -603,22 +607,22 @@ .BI \-into " windowId" Given an X window identifier (an integer, which can be hexadecimal, octal or decimal according to whether it begins with "0x", "0" or neither), -\fIxterm\fP will reparent its top-level shell widget to that window. -This is used to embed \fIxterm\fP within other applications. -.PP +\fI\*n\fP will reparent its top-level shell widget to that window. +This is used to embed \fI\*n\fP within other applications. +.IP For instance, there are scripts for Tcl/Tk and Gtk which can be used to demonstrate the feature. When using Gtk, there is a limitation of that toolkit which requires -that \fIxterm\fP's \fBallowSendEvents\fP resource is enabled. +that \fI\*n\fP's \fBallowSendEvents\fP resource is enabled. .TP 8 .B \-j -This option indicates that \fIxterm\fP should do jump scrolling. +This option indicates that \fI\*n\fP should do jump scrolling. It corresponds to the \fBjumpScroll\fP resource. Normally, -text is scrolled one line at a time; this option allows \fIxterm\fP to move +text is scrolled one line at a time; this option allows \fI\*n\fP to move multiple lines at a time so that it does not fall as far behind. Its use is -strongly recommended since it makes \fIxterm\fP much faster when scanning +strongly recommended since it makes \fI\*n\fP much faster when scanning through large amounts of text. The VT100 escape sequences for enabling and disabling smooth scroll as well as the \*(``VT Options\*('' @@ -626,11 +630,11 @@ feature on or off. .TP 8 .B +j -This option indicates that \fIxterm\fP should not do jump scrolling. +This option indicates that \fI\*n\fP should not do jump scrolling. .TP 8 .B \-k8 This option sets the \fBallowC1Printable\fP resource. -When \fBallowC1Printable\fP is set, \fIxterm\fP overrides the mapping +When \fBallowC1Printable\fP is set, \fI\*n\fP overrides the mapping of C1 control characters (code 128-159) to treat them as printable. .TP 8 .B +k8 @@ -663,8 +667,8 @@ .B \-l Turn logging on. Normally logging is not supported, due to security concerns. -Some versions of \fIxterm\fP may have logging enabled. -The logfile is written to the directory from which \fIxterm\fP is +Some versions of \fI\*n\fP may have logging enabled. +The logfile is written to the directory from which \fI\*n\fP is invoked. The filename is generated, of the form .sp @@ -674,7 +678,7 @@ .sp Xterm.log.\fIhostname.yyyy.mm.dd.hh.mm.ss.XXXXXX\fR .sp -depending on how \fIxterm\fP was built. +depending on how \fI\*n\fP was built. .TP 8 .B +l Turn logging off. @@ -711,16 +715,16 @@ See the \fB\-l\fP option. .TP 8 .B \-ls -This option indicates that the shell that is started in the \fIxterm\fP window +This option indicates that the shell that is started in the \fI\*n\fP window will be a login shell (i.e., the first character of argv[0] will be a dash, indicating to the shell that it should read the user's .login or .profile). .IP The \fB\-ls\fP flag and the \fBloginShell\fP resource are ignored if \fB\-e\fP is also given, -because \fIxterm\fP does not know how to make the shell +because \fI\*n\fP does not know how to make the shell start the given command after whatever it does when it is a login shell \- the user's shell of choice need not be a Bourne shell after all. -Also, \fIxterm\ \-e\fP is supposed to provide a consistent +Also, \fI\*n\ \-e\fP is supposed to provide a consistent functionality for other applications that need to start text-mode programs in a window, and if \fBloginShell\fP were not ignored, the result of ~/.profile might interfere with that. @@ -728,15 +732,16 @@ If you do want the effect of \fB\-ls\fP and \fB\-e\fP simultaneously, you may get away with something like .NS 15 -xterm \-e /bin/bash \-l \-c "my command here" +\*n \-e /bin/bash \-l \-c "my command here" .NE +.IP Finally, \fB\-ls\fP is not completely ignored, -because \fIxterm\ \-ls\ \-e\fP does write a \fI/etc/wtmp\fP entry +because \fI\*n\ \-ls\ \-e\fP does write a \fI/etc/wtmp\fP entry (if configured to do so), -whereas \fIxterm\ \-e\fP does not. +whereas \fI\*n\ \-e\fP does not. .TP 8 .B \-maximized -This option indicates that \fIxterm\fP should ask the window manager to +This option indicates that \fI\*n\fP should ask the window manager to maximize its layout on startup. This corresponds to the \fBmaximized\fP resource. .IP @@ -744,15 +749,15 @@ it is possible to do both with certain window managers. .TP 8 .B +maximized -This option indicates that \fIxterm\fP should ask the window manager to -maximize its layout on startup. +This option indicates that \fI\*n\fP should ask the window manager to +not maximize its layout on startup. .TP 8 .B +ls This option indicates that the shell that is started should not be a login shell (i.e., it will be a normal \*(``subshell\*(''). .TP 8 .B \-mb -This option indicates that \fIxterm\fP should ring a margin bell when +This option indicates that \fI\*n\fP should ring a margin bell when the user types near the right end of a line. .TP 8 .B +mb @@ -771,7 +776,7 @@ .TP 8 .B "\-mk_width" Set the \fBmkWidth\fP resource to \*(``true\*(''. -This makes \fIxterm\fP use a built-in version of the wide-character width +This makes \fI\*n\fP use a built-in version of the wide-character width calculation. The default is \*(``false\*('' .TP 8 @@ -833,14 +838,14 @@ This option indicates that reverse-wraparound should not be allowed. .TP 8 .B \-s -This option indicates that \fIxterm\fP may scroll asynchronously, meaning that +This option indicates that \fI\*n\fP may scroll asynchronously, meaning that the screen does not have to be kept completely up to date while scrolling. -This allows \fIxterm\fP to run faster when network latencies are very high +This allows \fI\*n\fP to run faster when network latencies are very high and is typically useful when running across a very large internet or many gateways. .TP 8 .B +s -This option indicates that \fIxterm\fP should scroll synchronously. +This option indicates that \fI\*n\fP should scroll synchronously. .TP 8 .B \-samename Does not send title and icon name change requests when the request @@ -913,11 +918,11 @@ .TP 8 .B \-sm This option, corresponding to the \fBsessionMgt\fR resource, -indicates that \fIxterm\fR should +indicates that \fI\*n\fR should set up session manager callbacks. .TP 8 .B +sm -This option indicates that \fIxterm\fR should +This option indicates that \fI\*n\fR should not set up session manager callbacks. .TP 8 .B \-sp @@ -930,43 +935,43 @@ keypad and function keys. .TP 8 .B \-t -This option indicates that \fIxterm\fP should start in Tektronix mode, rather +This option indicates that \fI\*n\fP should start in Tektronix mode, rather than in VT102 mode. Switching between the two windows is done using the \*(``Options\*('' menus. .IR Termcap (5) entries that work with -.I xterm +.I \*n \*(``tek4014\*('', \*(``tek4015\*('', \*(``tek4012\*('', \*(``tek4013\*('', \*(``tek4010\*('', and \*(``dumb\*(''. -.I xterm +.I \*n automatically searches the termcap file in this order for these entries and then sets the \*(``TERM\*('' and the \*(``TERMCAP\*('' environment variables. .TP 8 .B +t -This option indicates that \fIxterm\fP should start in VT102 mode. +This option indicates that \fI\*n\fP should start in VT102 mode. .TP 8 .B \-tb This option, corresponding to the \fBtoolBar\fR resource, -indicates that \fIxterm\fR should display a toolbar (or menubar) +indicates that \fI\*n\fR should display a toolbar (or menubar) at the top of its window. The buttons in the toolbar correspond to the popup menus, e.g., control/left/mouse for \*(``Main Options\*(''. .TP 8 .B +tb -This option indicates that \fIxterm\fR should +This option indicates that \fI\*n\fR should not set up a toolbar. .TP 8 .BI \-ti " term_id" -Specify the name used by \fIxterm\fP to select the +Specify the name used by \fI\*n\fP to select the correct response to terminal ID queries. It also specifies the emulation level, used to determine the type of response to a DA control sequence. -Valid values include vt52, vt100, vt101, vt102, and vt220 +Valid values include vt52, vt100, vt101, vt102, vt220, and vt240 (the \*(``vt\*('' is optional). The default is \*(``vt__default_termid__\*(''. The term_id argument specifies the terminal ID to use. @@ -985,21 +990,21 @@ It corresponds to the \fBtermName\fP resource. This terminal type must exist in the terminal database -(termcap or terminfo, depending on how \fIxterm\fP is built) +(termcap or terminfo, depending on how \fI\*n\fP is built) and should have \fIli#\fP and \fIco#\fP entries. -If the terminal type is not found, \fIxterm\fP uses the built-in list +If the terminal type is not found, \fI\*n\fP uses the built-in list \*(``xterm\*('', \*(``vt102\*('', etc. .TP 8 .B \-u8 This option sets the \fButf8\fP resource. -When \fButf8\fP is set, \fIxterm\fP interprets incoming data as UTF-8. +When \fButf8\fP is set, \fI\*n\fP interprets incoming data as UTF-8. This sets the \fBwideChars\fP resource as a side-effect, but the UTF-8 mode set by this option prevents it from being turned off. If you must turn it on and off, use the \fBwideChars\fP resource. .IP This option and the \fButf8\fR resource are overridden by the \fB\-lc\fP and \fB\-en\fP options and \fBlocale\fR resource. -That is, if \fIxterm\fP has been compiled to support \fIluit\fR, +That is, if \fI\*n\fP has been compiled to support \fIluit\fR, and the \fBlocale\fP resource is not \*(``false\*('' this option is ignored. We recommend using @@ -1036,11 +1041,11 @@ italics rather than with underlining. .TP 8 .B \-ut -This option indicates that \fIxterm\fP should not write a record into the +This option indicates that \fI\*n\fP should not write a record into the the system \fIutmp\fP log file. .TP 8 .B +ut -This option indicates that \fIxterm\fP should write a record into +This option indicates that \fI\*n\fP should write a record into the system \fIutmp\fP log file. .TP 8 .B \-vb @@ -1053,24 +1058,24 @@ .TP 8 .B \-wc This option sets the \fBwideChars\fP resource. -When \fBwideChars\fP is set, \fIxterm\fP maintains internal structures for 16-bit +When \fBwideChars\fP is set, \fI\*n\fP maintains internal structures for 16-bit characters. If you do not set this resource to \*(``true\*('', -\fIxterm\fP will ignore the escape sequence which turns UTF-8 mode on and off. +\fI\*n\fP will ignore the escape sequence which turns UTF-8 mode on and off. The default is \*(``false\*(''. .TP 8 .B +wc This option resets the \fBwideChars\fP resource. .TP 8 .B \-wf -This option indicates that \fIxterm\fP should wait for the window to be mapped +This option indicates that \fI\*n\fP should wait for the window to be mapped the first time before starting the subprocess so that the initial terminal size settings and environment variables are correct. It is the application's responsibility to catch subsequent terminal size changes. .TP 8 .B +wf -This option indicates that \fIxterm\fP should not wait before starting the +This option indicates that \fI\*n\fP should not wait before starting the subprocess. .TP 8 .B \-ziconbeep \fIpercent\fP @@ -1080,7 +1085,7 @@ and have \*(``***\*('' prepended to their icon titles. Most window managers will detect this change immediately, showing you which window has the output. -(A similar feature was in x10 \fIxterm\fP.) +(A similar feature was in x10 \fI\*n\fP.) .TP 8 .B \-C This option indicates that this window should receive console output. @@ -1094,7 +1099,7 @@ ownership of the console device in order to get this option to work. .TP 8 .B \-S\fIccn\fP -This option allows \fIxterm\fP to be used as an input and +This option allows \fI\*n\fP to be used as an input and output channel for an existing program and is sometimes used in specialized applications. The option value specifies the last few letters of the name of a pseudo-terminal @@ -1111,11 +1116,13 @@ -S123/45 -Sab34 .NE -Note that \fIxterm\fP does not close any file descriptor +.IP +Note that \fI\*n\fP does not close any file descriptor which it did not open for its own use. It is possible (though probably not portable) to have an application -which passes an open file descriptor down to \fIxterm\fP past the -initialization or the \fB\-S\fP option to a process running in the \fIxterm\fP. +which passes an open file descriptor down to \fI\*n\fP past the +initialization or the \fB\-S\fP option to a process running in the \fI\*n\fP. +.SS OLD OPTIONS .PP The following command line arguments are provided for compatibility with older versions. @@ -1131,14 +1138,16 @@ It is shorthand for specifying the \*(``\fI*iconGeometry\fP\*('' resource. .TP 8 .BI \-T " string" -This option specifies the title for \fIxterm\fP's windows. +This option specifies the title for \fI\*n\fP's windows. It is equivalent to \fB\-title\fP. .TP 8 .BI \-n " string" -This option specifies the icon name for \fIxterm\fP's windows. +This option specifies the icon name for \fI\*n\fP's windows. It is shorthand for specifying the \*(``\fI*iconName\fP\*('' resource. Note that this is not the same as the toolkit option \fB\-name\fP (see below). The default icon name is the application name. +.IP +If no suitable icon is found, \fI\*n\fP provides a compiled-in pixmap. .TP 8 .B \-r This option indicates that reverse video should be simulated by swapping @@ -1150,14 +1159,15 @@ This option specifies the width in pixels of the border surrounding the window. It is equivalent to \fB\-borderwidth\fP or \fB\-bw\fP. . +.SS X TOOLKIT OPTIONS .PP The following standard X Toolkit command line arguments are commonly used -with \fIxterm\fP: +with \fI\*n\fP: .TP 8 .B \-bd \fIcolor\fP This option specifies the color to use for the border of the window. The corresponding resource name is \fIborderColor\fP. -\fIxterm\fP uses the X Toolkit default, which is \*(``XtDefaultForeground\*(''. +\fI\*n\fP uses the X Toolkit default, which is \*(``XtDefaultForeground\*(''. .TP 8 .B \-bg \fIcolor\fP This option specifies the color to use for the background of the window. @@ -1172,7 +1182,7 @@ and may provide advice to your window manager to set the thickness of the window frame. Most window managers do not use this information. -See the \fB\-b\fP option, which controls the inner border of the \fIxterm\fP +See the \fB\-b\fP option, which controls the inner border of the \fI\*n\fP window. .TP 8 .B \-display \fIdisplay\fP @@ -1197,7 +1207,7 @@ see \fIX(__miscmansuffix__)\fP. .TP 8 .B \-iconic -This option indicates that \fIxterm\fP should ask the window manager to +This option indicates that \fI\*n\fP should ask the window manager to start it as an icon rather than as the normal window. The corresponding resource name is \fIiconic\fP. .TP 8 @@ -1236,12 +1246,13 @@ Tie the VTxxx \fBbackarrowKey\fP and \fBptyInitialErase\fP resources together by setting the DECBKM state according to whether the initial value of \fIstty\fP erase is a backspace (8) or delete (127) character. -The default is \*(``false\*('', which disables this feature. +A \*(``false\*('' value disables this feature. +The default is \*(``__backarrow_is_erase__\*(''. .TP 8 .B "fullscreen (\fPclass\fB Fullscreen)" -Specifies whether or not \fIxterm\fP should ask the window manager to +Specifies whether or not \fI\*n\fP should ask the window manager to use a fullscreen layout on startup. -\fIXterm\fP accepts either a keyword (ignoring case) +\fI\*N\fP accepts either a keyword (ignoring case) or the number shown in parentheses: .RS .TP 3 @@ -1267,7 +1278,7 @@ .TP 8 .B "hold (\fPclass\fB Hold)" If true, -\fIxterm\fP will not immediately destroy its window when the shell command completes. +\fI\*n\fP will not immediately destroy its window when the shell command completes. It will wait until you use the window manager to destroy/kill the window, or if you use the menu entries that send a signal, e.g., HUP or KILL. You may scroll back, select text, etc., to perform most graphical operations. @@ -1284,9 +1295,65 @@ Specifies the preferred size and position of the application when iconified. It is not necessarily obeyed by all window managers. .TP 8 +.B "iconHint (\fPclass\fB IconHint)" +Specifies a icon which will be added to the window manager hints. +\fI\*n\fP provides no default value. +.IP +Set this resource to \*(``none\*('' to omit the hint entirely, +using whatever the window manager may decide. +.IP +If the \fBiconHint\fP resource is given (or is set via the \fB\-n\fP option) +\fI\*n\fP searches for a pixmap file with that name, +in the current directory as well as in __pixmapsdir__. +if the resource does not specify an absolute pathname. +In each case, \fI\*n\fP adds \*(``_48x48\*('' +and/or \*(``.xpm\*('' to the filename +after trying without those suffixes. +If it is able to load the file, \fI\*n\fP sets the window manager +hint for the icon-pixmap. +These pixmaps are distributed with \fI\*n\fP, and can optionally be +compiled-in: +.RS +.bP +mini.\*n_16x16, +mini.\*n_32x32, +mini.\*n_48x48 +.bP +filled-\*n_16x16 +filled-\*n_32x32 +filled-\*n_48x48 +.bP +\*n_16x16 +\*n_32x32 +\*n_48x48 +.bP +\*n-color_16x16 +\*n-color_32x32 +\*n-color_48x48 +.RE +.IP +In either case, \fI\*n\fP allows for adding a \*(``_48x48\*('' to specify the +largest of the pixmaps as a default. +That is, \*(``mini.\*n\*('' is the same as \*(``mini.\*n_48x48\*(''. +.IP +If no explicit \fBiconHint\fP resource is given +(or if none of the compiled-in names matches), +\*n uses \*(``mini.\*n\*('' (which is always compiled-in). +.IP +The \fBiconHint\fP resource has no effect on \*(``desktop\*('' files, +including \*(``panel\*('' and \*(``menu\*(''. +Those are typically set via a \*(``.desktop\*('' file; +\fI\*n\fP provides samples for itself (and the \fIu\*n\fP script). +The more capable desktop systems allow changing the icon on a per-user basis. +.TP 8 .B "iconName (\fPclass\fB IconName)" -Specifies the icon name. -The default is the application name, e.g., \*(``xterm\*(''. +Specifies a label for \fI\*n\fP when iconified. +\fI\*n\fP provides no default value; +some window managers may assume the application name, e.g., \*(``\*n\*(''. +.IP +Setting the \fBiconName\fP resource sets the icon label +unless overridden by \fBzIconBeep\fP +or the control sequences which change the window and icon labels. .TP 8 .B "keyboardType (\fPclass\fB KeyboardType)" Enables one (or none) of the various keyboard-type resources: @@ -1320,7 +1387,7 @@ if the operating system prefers larger buffer sizes. .TP 8 .B "maximized (\fPclass\fB Maximized)" -Specifies whether or not \fIxterm\fP should ask the window manager to +Specifies whether or not \fI\*n\fP should ask the window manager to maximize its layout on startup. The default is \*(``false\*(''. @@ -1330,7 +1397,7 @@ See .BR mesg (1). The default is \*(``true\*(''. -.TP 9 +.TP 8 .B "menuLocale (\fPclass\fB MenuLocale)" Specify the locale used for character-set computations when loading the popup menus. @@ -1345,12 +1412,12 @@ .TP 8 .B "minBufSize (\fPclass\fB MinBufSize)" Specify the minimum size of the input buffer, i.e., the amount of data -that \fIxterm\fR requests on each read. +that \fI\*n\fR requests on each read. The default is \*(``4096\*(''. You cannot set this to a value less than 64. .TP 8 .B "omitTranslation (\fPclass\fB OmitTranslation)" -Selectively omit one or more parts of \fIxterm\fP's default translations +Selectively omit one or more parts of \fI\*n\fP's default translations at startup. The resource value is a comma-separated list of keywords, which may be abbreviated: @@ -1358,12 +1425,12 @@ \*(``scroll-lock\*('', \*(``shift-fonts\*('' or \*(``wheel-mouse\*(''. -\fIXterm\fP also recognizes \*(``default\*('', +\fI\*N\fP also recognizes \*(``default\*('', but omitting that will make the program unusable unless you provide a similar definition in your resource settings. .TP 8 .B "ptyHandshake (\fPclass\fB PtyHandshake) -If \*(``true\*('', \fIxterm\fP will perform handshaking during initialization +If \*(``true\*('', \fI\*n\fP will perform handshaking during initialization to ensure that the parent and child processes update the \fIutmp\fP and \fIstty\fP state. .IP @@ -1374,19 +1441,19 @@ The default is \*(``true\*(''. .TP 8 .B "ptyInitialErase (\fPclass\fB PtyInitialErase)" -If \*(``true\*('', \fIxterm\fP will use the pseudo-terminal's sense of the \fIstty\fP erase +If \*(``true\*('', \fI\*n\fP will use the pseudo-terminal's sense of the \fIstty\fP erase value. -If \*(``false\*('', \fIxterm\fP will set the \fIstty\fP erase value to match its own +If \*(``false\*('', \fI\*n\fP will set the \fIstty\fP erase value to match its own configuration, using the \fBkb\fP string from the termcap entry as a reference, if available. In either case, the result is applied to the TERMCAP variable -which \fIxterm\fP sets. +which \fI\*n\fP sets. .IP See also the \fBttyModes\fP resource, which may modify this. The default is \*(``false\*(''. .TP 8 .B "ptySttySize (\fPclass\fB PtySttySize) -If \*(``true\*('', \fIxterm\fP will reset the screen size after +If \*(``true\*('', \fI\*n\fP will reset the screen size after terminal initialization is complete. This is needed for some systems whose pseudo-terminals cannot propagate terminal characteristics. @@ -1399,7 +1466,7 @@ \*(``true\*('' otherwise. .TP 8 .B "sameName (\fPclass\fB SameName)" -If the value of this resource is \*(``true\*('', \fIxterm\fP does not send +If the value of this resource is \*(``true\*('', \fI\*n\fP does not send title and icon name change requests when the request would have no effect: the name is not changed. This has the advantage @@ -1417,7 +1484,7 @@ While this resource applies to either bitmap or TrueType fonts, its main purpose is to help work around incompatible changes in the Xft library's font metrics. -\fIXterm\fP checks the font metrics to find what the library claims are +\fI\*N\fP checks the font metrics to find what the library claims are the bounding boxes for each glyph (character). However, some of Xft's features (such as the autohinter) can cause the glyphs to be scaled larger than the bounding boxes, and be partly overwritten @@ -1433,7 +1500,7 @@ .TP 8 .B "sessionMgt (\fPclass\fB SessionMgt)" If the value of this resource is \*(``true\*('', -\fIxterm\fP sets up session manager callbacks +\fI\*n\fP sets up session manager callbacks for \fBXtNdieCallback\fR and \fBXtNsaveCallback\fR. The default is \*(``true\*(''. .TP 8 @@ -1450,9 +1517,9 @@ and CTRL F1-F12 to F11-F20, depending on the setting of the \fBctrlFKeys\fP resource. -so \fIxterm\fP emulates a DEC VT220 more accurately. +so \fI\*n\fP emulates a DEC VT220 more accurately. Otherwise (the default, with \fBsunKeyboard\fP set to \*(``false\*(''), -\fIxterm\fP uses PC-style bindings for the function keys and keypad. +\fI\*n\fP uses PC-style bindings for the function keys and keypad. .IP PC-style bindings use the Shift, Alt, Control and Meta keys as modifiers for function-keys @@ -1517,13 +1584,13 @@ .IP This is very useful for overriding the default terminal settings without having to do an \fIstty\fP every time -an \fIxterm\fP is started. +an \fI\*n\fP is started. Note, however, that the \fIstty\fP program on a given host may use different -keywords; \fIxterm\fR's table is built-in. +keywords; \fI\*n\fR's table is built-in. .IP If the \fBttyModes\fP resource specifies a value for \fBerase\fP, that overrides the \fBptyInitialErase\fP resource setting, -i.e., \fIxterm\fP initializes the terminal to match that value. +i.e., \fI\*n\fP initializes the terminal to match that value. .TP 8 .B "useInsertMode (\fPclass\fB UseInsertMode)" Force use of insert mode by adding appropriate entries to the TERMCAP @@ -1532,25 +1599,25 @@ The default is \*(``false\*(''. .TP 8 .B "utmpDisplayId (\fPclass\fB UtmpDisplayId)" -Specifies whether or not \fIxterm\fP should try to record the display +Specifies whether or not \fI\*n\fP should try to record the display identifier (display number and screen number) as well as the hostname in the system \fIutmp\fP log file. The default is \*(``true\*(''. .TP 8 .B "utmpInhibit (\fPclass\fB UtmpInhibit)" -Specifies whether or not \fIxterm\fP should try to record the user's terminal +Specifies whether or not \fI\*n\fP should try to record the user's terminal in the system \fIutmp\fP log file. -If true, \fIxterm\fP will not try. +If true, \fI\*n\fP will not try. The default is \*(``false\*(''. .TP 8 .B "waitForMap (\fPclass\fB WaitForMap)" -Specifies whether or not \fIxterm\fP should wait for the initial window map +Specifies whether or not \fI\*n\fP should wait for the initial window map before starting the subprocess. This is part of the .B ptyHandshake logic. -When \fIxterm\fP is directed to wait in this fashion, +When \fI\*n\fP is directed to wait in this fashion, it passes the terminal size from the display end of the pseudo-terminal to the terminal I/O connection, e.g., according to the window manager. Otherwise, it uses the size as given in resource values or command-line @@ -1561,11 +1628,20 @@ Same as \-ziconbeep command line argument. If the value of this resource is non-zero, xterms that produce output while iconified will cause an XBell sound at the given volume -and have \*(``***\*('' prepended to their icon titles. +and have \*(``***\ \*('' prepended to their icon titles. Most window managers will detect this change immediately, showing you which window has the output. -(A similar feature was in x10 \fIxterm\fR.) +(A similar feature was in x10 \fI\*n\fR.) The default is \*(``false\*(''. +.TP 8 +.B "zIconTitleFormat (\fPclass\fB ZIconTitleFormat)" +Allow customization of the string used in the \fBzIconBeep\fP feature. +The default value is \*(``***\ %s\*(''. +.IP +If the resource value contains a \*(``%s\*('', +then \fI\*n\fP inserts the icon title at that point rather +than prepending the string to the icon title. +(Only the first \*(``%s\*('' is used). .\" .SS VT100 Widget Resources .PP @@ -1573,7 +1649,7 @@ of the \fIvt100\fP widget (class \fIVT100\fP). They are specified by patterns such as \*(``\fB__default_class__.vt100.\fP\fINAME\fP\*(''. .PP -If your \fIxterm\fP is configured to support the \*(``toolbar\*('', then those +If your \fI\*n\fP is configured to support the \*(``toolbar\*('', then those patterns need an extra level for the form-widget which holds the toolbar and vt100 widget. A wildcard between the top-level @@ -1582,17 +1658,37 @@ .TP 8 .B "activeIcon (\fPclass\fB ActiveIcon)" Specifies whether or not active icon windows are to be used when the -\fIxterm\fP window is iconified, if this feature is compiled into \fIxterm\fR. +\fI\*n\fP window is iconified, if this feature is compiled into \fI\*n\fR. The active icon is a miniature representation of the content of the window and will update as the content changes. -Not all window managers -necessarily support application icon windows. +Not all window managers necessarily support application icon windows. Some window managers will allow you to enter keystrokes into the active icon window. -The default is \*(``false\*(''. +The default is \*(``default\*(''. +.IP +\fI\*N\fP accepts either a keyword (ignoring case) +or the number shown in parentheses: +.RS +.TP +false (0) +No active icon is shown. +.TP +true (1) +The active icon is shown. +If you are using \fItwm\fP, use this setting to enable active-icons. +.TP +default (2) +\fI\*n\fP checks at startup, and shows an active icon only for window +managers which it can identify and which are known to support the feature. +These are \fIfvwm\fP (full support), and \fIwindow maker\fP (limited). +A few other windows managers (such as \fItwm\fP and \fIctwm\fP) +support active icons, +but do not support the extensions which allow \fI\*n\fP +to identify the window manager. +.RE .TP 8 .B "allowBoldFonts (\fPclass\fB AllowBoldFonts)" -When set to \*(``false\*('', \fIxterm\fP will not use bold fonts. +When set to \*(``false\*('', \fI\*n\fP will not use bold fonts. This overrides both the \fBalwaysBoldMode\fP and the \fBboldMode\fP resources. .B "alwaysBoldMode (\fPclass\fB AlwaysBoldMode)" .TP 8 @@ -1612,6 +1708,15 @@ .B "allowFontOps (\fPclass\fB AllowFontOps)" Specifies whether control sequences that set/query the font should be allowed. The default is \*(``true\*(''. +.TP 5 +.B "allowPasteControls (\fPclass\fB AllowPasteControls)" +If true, allow control characters such as BEL and CAN to be pasted. +Formatting characters (tab, newline) are always allowed. +Other C0 control characters are suppressed unless this resource is enabled. +The exact set of control characters (C0 and C1) +depends upon whether UTF-8 encoding is used, +as well as the \fBallowC1Printable\fP resource. +The default is \*(``false\*(''. .TP 8 .B "allowScrollLock (\fPclass\fB AllowScrollLock)" Specifies whether control sequences that set/query @@ -1619,11 +1724,11 @@ as well as whether the Scroll Lock key responds to user's keypress. The default is \*(``false\*(''. .IP -When this feature is enabled, \fIxterm\fP will sense the state of the +When this feature is enabled, \fI\*n\fP will sense the state of the Scroll Lock key each time it acquires focus. -Pressing the Scroll Lock key toggles \fIxterm\fP's internal state, +Pressing the Scroll Lock key toggles \fI\*n\fP's internal state, as well as toggling the associated LED. -While the Scroll Lock is active, \fIxterm\fP attempts to keep a viewport on the +While the Scroll Lock is active, \fI\*n\fP attempts to keep a viewport on the same set of lines. If the current viewport is scrolled past the limit set by the \fBsaveLines\fP resource, then Scroll Lock has no further effect. @@ -1646,21 +1751,19 @@ Specifies whether control sequences that query the terminal's notion of its function-key strings, as termcap or terminfo capabilities should be allowed. -The default is \*(``false\*(''. +The default is \*(``true\*(''. .IP A few programs, e.g., \fIvim\fP, use this feature to get an accurate description of the terminal's capabilities, independent of the termcap/terminfo setting: .RS -.TP 3 -- -\fIxterm\fP can tell the querying program how many colors it supports. +.bP +\fI\*n\fP can tell the querying program how many colors it supports. This is a constant, depending on how it is compiled, typically 16. It does not change if you alter resource settings, e.g., the \fBboldColors\fP resource. -.TP 3 -- -\fIxterm\fP can tell the querying program what strings are sent by modified +.bP +\fI\*n\fP can tell the querying program what strings are sent by modified (shift-, control-, alt-) function- and keypad-keys. Reporting control- and alt-modifiers is a feature that relies on the \fIncurses\fP extended naming. @@ -1701,24 +1804,32 @@ (a character combined with the modifier associated with left/right Alt-keys) are converted into a two-character sequence with the character itself preceded by ESC. -This applies as well to function key control sequences, unless \fIxterm\fP +This applies as well to function key control sequences, unless \fI\*n\fP sees that \fBAlt\fP is used in your key translations. .bP If \*(``false\*('', Alt characters input from the keyboard cause a shift to 8-bit characters (just like \fBmetaSendsEscape\fP). By combining the Alt- and Meta-modifiers, you can create corresponding combinations of ESC-prefix and 8-bit characters. -The default is \*(``false\*(''. .RE .IP -\fIXterm\fP provides a menu option for toggling this resource. +The default is \*(``__alt_sends_esc__\*(''. +\fI\*N\fP provides a menu option for toggling this resource. +.TP 8 +.B "alternateScroll (\fPclass\fB ScrollCond)" +If \*(``true\*('', +the \fBscroll-back\fP and \fBscroll-forw\fP actions +send cursor\-up and \-down keys when \*n is displaying the alternate screen. +The default is \*(``false\*(''. +.IP +The \fBalternateScroll\fP state can also be set using a control sequence. .TP 8 .B "alwaysBoldMode (\fPclass\fB AlwaysBoldMode)" -Specifies whether \fIxterm\fP should check if the normal and bold +Specifies whether \fI\*n\fP should check if the normal and bold fonts are distinct before deciding whether to use overstriking to simulate bold fonts. If this resource is true, -\fIxterm\fP does not make the check for +\fI\*n\fP does not make the check for distinct fonts when deciding how to handle the \fBboldMode\fP resource. The default is \*(``false\*(''. .ne 9 @@ -1733,12 +1844,27 @@ true false different use font true true ignored overstrike .TE +.RS +.LP +This resource is used only for bitmap fonts: +.bP +When using bitmap fonts, it is possible that the font server will +approximate the bold font by rescaling it from +a different font size than expected. +The \fBalwaysBoldMode\fP resource +allows the user to override the (sometimes poor) +resulting bold font with overstriking (which is at least consistent). +.bP +The problem does not occur with TrueType fonts (though there can be +other unnecessary issues such as different coverage of the normal +and bold fonts). +.RE .IP As an alternative, setting the \fBallowBoldFonts\fP resource to false overrides both the \fBalwaysBoldMode\fP and the \fBboldMode\fP resources. .TP 8 .B "alwaysHighlight (\fPclass\fB AlwaysHighlight)" -Specifies whether or not \fIxterm\fP should always display a highlighted +Specifies whether or not \fI\*n\fP should always display a highlighted text cursor. By default (if this resource is false), a hollow text cursor is displayed whenever the @@ -1746,16 +1872,16 @@ The default is \*(``false\*(''. .TP 8 .B "alwaysUseMods (\fPclass\fB AlwaysUseMods)" -Override the \fBnumLock\fP resource, telling \fIxterm\fR to use the Alt and Meta +Override the \fBnumLock\fP resource, telling \fI\*n\fR to use the Alt and Meta modifiers to construct parameters for function key sequences even if those modifiers appear in the translations resource. -Normally \fIxterm\fP checks if Alt or Meta is used in a translation that +Normally \fI\*n\fP checks if Alt or Meta is used in a translation that would conflict with function key modifiers, and will ignore these modifiers in that special case. The default is \*(``false\*(''. .TP 8 .B "answerbackString (\fPclass\fB AnswerbackString)" -Specifies the string that \fIxterm\fR sends in response to an ENQ (control/E) +Specifies the string that \fI\*n\fR sends in response to an ENQ (control/E) character from the host. The default is a blank string, i.e., \*(``\*(''. A hardware VT100 implements this feature as a setup option. @@ -1769,6 +1895,11 @@ If \*(``true\*('', the keypad keys are initially in application mode. The default is \*(``false\*(''. .TP 8 +.B "assumeAllChars (\fPclass\fB AssumeAllChars)" +If \*(``true\*('', this enables a special case in bitmap fonts to +allow the font server to choose how to display missing glyphs. +The default is \*(``false\*(''. +.TP 8 .B "autoWrap (\fPclass\fB AutoWrap)" Specifies whether or not auto-wraparound should be enabled. This is the same as the VT102 DECAWM. @@ -1776,7 +1907,7 @@ default is \*(``true\*(''. .TP 8 .B "awaitInput (\fPclass\fB AwaitInput)" -Specifies whether or not the \fIxterm\fR uses a 50 millisecond timeout to +Specifies whether or not the \fI\*n\fR uses a 50 millisecond timeout to await input (i.e., to support the Xaw3d arrow scrollbar). The default is \*(``false\*(''. .TP 8 @@ -1785,7 +1916,8 @@ a backspace (8) or delete (127) character. This corresponds to the DECBKM control sequence. -The default (backspace) is \*(``true\*(''. +A \*(``true\*('' value specifies backspace. +The default is \*(``__backarrow_is_bs__\*(''. Pressing the control key toggles this behavior. .TP 8 .B "background (\fPclass\fB Background)" @@ -1835,8 +1967,8 @@ It may be desirable to disable bold fonts when color is being used for the bold attribute. .IP -Note that \fIxterm\fP has one bold font which you may set explicitly. -\fIXterm\fP attempts to derive a bold font for the other font selections +Note that \fI\*n\fP has one bold font which you may set explicitly. +\fI\*N\fP attempts to derive a bold font for the other font selections (\fBfont1\fP through \fBfont6\fP). If it cannot find a bold font, it will use the normal font. In each case (whether the explicit resource or the derived font), @@ -1846,41 +1978,43 @@ See the \fBalwaysBoldMode\fP resource which can modify the behavior of this resource. .IP -Although \fIxterm\fP attempts to derive a bold font for other font selections, +Although \fI\*n\fP attempts to derive a bold font for other font selections, the font server may not cooperate. Since X11R6, bitmap fonts have been scaled. -The font server claims to provide the bold font that \fIxterm\fP requests, +The font server claims to provide the bold font that \fI\*n\fP requests, but the result is not always readable. XFree86 introduced a feature which can be used to suppress the scaling. In the X server's configuration file (e.g., \*(``/etc/X11/XFree86\*(''), you can add \*(``:unscaled\*('' to the end of the directory specification for the \*(``misc\*('' fonts, -which comprise the fixed-pitch fonts that are used by \fIxterm\fP. +which comprise the fixed-pitch fonts that are used by \fI\*n\fP. For example .NS FontPath "/usr/lib/X11/fonts/misc/" .NE +.IP would become .NS FontPath "/usr/lib/X11/fonts/misc/:unscaled" .NE +.IP Depending on your configuration, the font server may have its own configuration file. The same \*(``:unscaled\*('' can be added to its configuration file at the end of the directory specification for \*(``misc\*(''. .IP -The bitmap scaling feature is also used by \fIxterm\fP to implement +The bitmap scaling feature is also used by \fI\*n\fP to implement VT102 double-width and double-height characters. .TP 8 .B "brokenLinuxOSC (\fPclass\fB BrokenLinuxOSC)" -If true, \fIxterm\fP applies a workaround to ignore malformed control +If true, \fI\*n\fP applies a workaround to ignore malformed control sequences that a Linux script might send. Compare the palette control sequences documented in \fIconsole_codes\fR with ECMA-48. The default is \*(``true\*(''. .TP 8 .B "brokenSelections (\fPclass\fB BrokenSelections)" -If true, \fIxterm\fP in 8-bit mode will interpret +If true, \fI\*n\fP in 8-bit mode will interpret .B STRING selections as carrying text in the current locale's encoding. Normally @@ -1894,10 +2028,10 @@ .B "brokenStringTerm (\fPclass\fB BrokenStringTerm)" provides a work-around for some ISDN routers which start an application control string without completing it. -Set this to \*(``true\*('' if \fIxterm\fP appears to freeze when connecting. +Set this to \*(``true\*('' if \fI\*n\fP appears to freeze when connecting. The default is \*(``false\*(''. .IP -\fIXterm\fP's state parser recognizes +\fI\*N\fP's state parser recognizes several types of control strings which can contain text, e.g., .sp .RS @@ -1917,7 +2051,7 @@ Ordinary control characters found within the string are not ignored; they are processed without interfering with the process of accumulating the control string's content. -\fIXterm\fP recognizes these controls in all modes, +\fI\*N\fP recognizes these controls in all modes, although some of the functions may be suppressed after parsing the control. .IP When enabled, this feature allows the user to exit from an unterminated @@ -1953,9 +2087,17 @@ The default is \*(``false\*(''. .TP 8 .B "cacheDoublesize (\fPclass\fB CacheDoublesize)" -Tells whether to cache double-sized fonts by \fIxterm\fR. +Tells whether to cache double-sized fonts by \fI\*n\fR. Set this to zero to disable double-sized fonts altogether. .TP 8 +.B "cdXtraScroll (\fPclass\fB CdXtraScroll)" +Specifies whether \fI\*n\fP should scroll to a new page when clearing +the whole screen. +Like \fBtiXtraScroll\fP, +the intent of this option is to provide a picture of the full-screen +application's display on the scrollback before wiping out the text. +The default for this resource is \*(``false\*(''. +.TP 8 .B "charClass (\fPclass\fB CharClass)" Specifies comma-separated lists of character class bindings of the form [\fIlow\fP-]\fIhigh\fP:\fIvalue\fP. @@ -1964,7 +2106,7 @@ See the \fBCHARACTER CLASSES\fP section. .TP 8 .B "cjkWidth (\fPclass\fB CjkWidth)" -Specifies whether \fIxterm\fP should follow +Specifies whether \fI\*n\fP should follow the traditional East Asian width convention. When turned on, characters with East Asian Ambiguous (A) category in UTR 11 have a column width of 2. @@ -1972,7 +2114,7 @@ if you have some old East Asian terminal based programs that assume that line-drawing characters have a column width of 2. If this resource is false, the \fBmkWidth\fP resource controls the -choice between the system's \fBwcwidth\fP and \fIxterm\fP's built-in tables. +choice between the system's \fBwcwidth\fP and \fI\*n\fP's built-in tables. The default is \*(``false\*(''. .TP 8 .B "color0 (\fPclass\fB Color0)" @@ -2067,6 +2209,8 @@ This specifies the color to use to display bold characters if the \*(``colorBDMode\*('' resource is enabled. The default is \*(``XtDefaultForeground\*(''. +.IP +See also the \fBveryBoldColors\fP resource which allows combining bold and color. .TP 8 .B "colorBDMode (\fPclass\fB ColorAttrMode)" Specifies whether characters with the bold attribute should be displayed in @@ -2079,6 +2223,8 @@ This specifies the color to use to display blink characters if the \*(``colorBLMode\*('' resource is enabled. The default is \*(``XtDefaultForeground\*(''. +.IP +See also the \fBveryBoldColors\fP resource which allows combining underline and color. .TP 8 .B "colorBLMode (\fPclass\fB ColorAttrMode)" Specifies whether characters with the blink attribute should be displayed in @@ -2095,6 +2241,8 @@ This specifies the color to use to display reverse characters if the \*(``colorRVMode\*('' resource is enabled. The default is \*(``XtDefaultForeground\*(''. +.IP +See also the \fBveryBoldColors\fP resource which allows combining reverse and color. .TP 8 .B "colorRVMode (\fPclass\fB ColorAttrMode)" Specifies whether characters with the reverse attribute should be displayed in @@ -2106,6 +2254,8 @@ This specifies the color to use to display underlined characters if the \*(``colorULMode\*('' resource is enabled. The default is \*(``XtDefaultForeground\*(''. +.IP +See also the \fBveryBoldColors\fP resource which allows combining underline and color. .TP 8 .B "colorULMode (\fPclass\fB ColorAttrMode)" Specifies whether characters with the underline attribute should be displayed @@ -2137,17 +2287,22 @@ .B "cursorBlink (\fPclass\fB CursorBlink)" Specifies whether to make the cursor blink. The default is \*(``false\*(''. +.IP +\fI\*N\fP uses two variables to determine whether the cursor blinks. +One is set by this resource. +The other is set by control sequences (private mode 12 and DECSCUSR). +\fI\*N\fP tests the XOR of the two variables. .TP 8 .B "cursorColor (\fPclass\fB CursorColor)" Specifies the color to use for the text cursor. The default is \*(``XtDefaultForeground\*(''. By default, -\fIxterm\fP attempts to keep this color from being the same as the background +\fI\*n\fP attempts to keep this color from being the same as the background color, since it draws the cursor by filling the background of a text cell. The same restriction applies to control sequences which may change this color. .IP Setting this resource overrides -most of \fIxterm\fP's adjustments to cursor color. +most of \fI\*n\fP's adjustments to cursor color. It will still use reverse-video to disallow some cases, such as a black cursor on a black background. .TP 8 @@ -2187,7 +2342,7 @@ The default is \*(``__default_termid__\*(''. .TP 8 .B "defaultString (\fPclass\fB DefaultString)" -Specify the character (or string) which \fIxterm\fP will substitute when +Specify the character (or string) which \fI\*n\fP will substitute when pasted text includes a character which cannot be represented in the current encoding. For instance, pasting UTF-8 text into a display of ISO-8859-1 characters @@ -2196,13 +2351,14 @@ The default is \*(``#\*('' (a single pound sign). .IP If the undisplayable text would be double-width, -\fIxterm\fP will add a space after the \*(``#\*('' character, to give roughly +\fI\*n\fP will add a space after the \*(``#\*('' character, to give roughly the same layout on the screen as the original text. .TP 8 .B "deleteIsDEL (\fPclass\fB DeleteIsDEL)" Specifies whether the Delete key on the editing keypad should send DEL (127) or the VT220-style Remove escape sequence. -The default is \*(``false\*('', for the latter. +A \*(``false\*('' value enables the latter. +The default is \*(``__delete_is_del__\*(''. .TP 8 .B "disallowedColorOps (\fPclass\fB DisallowedColorOps)" Specify which features will be disabled if \fBallowColorOps\fP is false. @@ -2213,7 +2369,7 @@ .RE .IP The names are listed below. -\fIxterm\fP ignores capitalization, but +\fI\*n\fP ignores capitalization, but they are shown in mixed-case for clarity. .RS .TP 5 @@ -2237,7 +2393,7 @@ .RE .IP The names are listed below. -\fIxterm\fP ignores capitalization, but +\fI\*n\fP ignores capitalization, but they are shown in mixed-case for clarity. .RS .TP 5 @@ -2257,7 +2413,7 @@ .RE .IP The names are listed below. -\fIxterm\fP ignores capitalization, but +\fI\*n\fP ignores capitalization, but they are shown in mixed-case for clarity. .RS .TP 5 @@ -2278,14 +2434,14 @@ .RE .IP The names are listed below. -\fIxterm\fP ignores capitalization, but +\fI\*n\fP ignores capitalization, but they are shown in mixed-case for clarity. Where a number can be used as an alternative, it is given in parentheses after the name. .RS .TP 5 GetIconTitle (20) -Report xterm window's icon label as a string. +Report \*n window's icon label as a string. .TP 5 GetScreenSizeChars (19) Report the size of the screen in characters as numbers. @@ -2294,22 +2450,22 @@ Report selection data as a base64 string. .TP 5 GetWinPosition (13) -Report xterm window position as numbers. +Report \*n window position as numbers. .TP 5 GetWinSizeChars (18) Report the size of the text area in characters as numbers. .TP 5 GetWinSizePixels (14) -Report xterm window in pixels as numbers. +Report \*n window in pixels as numbers. .TP 5 GetWinState (11) -Report xterm window state as a number. +Report \*n window state as a number. .TP 5 GetWinTitle (21) -Report xterm window's title as a string. +Report \*n window's title as a string. .TP 5 LowerWin (6) -Lower the xterm window to the bottom of the stacking order. +Lower the \*n window to the bottom of the stacking order. .TP 5 MaximizeWin (9) Maximize window (i.e., resize to screen size). @@ -2327,10 +2483,10 @@ Push title to internal stack. .TP 5 RaiseWin (5) -Raise the xterm window to the front of the stacking order. +Raise the \*n window to the front of the stacking order. .TP 5 RefreshWin (7) -Refresh the xterm window. +Refresh the \*n window. .TP 5 RestoreWin (1) De-iconify window. @@ -2348,7 +2504,7 @@ Resize the text area to given size in characters. .TP 5 SetWinSizePixels (4) -Resize the xterm window to given size in pixels. +Resize the \*n window to given size in pixels. .TP 5 SetXprop Set X property on top-level window. @@ -2387,7 +2543,7 @@ X defines modifiers for shift, (caps) lock and control, as well as 5 additional modifiers which are generally used to configure key modifiers. -\fIxterm\fP inspects the same information to find the modifier associated +\fI\*n\fP inspects the same information to find the modifier associated with either \fIMeta\fP key (left or right), and uses that key as the \fIMeta\fP modifier. It also looks for the NumLock key, @@ -2395,26 +2551,26 @@ .IP If your \fIxmodmap\fP configuration uses the same keycodes for Alt- and Meta-keys, -\fIxterm\fP will only see the Alt-key definitions, since those are tested +\fI\*n\fP will only see the Alt-key definitions, since those are tested before Meta-keys. NumLock is tested first. It is important to keep these keys distinct; -otherwise some of \fIxterm\fP's functionality is not available. +otherwise some of \fI\*n\fP's functionality is not available. .IP The \fBeightBitInput\fP resource is tested at startup time. If \*(``true\*('', -the \fIxterm\fP tries to put the terminal into 8-bit mode. +the \fI\*n\fP tries to put the terminal into 8-bit mode. If \*(``false\*('', -on startup, \fIxterm\fP tries to put the terminal into 7-bit mode. +on startup, \fI\*n\fP tries to put the terminal into 7-bit mode. For some configurations this is unsuccessful; failure is ignored. -After startup, \fIxterm\fP does not +After startup, \fI\*n\fP does not change the terminal between 8-bit and 7-bit mode. .IP As originally implemented in X11, the resource value did not change after startup. However (since patch #216 in 2006) -\fIxterm\fP can modify \fBeightBitInput\fP after startup +\fI\*n\fP can modify \fBeightBitInput\fP after startup via a control sequence. The corresponding terminfo capabilities \fBsmm\fP (set meta mode) and \fBrmm\fP (reset meta mode) @@ -2423,13 +2579,13 @@ differs from the standard definition (in the \fIterminfo\fP manual), which describes the change to the eighth bit of a character. It happens that \fIbash\fP views "meta mode" -as the ESC character that \fIxterm\fP puts before a character when a +as the ESC character that \fI\*n\fP puts before a character when a special meta key is pressed. \fIbash\fP's early documentation talks about the ESC character and ignores the eighth bit. .TP 8 .B "eightBitMeta (\fPclass\fB EightBitMeta\fP)" -This controls the way \fIxterm\fP modifies the eighth bit of a single-byte +This controls the way \fI\*n\fP modifies the eighth bit of a single-byte key when the \fBeightBitInput\fP resource is set. The default is \*(``locale\*(''. .IP @@ -2449,13 +2605,13 @@ The key is always sent unmodified. .RE .IP -Except for the \fBnever\fP choice, \fIxterm\fP honors the +Except for the \fBnever\fP choice, \fI\*n\fP honors the terminfo capabilities \fBsmm\fP (set meta mode) and \fBrmm\fP (reset meta mode), allowing the feature to be turned on or off dynamically. .IP If \fBeightBitMeta\fP is enabled when the locale uses UTF-8, -\fIxterm\fP encodes the value as UTF-8 +\fI\*n\fP encodes the value as UTF-8 (since patch #183 in 2003). .TP 8 .B "eightBitOutput (\fPclass\fB EightBitOutput\fP)" @@ -2465,19 +2621,19 @@ which means that they are accepted as is. .TP 8 .B "eightBitSelectTypes (\fPclass\fB EightBitSelectTypes\fP)" -Override \fIxterm\fP's default selection target list (see SELECT/PASTE) for +Override \fI\*n\fP's default selection target list (see SELECT/PASTE) for selections in normal (ISO-8859-1) mode. The default is an empty string, i.e., \*(``\*('', which does not override anything. .TP 8 .B "faceName (\fPclass\fB FaceName)" Specify the pattern for scalable fonts selected from the FreeType -library if support for that library was compiled into \fIxterm\fR. +library if support for that library was compiled into \fI\*n\fR. There is no default value. .IP If not specified, or if there is no match for both normal and bold fonts, -\fIxterm\fR uses the bitmap \fBfont\fP and related resources. +\fI\*n\fR uses the bitmap \fBfont\fP and related resources. .IP It is possible to select suitable bitmap fonts using a script such as this: .NS @@ -2485,6 +2641,7 @@ \&FONT=`xfontsel -print` \&test -n "$FONT" && xfd -fn "$FONT" .NE +.IP However (even though \fIxfd\fP accepts a \*(``\fB\-fa\fP\*('' option to denote FreeType fonts), \fIxfontsel\fP has not been similarly extended. @@ -2492,6 +2649,7 @@ .NS fc-list :scalable=true:spacing=mono: family .NE +.IP to find a list of scalable fixed-pitch fonts which may be used for the \fBfaceName\fP resource value. .TP 8 @@ -2501,11 +2659,11 @@ There is no default value. .IP If the application uses double-wide characters and this resource is not given, -\fIxterm\fP will use a scaled version of the font given by \fBfaceName\fP. +\fI\*n\fP will use a scaled version of the font given by \fBfaceName\fP. .TP 8 .B "faceSize (\fPclass\fB FaceSize)" Specify the pointsize for fonts selected from the FreeType -library if support for that library was compiled into \fIxterm\fR. +library if support for that library was compiled into \fI\*n\fR. The default is \*(``14.0\*('' On the \fBVT\ Fonts\fP menu, this corresponds to the \fIDefault\fP entry. .IP @@ -2523,16 +2681,16 @@ the following resource values. If you do not specify a value, they default to \*(``0.0\*('', -which causes \fIxterm\fP to use the ratio of font sizes +which causes \fI\*n\fP to use the ratio of font sizes from the corresponding bitmap font resources to obtain a TrueType pointsize. .IP -If all of the \fBfaceSize\fP resources are set, then \fIxterm\fP +If all of the \fBfaceSize\fP resources are set, then \fI\*n\fP will use this information to determine the next smaller/larger TrueType font for the -\fIlarger-vt-font()\fP and -\fIsmaller-vt-font()\fP actions. -If any are not set, \fIxterm\fP will use only the areas of the bitmap fonts. +\fBlarger-vt-font()\fP and +\fBsmaller-vt-font()\fP actions. +If any are not set, \fI\*n\fP will use only the areas of the bitmap fonts. .TP 8 .B "faceSize1 (\fPclass\fB FaceSize1)" Specifies the pointsize of the first alternative font. @@ -2563,14 +2721,17 @@ .NS *font: fixed .NE +.IP which are overly broad, affecting both .NS xterm.vt100.font .NE +.IP and .NS xterm.vt100.utf8Fonts.font .NE +.IP which is probably not what you intended. .TP 8 .B "fastScroll (\fPclass\fB FastScroll)" @@ -2581,34 +2742,40 @@ For instance, \fIcat\fP'ing a large file to the screen does this. .TP 8 .B "font1 (\fPclass\fB Font1)" -Specifies the name of the first alternative font. +Specifies the name of the first alternative font, +corresponding to \*(``Unreadable\*('' in the standard menu. .TP 8 .B "font2 (\fPclass\fB Font2)" -Specifies the name of the second alternative font. +Specifies the name of the second alternative font, +corresponding to \*(``Tiny\*('' in the standard menu. .TP 8 .B "font3 (\fPclass\fB Font3)" -Specifies the name of the third alternative font. +Specifies the name of the third alternative font, +corresponding to \*(``Small\*('' in the standard menu. .TP 8 .B "font4 (\fPclass\fB Font4)" -Specifies the name of the fourth alternative font. +Specifies the name of the fourth alternative font, +corresponding to \*(``Medium\*('' in the standard menu. .TP 8 .B "font5 (\fPclass\fB Font5)" -Specifies the name of the fifth alternative font. +Specifies the name of the fifth alternative font, +corresponding to \*(``Large\*('' in the standard menu. .TP 8 .B "font6 (\fPclass\fB Font6)" -Specifies the name of the sixth alternative font. +Specifies the name of the sixth alternative font, +corresponding to \*(``Huge\*('' in the standard menu. .TP 8 .B "fontDoublesize (\fPclass\fB FontDoublesize)" -Specifies whether \fIxterm\fP should attempt to use font scaling to draw +Specifies whether \fI\*n\fP should attempt to use font scaling to draw double-sized characters. Some older font servers cannot do this properly, will return misleading font metrics. The default is \*(``true\*(''. -If disabled, \fIxterm\fP will simulate double-sized characters by drawing +If disabled, \fI\*n\fP will simulate double-sized characters by drawing normal characters with spaces between them. .TP 8 .B "fontWarnings (\fPclass\fB FontWarnings)" -Specify whether \fIxterm\fP should report an error if it fails to load a font: +Specify whether \fI\*n\fP should report an error if it fails to load a font: .RS .TP 5 0 @@ -2624,28 +2791,26 @@ The default is \*(``1\*(''. .TP 8 .B "forceBoxChars (\fPclass\fB ForceBoxChars)" -Specifies whether \fIxterm\fP should assume the normal and bold fonts +Specifies whether \fI\*n\fP should assume the normal and bold fonts have VT100 line-drawing characters: .RS -.TP 5 -- -The fixed-pitch ISO-8859-*-encoded fonts used by \fIxterm\fP +.bP +The fixed-pitch ISO-8859-*-encoded fonts used by \fI\*n\fP normally have the VT100 line-drawing glyphs in cells 1-31. Other fixed-pitch fonts may be more attractive, but lack these glyphs. -.TP -- +.bP When using an ISO-10646-1 font and the \fBwideChars\fP resource is true, -\fIxterm\fP uses the Unicode glyphs which match the VT100 line-drawing glyphs. +\fI\*n\fP uses the Unicode glyphs which match the VT100 line-drawing glyphs. .RE .IP -If \*(``false\*('', \fIxterm\fP checks for missing glyphs in the font +If \*(``false\*('', \fI\*n\fP checks for missing glyphs in the font and makes line-drawing characters directly as needed. -If \*(``true\*('', \fIxterm\fP assumes the font does not contain the +If \*(``true\*('', \fI\*n\fP assumes the font does not contain the line-drawing characters, and draws them directly. The default is \*(``false\*(''. .TP 8 .B "forcePackedFont (\fPclass\fB ForcePackedFont)" -Specifies whether \fIxterm\fP should use the maximum or minimum glyph +Specifies whether \fI\*n\fP should use the maximum or minimum glyph width when displaying using a bitmap font. Use the maximum width to help with proportional fonts. The default is \*(``true\*('', denoting the minimum width. @@ -2671,9 +2836,9 @@ .RE .TP 8 .B "freeBoldBox (\fPclass\fB FreeBoldBox)" -Specifies whether \fIxterm\fP should assume the bounding boxes for +Specifies whether \fI\*n\fP should assume the bounding boxes for normal and bold fonts are compatible. -If \*(``false\*('', \fIxterm\fP compares them and will reject choices of +If \*(``false\*('', \fI\*n\fP compares them and will reject choices of bold fonts that do not match the size of the normal font. The default is \*(``false\*('', which means that the comparison is performed. .TP 8 @@ -2687,11 +2852,11 @@ The default is \*(``XtDefaultForeground\*(''. .TP 8 .B "highlightColorMode (\fPclass\fB HighlightColorMode)" -Specifies whether \fIxterm\fP should use +Specifies whether \fI\*n\fP should use \fBhighlightTextColor\fP and \fBhighlightColor\fP to override the reversed foreground/background colors in a selection. The default is unspecified: -at startup, \fIxterm\fP checks if those resources are set to something +at startup, \fI\*n\fP checks if those resources are set to something other than the default foreground and background colors. Setting this resource disables the check. .IP @@ -2751,25 +2916,25 @@ .TE .TP 8 .B "highlightReverse (\fPclass\fB HighlightReverse)" -Specifies whether \fIxterm\fP should reverse the selection foreground +Specifies whether \fI\*n\fP should reverse the selection foreground and background colors when selecting text with reverse-video attribute. This applies only to the \fBhighlightColor\fP and \fBhighlightTextColor\fP resources, e.g., to match the color scheme of \fIxwsh\fP. -If \*(``true\*('', \fIxterm\fP reverses the colors, -If \*(``false\*('', \fIxterm\fP does not reverse colors, +If \*(``true\*('', \fI\*n\fP reverses the colors, +If \*(``false\*('', \fI\*n\fP does not reverse colors, The default is \*(``true\*(''. .TP 8 .B "highlightSelection (\fPclass\fB HighlightSelection)" If \*(``false\*('', selecting with the mouse highlights all positions on the screen between the beginning of the selection and the current position. -If \*(``true\*('', \fIxterm\fP highlights only the positions that contain text that +If \*(``true\*('', \fI\*n\fP highlights only the positions that contain text that can be selected. The default is \*(``false\*(''. .IP Depending on the way your applications write to the screen, there may be trailing blanks on a line. -\fIXterm\fP stores data as it is shown on the screen. +\fI\*N\fP stores data as it is shown on the screen. Erasing the display changes the internal state of each cell so it is not considered a blank for the purpose of selection. Blanks written since the last erase are selectable. @@ -2785,12 +2950,12 @@ Specifies whether to work around a bug in HP's \fIxdb\fP, which ignores termcap and always sends ESC F to move to the lower left corner. -\*(``true\*('' causes \fIxterm\fP to interpret ESC F as a request to move to the +\*(``true\*('' causes \fI\*n\fP to interpret ESC F as a request to move to the lower left corner of the screen. The default is \*(``false\*(''. .TP 8 .B "i18nSelections (\fPclass\fB I18nSelections)" -If false, \fIxterm\fP will not request the targets +If false, \fI\*n\fP will not request the targets .B COMPOUND_TEXT or .BR TEXT . @@ -2799,28 +2964,28 @@ .TP 8 .B "iconBorderColor (\fPclass\fB BorderColor)" Specifies the border color for the active icon window if this feature -is compiled into \fIxterm\fR. +is compiled into \fI\*n\fR. Not all window managers will make the icon border visible. .TP 8 .B "iconBorderWidth (\fPclass\fB BorderWidth)" Specifies the border width for the active icon window if this feature -is compiled into \fIxterm\fR. +is compiled into \fI\*n\fR. The default is \*(``2\*(''. Not all window managers will make the border visible. .TP 8 .B "iconFont (\fPclass\fB IconFont)" Specifies the font for the miniature active icon window, if this feature -is compiled into \fIxterm\fR. +is compiled into \fI\*n\fR. The default is \*(``nil2\*(''. .TP 8 .B "initialFont (\fPclass\fB InitialFont)" Specifies which of the VT100 fonts to use initially. -Values are the same as for the \fIset-vt-font\fP action. +Values are the same as for the \fBset-vt-font\fP action. The default is \*(``d\*('', i.e., \*(``default\*(''. .TP 8 .B "inputMethod (\fPclass\fB XtCInputMethod)" -Tells \fIxterm\fP which type of input method to use. +Tells \fI\*n\fP which type of input method to use. There is no default method. .TP 8 .B "internalBorder (\fPclass\fB BorderWidth)" @@ -2839,7 +3004,7 @@ See \fBfastScroll\fP for a variation. .TP 8 .B "keepSelection (\fPclass\fB KeepSelection)" -Specifies whether \fIxterm\fR will keep the selection even after the +Specifies whether \fI\*n\fR will keep the selection even after the selected area was touched by some output to the terminal. The default is \*(``true\*(''. .TP 8 @@ -2865,7 +3030,7 @@ .RS .TP 4 .I true -\fIxterm\fR will use the +\fI\*n\fR will use the encoding specified by the users' LC_CTYPE locale (i.e., LC_ALL, LC_CTYPE, or LANG variables) as far as possible. This is realized @@ -2873,22 +3038,22 @@ locales. .TP .I medium -\fIxterm\fR will follow users' +\fI\*n\fR will follow users' LC_CTYPE locale only for UTF-8, east Asian, and Thai locales, where the encodings were not supported by conventional 8bit mode with changing fonts. -For other locales, \fIxterm\fR will use conventional 8bit mode. +For other locales, \fI\*n\fR will use conventional 8bit mode. .TP .I checkfont -If mini-luit is compiled-in, \fIxterm\fR will check if a Unicode font has +If mini-luit is compiled-in, \fI\*n\fR will check if a Unicode font has been specified. If so, it checks if the character encoding for the current locale is POSIX, Latin-1 or Latin-9, uses the appropriate mapping to support those with the Unicode font. -For other encodings, \fIxterm\fR assumes that UTF-8 encoding is required. +For other encodings, \fI\*n\fR assumes that UTF-8 encoding is required. .TP .I false -\fIxterm\fR will use conventional 8bit mode +\fI\*n\fR will use conventional 8bit mode or UTF-8 mode according to \fButf8\fR resource or \fB\-u8\fP option. .RE .IP @@ -2901,8 +3066,8 @@ Regardless of your locale and encoding, you need an ISO-10646-1 font to display the result. Your configuration may not include this font, -or locale-support by \fIxterm\fP may not be needed. -At startup, \fIxterm\fP uses a mechanism equivalent to +or locale-support by \fI\*n\fP may not be needed. +At startup, \fI\*n\fP uses a mechanism equivalent to the \fBload-vt-fonts(utf8Fonts,\ Utf8Fonts)\fP action to load font name subresources of the VT100 widget. That is, @@ -2910,13 +3075,13 @@ and (if this resource is enabled), override the normal fonts. If no subresources are found, the normal fonts such as \*(``\fB*vt100.font\fP\*('', etc., are used. -The resource files distributed with \fIxterm\fP use ISO-10646-1 fonts, +The resource files distributed with \fI\*n\fP use ISO-10646-1 fonts, but do not rely on them unless you are using the locale mechanism. .TP 8 .B "localeFilter (\fPclass\fB LocaleFilter)" Specifies the file name for the encoding converter from/to locale encodings and UTF-8 which is used with the \fB\-lc\fR option or \fBlocale\fR resource. -The help message shown by \*(``xterm \-help\*('' lists the default value, +The help message shown by \*(``\*n \-help\*('' lists the default value, which depends on your system configuration. .IP If the encoding converter requires command-line parameters, @@ -2924,9 +3089,15 @@ .NS *localeFilter: xterm-filter -p .NE +.IP Alternatively, you may put those parameter within a shell script to execute the converter, and set this resource to point to the shell script. +.IP +When using a locale-filter, e.g., with the \fI\-e\fP option, or the shell, +\fI\*n\fP first tries passing control via that filter. +If it fails, \fI\*n\fP will retry without the locale-filter. +\fI\*N\fP warns about the failure before retrying. .TP 8 .B "loginShell (\fPclass\fB LoginShell)" Specifies whether or not the shell to be run in the window should be started @@ -2943,16 +3114,16 @@ (a character combined with the \fIMeta\fP modifier key) are converted into a two-character sequence with the character itself preceded by ESC. -This applies as well to function key control sequences, unless \fIxterm\fP +This applies as well to function key control sequences, unless \fI\*n\fP sees that \fBMeta\fP is used in your key translations. If \*(``false\*('', Meta characters input from the keyboard are handled according to the \fBeightBitInput\fP resource. -The default is \*(``false\*(''. +The default is \*(``__meta_sends_esc__\*(''. .TP 8 .B "mkSamplePass (\fPclass\fB MkSamplePass)" If \fBmkSampleSize\fP is nonzero, and \fBmkWidth\fP (and \fBcjkWidth\fP) are false, -on startup \fIxterm\fP compares its built-in tables to the system's +on startup \fI\*n\fP compares its built-in tables to the system's wide character width data to decide if it will use the system's data. It tests the first \fBmkSampleSize\fP character values, and allows up to \fBmkSamplePass\fP mismatches before the test fails. @@ -2964,7 +3135,7 @@ The default (number of characters to check) is 1024. .TP 8 .B "mkWidth (\fPclass\fB MkWidth)" -Specifies whether \fIxterm\fP should use a built-in version of the wide +Specifies whether \fI\*n\fP should use a built-in version of the wide character width calculation. See also the \fBcjkWidth\fP resource which can override this. The default is \*(``false\*(''. @@ -2988,17 +3159,24 @@ Control-, Shift-, Alt- or Meta-modifiers are used to add a parameter to the escape sequence returned by a cursor-key. The default is \*(``2\*('': -.IP -Set it to \-1 to disable it. -.br -Set it to 0 to use the old/obsolete behavior. -.br -Set it to 1 to prefix modified sequences with CSI. -.br -Set it to 2 to force the modifier to be the second parameter if it would +.RS +.TP 5 +\-1 +disables the feature. +.TP 5 +0 +uses the old/obsolete behavior. +.TP 5 +1 +prefixes modified sequences with CSI. +.TP 5 +2 +forces the modifier to be the second parameter if it would otherwise be the first. -.br -Set it to 3 to mark the sequence with a \*(``>\*('' to hint that it is private. +.TP 5 +3 +marks the sequence with a \*(``>\*('' to hint that it is private. +.RE .TP 8 .B "modifyFunctionKeys (\fPclass\fB ModifyFunctionKeys\fP)" Tells how to handle the special case where @@ -3006,21 +3184,28 @@ the escape sequence returned by a (numbered) function-key. The default is \*(``2\*(''. The resource values are similar to \fBmodifyCursorKeys\fP: -.IP -Set it to \-1 to permit the user to use shift- and control-modifiers +.RS +.TP 5 +\-1 +permits the user to use shift- and control-modifiers to construct function-key strings using the normal encoding scheme. -.br -Set it to 0 to use the old/obsolete behavior. -.br -Set it to 1 to prefix modified sequences with CSI. -.br -Set it to 2 to force the modifier to be the second parameter if it would +.TP 5 +0 +uses the old/obsolete behavior. +.TP 5 +1 +prefixes modified sequences with CSI. +.TP 5 +2 +forces the modifier to be the second parameter if it would otherwise be the first. -.br -Set it to 3 to mark the sequence with a \*(``>\*('' to hint that it is private. +.TP 5 +3 +marks the sequence with a \*(``>\*('' to hint that it is private. +.RE .IP If \fBmodifyFunctionKeys\fP is zero, -\fIxterm\fP uses Control- and Shift-modifiers to allow the user to +\fI\*n\fP uses Control- and Shift-modifiers to allow the user to construct numbered function-keys beyond the set provided by the keyboard: .RS @@ -3035,15 +3220,40 @@ adds three times the value given by the \fBctrlFKeys\fP resource. .RE .IP -As a special case, -legacy (when \fBoldFunctionKeys\fP is true) -or vt220 (when \fBsunKeyboard\fP is true) keyboards interpret only the -Control-modifier when constructing numbered function-keys. +.TP 8 +.B "modifyKeyboard (\fPclass\fB ModifyKeyboard\fP)" +Normally \fI\*n\fP makes a special case regarding +modifiers (shift, control, etc.) +to handle special keyboard layouts (\fBlegacy\fP and \fBvt220\fP). This is done to provide compatible keyboards for DEC VT220 and related terminals that implement user-defined keys (UDK). +.IP +The bits of the resource value selectively enable +modification of the given category when these keyboards are selected. +The default is \*(``0\*('': +.RS +.TP 5 +0 +The legacy/vt220 keyboards interpret only the +Control-modifier when constructing numbered function-keys. +Other special keys are not modified. +.TP 5 +1 +allows modification of the numeric keypad +.TP 5 +2 +allows modification of the editing keypad +.TP 5 +4 +allows modification of function-keys, +overrides use of Shift-modifier for UDK. +.TP 5 +8 +allows modification of other special keys +.RE .TP 8 .B "modifyOtherKeys (\fPclass\fB ModifyOtherKeys\fP)" -Like \fBmodifyCursorKeys\fP, tells \fIxterm\fP to construct an +Like \fBmodifyCursorKeys\fP, tells \fI\*n\fP to construct an escape sequence for other keys (such as \*(``2\*('') when modified by Control-, Alt- or Meta-modifiers. This feature does not apply to function keys and well-defined @@ -3078,7 +3288,7 @@ The default is \*(``10\*(''. .TP 8 .B "numLock (\fPclass\fB NumLock)" -If \*(``true\*('', \fIxterm\fR checks if NumLock is used as a modifier (see \fIxmodmap\fP(__mansuffix__)). +If \*(``true\*('', \fI\*n\fR checks if NumLock is used as a modifier (see \fIxmodmap\fP(__mansuffix__)). If so, this modifier is used to simplify the logic when implementing special NumLock for the \fBsunKeyboard\fP resource. Also (when \fBsunKeyboard\fP is false), similar logic is used to find the @@ -3086,8 +3296,8 @@ The default is \*(``true\*(''. .TP 8 .B "oldXtermFKeys (\fPclass\fB OldXtermFKeys)" -If \*(``true\*('', \fIxterm\fR will use old-style control sequences for function keys F1 to F4, -for compatibility with X Consortium \fIxterm\fR. +If \*(``true\*('', \fI\*n\fR will use old-style control sequences for function keys F1 to F4, +for compatibility with X Consortium \fI\*n\fR. Otherwise, it uses the VT100-style codes for PF1 to PF4. The default is \*(``false\*(''. @@ -3132,7 +3342,7 @@ .TP none No selection action is associated with this resource. -\fIxterm\fP interprets it as the end of the list. +\fI\*n\fP interprets it as the end of the list. For example, you may use it to disable triple (and higher) clicking by setting \fBon3Clicks\fP to \*(``none\*(''. .RE @@ -3141,11 +3351,11 @@ \*(``word\*('' and \*(``line\*('', respectively. There is no default value for \fBon4Clicks\fP or \fBon5Clicks\fP, making those inactive. -On startup, \fIxterm\fP determines the maximum number of clicks +On startup, \fI\*n\fP determines the maximum number of clicks by the \fBon\fP\fIX\fP\fBClicks\fP resource values which are set. .TP 8 .B "openIm (\fPclass\fB XtCOpenIm)" -Tells \fIxterm\fP whether to open the input method at startup. +Tells \fI\*n\fP whether to open the input method at startup. The default is \*(``true\*(''. .TP 8 .B "pointerColor (\fPclass\fB PointerColor)" @@ -3168,7 +3378,7 @@ never .TP 3 1 -the application running in \fIxterm\fP has not activated mouse mode. +the application running in \fI\*n\fP has not activated mouse mode. This is the default. .TP 3 2 @@ -3187,8 +3397,14 @@ However, the \fBzIconBeep\fP resource provides you with the ability to see which iconified windows have sounded a bell. .TP 8 +.B "precompose (\fPclass\fB XtCPrecompose)" +Tells \fI\*n\fP whether to precompose UTF-8 data into Normalization Form C, +which combines commonly-used accents onto base characters. +If it does not do this, accents are left as separatate characters. +The default is \*(``true\*(''. +.TP 8 .B "preeditType (\fPclass\fB XtCPreeditType)" -Tells \fIxterm\fP which types of preedit (preconversion) string to display. +Tells \fI\*n\fP which types of preedit (preconversion) string to display. The default is \*(``OverTheSpot,Root\*(''. .TP 8 .B "printAttributes (\fPclass\fB PrintAttributes)" @@ -3209,7 +3425,7 @@ .TP 8 .B "printFileImmediate (\fPPrintFileImmediate)" When the \fBprint-immediate\fP action is invoked, -\fIxterm\fP prints the screen contents directly to a file. +\fI\*n\fP prints the screen contents directly to a file. Set this resource to the prefix of the filename (a timestamp will be appended to the actual name). .IP @@ -3218,7 +3434,7 @@ if the string is empty, then \*(``__default_class__\*('' is used. .TP 8 .B "printFileOnXError (\fPPrintFileOnXError)" -If \fIxterm\fP exits with an X error, +If \fI\*n\fP exits with an X error, e.g., your connection is broken when the server crashes, it can be told to write the contents of the screen to a file. To enable the feature, set this resource to the prefix of the filename @@ -3236,14 +3452,14 @@ .TP 8 .B "printModeImmediate (\fPPrintModeImmediate)" When the \fBprint-immediate\fP action is invoked, -\fIxterm\fP prints the screen contents directly to a file. +\fI\*n\fP prints the screen contents directly to a file. You can use the \fBprintModeImmediate\fP resource to tell it to use escape sequences to reconstruct the video attributes and colors. This uses the same values as the \fBprintAttributes\fP resource. The default is \*(``0\*(''. .TP 8 .B "printModeOnXError (\fPPrintModeOnXError)" -\fIXterm\fP implements the \fBprintFileOnXError\fP feature using +\fI\*N\fP implements the \fBprintFileOnXError\fP feature using the printer feature, although the output is written directly to a file. You can use the \fBprintModeOnXError\fP resource to tell it to use escape sequences to reconstruct the video attributes and colors. @@ -3264,7 +3480,7 @@ select the range: .RS .TP 3 -8 +8 selects the saved lines. .TP 3 4 @@ -3291,13 +3507,13 @@ plus saved lines, with no special case for the alternated screen. .TP 8 .B "printerAutoClose (\fPclass\fB PrinterAutoClose)" -If \*(``true\*('', \fIxterm\fR will close the printer (a pipe) when the application switches +If \*(``true\*('', \fI\*n\fR will close the printer (a pipe) when the application switches the printer offline with a Media Copy command. The default is \*(``false\*(''. .TP 8 .B "printerCommand (\fPclass\fB PrinterCommand)" Specifies a shell command to which -.I xterm +.I \*n will open a pipe when the first MC (Media Copy) command is initiated. The default is an empty string, i.e., \*(``\*(''. @@ -3306,7 +3522,7 @@ .B "printerControlMode (\fPclass\fB PrinterControlMode)" Specifies the printer control mode. A \*(``1\*('' selects autoprint mode, which causes -.I xterm +.I \*n to print a line from the screen when you move the cursor off that line with a line feed, form feed or vertical tab character, or an autowrap occurs. @@ -3329,6 +3545,13 @@ page function. The default is \*(``true\*(''. .TP 8 +.B "privateColorRegisters (\fPclass\fB privateColorRegisters)" +If true, allocate separate color registers for each sixel +device control string, e.g., for DECGCI. +If not true, color registers are allocated only once, +when the terminal is reset. +The default is \*(``true\*(''. +.TP 8 .B "quietGrab (\fPclass\fB QuietGrab)" Controls whether the cursor is repainted when \fINotifyGrab\fP and \fINotifyUngrab\fP @@ -3336,7 +3559,7 @@ The default is \*(``false\*(''. .TP 8 .B "renderFont (\fPclass\fB RenderFont)" -If \fIxterm\fR is built with the Xft library, +If \fI\*n\fR is built with the Xft library, this controls whether the \fBfaceName\fR resource is used. The default is \*(``default\*(''. .IP @@ -3365,7 +3588,7 @@ .IP If there is no \fBfaceName\fP resource set, then runtime switching to TrueType fonts is disabled. -\fIXterm\fP has a separate compiled-in value for \fBfaceName\fP +\fI\*N\fP has a separate compiled-in value for \fBfaceName\fP for the special case where \fBrenderFont\fP is \*(``default\*(''. That is normally \*(``mono\*(''. .RE @@ -3388,7 +3611,7 @@ top of the screen, and the top saved lines will be dropped. .TP 8 .B "retryInputMethod (\fPclass\fB XtCRetryInputMethod)" -Tells \fIxterm\fP how many times to retry, +Tells \fI\*n\fP how many times to retry, in case the input-method server is not responding. This is a different issue than unsupported preedit type, etc. You may encounter retries if your X configuration (and its libraries) @@ -3401,18 +3624,18 @@ The default is \*(``false\*(''. .IP -There are several aspects to reverse video in \fIxterm\fP: +There are several aspects to reverse video in \fI\*n\fP: .RS .bP The command-line \fB\-rv\fP option tells the X libraries to reverse the foreground and background colors. -\fIXterm\fP's command-line options set resource values. +\fI\*N\fP's command-line options set resource values. In particular, the X Toolkit sets the \fBreverseVideo\fP resource when the \fB\-rv\fP option is used. .bP -If the user has also used command-line options \fB\-fg\fP or \fB\-bg\fP +If the user has also used command-line options \fB\-fg\fP or \fB\-bg\fP to set the foreground and background colors, -\fIxterm\fP does not see these options directly. +\fI\*n\fP does not see these options directly. Instead, it examines the resource values to reconstruct the command-line options, and determine which of the colors is the user's intended foreground, etc. @@ -3429,10 +3652,10 @@ the \fBreverseVideo\fP resource applies to more than the VT100 widget. .RE .IP -Programs running in an \fIxterm\fP can also use control sequences +Programs running in an \fI\*n\fP can also use control sequences to enable the VT100 reverse video mode. These are independent of the \fIreverseVideo\fP resource and the menu entry. -\fIXterm\fP exchanges the current foreground and background colors +\fI\*N\fP exchanges the current foreground and background colors when drawing text affected by these control sequences. .IP Other control sequences can alter the foreground and background colors @@ -3451,7 +3674,7 @@ .TP 8 .B "reverseWrap (\fPclass\fB ReverseWrap)" Specifies whether or not reverse-wraparound should be enabled. -This corresponds to \fIxterm\fP's private mode 45. +This corresponds to \fI\*n\fP's private mode 45. The default is \*(``false\*(''. .TP 8 @@ -3472,7 +3695,7 @@ .TP 8 .B "scrollBarBorder (\fPclass\fB ScrollBarBorder)" Specifies the width of the scrollbar border. -Note that this is drawn to overlap the border of the \fIxterm\fP window. +Note that this is drawn to overlap the border of the \fI\*n\fP window. Modifying the scrollbar's border affects only the line between the VT100 widget and the scrollbar. The default value is 1. @@ -3480,13 +3703,13 @@ .B "scrollKey (\fPclass\fB ScrollCond)" Specifies whether or not pressing a key should automatically cause the scrollbar to go to the bottom of the scrolling region. -This corresponds to \fIxterm\fP's private mode 1011. +This corresponds to \fI\*n\fP's private mode 1011. The default is \*(``false\*(''. .TP 8 .B "scrollLines (\fPclass\fB ScrollLines)" Specifies the number of lines that the \fIscroll-back\fP and -\fIscroll-forw\fP actions should use as a default. +\fBscroll-forw\fP actions should use as a default. The default value is 1. .TP 8 .B "scrollTtyOutput (\fPclass\fB ScrollCond)" @@ -3495,7 +3718,7 @@ The default is \*(``true\*(''. .TP .B "selectToClipboard (\fPclass\fB SelectToClipboard)" -Tells \fIxterm\fP whether to use the PRIMARY or CLIPBOARD for +Tells \fI\*n\fP whether to use the PRIMARY or CLIPBOARD for SELECT tokens in the selection mechanism. The \fBset-select\fP action can change this at runtime, allowing the user to work with programs that handle only one of these @@ -3510,26 +3733,31 @@ The default is \*(``true\*(''. .TP 8 .B "showBlinkAsBold (\fPclass\fB ShowBlinkAsBold)" -Tells \fIxterm\fP whether to display text with blink-attribute the same +Tells \fI\*n\fP whether to display text with blink-attribute the same as bold. -If \fIxterm\fP has not been configured to support blinking text, -the default is \*(``true\*('', which corresponds to older versions of \fIxterm\fP, +If \fI\*n\fP has not been configured to support blinking text, +the default is \*(``true\*('', which corresponds to older versions of \fI\*n\fP, otherwise the default is \*(``false\*(''. .TP 8 .B "showMissingGlyphs (\fPclass\fB ShowMissingGlyphs)" -Tells \fIxterm\fP whether to display a box outlining places where +Tells \fI\*n\fP whether to display a box outlining places where a character has been used that the font does not represent. The default is \*(``false\*(''. .TP 8 .B "showWrapMarks (\fPclass\fB ShowWrapMarks)" -For debugging \fIxterm\fP and applications that may manipulate the +For debugging \fI\*n\fP and applications that may manipulate the wrapped-line flag by writing text at the right margin, show a mark on the right inner-border of the window. The mark shows which lines have the flag set. .TP 8 .B "signalInhibit (\fPclass\fB SignalInhibit)" Specifies whether or not the entries in the \*(``Main Options\*('' menu for sending -signals to \fIxterm\fP should be disallowed. +signals to \fI\*n\fP should be disallowed. +The default is \*(``false\*(''. +.TP 8 +.B "sixelScrolling (\fPclass\fB SixelScrolling)" +If true, graphics scroll up one line at a time when sixels would be written +past the bottom line on the window. The default is \*(``false\*(''. .TP 8 .B "tekGeometry (\fPclass\fB Geometry)" @@ -3546,16 +3774,16 @@ .B "tekSmall (\fPclass\fB TekSmall)" Specifies whether or not the Tektronix mode window should start in its smallest size if no explicit geometry is given. -This is useful when running \fIxterm\fP +This is useful when running \fI\*n\fP on displays with small screens. The default is \*(``false\*(''. .TP 8 .B "tekStartup (\fPclass\fB TekStartup)" -Specifies whether or not \fIxterm\fP should start up in Tektronix mode. +Specifies whether or not \fI\*n\fP should start up in Tektronix mode. The default is \*(``false\*(''. .TP 8 .B "tiXtraScroll (\fPclass\fB TiXtraScroll)" -Specifies whether \fIxterm\fP should scroll to a new page when processing +Specifies whether \fI\*n\fP should scroll to a new page when processing the \fIti\fP termcap entry, i.e., the private modes 47, 1047 or 1049. This is only in effect if \fBtiteInhibit\fP is \*(``true\*('', because the intent of this option is to provide a picture of the full-screen @@ -3564,19 +3792,19 @@ The default for this resource is \*(``false\*(''. .TP 8 .B "titeInhibit (\fPclass\fB TiteInhibit)" -Specifies whether or not \fIxterm\fP should remove \fIti\fP and \fIte\fP +Specifies whether or not \fI\*n\fP should remove \fIti\fP and \fIte\fP termcap entries (used to switch between alternate screens on startup of many screen-oriented programs) from the TERMCAP string. If set, -\fIxterm\fP also ignores the escape sequence to switch to the +\fI\*n\fP also ignores the escape sequence to switch to the alternate screen. -\fIXterm\fP supports terminfo in a different way, supporting composite control +\fI\*N\fP supports terminfo in a different way, supporting composite control sequences (also known as private modes) 1047, 1048 and 1049 which have the same effect as the original 47 control sequence. The default for this resource is \*(``false\*(''. .TP 8 .B "titleModes (\fPclass\fB TitleModes)" -Tells \fIxterm\fP whether to accept or return +Tells \fI\*n\fP whether to accept or return window- and icon-labels in ISO-8859-1 (the default) or UTF-8. Either can be encoded in hexadecimal. @@ -3594,7 +3822,7 @@ Query window/icon labels using hexadecimal .TP 5 2 -Set window/icon labels using UTF-8 (overrides \fButf8Titles\fP resource). +Set window/icon labels using UTF-8 (overrides \fButf8Title\fP resource). .TP 5 3 Query window/icon labels using UTF-8 @@ -3604,7 +3832,7 @@ Specifies the key and button bindings for menus, selections, \*(``programmed strings\*('', etc. The \fBtranslations\fP resource, -which provides much of \fIxterm\fP's configurability, +which provides much of \fI\*n\fP's configurability, is a feature of the X Toolkit Intrinsics library (Xt). See the \fBACTIONS\fP section. .TP 8 @@ -3615,7 +3843,7 @@ Some lines may contain trailing spaces when an application writes them to the screen. However, you may not wish to paste lines with trailing spaces. -If this resource is true, \fIxterm\fP will trim trailing spaces from +If this resource is true, \fI\*n\fP will trim trailing spaces from text which is selected. It does not affect spaces which result in a wrapped line, nor will it trim the trailing newline from your selection. @@ -3629,19 +3857,19 @@ The default is \*(``true\*(''. .TP 8 .B "useClipping (\fPclass\fB UseClipping)" -Tell \fIxterm\fP whether to use clipping to keep +Tell \fI\*n\fP whether to use clipping to keep from producing dots outside the text drawing area. Originally used to work around for overstriking effects, this is also needed to work with some incorrectly-sized fonts. The default is \*(``true\*(''. .TP 8 .B "utf8 (\fPclass\fB Utf8)" -This specifies whether \fIxterm\fP will run in UTF-8 mode. -If you set this resource, \fIxterm\fP also sets the \fBwideChars\fP resource as a side-effect. +This specifies whether \fI\*n\fP will run in UTF-8 mode. +If you set this resource, \fI\*n\fP also sets the \fBwideChars\fP resource as a side-effect. The resource can be set via the menu entry \*(``UTF-8 Encoding\*(''. The default is \*(``default\*(''. .IP -\fIXterm\fP accepts either a keyword (ignoring case) +\fI\*N\fP accepts either a keyword (ignoring case) or the number shown in parentheses: .RS .TP 3 @@ -3673,13 +3901,13 @@ .TP 8 .B "utf8Fonts (\fPclass\fB Utf8Fonts)" See the discussion of the \fBlocale\fP resource. -This specifies whether \fIxterm\fP will use UTF-8 fonts specified via -resource patterns such as \*(``\fB*vt100.utf8Fonts.font\fP\*('' +This specifies whether \fI\*n\fP will use UTF-8 fonts specified via +resource patterns such as \*(``\fB*vt100.utf8Fonts.font\fP\*('' or normal (ISO-8859-1) fonts via patterns such as \*(``\fB*vt100.font\fP\*(''. The resource can be set via the menu entry \*(``UTF-8 Fonts\*(''. The default is \*(``default\*(''. .IP -\fIXterm\fP accepts either a keyword (ignoring case) +\fI\*N\fP accepts either a keyword (ignoring case) or the number shown in parentheses: .RS .TP @@ -3710,17 +3938,17 @@ The default is \*(``false\*(''. .TP 8 .B "utf8SelectTypes (\fPclass\fB Utf8SelectTypes)" -Override \fIxterm\fP's default selection target list (see SELECT/PASTE) for +Override \fI\*n\fP's default selection target list (see SELECT/PASTE) for selections in wide-character (UTF-8) mode. The default is an empty string, i.e., \*(``\*('', which does not override anything. .TP 8 .B "utf8Title (\fPclass\fB Utf8Title)" -Applications can set \fIxterm\fP's title by writing a control sequence. +Applications can set \fI\*n\fP's title by writing a control sequence. Normally this control sequence follows the VT220 convention, which encodes the string in ISO-8859-1 and allows for an 8-bit string terminator. -If \fIxterm\fP is started in a UTF-8 locale, +If \fI\*n\fP is started in a UTF-8 locale, it translates the ISO-8859-1 string to UTF-8 to work with the X libraries which assume the string is UTF-8. .IP @@ -3732,7 +3960,7 @@ allowing UTF-8 strings to be displayed as is. .IP This feature is available as a menu entry, since it is related to -the particular applications you are running within \fIxterm\fP. +the particular applications you are running within \fI\*n\fP. You can also use a control sequence (see the discussion of \*(``Title Modes\*('' in the control sequences document), to set an equivalent flag. @@ -3759,7 +3987,7 @@ .B "visualBell (\fPclass\fB VisualBell)" Specifies whether or not a visible bell (i.e., flashing) should be used instead of an audible bell when Control-G is received. -The default is \*(``false\*('', which tells \fIxterm\fP to use an audible bell. +The default is \*(``false\*('', which tells \fI\*n\fP to use an audible bell. .TP 8 .B "visualBellDelay (\fPclass\fB VisualBellDelay)" Number of milliseconds to delay when displaying a visual bell. @@ -3771,10 +3999,10 @@ Specifies whether to flash only the current line when displaying a visual bell. rather than flashing the entire screen: The default is \*(``false\*('', -which tells \fIxterm\fP to flash the entire screen. +which tells \fI\*n\fP to flash the entire screen. .TP 8 .B "vt100Graphics (\fPclass\fB VT100Graphics)" -This specifies whether \fIxterm\fP will interpret VT100 graphic character +This specifies whether \fI\*n\fP will interpret VT100 graphic character escape sequences while in UTF-8 mode. The default is \*(``true\*('', to provide support for various legacy applications. .TP 8 @@ -3787,7 +4015,7 @@ the bold font. .TP 8 .B "wideChars (\fPclass\fB WideChars)" -Specifies if \fIxterm\fP should respond to control sequences that +Specifies if \fI\*n\fP should respond to control sequences that process 16-bit characters. The default is \*(``false\*(''. .TP 8 @@ -3808,7 +4036,7 @@ It is the XIM server's responsibility to display the preedit string. The XIM client must inform the XIM server of the cursor position. For best results, the preedit string must be displayed with a proper font. -Therefore, \fIxterm\fP informs the XIM server of the proper font. +Therefore, \fI\*n\fP informs the XIM server of the proper font. The font is be supplied by a "fontset", whose default value is \*(``*\*(''. This matches every font, the X library automatically chooses fonts with proper charsets. @@ -3843,7 +4071,7 @@ .TP 8 .B "initialFont (\fPclass\fB InitialFont)" Specifies which of the four Tektronix fonts to use initially. -Values are the same as for the \fIset-tek-text\fP action. +Values are the same as for the \fBset-tek-text\fP action. The default is \*(``large\*(''. .TP 8 .B "width (\fPclass\fB Width)" @@ -3853,13 +4081,16 @@ .PP The resources that may be specified for the various menus are described in the documentation for the Athena \fBSimpleMenu\fP widget. -The name and classes -of the entries in each of the menus are listed below. +The name and classes of the entries in each of the menus are listed below. Resources named \*(``\fBline\fR\fIN\fR\*('' where \fIN\fR is a number are separators with class \fBSmeLine\fR. +.PP +As with all X resource-based widgets, +the labels mentioned are customary defaults for the application. . .PP -The \fImainMenu\fP has the following entries: +The \fIMain Options\fP menu (widget name \fImainMenu\fP) +has the following entries: .TP 8 .B "toolbar (\fPclass\fB SmeBSB)" This entry invokes the \fBset-toolbar(toggle)\fP action. @@ -3945,7 +4176,8 @@ This entry invokes the \fBquit()\fP action. . .PP -The \fIvtMenu\fP has the following entries: +The \fIVT Options\fP menu (widget name \fIvtMenu\fP) +has the following entries: .TP 8 .B "scrollbar (\fPclass\fB SmeBSB)" This entry invokes the \fBset-scrollbar(toggle)\fP action. @@ -4000,8 +4232,8 @@ .TP 8 .B "activeicon (\fPclass\fB SmeBSB)" This entry toggles active icons on and off if this feature was -compiled into \fIxterm\fP. -It is enabled only if \fIxterm\fP +compiled into \fI\*n\fP. +It is enabled only if \fI\*n\fP was started with the command line option +ai or the \fBactiveIcon\fP resource is set to \*(``true\*(''. .TP 8 @@ -4025,30 +4257,48 @@ .TP 8 .B "altscreen (\fPclass\fB SmeBSB)" This entry invokes the \fBset-altscreen(toggle)\fP action. +.TP 8 +.B "sixelScrolling (\fPclass\fB SmeBSB)" +This entry invokes the \fBset-sixel-scrolling(toggle)\fP action. . .PP -The \fIfontMenu\fP has the following entries: +The \fIVT Fonts\fP menu (widget name \fIfontMenu\fP) +has the following entries: .TP 8 .B "fontdefault (\fPclass\fB SmeBSB)" -This entry invokes the \fBset-vt-font(d)\fP action. +This entry invokes the \fBset-vt-font(d)\fP action, +setting the font using the \fBfont\fP (default) resource, +e.g., \*(``Default\*('' in the menu. .TP 8 .B "font1 (\fPclass\fB SmeBSB)" -This entry invokes the \fBset-vt-font(1)\fP action. +This entry invokes the \fBset-vt-font(1)\fP action, +setting the font using the \fBfont1\fP resource, +e.g., \*(``Unreadable\*('' in the menu. .TP 8 .B "font2 (\fPclass\fB SmeBSB)" -This entry invokes the \fBset-vt-font(2)\fP action. +This entry invokes the \fBset-vt-font(2)\fP action, +setting the font using the \fBfont2\fP resource, +e.g., \*(``Tiny\*('' in the menu. .TP 8 .B "font3 (\fPclass\fB SmeBSB)" -This entry invokes the \fBset-vt-font(3)\fP action. +This entry invokes the \fBset-vt-font(3)\fP action, +setting the font using the \fBfont3\fP resource, +e.g., \*(``Small\*('' in the menu. .TP 8 .B "font4 (\fPclass\fB SmeBSB)" -This entry invokes the \fBset-vt-font(4)\fP action. +This entry invokes the \fBset-vt-font(4)\fP action, +letting the font using the \fBfont4\fP resource, +e.g., \*(``Medium\*('' in the menu. .TP 8 .B "font5 (\fPclass\fB SmeBSB)" -This entry invokes the \fBset-vt-font(5)\fP action. +This entry invokes the \fBset-vt-font(5)\fP action, +letting the font using the \fBfont5\fP resource, +e.g., \*(``Large\*('' in the menu. .TP 8 .B "font6 (\fPclass\fB SmeBSB)" -This entry invokes the \fBset-vt-font(6)\fP action. +This entry invokes the \fBset-vt-font(6)\fP action, +letting the font using the \fBfont6\fP resource, +e.g., \*(``Huge\*('' in the menu. .TP 8 .B "fontescape (\fPclass\fB SmeBSB)" This entry invokes the \fBset-vt-font(e)\fP action. @@ -4075,7 +4325,8 @@ This entry invokes the \fBset-utf8-title(s)\fP action. . .PP -The \fItekMenu\fP has the following entries: +The \fITEK Options\fP menu (widget name \fItekMenu\fP) +has the following entries: .TP 8 .B "tektextlarge (\fPclass\fB SmeBSB)" This entry invokes the \fBset-tek-text(large)\fP action. @@ -4129,7 +4380,7 @@ . .PP Once the VT102 window is created, -.I xterm +.I \*n allows you to select text and copy it within the same or other windows. . .SS "SELECTION" @@ -4147,26 +4398,21 @@ The selected text is highlighted and is saved in the global cut buffer and made the PRIMARY selection when the button is released. Normally (but see the discussion of \fBon2Clicks\fP, etc): -.RS -.TP 3 -- +.bP Double-clicking selects by words. -.TP -- +.bP Triple-clicking selects by lines. -.TP -- +.bP Quadruple-clicking goes back to characters, etc. -.RE .PP Multiple-click is determined by the time from button up to button down, so you can change the selection unit in the middle of a selection. Logical words and lines selected by double- or triple-clicking may wrap -across more than one screen line if lines were wrapped by \fIxterm\fP +across more than one screen line if lines were wrapped by \fI\*n\fP itself rather than by the application running in the window. If the key/button bindings specify that an X selection is to be made, -\fIxterm\fP will leave the selected text highlighted for as long as it +\fI\*n\fP will leave the selected text highlighted for as long as it is the selection owner. . .PP @@ -4184,7 +4430,7 @@ right edge of the selection. If you contract the selection past the left edge of the selection, -.I xterm +.I \*n assumes you really meant the left edge, restores the original selection, then extends/contracts the left edge of the selection. Extension starts in the @@ -4245,14 +4491,14 @@ by the server. .SS PRIMARY When configured to use the primary selection, -(the default) \fIxterm\fP can +(the default) \fI\*n\fP can provide the selection data in ways which help to retain character encoding information as it is pasted. .PP -A user \*(``selects\*('' text on xterm, which highlights the selected text. +A user \*(``selects\*('' text on \*n, which highlights the selected text. A subsequent \*(``paste\*('' to another client forwards a request to the client owning the selection. -If \fIxterm\fP owns the primary selection, it makes the data +If \fI\*n\fP owns the primary selection, it makes the data available in the form of one or more \*(``selection targets\*(''. If it does not own the primary selection, e.g., if it has released it or another client has @@ -4272,12 +4518,12 @@ These are termed \fIselection targets\fP. .PP When asking for the selection data, -\fIxterm\fP tries the following types in this order: +\fI\*n\fP tries the following types in this order: .RS .TP 5 UTF8_STRING This is an XFree86 extension, which denotes that the data is encoded in UTF-8. -When \fIxterm\fP is built with wide-character support, +When \fI\*n\fP is built with wide-character support, it both accepts and provides this type. .TP 5 TEXT @@ -4293,19 +4539,19 @@ This is Latin 1 (ISO-8859-1) data. .RE .PP -The middle two (TEXT and COMPOUND_TEXT) are added if \fIxterm\fP +The middle two (TEXT and COMPOUND_TEXT) are added if \fI\*n\fP is configured with the \fBi18nSelections\fP resource set to \*(``true\*(''. .PP UTF8_STRING is preferred (therefore first in the list) -since \fIxterm\fP stores text as Unicode data when +since \fI\*n\fP stores text as Unicode data when running in wide-character mode, and no translation is needed. On the other hand, TEXT and COMPOUND_TEXT may require translation. If the translation is incomplete, they will insert X's \*(``defaultString\*('' whose value cannot be set, and may simply be empty. -\fIXterm\fP's \fBdefaultString\fP resource specifies the string to +\fI\*N\fP's \fBdefaultString\fP resource specifies the string to use for incomplete translations of the UTF8_STRING. .PP -You can alter the types which \fIxterm\fP tries using the +You can alter the types which \fI\*n\fP tries using the \fBeightBitSelectTypes\fP or \fButf8SelectTypes\fP resources. For instance, you might have some specific locale setting which does not use UTF-8 encoding. @@ -4349,7 +4595,7 @@ .\" ************************************************************************ .SS "Main Options" .PP -The \fIxterm\fP \fImainMenu\fP pops up +The \fI\*n\fP \fImainMenu\fP pops up when the \*(``control\*('' key and pointer button one are pressed in a window. This menu contains items that apply to both the VT102 and Tektronix windows. There are several sections: @@ -4396,7 +4642,7 @@ .TP Print-All on Error Invokes the \fBprint-on-error\fP action, -which toggles a flag telling \fIxterm\fP that if it exits with an X error, +which toggles a flag telling \fI\*n\fP that if it exits with an X error, to send the text of the current window directly to a file, as specified by the \fBprintFileXError\fP, @@ -4420,11 +4666,11 @@ .RS .TP 8-Bit Controls (8-bit-control) -Enabled for VT220 emulation, this controls whether \fIxterm\fP will send +Enabled for VT220 emulation, this controls whether \fI\*n\fP will send 8-bit control sequences rather than using 7-bit (ASCII) controls, e.g., sending a byte in the range 128-159 rather than the escape character followed by a second byte. -\fIXterm\fP always interprets both 8-bit and 7-bit control sequences +\fI\*N\fP always interprets both 8-bit and 7-bit control sequences (see the document \fIXterm Control Sequences\fP). This corresponds to the \fBeightBitControl\fP resource. .TP @@ -4481,7 +4727,7 @@ Send KILL Signal (kill) These send the SIGTSTP, SIGCONT, SIGINT, SIGHUP, SIGTERM and SIGKILL signals respectively, to the process group of the process running under -.I xterm +.I \*n (usually the shell). The .B SIGCONT @@ -4492,7 +4738,7 @@ Stop processing X events except to support the \fB-hold\fP option, and then send a SIGHUP signal to the the process group of the process running under -.I xterm +.I \*n (usually the shell). .RE .PP @@ -4607,10 +4853,10 @@ . .TP Keep Selection (keepSelection) -Tell \fIxterm\fP whether to disown the selection when it stops highlighting it, +Tell \fI\*n\fP whether to disown the selection when it stops highlighting it, e.g., when an application modifies the display so that it no longer matches the text which has been highlighted. -As long as \fIxterm\fP continues to own the selection, +As long as \fI\*n\fP continues to own the selection, it can provide the corresponding text to other clients via cut/paste. This corresponds to the .B keepSelection @@ -4619,7 +4865,7 @@ . .TP Select to Clipboard (selectToClipboard) -Tell \fIxterm\fP whether to use the PRIMARY or CLIPBOARD +Tell \fI\*n\fP whether to use the PRIMARY or CLIPBOARD for SELECT tokens in the \fBtranslations\fP resource which maps keyboard and mouse actions to select/paste actions. This corresponds to the @@ -4682,6 +4928,34 @@ option and the .B activeIcon resource. +. +.TP +Sixel Scrolling (sixelScrolling) +When enabled, +sixel graphics are positioned at the current text cursor location, scroll +the image vertically if larger than the screen, and leave the text cursor +after the image when returning to text mode. +When disabled, +sixel graphics are positioned at the upper left of the screen, are +cropped to fit the screen, and do not affect the text cursor location +(this is the default). +This corresponds to the +.B sixelScrolling +resource. +There is no corresponding command-line option. +. +.TP +Private Color Registers (privateColorRegisters) +When enabled, +each graphic image uses a separate set of color registers, so that it +essentially has a private palette (this is the default). If it is not set, +all graphics images share a common set of registers which is how sixel and +ReGIS graphics worked on actual hardware. The default is likely a more +useful mode on modern TrueColor hardware. +This corresponds to the +.B privateColorRegisters +resource. +There is no corresponding command-line option. .RE . .TP @@ -4699,7 +4973,7 @@ The full reset entry will clear the screen, reset tabs to every eight columns, and reset the terminal modes (such as wrap and smooth scroll) to their initial states just after -.I xterm +.I \*n has finished processing the command line options. This corresponds to the VT102 RIS control sequence, with a few obvious differences. @@ -4813,22 +5087,22 @@ .TP Bold Fonts This is normally checked (enabled). -When unchecked, \fIxterm\fP will not use bold fonts. +When unchecked, \fI\*n\fP will not use bold fonts. The setting corresponds to the \fBallowBoldFonts\fP resource. .TP Line-Drawing Characters (font-linedrawing) -When set, tells \fIxterm\fP to draw its own line-drawing characters. +When set, tells \fI\*n\fP to draw its own line-drawing characters. Otherwise it relies on the font containing these. Compare to the \fBforceBoxChars\fP resource. .TP Packed Font (font-packed) -When set, tells \fIxterm\fP to use the minimum glyph-width from a font +When set, tells \fI\*n\fP to use the minimum glyph-width from a font when displaying characters. Use the maximum width (unchecked) to help display proportional fonts. Compare to the \fBforcePackedFont\fP resource. .TP Doublesized Characters (font-doublesize) -When set, \fIxterm\fP may ask the font server to produce scaled versions +When set, \fI\*n\fP may ask the font server to produce scaled versions of the normal font, for VT102 double-size characters. .RE .PP @@ -4839,23 +5113,23 @@ If the .B "renderFont and corresponding resources were set, -this is a further control whether \fIxterm\fP will actually use the +this is a further control whether \fI\*n\fP will actually use the Xft library calls to obtain a font. .TP UTF-8 Encoding (utf8-mode) -This controls whether \fIxterm\fP uses UTF-8 encoding of input/output. -It is useful for temporarily switching \fIxterm\fP to display +This controls whether \fI\*n\fP uses UTF-8 encoding of input/output. +It is useful for temporarily switching \fI\*n\fP to display text from an application which does not follow the locale settings. It corresponds to the \fButf8\fP resource. .TP UTF-8 Fonts (utf8-fonts) -This controls whether \fIxterm\fP uses UTF-8 fonts for display. -It is useful for temporarily switching \fIxterm\fP to display +This controls whether \fI\*n\fP uses UTF-8 fonts for display. +It is useful for temporarily switching \fI\*n\fP to display text from an application which does not follow the locale settings. It combines the \fButf8\fP and \fButf8Fonts\fP resources. .TP UTF-8 Titles (utf8-titles) -This controls whether \fIxterm\fP accepts UTF-8 encoding for +This controls whether \fI\*n\fP accepts UTF-8 encoding for title control sequences. It corresponds to the \fButf8Fonts\fP resource. .IP @@ -4868,12 +5142,13 @@ The standard \fB__default_class__\fP app-defaults file defines both sets of fonts, while the \fBU__default_class__\fP app-defaults file defines only one set. assuming the standard app-defaults files, -this command will launch \fIxterm\fP able to switch between UTF-8 +this command will launch \fI\*n\fP able to switch between UTF-8 and ISO-8859-1 encoded fonts: .NS -uxterm -class __default_class__ +u\*n -class __default_class__ .NE .RE +.IP The fourth section allows you to enable or disable special operations which can be controlled by writing escape sequences to the terminal. These are disabled if the SendEvents feature is enabled: @@ -4979,13 +5254,13 @@ authorization mechanism than is provided by X. .PP Subject to all of these caveats, -a simple mechanism exists for protecting keyboard input in \fIxterm\fP. +a simple mechanism exists for protecting keyboard input in \fI\*n\fP. . .PP -The \fIxterm\fP menu (see \fBMENUS\fP above) contains a \fBSecure Keyboard\fP +The \fI\*n\fP menu (see \fBMENUS\fP above) contains a \fBSecure Keyboard\fP entry which, when enabled, attempts to ensure that all keyboard input is directed -\fIonly\fP to \fIxterm\fP (using the GrabKeyboard protocol request). +\fIonly\fP to \fI\*n\fP (using the GrabKeyboard protocol request). When an application prompts you for a password (or other sensitive data), you can enable \fBSecure Keyboard\fP using the menu, type in the data, and then disable \fBSecure Keyboard\fP using @@ -5016,7 +5291,7 @@ mark appears next to the entry. . .PP -\fBSecure Keyboard\fP mode will be disabled automatically if your \fIxterm\fP +\fBSecure Keyboard\fP mode will be disabled automatically if your \fI\*n\fP window becomes iconified (or otherwise unmapped), or if you start up a reparenting window manager (that places a title bar or other decoration around the window) while in \fBSecure Keyboard\fP mode. @@ -5118,6 +5393,7 @@ /\(** o/ u` u\*(AQ u^ u: y\*(AQ P y: */ 48, 48, 48, 48, 48, 48, 48, 48}; .NE +.IP For example, the string \*(``33:48,37:48,45\-47:48,38:48\*('' indicates that the exclamation mark, percent sign, dash, period, slash, and ampersand characters should be treated the same way as characters and numbers. @@ -5125,39 +5401,41 @@ for cutting and pasting electronic mailing addresses and filenames. . . -.SH ACTIONS +.SH KEY BINDINGS +.PP It is possible to rebind keys (or sequences of keys) to arbitrary strings for input, by changing the \fBtranslations\fP resources for the vt100 or tek4014 widgets. Changing the \fBtranslations\fP resource for events other than key and button events is not expected, and will cause unpredictable behavior. +.SS ACTIONS The following actions are provided for use within the \fIvt100\fP or \fItek4014\fP \fBtranslations\fP resources: .TP 8 .B "allow-color-ops(\fIon/off/toggle\fP)" -This action set or toggles the \fBallowColorOps\fP resource and is also +This action sets, unsets or toggles the \fBallowColorOps\fP resource and is also invoked by the \fBallow-color-ops\fP entry in \fIfontMenu\fP. .TP 8 .B "allow-font-ops(\fIon/off/toggle\fP)" -This action set or toggles the \fBallowFontOps\fP resource and is also +This action sets, unsets or toggles the \fBallowFontOps\fP resource and is also invoked by the \fBallow-font-ops\fP entry in \fIfontMenu\fP. .TP 8 .B "allow-send-events(\fIon/off/toggle\fP)" -This action set or toggles the \fBallowSendEvents\fP resource and is also +This action sets, unsets or toggles the \fBallowSendEvents\fP resource and is also invoked by the \fBallowsends\fP entry in \fImainMenu\fP. .TP 8 .B "allow-tcap-ops(\fIon/off/toggle\fP)" -This action set or toggles the \fBallowTcapOps\fP resource and is also +This action sets, unsets or toggles the \fBallowTcapOps\fP resource and is also invoked by the \fBallow-tcap-ops\fP entry in \fIfontMenu\fP. .TP 8 .B "allow-title-ops(\fIon/off/toggle\fP)" -This action set or toggles the \fBallowTitleOps\fP resource and is also +This action sets, unsets or toggles the \fBallowTitleOps\fP resource and is also invoked by the \fBallow-title-ops\fP entry in \fIfontMenu\fP. .TP 8 .B "allow-window-ops(\fIon/off/toggle\fP)" -This action set or toggles the \fBallowWindowOps\fP resource and is also +This action sets, unsets or toggles the \fBallowWindowOps\fP resource and is also invoked by the \fBallow-window-ops\fP entry in \fIfontMenu\fP. .TP 8 .B "alt-sends-escape()" @@ -5180,7 +5458,7 @@ modify the internal selection state. .TP 8 .B "create-menu(\fIm/v/f/t\fP)" -This action creates one of the menus used by \fIxterm\fP, +This action creates one of the menus used by \fI\*n\fP, if it has not been previously created. The parameter values are the menu names: \fImainMenu\fP, \fIvtMenu\fP, \fIfontMenu\fP, \fItekMenu\fP, respectively. @@ -5199,7 +5477,7 @@ The word here is defined as a sequence of non-whitespace characters. This feature partially emulates the behavior of \*(``dynamic abbreviation\*('' expansion in Emacs (bound there to M\-/). -Here is a resource setting for \fIxterm\fP which will do the same thing: +Here is a resource setting for \fI\*n\fP which will do the same thing: .NS *VT100*translations: #override \\n\\\& Meta /:dabbrev-expand() @@ -5220,8 +5498,8 @@ ^X ESC G .in -8 .TP 8 -.B "fullscreen()" -Asks the window manager to change the window to full-screen. +.B "fullscreen(\fIon/off/toggle\fP)" +This action sets, unsets or toggles the \fBfullscreen\fP resource. .TP 8 .B "iconify()" Iconifies the window. @@ -5252,11 +5530,11 @@ See the \fBeightBitInput\fP resource for a full discussion. .IP The term \*(``eight-bit\*('' is misleading: -\fIxterm\fP checks if the key is in the range 128 to 255 +\fI\*n\fP checks if the key is in the range 128 to 255 (the eighth bit is set). If the value is in that range, depending on the resource values, -\fIxterm\fP may then do one of the following: +\fI\*n\fP may then do one of the following: .RS .bP add 128 to the value, setting its eighth bit, @@ -5311,8 +5589,8 @@ .RE .IP After constructing the command-string, -\fIxterm\fP forks a subprocess and executes the command, -which completes independently of xterm. +\fI\*n\fP forks a subprocess and executes the command, +which completes independently of \*n. .TP 8 .B "exec-selectable(\fIformat\fP, \fIonClicks\fP)" Execute an external command, @@ -5348,7 +5626,7 @@ .B "insert-seven-bit()" This action is a synonym for \fBinsert()\fP The term \*(``seven-bit\*('' is misleading: -it only implies that \fIxterm\fP does not try to add 128 to the key's value +it only implies that \fI\*n\fP does not try to add 128 to the key's value as in \fBinsert-eight-bit()\fP. .TP 8 .B "interpret(\fIcontrol-sequence\fP)" @@ -5392,8 +5670,8 @@ and \fItekMenu\fP. .TP 8 .B "print(\fIprinter-flags\fP)" -This action prints the window and is also invoked by the -\fIprint\fP entry in \fImainMenu\fP. +This action prints the window. +It is also invoked by the \fIprint\fP entry in \fImainMenu\fP. .IP The action accepts optional parameters, which temporarily override resource settings. @@ -5447,7 +5725,7 @@ resources. .TP 8 .B "print-on-error()" -Toggles a flag telling \fIxterm\fP that if it exits with an X error, +Toggles a flag telling \fI\*n\fP that if it exits with an X error, to send the text of the current window directly to a file, as specified by the \fBprintFileXError\fP, @@ -5473,8 +5751,8 @@ position to match the button event. .TP 8 .B "redraw()" -This action redraws the window and is also invoked by the -\fIredraw\fP entry in \fImainMenu\fP. +This action redraws the window. +It is also invoked by the \fIredraw\fP entry in \fImainMenu\fP. .TP 8 .B "restore()" Restores the window to the size before it was last maximized. @@ -5505,8 +5783,8 @@ entry in \fImainMenu\fP. .TP 8 .B "scroll-lock(\fIon/off/toggle\fP)" -This action toggles internal state which tells -\fIxterm\fP whether Scroll Lock is active, +This action sets, unsets or toggles internal state which tells +\fI\*n\fP whether Scroll Lock is active, subject to the \fBallowScrollLock\fP resource. .TP 8 .B "select-cursor-end(\fIdestname\fP [, ...])" @@ -5542,8 +5820,9 @@ .TP 8 .B "send-signal(\fIsigname\fP)" This action sends the signal named by \fIsigname\fP -to the \fIxterm\fP subprocess (the shell or program specified with -the \fI\-e\fP command line option) and is also invoked by the +to the \fI\*n\fP subprocess (the shell or program specified with +the \fI\-e\fP command line option). +It is also invoked by the .BR suspend , .BR continue , .BR interrupt , @@ -5561,143 +5840,164 @@ \fIalrm\fP, \fIalarm\fP (same as \fIalrm\fP) and \fIkill\fP. .TP 8 .B "set-8-bit-control(\fIon/off/toggle\fP)" -This action toggles the \fBeightBitControl\fP resource and is also invoked from the -\fB8-bit-control\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBeightBitControl\fP resource. +It is also invoked from the \fB8-bit-control\fP entry in \fIvtMenu\fP. .TP 8 .B "set-allow132(\fIon/off/toggle\fP)" -This action toggles the \fBc132\fP resource and is also invoked from the -\fBallow132\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBc132\fP resource. +It is also invoked from the \fBallow132\fP entry in \fIvtMenu\fP. .TP 8 .B "set-altscreen(\fIon/off/toggle\fP)" -This action toggles between the alternate and current screens. +This action sets, unsets or toggles between the alternate and current screens. .TP 8 .B "set-appcursor(\fIon/off/toggle\fP)" -This action toggles the handling Application Cursor Key mode +This action sets, unsets or toggles the handling Application Cursor Key mode and is also invoked by the \fBappcursor\fP entry in \fIvtMenu\fP. .TP 8 .B "set-appkeypad(\fIon/off/toggle\fP)" -This action toggles the handling of Application Keypad mode and is also +This action sets, unsets or toggles the handling of Application Keypad mode and is also invoked by the \fBappkeypad\fP entry in \fIvtMenu\fP. .TP 8 .B "set-autolinefeed(\fIon/off/toggle\fP)" -This action toggles automatic insertion of linefeeds and is also invoked by -the \fBautolinefeed\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles automatic insertion of linefeeds. +It is also invoked by the \fBautolinefeed\fP entry in \fIvtMenu\fP. .TP 8 .B "set-autowrap(\fIon/off/toggle\fP)" -This action toggles automatic wrapping of long lines and is also invoked by -the \fBautowrap\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles automatic wrapping of long lines. +It is also invoked by the \fBautowrap\fP entry in \fIvtMenu\fP. .TP 8 .B "set-backarrow(\fIon/off/toggle\fP)" -This action toggles the \fBbackarrowKey\fP resource and is also invoked from the -\fBbackarrow key\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBbackarrowKey\fP resource. +It is also invoked from the \fBbackarrow key\fP entry in \fIvtMenu\fP. .TP 8 .B "set-bellIsUrgent(\fIon/off/toggle\fP)" -This action toggles the \fBbellIsUrgent\fP resource and is also invoked -by the \fBbellIsUrgent\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBbellIsUrgent\fP resource. +It is also invoked by the \fBbellIsUrgent\fP entry in \fIvtMenu\fP. .TP 8 .B "set-cursorblink(\fIon/off/toggle\fP)" -This action toggles the \fBcursorBlink\fP resource and is also invoked from the -\fBcursorblink\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBcursorBlink\fP resource. +It is also invoked from the \fBcursorblink\fP entry in \fIvtMenu\fP. .TP 8 .B "set-cursesemul(\fIon/off/toggle\fP)" -This action toggles the \fBcurses\fP resource and is also invoked from the -\fBcursesemul\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBcurses\fP resource. +It is also invoked from the \fBcursesemul\fP entry in \fIvtMenu\fP. .TP 8 .B "set-font-doublesize(\fIon/off/toggle\fP)" -This action toggles the \fBfontDoublesize\fP resource and is also invoked by -the \fBfont-doublesize\fP entry in \fIfontMenu\fP. +This action sets, unsets or toggles the \fBfontDoublesize\fP resource. +It is also invoked by the \fBfont-doublesize\fP entry in \fIfontMenu\fP. .TP 8 .B "set-hp-function-keys(\fIon/off/toggle\fP)" -This action toggles the \fBhpFunctionKeys\fP resource and is also invoked by -the \fBhpFunctionKeys\fP entry in \fImainMenu\fP. +This action sets, unsets or toggles the \fBhpFunctionKeys\fP resource. +It is also invoked by the \fBhpFunctionKeys\fP entry in \fImainMenu\fP. .TP 8 .B "set-jumpscroll(\fIon/off/toggle\fP)" -This action toggles the \fBjumpscroll\fP resource and is also invoked by the -\fBjumpscroll\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBjumpscroll\fP resource. +It is also invoked by the \fBjumpscroll\fP entry in \fIvtMenu\fP. .TP 8 .B "set-font-linedrawing(\fIon/off/toggle\fP)" -This action toggles the \fIxterm\fR's state regarding whether the current font +This action sets, unsets or toggles the \fI\*n\fR's state regarding whether the current font has line-drawing characters and whether it should draw them directly. It is also invoked by the \fBfont-linedrawing\fP entry in \fIfontMenu\fP. .\" .\" not implemented .\" .TP 8 .\" .B "set-font-loading(\fIon/off/toggle\fP)" -.\" This action toggles the TBD resource +.\" This action sets, unsets or toggles the TBD resource .\" which controls the ability to load VT220 soft fonts. .\" It is also invoked by the \fBfont-loadable\fP entry in \fIfontMenu\fP. .TP 8 .B "set-font-packed(\fIon/off/toggle\fP)" -This action toggles the \fIforcePackedFont\fR's resource +This action sets, unsets or toggles the \fIforcePackedFont\fR's resource which controls use of the font's minimum or maximum glyph width. It is also invoked by the \fBfont-packed\fP entry in \fIfontMenu\fP. .TP 8 .B "set-keep-selection(\fIon/off/toggle\fP)" -This action toggles the \fBkeepSelection\fP resource and is also invoked by -the \fBkeepSelection\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBkeepSelection\fP resource. +It is also invoked by the \fBkeepSelection\fP entry in \fIvtMenu\fP. .TP 8 -.B "set-logging()" -This action toggles the state of the logging option. +.B "set-logging(\fIon/off/toggle\fP)" +This action sets, unsets or toggles the state of the logging option. .TP 8 .B "set-old-function-keys(\fIon/off/toggle\fP)" -This action toggles the state of legacy function keys and is also invoked by -the \fBoldFunctionKeys\fP entry in \fImainMenu\fP. +This action sets, unsets or toggles the state of legacy function keys. +It is also invoked by the \fBoldFunctionKeys\fP entry in \fImainMenu\fP. .TP 8 .B "set-marginbell(\fIon/off/toggle\fP)" -This action toggles the \fBmarginBell\fP resource. +This action sets, unsets or toggles the \fBmarginBell\fP resource. .TP 8 -.B "set-num-lock()" +.B "set-num-lock(\fIon/off/toggle\fP)" This action toggles the state of the \fBnumLock\fP resource. .TP 8 .B "set-pop-on-bell(\fIon/off/toggle\fP)" -This action toggles the \fBpopOnBell\fP resource and is also invoked -by the \fBpoponbell\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBpopOnBell\fP resource. +It is also invoked by the \fBpoponbell\fP entry in \fIvtMenu\fP. +.TP 8 +.B "set-private-colors(\fIon/off/toggle\fP)" +This action sets, unsets or toggles the \fBprivateColorRegisters\fP resource. .TP 8 .B "set-render-font(\fIon/off/toggle\fP)" -This action toggles the \fBrenderFont\fP resource and is also invoked by -the \fBrender-font\fP entry in \fIfontMenu\fP. +This action sets, unsets or toggles the \fBrenderFont\fP resource. +It is also invoked by the \fBrender-font\fP entry in \fIfontMenu\fP. .TP 8 .B "set-reverse-video(\fIon/off/toggle\fP)" -This action toggles the \fBreverseVideo\fP resource and is also invoked by -the \fBreversevideo\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBreverseVideo\fP resource. +It is also invoked by the \fBreversevideo\fP entry in \fIvtMenu\fP. .TP 8 .B "set-reversewrap(\fIon/off/toggle\fP)" -This action toggles the \fBreverseWrap\fP resource and is also invoked by -the \fBreversewrap\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBreverseWrap\fP resource. +It is also invoked by the \fBreversewrap\fP entry in \fIvtMenu\fP. .TP 8 .B "set-scroll-on-key(\fIon/off/toggle\fP)" -This action toggles the \fBscrollKey\fP resource and is also invoked from -the \fBscrollkey\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBscrollKey\fP resource. +It is also invoked from the \fBscrollkey\fP entry in \fIvtMenu\fP. .TP 8 .B "set-scroll-on-tty-output(\fIon/off/toggle\fP)" -This action toggles the \fBscrollTtyOutput\fP resource and is also invoked -from the \fBscrollttyoutput\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBscrollTtyOutput\fP resource. +It is also invoked from the \fBscrollttyoutput\fP entry in \fIvtMenu\fP. .TP 8 .B "set-scrollbar(\fIon/off/toggle\fP)" -This action toggles the \fBscrollbar\fP resource and is also invoked by -the \fBscrollbar\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBscrollbar\fP resource. +It is also invoked by the \fBscrollbar\fP entry in \fIvtMenu\fP. +.TP 8 +.B "set-sco-function-keys(\fIon/off/toggle\fP)" +This action sets, unsets or toggles the \fBscoFunctionKeys\fP resource. +It is also invoked by the \fBscoFunctionKeys\fP entry in \fImainMenu\fP. .TP 8 .B "set-select(\fIon/off/toggle\fP)" -This action toggles the \fBselectToClipboard\fP resource and is also invoked by -the \fBselectToClipboard\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBselectToClipboard\fP resource. +It is also invoked by the \fBselectToClipboard\fP entry in \fIvtMenu\fP. .TP 8 -.B "set-sco-function-keys(\fIon/off/toggle\fP)" -This action toggles the \fBscoFunctionKeys\fP resource and is also invoked by -the \fBscoFunctionKeys\fP entry in \fImainMenu\fP. +.B "set-sixel-scrolling(\fIon/off/toggle\fP)" +This action toggles between inline (sixel scrolling) and absolute positioning. +It can also be controlled via DEC private mode 80 (DECSDM) or from +the \fBsixelScrolling\fP entry in the \fIbtMenu\fP. .TP 8 .B "set-sun-function-keys(\fIon/off/toggle\fP)" -This action toggles the \fBsunFunctionKeys\fP resource and is also invoked by -the \fBsunFunctionKeys\fP entry in \fImainMenu\fP. +This action sets, unsets or toggles the \fBsunFunctionKeys\fP resource. +It is also invoked by the \fBsunFunctionKeys\fP entry in \fImainMenu\fP. .TP 8 .B "set-sun-keyboard(\fIon/off/toggle\fP)" -This action toggles the \fBsunKeyboard\fP resource and is also invoked by -the \fBsunKeyboard\fP entry in \fImainMenu\fP. +This action sets, unsets or toggles the \fBsunKeyboard\fP resource. +It is also invoked by the \fBsunKeyboard\fP entry in \fImainMenu\fP. .TP 8 .B "set-tek-text(\fIlarge/2/3/small\fP)" -This action sets font used in the Tektronix window to the value of the -resources \fBtektextlarge\fP, \fBtektext2\fP, \fBtektext3\fP, and -\fBtektextsmall\fP according to the argument. -It is also invoked by the entries -of the same names as the resources in \fItekMenu\fP. +This action sets the font used in the Tektronix window to the value of the +selected resource according to the argument. +The argument can be either a keyword or single-letter alias, +as shown in parentheses: +.RS +.TP 5 +large (l) +Use resource \fBfontLarge\fP, same as menu entry \fBtektextlarge\fP. +.TP 5 +two (2) +Use resource \fBfont2\fP, same as menu entry \fBtektext2\fP. +.TP 5 +three (3) +Use resource \fBfont3\fP, same as menu entry \fBtektext3\fP. +.TP 5 +small (s) +Use resource \fBfontSmall\fP, same as menu entry \fBtektextsmall\fP. +.RE .TP 8 .B "set-terminal-type(\fItype\fP)" This action directs output to either the \fIvt\fP or \fItek\fP windows, @@ -5707,31 +6007,31 @@ \fItekMenu\fP. .TP 8 .B "set-titeInhibit(\fIon/off/toggle\fP)" -This action toggles the \fBtiteInhibit\fP resource, +This action sets, unsets or toggles the \fBtiteInhibit\fP resource, which controls switching between the alternate and current screens. .TP 8 .B "set-toolbar(\fIon/off/toggle\fP)" -This action toggles the toolbar feature and is also invoked by -the \fBtoolbar\fP entry in \fImainMenu\fP. +This action sets, unsets or toggles the toolbar feature. +It is also invoked by the \fBtoolbar\fP entry in \fImainMenu\fP. .TP 8 .B "set-utf8-mode(\fIon/off/toggle\fP)" -This action toggles the \fButf8\fP resource and is also invoked by -the \fButf8-mode\fP entry in \fIfontMenu\fP. +This action sets, unsets or toggles the \fButf8\fP resource. +It is also invoked by the \fButf8-mode\fP entry in \fIfontMenu\fP. .TP 8 .B "set-utf8-title(\fIon/off/toggle\fP)" -This action toggles the \fButf8Title\fP resource and is also invoked by -the \fButf8-title\fP entry in \fIfontMenu\fP. +This action sets, unsets or toggles the \fButf8Title\fP resource. +It is also invoked by the \fButf8-title\fP entry in \fIfontMenu\fP. .TP 8 .B "set-visibility(\fIvt/tek\fP,\fIon/off/toggle\fP)" -This action controls whether or not the \fIvt\fP or \fItek\fP windows are +This action sets, unsets or toggles whether or not the \fIvt\fP or \fItek\fP windows are visible. It is also invoked from the \fBtekshow\fP and \fBvthide\fP entries in \fIvtMenu\fP and the \fBvtshow\fP and \fBtekhide\fP entries in \fItekMenu\fP. .TP 8 .B "set-visual-bell(\fIon/off/toggle\fP)" -This action toggles the \fBvisualBell\fP resource and is also invoked -by the \fBvisualbell\fP entry in \fIvtMenu\fP. +This action sets, unsets or toggles the \fBvisualBell\fP resource. +It is also invoked by the \fBvisualbell\fP entry in \fIvtMenu\fP. .TP 8 .B "set-vt-font(\fId/1/2/3/4/5/6/e/s\fP [,\fInormalfont\fP [, \fIboldfont\fP]])" This action sets the font or fonts currently being used in the VT102 window. @@ -5741,10 +6041,10 @@ .HP \fId\fP or \fID\fP indicate the default font (the font initially used when -\fIxterm\fP was started), +\fI\*n\fP was started), .HP \fI1\fP through \fI6\fP indicate the fonts -specified by the \fIfont1\fP through \fIfont6\fP resources, +specified by the \fBfont1\fP through \fBfont6\fP resources, .HP \fIe\fP or \fIE\fP indicate the normal and bold fonts that have been set through escape codes @@ -5754,7 +6054,7 @@ \fIxfontsel(__mansuffix__)\fP) indicated by the second action argument. .RE .IP -If \fIxterm\fR is configured to support wide characters, an +If \fI\*n\fR is configured to support wide characters, an additional two optional parameters are recognized for the \fIe\fP argument: wide font and wide bold font. .TP 8 @@ -5763,24 +6063,24 @@ See also \fBset-vt-font()\fP. .TP 8 .B "soft-reset()" -This action resets the scrolling region and is also invoked from the -\fBsoftreset\fP entry in \fIvtMenu\fP. +This action resets the scrolling region. +It is also invoked from the \fBsoftreset\fP entry in \fIvtMenu\fP. The effect is identical to a soft reset (DECSTR) control sequence. .TP 8 .B "spawn-new-terminal(params)" -Spawn a new \fIxterm\fP process. +Spawn a new \fI\*n\fP process. This is available on systems which have a modern version of the -process filesystem, e.g., \*(``/proc\*('', which \fIxterm\fP can read. +process filesystem, e.g., \*(``/proc\*('', which \fI\*n\fP can read. .IP Use the \*(``cwd\*('' process entry, e.g., /proc/12345/cwd to obtain the -working directory of the process which is running in the current \fIxterm\fP. +working directory of the process which is running in the current \fI\*n\fP. .IP On systems which have the \*(``exe\*('' process entry, e.g., /proc/12345/exe, use this to obtain the actual executable. -Otherwise, use the $PATH variable to find \fIxterm\fP. +Otherwise, use the $PATH variable to find \fI\*n\fP. .IP If parameters are given in the action, -pass them to the new \fIxterm\fP process. +pass them to the new \fI\*n\fP process. .TP 8 .B "start-extend()" This action is similar to \fBselect-start\fP except that the @@ -5804,12 +6104,12 @@ It is also invoked from the \fItekcopy\fP entry in \fItekMenu\fP. .TP 8 .B "tek-page()" -This action clears the Tektronix window and is also invoked by the -\fBtekpage\fP entry in \fItekMenu\fP. +This action clears the Tektronix window. +It is also invoked by the \fBtekpage\fP entry in \fItekMenu\fP. .TP 8 .B "tek-reset()" -This action resets the Tektronix window and is also invoked by the -\fItekreset\fP entry in \fItekMenu\fP. +This action resets the Tektronix window. +It is also invoked by the \fItekreset\fP entry in \fItekMenu\fP. .TP 8 .B "vi-button()" Handles a button event (other than press and release) @@ -5840,11 +6140,11 @@ .B "gin-press(\fIl/L/m/M/r/R\fP)" This action sends the indicated graphics input code. . +.SS DEFAULT KEY BINDINGS .PP The default bindings in the VT102 window use the SELECT token, which is set by the \fBselectToClipboard\fP resource: .NS -.ta 2.5i Shift Prior:scroll-back(1,halfpage) \\n\\\& Shift Next:scroll-forw(1,halfpage) \\n\\\& Shift Select:select-cursor-start() \\\& @@ -5889,10 +6189,10 @@ :select-end(SELECT, CUT_BUFFER0) \\n\\\& :ignore() .NE +.PP The default bindings for the scrollbar widget are separate from the VT100 widget: .NS -.ta 2.5i : StartScroll(Forward) \\n\\\& : StartScroll(Forward) \\n\\\& : StartScroll(Continuous) MoveThumb() NotifyThumb() \\n\\\& @@ -5901,9 +6201,9 @@ : MoveThumb() NotifyThumb() \\n\\\& : NotifyScroll(Proportional) EndScroll() .NE +.PP The default bindings in the Tektronix window are: .NS -.ta 2.5i ~Meta: insert-seven-bit() \\n\\\& Meta: insert-eight-bit() \\n\\\& !Ctrl : popup-menu(mainMenu) \\n\\\& @@ -5921,6 +6221,7 @@ Shift ~Meta: gin-press(R) \\n\\\& ~Meta: gin-press(r) .NE +.PP Here is an example which uses shifted select/paste to copy to the clipboard, and unshifted select/paste for the primary selection. In each case, a (different) cut buffer is @@ -5928,21 +6229,20 @@ It is important to remember however, that cut buffers store data in ISO-8859-1 encoding, while selections can store data in a variety of formats and encodings. -While \fIxterm\fP owns the selection, it highlights it. +While \fI\*n\fP owns the selection, it highlights it. When it loses the selection, it removes the corresponding highlight. But you can still paste from the corresponding cut buffer. .NS -.ta .5i 1.5i *VT100*translations: #override \\n\\\& ~Shift~Ctrl: insert-selection(PRIMARY, CUT_BUFFER0) \\n\\\& Shift~Ctrl: insert-selection(CLIPBOARD, CUT_BUFFER1) \\n\\\& ~Shift: select-end(PRIMARY, CUT_BUFFER0) \\n\\\& Shift: select-end(CLIPBOARD, CUT_BUFFER1) .NE +.PP Below is a sample of how the \fBkeymap()\fP action is used to add special keys for entering commonly-typed works: .NS -.ta .5i 1.5i *VT100.Translations: #override F13: keymap(dbx) *VT100.dbxKeymap.translations: \\\& F14: keymap(None) \\n\\\& @@ -5951,11 +6251,11 @@ F19: string("continue") string(0x0d) \\n\\\& F20: string("print ") insert-selection(PRIMARY, CUT_BUFFER0) .NE +.PP Some people prefer using the left pointer button for dragging the scrollbar thumb. That can be setup by altering the translations resource, e.g., .NS -.ta .5i 1.5i *VT100.scrollbar.translations: #override \\n\\\& : StartScroll(Forward) \\n\\\& : StartScroll(Continuous) MoveThumb() NotifyThumb() \\n\\\& @@ -5965,7 +6265,7 @@ .NE .SH "CONTROL SEQUENCES AND KEYBOARD" The \fIXterm Control Sequences\fP document lists the control sequences which -an application can send \fIxterm\fP to make it perform various operations. +an application can send \fI\*n\fP to make it perform various operations. Most of these operations are standardized, from either the DEC or Tektronix terminals, or from more widely used standards such as ISO-6429. . @@ -5983,10 +6283,14 @@ a reference. .TP 5 WINDOWID -is set to the X window id number of the \fIxterm\fP window. +is set to the X window id number of the \fI\*n\fP window. +.TP 5 +XTERM_FILTER +is set if a locale-filter is used. +The value is the pathname of the filter. .TP 5 XTERM_LOCALE -shows the locale which was used by \fIxterm\fP on startup. +shows the locale which was used by \fI\*n\fP on startup. Some shell initialization scripts may set a different locale. .TP 5 XTERM_SHELL @@ -5998,29 +6302,29 @@ XTERM_VERSION is set to the string displayed by the \fB\-version\fP option. That is normally an identifier for the X Window libraries used to -build \fIxterm\fP, followed by -\fIxterm\fP's patch number in parenthesis. +build \fI\*n\fP, followed by +\fI\*n\fP's patch number in parenthesis. The patch number is also part of the response to a Secondary Device Attributes (DA) control sequence (see \fIXterm Control Sequences\fP). . .PP -Depending on your system configuration, \fIxterm\fP may also set the +Depending on your system configuration, \fI\*n\fP may also set the following: .TP 5 COLUMNS -the width of the \fIxterm\fP in characters (cf: \*(``stty columns\*(''). +the width of the \fI\*n\fP in characters (cf: \*(``stty columns\*(''). .TP 5 HOME -when \fIxterm\fP is configured to update utmp. +when \fI\*n\fP is configured to update utmp. .TP 5 LINES -the height of the \fIxterm\fP in characters (cf: \*(``stty rows\*(''). +the height of the \fI\*n\fP in characters (cf: \*(``stty rows\*(''). .TP 5 LOGNAME -when \fIxterm\fP is configured to update utmp. +when \fI\*n\fP is configured to update utmp. .TP 5 SHELL -when \fIxterm\fP is configured to update utmp. +when \fI\*n\fP is configured to update utmp. It is also set if you provide the shell name as the optional parameter. .TP 5 TERMCAP @@ -6043,10 +6347,10 @@ the system logfile, which records user logins and logouts. .TP 5 .I __apploaddir__/__default_class__ -the \fIxterm\fP default application resources. +the \fI\*n\fP default application resources. .TP 5 .I __apploaddir__/__default_class__\-color -the \fIxterm\fP color application resources. +the \fI\*n\fP color application resources. If your display supports color, use this .in +10 *customization: \-color @@ -6055,15 +6359,18 @@ automatically use this resource file rather than .IR __apploaddir__/__default_class__ . If you do not do this, -\fIxterm\fP uses its compiled-in default resource settings for colors. +\fI\*n\fP uses its compiled-in default resource settings for colors. +.TP 5 +.I __pixmapsdir__ +the directory in which \fI\*n\fP's pixmap icon files are installed. . . .SH ERROR MESSAGES -Most of the fatal error messages from \fIxterm\fP use the following format: +Most of the fatal error messages from \fI\*n\fP use the following format: .RS -xterm: Error \fIXXX\fP, errno \fIYYY\fP: \fIZZZ\fP +\*n: Error \fIXXX\fP, errno \fIYYY\fP: \fIZZZ\fP .RE -The \fIXXX\fP codes (which are used by \fIxterm\fP as its exit-code) +The \fIXXX\fP codes (which are used by \fI\*n\fP as its exit-code) are listed below, with a brief explanation. .TP 5 1 @@ -6263,11 +6570,6 @@ ERROR_SAVE_PTR .br ScrnPointers: malloc/realloc() failed -.TP -121 -ERROR_MMALLOC -.br -my_memmove: malloc/realloc failed . . .SH BUGS @@ -6275,19 +6577,19 @@ .PP Large pastes do not work on some systems. This is not a bug in -\fIxterm\fP; it is a bug in the pseudo terminal driver of those +\fI\*n\fP; it is a bug in the pseudo terminal driver of those systems. -\fIxterm\fP feeds large pastes to the pty only as fast as the pty +\fI\*n\fP feeds large pastes to the pty only as fast as the pty will accept data, but some pty drivers do not return enough information to know if the write has succeeded. . .PP -When connected to an input method, it is possible for xterm to hang +When connected to an input method, it is possible for \*n to hang if the XIM server is suspended or killed. . .PP Many of the options are not resettable after -.I xterm +.I \*n starts. . .PP @@ -6306,7 +6608,7 @@ .na resize(__mansuffix__), luit(__mansuffix__), -uxterm(__mansuffix__), +u\*n(__mansuffix__), X(__miscmansuffix__), pty(4), tty(4) diff -Nru xterm-278/xterm_io.h xterm-297/xterm_io.h --- xterm-278/xterm_io.h 2011-12-30 22:45:49.000000000 +0000 +++ xterm-297/xterm_io.h 2013-01-06 15:20:45.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: xterm_io.h,v 1.53 2011/12/30 22:45:49 tom Exp $ */ +/* $XTermId: xterm_io.h,v 1.56 2013/01/06 15:20:45 tom Exp $ */ /* - * Copyright 2000-2006,2010 by Thomas E. Dickey + * Copyright 2000-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -52,10 +52,6 @@ #define USE_SYSV_TERMIO #endif -#ifdef __UNIXOS2__ -#define USE_SYSV_TERMIO -#endif - #if defined(__DragonFly__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__INTERIX) || defined(__APPLE__) || defined(__UNIXWARE__) || defined(__hpux) #ifndef USE_POSIX_TERMIOS #define USE_POSIX_TERMIOS @@ -171,11 +167,6 @@ #include /* get struct winsize */ #endif #endif /* USE_USG_PTYS */ -#elif defined(sun) && !defined(SVR4) -#include -#ifdef TIOCSWINSZ -#undef TIOCSSIZE -#endif #endif /* SYSV */ /* @@ -186,56 +177,6 @@ #define TIOCSPGRP (_IOW('t', 118, pid_t)) #endif -#ifdef __UNIXOS2__ - -#define XFREE86_PTY 0x76 - -#define XTY_TIOCSETA 0x48 -#define XTY_TIOCSETAW 0x49 -#define XTY_TIOCSETAF 0x4a -#define XTY_TIOCCONS 0x4d -#define XTY_TIOCSWINSZ 0x53 -#define XTY_ENADUP 0x5a -#define XTY_TRACE 0x5b -#define XTY_TIOCGETA 0x65 -#define XTY_TIOCGWINSZ 0x66 -#define PTMS_GETPTY 0x64 -#define PTMS_BUFSZ 14 - -#ifndef NCCS -#define NCCS 11 -#endif - -#define TIOCCONS 108 -#define TIOCSWINSZ 113 -#define TIOCGWINSZ 117 - -struct pt_termios -{ - unsigned short c_iflag; - unsigned short c_oflag; - unsigned short c_cflag; - unsigned short c_lflag; - unsigned char c_cc[NCCS]; - long _reserved_[4]; -}; - -struct winsize { - unsigned short ws_row; /* rows, in characters */ - unsigned short ws_col; /* columns, in characters */ - unsigned short ws_xpixel; /* horizontal size, pixels */ - unsigned short ws_ypixel; /* vertical size, pixels */ -}; -#define TTYSIZE_STRUCT struct winsize -#define USE_STRUCT_WINSIZE 1 - -#ifdef XTERM_MAIN -extern int ptioctl(int fd, int func, void* data); -#define ioctl ptioctl -#endif - -#endif /* __UNIXOS2__ */ - #ifdef __hpux #include /* defines TIOCSLTC */ #endif @@ -283,25 +224,30 @@ #endif #if !defined(TTYSIZE_STRUCT) -#if defined(TIOCSSIZE) && (defined(sun) && !defined(SVR4)) -#define USE_STRUCT_TTYSIZE 1 -#define TTYSIZE_STRUCT struct ttysize -#elif defined(TIOCSWINSZ) +#if defined(TIOCSWINSZ) #define USE_STRUCT_WINSIZE 1 #define TTYSIZE_STRUCT struct winsize -#endif /* sun vs TIOCSWINSZ */ -#endif /* TTYSIZE_STRUCT */ - -#if defined(USE_STRUCT_TTYSIZE) -#define TTYSIZE_STRUCT struct ttysize -#define SET_TTYSIZE(fd, data) ioctl(fd, TIOCSSIZE, &data); -#define TTYSIZE_COLS(data) data.ts_cols -#define TTYSIZE_ROWS(data) data.ts_lines -#elif defined(USE_STRUCT_WINSIZE) -#define TTYSIZE_STRUCT struct winsize +#define GET_TTYSIZE(fd, data) ioctl(fd, TIOCGWINSZ, (char *) &data) #define SET_TTYSIZE(fd, data) ioctl(fd, TIOCSWINSZ, (char *) &data) #define TTYSIZE_COLS(data) data.ws_col #define TTYSIZE_ROWS(data) data.ws_row +#endif /* TIOCSWINSZ */ +#endif /* TTYSIZE_STRUCT */ + +#ifndef USE_STRUCT_WINSIZE +#error "There is a configuration error with struct winsize ifdef" +#endif + +#if OPT_TRACE +#define TRACE_TTYSIZE(fd, id) { \ + TTYSIZE_STRUCT debug_ttysize; \ + if (GET_TTYSIZE(fd, debug_ttysize) == 0) \ + TRACE(("%s@%d, TTYSIZE %s %d %d\n", __FILE__, __LINE__, id, TTYSIZE_ROWS(debug_ttysize), TTYSIZE_COLS(debug_ttysize))); \ + else \ + TRACE(("%s@%d, TTYSIZE failed %s\n", __FILE__, __LINE__, strerror(errno))); \ + } +#else +#define TRACE_TTYSIZE(fd, id) /* nothing */ #endif typedef unsigned short ttySize_t; diff -Nru xterm-278/xtermcap.h xterm-297/xtermcap.h --- xterm-278/xtermcap.h 2011-09-11 14:59:33.000000000 +0000 +++ xterm-297/xtermcap.h 2013-06-23 15:34:37.000000000 +0000 @@ -1,4 +1,4 @@ -/* $XTermId: xtermcap.h,v 1.18 2011/09/11 14:59:33 tom Exp $ */ +/* $XTermId: xtermcap.h,v 1.19 2013/06/23 15:34:37 tom Exp $ */ /* * Copyright 2007-2010,2011 by Thomas E. Dickey @@ -35,6 +35,7 @@ */ #ifndef included_xtermcap_h #define included_xtermcap_h +/* *INDENT-OFF* */ #include @@ -115,4 +116,5 @@ } #endif +/* *INDENT-ON* */ #endif /* included_xtermcap_h */ diff -Nru xterm-278/xtermcfg.hin xterm-297/xtermcfg.hin --- xterm-278/xtermcfg.hin 2012-01-05 10:28:29.000000000 +0000 +++ xterm-297/xtermcfg.hin 2013-06-23 19:20:22.000000000 +0000 @@ -1,7 +1,7 @@ -/* $XTermId: xtermcfg.hin,v 1.188 2012/01/05 10:28:29 tom Exp $ */ +/* $XTermId: xtermcfg.hin,v 1.200 2013/06/23 19:20:22 tom Exp $ */ /* - * Copyright 1997-2010,2011 by Thomas E. Dickey + * Copyright 1997-2012,2013 by Thomas E. Dickey * * All Rights Reserved * @@ -40,6 +40,11 @@ #undef CC_HAS_PROTOS /* CF_ANSI_CC */ #undef CSRG_BASED /* CF_TYPE_FD_MASK */ #undef DECL_ERRNO /* CF_ERRNO */ +#undef DEFDELETE_DEL /* AC_ARG_ENABLE(delete-is-del) */ +#undef DEF_ALT_SENDS_ESC /* CF_ARG_ENABLE(alt-sends-esc) */ +#undef DEF_BACKARO_BS /* CF_ARG_DISABLE(backarrow-key) */ +#undef DEF_BACKARO_ERASE /* CF_ARG_ENABLE(backarrow-is-erase) */ +#undef DEF_META_SENDS_ESC /* CF_ARG_ENABLE(meta-sends-esc) */ #undef DFT_COLORMODE /* AC_ARG_WITH(default-color-mode) */ #undef DFT_DECID /* AC_ARG_WITH(default-terminal-id) */ #undef DFT_TERMTYPE /* AC_ARG_WITH(default-term-type) */ @@ -48,8 +53,10 @@ #undef HAVE_GETHOSTNAME /* AC_CHECK_FUNCS(gethostname) */ #undef HAVE_GETLOGIN /* AC_CHECK_FUNCS(getlogin) */ #undef HAVE_GRANTPT /* CF_FUNC_GRANTPT */ +#undef HAVE_GRANTPT_PTY_ISATTY /* CF_FUNC_GRANTPT */ #undef HAVE_LANGINFO_CODESET /* AM_LANGINFO_CODESET */ #undef HAVE_LASTLOG_H /* CF_LASTLOG */ +#undef HAVE_LIBXPM /* CF_WITH_XPM */ #undef HAVE_LIB_NEXTAW /* CF_X_ATHENA(--with-neXtaw) */ #undef HAVE_LIB_PCRE /* CF_WITH_PCRE */ #undef HAVE_LIB_XAW /* CF_X_ATHENA */ @@ -66,7 +73,6 @@ #undef HAVE_SCHED_YIELD /* AC_CHECK_FUNCS(sched_yield) */ #undef HAVE_SETPGID /* AC_CHECK_FUNCS(setpgid) */ #undef HAVE_STDLIB_H /* AC_CHECK_HEADERS(stdlib.h) */ -#undef HAVE_STRERROR /* AC_CHECK_FUNCS(strerror) */ #undef HAVE_STRFTIME /* AC_CHECK_FUNCS(strftime) */ #undef HAVE_SYS_TIME_H /* AC_HEADER_TIME */ #undef HAVE_SYS_TTYDEFAULTS_H /* AC_CHECK_HEADERS(sys/ttydefaults.h) */ @@ -98,6 +104,7 @@ #undef HAVE_X11_XPOLL_H /* AC_CHECK_HEADERS(X11/Xpoll.h) */ #undef HAVE_XFTDRAWSETCLIP /* CF_X_FREETYPE */ #undef HAVE_XFTDRAWSETCLIPRECTANGLES /* CF_X_FREETYPE */ +#undef HAVE_XKBKEYCODETOKEYSYM /* AC_CHECK_FUNCS(XkbKeycodeToKeysym) */ #undef HAVE_XKBQUERYEXTENSION /* AC_CHECK_FUNCS(XkbQueryExtension) */ #undef HAVE_XKB_BELL_EXT /* CF_XKB_BELL_EXT */ #undef LUIT_PATH /* CF_ARG_ENABLE(luit) */ @@ -116,6 +123,7 @@ #undef OPT_DABBREV /* CF_ARG_ENABLE(dabbrev) */ #undef OPT_DEC_CHRSET /* CF_ARG_DISABLE(doublechars) */ #undef OPT_DEC_LOCATOR /* CF_ARG_ENABLE(dec-locator) */ +#undef OPT_DOUBLE_BUFFER /* CF_ARG_ENABLE(double-buffer) */ #undef OPT_DEC_RECTOPS /* CF_ARG_ENABLE(rectangles) */ #undef OPT_EXEC_XTERM /* CF_ARG_ENABLE(exec-xterm) */ #undef OPT_FIFO_LINES /* CF_ARG_ENABLE(fifo-lines) */ @@ -139,6 +147,7 @@ #undef OPT_SELECTION_OPS /* CF_ARG_DISABLE(selection-ops) */ #undef OPT_SELECT_REGEX /* CF_ARG_DISABLE(regex) */ #undef OPT_SESSION_MGT /* CF_ARG_DISABLE(session-mgt) */ +#undef OPT_SIXEL_GRAPHICS /* CF_ARG_ENABLE(sixel-graphics) */ #undef OPT_SUN_FUNC_KEYS /* CF_ARG_ENABLE(sun-fkeys) */ #undef OPT_TCAP_FKEYS /* CF_ARG_ENABLE(tcap-fkeys) */ #undef OPT_TCAP_QUERY /* CF_ARG_ENABLE(tcap-query) */ @@ -158,8 +167,6 @@ #undef TIME_WITH_SYS_TIME /* AC_HEADER_TIME */ #undef TTY_GROUP_NAME /* CF_TTY_GROUP */ #undef USE_LASTLOG /* CF_LASTLOG */ -#undef USE_MY_MEMMOVE /* CF_FUNC_MEMMOVE */ -#undef USE_OK_BCOPY /* CF_FUNC_MEMMOVE */ #undef USE_POSIX_WAIT /* CF_POSIX_WAIT */ #undef USE_STRUCT_LASTLOG /* CF_STRUCT_LASTLOG */ #undef USE_SYSV_UTMP /* CF_UTMP */ @@ -171,12 +178,11 @@ #undef USE_UTMP_SETGID /* AC_ARG_WITH(utmp-setgid) */ #undef UTMPX_FOR_UTMP /* CF_UTMP */ #undef XRENDERFONT /* CF_X_FREETYPE */ -#undef const /* AC_CONST */ +#undef cc_t /* CF_TYPE_CC_T */ #undef gid_t /* AC_TYPE_UID_T */ #undef mode_t /* AC_TYPE_MODE_T */ #undef off_t /* AC_TYPE_OFF_T */ #undef pid_t /* AC_TYPE_PID_T */ -#undef size_t /* AC_TYPE_SIZE_T */ #undef time_t /* AC_CHECK_TYPE(time_t, long) */ #undef uid_t /* AC_TYPE_UID_T */ #undef ut_name /* CF_UTMP */ @@ -197,23 +203,10 @@ #ifndef __cplusplus #undef GCC_PRINTF #undef GCC_PRINTFLIKE +#undef GCC_NORETURN #undef GCC_UNUSED #endif -#ifdef USE_OK_BCOPY -#define memmove(d,s,n) bcopy(s,d,n) -#endif - -#ifdef USE_MY_MEMMOVE -#define memmove(d,s,n) my_memmove(d,s,n) -extern void * my_memmove(void * s1, void * s2, size_t n); -#endif - -#ifndef HAVE_STRERROR -#define strerror(n) my_strerror(n) -extern char *my_strerror(int n); -#endif - #ifndef HAVE_X11_XPOLL_H #define NO_XPOLL_H /* X11R6.1 & up use Xpoll.h for select() definitions */ #endif diff -Nru xterm-278/xutf8.c xterm-297/xutf8.c --- xterm-278/xutf8.c 2011-09-11 14:59:37.000000000 +0000 +++ xterm-297/xutf8.c 2012-05-09 20:56:09.000000000 +0000 @@ -1,4 +1,4 @@ -/* $XTermId: xutf8.c,v 1.11 2011/09/11 14:59:37 tom Exp $ */ +/* $XTermId: xutf8.c,v 1.13 2012/05/09 20:56:09 tom Exp $ */ /* * Copyright (c) 2001 by Juliusz Chroboczek @@ -68,7 +68,7 @@ } static void -utf8insert(char *dest, int c, int *len_return) +utf8insert(char *dest, int c, size_t *len_return) { if (c < 0) return; @@ -95,10 +95,10 @@ } static int -l1countUtf8Bytes(char *s, int len) +l1countUtf8Bytes(char *s, size_t len) { int l = 0; - while (len > 0) { + while (len != 0) { if ((*s & 0x80) == 0) l++; else @@ -110,12 +110,12 @@ } static void -l1utf8copy(char *d, char *s, int len) +l1utf8copy(char *d, char *s, size_t len) { - int l; - while (len > 0) { + size_t l; + while (len != 0) { utf8insert(d, (*s) & 0xFF, &l); - d += l; + d += (int) l; s++; len--; } @@ -334,7 +334,7 @@ int rc; KeySym keysym; int codepoint; - int len; + size_t len; rc = XLookupString(ev, buffer, nbytes, &keysym, NULL); @@ -367,7 +367,7 @@ } else { *status_return = XLookupChars; } - return len; + return (int) len; } #else /* X_HAVE_UTF8_STRING */ /* Silence the compiler */