Title : Port of the week: pmenu
Author: Solène
Date : 12 March 2021
Tags : openbsd
# Introduction
This Port of the week will introduce you to a Pie-menu for X11, available on OpenBSD since 6.9 (not released yet). A pie menu is a circle with items spread in the circle, allowing to open other circle with other items in it. I find it very effective for me because I am more comfortable with information spatially organized (my memory is based on spatialization). I think pmenu was designed for a tablet input device using a pen to trigger pmenu.
Pmenu github
# Installation
On OpenBSD, a pkg_add pmenu is enough, but on other systems you should be able to compile it out of the box with a C compiler and the X headers.
# Configuration
This part is a bit tricky because the configuration is not obvious. Pmenu takes its configuration on the standard input and then must be piped to a shell.
My configuration file looks like this:
```pmenu configuration file
#!/bin/sh
cat <
IMG:/usr/local/share/icons/Adwaita/48x48/legacy/utilities-terminal.png
IMG:/usr/local/share/icons/Adwaita/48x48/legacy/applets-screenshooter.png
Apps
Games
Volume
ENDOFFILE
```
The configuration supports levels, like "Apps" or "Games" in this example, that will allow a second level of shortcuts. A text could be used like in Volume, but you can also use images like in other categories. Every blank appearing in the configuration are tabs.
The pmenu itself can be customized by using X attributes, you can learn more about this on the official project page.
# Video
I made a short video to show how it looks with the configuration shown here.
Note that pmenu is entirely browseable with the keyboard by using tab / enter / escape to switch to next / validate / exit.
=> static/pmenu.mp4 Video demonstrating pmenu in action