You are not logged in.

#1 2019-10-09 01:30:41

Meikk99
Member
Registered: 2019-10-09
Posts: 6

[SOLVED] Starting compton in i3 config and i3 layout restore

When I restore a saved i3 layout using  something like:

exec --no-startup-id "i3-msg 'workspace 1:control; append_layout /home/mk/.config/i3/workspace-1.json'"
exec --no-startup-id termite --name "ncmpcpp-container" -e ncmpcpp

and I also start compton anywhere in my i3 config or .xinitrd, it causes some issues. For one transparency does not work on the restored windows and it causes some kind of strange ghosting effect when, for example I move my selection in ncmpcpp.

The strangest thing is that if I start compton manually after i3 has started it works perfectly fine for every window, including the restored ones.

The command I am using to start compton is

compton -b

, though i have tried

compton &

and

compton -b &

as well.

EDIT:

I just found this post on reddit, which I believe may be the same issue, in short the layout windows that i3 creates are not transparent and this property is transferred to the windows that it swallows. The post has no solution though.

Last edited by Meikk99 (2019-10-09 14:56:02)

Offline

#2 2019-10-09 06:07:40

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 78,319

Re: [SOLVED] Starting compton in i3 config and i3 layout restore

something like

Not "something like", post the actual script/i3config: https://bbs.archlinux.org/viewtopic.php?id=57855

Offline

#3 2019-10-09 07:07:48

Meikk99
Member
Registered: 2019-10-09
Posts: 6

Re: [SOLVED] Starting compton in i3 config and i3 layout restore

Apologies, here is my complete i3 config: https://pastebin.com/JZvWjWnM, here my attempts at starting compton are commented out, but i have tried all of the commands I mentioned before.

Edit:

I should probably provide my compton config as well: https://pastebin.com/i1yK7gzU

Last edited by Meikk99 (2019-10-09 07:29:49)

Offline

#4 2019-10-09 14:11:09

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 78,319

Re: [SOLVED] Starting compton in i3 config and i3 layout restore

I'd move "exec --no-startup-id compton" to pretty much the top of the file (right now it's started in proximity to the termite windows what might lead to a race condition where compton misses the appearance of a window which is also not present during comptons init) - you might even want to add some small arbitrary delay.
Starting the compositor ahead generally makes sense so clients see the RGBA potential.

Offline

#5 2019-10-09 14:55:11

Meikk99
Member
Registered: 2019-10-09
Posts: 6

Re: [SOLVED] Starting compton in i3 config and i3 layout restore

I tried making certain that compton started before I created any windows, however when I do this I get the same result as before. However, when I make certain it starts after any windows are created, it somehow does work. I am not entirely certain what the reason for this is, however I suspect that it has to do with the containers that i3 creates to restore the window, namely their lack of transparency. What I think happens is that when you start compton after the creation of the windows, compton will never have been aware of the original opaque containers and thus bases the transparency of the terminal instead of the original container.

Regardless, it seems that by adding a delay to the starting of compton everything now works perfectly fine, so I will mark this as solved.

Offline

#6 2019-10-09 15:17:10

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 78,319

Re: [SOLVED] Starting compton in i3 config and i3 layout restore

Check the termite manpage on whether it has some explicit no-argb option (to enforce a 24bit drawable)

Offline

Board footer

Powered by FluxBB