Introduction
Introduction Statistics Contact Development Disclaimer Help
Title: Port of the week: pmenu
Author: Solène
Date: 12 March 2021
Tags: openbsd
Description:
# 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 page
# 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 <<ENDOFFILE | pmenu | sh &
IMG:/usr/local/share/icons/Adwaita/48x48/legacy/utilities-terminal.png s…
IMG:/usr/local/share/icons/Adwaita/48x48/legacy/applets-screenshooter.png …
Apps
IMG:/usr/local/share/icons/hicolor/48x48/apps/gimp.png gimp
IMG:/home/solene/dev/pmenu/claws-mail.png claws-mail
IMG:/usr/local/share/pixmaps/firefox.png firefox
IMG:/usr/local/share/icons/hicolor/256x256/apps/keepassxc.png ke…
IMG:/usr/local/share/icons/hicolor/48x48/apps/chrome.png chrome
IMG:/usr/local/share/icons/hicolor/128x128/apps/rclone-browser.png …
Games
IMG:/home/jeux/slay_the_spire/sts.png cd /home/jeux/slay_the_spi…
IMG:/home/jeux/Delver/unjar/a/Delver-Logo.png cd /home/jeux/Delv…
IMG:/home/jeux/Dead_Cells/deadcells.png cd /home/jeux/Dead_Cells…
IMG:/home/jeux/brutal_doom/Doom-The-Ultimate-1-icon.png cd /home…
Volume
0% sndioctl output.level=0
10% sndioctl output.level=0.1
20% sndioctl output.level=0.2
30% sndioctl output.level=0.3
40% sndioctl output.level=0.4
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.
Video demonstrating pmenu in action
You are viewing proxied material from dataswamp.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.