berry icon indicating copy to clipboard operation
berry copied to clipboard

Decorations get toggled when window is sent to another WS, and smart_place doesn't appear to work

Open broccoli5 opened this issue 3 years ago • 10 comments

I really hope that this just isn't me being stupid, yet again.

For some reason, when I move a window to another workspace it toggles it's decorations, and I have to manually toggle them back on, this happens with every program. decorate_new has no effect on this. This is my keybind:

# Switch to WS / send window to WS
super + {_,shift + }{1-9,0}
	berryc {switch_workspace,send_to_workspace} {0-9}

And regarding the smart_place problem: I'm not sure if my screen resolution (1280x800) has to do anything with it, or the way that it determines whats a empty space. But no matter what I try it always places windows to the top left corner as if it was turned off, even if there are already windows there.

I'm not sure how to get any logs tho

broccoli5 avatar Jul 06 '21 17:07 broccoli5

I'll try to repro...

JLErvin avatar Jul 06 '21 17:07 JLErvin

It looks like the decorations issues was introduced as a bug in https://github.com/JLErvin/berry/pull/136, I'll look into a fix.

JLErvin avatar Jul 06 '21 18:07 JLErvin

I had a look around and I think that I understand the problem. I'm still learning C and I haven't worked with Xorg yet. But is there a way to check if the "dummy" windows are drawn around the clients when you switch to a WS? Something like a struct inside a struct that would hold the client and state of the "dummy" window? IDK, just an idea

broccoli5 avatar Jul 06 '21 21:07 broccoli5

I know what the issue is, it’s just a matter of the simplest way to fix it. The PR I linked introduced destroying decorating when clients are moved to prevent certain errors, but this leads to the state being lost during workspace switches.

Regarding your question, yes. Clients maintain a boolean value determining whether or not they are decorated.

JLErvin avatar Jul 06 '21 21:07 JLErvin

still happens, really bothersome, can't move windows around with my mouse anymore when I move them to another workspace

acoolstraw avatar Jan 21 '22 10:01 acoolstraw

Any update on this? Loving berry so far

willowbit avatar Apr 27 '22 19:04 willowbit

Sorry, this slipped off my radar. Out of town until this weekend but will look into it when I get home.

JLErvin avatar Apr 27 '22 21:04 JLErvin

@willowbit can you try the changes made here https://github.com/JLErvin/berry/issues/143 and see if they persist decorations for you?

JLErvin avatar May 08 '22 05:05 JLErvin

This works wonderfully, thank you so much!

Looking forward to your work :)

willowbit avatar May 09 '22 00:05 willowbit

Hey, I open it again because it still happen to me, when I move a window from a workspace to another its decoration is removed.

super + shift + 1
    berryc send_to_workspace 0

that's how I send the window to another workspace in my sxhkdrc script

4zv4l avatar Sep 07 '22 08:09 4zv4l