Skip to main content

Rofi Application Launcher

Rofi is a fast, customizable application launcher and window switcher for X11 and Wayland. This configuration provides a clean, minimal interface for launching applications and switching between windows.

Configuration

Rofi is configured using config.rasi located in ~/.config/rofi/.

Basic Settings

configuration {
    modi:         "drun";
    show-icons:   true;
    display-drun: "";
}

Mode

drun - Desktop application launcher

Icons

Application icons are displayed

Theme Configuration

Window Appearance

window {
    transparency:     "real";
    width:            450px;
    border-radius:    8px;
    background-color: #000000CC;
    border:           2px solid;
    border-color:     #FFFFFFFF;
    padding:          12px;
}
PropertyValueDescription
Width450pxFixed width for consistency
Border Radius8pxRounded corners
Background#000000CCSemi-transparent black
Border2px whiteClean white border
Padding12pxInternal spacing

Layout Structure

mainbox {
    spacing:  10px;
    margin:   0px;
    padding:  8px;
    children: ["inputbar", "listview", "message"];
}
The main container includes:
  • Input bar: Search field and prompt
  • List view: Application results
  • Message: Error/info messages

Input Bar

Search input with prompt:
inputbar {
    children: ["prompt", "entry"];
    spacing:  10px;
}

prompt {
    text-color: #FFFFFFFF;
}

entry {
    placeholder:       "Search Apps";
    text-color:        #FFFFFFFF;
    placeholder-color: #888888FF;
    cursor:            text;
}
The search is instant and fuzzy - start typing to filter applications immediately.

List View

Results are displayed in a scrollable list:
listview {
    columns:       1;
    lines:         7;
    fixed-height:  true;
    fixed-columns: true;
    cycle:         false;
    scrollbar:     false;
    border:        0px solid;
}

Single Column

One application per line

7 Visible Items

Shows 7 items at once

No Cycling

List doesn’t wrap around

No Scrollbar

Clean minimal interface

Element Styling

Normal Elements

element {
    spacing:          10px;
    margin:           0px;
    padding:          8px;
    border-radius:    8px;
    background-color: transparent;
    text-color:       #FFFFFFFF;
    children:         ["element-icon", "element-text"];
    cursor:           pointer;
}

element normal.normal {
    background-color: transparent;
    text-color:       #FFFFFFFF;
}

element alternate.normal {
    background-color: #111111FF;
    text-color:       #FFFFFFFF;
}
StateBackgroundDescription
NormalTransparentStandard list items
AlternateDark grayZebra striping
SelectedWhiteCurrently highlighted

Selected Elements

element selected.normal,
element selected.active {
    background-color: #FFFFFFFF;
    text-color:       #000000FF;
}
Selected items have inverted colors (white background, black text) for high contrast.

Element Components

element-icon {
    background-color: inherit;
    size:             1.2em;
}

element-text {
    background-color: inherit;
    text-color:       inherit;
    cursor:           inherit;
}
Icons are 1.2em (relative to font size) and inherit the parent element’s styling.

Color Scheme

The configuration uses a minimal monochrome palette:
* {
    font:           "Figtree 13";
    b-color:        #000000FF;  /* Black */
    fg-color:       #FFFFFFFF;  /* White */
    fgp-color:      #888888FF;  /* Gray (placeholder) */
    b-radius:       8px;
    hl-color:       #FFFFFFFF;  /* Highlight - White */
    hlt-color:      #000000FF;  /* Highlight text - Black */
    alt-color:      #111111FF;  /* Alternate - Dark gray */
    wbg-color:      #000000CC;  /* Window bg - Semi-transparent */
    w-border:       2px solid;
    w-border-color: #FFFFFFFF;  /* White border */
}
Customize colors by changing the hex values in the variables section at the top of config.rasi.

Usage and Shortcuts

Opening Rofi

rofi -show drun
KeyAction
TypeFilter applications
/ Navigate list
EnterLaunch selected app
EscapeClose Rofi
TabAuto-complete
ActionResult
HoverHighlight item
ClickLaunch application
ScrollNavigate list

Available Modes

While configured for drun, Rofi supports multiple modes:

drun

Desktop applications (.desktop files)

run

Execute commands from PATH

window

Switch between open windows

ssh

Quick SSH connections
Switch modes by adding to the configuration:
configuration {
    modi: "drun,run,window";
    show-icons: true;
}
Then use Super + Tab or arrow keys to cycle modes when Rofi is open.

Customization

Changing Font

* {
    font: "Your Font Name 13";
}
Popular alternatives:
  • "JetBrainsMono Nerd Font 12"
  • "Ubuntu 13"
  • "Roboto 12"

Adjusting Size

window {
    width: 600px;  /* Wider window */
}

listview {
    lines: 10;     /* Show more items */
}

Adding Transparency

window {
    background-color: #000000AA;  /* More transparent */
}
Transparency format: #RRGGBBAA where AA is alpha (00-FF).

Color Themes

Quick theme example - Catppuccin style:
* {
    bg-color:       #1e1e2e;
    fg-color:       #cdd6f4;
    hl-color:       #cba6f7;
    border-color:   #89b4fa;
}

Performance

Fast Launch

Rofi starts in milliseconds

Instant Search

Real-time filtering as you type

Low Memory

Minimal resource footprint

Wayland Native

Full Wayland support with -show drun

Troubleshooting

Ensure show-icons: true is set and you have an icon theme installed:
sudo pacman -S papirus-icon-theme
Rofi reads .desktop files from:
  • /usr/share/applications/
  • ~/.local/share/applications/
Ensure applications have valid desktop entries.
Check syntax errors in config.rasi:
rofi -dump-config
Rofi requires properly formatted .desktop files. Applications installed from source may need manual desktop file creation.

Build docs developers (and LLMs) love