No description
Find a file
2016-10-29 11:13:28 +02:00
.github Update CONTRIBUTING.md 2016-08-01 14:40:36 +02:00
config Option to disable/enable the highlighting of match. 2016-10-24 21:47:36 +02:00
data Issue #411: Show list of Keyboard bindings with rofi, from rofi. 2016-05-30 10:25:58 +02:00
doc Update so absolute paths are used in doxy file. 2016-10-25 21:57:09 +02:00
Examples Fix filebrowser script, Fixes #486 2016-10-23 13:49:34 +02:00
include Update some code. 2016-10-28 23:28:49 +02:00
libgwater@173f2f5566 gitmodules: Update libgwater 2016-05-30 18:25:40 +02:00
releasenotes Updated release notes 2016-08-08 18:04:57 +02:00
script Small fix for rofi-theme-selector 2016-10-29 11:13:28 +02:00
source Update some code. 2016-10-28 23:28:49 +02:00
test Make scrollbar behave better 2016-10-26 08:24:34 +02:00
themes Add darkblue as screen 2016-10-27 21:08:08 +02:00
.gitignore add scrollbar test. 2016-10-24 17:48:04 +02:00
.gitlab-ci.yml Disable gitlab test, as it get stuck. 2016-04-10 22:46:46 +02:00
.gitmodules rofi: Convert to XCB events 2016-02-21 16:04:53 +01:00
.travis.yml Fix document coverage tool. 2016-10-25 22:08:19 +02:00
AUTHORS Initialize mouse_seen. (#461) 2016-09-09 20:36:12 +02:00
Changelog Update Changelog. 2016-09-01 21:29:02 +02:00
configure.ac Issue #474: reverse logic. 2016-09-26 11:57:40 +02:00
COPYING Update copyright 2016-01-01 00:27:00 +01:00
INSTALL.md Update INSTALL. 2016-08-31 10:01:49 +02:00
libgwater-xcb-nolibtool.mk rofi: Convert to XCB events 2016-02-21 16:04:53 +01:00
Makefile.am Add 2 more themes. 2016-10-28 08:58:11 +02:00
README.md Add Coverity scan 2016-10-17 20:58:50 +02:00

Build Status codecov.io Issues Forks Stars Downloads Coverity

A window switcher, run dialog and dmenu replacement

Rofi started as clone of simpleswitcher, written by Sean Pringle a popup window switcher roughly based on superswitcher. Simpleswitcher laid the foundations and therefor Sean Pringle deserves most of the credit for this tool. Rofi, renamed as it lost the simple property, has been extended with extra features, like a run-dialog, ssh-launcher and can act as a drop-in dmenu replacement, making it a very versatile tool.

Rofi, like dmenu, will provide the user with a textual list of options where one or more can be selected. This can either be, running an application, selecting a window or options provided by an external script.

It main features are:

  • Full (configurable) keyboard navigation.
  • Type to filter
    • Tokenized: Type any word in any order to filter.
    • (toggable) Case insensitive.
    • Supports regex and glob matching.
  • UTF-8 enabled.
    • UTF-8 aware string collating.
    • intl. keyboard support (`e -> è)
  • RTL language support.
  • Cairo drawing and Pango font rendering.
  • Build in modes:
    • Window switcher mode.
      • EWMH compatible WM.
    • Run mode.
    • Desktop File Run mode.
    • SSH launcher mode.
    • Combi mode, allow several modes to be merged into one list.
  • History based ordering last 25 choices are ordered on top based on use. (optional)
  • Levenshtein distance ordering of matches. (optional)
  • Drop in dmenu replacement.
    • With many added improvements.
  • Can be easily extended using scripts.
  • Themeing.

Rofi has several buildin modes implementing common use-cases and can be exteneded by scripts (either called from Rofi or calling Rofi).

Below the different modes are listed:

Window Switcher

Window List

The window switcher shows the following informations in columns (can be customized):

  1. Desktop number
  2. Window class.
  3. Window title.

Run mode

run mode

The run mode allows users to quickly search and launch a program. Run mode features:

  • Shift-Return to run the selected program in a terminal.
  • Favorites list, frequently used programs are sorted on top.

DRun mode

The desktop run mode allows users to quickly search and launch an application from the freedesktop.org Desktop Entries. These are used by most common Desktop Environments to populate launchers and menus. Drun mode features:

  • Favorites list, frequently used programs are sorted on top.
  • Auto starting terminal applications in a terminal.

SSH launcher

SSH Launcher

Quickly ssh into remote machines

  • Parses ~/.ssh/config to find hosts.

Script mode

Loads external scripts to add modes to Rofi, for example a file-browser.

rofi  -show fb -modi fb:../Examples/rofi-file-browser.sh

COMBI mode

Combine multiple modes in one view. This is especially usefull when merging the window and run mode into one view. Allowing to quickly switch to an application, either by switching to it when it is already running or starting it.

Example to combine Desktop run and the window switcher:

rofi -combi-modi window,drun -show combi

dmenu replacement

DMENU replacement (running teiler)

Drop in dmenu replacement. (Screenshot shows rofi used by teiler ).

Rofi features several improvements over dmenu to improve usability. There is the option to add an extra message bar (-mesg), pre-entering of text (-filter) or selecting entries based on a pattern (-select). Also highlighting (-u and -a) options and modi to force user to select one provided option (-only-match). In addition to this rofi's dmenu mode can select multiple lines and write them to stdout.

Usage

If used with -show [mode], rofi will immediately open in the specified [mode]

If used with -dmenu, rofi will use data from STDIN to let the user select an option.

For example to show a run dialog:

rofi -show run

Show a ssh dialog:

rofi -show ssh

dmenu

If passed the -dmenu option, or ran as dmenu (ie, /usr/bin/dmenu is symlinked to /usr/bin/rofi), rofi will use the data passed from STDIN.

~/scripts/my_script.sh | rofi -dmenu
echo -e "Option #1\nOption #2\nOption #3" | rofi -dmenu

In both cases, rofi will output the user's selection to STDOUT.

Switching Between Modi

Type Shift-/Left/Right to switch between active modi.

Keybindings

Key Action
Ctrl-v, Insert Paste clipboard
Ctrl-Shift-v, Shift-Insert Paste primary selection
Ctrl-u Clear the line
Ctrl-a Beginning of line
Ctrl-e End of line
Ctrl-f, Right Forward one character
Alt-f Forward one word
Ctrl-b, Left Back one character
Alt-b Back one word
Ctrl-d, Delete Delete character
Ctrl-Alt-d Delete word
Ctrl-h, Backspace Backspace (delete previous character)
Ctrl-Alt-h Delete previous word
Ctrl-j,Ctrl-m,Enter Accept entry
Ctrl-n,Down Select next entry
Ctrl-p,Up Select previous entry
Page Up Go to the previous page
Page Down Go to the next page
Ctrl-Page Up Go to the previous column
Ctrl-Page Down Go to the next column
Ctrl-Enter Use entered text as command (in ssh/run modi)
Shift-Enter Launch the application in a terminal (in run mode)
Shift-Enter Return the selected entry and move to the next item while keeping Rofi open. (in dmenu)
Shift-Right Switch to the next modi. The list can be customized with the -modi option.
Shift-Left Switch to the previous modi. The list can be customized with the -modi option.
Ctrl-Tab Switch to the next modi. The list can be customized with the -modi option.
Ctrl-Shift-Tab Switch to the previous modi. The list can be customized with the -modi option.
Ctrl-space Set selected item as input text.
Shift-Del Delete entry from history.
grave Toggle case sensitivity.
Alt-grave Toggle levenshtein sort.
Alt-Shift-S Take a screenshot and store this in the Pictures directory.

For the full list of keybindings see: rofi -show keys or rofi -help.

Configuration

There are currently three methods of setting configuration options:

  • Local configuration. Normally, depending on XDG, in ~/.local/rofi/config. This uses the Xresources format.
  • Xresources: A method of storing key values in the Xserver. See here for more information.
  • Commandline options: Arguments passed to Rofi.

The Xresources options and the commandline options are aliased. To define option X set:

rofi.X: value

In the Xresources file. To set/override this from commandline pass the same key prefixed with '-':

rofi -X value

To get a list of available options, formatted as Xresources entries run:

rofi -dump-Xresources

or in a more readable format

rofi -help

The configuration system supports the following types:

  • String
  • Integer (signed and unsigned)
  • Char
  • Boolean

The boolean option has a non-default commandline syntax, to enable option X you do:

rofi -X

to disable it:

rofi -no-X

Installation

Please see the installation guide for instruction on how to install Rofi.