ironbar icon indicating copy to clipboard operation
ironbar copied to clipboard

Support Niri out of the box

Open VarLad opened this issue 1 year ago • 4 comments
trafficstars

Is your feature request related to a problem? Please describe.

Currently workspaces in Niri WM are not supported. Niri does have IPC.

Describe the solution you'd like Support Niri workspaces out of the box. What would be required to do this?

VarLad avatar Jun 28 '24 02:06 VarLad

Yes, happy for this to be added.

I've had a brief look at Niri's IPC and it looks like it's missing events, which would make this tricky. Without those, Ironbar would have to constantly poll Niri to find the focused workspace, as it won't be notified of changes. I might be missing something though.

Assuming that can be resolved, the rest shouldn't be too hard, especially since Niri provides rust types for its IPC. Effectively entries would need to be added to the compositor client code to spawn a Niri client here and a new client would need to be written which implements the WorkspaceClient trait https://github.com/JakeStanger/ironbar/blob/6a06fa534a8f02aa1fa3fe04a9da59697a3fff25/src/clients/compositor/mod.rs#L142-L148

JakeStanger avatar Jun 28 '24 18:06 JakeStanger

@JakeStanger Does it make sense to wait for https://github.com/YaLTeR/niri/pull/453 then?

VarLad avatar Jun 29 '24 03:06 VarLad

Aha. Yeah definitely so, I'll mark this as blocked for now.

JakeStanger avatar Jun 29 '24 08:06 JakeStanger

@JakeStanger ~~Work on the event stream IPC has progressed and the niri dev is wondering if there are any design flaws that need to be worked on. There are some details in the PR linked above. I'm not a programmer but I'm willing to helping in testing.~~

The PR has been merged.

Brisingr05 avatar Aug 30 '24 16:08 Brisingr05