Skip to content

Multi-column layout dynamic menus with custom walker window dimensions? #209

@nickjj

Description

@nickjj

I have a custom menu being presented with walker --dmenu to load around 150 items in a list. It's a list of key binds along with a description.

It looks like this, I used shell scripting to make it visually look like 2 columns.

Image

Overall it works but what I'd really like is for this 1 specific walker menu to allow for being displayed in multiple columns and also have more height + width than everything else.

For example, having something like this:

[Key]       | [Description]  ||  [Key]       | [Description]
[Key]       | [Description]  ||  [Key]       | [Description]
[Key]       | [Description]  ||  [Key]       | [Description]

[Be at least twice the height and width as my screenshot]

In the above case || would be a walker-level column split. The left and right items would be individually selectable, sort of like what walker already does for the multi column layout on symbols. In this case || wouldn't be visible, I just added that to show it here.

For this 1 use case being able to see many items at a glance is helpful.

I know there's the --height and --width flags which works, but it would be neat if it were dynamically sized based on the display size, number of items and number of columns. Basically some way to say a max percent height / width and walker would automatically create dynamic columns based on the number of items to present things with the least amount of scroll.

This would probably be a lot of work to implement, but I'm wondering if it's something you've thought about implementing.

Here's 3 examples of other tools handling this:

Maybe a quick workaround for now would be to allow --columns to be set just like --height and --width so we can create custom menus with multiple columns? I wouldn't want all menus to have 2-3 columns, just this one menu.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions