urxvt(1)
urxvt(1) β RXVT-UNICODE π¦
β¨ NAME β¨
rxvt-unicode β (ouR XVT, unicode), a VT102 emulator for the X window system. π
π¦ SYNOPSIS π¦
urxvt [options] [-e command [ args ]]
πΈ DESCRIPTION πΈ
okay so rxvt-unicode, version 9.31, is a colour vt102 terminal emulator intended as an xterm(1) replacement for users who do not require features such as Tektronix 4014 emulation and toolkit-style configurability. As a result, rxvt-unicode uses much less swap space β a significant advantage on a machine serving many X sessions. β¨
This document is also available on the World-Wide-Web at <http://pod.tst.eu/http://cvs.schmorp.de/rxvt-unicode/doc/rxvt.1.pod>.
β FREQUENTLY ASKED QUESTIONS β
See urxvt(7) (try "man 7 urxvt") for a list of frequently asked questions and answer to them and some common problems. That document is also accessible on the World-Wide-Web at <http://pod.tst.eu/http://cvs.schmorp.de/rxvt-unicode/doc/rxvt.7.pod>.
π RXVT-UNICODE VS. RXVT π
Unlike the original rxvt, rxvt-unicode stores all text in Unicode internally. That means it can store and display most scripts in the world. Being a terminal emulator, however, some things are very difficult, especially cursive scripts such as arabic, vertically written scripts like mongolian or scripts requiring extremely complex combining rules, like tibetan or devanagari. Don't expect pretty output when using these scripts. Most other scripts, latin, cyrillic, kanji, thai etc. should work fine, though. A somewhat difficult case are right-to-left scripts, such as hebrew: rxvt-unicode adopts the view that bidirectional algorithms belong in the application, not the terminal emulator (too many things β such as cursor-movement while editing β break otherwise), but that might change. π
If you are looking for a terminal that supports more exotic scripts, let me recommend mlterm, which is a very user friendly, lean and clean terminal emulator. In fact, the reason rxvt-unicode was born was solely because the author couldn't get mlterm to use one font for latin1 and another for japanese. π
Therefore another design rationale was the use of multiple fonts to display characters: The idea of a single unicode font which many other programs force onto its users never made sense to me: You should be able to choose any font for any script freely. π
Apart from that, rxvt-unicode is also much better internationalised than its predecessor, supports things such as XFT and ISO 14755 that are handy in i18n-environments, is faster, and has a lot bugs less than the original rxvt. This all in addition to dozens of other small improvements. β¨
It is still faithfully following the original rxvt idea of being lean and nice on resources: for example, you can still configure rxvt-unicode without most of its features to get a lean binary. It also comes with a client/daemon pair that lets you open any number of terminal windows from within a single process, which makes startup time very fast and drastically reduces memory usage. See urxvtd(1) (daemon) and urxvtc(1) (client). π«Ά
It also makes technical information about escape sequences (which have been extended) more accessible: see urxvt(7) for technical reference documentation (escape sequences etc.).
π OPTIONS π
The urxvt options (mostly a subset of xterm's) are listed below. In keeping with the smaller-is-better philosophy, options may be eliminated or default values chosen at compile-time, so options and defaults listed may not accurately reflect the version installed on your system. urxvt -h gives a list of major compile-time options on the Options line. Option descriptions may be prefixed with which compile option each is dependent upon. e.g. Compile XIM: requires XIM on the Options line. Note: urxvt -help gives a list of all command-line options compiled into your version.
Note that urxvt permits the resource name to be used as a long-option (--/++ option) so the potential command-line options are far greater than those listed. For example: urxvt --loginShell --color1 Orange.
The following options are available:
-help,--helpβ Print out a message describing available options.-displaydisplayname β Attempt to open a window on the named X display (the older form-dis still respected but deprecated). In the absence of this option, the display specified by theDISPLAYenvironment variable is used.-depthbitdepth β Compile frills: Attempt to find a visual with the given bit depth; resourcedepth.
[Please note that many X servers (andlibXft) are buggy with respect to-depth 32and/or alpha channels, and will cause all sorts of graphical corruption. This is harmless, but we can't do anything about this, so watch out]
-visualvisualID β Compile frills: Use the given visual (see e.g.xdpyinfofor possible visual ids) instead of the default, and also allocate a private colormap. All visual types except for DirectColor are supported.-geometrygeom β Window geometry (-gstill respected); resourcegeometry.-rv|+rvβ Turn on/off simulated reverse video; resourcereverseVideo.-j|+jβ Turn on/off jump scrolling (allow multiple lines per refresh); resourcejumpScroll.-ss|+ssβ Turn on/off skip scrolling (allow multiple screens per refresh); resourceskipScroll.-fpsnumber β Compile frills: Set the refresh interval (in frames per second or negative seconds); resourcerefreshRate.-fadenumber β Fade the text by the given percentage when focus is lost. Small values fade a little only, 100 completely replaces all colours by the fade colour; resourcefading.-fadecolorcolour β Fade to this colour when fading is used (see-fade). The default colour is opaque black. resourcefadeColor.-iconfile β Compile pixbuf: Use the specified image as application icon. This is used by many window managers, taskbars and pagers to represent the application window; resourceiconFile.-bgcolour β Window background colour; resourcebackground.-fgcolour β Window foreground colour; resourceforeground.-crcolour β The cursor colour; resourcecursorColor.-prcolour β The mouse pointer foreground colour; resourcepointerColor.-pr2colour β The mouse pointer background colour; resourcepointerColor2.-bdcolour β The colour of the border around the text area and between the scrollbar and the text; resourceborderColor.-fnfontlist β Select the fonts to be used. This is a comma separated list of font names that are checked in order when trying to find glyphs for characters. The first font defines the cell size for characters; other fonts might be smaller, but not (in general) larger. A (hopefully) reasonable default font list is always appended to it. See resourcefontfor more details.
In short, to specify an X11 core font, just specify its name or prefix it with x:. To specify an XFT-font, you need to prefix it with xft:, e.g.:
urxvt -fn "xft:Bitstream Vera Sans Mono:pixelsize=15"
urxvt -fn "9x15bold,xft:Bitstream Vera Sans Mono"
See also the question "How does rxvt-unicode choose fonts?" in the FAQ section of urxvt(7).
-fbfontlist β Compile font-styles: The bold font list to use when bold characters are to be printed. See resourceboldFontfor details.-fifontlist β Compile font-styles: The italic font list to use when italic characters are to be printed. See resourceitalicFontfor details.-fbifontlist β Compile font-styles: The bold italic font list to use when bold italic characters are to be printed. See resourceboldItalicFontfor details.-is|+isβ Compile font-styles: Bold/Blink font styles imply high intensity foreground/background (default). See resourceintensityStylesfor details.-namename β Specify the application name under which resources are to be obtained, rather than the default executable file name. Name should not contain'.'or'*'characters. Also sets the icon and title name.-ls|+lsβ Start as a login-shell/sub-shell; resourceloginShell.-mcmilliseconds β Specify the maximum time between multi-click selections.-ut|+utβ Compile utmp: Inhibit/enable writing a utmp entry; resourceutmpInhibit.-vb|+vbβ Turn on/off visual bell on receipt of a bell character; resourcevisualBell.-sb|+sbβ Turn on/off scrollbar; resourcescrollBar.-sr|+srβ Put scrollbar on right/left; resourcescrollBar_right.-st|+stβ Display rxvt (non XTerm/NeXT) scrollbar without/with a trough; resourcescrollBar_floating.-si|+siβ Turn on/off scroll-to-bottom on TTY output inhibit; resourcescrollTtyOutputhas opposite effect.-sk|+skβ Turn on/off scroll-to-bottom on keypress; resourcescrollTtyKeypress.-sw|+swβ Turn on/off scrolling with the scrollback buffer as new lines appear. This only takes effect if-siis also given; resourcescrollWithBuffer.-ptab|+ptabβ If enabled (default), "Horizontal Tab" characters are being stored as actual wide characters in the screen buffer, which makes it possible to select and paste them. Since a horizontal tab is a cursor movement and not an actual glyph, this can sometimes be visually annoying as the cursor on a tab character is displayed as a wide cursor; resourcepastableTabs.-bc|+bcβ Blink the cursor; resourcecursorBlink.-uc|+ucβ Make the cursor underlined; resourcecursorUnderline.-iconicβ Start iconified, if the window manager supports that option. Alternative form is-ic.-slnumber β Save number lines in the scrollback buffer. See resource entry for limits; resourcesaveLines.-bnumber β Compile frills: Internal border of number pixels. See resource entry for limits; resourceinternalBorder.-wnumber β Compile frills: External border of number pixels. Also,-bwand-borderwidth. See resource entry for limits; resourceexternalBorder.-blβ Compile frills: Set MWM hints to request a borderless window, i.e. if honoured by the WM, the rxvt-unicode window will not have window decorations; resourceborderLess. If the window manager does not support MWM hints (e.g. kwin), enables override-redirect mode.-override-redirectβ Compile frills: Sets override-redirect on the window; resourceoverride-redirect.-dockappβ this one sets the window's initial state toWithdrawnState, which means any window manager that supports that extension will treat urxvt like a dockapp π«Ά-sbgβ Compile frills π turns off the built-in block graphics / line drawing characters and just trusts whatever the fonts you picked give you. Use this if you've got a gorgeous font and you actually want its block graphic glyphs; resourceskipBuiltinGlyphs.-lspnumber β Compile frills β¨ how many lines (pixel height) to insert between each row of the display. Genuinely a lifesaver for working around font rendering problems; resourcelineSpace.-letspnumber β Compile frills π how much to adjust the computed character width by, to control your overall letter spacing. Negative values tighten the letters up, positive values spread them out more. Perfect for working around weird font metrics; resourceletterSpace.-tntermname β sets the terminal type name that goes into theTERMenvironment variable. Heads up: this terminal type has to actually exist in thetermcap(5)database and should haveli#andco#entries; resourcetermName.-ecommand [arguments] β runs the command plus its command-line arguments inside the urxvt window. It also sets the window title and icon name to the basename of the program being executed, but only if neither-title(-T) nor-nwere given on the command line. If you use this option it has to be the last thing on the command line, periodt. If there's no-eat all, the default is to run whatever theSHELLenvironment variable says, or if that fails,sh(1).
okay bestie this part trips everyone up: you must specify a program with arguments. If you want to run shell commands you have to name the shell explicitly, like this:
urxvt -e sh -c "shell commands"
-titletext β the window title (-Tis still respected, don't worry); the default title is the basename of the program specified after-e, if there is one, otherwise it's the application name; resourcetitle.-ntext β the icon name; the default name is the basename of the program given after-e, if any, otherwise the application name; resourceiconName.-Cβ Capture system console messages π-ptstyle β Compile XIM π¦ the input style for the input method; one ofOverTheSpot,OffTheSpot,Root; resourcepreeditType.
Also, if the perl extension xim-onthespot is in play (and that's the default, fyi), then you additionally get the OnTheSpot preedit type available.
-imtext β Compile XIM πΈ input method name. resourceinputMethod.-imlocalestring β the locale used for opening the IM. The vibe here is that you can use anLC_CTYPEof e.g.de_DE.UTF-8for normal text processing butja_JP.EUC-JPfor the input extension, so you can input japanese characters while staying in another locale. resourceimLocale.-imfontfontset β set the font set used for the X Input Method; see the resourceimFontfor more info.-tcwβ changes the meaning of triple-click selection with the left mouse button. Only does anything when the original (non-perl) selection code is in-use. Instead of selecting a full line, it extends the selection to the end of the logical line only. resourcetripleclickwords.-dpb|+dpbβ Compile frills π disables (or enables) emitting bracketed paste mode sequences (default is enabled). Bracketed paste mode is what lets programs detect when something got pasted. But since more and more programs abuse it π you can turn these sequences off. The command sequences to enable and query paste mode will still work, but the actual bracket sequences will no longer be emitted. You can also toggle this from the ctrl-middle-mouse-button menu; resourcedisablePasteBrackets.-insecureβ enables "insecure" mode, which currently enables most of the escape sequences that echo strings. See the resourceinsecurefor more info.-modmodifier β overrides detection of the Meta modifier with the specified key:alt,meta,hyper,super,mod1,mod2,mod3,mod4,mod5; resourcemodifier.-ssc|+sscβ turn on/off secondary screen (default enabled); resourcesecondaryScreen.-ssr|+ssrβ turn on/off secondary screen scroll (default enabled); resourcesecondaryScroll.-rmmode β Compile frills β sets long line rewrapping behaviour on window resizes to one ofauto(the default),alwaysornever. The latter two do the obvious thing;autorewraps (acts likealways) if scrollback is non-empty, and wings lines (acts likenever) otherwise; resourcerewrapMode.-hold|+holdβ turn on/off hold window after exit support. If it's enabled, urxvt will not immediately destroy its window when the program running inside it exits. Instead it waits until it gets killed or closed by the user; resourcehold.-cdpath β sets the working directory for the shell (or for the command specified via-e). The path has to be an absolute path, and it genuinely must exist or urxvt won't start; resourcechdir.-xrmstring β works just like the X Toolkit option of the same name, by adding the string as if it were specified in a resource file. Resource values specified this way take precedence over all other resource specifications.
Note that you need to use the same syntax as in the .Xdefaults file, e.g. "*.background: black". Also note that all urxvt-specific options can be specified as long-options on the commandline, so use of -xrm is mostly limited to cases where you want to specify other resources (e.g. for input methods) or for compatibility with other programs.
- *
-keysym.sym* string β remap a key symbol. See resourcekeysym. -embedwindowid β tells urxvt to embed its windows into an already-existing window, which is how applications can easily embed a terminal π«Ά
Right now, urxvt will first unmap/map the specified window, so it shouldn't be a top-level window. urxvt will also reconfigure it quite a bit, so don't expect it to keep some specific state. It's best to create an extra subwindow for urxvt and leave it alone.
The window will not be destroyed when urxvt exits.
It might be useful to know that urxvt will not close file descriptors passed to it (except for stdin/out/err, of course), so you can use file descriptors to communicate with the programs within the terminal. This works regardless of whether the -embed option was used or not.
Here's a short Gtk2-perl snippet showing how this option can be used (a longer example lives in doc/embed):
my $rxvt = new Gtk2::Socket;
$rxvt->signal_connect_after (realize => sub {
my $xid = $_[0]->window->get_xid;
system "urxvt -embed $xid &";
});
-pty-fdfile descriptor β tells urxvt NOT to execute any commands or create a new pty/tty pair, and instead use the given file descriptor as the tty master. This is useful if you want to drive urxvt as a generic terminal emulator without having to run a program inside it.
If this switch is given, urxvt will not create any utmp/wtmp entries and will not tinker with pty/tty permissions β you have to do that yourself if you want it.
And as an extremely special case, specifying -1 will completely suppress pty/tty operations, which is probably only useful in conjunction with some perl extension that manages the terminal.
Here's an example in perl illustrating how this option can be used (a longer example is in doc/pty-fd):
use IO::Pty;
use Fcntl;
my $pty = new IO::Pty;
fcntl $pty, F_SETFD, 0; # clear close-on-exec
system "urxvt -pty-fd " . (fileno $pty) . "&";
close $pty;
# now communicate with rxvt
my $slave = $pty->slave;
while (<$slave>) { print $slave "got <$_>\n" }
Note that, despite what the name might imply, the file descriptor does not need to be a pty β it can be a bi-directional pipe as well (e.g. a unix domain or tcp socket). While tty operations cannot be done in this case, urxvt can still be remote controlled with it:
use Socket;
use Fcntl;
socketpair my $URXVT, my $slave, Socket::AF_UNIX, Socket::SOCK_STREAM, Socket::PF_UNSPEC;
fcntl $slave, Fcntl::F_SETFD, 0;
system "exec urxvt -pty-fd " . (fileno $slave) . " &";
close $slave;
syswrite $URXVT, "Type a secret password: ";
my $secret = do { local $/ = "\r"; <$URXVT> };
print "Not so secret anymore: $secret\n";
-pestring β a comma-separated list of perl extension scripts to use (or not to use) in this terminal instance. See resourceperl-extfor the details.
π RESOURCES π
Quick note before we dive in: urxvt --help hands you a list of all the resources (long options) compiled into your particular version. And every single resource is also available as a long-option. iykyk π
You can set and change the resources using X11 tools like xrdb. A lot of distributions also load settings from the ~/.Xresources file when X starts up. urxvt consults the following files/resources in order, with later settings overwriting earlier ones:
- app-defaults file in
$XAPPLRESDIR $HOME/.XdefaultsRESOURCE_MANAGERproperty on root-window of screen 0SCREEN_RESOURCESproperty on root-window of the current screen$XENVIRONMENTfile OR$HOME/.Xdefaults-<nodename>- resources specified via
-xrmon the commandline
Also fyi, when reading X resources, urxvt recognizes two class names: Rxvt and URxvt. The class name Rxvt lets resources common to both urxvt and the original rxvt be easily configured, while the class name URxvt lets resources unique to urxvt be shared between different urxvt configurations. If no resources are specified, suitable defaults will be used. Command-line arguments can be used to override resource settings. The following resources are supported (you might want to check the urxvtperl(3) manpage for additional settings by perl extensions that aren't documented here):
depth: bitdepth β Compile xft π attempt to find a visual with the given bit depth; option-depth.buffered: boolean β Compile xft β¨ turn on/off double-buffering for xft (default enabled). On some card/driver combinations enabling it slightly decreases performance, but on most it greatly helps it. The slowdown is small, so it should normally be enabled.geometry: geom β creates the window with the specified X window geometry [default80x24]; option-geometry.background:colour β sets the window's background colour, no cap β¨ [defaultWhite]; CLI twin is-bg.foreground:colour β and this one sets the window's foreground colour, the main character of your text π [defaultBlack]; CLI twin is-fg.colorn:colour β use the specified colour as the value of colour n, where0-7is giving low-intensity (normal) colours and8-15is giving high-intensity ones (bold = bright foreground, blink = bright background) π. The canonical names go like this:0=black,1=red,2=green,3=yellow,4=blue,5=magenta,6=cyan,7=whiteβ but the actual colour names that get used are listed down in the COLOURS AND GRAPHICS section, iykyk.
Colours higher than 15 cannot be set using resources (yet, bestie, yet), but they can be changed with an escape command (see urxvt(7)) π¦.
Colours 16-79 form a standard 4x4x4 colour cube (the exact same one xterm has with 88 colour support). Colours 80-87 are evenly spaced grey steps. π
colorBD:colourcolorIT:colour
These two go together fr β use the specified colour to display bold or italic characters when the foreground colour is the default. If font styles aren't available (Compile styles) and this option is unset, reverse video gets used instead. π
(Also: because of a bug in the X resource manager, it's not always possible to override values given on the command line via resources.)
colorUL:colour β use the specified colour to display underlined characters when the foreground colour is the default βοΈ.underlineColor:colour β if set, this is the colour of the underline itself. If it's unset, the foreground colour gets used instead.highlightColor:colour β if set, use it as the background for highlighted characters. If unset, reverse video takes over π«.highlightTextColor:colour β if this is set andhighlightColoris set, use it as the foreground for highlighted characters.cursorColor:colour β the cursor's colour π. Default is to just use the foreground colour; CLI twin is-cr.cursorColor2:colour β the colour of the cursor text π. For this to actually take effect,cursorColorhas to be specified too. Default is the background colour.reverseVideo:boolean βTrue: simulate reverse video by swapping foreground and background colours; CLI twin-rv.False: regular screen colours, and that's the default; CLI twin+rv. Go read the note in the COLOURS AND GRAPHICS section, bestie, it matters.jumpScroll:boolean βTrue: use jump scrolling. When lots of lines come in, urxvt only scrolls once a whole screen height of lines has been read, which means fewer updates while still displaying every single received line π; CLI twin-j.
False: use smooth scrolling instead β urxvt forces a screen refresh on each new line it receives; CLI twin +j.
skipScroll:boolean βTrue(the default): use skip scrolling. When lots of lines come in, urxvt only scrolls once in a while (around60times per second), which means far fewer updates π₯. Lowkey the trade-off is that urxvt might never display some of the lines it receives; CLI twin-ss.
False: everything gets displayed, even if the refresh is too fast for the human eye to read anything (or for the monitor to even display anything); CLI twin +ss.
refreshRate:number βCompile frills: when it's positive, this sets the maximum refreshes per second (the default is60) β±οΈ. When it's zero or negative, it sets the minimum interval between refreshes, negated. So like: positive numbers limit the refreshes per second to that number, basically an fps limiter in a game. A negative number gets negated and directly sets the minimum interval between refreshes β meaning10and-0.1both specify the same refresh interval (and likewise50and0.02). And finally,0makes urxvt refresh as fast as it possibly can π. Fractional values are supported; CLI twin is-fps.fading:number β fade the text by the given percentage when focus is lost π«₯; CLI twin-fade.fadeColor:colour β fade to this colour when fading is used (seefading:). Default colour is black; CLI twin-fadecolor.iconFile:file β set the application icon pixmap πΌοΈ; CLI twin-icon.scrollColor:colour β the scrollbar's colour [default#B2B2B2].troughColor:colour β the colour of the scrollbar's trough area [default#969696]. Only relevant for the rxvt (non XTerm/NeXT) scrollbar, just so you know.borderColor:colour β the colour of the border around the text area, and between the scrollbar and the text β¨.font:fontlist β pick the fonts to use π¨. This is a comma separated list of font names that get checked in order when urxvt is trying to find glyphs for characters. The first font defines the cell size for characters; other fonts can be smaller, but (in general) not larger. A (hopefully) reasonable default font list is always appended to it; CLI twin-fn.
Each font can either be a standard X11 core font (XLFD) name, with an optional x: prefix, or an Xft font (Compile xft), prefixed with xft:.
On top of that, each font can be prefixed with extra hints and specifications wrapped in square brackets ([]). The only hint available right now is codeset=codeset-name, and it's only used for Xft fonts.
For example, this font resource:
URxvt.font: 9x15bold,\
-misc-fixed-bold-r-normal--15-140-75-75-c-90-iso10646-1,\
-misc-fixed-medium-r-normal--15-140-75-75-c-90-iso10646-1, \
[codeset=JISX0208]xft:Kochi Gothic:antialias=false, \
xft:Code2000:antialias=false
specifies five fonts to be used ποΈ. The first one is 9x15bold (which is actually the iso8859-1 version of the second font), and it's the base font β because it's named first β so it defines the character cell grid to be 9 pixels wide and 15 pixels high.
The second font is just there to add extra unicode characters that aren't in the base font, and likewise the third β which is unfortunately non-bold, but the bold version of that font contains fewer characters, so this is a genuinely useful supplement π.
The third font is an Xft font with aliasing turned off, and its characters are limited to the JIS 0208 codeset (i.e. japanese kanji). The font contains other characters, but we are simply not interested in them π .
The last font is a useful catch-all font that supplies most of the remaining unicode characters. Iconic.
boldFont:fontlistitalicFont:fontlistboldItalicFont:fontlist
The font list to use for displaying bold, italic or bold italic characters, respectively.
If specified and non-empty, the syntax is the same as for the font resource, and the given font list gets used as-is, which means you can substitute completely different font styles for bold and italic π.
If unset (the default), a suitable font list gets synthesized by "morphing" the normal text font list into the desired shape. If that's not possible, replacement fonts of the desired shape get tried.
If set but empty, then that specific style is disabled and the normal text font gets used for that style instead. π
intensityStyles:boolean β when font styles aren't enabled, or when this option is enabled (True, CLI twin-is, and yes that's the default), bold/blink font styles imply high intensity foreground/background colours π₯. Disabling it (False, CLI twin+is) disables that behaviour β and then the high intensity colours are simply not reachable. Periodt.title:string β set the window title string π. The default title is the command-line specified after the-eoption, if there is one; otherwise it's the application name. CLI twin-title.iconName:string β set the name used to label the window's icon or displayed in an icon manager window. It also sets the window's title unless that was explicitly set; CLI twin-n.mapAlert:boolean βTrue: de-iconify (map) on receipt of a bell character π.False: no de-iconify (map) on receipt of a bell character, and that's the default.urgentOnBell:boolean βTrue: set the urgency hint for the wm on receipt of a bell character.False: don't set the urgency hint, which is the default.
urxvt resets the urgency hint on every focus change, fyi π«Ά.
visualBell:boolean βTrue: use a visual bell on receipt of a bell character; CLI twin-vb.False: no visual bell, and that's the default; CLI twin+vb.loginShell:boolean βTrue: start as a login shell by prepending a`-toargv[0]of the shell; CLI twin-ls.False: start as a normal sub-shell, which is the default; CLI twin+ls.multiClickTime:number β the maximum time in milliseconds between multi-click select events π±οΈ. Default is500milliseconds; CLI twin-mc.utmpInhibit:boolean βTrue: inhibit writing the record into the system log fileutmp; CLI twin-ut.False: write the record into the system log fileutmp, which is the default; CLI twin+ut.print-pipe:string β specify a command pipe for the vt100 printer π¨οΈ [defaultlpr(1)]. UsePrintto start a screen dump to the printer, andCtrl-PrintorShift-Printto include the scrollback as well.
The string gets interpreted as if it was typed into the shell as-is.
Example:
URxvt.print-pipe: cat > $(TMPDIR=$HOME mktemp urxvt.XXXXXX)
This creates a new file in your home directory with the screen contents every single time you hit Print. Obsessed, honestly.
scrollstyle:mode β set the scrollbar style torxvt,plain,nextorxterm.plainis the author's favourite π.thickness:number β set the scrollbar width in pixels.scrollBar:boolean βTrue: enable the scrollbar, which is the default; CLI twin-sb.False: disable the scrollbar; CLI twin+sb.scrollBar_right:boolean βTrue: put the scrollbar on the right of the window; CLI twin-sr.False: put the scrollbar on the left of the window; CLI twin+sr.scrollBar_floating:boolean βTrue: display an rxvt scrollbar with no trough; CLI twin-st.False: display an rxvt scrollbar with a trough; CLI twin+st.scrollBar_align:mode β align the top, bottom or centre [default] of the scrollbar thumb with the pointer on middle button press/drag π.scrollTtyOutput:boolean βTrue: scroll to bottom when the tty receives output; CLI twin-si.False: don't scroll to bottom when the tty receives output; CLI twin+si.scrollWithBuffer:boolean βTrue: scroll with the scrollback buffer when the tty receives new lines (i.e. try to show the same lines) andscrollTtyOutputisFalse; CLI twin-sw.False: don't scroll with the scrollback buffer when the tty receives new lines; CLI twin+sw.
scrollTtyKeypress: boolean
- True: the second you hit a non-special key, we scroll allll the way to the bottom. "Special keys" = the ones rxvt-unicode snatches up for its own special handling and never passes on to the shell. π option
-sk. - False: nah, don't scroll to the bottom on a non-special keypress. π option
+sk.
saveLines: number
Saves number lines in the scrollback buffer. [default 1000] π option -sl.
internalBorder: number
An internal border of number pixels. This resource is capped at 100. π option -b.
externalBorder: number
An external border of number pixels. Also capped at 100. π option -w, -bw, -borderwidth.
borderLess: boolean
Sets MWM hints asking for a borderless window β so if your WM is nice enough to honor it, the rxvt-unicode window shows up with zero window decorations. πͺβ¨ π option -bl.
skipBuiltinGlyphs: boolean
Compile frills: turns OFF the built-in block graphics / line drawing characters and just trusts whatever your fonts actually provide. Use this when you've got a gorgeous font and you want its block glyphs instead. π option -sbg.
termName: termname
Sets the terminal type name that goes into the TERM environment variable. π option -tn.
lineSpace: number
How many lines (measured in pixel height) to shove in between each row of the display. [default 0] π option -lsp.
meta8: boolean
- True: Meta (Alt) + keypress sets the 8th bit.
- False: Meta (Alt) + keypress gets handled as an escape prefix. [default]
mouseWheelScrollPage: boolean
- True: mouse wheel scrolls a whole page at a time.
- False: mouse wheel scrolls five lines. [default]
pastableTabs: boolean
- True: tabs get stored as wide characters.
- False: tabs are interpreted as cursor movement only. π option
-ptab.
cursorBlink: boolean
- True: blink that cursor, bestie. β¨
- False: no blinking. [default] π option
-bc.
cursorUnderline: boolean
- True: cursor is underlined.
- False: cursor is a box. [default] π option
-uc.
pointerBlank: boolean
- True: blank the pointer whenever a key is pressed, or after a set number of seconds of doing absolutely nothing. π€
- False: pointer stays visible forever. [default]
pointerColor: colour
Mouse pointer foreground colour. π¨
pointerColor2: colour
Mouse pointer background colour. π¨
pointerShape: string
Compile frills: sets the name of the mouse pointer shape. [default xterm] Wanna know the possible values? Go look at the macros in the X11/cursorfont.h include file and drop the "XC_" prefix, okay? π±οΈ
pointerBlankDelay: number
How many seconds to wait before blanking the pointer. [default 2] Pro tip from the manpage itself: use a giant number (like 987654321) to effectively kill the timeout entirely. π
backspacekey: string
The string sent when the backspace key is pressed. If it's set to DEC, or if it's just unset, it sends Delete (code 127) or, with control, Backspace (code 8) β and you can flip that around again with the appropriate DEC private mode escape sequence. π
deletekey: string
The string sent when the delete key is pressed (and not the keypad delete key). If unset, it sends the sequence traditionally associated with the Execute key.
cutchars: string
The characters used as delimiters for double-click word selection. (Whitespace delimiting gets added automatically if this resource is given.)
When the perl selection extension is in play (which is the default if it was compiled in β see the urxvtperl(3) manpage), a suitable regex using these characters gets created, if the resource exists β otherwise no regex is created at all. In this mode you can also use characters outside ISO-8859-1. π
When the selection extension is not used, only ISO-8859-1 characters are allowed. If you never specify anything, the built-in default is what you get:
BACKSLASH `"'&()*,;<=>?@[]^{|}
preeditType: style
OnTheSpot, OverTheSpot, OffTheSpot, Root. π option -pt.
inputMethod: name
The name of the inputMethod to use. π option -im.
imLocale: name
The locale to use for opening the IM. You can set an "LC_CTYPE" of e.g. "de_DE.UTF-8" for normal text processing while using "ja_JP.EUC-JP" for the input extension β so you can type Japanese characters and still stay in a whole other locale. iconic. π option -imlocale.
imFont: fontset
Specifies the font-set used for XIM styles "OverTheSpot" or "OffTheSpot". Heads up: this has to be a standard X font set (XLFD patterns separated by commas) β meaning it's not in the same format as the other font lists used in urxvt. The default gets set up to choose any suitable font found, preferably one or two pixels different in size from the base font. π option -imfont.
tripleclickwords: boolean
Changes what triple-click selection with the left mouse button means. Instead of selecting the whole entire line, it extends the selection to the end of the logical line only. π option -tcw.
disablePasteBrackets: boolean
Prevents emission of paste bracket sequences. π option -dpb.
insecure: boolean
Enables "insecure" mode. π Okay so here's the tea: rxvt-unicode offers some escape sequences that echo arbitrary strings β like the icon name or the locale. That could absolutely be abused if somebody gets 8-bit-clean access to your display, whether that's through a mail client showing you unfiltered mail bodies, through write(1), or literally any other means. So these sequences are disabled by default for your own good.
(And yeah, note that tons of other terminals β xterm included β have these sequences enabled by default. Which does not make it any safer. π)
You can enable them by setting this boolean resource or by passing -insecure as an option. As of right now, turning this on enables: display-answer, locale, findfont, icon label and window title requests.
modifier: modifier
Sets which key gets interpreted as the Meta key. Your options are: alt, meta, hyper, super, mod1, mod2, mod3, mod4, mod5. π option -mod.
answerbackString: string
The reply rxvt-unicode sends to the shell when an ENQ (control-E) character is passed through. It may contain escape values, as described in the entry on keysym below. π¨
secondaryScreen: boolean
Turns the secondary screen on/off. (Default is enabled.)
rewrapMode: mode
Sets the long line rewrap behaviour on window resize to one of auto (default), always or never.
secondaryScroll: boolean
Turns the secondary screen scroll on/off. (Default is enabled.) If this option is enabled, scrolling on the secondary screen will change the scrollback buffer, and β when secondaryScreen is off β switching to/from the secondary screen will instead scroll the screen up.
hold: boolean
Turns hold-window-after-exit support on/off. If enabled, urxvt won't immediately destroy its window when the program running inside it exits. Instead it waits until it gets killed or closed by the user. π«Ά
chdir: path
Sets the working directory for the shell (or for whatever command you specified via -e). The path has to be an absolute path, and it has to actually exist for urxvt to start at all. If you don't specify one, the current working directory is used. π option -cd.
keysym.sym: action
Compile frills: associates action with keysym sym. The intervening resource name keysym. is not omittable β you need it, bestie. β
With this resource you can map key combinations like "Ctrl-Shift-BackSpace" to all sorts of actions β like outputting a totally different string than that combo would normally give you, making the terminal scroll up or down exactly how you want, or literally anything else an extension might offer. π
The key combination that triggers the action, sym, has this format:
(modifiers-)key
Where modifiers can be any combination of these full or abbreviated modifier names:
ISOLevel3βIAppKeypadβKControlβCNumLockβNShiftβSMetaβMorALockβLMod1β1Mod2β2Mod3β3Mod4β4Mod5β5
The NumLock, Meta and ISOLevel3 modifiers are usually aliased to whatever modifier the NumLock key, Meta/Alt keys or ISO Level3 Shift/AltGr keys are mapped to. AppKeypad is a synthetic modifier mapped to the current application keymap mode state.
Because there are, like, a huge number of modifier combos, a key mapping matches if at least the specified identifiers are set, and no other key mappings with those and more bits are defined. What that means: defining a mapping for "a" automatically gives you definitions for "Meta-a", "Shift-a" and so on β unless some of those are defined mappings themselves. See the "builtin:" action below for a way to work around this when it's a problem. π§ β¨
How you spell key depends on your X implementation. The easy way to find a key name is to use the xev(1) command. You can also find a whole list by looking for the "XK_" macros in the X11/keysymdef.h include file (again, omit the "XK_" prefix). Or, alternatively, you can specify key by its hex keysym value (0x0000 - 0xFFFF).
Just like with any resource value, the action string can contain backslash escape sequences ("\n": newline, "\\": backslash, "\000": octal number). See RESOURCES in man 7 X for further deets.
An action starts with an action prefix that picks out a certain type of action, followed by a colon. An action string with no colons in it is interpreted as a literal string to pass to the tty (exactly as if it were prefixed with "string:").
Here are the action prefixes we know about β extensions can provide extra prefixes, so stay tuned:
string:STRINGβ If the action starts with"string:"(or otherwise contains no colons), then the remaining"STRING"gets passed to the program running inside the terminal. For example, you could replace whatever Shift-Tab outputs with the string"echo rm -rf /"followed by a newline:
URxvt.keysym.Shift-Tab: string:echo rm -rf /\n
In theory, this could be used to completely redefine your entire keymap. π³
On top of that, for actions of this type you can define a range of keysyms all in one shot by loading the "keysym-list" perl extension and providing an action with the pattern list/PREFIX/MIDDLE/SUFFIX, where the delimiter / should be a character that the strings themselves don't use.
Its usage can be demonstrated with an example:
URxvt.keysym.M-C-0x61: list|\033<|abc|>
The above line is equivalent to the following three lines:
URxvt.keysym.Meta-Control-0x61: string:\033<a>
URxvt.keysym.Meta-Control-0x62: string:\033<b>
URxvt.keysym.Meta-Control-0x63: string:\033<c>
command:STRING
So when your action looks like command:STRING, that STRING gets interpreted and executed as urxvt's own control sequence. Basically it's the exact opposite of string: β instead of yeeting it off to whatever program is running inside the terminal, urxvt treats it like the program itself spat it out. Peak useful for feeding command sequences straight into urxvt π
Like, this one means "change the current locale to zh_CN.GBK when Control-Meta-c is being pressed":
URxvt.keysym.M-C-c: command:\033]701;zh_CN.GBK\007
And this one maps Control-Meta-1 and Control-Meta-2 to the fonts suxuseuro and 9x15bold, so you get some limited font-switching at runtime:
URxvt.keysym.M-C-1: command:\033]50;suxuseuro\007
URxvt.keysym.M-C-2: command:\033]50;9x15bold\007
Other things are possible too, like resizing (see urxvt(7) for the deets):
URxvt.keysym.M-C-3: command:\033[8;25;80t
URxvt.keysym.M-C-4: command:\033[8;48;110t
builtin:
builtin: is literally the action urxvt would have executed if no key binding existed for that key combo. Obvious use: undo a binding you set up. Not-so-obvious use: put bindings back when some other binding gobbled up too many modifiers π«Ά
Say you overwrite the Insert key β congrats, you just disabled urxvt's Shift-Insert mapping π. To re-enable it, you poke "holes" into your user-defined keymap with the builtin: replacement:
URxvt.keysym.Insert: <my insert key sequence>
URxvt.keysym.S-Insert: builtin:
Line one defines a mapping for Insert and any combination of modifiers. Line two re-establishes the default mapping for Shift-Insert. Chef's kiss π
builtin-string:
This one is mainly for restoring string mappings on keys that have predefined actions in urxvt. The exact semantics are, ngl, a little hard to explain β basically it sends the string to the application that would've been sent if urxvt didn't have a built-in action for that key.
An example clears it up way better: urxvt normally pastes the selection when you press Shift-Insert. With these bindings, it instead emits the (undocumented, but what applications running in the terminal might expect) sequence ESC [ 2 $:
URxvt.keysym.S-Insert: builtin-string:
URxvt.keysym.C-S-Insert: builtin:
So line one kills the paste functionality for that key combo, and line two reinstates the default behaviour for Control-Shift-Insert, which would've been overridden otherwise.
Same energy for letting apps get at the C-M-c (copy to clipboard) and C-M-v (paste clipboard) combos:
URxvt.keysym.C-M-c: builtin-string:
URxvt.keysym.C-M-v: builtin-string:
EXTENSION:STRING
An action shaped like this invokes the action STRING β if there is one β provided by the urxvtperl(3) extension EXTENSION. The extension gets loaded automatically if it needs to be.
Not every extension defines actions, but the popular ones that do include the selection and matcher extensions (documented in their own manpages, urxvt-selection(1) and urxvt-matcher(1), respectively).
From the silly examples department: this rot13-"encrypts" urxvt's selection when Alt-Control-c is pressed on typical PC keyboards:
URxvt.keysym.M-C-c: selection:rot13
perl:STRING DEPRECATED
This is a deprecated way of invoking commands provided by perl extensions. It still works, but bestie, please don't use it anymore π
perl-ext-common: string,perl-ext: stringβ comma-separated list(s) of perl extension scripts (default:default) to use in this terminal instance; option-pe.
Extension names can take a - prefix to remove them again, in case they were specified earlier β super handy for selectively disabling some extensions that got loaded by default, or that came in via the perl-ext-common resource. So default,-selection uses all the default extensions except selection.
To prohibit autoloading of extensions, prefix them with /, which makes urxvt refuse to automatically load them (this can be overridden by specifying the extension name again without the prefix, though). It doesn't stop extensions from loading other extensions themselves. Like, default,/background keeps the background extension from being loaded when a background OSC sequence shows up.
The default set includes the selection, option-popup, selection-popup, readline, searchable-scrollback and confirm-paste extensions, plus any extensions mentioned in keysym resources.
Any extension with a corresponding resource given on the command line gets automatically appended to perl-ext.
Each extension is looked up in the library directories, loaded if necessary, and bound to the current terminal instance. When the library search path has multiple extension files with the same name, the first one found wins.
If both of these resources are the empty string, the perl interpreter just... never gets initialized. The reason there are two options is that perl-ext-common handles extensions that should be available to all instances, while perl-ext is for specific instances π§
perl-eval: stringβ perl code to be evaluated when all extensions have been registered. See theurxvtperl(3)manpage.perl-lib: pathβ colon-separated list of additional directories that hold extension scripts. When hunting for perl extensions, urxvt looks in these directories first, then$URXVT_PERL_LIB, then$HOME/.urxvt/ext, and lastly/usr/lib/x86_64-linux-gnu/urxvt/perl/.
See the urxvtperl(3) manpage.
selection.pattern-idx: perl-regexβ additional selection patterns, see theurxvtperl(3)manpage for details.selection-autotransform.idx: perl-transformβ selection auto-transform patterns, see theurxvtperl(3)manpage for details.searchable-scrollback: keysymDEPRECATED β this resource is deprecated and will be removed. Use a keysym resource instead, e.g.:
URxvt.keysym.M-s: searchable-scrollback:start
url-launcher: stringβ specifies the program to be started with a URL argument. Used by theselection-popupandmatcherperl extensions.transient-for: windowidβ Compile frills: sets theWM_TRANSIENT_FORproperty to the given window id.override-redirect: booleanβ Compile frills: sets override-redirect for the terminal window, making it almost invisible to window managers; option-override-redirect.iso14755: booleanβ turn on/off ISO 14755 (default enabled).iso14755_52: booleanβ turn on/off ISO 14755 5.2 mode (default enabled).
π THE SCROLLBAR π
Lines of text that scroll off the top of the urxvt window (resource: saveLines) and can be scrolled back using the scrollbar or by keystrokes. The normal urxvt scrollbar has arrows and its behaviour is fairly intuitive. The xterm-scrollbar is without arrows and its behaviour mimics that of xterm.
Scroll down with Button1 (xterm-scrollbar) or Shift-Next. Scroll up with Button3 (xterm-scrollbar) or Shift-Prior. Continuous scroll with Button2. β¨
π±οΈ MOUSE REPORTING π±οΈ
To temporarily override mouse reporting β for either the scrollbar or the normal text selection/insertion β hold either the Shift or the Meta (Alt) key while performing the desired mouse action.
If mouse reporting mode is active, the normal scrollbar actions are disabled β on the assumption that we are using a fullscreen application π. Instead, pressing Button1 and Button3 sends ESC [ 6 ~ (Next) and ESC [ 5 ~ (Prior), respectively. Similarly, clicking on the up and down arrows sends ESC [ A (Up) and ESC [ B (Down), respectively.
π THE SELECTION: SELECTING AND PASTING TEXT π
The behaviour of text selection and insertion/pasting mechanism is similar to xterm(1).
Selecting:
- Left click at the beginning of the region, drag to the end of the region and release; Right click to extend the marked region; Left double-click to select a word; Left triple-click to select the entire logical line (which can span multiple screen lines), unless modified by resource
tripleclickwords. - Starting a selection while pressing the Meta key (or Meta+Ctrl keys) (Compile: frills) will create a rectangular selection instead of a normal one. In this mode, every selected row becomes its own line in the selection, and trailing whitespace is visually underlined and removed from the selection.
Pasting:
- Pressing and releasing the Middle mouse button in an urxvt window causes the value of the PRIMARY selection (or CLIPBOARD with the Meta modifier) to be inserted as if it had been typed on the keyboard.
- Pressing Shift-Insert causes the value of the PRIMARY selection to be inserted too.
- rxvt-unicode also provides the bindings Ctrl-Meta-c and
<Ctrl-Meta-v>to interact with the CLIPBOARD selection. The first binding causes the value of the internal selection to be copied to the CLIPBOARD selection, while the second binding causes the value of the CLIPBOARD selection to be inserted. π«Ά
π CHANGING FONTS π
Changing fonts (or font sizes, respectively) via the keypad is not yet supported in rxvt-unicode. Bug me if you need this π
You can, however, switch fonts at runtime using escape sequences, e.g.:
printf '\e]710;%s\007' "9x15bold,xft:Kochi Gothic"
You can use keyboard shortcuts, too:
URxvt.keysym.M-C-1: command:\033]710;suxuseuro\007\033]711;suxuseuro\007
URxvt.keysym.M-C-2: command:\033]710;9x15bold\007\033]711;9x15bold\007
rxvt-unicode will automatically re-apply these fonts to the output so far. π
π ISO 14755 SUPPORT π
okay so ISO 14755 is the standard for typing in and looking at unicode characters and character codes from your keyboard, and it's got 4 parts bestie. The first part is only available if rxvt-unicode was compiled with --enable-frills, and the rest of them show up when rxvt-unicode was compiled with --enable-iso14755. π
- 5.1: Basic method β this one lets you type unicode characters by their hexcode. Press and hold both Control and Shift, then type hex-digits (between one and six of them). Let go of Control and Shift and boom, the character gets committed like you typed it directly. And while you're still holding Control and Shift you can also enter multiple characters by pressing Space, which commits the current character and lets you start a fresh one. β¨
so like, imagine a business card with a japanese e-mail address on it that you literally cannot type. good news, the card has the e-mail address printed as hexcodes, e.g. 671d 65e5. You can enter this easily by pressing Control and Shift, followed by 6-7-1-D-SPACE-6-5-E-5, followed by releasing the modifier keys. iconic behavior honestly π«Ά
- 5.2: Keyboard symbols entry method β this mode lets you input characters representing the keycap symbols of your keyboard, if they're representable in the current locale encoding. Start by pressing Control and Shift together, then releasing them. The next special key (cursor keys, home etc.) you enter will not invoke its usual function β instead it'll insert the corresponding keycap symbol. Heads up though: the symbol is only entered when the key has been released, otherwise pressing e.g. Shift would enter the symbol for
ISO Level 2 Switch, even though your intention might have been to enter a reverse tab (Shift-Tab). π - 5.3: Screen-selection entry method β while this is implemented already (it's basically the selection mechanism), it could be extended by displaying a unicode character map. so she's there, she's just waiting on her glow-up β¨
- 5.4: Feedback method for identifying displayed characters for later input β this method lets you display the unicode character code associated with characters already displayed. You enter this mode by holding down Control and Shift together, then pressing and holding the left mouse button and moving around. The unicode hex code(s) (it might be a combining character) of the character under the pointer is displayed until you release Control and Shift. On top of the hex codes it'll also display the font used to draw this character β and due to implementation reasons, characters combined with combining characters, line drawing characters and unknown characters will always be drawn using the built-in support font. no cap π
With respect to conformance, rxvt-unicode is supposed to be compliant to both scenario A and B of ISO 14755, including part 5.2. slay, standards-compliant queen π
π LOGIN STAMP π
urxvt tries to write an entry into the utmp(5) file so that it can be seen via the who(1) command, and so it can accept messages. To allow this feature, urxvt may need to be installed setuid root on some systems, or setgid to root or to some other group on others. it's giving "permissions are the drama" π
π COLOURS AND GRAPHICS π
On top of the default foreground and background colours, urxvt can display up to 88/256 colours: 8 ANSI colours plus high-intensity (potentially bold/blink) versions of the same, and 72 (or 240 in 256 colour mode) colours arranged in a 4x4x4 (or 6x6x6) colour RGB cube plus a 8 (24) colour greyscale ramp. the palette is rich bestie π¨
urxvt supports direct 24-bit fg/bg RGB colour escapes ESC [ 38 ; 2 ; R ; G ; Bm / ESC [ 48 ; 2; R ; G ; Bm. However the number of 24-bit colours that can be used is limited: an internal 7x7x5 (256 colour mode) or 6x6x4 (88 colour mode) colour cube is used to index into the 24-bit colour space. When indexing collisions happen, the nearest old colour in the cube will be adapted to the new 24-bit RGB colour. That means you can't use many similar 24-bit colours. It's typically not a problem in common scenarios though, so breathe πΈ
Here's the list of the ANSI colours with their names, verbatim, don't @ me:
color0 (black) = Black
color1 (red) = Red3
color2 (green) = Green3
color3 (yellow) = Yellow3
color4 (blue) = Blue3
color5 (magenta) = Magenta3
color6 (cyan) = Cyan3
color7 (white) = AntiqueWhite
color8 (bright black) = Grey25
color9 (bright red) = Red
color10 (bright green) = Green
color11 (bright yellow) = Yellow
color12 (bright blue) = Blue
color13 (bright magenta) = Magenta
color14 (bright cyan) = Cyan
color15 (bright white) = White
foreground = Black
background = White
It is also possible to specify the colour values of foreground, background, cursorColor, cursorColor2, colorBD, colorUL as a number 0-15, as a convenient shorthand to reference the colour name of color0-color15. cute shortcut, love that for us π
The following text gives values for the standard 88 colour mode (and values for the 256 colour mode in parentheses).
The RGB cube uses indices 16..79 (16..231) using the following formulas:
index_88 = (r * 4 + g) * 4 + b + 16 # r, g, b = 0..3
index_256 = (r * 6 + g) * 6 + b + 16 # r, g, b = 0..5
The grayscale ramp uses indices 80..87 (232..239), from 10% to 90% in 10% steps (1/26 to 25/26 in 1/26 steps) β black and white are already part of the RGB cube, so they didn't need an invite. β¨
Together, all those colours implement the 88 (256) colour xterm colours. Only the first 16 can be changed using resources currently, the rest can only be changed via command sequences ("escape codes"). sorry bestie, that's just the rules π€·
Applications are advised to use terminfo or command sequences to discover number and RGB values of all colours (yes, you can query this...). π
Note that -rv (reverseVideo: True) simulates reverse video by always swapping the foreground/background colours. This is in contrast to xterm(1) where the colours are only swapped if they have not otherwise been specified. For example:
urxvt -fg Black -bg White -rv
would yield White on Black, while on xterm(1) it would yield Black on White. not her being different on purpose π
π¦ ALPHA CHANNEL SUPPORT π¦
If Xft support has been compiled in and as long as Xft/Xrender/X don't get their act together, rxvt-unicode will do its own alpha channel management. she's handling it herself, she's independent like that π
You can prefix any colour with an opaqueness percentage enclosed in brackets, i.e. [percent], where percent is a decimal percentage (0-100) that specifies the opacity of the colour, where 0 is completely transparent and 100 is completely opaque. So for example, [50]red is a half-transparent red, while [95]#00ff00 is an almost opaque green. This is the recommended format to specify transparency values, and it works with all ways to specify a colour. π
For complete control, rxvt-unicode also supports rgba:rrrr/gggg/bbbb/aaaa (exactly four hex digits/component) colour specifications, where the additional aaaa component specifies opacity (alpha) values. The minimum value of 0000 is completely transparent, while ffff is completely opaque. The two example colours from earlier could also be specified as rgba:ff00/0000/0000/8000 and rgba:0000/ff00/0000/f332. π€
You probably need to specify -depth 32, too, to force a visual with alpha channels, and have the luck that your X-server uses ARGB pixel layout, as X is far from just supporting ARGB visuals out of the box, and rxvt-unicode just fudges around. yeah. fudges around. that's the technical term fr fr π
For example, the following selects an almost completely transparent black background, and an almost opaque pink foreground:
urxvt -depth 32 -bg rgba:0000/0000/0000/4444 -fg "[80]pink"
When not using a background image, then the interpretation of the alpha channel is up to your compositing manager (most interpret it as transparency of course). π
When using a background pixmap or pseudo-transparency, then the background colour will always behave as if it were completely transparent (so the background image shows instead), regardless of how it was specified, while other colours will either be transparent as specified (the background image will show through) on servers supporting the RENDER extension, or fully opaque on servers not supporting the RENDER EXTENSION. π
Please note that due to bugs in Xft, specifying alpha values might result in garbage being displayed when the X-server does not support the RENDER extension. consider this your warning bestie π
π ENVIRONMENT π
okay so urxvt is a whole environment girlie β it sets and reads a bunch of environment variables, and here's every single one, no skips bestie π
TERMβ normally it's set to"rxvt-unicode", unless someone overwrote it at configure time, or via resources, or straight up on the command line. periodt.COLORTERMβ either"rxvt"or"rxvt-xpm", depending on whether yoururxvtwas compiled with background image support. And optionally it gets"-mono"tacked on the end to say "hey, this urxvt is running on a monochrome screen" πCOLORFGBGβ set to a string shaped like"fg;bg"or"fg;xpm;bg". Let's break it down bestie:fgis the colour code used as the default foreground/text colour β or the literal string"default"to say "use the default-colour escape sequence" β¨bgis the colour code used as the default background colour β or again the string"default"xpmis the string"default"ifurxvtwas compiled with background image support- libraries like
"ncurses"and"slang"can (and literally do) use this info to optimise screen output. icon behaviour fr fr.
WINDOWIDβ set to the (decimal) X Window ID of theurxvtwindow. That's the toplevel window btw, which usually has subwindows for the scrollbar, the terminal window, and so on πTERMINFOβ set to the terminfo directory iffurxvtwas configured with--with-terminfo=PATH. that's an "if and only if", bestie, not a suggestion πDISPLAYβurxvtuses this to connect to the display, and sets it to the correct display in its child processes if-displayisn't used to override. and if it doesn't exist at all? it defaults to":0"π¦SHELLβ the shell used for command execution. defaults to"/bin/sh"πRXVT_SOCKET[sic] β the unix domain socket path used byurxvtc(1)andurxvtd(1).- default:
$HOME/.urxvt/urxvtd-<nodename>
- default:
URXVT_PERL_LIBβ an additional:-separated library search path for perl extensions. the search order is: after-perl-lib, but before~/.urxvt/extand the system library directory. so it's the middle child, respectfully π§URXVT_PERL_VERBOSITYβ seeurxvtperl(3)for the deets.HOMEβ used to locate the default directory for the unix domain socket for daemon communications, and also to locate various resource files (like".Xdefaults") πXAPPLRESDIRβ the directory where application-specific X resource files live.XENVIRONMENTβ if it's set and accessible, it gives the name of an X resource file thaturxvtshould load. accessible is doing a lot of heavy lifting in that sentence ngl π
π FILES π
/etc/X11/rgb.txtβ colour names. that's it. that's the file. it's giving very demure, very minimal π
π SEE ALSO π
go read these too bestie, they're all part of the cinematic universe:
urxvt(7), urxvtc(1), urxvtd(1), urxvt-extensions(1), urxvtperl(3), xterm(1), sh(1), resize(1), X(1), pty(4), tty(4), utmp(5)
π CURRENT PROJECT COORDINATOR π
- Project Coordinator β Marc A. Lehmann
<rxvt-unicode@schmorp.de>.
and the project home is right here, in plain text because we keep it real:
http://software.schmorp.de/pkg/rxvt-unicode.html
π AUTHORS π
the legend roll call, every single one of them, we do not erase the lore:
- John Bovey β University of Kent, 1992, wrote the original Xvt. the OG. the blueprint. π±
- Rob Nation
<nation@rocket.sanders.lockheed.com>β very heavily modified Xvt and came up with Rxvt. "very heavily" is such a mood honestly π - Angelo Haritsis
<ah@doc.ic.ac.uk>β wrote the Greek Keyboard Input (no longer in code). rip to a real one ποΈ - mj olesen
<olesen@me.QueensU.CA>β wrote the menu system.- Project Coordinator (changes.txt 2.11 to 2.21)
- Oezguer Kesim
<kesim@math.fu-berlin.de>β Project Coordinator (changes.txt 2.21a to 2.4.5) - Geoff Wing
<gcw@pobox.com>β rewrote screen display and text selection routines.- Project Coordinator (changes.txt 2.4.6 - rxvt-unicode)
- Marc Alexander Lehmann
<rxvt-unicode@schmorp.de>β forked rxvt-unicode, unicode support, rewrote almost all the code, perl extension, random hacks, numerous bugfixes and extensions.- Project Coordinator (Changes 1.0 -)
- Emanuele Giaquinta
<emanuele.giaquinta@gmail.com>β pty/utmp code rewrite, image code improvements, many random hacks and bugfixes. king behaviour π
okay that's the WHOLE page bestie, you made it to the end, we're both so iconic for this π«Άβ¨ this one's urxvt(1), version 9.31, dated 2026-08-20 β and that's a wrap, no cap π
π
π¦ where this page comes from
- ubuntu stonking: rxvt-unicode 9.31-3build5 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms