Skip to content

Conversation

@mbroemme
Copy link

Summary

This PR adds an optional boolean truncate to the wlr/taskbar module. When enabled, task button text is ellipsized (… at the end) whenever the label would exceed the button's available width. This keeps the taskbar tidy when window titles are long or when space is tight. It will fix issue #3770 for wlr/taskbar.

Configuration

It is off by default and enabling requires:

"wlr/taskbar": {
  "truncate": true
}
  • No breaking changes. The new behavior is opt-in.
  • Existing configs continue to behave the same.

Screenshots

Before: different length of taskbar button label.
image

After: with "truncate": true (visuals depend on theme and spacing).
image

Before: huge amount of taskbar buttons.
image

After: with "truncate": "true"
image

Docs

  • Add the new truncate key to the wlr/taskbar module documentation with accepted values and defaults.

Testing

  1. Enable the option:
"wlr/taskbar": { "truncate": true }
  1. Enforce a static width with:
"width": 1280
  1. Open an app with a very long title (e.g., a browser tab with a long page title).
  2. Reduce available taskbar width (resize bar/monitor or open more tasks).
  3. Verify the label is a single line and ends with an ellipsis rather than wrapping or pushing layout.

Motivation

Long window titles can cause layout jitter or overflow in the taskbar. Providing a first-class switch to ellipsize labels gives users a simple, predictable way to keep the module compact, regardless of how many tasks are present or how verbose their titles are.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant