XMenu



  1. Xmenu Start
  2. Xmenu Sierra
  3. Jack In The Box Menu

JavaScript must be enabled! XMenu is a real app, no hack, no extension. Xmenu-xlayer is a versatile, javascript driven DHTML menu that works on. Internet Explorer Windows 5 and later (5, 5.5, 6) Gecko (Mozilla, Mozilla-Firebird, Galeon, Netscape 6, 7, etc.) Opera 6, 7; Internet Explorer Macintosh 5 and later (5, 5.1, 5.2). By default, XMenu pops a little icon up near the right-hand side of the menu bar, near Spotlight's magnifying glass. It's easy to overlook - the new version's icon is a tiny version of the stylized A on Apple's Applications folder. Clicking on the icon drops down a scrollable, alphabetized list of the contents of the Applications folder.

At a Glance

Expert’s Rating

Cons

Our Verdict

Band

One of my favorite OS X add-ons is FinderPop, in part because of its menu-bar menu that provides quick access to my favorite files and folders. But if this is the only one of FinderPop’s many features you need, a suitable alternative is Devon Technologies’ XMenu. I wrote a one-paragraph review of XMenu back in 2005, but the program is worth revisiting: since that time, it’s been updated for Intel Macs, gained some impressive speed boosts, and added some useful features.

XMenu lets you add one or more menus to the menu bar for browsing files and data. The available menus are Applications (for the main Applications folder), Developer (for the /Developer folder, if you’ve installed Apple’s developer tools), Home (for your home directory), Documents (for your personal Documents folder), User-Defined, and Snippets. User-Defined is a custom menu you create by dropping files, folders, and aliases into ~/Library/Application Support/XMenu.

The new Snippets menu is for frequently used text files, rich-text files, text clippings, and Internet Location files. Place these items in ~/Library/Application Support/XSnippets, and when you want to use one, you just choose it from the Snippets menu; XMenu inserts the item’s contents into the current document or text field.

You can choose to view any combination of these menus. Each menu has a unique icon to help you distinguish it from the others, though you can instead choose to view the menus by their (editable) names—or by both name and icon. You can also choose how the contents of these menus are displayed: in small or large text, or as small or large icons with text. (You can dramatically increase XMenu’s performance by enabling the option to use generic icons.)

The XMenu documentation claims you can perform different actions on menu items by using modifier keys; for example, control-choosing an item in a menu is supposed to show the item instead of opening it, and command-choosing an item is supposed to open the Finder’s Info window for that item. However, I couldn’t get these features to work on two different Macs. Luckily, I rarely wanted to use them; I mainly used XMenu to open frequently-used files and folders.

A couple features I miss from FinderPop are ways to organize the custom menu without having to fool around with spaces and special characters, and the capability to add dividing lines between groups of items. Another feature I’d like to see is the capability to create multiple custom menus, as well as to designate any folder—for example, the Desktop or a project folder—as a new menu.

Of course, FinderPop has many other features not found in XMenu. But FinderPop also injects its code into every running application, whereas XMenu doesn’t touch other programs, so it shouldn’t affect the stability of the OS or applications. It’s a simpler solution for those who don’t need much more than a few quick-access menus.

Want to stay up to date with the latest Gems? Sign up for the Mac Gems newsletter for a weekly e-mail summary of Gems reviews sent directly to your Inbox.

In the past, I have detailed some of the helper programs I use with the i3 window manager. I have a new one, something that is actually really helpful for my workflow.

So far, my workflow has been entirely keyboard driven. But that doesn’t mean I hate the mouse. I really hate switching between the keyboard and mouse. So if I am just using themouse to click youtube videos or play a game, why would I want to reach for the keyboard to bring up rofi?

That’s where xmenu comes in. xmenu gives you the openbox style menu that can be navigated with either the keyboard or the mouse.

Since I run arch, I was able to grab the xmenu program off of the AUR with

Otherwise you can clone the repository, enter it, and

I choose to build from source because it allows me to theme on the fly.

The beauty of xmenu is that it works like dmenu or rofi, and takes its options from STDIN.

This means that by default, xmenu does nothing. When we want to invoke it, we would pipe in the options we want, usually through a bash script for convenience.

Xmenu Start

For example, to create the example in the above gif, simply use this script:

Xmenu Sierra

Each value is separated by the TAB character. On the left is the name to be displayed, and then one tab over is the command/script to be run if that option is selected.

You can make nested menus by indenting another tab, and line breaks with empty lines. Note that nested line breaks need the appropriate number of tabs at the beginning of the linefollowed by nothing.

If you know anything about me, it’s that I will not be happy with that lame white menu. Inside the xmenu directory, we can find a file called config.h.

This file defines all of the colors and styles used by xmenu. Changing this file requires a rebuild of xmenu.

Jack In The Box Menu

So I created a pywal template for the config.h file.

Every time wal is run, a new file is created in ~/.cache/wal/. I symlink this file to the location xmenu, and rebuild it every time I change theme.

I use my own theming tool chameleon to handle themes. If chameleon detects xmenu on your system, it will attempt to rebuild it on thefly.

Look at these colors!!

I use i3, which doesn’t exactly have a built in mechanism for “right click desktop menu”. The author of xmenu has another tool, xclickroot which helps with this.

However, since my windows are tiled, I rarely see the desktop anyways. That is why I integrated xmenu into my polybar like a traditional start menu!

In my polybar config, I have the following module:

I have three almost identical modules, one for each of my monitors. The reason for this is that each monitor calls a differentxmenu script, which tells xmenu to positionitself below the bar of that display.

Xmenu xbox

The script xmenu-button.sh is dead simple, and can remain consistent across all modules if you like. It simply echoes out the character you want to click on in polybar.

You can slap pretty much anything in there, but I like to use FontAwesome icons because that’s what the rest of my bar uses.

Here is the ENTIRE xmenu script I have at the moment for my bars. Note the invocation of xmenu.

xmenu -i -p 0x25:1

  • -i tells xmenu to remove the space for icons
  • -p tells xmenu to use a specific position
  • 0x25 the coordinates that place xmenu below my bar (25px down)
  • :1 on screen one

Feel free to take inspiration!

Good job for making it this far. If you followed along, you should have a desktop environment agnostic menu utility with infinite potential!





Comments are closed.