ekalinin / SpaceName

MacOS space id/name indicator in the menu bar
MIT License
29 stars 5 forks source link

Selecting a space from the menu does not cause a jump to that space #7

Open smurp opened 8 months ago

smurp commented 8 months ago

Is this actually working for anybody at this point?

My situation is possibly complicated by me having 3 monitors and 20+ spaces

The HammerSpoon console shows this

> hs.spaces.allSpaces()
{
  ["13E127EE-6734-43F5-BFD9-D04FCCA177E4"] = { 3913, 25, 26, 27, 28, 29, 30, 31 },
  ["8543700D-E4DA-433C-AC38-CF9DC691E338"] = { 3950, 33, 34, 35, 36, 37, 38, 39, 40, 2785 },
  ["E218F401-53B5-4AC2-8893-6833C1E56359"] = { 6, 8, 9, 10, 11, 12, 13, 15, 16, 17, 7, 18, 19, 20, 21, 22, 23, 41, 42, 43, 44, 45, 46, 14 }
}

Running macOS Sonoma 14.1.2

I see in the source multimonitor situations are ignored and I am happy to try to fix that but since I haven't seen SpaceName.spoon demonstrate that it CAN cause a move to different screen when its menu item is selected I'm reluctant to continue.

I've seen indication that this might be quite hard, given that SIP seems to need to turned off so Dock.app can be overpowered to achieve this. As far as I know there is no API exposed for having control over that

I guess I am asking question!

Is the basic functionality working, ie "choosing one of the spaces from the menu" successfully cause a jump to the selected space?

ekalinin commented 7 months ago

Hey,

Please, try a new version:

smurp commented 7 months ago

Hiya!

Thanks for that! OK, the good: 1) it is "changing spaces when I choose them from the SpaceName menu" 2) it changes the name presented on the menubar when "set name" is used

But there are some problems: 1) Choosing a named screen from the SpaceName menu does not reliably go to the desired screen 2) There is not a stable relationship between the named space and even what monitor it is on 3) Switching Space using Apple-provided techniques does not update the SpaceName menubar state 4) Trying to name a space sometimes causes a different name to be overwritten

Bottom line, there is currently no clear mapping between action and result.

BTW I have been so frustrated for EVER about how stupid it is that Apple does not properly support nameable Spaces! It is so difficult to use Spaces at the level of intensity that I do without naming. So, thank you for working on a solution to this.

Cheers

smurp commented 7 months ago

Side note, there IS retention of the state of the menu between restarts of Hammerspoon.