ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/doc/rxvt.7.man.in
(Generate patch)

Comparing rxvt-unicode/doc/rxvt.7.man.in (file contents):
Revision 1.55 by root, Mon Jan 30 22:49:30 2006 UTC vs.
Revision 1.63 by root, Tue Jan 31 20:57:29 2006 UTC

127.\} 127.\}
128.rm #[ #] #H #V #F C 128.rm #[ #] #H #V #F C
129.\" ======================================================================== 129.\" ========================================================================
130.\" 130.\"
131.IX Title "rxvt 7" 131.IX Title "rxvt 7"
132.TH rxvt 7 "2006-01-30" "7.4" "RXVT-UNICODE" 132.TH rxvt 7 "2006-01-31" "7.5" "RXVT-UNICODE"
133.SH "NAME" 133.SH "NAME"
134RXVT REFERENCE \- FAQ, command sequences and other background information 134RXVT REFERENCE \- FAQ, command sequences and other background information
135.SH "SYNOPSIS" 135.SH "SYNOPSIS"
136.IX Header "SYNOPSIS" 136.IX Header "SYNOPSIS"
137.Vb 2 137.Vb 2
151.SH "DESCRIPTION" 151.SH "DESCRIPTION"
152.IX Header "DESCRIPTION" 152.IX Header "DESCRIPTION"
153This document contains the \s-1FAQ\s0, the \s-1RXVT\s0 \s-1TECHNICAL\s0 \s-1REFERENCE\s0 documenting 153This document contains the \s-1FAQ\s0, the \s-1RXVT\s0 \s-1TECHNICAL\s0 \s-1REFERENCE\s0 documenting
154all escape sequences, and other background information. 154all escape sequences, and other background information.
155.PP 155.PP
156The newest version of this document is 156The newest version of this document is also available on the World Wide Web at
157also available on the World Wide Web at
158<http://cvs.schmorp.de/browse/*checkout*/rxvt\-unicode/doc/rxvt.7.html>. 157<http://cvs.schmorp.de/browse/*checkout*/rxvt\-unicode/doc/rxvt.7.html>.
159.SH "FREQUENTLY ASKED QUESTIONS" 158.SH "FREQUENTLY ASKED QUESTIONS"
160.IX Header "FREQUENTLY ASKED QUESTIONS" 159.IX Header "FREQUENTLY ASKED QUESTIONS"
161.IP "The new selection selects pieces that are too big, how can I select single words?" 4 160.Sh "Meta, Features & Commandline Issues"
162.IX Item "The new selection selects pieces that are too big, how can I select single words?" 161.IX Subsection "Meta, Features & Commandline Issues"
163Yes. For example, if you want to select alphanumeric words, you can use 162\fIMy question isn't answered here, can I ask a human?\fR
164the following resource: 163.IX Subsection "My question isn't answered here, can I ask a human?"
165.Sp 164.PP
165Before sending me mail, you could go to \s-1IRC:\s0 \f(CW\*(C`irc.freenode.net\*(C'\fR,
166channel \f(CW\*(C`#rxvt\-unicode\*(C'\fR has some rxvt-unicode enthusiasts that might be
167interested in learning about new and exciting problems (but not FAQs :).
168.PP
169\fIDoes it support tabs, can I have a tabbed rxvt\-unicode?\fR
170.IX Subsection "Does it support tabs, can I have a tabbed rxvt-unicode?"
171.PP
172Beginning with version 7.3, there is a perl extension that implements a
173simple tabbed terminal. It is installed by default, so any of these should
174give you tabs:
175.PP
166.Vb 1 176.Vb 1
167\& URxvt.selection.pattern-0: ([[:word:]]+) 177\& @@URXVT_NAME@@ -pe tabbed
168.Ve 178.Ve
169.Sp 179.PP
170If you click more than twice, the selection will be extended
171more and more.
172.Sp
173To get a selection that is very similar to the old code, try this pattern:
174.Sp
175.Vb 1 180.Vb 1
176\& URxvt.selection.pattern-0: ([^"&'()*,;<=>?@[\e\e\e\e]^`{|})]+) 181\& URxvt.perl-ext-common: default,tabbed
177.Ve 182.Ve
178.Sp 183.PP
179Please also note that the \fILeftClick Shift-LeftClik\fR combination also 184It will also work fine with tabbing functionality of many window managers
180selects words like the old code. 185or similar tabbing programs, and its embedding-features allow it to be
181.IP "I don't like the new selection/popups/hotkeys/perl, how do I change/disable it?" 4 186embedded into other programs, as witnessed by \fIdoc/rxvt\-tabbed\fR or
182.IX Item "I don't like the new selection/popups/hotkeys/perl, how do I change/disable it?" 187the upcoming \f(CW\*(C`Gtk2::URxvt\*(C'\fR perl module, which features a tabbed urxvt
183You can disable the perl extension completely by setting the 188(murxvt) terminal as an example embedding application.
184\&\fBperl-ext-common\fR resource to the empty string, which also keeps 189.PP
185rxvt-unicode from initialising perl, saving memory. 190\fIHow do I know which rxvt-unicode version I'm using?\fR
186.Sp 191.IX Subsection "How do I know which rxvt-unicode version I'm using?"
187If you only want to disable specific features, you first have to 192.PP
188identify which perl extension is responsible. For this, read the section 193The version number is displayed with the usage (\-h). Also the escape
189\&\fB\s-1PREPACKAGED\s0 \s-1EXTENSIONS\s0\fR in the @@RXVT_NAME@@\fIperl\fR\|(3) manpage. For 194sequence \f(CW\*(C`ESC [ 8 n\*(C'\fR sets the window title to the version number. When
190example, to disable the \fBselection-popup\fR and \fBoption-popup\fR, specify 195using the @@URXVT_NAME@@c client, the version displayed is that of the
191this \fBperl-ext-common\fR resource: 196daemon.
192.Sp 197.PP
198\fIRxvt-unicode uses gobs of memory, how can I reduce that?\fR
199.IX Subsection "Rxvt-unicode uses gobs of memory, how can I reduce that?"
200.PP
201Rxvt-unicode tries to obey the rule of not charging you for something you
202don't use. One thing you should try is to configure out all settings that
203you don't need, for example, Xft support is a resource hog by design,
204when used. Compiling it out ensures that no Xft font will be loaded
205accidentally when rxvt-unicode tries to find a font for your characters.
206.PP
207Also, many people (me included) like large windows and even larger
208scrollback buffers: Without \f(CW\*(C`\-\-enable\-unicode3\*(C'\fR, rxvt-unicode will use
2096 bytes per screen cell. For a 160x?? window this amounts to almost a
210kilobyte per line. A scrollback buffer of 10000 lines will then (if full)
211use 10 Megabytes of memory. With \f(CW\*(C`\-\-enable\-unicode3\*(C'\fR it gets worse, as
212rxvt-unicode then uses 8 bytes per screen cell.
213.PP
214\fIHow can I start @@URXVT_NAME@@d in a race-free way?\fR
215.IX Subsection "How can I start @@URXVT_NAME@@d in a race-free way?"
216.PP
217Try \f(CW\*(C`@@URXVT_NAME@@d \-f \-o\*(C'\fR, which tells @@URXVT_NAME@@d to open the
218display, create the listening socket and then fork.
219.PP
220\fIHow do I distinguish wether I'm running rxvt-unicode or a regular xterm? I need this to decide about setting colors etc.\fR
221.IX Subsection "How do I distinguish wether I'm running rxvt-unicode or a regular xterm? I need this to decide about setting colors etc."
222.PP
223rxvt and rxvt-unicode always export the variable \*(L"\s-1COLORTERM\s0\*(R", so you can
224check and see if that is set. Note that several programs, \s-1JED\s0, slrn,
225Midnight Commander automatically check this variable to decide whether or
226not to use color.
227.PP
228\fIHow do I set the correct, full \s-1IP\s0 address for the \s-1DISPLAY\s0 variable?\fR
229.IX Subsection "How do I set the correct, full IP address for the DISPLAY variable?"
230.PP
231If you've compiled rxvt-unicode with \s-1DISPLAY_IS_IP\s0 and have enabled
232insecure mode then it is possible to use the following shell script
233snippets to correctly set the display. If your version of rxvt-unicode
234wasn't also compiled with \s-1ESCZ_ANSWER\s0 (as assumed in these snippets) then
235the \s-1COLORTERM\s0 variable can be used to distinguish rxvt-unicode from a
236regular xterm.
237.PP
238Courtesy of Chuck Blake <cblake@BBN.COM> with the following shell script
239snippets:
240.PP
193.Vb 1 241.Vb 12
194\& URxvt.perl-ext-common: default,-selection-popup,-option-popup 242\& # Bourne/Korn/POSIX family of shells:
243\& [ ${TERM:-foo} = foo ] && TERM=xterm # assume an xterm if we don't know
244\& if [ ${TERM:-foo} = xterm ]; then
245\& stty -icanon -echo min 0 time 15 # see if enhanced rxvt or not
246\& echo -n '^[Z'
247\& read term_id
248\& stty icanon echo
249\& if [ ""${term_id} = '^[[?1;2C' -a ${DISPLAY:-foo} = foo ]; then
250\& echo -n '^[[7n' # query the rxvt we are in for the DISPLAY string
251\& read DISPLAY # set it in our local shell
252\& fi
253\& fi
195.Ve 254.Ve
196.Sp 255.PP
197This will keep the default extensions, but disable the two popup 256\fIHow do I compile the manual pages on my own?\fR
198extensions. Some extensions can also be configured, for example, 257.IX Subsection "How do I compile the manual pages on my own?"
199scrollback search mode is triggered by \fBM\-s\fR. You can move it to any 258.PP
200other combination either by setting the \fBsearchable-scrollback\fR resource: 259You need to have a recent version of perl installed as \fI/usr/bin/perl\fR,
201.Sp 260one that comes with \fIpod2man\fR, \fIpod2text\fR and \fIpod2html\fR. Then go to
202.Vb 1 261the doc subdirectory and enter \f(CW\*(C`make alldoc\*(C'\fR.
203\& URxvt.searchable-scrollback: CM-s 262.PP
204.Ve
205.IP "Why doesn't rxvt-unicode read my resources?" 4
206.IX Item "Why doesn't rxvt-unicode read my resources?"
207Well, why, indeed? It does, in a way very similar to other X
208applications. Most importantly, this means that if you or your \s-1OS\s0 loads
209resources into the X display (the right way to do it), rxvt-unicode will
210ignore any resource files in your home directory. It will only read
211\&\fI$HOME/.Xdefaults\fR when no resources are attached to the display.
212.Sp
213If you have or use an \fI$HOME/.Xresources\fR file, chances are that
214resources are loaded into your X\-server. In this case, you have to
215re-login after every change (or run \fIxrdb \-merge \f(CI$HOME\fI/.Xresources\fR).
216.Sp
217Also consider the form resources have to use:
218.Sp
219.Vb 1
220\& URxvt.resource: value
221.Ve
222.Sp
223If you want to use another form (there are lots of different ways of
224specifying resources), make sure you understand wether and why it
225works. If unsure, use the form above.
226.IP "I can't get transparency working, what am I doing wrong?" 4
227.IX Item "I can't get transparency working, what am I doing wrong?"
228First of all, transparency isn't officially supported in rxvt\-unicode, so
229you are mostly on your own. Do not bug the author about it (but you may
230bug everybody else). Also, if you can't get it working consider it a rite
231of passage, and you failed.
232.Sp
233Here are three ways to get transparency. \fBDo\fR read the manpage and option
234descriptions for the programs mentioned and rxvt\-unicode. Really, do it!
235.Sp
2361. Use inheritPixmap:
237.Sp
238.Vb 2
239\& Esetroot wallpaper.jpg
240\& @@RXVT_NAME@@ -ip -tint red -sh 40
241.Ve
242.Sp
243That works. If you think it doesn't, you lack transparency and tinting
244support, or you are unable to read.
245.Sp
2462. Use a simple pixmap and emulate pseudo\-transparency. This enables you
247to use effects other than tinting and shading: Just shade/tint/whatever
248your picture with gimp:
249.Sp
250.Vb 2
251\& convert wallpaper.jpg -blur 20x20 -modulate 30 background.xpm
252\& @@RXVT_NAME@@ -pixmap background.xpm -pe automove-background
253.Ve
254.Sp
255That works. If you think it doesn't, you lack \s-1XPM\s0 and Perl support, or you
256are unable to read.
257.Sp
2583. Use an \s-1ARGB\s0 visual:
259.Sp
260.Vb 1
261\& @@RXVT_NAME@@ -depth 432 -fg grey90 -bg rgba:0000/0000/0000/c000
262.Ve
263.Sp
264This requires \s-1XFT\s0 support, and support form your X\-server. If that doesn't
265work for you, blame Xorg and Keith Packard. \s-1ARGB\s0 visuals aren't there yet,
266no matter what they claim. Rxvt-Unicode contains the neccessary bugfixes
267and workarounds for Xft and Xlib to make it work.
268.IP "Isn't rxvt supposed to be small? Don't all those features bloat?" 4 263\fIIsn't rxvt-unicode supposed to be small? Don't all those features bloat?\fR
269.IX Item "Isn't rxvt supposed to be small? Don't all those features bloat?" 264.IX Subsection "Isn't rxvt-unicode supposed to be small? Don't all those features bloat?"
265.PP
270I often get asked about this, and I think, no, they didn't cause extra 266I often get asked about this, and I think, no, they didn't cause extra
271bloat. If you compare a minimal rxvt and a minimal urxvt, you can see 267bloat. If you compare a minimal rxvt and a minimal urxvt, you can see
272that the urxvt binary is larger (due to some encoding tables always being 268that the urxvt binary is larger (due to some encoding tables always being
273compiled in), but it actually uses less memory (\s-1RSS\s0) after startup. Even 269compiled in), but it actually uses less memory (\s-1RSS\s0) after startup. Even
274with \f(CW\*(C`\-\-disable\-everything\*(C'\fR, this comparison is a bit unfair, as many 270with \f(CW\*(C`\-\-disable\-everything\*(C'\fR, this comparison is a bit unfair, as many
275features unique to urxvt (locale, encoding conversion, iso14755 etc.) are 271features unique to urxvt (locale, encoding conversion, iso14755 etc.) are
276already in use in this mode. 272already in use in this mode.
277.Sp 273.PP
278.Vb 3 274.Vb 3
279\& text data bss drs rss filename 275\& text data bss drs rss filename
280\& 98398 1664 24 15695 1824 rxvt --disable-everything 276\& 98398 1664 24 15695 1824 rxvt --disable-everything
281\& 188985 9048 66616 18222 1788 urxvt --disable-everything 277\& 188985 9048 66616 18222 1788 urxvt --disable-everything
282.Ve 278.Ve
283.Sp 279.PP
284When you \f(CW\*(C`\-\-enable\-everything\*(C'\fR (which _is_ unfair, as this involves xft 280When you \f(CW\*(C`\-\-enable\-everything\*(C'\fR (which _is_ unfair, as this involves xft
285and full locale/XIM support which are quite bloaty inside libX11 and my 281and full locale/XIM support which are quite bloaty inside libX11 and my
286libc), the two diverge, but not unreasnobaly so. 282libc), the two diverge, but not unreasnobaly so.
287.Sp 283.PP
288.Vb 3 284.Vb 3
289\& text data bss drs rss filename 285\& text data bss drs rss filename
290\& 163431 2152 24 20123 2060 rxvt --enable-everything 286\& 163431 2152 24 20123 2060 rxvt --enable-everything
291\& 1035683 49680 66648 29096 3680 urxvt --enable-everything 287\& 1035683 49680 66648 29096 3680 urxvt --enable-everything
292.Ve 288.Ve
293.Sp 289.PP
294The very large size of the text section is explained by the east-asian 290The very large size of the text section is explained by the east-asian
295encoding tables, which, if unused, take up disk space but nothing else 291encoding tables, which, if unused, take up disk space but nothing else
296and can be compiled out unless you rely on X11 core fonts that use those 292and can be compiled out unless you rely on X11 core fonts that use those
297encodings. The \s-1BSS\s0 size comes from the 64k emergency buffer that my c++ 293encodings. The \s-1BSS\s0 size comes from the 64k emergency buffer that my c++
298compiler allocates (but of course doesn't use unless you are out of 294compiler allocates (but of course doesn't use unless you are out of
299memory). Also, using an xft font instead of a core font immediately adds a 295memory). Also, using an xft font instead of a core font immediately adds a
300few megabytes of \s-1RSS\s0. Xft indeed is responsible for a lot of \s-1RSS\s0 even when 296few megabytes of \s-1RSS\s0. Xft indeed is responsible for a lot of \s-1RSS\s0 even when
301not used. 297not used.
302.Sp 298.PP
303Of course, due to every character using two or four bytes instead of one, 299Of course, due to every character using two or four bytes instead of one,
304a large scrollback buffer will ultimately make rxvt-unicode use more 300a large scrollback buffer will ultimately make rxvt-unicode use more
305memory. 301memory.
306.Sp 302.PP
307Compared to e.g. Eterm (5112k), aterm (3132k) and xterm (4680k), this 303Compared to e.g. Eterm (5112k), aterm (3132k) and xterm (4680k), this
308still fares rather well. And compared to some monsters like gnome-terminal 304still fares rather well. And compared to some monsters like gnome-terminal
309(21152k + extra 4204k in separate processes) or konsole (22200k + extra 305(21152k + extra 4204k in separate processes) or konsole (22200k + extra
31043180k in daemons that stay around after exit, plus half a minute of 30643180k in daemons that stay around after exit, plus half a minute of
311startup time, including the hundreds of warnings it spits out), it fares 307startup time, including the hundreds of warnings it spits out), it fares
312extremely well *g*. 308extremely well *g*.
309.PP
313.IP "Why \*(C+, isn't that unportable/bloated/uncool?" 4 310\fIWhy \*(C+, isn't that unportable/bloated/uncool?\fR
314.IX Item "Why , isn't that unportable/bloated/uncool?" 311.IX Subsection "Why , isn't that unportable/bloated/uncool?"
312.PP
315Is this a question? :) It comes up very often. The simple answer is: I had 313Is this a question? :) It comes up very often. The simple answer is: I had
316to write it, and \*(C+ allowed me to write and maintain it in a fraction 314to write it, and \*(C+ allowed me to write and maintain it in a fraction
317of the time and effort (which is a scarce resource for me). Put even 315of the time and effort (which is a scarce resource for me). Put even
318shorter: It simply wouldn't exist without \*(C+. 316shorter: It simply wouldn't exist without \*(C+.
319.Sp 317.PP
320My personal stance on this is that \*(C+ is less portable than C, but in 318My personal stance on this is that \*(C+ is less portable than C, but in
321the case of rxvt-unicode this hardly matters, as its portability limits 319the case of rxvt-unicode this hardly matters, as its portability limits
322are defined by things like X11, pseudo terminals, locale support and unix 320are defined by things like X11, pseudo terminals, locale support and unix
323domain sockets, which are all less portable than \*(C+ itself. 321domain sockets, which are all less portable than \*(C+ itself.
324.Sp 322.PP
325Regarding the bloat, see the above question: It's easy to write programs 323Regarding the bloat, see the above question: It's easy to write programs
326in C that use gobs of memory, an certainly possible to write programs in 324in C that use gobs of memory, an certainly possible to write programs in
327\&\*(C+ that don't. \*(C+ also often comes with large libraries, but this is 325\&\*(C+ that don't. \*(C+ also often comes with large libraries, but this is
328not necessarily the case with \s-1GCC\s0. Here is what rxvt links against on my 326not necessarily the case with \s-1GCC\s0. Here is what rxvt links against on my
329system with a minimal config: 327system with a minimal config:
330.Sp 328.PP
331.Vb 4 329.Vb 4
332\& libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x00002aaaaabc3000) 330\& libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x00002aaaaabc3000)
333\& libc.so.6 => /lib/libc.so.6 (0x00002aaaaadde000) 331\& libc.so.6 => /lib/libc.so.6 (0x00002aaaaadde000)
334\& libdl.so.2 => /lib/libdl.so.2 (0x00002aaaab01d000) 332\& libdl.so.2 => /lib/libdl.so.2 (0x00002aaaab01d000)
335\& /lib64/ld-linux-x86-64.so.2 (0x00002aaaaaaab000) 333\& /lib64/ld-linux-x86-64.so.2 (0x00002aaaaaaab000)
336.Ve 334.Ve
337.Sp 335.PP
338And here is rxvt\-unicode: 336And here is rxvt\-unicode:
339.Sp 337.PP
340.Vb 5 338.Vb 5
341\& libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x00002aaaaabc3000) 339\& libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x00002aaaaabc3000)
342\& libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00002aaaaada2000) 340\& libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00002aaaaada2000)
343\& libc.so.6 => /lib/libc.so.6 (0x00002aaaaaeb0000) 341\& libc.so.6 => /lib/libc.so.6 (0x00002aaaaaeb0000)
344\& libdl.so.2 => /lib/libdl.so.2 (0x00002aaaab0ee000) 342\& libdl.so.2 => /lib/libdl.so.2 (0x00002aaaab0ee000)
345\& /lib64/ld-linux-x86-64.so.2 (0x00002aaaaaaab000) 343\& /lib64/ld-linux-x86-64.so.2 (0x00002aaaaaaab000)
346.Ve 344.Ve
347.Sp 345.PP
348No large bloated libraries (of course, none were linked in statically), 346No large bloated libraries (of course, none were linked in statically),
349except maybe libX11 :) 347except maybe libX11 :)
350.IP "Does it support tabs, can I have a tabbed rxvt\-unicode?" 4 348.Sh "Rendering, Font & Look and Feel Issues"
351.IX Item "Does it support tabs, can I have a tabbed rxvt-unicode?" 349.IX Subsection "Rendering, Font & Look and Feel Issues"
352Beginning with version 7.3, there is a perl extension that implements a 350\fII can't get transparency working, what am I doing wrong?\fR
353simple tabbed terminal. It is installed by default, so any of these should 351.IX Subsection "I can't get transparency working, what am I doing wrong?"
354give you tabs: 352.PP
355.Sp 353First of all, transparency isn't officially supported in rxvt\-unicode, so
354you are mostly on your own. Do not bug the author about it (but you may
355bug everybody else). Also, if you can't get it working consider it a rite
356of passage: ... and you failed.
357.PP
358Here are four ways to get transparency. \fBDo\fR read the manpage and option
359descriptions for the programs mentioned and rxvt\-unicode. Really, do it!
360.PP
3611. Use inheritPixmap:
362.PP
363.Vb 2
364\& Esetroot wallpaper.jpg
365\& @@URXVT_NAME@@ -ip -tint red -sh 40
366.Ve
367.PP
368That works. If you think it doesn't, you lack transparency and tinting
369support, or you are unable to read.
370.PP
3712. Use a simple pixmap and emulate pseudo\-transparency. This enables you
372to use effects other than tinting and shading: Just shade/tint/whatever
373your picture with gimp or any other tool:
374.PP
375.Vb 2
376\& convert wallpaper.jpg -blur 20x20 -modulate 30 background.xpm
377\& @@URXVT_NAME@@ -pixmap background.xpm -pe automove-background
378.Ve
379.PP
380That works. If you think it doesn't, you lack \s-1XPM\s0 and Perl support, or you
381are unable to read.
382.PP
3833. Use an \s-1ARGB\s0 visual:
384.PP
356.Vb 1 385.Vb 1
357\& @@RXVT_NAME@@ -pe tabbed 386\& @@URXVT_NAME@@ -depth 32 -fg grey90 -bg rgba:0000/0000/4444/cccc
358.Ve 387.Ve
359.Sp 388.PP
389This requires \s-1XFT\s0 support, and the support of your X\-server. If that
390doesn't work for you, blame Xorg and Keith Packard. \s-1ARGB\s0 visuals aren't
391there yet, no matter what they claim. Rxvt-Unicode contains the neccessary
392bugfixes and workarounds for Xft and Xlib to make it work, but that
393doesn't mean that your \s-1WM\s0 has the required kludges in place.
394.PP
3954. Use xcompmgr and let it do the job:
396.PP
397.Vb 2
398\& xprop -frame -f _NET_WM_WINDOW_OPACITY 32c \e
399\& -set _NET_WM_WINDOW_OPACITY 0xc0000000
400.Ve
401.PP
402Then click on a window you want to make transparent. Replace \f(CW0xc0000000\fR
403by other values to change the degree of opacity. If it doesn't work and
404your server crashes, you got to keep the pieces.
405.PP
406\fIWhy do some chinese characters look so different than others?\fR
407.IX Subsection "Why do some chinese characters look so different than others?"
408.PP
409This is because there is a difference between script and language \*(--
410rxvt-unicode does not know which language the text that is output is,
411as it only knows the unicode character codes. If rxvt-unicode first
412sees a japanese/chinese character, it might choose a japanese font for
413display. Subsequent japanese characters will use that font. Now, many
414chinese characters aren't represented in japanese fonts, so when the first
415non-japanese character comes up, rxvt-unicode will look for a chinese font
416\&\*(-- unfortunately at this point, it will still use the japanese font for
417chinese characters that are also in the japanese font.
418.PP
419The workaround is easy: just tag a chinese font at the end of your font
420list (see the previous question). The key is to view the font list as
421a preference list: If you expect more japanese, list a japanese font
422first. If you expect more chinese, put a chinese font first.
423.PP
424In the future it might be possible to switch language preferences at
425runtime (the internal data structure has no problem with using different
426fonts for the same character at the same time, but no interface for this
427has been designed yet).
428.PP
429Until then, you might get away with switching fonts at runtime (see \*(L"Can I switch the fonts at runtime?\*(R" later in this document).
430.PP
431\fIWhy does rxvt-unicode sometimes leave pixel droppings?\fR
432.IX Subsection "Why does rxvt-unicode sometimes leave pixel droppings?"
433.PP
434Most fonts were not designed for terminal use, which means that character
435size varies a lot. A font that is otherwise fine for terminal use might
436contain some characters that are simply too wide. Rxvt-unicode will avoid
437these characters. For characters that are just \*(L"a bit\*(R" too wide a special
438\&\*(L"careful\*(R" rendering mode is used that redraws adjacent characters.
439.PP
440All of this requires that fonts do not lie about character sizes,
441however: Xft fonts often draw glyphs larger than their acclaimed bounding
442box, and rxvt-unicode has no way of detecting this (the correct way is to
443ask for the character bounding box, which unfortunately is wrong in these
444cases).
445.PP
446It's not clear (to me at least), wether this is a bug in Xft, freetype,
447or the respective font. If you encounter this problem you might try using
448the \f(CW\*(C`\-lsp\*(C'\fR option to give the font more height. If that doesn't work, you
449might be forced to use a different font.
450.PP
451All of this is not a problem when using X11 core fonts, as their bounding
452box data is correct.
453.PP
454\fIHow can I keep rxvt-unicode from using reverse video so much?\fR
455.IX Subsection "How can I keep rxvt-unicode from using reverse video so much?"
456.PP
457First of all, make sure you are running with the right terminal settings
458(\f(CW\*(C`TERM=rxvt\-unicode\*(C'\fR), which will get rid of most of these effects. Then
459make sure you have specified colours for italic and bold, as otherwise
460rxvt-unicode might use reverse video to simulate the effect:
461.PP
462.Vb 2
463\& URxvt.colorBD: white
464\& URxvt.colorIT: green
465.Ve
466.PP
467\fISome programs assume totally weird colours (red instead of blue), how can I fix that?\fR
468.IX Subsection "Some programs assume totally weird colours (red instead of blue), how can I fix that?"
469.PP
470For some unexplainable reason, some rare programs assume a very weird
471colour palette when confronted with a terminal with more than the standard
4728 colours (rxvt\-unicode supports 88). The right fix is, of course, to fix
473these programs not to assume non-ISO colours without very good reasons.
474.PP
475In the meantime, you can either edit your \f(CW\*(C`rxvt\-unicode\*(C'\fR terminfo
476definition to only claim 8 colour support or use \f(CW\*(C`TERM=rxvt\*(C'\fR, which will
477fix colours but keep you from using other rxvt-unicode features.
478.PP
479\fICan I switch the fonts at runtime?\fR
480.IX Subsection "Can I switch the fonts at runtime?"
481.PP
482Yes, using an escape sequence. Try something like this, which has the same
483effect as using the \f(CW\*(C`\-fn\*(C'\fR switch, and takes effect immediately:
484.PP
360.Vb 1 485.Vb 1
486\& printf '\ee]50;%s\e007' "9x15bold,xft:Kochi Gothic"
487.Ve
488.PP
489This is useful if you e.g. work primarily with japanese (and prefer a
490japanese font), but you have to switch to chinese temporarily, where
491japanese fonts would only be in your way.
492.PP
493You can think of this as a kind of manual \s-1ISO\-2022\s0 switching.
494.PP
495\fIWhy do italic characters look as if clipped?\fR
496.IX Subsection "Why do italic characters look as if clipped?"
497.PP
498Many fonts have difficulties with italic characters and hinting. For
499example, the otherwise very nicely hinted font \f(CW\*(C`xft:Bitstream Vera Sans
500Mono\*(C'\fR completely fails in it's italic face. A workaround might be to
501enable freetype autohinting, i.e. like this:
502.PP
503.Vb 2
504\& URxvt.italicFont: xft:Bitstream Vera Sans Mono:italic:autohint=true
505\& URxvt.boldItalicFont: xft:Bitstream Vera Sans Mono:bold:italic:autohint=true
506.Ve
507.PP
508\fICan I speed up Xft rendering somehow?\fR
509.IX Subsection "Can I speed up Xft rendering somehow?"
510.PP
511Yes, the most obvious way to speed it up is to avoid Xft entirely, as
512it is simply slow. If you still want Xft fonts you might try to disable
513antialiasing (by appending \f(CW\*(C`:antialias=false\*(C'\fR), which saves lots of
514memory and also speeds up rendering considerably.
515.PP
516\fIRxvt-unicode doesn't seem to anti-alias its fonts, what is wrong?\fR
517.IX Subsection "Rxvt-unicode doesn't seem to anti-alias its fonts, what is wrong?"
518.PP
519Rxvt-unicode will use whatever you specify as a font. If it needs to
520fall back to it's default font search list it will prefer X11 core
521fonts, because they are small and fast, and then use Xft fonts. It has
522antialiasing disabled for most of them, because the author thinks they
523look best that way.
524.PP
525If you want antialiasing, you have to specify the fonts manually.
526.PP
527\fIWhat's with this bold/blink stuff?\fR
528.IX Subsection "What's with this bold/blink stuff?"
529.PP
530If no bold colour is set via \f(CW\*(C`colorBD:\*(C'\fR, bold will invert text using the
531standard foreground colour.
532.PP
533For the standard background colour, blinking will actually make the
534text blink when compiled with \f(CW\*(C`\-\-enable\-blinking\*(C'\fR. with standard
535colours. Without \f(CW\*(C`\-\-enable\-blinking\*(C'\fR, the blink attribute will be
536ignored.
537.PP
538On \s-1ANSI\s0 colours, bold/blink attributes are used to set high-intensity
539foreground/background colors.
540.PP
541color0\-7 are the low-intensity colors.
542.PP
543color8\-15 are the corresponding high-intensity colors.
544.PP
545\fII don't like the screen colors. How do I change them?\fR
546.IX Subsection "I don't like the screen colors. How do I change them?"
547.PP
548You can change the screen colors at run-time using \fI~/.Xdefaults\fR
549resources (or as long\-options).
550.PP
551Here are values that are supposed to resemble a \s-1VGA\s0 screen,
552including the murky brown that passes for low-intensity yellow:
553.PP
554.Vb 8
555\& URxvt.color0: #000000
556\& URxvt.color1: #A80000
557\& URxvt.color2: #00A800
558\& URxvt.color3: #A8A800
559\& URxvt.color4: #0000A8
560\& URxvt.color5: #A800A8
561\& URxvt.color6: #00A8A8
562\& URxvt.color7: #A8A8A8
563.Ve
564.PP
565.Vb 8
566\& URxvt.color8: #000054
567\& URxvt.color9: #FF0054
568\& URxvt.color10: #00FF54
569\& URxvt.color11: #FFFF54
570\& URxvt.color12: #0000FF
571\& URxvt.color13: #FF00FF
572\& URxvt.color14: #00FFFF
573\& URxvt.color15: #FFFFFF
574.Ve
575.PP
576And here is a more complete set of non-standard colors described (not by
577me) as \*(L"pretty girly\*(R".
578.PP
579.Vb 18
580\& URxvt.cursorColor: #dc74d1
581\& URxvt.pointerColor: #dc74d1
582\& URxvt.background: #0e0e0e
583\& URxvt.foreground: #4ad5e1
584\& URxvt.color0: #000000
585\& URxvt.color8: #8b8f93
586\& URxvt.color1: #dc74d1
587\& URxvt.color9: #dc74d1
588\& URxvt.color2: #0eb8c7
589\& URxvt.color10: #0eb8c7
590\& URxvt.color3: #dfe37e
591\& URxvt.color11: #dfe37e
592\& URxvt.color5: #9e88f0
593\& URxvt.color13: #9e88f0
594\& URxvt.color6: #73f7ff
595\& URxvt.color14: #73f7ff
596\& URxvt.color7: #e1dddd
597\& URxvt.color15: #e1dddd
598.Ve
599.PP
600\fIWhy do some characters look so much different than others?\fR
601.IX Subsection "Why do some characters look so much different than others?"
602.PP
603See next entry.
604.PP
605\fIHow does rxvt-unicode choose fonts?\fR
606.IX Subsection "How does rxvt-unicode choose fonts?"
607.PP
608Most fonts do not contain the full range of Unicode, which is
609fine. Chances are that the font you (or the admin/package maintainer of
610your system/os) have specified does not cover all the characters you want
611to display.
612.PP
613\&\fBrxvt-unicode\fR makes a best-effort try at finding a replacement
614font. Often the result is fine, but sometimes the chosen font looks
615bad/ugly/wrong. Some fonts have totally strange characters that don't
616resemble the correct glyph at all, and rxvt-unicode lacks the artificial
617intelligence to detect that a specific glyph is wrong: it has to believe
618the font that the characters it claims to contain indeed look correct.
619.PP
620In that case, select a font of your taste and add it to the font list,
621e.g.:
622.PP
623.Vb 1
624\& @@URXVT_NAME@@ -fn basefont,font2,font3...
625.Ve
626.PP
627When rxvt-unicode sees a character, it will first look at the base
628font. If the base font does not contain the character, it will go to the
629next font, and so on. Specifying your own fonts will also speed up this
630search and use less resources within rxvt-unicode and the X\-server.
631.PP
632The only limitation is that none of the fonts may be larger than the base
633font, as the base font defines the terminal character cell size, which
634must be the same due to the way terminals work.
635.Sh "Keyboard, Mouse & User Interaction"
636.IX Subsection "Keyboard, Mouse & User Interaction"
637\fIThe new selection selects pieces that are too big, how can I select single words?\fR
638.IX Subsection "The new selection selects pieces that are too big, how can I select single words?"
639.PP
640If you want to select e.g. alphanumeric words, you can use the following
641setting:
642.PP
643.Vb 1
644\& URxvt.selection.pattern-0: ([[:word:]]+)
645.Ve
646.PP
647If you click more than twice, the selection will be extended
648more and more.
649.PP
650To get a selection that is very similar to the old code, try this pattern:
651.PP
652.Vb 1
653\& URxvt.selection.pattern-0: ([^"&'()*,;<=>?@[\e\e\e\e]^`{|})]+)
654.Ve
655.PP
656Please also note that the \fILeftClick Shift-LeftClik\fR combination also
657selects words like the old code.
658.PP
659\fII don't like the new selection/popups/hotkeys/perl, how do I change/disable it?\fR
660.IX Subsection "I don't like the new selection/popups/hotkeys/perl, how do I change/disable it?"
661.PP
662You can disable the perl extension completely by setting the
663\&\fBperl-ext-common\fR resource to the empty string, which also keeps
664rxvt-unicode from initialising perl, saving memory.
665.PP
666If you only want to disable specific features, you first have to
667identify which perl extension is responsible. For this, read the section
668\&\fB\s-1PREPACKAGED\s0 \s-1EXTENSIONS\s0\fR in the @@URXVT_NAME@@\fIperl\fR\|(3) manpage. For
669example, to disable the \fBselection-popup\fR and \fBoption-popup\fR, specify
670this \fBperl-ext-common\fR resource:
671.PP
672.Vb 1
673\& URxvt.perl-ext-common: default,-selection-popup,-option-popup
674.Ve
675.PP
676This will keep the default extensions, but disable the two popup
677extensions. Some extensions can also be configured, for example,
678scrollback search mode is triggered by \fBM\-s\fR. You can move it to any
679other combination either by setting the \fBsearchable-scrollback\fR resource:
680.PP
681.Vb 1
682\& URxvt.searchable-scrollback: CM-s
683.Ve
684.PP
685\fIThe cursor moves when selecting text in the current input line, how do I switch this off?\fR
686.IX Subsection "The cursor moves when selecting text in the current input line, how do I switch this off?"
687.PP
688See next entry.
689.PP
690\fIDuring rlogin/ssh/telnet/etc. sessions, clicking near the cursor outputs strange escape sequences, how do I fix this?\fR
691.IX Subsection "During rlogin/ssh/telnet/etc. sessions, clicking near the cursor outputs strange escape sequences, how do I fix this?"
692.PP
693These are caused by the \f(CW\*(C`readline\*(C'\fR perl extension. Under normal
694circumstances, it will move your cursor around when you click into the
695line that contains it. It tries hard not to do this at the wrong moment,
696but when running a program that doesn't parse cursor movements or in some
697cases during rlogin sessions, it fails to detect this properly.
698.PP
699You can permamently switch this feature off by disabling the \f(CW\*(C`readline\*(C'\fR
700extension:
701.PP
702.Vb 1
361\& URxvt.perl-ext-common: default,tabbed 703\& URxvt.perl-ext-common: default,-readline
362.Ve 704.Ve
363.Sp 705.PP
364It will also work fine with tabbing functionality of many window managers 706\fIMy numerical keypad acts weird and generates differing output?\fR
365or similar tabbing programs, and its embedding-features allow it to be 707.IX Subsection "My numerical keypad acts weird and generates differing output?"
366embedded into other programs, as witnessed by \fIdoc/rxvt\-tabbed\fR or 708.PP
367the upcoming \f(CW\*(C`Gtk2::URxvt\*(C'\fR perl module, which features a tabbed urxvt 709Some Debian GNUL/Linux users seem to have this problem, although no
368(murxvt) terminal as an example embedding application. 710specific details were reported so far. It is possible that this is caused
369.IP "How do I know which rxvt-unicode version I'm using?" 4 711by the wrong \f(CW\*(C`TERM\*(C'\fR setting, although the details of wether and how
370.IX Item "How do I know which rxvt-unicode version I'm using?" 712this can happen are unknown, as \f(CW\*(C`TERM=rxvt\*(C'\fR should offer a compatible
371The version number is displayed with the usage (\-h). Also the escape 713keymap. See the answer to the previous question, and please report if that
372sequence \f(CW\*(C`ESC [ 8 n\*(C'\fR sets the window title to the version number. When 714helped.
373using the @@RXVT_NAME@@c client, the version displayed is that of the 715.PP
374daemon. 716\fIMy Compose (Multi_key) key is no longer working.\fR
375.IP "I am using Debian GNU/Linux and have a problem..." 4 717.IX Subsection "My Compose (Multi_key) key is no longer working."
376.IX Item "I am using Debian GNU/Linux and have a problem..." 718.PP
377The Debian GNU/Linux package of rxvt-unicode in sarge contains large 719The most common causes for this are that either your locale is not set
378patches that considerably change the behaviour of rxvt-unicode (but 720correctly, or you specified a \fBpreeditStyle\fR that is not supported by
379unfortunately this notice has been removed). Before reporting a bug to 721your input method. For example, if you specified \fBOverTheSpot\fR and
380the original rxvt-unicode author please download and install the genuine 722your input method (e.g. the default input method handling Compose keys)
381version (<http://software.schmorp.de#rxvt\-unicode>) and try to reproduce 723does not support this (for instance because it is not visual), then
382the problem. If you cannot, chances are that the problems are specific to 724rxvt-unicode will continue without an input method.
383Debian GNU/Linux, in which case it should be reported via the Debian Bug 725.PP
384Tracking System (use \f(CW\*(C`reportbug\*(C'\fR to report the bug). 726In this case either do not specify a \fBpreeditStyle\fR or specify more than
385.Sp 727one pre-edit style, such as \fBOverTheSpot,Root,None\fR.
386For other problems that also affect the Debian package, you can and 728.PP
387probably should use the Debian \s-1BTS\s0, too, because, after all, it's also a 729\fII cannot type \f(CI\*(C`Ctrl\-Shift\-2\*(C'\fI to get an \s-1ASCII\s0 \s-1NUL\s0 character due to \s-1ISO\s0 14755\fR
388bug in the Debian version and it serves as a reminder for other users that 730.IX Subsection "I cannot type Ctrl-Shift-2 to get an ASCII NUL character due to ISO 14755"
389might encounter the same issue. 731.PP
390.IP "I am maintaining rxvt-unicode for distribution/OS \s-1XXX\s0, any recommendation?" 4 732Either try \f(CW\*(C`Ctrl\-2\*(C'\fR alone (it often is mapped to \s-1ASCII\s0 \s-1NUL\s0 even on
391.IX Item "I am maintaining rxvt-unicode for distribution/OS XXX, any recommendation?" 733international keyboards) or simply use \s-1ISO\s0 14755 support to your
392You should build one binary with the default options. \fIconfigure\fR 734advantage, typing <Ctrl\-Shift\-0> to get a \s-1ASCII\s0 \s-1NUL\s0. This works for other
393now enables most useful options, and the trend goes to making them 735codes, too, such as \f(CW\*(C`Ctrl\-Shift\-1\-d\*(C'\fR to type the default telnet escape
394runtime\-switchable, too, so there is usually no drawback to enbaling them, 736character and so on.
395except higher disk and possibly memory usage. The perl interpreter should 737.PP
396be enabled, as important functionality (menus, selection, likely more in 738\fIMouse cut/paste suddenly no longer works.\fR
397the future) depends on it. 739.IX Subsection "Mouse cut/paste suddenly no longer works."
398.Sp 740.PP
399You should not overwrite the \f(CW\*(C`perl\-ext\-common\*(C'\fR snd \f(CW\*(C`perl\-ext\*(C'\fR resources 741Make sure that mouse reporting is actually turned off since killing
400system-wide (except maybe with \f(CW\*(C`defaults\*(C'\fR). This will result in useful 742some editors prematurely may leave the mouse in mouse report mode. I've
401behaviour. If your distribution aims at low memory, add an empty 743heard that tcsh may use mouse reporting unless it otherwise specified. A
402\&\f(CW\*(C`perl\-ext\-common\*(C'\fR resource to the app-defaults file. This will keep the 744quick check is to see if cut/paste works when the Alt or Shift keys are
403perl interpreter disabled until the user enables it. 745depressed.
404.Sp 746.PP
405If you can/want build more binaries, I recommend building a minimal 747\fIWhat's with the strange Backspace/Delete key behaviour?\fR
406one with \f(CW\*(C`\-\-disable\-everything\*(C'\fR (very useful) and a maximal one with 748.IX Subsection "What's with the strange Backspace/Delete key behaviour?"
407\&\f(CW\*(C`\-\-enable\-everything\*(C'\fR (less useful, it will be very big due to a lot of 749.PP
408encodings built-in that increase download times and are rarely used). 750Assuming that the physical Backspace key corresponds to the
409.IP "I need to make it setuid/setgid to support utmp/ptys on my \s-1OS\s0, is this safe?" 4 751BackSpace keysym (not likely for Linux ... see the following
410.IX Item "I need to make it setuid/setgid to support utmp/ptys on my OS, is this safe?" 752question) there are two standard values that can be used for
411It should be, starting with release 7.1. You are encouraged to properly 753Backspace: \f(CW\*(C`^H\*(C'\fR and \f(CW\*(C`^?\*(C'\fR.
412install urxvt with privileges necessary for your \s-1OS\s0 now. 754.PP
413.Sp 755Historically, either value is correct, but rxvt-unicode adopts the debian
414When rxvt-unicode detects that it runs setuid or setgid, it will fork 756policy of using \f(CW\*(C`^?\*(C'\fR when unsure, because it's the one only only correct
415into a helper process for privileged operations (pty handling on some 757choice :).
416systems, utmp/wtmp/lastlog handling on others) and drop privileges 758.PP
417immediately. This is much safer than most other terminals that keep 759Rxvt-unicode tries to inherit the current stty settings and uses the value
418privileges while running (but is more relevant to urxvt, as it contains 760of `erase' to guess the value for backspace. If rxvt-unicode wasn't
419things as perl interpreters, which might be \*(L"helpful\*(R" to attackers). 761started from a terminal (say, from a menu or by remote shell), then the
420.Sp 762system value of `erase', which corresponds to \s-1CERASE\s0 in <termios.h>, will
421This forking is done as the very first within \fImain()\fR, which is very early 763be used (which may not be the same as your stty setting).
422and reduces possible bugs to initialisation code run before \fImain()\fR, or 764.PP
423things like the dynamic loader of your system, which should result in very 765For starting a new rxvt\-unicode:
424little risk. 766.PP
767.Vb 3
768\& # use Backspace = ^H
769\& $ stty erase ^H
770\& $ @@URXVT_NAME@@
771.Ve
772.PP
773.Vb 3
774\& # use Backspace = ^?
775\& $ stty erase ^?
776\& $ @@URXVT_NAME@@
777.Ve
778.PP
779Toggle with \f(CW\*(C`ESC [ 36 h\*(C'\fR / \f(CW\*(C`ESC [ 36 l\*(C'\fR.
780.PP
781For an existing rxvt\-unicode:
782.PP
783.Vb 3
784\& # use Backspace = ^H
785\& $ stty erase ^H
786\& $ echo -n "^[[36h"
787.Ve
788.PP
789.Vb 3
790\& # use Backspace = ^?
791\& $ stty erase ^?
792\& $ echo -n "^[[36l"
793.Ve
794.PP
795This helps satisfy some of the Backspace discrepancies that occur, but
796if you use Backspace = \f(CW\*(C`^H\*(C'\fR, make sure that the termcap/terminfo value
797properly reflects that.
798.PP
799The Delete key is a another casualty of the ill-defined Backspace problem.
800To avoid confusion between the Backspace and Delete keys, the Delete
801key has been assigned an escape sequence to match the vt100 for Execute
802(\f(CW\*(C`ESC [ 3 ~\*(C'\fR) and is in the supplied termcap/terminfo.
803.PP
804Some other Backspace problems:
805.PP
806some editors use termcap/terminfo,
807some editors (vim I'm told) expect Backspace = ^H,
808\&\s-1GNU\s0 Emacs (and Emacs-like editors) use ^H for help.
809.PP
810Perhaps someday this will all be resolved in a consistent manner.
811.PP
812\fII don't like the key\-bindings. How do I change them?\fR
813.IX Subsection "I don't like the key-bindings. How do I change them?"
814.PP
815There are some compile-time selections available via configure. Unless
816you have run \*(L"configure\*(R" with the \f(CW\*(C`\-\-disable\-resources\*(C'\fR option you can
817use the `keysym' resource to alter the keystrings associated with keysyms.
818.PP
819Here's an example for a URxvt session started using \f(CW\*(C`@@URXVT_NAME@@ \-name URxvt\*(C'\fR
820.PP
821.Vb 20
822\& URxvt.keysym.Home: \e033[1~
823\& URxvt.keysym.End: \e033[4~
824\& URxvt.keysym.C-apostrophe: \e033<C-'>
825\& URxvt.keysym.C-slash: \e033<C-/>
826\& URxvt.keysym.C-semicolon: \e033<C-;>
827\& URxvt.keysym.C-grave: \e033<C-`>
828\& URxvt.keysym.C-comma: \e033<C-,>
829\& URxvt.keysym.C-period: \e033<C-.>
830\& URxvt.keysym.C-0x60: \e033<C-`>
831\& URxvt.keysym.C-Tab: \e033<C-Tab>
832\& URxvt.keysym.C-Return: \e033<C-Return>
833\& URxvt.keysym.S-Return: \e033<S-Return>
834\& URxvt.keysym.S-space: \e033<S-Space>
835\& URxvt.keysym.M-Up: \e033<M-Up>
836\& URxvt.keysym.M-Down: \e033<M-Down>
837\& URxvt.keysym.M-Left: \e033<M-Left>
838\& URxvt.keysym.M-Right: \e033<M-Right>
839\& URxvt.keysym.M-C-0: list \e033<M-C- 0123456789 >
840\& URxvt.keysym.M-C-a: list \e033<M-C- abcdefghijklmnopqrstuvwxyz >
841\& URxvt.keysym.F12: command:\e033]701;zh_CN.GBK\e007
842.Ve
843.PP
844See some more examples in the documentation for the \fBkeysym\fR resource.
845.PP
846\fII'm using keyboard model \s-1XXX\s0 that has extra Prior/Next/Insert keys. How do I make use of them? For example, the Sun Keyboard type 4 has the following map\fR
847.IX Subsection "I'm using keyboard model XXX that has extra Prior/Next/Insert keys. How do I make use of them? For example, the Sun Keyboard type 4 has the following map"
848.PP
849.Vb 6
850\& KP_Insert == Insert
851\& F22 == Print
852\& F27 == Home
853\& F29 == Prior
854\& F33 == End
855\& F35 == Next
856.Ve
857.PP
858Rather than have rxvt-unicode try to accommodate all the various possible
859keyboard mappings, it is better to use `xmodmap' to remap the keys as
860required for your particular machine.
861.Sh "Terminal Configuration"
862.IX Subsection "Terminal Configuration"
863\fIWhy doesn't rxvt-unicode read my resources?\fR
864.IX Subsection "Why doesn't rxvt-unicode read my resources?"
865.PP
866Well, why, indeed? It does, in a way very similar to other X
867applications. Most importantly, this means that if you or your \s-1OS\s0 loads
868resources into the X display (the right way to do it), rxvt-unicode will
869ignore any resource files in your home directory. It will only read
870\&\fI$HOME/.Xdefaults\fR when no resources are attached to the display.
871.PP
872If you have or use an \fI$HOME/.Xresources\fR file, chances are that
873resources are loaded into your X\-server. In this case, you have to
874re-login after every change (or run \fIxrdb \-merge \f(CI$HOME\fI/.Xresources\fR).
875.PP
876Also consider the form resources have to use:
877.PP
878.Vb 1
879\& URxvt.resource: value
880.Ve
881.PP
882If you want to use another form (there are lots of different ways of
883specifying resources), make sure you understand wether and why it
884works. If unsure, use the form above.
885.PP
425.IP "When I log-in to another system it tells me about missing terminfo data?" 4 886\fIWhen I log-in to another system it tells me about missing terminfo data?\fR
426.IX Item "When I log-in to another system it tells me about missing terminfo data?" 887.IX Subsection "When I log-in to another system it tells me about missing terminfo data?"
888.PP
427The terminal description used by rxvt-unicode is not as widely available 889The terminal description used by rxvt-unicode is not as widely available
428as that for xterm, or even rxvt (for which the same problem often arises). 890as that for xterm, or even rxvt (for which the same problem often arises).
429.Sp 891.PP
430The correct solution for this problem is to install the terminfo, this can 892The correct solution for this problem is to install the terminfo, this can
431be done like this (with ncurses' infocmp): 893be done like this (with ncurses' infocmp):
432.Sp 894.PP
433.Vb 2 895.Vb 2
434\& REMOTE=remotesystem.domain 896\& REMOTE=remotesystem.domain
435\& infocmp rxvt-unicode | ssh $REMOTE "cat >/tmp/ti && tic /tmp/ti" 897\& infocmp rxvt-unicode | ssh $REMOTE "cat >/tmp/ti && tic /tmp/ti"
436.Ve 898.Ve
437.Sp 899.PP
438\&... or by installing rxvt-unicode normally on the remote system, 900\&... or by installing rxvt-unicode normally on the remote system,
439.Sp 901.PP
440If you cannot or do not want to do this, then you can simply set 902If you cannot or do not want to do this, then you can simply set
441\&\f(CW\*(C`TERM=rxvt\*(C'\fR or even \f(CW\*(C`TERM=xterm\*(C'\fR, and live with the small number of 903\&\f(CW\*(C`TERM=rxvt\*(C'\fR or even \f(CW\*(C`TERM=xterm\*(C'\fR, and live with the small number of
442problems arising, which includes wrong keymapping, less and different 904problems arising, which includes wrong keymapping, less and different
443colours and some refresh errors in fullscreen applications. It's a nice 905colours and some refresh errors in fullscreen applications. It's a nice
444quick-and-dirty workaround for rare cases, though. 906quick-and-dirty workaround for rare cases, though.
445.Sp 907.PP
446If you always want to do this (and are fine with the consequences) you 908If you always want to do this (and are fine with the consequences) you
447can either recompile rxvt-unicode with the desired \s-1TERM\s0 value or use a 909can either recompile rxvt-unicode with the desired \s-1TERM\s0 value or use a
448resource to set it: 910resource to set it:
449.Sp 911.PP
450.Vb 1 912.Vb 1
451\& URxvt.termName: rxvt 913\& URxvt.termName: rxvt
452.Ve 914.Ve
453.Sp 915.PP
454If you don't plan to use \fBrxvt\fR (quite common...) you could also replace 916If you don't plan to use \fBrxvt\fR (quite common...) you could also replace
455the rxvt terminfo file with the rxvt-unicode one. 917the rxvt terminfo file with the rxvt-unicode one.
456.ie n .IP """tic"" outputs some error when compiling the terminfo entry." 4 918.PP
457.el .IP "\f(CWtic\fR outputs some error when compiling the terminfo entry." 4 919\fI\f(CI\*(C`tic\*(C'\fI outputs some error when compiling the terminfo entry.\fR
458.IX Item "tic outputs some error when compiling the terminfo entry." 920.IX Subsection "tic outputs some error when compiling the terminfo entry."
921.PP
459Most likely it's the empty definition for \f(CW\*(C`enacs=\*(C'\fR. Just replace it by 922Most likely it's the empty definition for \f(CW\*(C`enacs=\*(C'\fR. Just replace it by
460\&\f(CW\*(C`enacs=\eE[0@\*(C'\fR and try again. 923\&\f(CW\*(C`enacs=\eE[0@\*(C'\fR and try again.
461.ie n .IP """bash""'s readline does not work correctly under @@RXVT_NAME@@." 4 924.PP
462.el .IP "\f(CWbash\fR's readline does not work correctly under @@RXVT_NAME@@." 4 925\fI\f(CI\*(C`bash\*(C'\fI's readline does not work correctly under @@URXVT_NAME@@.\fR
463.IX Item "bash's readline does not work correctly under @@RXVT_NAME@@." 926.IX Subsection "bash's readline does not work correctly under @@URXVT_NAME@@."
464.PD 0 927.PP
928See next entry.
929.PP
465.IP "I need a termcap file entry." 4 930\fII need a termcap file entry.\fR
466.IX Item "I need a termcap file entry." 931.IX Subsection "I need a termcap file entry."
467.PD 932.PP
468One reason you might want this is that some distributions or operating 933One reason you might want this is that some distributions or operating
469systems still compile some programs using the long-obsoleted termcap 934systems still compile some programs using the long-obsoleted termcap
470library (Fedora Core's bash is one example) and rely on a termcap entry 935library (Fedora Core's bash is one example) and rely on a termcap entry
471for \f(CW\*(C`rxvt\-unicode\*(C'\fR. 936for \f(CW\*(C`rxvt\-unicode\*(C'\fR.
472.Sp 937.PP
473You could use rxvt's termcap entry with resonable results in many cases. 938You could use rxvt's termcap entry with resonable results in many cases.
474You can also create a termcap entry by using terminfo's infocmp program 939You can also create a termcap entry by using terminfo's infocmp program
475like this: 940like this:
476.Sp 941.PP
477.Vb 1 942.Vb 1
478\& infocmp -C rxvt-unicode 943\& infocmp -C rxvt-unicode
479.Ve 944.Ve
480.Sp 945.PP
481Or you could use this termcap entry, generated by the command above: 946Or you could use this termcap entry, generated by the command above:
482.Sp 947.PP
483.Vb 20 948.Vb 20
484\& rxvt-unicode|rxvt-unicode terminal (X Window System):\e 949\& rxvt-unicode|rxvt-unicode terminal (X Window System):\e
485\& :am:bw:eo:km:mi:ms:xn:xo:\e 950\& :am:bw:eo:km:mi:ms:xn:xo:\e
486\& :co#80:it#8:li#24:lm#0:\e 951\& :co#80:it#8:li#24:lm#0:\e
487\& :AL=\eE[%dL:DC=\eE[%dP:DL=\eE[%dM:DO=\eE[%dB:IC=\eE[%d@:\e 952\& :AL=\eE[%dL:DC=\eE[%dP:DL=\eE[%dM:DO=\eE[%dB:IC=\eE[%d@:\e
500\& :sc=\eE7:se=\eE[27m:sf=^J:so=\eE[7m:sr=\eEM:st=\eEH:ta=^I:\e 965\& :sc=\eE7:se=\eE[27m:sf=^J:so=\eE[7m:sr=\eEM:st=\eEH:ta=^I:\e
501\& :te=\eE[r\eE[?1049l:ti=\eE[?1049h:ue=\eE[24m:up=\eE[A:\e 966\& :te=\eE[r\eE[?1049l:ti=\eE[?1049h:ue=\eE[24m:up=\eE[A:\e
502\& :us=\eE[4m:vb=\eE[?5h\eE[?5l:ve=\eE[?25h:vi=\eE[?25l:\e 967\& :us=\eE[4m:vb=\eE[?5h\eE[?5l:ve=\eE[?25h:vi=\eE[?25l:\e
503\& :vs=\eE[?25h: 968\& :vs=\eE[?25h:
504.Ve 969.Ve
505.ie n .IP "Why does ""ls"" no longer have coloured output?" 4 970.PP
506.el .IP "Why does \f(CWls\fR no longer have coloured output?" 4 971\fIWhy does \f(CI\*(C`ls\*(C'\fI no longer have coloured output?\fR
507.IX Item "Why does ls no longer have coloured output?" 972.IX Subsection "Why does ls no longer have coloured output?"
973.PP
508The \f(CW\*(C`ls\*(C'\fR in the \s-1GNU\s0 coreutils unfortunately doesn't use terminfo to 974The \f(CW\*(C`ls\*(C'\fR in the \s-1GNU\s0 coreutils unfortunately doesn't use terminfo to
509decide wether a terminal has colour, but uses it's own configuration 975decide wether a terminal has colour, but uses it's own configuration
510file. Needless to say, \f(CW\*(C`rxvt\-unicode\*(C'\fR is not in it's default file (among 976file. Needless to say, \f(CW\*(C`rxvt\-unicode\*(C'\fR is not in it's default file (among
511with most other terminals supporting colour). Either add: 977with most other terminals supporting colour). Either add:
512.Sp 978.PP
513.Vb 1 979.Vb 1
514\& TERM rxvt-unicode 980\& TERM rxvt-unicode
515.Ve 981.Ve
516.Sp 982.PP
517to \f(CW\*(C`/etc/DIR_COLORS\*(C'\fR or simply add: 983to \f(CW\*(C`/etc/DIR_COLORS\*(C'\fR or simply add:
518.Sp 984.PP
519.Vb 1 985.Vb 1
520\& alias ls='ls --color=auto' 986\& alias ls='ls --color=auto'
521.Ve 987.Ve
522.Sp 988.PP
523to your \f(CW\*(C`.profile\*(C'\fR or \f(CW\*(C`.bashrc\*(C'\fR. 989to your \f(CW\*(C`.profile\*(C'\fR or \f(CW\*(C`.bashrc\*(C'\fR.
990.PP
524.IP "Why doesn't vim/emacs etc. use the 88 colour mode?" 4 991\fIWhy doesn't vim/emacs etc. use the 88 colour mode?\fR
525.IX Item "Why doesn't vim/emacs etc. use the 88 colour mode?" 992.IX Subsection "Why doesn't vim/emacs etc. use the 88 colour mode?"
526.PD 0 993.PP
994See next entry.
995.PP
527.IP "Why doesn't vim/emacs etc. make use of italic?" 4 996\fIWhy doesn't vim/emacs etc. make use of italic?\fR
528.IX Item "Why doesn't vim/emacs etc. make use of italic?" 997.IX Subsection "Why doesn't vim/emacs etc. make use of italic?"
998.PP
999See next entry.
1000.PP
529.IP "Why are the secondary screen-related options not working properly?" 4 1001\fIWhy are the secondary screen-related options not working properly?\fR
530.IX Item "Why are the secondary screen-related options not working properly?" 1002.IX Subsection "Why are the secondary screen-related options not working properly?"
531.PD 1003.PP
532Make sure you are using \f(CW\*(C`TERM=rxvt\-unicode\*(C'\fR. Some pre-packaged 1004Make sure you are using \f(CW\*(C`TERM=rxvt\-unicode\*(C'\fR. Some pre-packaged
533distributions (most notably Debian GNU/Linux) break rxvt-unicode 1005distributions (most notably Debian GNU/Linux) break rxvt-unicode
534by setting \f(CW\*(C`TERM\*(C'\fR to \f(CW\*(C`rxvt\*(C'\fR, which doesn't have these extra 1006by setting \f(CW\*(C`TERM\*(C'\fR to \f(CW\*(C`rxvt\*(C'\fR, which doesn't have these extra
535features. Unfortunately, some of these (most notably, again, Debian 1007features. Unfortunately, some of these (most notably, again, Debian
536GNU/Linux) furthermore fail to even install the \f(CW\*(C`rxvt\-unicode\*(C'\fR terminfo 1008GNU/Linux) furthermore fail to even install the \f(CW\*(C`rxvt\-unicode\*(C'\fR terminfo
537file, so you will need to install it on your own (See the question \fBWhen 1009file, so you will need to install it on your own (See the question \fBWhen
538I log-in to another system it tells me about missing terminfo data?\fR on 1010I log-in to another system it tells me about missing terminfo data?\fR on
539how to do this). 1011how to do this).
540.IP "My numerical keypad acts weird and generates differing output?" 4 1012.Sh "Encoding / Locale / Input Method Issues"
541.IX Item "My numerical keypad acts weird and generates differing output?" 1013.IX Subsection "Encoding / Locale / Input Method Issues"
542Some Debian GNUL/Linux users seem to have this problem, although no
543specific details were reported so far. It is possible that this is caused
544by the wrong \f(CW\*(C`TERM\*(C'\fR setting, although the details of wether and how
545this can happen are unknown, as \f(CW\*(C`TERM=rxvt\*(C'\fR should offer a compatible
546keymap. See the answer to the previous question, and please report if that
547helped.
548.IP "Rxvt-unicode does not seem to understand the selected encoding?" 4 1014\fIRxvt-unicode does not seem to understand the selected encoding?\fR
549.IX Item "Rxvt-unicode does not seem to understand the selected encoding?" 1015.IX Subsection "Rxvt-unicode does not seem to understand the selected encoding?"
550.PD 0 1016.PP
1017See next entry.
1018.PP
551.IP "Unicode does not seem to work?" 4 1019\fIUnicode does not seem to work?\fR
552.IX Item "Unicode does not seem to work?" 1020.IX Subsection "Unicode does not seem to work?"
553.PD 1021.PP
554If you encounter strange problems like typing an accented character but 1022If you encounter strange problems like typing an accented character but
555getting two unrelated other characters or similar, or if program output is 1023getting two unrelated other characters or similar, or if program output is
556subtly garbled, then you should check your locale settings. 1024subtly garbled, then you should check your locale settings.
557.Sp 1025.PP
558Rxvt-unicode must be started with the same \f(CW\*(C`LC_CTYPE\*(C'\fR setting as the 1026Rxvt-unicode must be started with the same \f(CW\*(C`LC_CTYPE\*(C'\fR setting as the
559programs. Often rxvt-unicode is started in the \f(CW\*(C`C\*(C'\fR locale, while the 1027programs. Often rxvt-unicode is started in the \f(CW\*(C`C\*(C'\fR locale, while the
560login script running within the rxvt-unicode window changes the locale to 1028login script running within the rxvt-unicode window changes the locale to
561something else, e.g. \f(CW\*(C`en_GB.UTF\-8\*(C'\fR. Needless to say, this is not going to work. 1029something else, e.g. \f(CW\*(C`en_GB.UTF\-8\*(C'\fR. Needless to say, this is not going to work.
562.Sp 1030.PP
563The best thing is to fix your startup environment, as you will likely run 1031The best thing is to fix your startup environment, as you will likely run
564into other problems. If nothing works you can try this in your .profile. 1032into other problems. If nothing works you can try this in your .profile.
565.Sp 1033.PP
566.Vb 1 1034.Vb 1
567\& printf '\ee]701;%s\e007' "$LC_CTYPE" 1035\& printf '\ee]701;%s\e007' "$LC_CTYPE"
568.Ve 1036.Ve
569.Sp 1037.PP
570If this doesn't work, then maybe you use a \f(CW\*(C`LC_CTYPE\*(C'\fR specification not 1038If this doesn't work, then maybe you use a \f(CW\*(C`LC_CTYPE\*(C'\fR specification not
571supported on your systems. Some systems have a \f(CW\*(C`locale\*(C'\fR command which 1039supported on your systems. Some systems have a \f(CW\*(C`locale\*(C'\fR command which
572displays this (also, \f(CW\*(C`perl \-e0\*(C'\fR can be used to check locale settings, as 1040displays this (also, \f(CW\*(C`perl \-e0\*(C'\fR can be used to check locale settings, as
573it will complain loudly if it cannot set the locale). If it displays something 1041it will complain loudly if it cannot set the locale). If it displays something
574like: 1042like:
575.Sp 1043.PP
576.Vb 1 1044.Vb 1
577\& locale: Cannot set LC_CTYPE to default locale: ... 1045\& locale: Cannot set LC_CTYPE to default locale: ...
578.Ve 1046.Ve
579.Sp 1047.PP
580Then the locale you specified is not supported on your system. 1048Then the locale you specified is not supported on your system.
581.Sp 1049.PP
582If nothing works and you are sure that everything is set correctly then 1050If nothing works and you are sure that everything is set correctly then
583you will need to remember a little known fact: Some programs just don't 1051you will need to remember a little known fact: Some programs just don't
584support locales :( 1052support locales :(
585.IP "Why do some characters look so much different than others?" 4 1053.PP
586.IX Item "Why do some characters look so much different than others?" 1054\fIHow does rxvt-unicode determine the encoding to use?\fR
587.PD 0 1055.IX Subsection "How does rxvt-unicode determine the encoding to use?"
588.IP "How does rxvt-unicode choose fonts?" 4 1056.PP
589.IX Item "How does rxvt-unicode choose fonts?" 1057See next entry.
590.PD 1058.PP
591Most fonts do not contain the full range of Unicode, which is 1059\fIIs there an option to switch encodings?\fR
592fine. Chances are that the font you (or the admin/package maintainer of 1060.IX Subsection "Is there an option to switch encodings?"
593your system/os) have specified does not cover all the characters you want 1061.PP
594to display. 1062Unlike some other terminals, rxvt-unicode has no encoding switch, and no
595.Sp 1063specific \*(L"utf\-8\*(R" mode, such as xterm. In fact, it doesn't even know about
596\&\fBrxvt-unicode\fR makes a best-effort try at finding a replacement 1064\&\s-1UTF\-8\s0 or any other encodings with respect to terminal I/O.
597font. Often the result is fine, but sometimes the chosen font looks 1065.PP
598bad/ugly/wrong. Some fonts have totally strange characters that don't 1066The reasons is that there exists a perfectly fine mechanism for selecting
599resemble the correct glyph at all, and rxvt-unicode lacks the artificial 1067the encoding, doing I/O and (most important) communicating this to all
600intelligence to detect that a specific glyph is wrong: it has to believe 1068applications so everybody agrees on character properties such as width
601the font that the characters it claims to contain indeed look correct. 1069and code number. This mechanism is the \fIlocale\fR. Applications not using
602.Sp 1070that info will have problems (for example, \f(CW\*(C`xterm\*(C'\fR gets the width of
603In that case, select a font of your taste and add it to the font list, 1071characters wrong as it uses it's own, locale-independent table under all
604e.g.: 1072locales).
605.Sp 1073.PP
1074Rxvt-unicode uses the \f(CW\*(C`LC_CTYPE\*(C'\fR locale category to select encoding. All
1075programs doing the same (that is, most) will automatically agree in the
1076interpretation of characters.
1077.PP
1078Unfortunately, there is no system-independent way to select locales, nor
1079is there a standard on how locale specifiers will look like.
1080.PP
1081On most systems, the content of the \f(CW\*(C`LC_CTYPE\*(C'\fR environment variable
1082contains an arbitrary string which corresponds to an already-installed
1083locale. Common names for locales are \f(CW\*(C`en_US.UTF\-8\*(C'\fR, \f(CW\*(C`de_DE.ISO\-8859\-15\*(C'\fR,
1084\&\f(CW\*(C`ja_JP.EUC\-JP\*(C'\fR, i.e. \f(CW\*(C`language_country.encoding\*(C'\fR, but other forms
1085(i.e. \f(CW\*(C`de\*(C'\fR or \f(CW\*(C`german\*(C'\fR) are also common.
1086.PP
1087Rxvt-unicode ignores all other locale categories, and except for
1088the encoding, ignores country or language-specific settings,
1089i.e. \f(CW\*(C`de_DE.UTF\-8\*(C'\fR and \f(CW\*(C`ja_JP.UTF\-8\*(C'\fR are the normally same to
1090rxvt\-unicode.
1091.PP
1092If you want to use a specific encoding you have to make sure you start
1093rxvt-unicode with the correct \f(CW\*(C`LC_CTYPE\*(C'\fR category.
1094.PP
1095\fICan I switch locales at runtime?\fR
1096.IX Subsection "Can I switch locales at runtime?"
1097.PP
1098Yes, using an escape sequence. Try something like this, which sets
1099rxvt\-unicode's idea of \f(CW\*(C`LC_CTYPE\*(C'\fR.
1100.PP
606.Vb 1 1101.Vb 1
607\& @@RXVT_NAME@@ -fn basefont,font2,font3... 1102\& printf '\ee]701;%s\e007' ja_JP.SJIS
608.Ve 1103.Ve
609.Sp 1104.PP
610When rxvt-unicode sees a character, it will first look at the base 1105See also the previous answer.
611font. If the base font does not contain the character, it will go to the 1106.PP
612next font, and so on. Specifying your own fonts will also speed up this 1107Sometimes this capability is rather handy when you want to work in
613search and use less resources within rxvt-unicode and the X\-server. 1108one locale (e.g. \f(CW\*(C`de_DE.UTF\-8\*(C'\fR) but some programs don't support it
614.Sp 1109(e.g. \s-1UTF\-8\s0). For example, I use this script to start \f(CW\*(C`xjdic\*(C'\fR, which
615The only limitation is that none of the fonts may be larger than the base 1110first switches to a locale supported by xjdic and back later:
616font, as the base font defines the terminal character cell size, which 1111.PP
617must be the same due to the way terminals work. 1112.Vb 3
618.IP "Why do some chinese characters look so different than others?" 4 1113\& printf '\ee]701;%s\e007' ja_JP.SJIS
619.IX Item "Why do some chinese characters look so different than others?" 1114\& xjdic -js
620This is because there is a difference between script and language \*(-- 1115\& printf '\ee]701;%s\e007' de_DE.UTF-8
621rxvt-unicode does not know which language the text that is output is, 1116.Ve
622as it only knows the unicode character codes. If rxvt-unicode first 1117.PP
623sees a japanese/chinese character, it might choose a japanese font for 1118You can also use xterm's \f(CW\*(C`luit\*(C'\fR program, which usually works fine, except
624display. Subsequent japanese characters will use that font. Now, many 1119for some locales where character width differs between program\- and
625chinese characters aren't represented in japanese fonts, so when the first 1120rxvt\-unicode\-locales.
626non-japanese character comes up, rxvt-unicode will look for a chinese font 1121.PP
627\&\*(-- unfortunately at this point, it will still use the japanese font for 1122\fIMy input method wants <some encoding> but I want \s-1UTF\-8\s0, what can I do?\fR
628chinese characters that are also in the japanese font. 1123.IX Subsection "My input method wants <some encoding> but I want UTF-8, what can I do?"
629.Sp 1124.PP
630The workaround is easy: just tag a chinese font at the end of your font 1125You can specify separate locales for the input method and the rest of the
631list (see the previous question). The key is to view the font list as 1126terminal, using the resource \f(CW\*(C`imlocale\*(C'\fR:
632a preference list: If you expect more japanese, list a japanese font 1127.PP
633first. If you expect more chinese, put a chinese font first. 1128.Vb 1
634.Sp 1129\& URxvt.imlocale: ja_JP.EUC-JP
635In the future it might be possible to switch language preferences at 1130.Ve
636runtime (the internal data structure has no problem with using different 1131.PP
637fonts for the same character at the same time, but no interface for this 1132Now you can start your terminal with \f(CW\*(C`LC_CTYPE=ja_JP.UTF\-8\*(C'\fR and still
638has been designed yet). 1133use your input method. Please note, however, that you will not be able to
639.Sp 1134input characters outside \f(CW\*(C`EUC\-JP\*(C'\fR in a normal way then, as your input
640Until then, you might get away with switching fonts at runtime (see \*(L"Can I switch the fonts at runtime?\*(R" later in this document). 1135method limits you.
641.IP "Why does rxvt-unicode sometimes leave pixel droppings?" 4 1136.PP
642.IX Item "Why does rxvt-unicode sometimes leave pixel droppings?" 1137\fIRxvt-unicode crashes when the X Input Method changes or exits.\fR
643Most fonts were not designed for terminal use, which means that character 1138.IX Subsection "Rxvt-unicode crashes when the X Input Method changes or exits."
644size varies a lot. A font that is otherwise fine for terminal use might 1139.PP
645contain some characters that are simply too wide. Rxvt-unicode will avoid 1140Unfortunately, this is unavoidable, as the \s-1XIM\s0 protocol is racy by
646these characters. For characters that are just \*(L"a bit\*(R" too wide a special 1141design. Applications can avoid some crashes at the expense of memory
647\&\*(L"careful\*(R" rendering mode is used that redraws adjacent characters. 1142leaks, and Input Methods can avoid some crashes by careful ordering at
648.Sp 1143exit time. \fBkinput2\fR (and derived input methods) generally succeeds,
649All of this requires that fonts do not lie about character sizes, 1144while \fB\s-1SCIM\s0\fR (or similar input methods) fails. In the end, however,
650however: Xft fonts often draw glyphs larger than their acclaimed bounding 1145crashes cannot be completely avoided even if both sides cooperate.
651box, and rxvt-unicode has no way of detecting this (the correct way is to 1146.PP
652ask for the character bounding box, which unfortunately is wrong in these 1147So the only workaround is not to kill your Input Method Servers.
653cases). 1148.Sh "Operating Systems / Package Maintaining"
654.Sp 1149.IX Subsection "Operating Systems / Package Maintaining"
655It's not clear (to me at least), wether this is a bug in Xft, freetype, 1150\fII am using Debian GNU/Linux and have a problem...\fR
656or the respective font. If you encounter this problem you might try using 1151.IX Subsection "I am using Debian GNU/Linux and have a problem..."
657the \f(CW\*(C`\-lsp\*(C'\fR option to give the font more height. If that doesn't work, you 1152.PP
658might be forced to use a different font. 1153The Debian GNU/Linux package of rxvt-unicode in sarge contains large
659.Sp 1154patches that considerably change the behaviour of rxvt-unicode (but
660All of this is not a problem when using X11 core fonts, as their bounding 1155unfortunately this notice has been removed). Before reporting a bug to
661box data is correct. 1156the original rxvt-unicode author please download and install the genuine
1157version (<http://software.schmorp.de#rxvt\-unicode>) and try to reproduce
1158the problem. If you cannot, chances are that the problems are specific to
1159Debian GNU/Linux, in which case it should be reported via the Debian Bug
1160Tracking System (use \f(CW\*(C`reportbug\*(C'\fR to report the bug).
1161.PP
1162For other problems that also affect the Debian package, you can and
1163probably should use the Debian \s-1BTS\s0, too, because, after all, it's also a
1164bug in the Debian version and it serves as a reminder for other users that
1165might encounter the same issue.
1166.PP
1167\fII am maintaining rxvt-unicode for distribution/OS \s-1XXX\s0, any recommendation?\fR
1168.IX Subsection "I am maintaining rxvt-unicode for distribution/OS XXX, any recommendation?"
1169.PP
1170You should build one binary with the default options. \fIconfigure\fR
1171now enables most useful options, and the trend goes to making them
1172runtime\-switchable, too, so there is usually no drawback to enbaling them,
1173except higher disk and possibly memory usage. The perl interpreter should
1174be enabled, as important functionality (menus, selection, likely more in
1175the future) depends on it.
1176.PP
1177You should not overwrite the \f(CW\*(C`perl\-ext\-common\*(C'\fR snd \f(CW\*(C`perl\-ext\*(C'\fR resources
1178system-wide (except maybe with \f(CW\*(C`defaults\*(C'\fR). This will result in useful
1179behaviour. If your distribution aims at low memory, add an empty
1180\&\f(CW\*(C`perl\-ext\-common\*(C'\fR resource to the app-defaults file. This will keep the
1181perl interpreter disabled until the user enables it.
1182.PP
1183If you can/want build more binaries, I recommend building a minimal
1184one with \f(CW\*(C`\-\-disable\-everything\*(C'\fR (very useful) and a maximal one with
1185\&\f(CW\*(C`\-\-enable\-everything\*(C'\fR (less useful, it will be very big due to a lot of
1186encodings built-in that increase download times and are rarely used).
1187.PP
1188\fII need to make it setuid/setgid to support utmp/ptys on my \s-1OS\s0, is this safe?\fR
1189.IX Subsection "I need to make it setuid/setgid to support utmp/ptys on my OS, is this safe?"
1190.PP
1191It should be, starting with release 7.1. You are encouraged to properly
1192install urxvt with privileges necessary for your \s-1OS\s0 now.
1193.PP
1194When rxvt-unicode detects that it runs setuid or setgid, it will fork
1195into a helper process for privileged operations (pty handling on some
1196systems, utmp/wtmp/lastlog handling on others) and drop privileges
1197immediately. This is much safer than most other terminals that keep
1198privileges while running (but is more relevant to urxvt, as it contains
1199things as perl interpreters, which might be \*(L"helpful\*(R" to attackers).
1200.PP
1201This forking is done as the very first within \fImain()\fR, which is very early
1202and reduces possible bugs to initialisation code run before \fImain()\fR, or
1203things like the dynamic loader of your system, which should result in very
1204little risk.
1205.PP
662.IP "On Solaris 9, many line-drawing characters are too wide." 4 1206\fIOn Solaris 9, many line-drawing characters are too wide.\fR
663.IX Item "On Solaris 9, many line-drawing characters are too wide." 1207.IX Subsection "On Solaris 9, many line-drawing characters are too wide."
1208.PP
664Seems to be a known bug, read 1209Seems to be a known bug, read
665<http://nixdoc.net/files/forum/about34198.html>. Some people use the 1210<http://nixdoc.net/files/forum/about34198.html>. Some people use the
666following ugly workaround to get non-double-wide-characters working: 1211following ugly workaround to get non-double-wide-characters working:
667.Sp 1212.PP
668.Vb 1 1213.Vb 1
669\& #define wcwidth(x) wcwidth(x) > 1 ? 1 : wcwidth(x) 1214\& #define wcwidth(x) wcwidth(x) > 1 ? 1 : wcwidth(x)
670.Ve 1215.Ve
671.IP "My Compose (Multi_key) key is no longer working." 4 1216.PP
672.IX Item "My Compose (Multi_key) key is no longer working."
673The most common causes for this are that either your locale is not set
674correctly, or you specified a \fBpreeditStyle\fR that is not supported by
675your input method. For example, if you specified \fBOverTheSpot\fR and
676your input method (e.g. the default input method handling Compose keys)
677does not support this (for instance because it is not visual), then
678rxvt-unicode will continue without an input method.
679.Sp
680In this case either do not specify a \fBpreeditStyle\fR or specify more than
681one pre-edit style, such as \fBOverTheSpot,Root,None\fR.
682.ie n .IP "I cannot type ""Ctrl\-Shift\-2"" to get an \s-1ASCII\s0 \s-1NUL\s0 character due to \s-1ISO\s0 14755" 4
683.el .IP "I cannot type \f(CWCtrl\-Shift\-2\fR to get an \s-1ASCII\s0 \s-1NUL\s0 character due to \s-1ISO\s0 14755" 4
684.IX Item "I cannot type Ctrl-Shift-2 to get an ASCII NUL character due to ISO 14755"
685Either try \f(CW\*(C`Ctrl\-2\*(C'\fR alone (it often is mapped to \s-1ASCII\s0 \s-1NUL\s0 even on
686international keyboards) or simply use \s-1ISO\s0 14755 support to your
687advantage, typing <Ctrl\-Shift\-0> to get a \s-1ASCII\s0 \s-1NUL\s0. This works for other
688codes, too, such as \f(CW\*(C`Ctrl\-Shift\-1\-d\*(C'\fR to type the default telnet escape
689character and so on.
690.IP "How can I keep rxvt-unicode from using reverse video so much?" 4
691.IX Item "How can I keep rxvt-unicode from using reverse video so much?"
692First of all, make sure you are running with the right terminal settings
693(\f(CW\*(C`TERM=rxvt\-unicode\*(C'\fR), which will get rid of most of these effects. Then
694make sure you have specified colours for italic and bold, as otherwise
695rxvt-unicode might use reverse video to simulate the effect:
696.Sp
697.Vb 2
698\& URxvt.colorBD: white
699\& URxvt.colorIT: green
700.Ve
701.IP "Some programs assume totally weird colours (red instead of blue), how can I fix that?" 4
702.IX Item "Some programs assume totally weird colours (red instead of blue), how can I fix that?"
703For some unexplainable reason, some rare programs assume a very weird
704colour palette when confronted with a terminal with more than the standard
7058 colours (rxvt\-unicode supports 88). The right fix is, of course, to fix
706these programs not to assume non-ISO colours without very good reasons.
707.Sp
708In the meantime, you can either edit your \f(CW\*(C`rxvt\-unicode\*(C'\fR terminfo
709definition to only claim 8 colour support or use \f(CW\*(C`TERM=rxvt\*(C'\fR, which will
710fix colours but keep you from using other rxvt-unicode features.
711.IP "I am on FreeBSD and rxvt-unicode does not seem to work at all." 4 1217\fII am on FreeBSD and rxvt-unicode does not seem to work at all.\fR
712.IX Item "I am on FreeBSD and rxvt-unicode does not seem to work at all." 1218.IX Subsection "I am on FreeBSD and rxvt-unicode does not seem to work at all."
1219.PP
713Rxvt-unicode requires the symbol \f(CW\*(C`_\|_STDC_ISO_10646_\|_\*(C'\fR to be defined 1220Rxvt-unicode requires the symbol \f(CW\*(C`_\|_STDC_ISO_10646_\|_\*(C'\fR to be defined
714in your compile environment, or an implementation that implements it, 1221in your compile environment, or an implementation that implements it,
715wether it defines the symbol or not. \f(CW\*(C`_\|_STDC_ISO_10646_\|_\*(C'\fR requires that 1222wether it defines the symbol or not. \f(CW\*(C`_\|_STDC_ISO_10646_\|_\*(C'\fR requires that
716\&\fBwchar_t\fR is represented as unicode. 1223\&\fBwchar_t\fR is represented as unicode.
717.Sp 1224.PP
718As you might have guessed, FreeBSD does neither define this symobl nor 1225As you might have guessed, FreeBSD does neither define this symobl nor
719does it support it. Instead, it uses it's own internal representation of 1226does it support it. Instead, it uses it's own internal representation of
720\&\fBwchar_t\fR. This is, of course, completely fine with respect to standards. 1227\&\fBwchar_t\fR. This is, of course, completely fine with respect to standards.
721.Sp 1228.PP
722However, that means rxvt-unicode only works in \f(CW\*(C`POSIX\*(C'\fR, \f(CW\*(C`ISO\-8859\-1\*(C'\fR and 1229However, that means rxvt-unicode only works in \f(CW\*(C`POSIX\*(C'\fR, \f(CW\*(C`ISO\-8859\-1\*(C'\fR and
723\&\f(CW\*(C`UTF\-8\*(C'\fR locales under FreeBSD (which all use Unicode as \fBwchar_t\fR. 1230\&\f(CW\*(C`UTF\-8\*(C'\fR locales under FreeBSD (which all use Unicode as \fBwchar_t\fR.
724.Sp 1231.PP
725\&\f(CW\*(C`_\|_STDC_ISO_10646_\|_\*(C'\fR is the only sane way to support multi-language 1232\&\f(CW\*(C`_\|_STDC_ISO_10646_\|_\*(C'\fR is the only sane way to support multi-language
726apps in an \s-1OS\s0, as using a locale-dependent (and non\-standardized) 1233apps in an \s-1OS\s0, as using a locale-dependent (and non\-standardized)
727representation of \fBwchar_t\fR makes it impossible to convert between 1234representation of \fBwchar_t\fR makes it impossible to convert between
728\&\fBwchar_t\fR (as used by X11 and your applications) and any other encoding 1235\&\fBwchar_t\fR (as used by X11 and your applications) and any other encoding
729without implementing OS-specific-wrappers for each and every locale. There 1236without implementing OS-specific-wrappers for each and every locale. There
730simply are no APIs to convert \fBwchar_t\fR into anything except the current 1237simply are no APIs to convert \fBwchar_t\fR into anything except the current
731locale encoding. 1238locale encoding.
732.Sp 1239.PP
733Some applications (such as the formidable \fBmlterm\fR) work around this 1240Some applications (such as the formidable \fBmlterm\fR) work around this
734by carrying their own replacement functions for character set handling 1241by carrying their own replacement functions for character set handling
735with them, and either implementing OS-dependent hacks or doing multiple 1242with them, and either implementing OS-dependent hacks or doing multiple
736conversions (which is slow and unreliable in case the \s-1OS\s0 implements 1243conversions (which is slow and unreliable in case the \s-1OS\s0 implements
737encodings slightly different than the terminal emulator). 1244encodings slightly different than the terminal emulator).
738.Sp 1245.PP
739The rxvt-unicode author insists that the right way to fix this is in the 1246The rxvt-unicode author insists that the right way to fix this is in the
740system libraries once and for all, instead of forcing every app to carry 1247system libraries once and for all, instead of forcing every app to carry
741complete replacements for them :) 1248complete replacements for them :)
1249.PP
742.IP "I use Solaris 9 and it doesn't compile/work/etc." 4 1250\fII use Solaris 9 and it doesn't compile/work/etc.\fR
743.IX Item "I use Solaris 9 and it doesn't compile/work/etc." 1251.IX Subsection "I use Solaris 9 and it doesn't compile/work/etc."
1252.PP
744Try the diff in \fIdoc/solaris9.patch\fR as a base. It fixes the worst 1253Try the diff in \fIdoc/solaris9.patch\fR as a base. It fixes the worst
745problems with \f(CW\*(C`wcwidth\*(C'\fR and a compile problem. 1254problems with \f(CW\*(C`wcwidth\*(C'\fR and a compile problem.
1255.PP
746.IP "How can I use rxvt-unicode under cygwin?" 4 1256\fIHow can I use rxvt-unicode under cygwin?\fR
747.IX Item "How can I use rxvt-unicode under cygwin?" 1257.IX Subsection "How can I use rxvt-unicode under cygwin?"
1258.PP
748rxvt-unicode should compile and run out of the box on cygwin, using 1259rxvt-unicode should compile and run out of the box on cygwin, using
749the X11 libraries that come with cygwin. libW11 emulation is no 1260the X11 libraries that come with cygwin. libW11 emulation is no
750longer supported (and makes no sense, either, as it only supported a 1261longer supported (and makes no sense, either, as it only supported a
751single font). I recommend starting the X\-server in \f(CW\*(C`\-multiwindow\*(C'\fR or 1262single font). I recommend starting the X\-server in \f(CW\*(C`\-multiwindow\*(C'\fR or
752\&\f(CW\*(C`\-rootless\*(C'\fR mode instead, which will result in similar look&feel as the 1263\&\f(CW\*(C`\-rootless\*(C'\fR mode instead, which will result in similar look&feel as the
753old libW11 emulation. 1264old libW11 emulation.
754.Sp 1265.PP
755At the time of this writing, cygwin didn't seem to support any multi-byte 1266At the time of this writing, cygwin didn't seem to support any multi-byte
756encodings (you might try \f(CW\*(C`LC_CTYPE=C\-UTF\-8\*(C'\fR), so you are likely limited 1267encodings (you might try \f(CW\*(C`LC_CTYPE=C\-UTF\-8\*(C'\fR), so you are likely limited
757to 8\-bit encodings. 1268to 8\-bit encodings.
758.IP "How does rxvt-unicode determine the encoding to use?" 4
759.IX Item "How does rxvt-unicode determine the encoding to use?"
760.PD 0
761.IP "Is there an option to switch encodings?" 4
762.IX Item "Is there an option to switch encodings?"
763.PD
764Unlike some other terminals, rxvt-unicode has no encoding switch, and no
765specific \*(L"utf\-8\*(R" mode, such as xterm. In fact, it doesn't even know about
766\&\s-1UTF\-8\s0 or any other encodings with respect to terminal I/O.
767.Sp
768The reasons is that there exists a perfectly fine mechanism for selecting
769the encoding, doing I/O and (most important) communicating this to all
770applications so everybody agrees on character properties such as width
771and code number. This mechanism is the \fIlocale\fR. Applications not using
772that info will have problems (for example, \f(CW\*(C`xterm\*(C'\fR gets the width of
773characters wrong as it uses it's own, locale-independent table under all
774locales).
775.Sp
776Rxvt-unicode uses the \f(CW\*(C`LC_CTYPE\*(C'\fR locale category to select encoding. All
777programs doing the same (that is, most) will automatically agree in the
778interpretation of characters.
779.Sp
780Unfortunately, there is no system-independent way to select locales, nor
781is there a standard on how locale specifiers will look like.
782.Sp
783On most systems, the content of the \f(CW\*(C`LC_CTYPE\*(C'\fR environment variable
784contains an arbitrary string which corresponds to an already-installed
785locale. Common names for locales are \f(CW\*(C`en_US.UTF\-8\*(C'\fR, \f(CW\*(C`de_DE.ISO\-8859\-15\*(C'\fR,
786\&\f(CW\*(C`ja_JP.EUC\-JP\*(C'\fR, i.e. \f(CW\*(C`language_country.encoding\*(C'\fR, but other forms
787(i.e. \f(CW\*(C`de\*(C'\fR or \f(CW\*(C`german\*(C'\fR) are also common.
788.Sp
789Rxvt-unicode ignores all other locale categories, and except for
790the encoding, ignores country or language-specific settings,
791i.e. \f(CW\*(C`de_DE.UTF\-8\*(C'\fR and \f(CW\*(C`ja_JP.UTF\-8\*(C'\fR are the normally same to
792rxvt\-unicode.
793.Sp
794If you want to use a specific encoding you have to make sure you start
795rxvt-unicode with the correct \f(CW\*(C`LC_CTYPE\*(C'\fR category.
796.IP "Can I switch locales at runtime?" 4
797.IX Item "Can I switch locales at runtime?"
798Yes, using an escape sequence. Try something like this, which sets
799rxvt\-unicode's idea of \f(CW\*(C`LC_CTYPE\*(C'\fR.
800.Sp
801.Vb 1
802\& printf '\ee]701;%s\e007' ja_JP.SJIS
803.Ve
804.Sp
805See also the previous answer.
806.Sp
807Sometimes this capability is rather handy when you want to work in
808one locale (e.g. \f(CW\*(C`de_DE.UTF\-8\*(C'\fR) but some programs don't support it
809(e.g. \s-1UTF\-8\s0). For example, I use this script to start \f(CW\*(C`xjdic\*(C'\fR, which
810first switches to a locale supported by xjdic and back later:
811.Sp
812.Vb 3
813\& printf '\ee]701;%s\e007' ja_JP.SJIS
814\& xjdic -js
815\& printf '\ee]701;%s\e007' de_DE.UTF-8
816.Ve
817.Sp
818You can also use xterm's \f(CW\*(C`luit\*(C'\fR program, which usually works fine, except
819for some locales where character width differs between program\- and
820rxvt\-unicode\-locales.
821.IP "Can I switch the fonts at runtime?" 4
822.IX Item "Can I switch the fonts at runtime?"
823Yes, using an escape sequence. Try something like this, which has the same
824effect as using the \f(CW\*(C`\-fn\*(C'\fR switch, and takes effect immediately:
825.Sp
826.Vb 1
827\& printf '\ee]50;%s\e007' "9x15bold,xft:Kochi Gothic"
828.Ve
829.Sp
830This is useful if you e.g. work primarily with japanese (and prefer a
831japanese font), but you have to switch to chinese temporarily, where
832japanese fonts would only be in your way.
833.Sp
834You can think of this as a kind of manual \s-1ISO\-2022\s0 switching.
835.IP "Why do italic characters look as if clipped?" 4
836.IX Item "Why do italic characters look as if clipped?"
837Many fonts have difficulties with italic characters and hinting. For
838example, the otherwise very nicely hinted font \f(CW\*(C`xft:Bitstream Vera Sans
839Mono\*(C'\fR completely fails in it's italic face. A workaround might be to
840enable freetype autohinting, i.e. like this:
841.Sp
842.Vb 2
843\& URxvt.italicFont: xft:Bitstream Vera Sans Mono:italic:autohint=true
844\& URxvt.boldItalicFont: xft:Bitstream Vera Sans Mono:bold:italic:autohint=true
845.Ve
846.IP "My input method wants <some encoding> but I want \s-1UTF\-8\s0, what can I do?" 4
847.IX Item "My input method wants <some encoding> but I want UTF-8, what can I do?"
848You can specify separate locales for the input method and the rest of the
849terminal, using the resource \f(CW\*(C`imlocale\*(C'\fR:
850.Sp
851.Vb 1
852\& URxvt.imlocale: ja_JP.EUC-JP
853.Ve
854.Sp
855Now you can start your terminal with \f(CW\*(C`LC_CTYPE=ja_JP.UTF\-8\*(C'\fR and still
856use your input method. Please note, however, that you will not be able to
857input characters outside \f(CW\*(C`EUC\-JP\*(C'\fR in a normal way then, as your input
858method limits you.
859.IP "Rxvt-unicode crashes when the X Input Method changes or exits." 4
860.IX Item "Rxvt-unicode crashes when the X Input Method changes or exits."
861Unfortunately, this is unavoidable, as the \s-1XIM\s0 protocol is racy by
862design. Applications can avoid some crashes at the expense of memory
863leaks, and Input Methods can avoid some crashes by careful ordering at
864exit time. \fBkinput2\fR (and derived input methods) generally succeeds,
865while \fB\s-1SCIM\s0\fR (or similar input methods) fails. In the end, however,
866crashes cannot be completely avoided even if both sides cooperate.
867.Sp
868So the only workaround is not to kill your Input Method Servers.
869.IP "Rxvt-unicode uses gobs of memory, how can I reduce that?" 4
870.IX Item "Rxvt-unicode uses gobs of memory, how can I reduce that?"
871Rxvt-unicode tries to obey the rule of not charging you for something you
872don't use. One thing you should try is to configure out all settings that
873you don't need, for example, Xft support is a resource hog by design,
874when used. Compiling it out ensures that no Xft font will be loaded
875accidentally when rxvt-unicode tries to find a font for your characters.
876.Sp
877Also, many people (me included) like large windows and even larger
878scrollback buffers: Without \f(CW\*(C`\-\-enable\-unicode3\*(C'\fR, rxvt-unicode will use
8796 bytes per screen cell. For a 160x?? window this amounts to almost a
880kilobyte per line. A scrollback buffer of 10000 lines will then (if full)
881use 10 Megabytes of memory. With \f(CW\*(C`\-\-enable\-unicode3\*(C'\fR it gets worse, as
882rxvt-unicode then uses 8 bytes per screen cell.
883.IP "Can I speed up Xft rendering somehow?" 4
884.IX Item "Can I speed up Xft rendering somehow?"
885Yes, the most obvious way to speed it up is to avoid Xft entirely, as
886it is simply slow. If you still want Xft fonts you might try to disable
887antialiasing (by appending \f(CW\*(C`:antialias=false\*(C'\fR), which saves lots of
888memory and also speeds up rendering considerably.
889.IP "Rxvt-unicode doesn't seem to anti-alias its fonts, what is wrong?" 4
890.IX Item "Rxvt-unicode doesn't seem to anti-alias its fonts, what is wrong?"
891Rxvt-unicode will use whatever you specify as a font. If it needs to
892fall back to it's default font search list it will prefer X11 core
893fonts, because they are small and fast, and then use Xft fonts. It has
894antialiasing disabled for most of them, because the author thinks they
895look best that way.
896.Sp
897If you want antialiasing, you have to specify the fonts manually.
898.IP "Mouse cut/paste suddenly no longer works." 4
899.IX Item "Mouse cut/paste suddenly no longer works."
900Make sure that mouse reporting is actually turned off since killing
901some editors prematurely may leave the mouse in mouse report mode. I've
902heard that tcsh may use mouse reporting unless it otherwise specified. A
903quick check is to see if cut/paste works when the Alt or Shift keys are
904depressed.
905.IP "What's with this bold/blink stuff?" 4
906.IX Item "What's with this bold/blink stuff?"
907If no bold colour is set via \f(CW\*(C`colorBD:\*(C'\fR, bold will invert text using the
908standard foreground colour.
909.Sp
910For the standard background colour, blinking will actually make the
911text blink when compiled with \f(CW\*(C`\-\-enable\-blinking\*(C'\fR. with standard
912colours. Without \f(CW\*(C`\-\-enable\-blinking\*(C'\fR, the blink attribute will be
913ignored.
914.Sp
915On \s-1ANSI\s0 colours, bold/blink attributes are used to set high-intensity
916foreground/background colors.
917.Sp
918color0\-7 are the low-intensity colors.
919.Sp
920color8\-15 are the corresponding high-intensity colors.
921.IP "I don't like the screen colors. How do I change them?" 4
922.IX Item "I don't like the screen colors. How do I change them?"
923You can change the screen colors at run-time using \fI~/.Xdefaults\fR
924resources (or as long\-options).
925.Sp
926Here are values that are supposed to resemble a \s-1VGA\s0 screen,
927including the murky brown that passes for low-intensity yellow:
928.Sp
929.Vb 8
930\& URxvt.color0: #000000
931\& URxvt.color1: #A80000
932\& URxvt.color2: #00A800
933\& URxvt.color3: #A8A800
934\& URxvt.color4: #0000A8
935\& URxvt.color5: #A800A8
936\& URxvt.color6: #00A8A8
937\& URxvt.color7: #A8A8A8
938.Ve
939.Sp
940.Vb 8
941\& URxvt.color8: #000054
942\& URxvt.color9: #FF0054
943\& URxvt.color10: #00FF54
944\& URxvt.color11: #FFFF54
945\& URxvt.color12: #0000FF
946\& URxvt.color13: #FF00FF
947\& URxvt.color14: #00FFFF
948\& URxvt.color15: #FFFFFF
949.Ve
950.Sp
951And here is a more complete set of non-standard colors described (not by
952me) as \*(L"pretty girly\*(R".
953.Sp
954.Vb 18
955\& URxvt.cursorColor: #dc74d1
956\& URxvt.pointerColor: #dc74d1
957\& URxvt.background: #0e0e0e
958\& URxvt.foreground: #4ad5e1
959\& URxvt.color0: #000000
960\& URxvt.color8: #8b8f93
961\& URxvt.color1: #dc74d1
962\& URxvt.color9: #dc74d1
963\& URxvt.color2: #0eb8c7
964\& URxvt.color10: #0eb8c7
965\& URxvt.color3: #dfe37e
966\& URxvt.color11: #dfe37e
967\& URxvt.color5: #9e88f0
968\& URxvt.color13: #9e88f0
969\& URxvt.color6: #73f7ff
970\& URxvt.color14: #73f7ff
971\& URxvt.color7: #e1dddd
972\& URxvt.color15: #e1dddd
973.Ve
974.IP "How can I start @@RXVT_NAME@@d in a race-free way?" 4
975.IX Item "How can I start @@RXVT_NAME@@d in a race-free way?"
976Try \f(CW\*(C`@@RXVT_NAME@@d \-f \-o\*(C'\fR, which tells @@RXVT_NAME@@d to open the
977display, create the listening socket and then fork.
978.IP "What's with the strange Backspace/Delete key behaviour?" 4
979.IX Item "What's with the strange Backspace/Delete key behaviour?"
980Assuming that the physical Backspace key corresponds to the
981BackSpace keysym (not likely for Linux ... see the following
982question) there are two standard values that can be used for
983Backspace: \f(CW\*(C`^H\*(C'\fR and \f(CW\*(C`^?\*(C'\fR.
984.Sp
985Historically, either value is correct, but rxvt-unicode adopts the debian
986policy of using \f(CW\*(C`^?\*(C'\fR when unsure, because it's the one only only correct
987choice :).
988.Sp
989Rxvt-unicode tries to inherit the current stty settings and uses the value
990of `erase' to guess the value for backspace. If rxvt-unicode wasn't
991started from a terminal (say, from a menu or by remote shell), then the
992system value of `erase', which corresponds to \s-1CERASE\s0 in <termios.h>, will
993be used (which may not be the same as your stty setting).
994.Sp
995For starting a new rxvt\-unicode:
996.Sp
997.Vb 3
998\& # use Backspace = ^H
999\& $ stty erase ^H
1000\& $ @@RXVT_NAME@@
1001.Ve
1002.Sp
1003.Vb 3
1004\& # use Backspace = ^?
1005\& $ stty erase ^?
1006\& $ @@RXVT_NAME@@
1007.Ve
1008.Sp
1009Toggle with \f(CW\*(C`ESC [ 36 h\*(C'\fR / \f(CW\*(C`ESC [ 36 l\*(C'\fR.
1010.Sp
1011For an existing rxvt\-unicode:
1012.Sp
1013.Vb 3
1014\& # use Backspace = ^H
1015\& $ stty erase ^H
1016\& $ echo -n "^[[36h"
1017.Ve
1018.Sp
1019.Vb 3
1020\& # use Backspace = ^?
1021\& $ stty erase ^?
1022\& $ echo -n "^[[36l"
1023.Ve
1024.Sp
1025This helps satisfy some of the Backspace discrepancies that occur, but
1026if you use Backspace = \f(CW\*(C`^H\*(C'\fR, make sure that the termcap/terminfo value
1027properly reflects that.
1028.Sp
1029The Delete key is a another casualty of the ill-defined Backspace problem.
1030To avoid confusion between the Backspace and Delete keys, the Delete
1031key has been assigned an escape sequence to match the vt100 for Execute
1032(\f(CW\*(C`ESC [ 3 ~\*(C'\fR) and is in the supplied termcap/terminfo.
1033.Sp
1034Some other Backspace problems:
1035.Sp
1036some editors use termcap/terminfo,
1037some editors (vim I'm told) expect Backspace = ^H,
1038\&\s-1GNU\s0 Emacs (and Emacs-like editors) use ^H for help.
1039.Sp
1040Perhaps someday this will all be resolved in a consistent manner.
1041.IP "I don't like the key\-bindings. How do I change them?" 4
1042.IX Item "I don't like the key-bindings. How do I change them?"
1043There are some compile-time selections available via configure. Unless
1044you have run \*(L"configure\*(R" with the \f(CW\*(C`\-\-disable\-resources\*(C'\fR option you can
1045use the `keysym' resource to alter the keystrings associated with keysyms.
1046.Sp
1047Here's an example for a URxvt session started using \f(CW\*(C`@@RXVT_NAME@@ \-name URxvt\*(C'\fR
1048.Sp
1049.Vb 20
1050\& URxvt.keysym.Home: \e033[1~
1051\& URxvt.keysym.End: \e033[4~
1052\& URxvt.keysym.C-apostrophe: \e033<C-'>
1053\& URxvt.keysym.C-slash: \e033<C-/>
1054\& URxvt.keysym.C-semicolon: \e033<C-;>
1055\& URxvt.keysym.C-grave: \e033<C-`>
1056\& URxvt.keysym.C-comma: \e033<C-,>
1057\& URxvt.keysym.C-period: \e033<C-.>
1058\& URxvt.keysym.C-0x60: \e033<C-`>
1059\& URxvt.keysym.C-Tab: \e033<C-Tab>
1060\& URxvt.keysym.C-Return: \e033<C-Return>
1061\& URxvt.keysym.S-Return: \e033<S-Return>
1062\& URxvt.keysym.S-space: \e033<S-Space>
1063\& URxvt.keysym.M-Up: \e033<M-Up>
1064\& URxvt.keysym.M-Down: \e033<M-Down>
1065\& URxvt.keysym.M-Left: \e033<M-Left>
1066\& URxvt.keysym.M-Right: \e033<M-Right>
1067\& URxvt.keysym.M-C-0: list \e033<M-C- 0123456789 >
1068\& URxvt.keysym.M-C-a: list \e033<M-C- abcdefghijklmnopqrstuvwxyz >
1069\& URxvt.keysym.F12: command:\e033]701;zh_CN.GBK\e007
1070.Ve
1071.Sp
1072See some more examples in the documentation for the \fBkeysym\fR resource.
1073.IP "I'm using keyboard model \s-1XXX\s0 that has extra Prior/Next/Insert keys. How do I make use of them? For example, the Sun Keyboard type 4 has the following mappings that rxvt-unicode doesn't recognize." 4
1074.IX Item "I'm using keyboard model XXX that has extra Prior/Next/Insert keys. How do I make use of them? For example, the Sun Keyboard type 4 has the following mappings that rxvt-unicode doesn't recognize."
1075.Vb 6
1076\& KP_Insert == Insert
1077\& F22 == Print
1078\& F27 == Home
1079\& F29 == Prior
1080\& F33 == End
1081\& F35 == Next
1082.Ve
1083.Sp
1084Rather than have rxvt-unicode try to accommodate all the various possible
1085keyboard mappings, it is better to use `xmodmap' to remap the keys as
1086required for your particular machine.
1087.IP "How do I distinguish wether I'm running rxvt-unicode or a regular xterm? I need this to decide about setting colors etc." 4
1088.IX Item "How do I distinguish wether I'm running rxvt-unicode or a regular xterm? I need this to decide about setting colors etc."
1089rxvt and rxvt-unicode always export the variable \*(L"\s-1COLORTERM\s0\*(R", so you can
1090check and see if that is set. Note that several programs, \s-1JED\s0, slrn,
1091Midnight Commander automatically check this variable to decide whether or
1092not to use color.
1093.IP "How do I set the correct, full \s-1IP\s0 address for the \s-1DISPLAY\s0 variable?" 4
1094.IX Item "How do I set the correct, full IP address for the DISPLAY variable?"
1095If you've compiled rxvt-unicode with \s-1DISPLAY_IS_IP\s0 and have enabled
1096insecure mode then it is possible to use the following shell script
1097snippets to correctly set the display. If your version of rxvt-unicode
1098wasn't also compiled with \s-1ESCZ_ANSWER\s0 (as assumed in these snippets) then
1099the \s-1COLORTERM\s0 variable can be used to distinguish rxvt-unicode from a
1100regular xterm.
1101.Sp
1102Courtesy of Chuck Blake <cblake@BBN.COM> with the following shell script
1103snippets:
1104.Sp
1105.Vb 12
1106\& # Bourne/Korn/POSIX family of shells:
1107\& [ ${TERM:-foo} = foo ] && TERM=xterm # assume an xterm if we don't know
1108\& if [ ${TERM:-foo} = xterm ]; then
1109\& stty -icanon -echo min 0 time 15 # see if enhanced rxvt or not
1110\& echo -n '^[Z'
1111\& read term_id
1112\& stty icanon echo
1113\& if [ ""${term_id} = '^[[?1;2C' -a ${DISPLAY:-foo} = foo ]; then
1114\& echo -n '^[[7n' # query the rxvt we are in for the DISPLAY string
1115\& read DISPLAY # set it in our local shell
1116\& fi
1117\& fi
1118.Ve
1119.IP "How do I compile the manual pages for myself?" 4
1120.IX Item "How do I compile the manual pages for myself?"
1121You need to have a recent version of perl installed as \fI/usr/bin/perl\fR,
1122one that comes with \fIpod2man\fR, \fIpod2text\fR and \fIpod2html\fR. Then go to
1123the doc subdirectory and enter \f(CW\*(C`make alldoc\*(C'\fR.
1124.IP "My question isn't answered here, can I ask a human?" 4
1125.IX Item "My question isn't answered here, can I ask a human?"
1126Before sending me mail, you could go to \s-1IRC:\s0 \f(CW\*(C`irc.freenode.net\*(C'\fR,
1127channel \f(CW\*(C`#rxvt\-unicode\*(C'\fR has some rxvt-unicode enthusiasts that might be
1128interested in learning about new and exciting problems (but not FAQs :).
1129.SH "RXVT TECHNICAL REFERENCE" 1269.SH "RXVT TECHNICAL REFERENCE"
1130.IX Header "RXVT TECHNICAL REFERENCE" 1270.IX Header "RXVT TECHNICAL REFERENCE"
1131.SH "DESCRIPTION" 1271.SH "DESCRIPTION"
1132.IX Header "DESCRIPTION" 1272.IX Header "DESCRIPTION"
1133The rest of this document describes various technical aspects of 1273The rest of this document describes various technical aspects of

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines