JWM. How to set a key combo for a certain virtual desktop?

New to Puppy and have questions? Start here

Moderator: Forum moderators

Post Reply
User avatar
monketype
Posts: 5
Joined: Fri Jul 29, 2022 11:06 pm
Has thanked: 1 time

JWM. How to set a key combo for a certain virtual desktop?

Post by monketype »

Hi puppyans!

I want to use ten virtual desktops in JWM:

Code: Select all

<Desktops width="10" height="1">

Fine, I got'em.

Now I want to switch or send to desktop number 10 directly, without using rdesktop and sendr.
Tried these, but obviously, without luck:

Code: Select all

<Key mask="4" key="0">desktop#10</Key>
<Key mask="4" key="0">desktop:10</Key>
<Key mask="4" key="0">desktop10</Key>

$ jwm -p says those are invalid key actions.

So how do I jump to desktop No.10 with Super+0 or to desktop, say, No.25 with Super+K?

User avatar
MochiMoppel
Posts: 1232
Joined: Mon Jun 15, 2020 6:25 am
Location: Japan
Has thanked: 21 times
Been thanked: 436 times

Re: JWM. How to set a key combo for a certain virtual desktop?

Post by MochiMoppel »

moketype wrote: Fri Jul 29, 2022 11:37 pm

Now I want to switch or send to desktop number 10 directly, without using rdesktop and sendr.

May be impossible.
It works only for WinKey + 1~9.
9 used to be the max number of desktops, maybe just because there are only number keys 1~9 on a keyboard which would the desktop# action make work (0 wouldn't do anything as JWM desktops count from 1).

Code: Select all

<Key mask="4" key="#">desktop#</Key>

The '#' in above code must not be replaced by a number. It's the code that covers actions for all 9 keys. The manual is a bit misleading.

User avatar
monketype
Posts: 5
Joined: Fri Jul 29, 2022 11:06 pm
Has thanked: 1 time

Re: JWM. How to set a key combo for a certain virtual desktop?

Post by monketype »

MochiMoppel wrote: Sat Jul 30, 2022 3:00 am

The '#' in above code must not be replaced by a number.

Oh, I do have and make use of <Key mask="4" key="#">desktop#</Key> entry. I Just hope there is a way to use keys other than 1-9.

User avatar
MochiMoppel
Posts: 1232
Joined: Mon Jun 15, 2020 6:25 am
Location: Japan
Has thanked: 21 times
Been thanked: 436 times

Re: JWM. How to set a key combo for a certain virtual desktop?

Post by MochiMoppel »

moketype wrote: Fri Jul 29, 2022 11:37 pm

So how do I jump to desktop No.10 with Super+0

Code: Select all

<Key mask="4" key="0">exec:wmctrl -s 9</Key>
User avatar
monketype
Posts: 5
Joined: Fri Jul 29, 2022 11:06 pm
Has thanked: 1 time

Re: JWM. How to set a key combo for a certain virtual desktop?

Post by monketype »

That's a good one! Thanks, MochiMoppel :)
Will use it for now. Still gonna bump this thread a couple of times and then contact Joe, probably a quick fix for him.

Post Reply

Return to “Beginners Help”