Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Start the numbering from 1 instead of 0 #2

Open
xvitcoder opened this issue Feb 18, 2025 · 1 comment
Open

Feature: Start the numbering from 1 instead of 0 #2

xvitcoder opened this issue Feb 18, 2025 · 1 comment
Labels
enhancement New feature or request

Comments

@xvitcoder
Copy link

EXWM allows mapping of workspace numbers to start from 1 instead of 0

  (setq exwm-workspace-index-map (lambda (i) (number-to-string (1+ i))))

which is really intuitive.

In my case I have two monitors and 10 workspaces, each monitor has 5 workspaces.
The issue is that when changing the workspace index to start at 1 instead of 0, the numbers in the modeline apears [2|3|4|5|6] on the first monitor and [1|7|8|9|10] on the second monitor

It would be nice to add an option that will allow to change the visual number of the exwm workspaces in the modeline.

@SqrtMinusOne
Copy link
Owner

Yeah, that was the intended behaviour; the package simply reuses exwm-workspace-index-map for display. I thought it made sense because, for instance, M-x exwm-workspace-switch also uses that.

But I've added exwm-modeline-workspace-index-map if you need that. So, e.g.:

(setopt exwm-modeline-workspace-index-map
        (lambda (i) (format "-%d-" i)))

This will apply only to the modeline. By default, the package reuses exwm-workspace-index-map.

@SqrtMinusOne SqrtMinusOne added the enhancement New feature or request label Feb 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants