<div dir="ltr"><div dir="ltr">On Tue, Mar 9, 2021 at 6:11 PM Parke <<a href="mailto:parke.nexus@gmail.com">parke.nexus@gmail.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Tue, Mar 9, 2021 at 1:57 PM Mikael Magnusson <<a href="mailto:mikachu@gmail.com" target="_blank">mikachu@gmail.com</a>> wrote:<br>
> > So, my question is:  Is it possible to dynamically change the<br>
> > _OB_APP_ROLE property for a pre-existing client window?<br>
<br>
> On 3/9/21, Parke <<a href="mailto:parke.nexus@gmail.com" target="_blank">parke.nexus@gmail.com</a>> wrote:<br>
> You can't, and it wouldn't affect anything either way. The role of a<br>
> window only serves to identify it uniquely for session restoration.<br>
<br>
I'm confused.  The wiki clearly states that the If action can branch<br>
based on a window's role.<br>
<br>
<a href="http://openbox.org/wiki/Help:Actions#If" rel="noreferrer" target="_blank">http://openbox.org/wiki/Help:Actions#If</a><br>
<br>
In fact, I already have a mousebind and a keybind that branch based on<br>
the window's role, and it works as documented in the wiki.<br>
<br>
So role does have uses besides session restoration.<br></blockquote><div><br></div><div>Yeah.. so the role hint is used for session restore. Openbox lets you repurpose it for other things. The OB_APP_ROLE isn't a real hint.. it's a cached value so that you can see what Openbox read when the window appeared. in case the app changes it afterward - which would have no effect as per the spec. So that's why you can't change it and expect something to happen.</div><div><br></div><div>To have a window change its behaviour would require another openbox-specific property which currently doesn't exist. And watching for changes to that property to reapply settings, which also doesn't exist.</div><div><br></div><div>The title property on the other hand can change according to the spec,  and Openbox would see those changes. Otherwise.. you'd need to invent a whole other unspecced hint I guess, and set that hint through some 3rd-party app onto other windows.</div><div><br></div><div>Anyhow, if you can get a 3rd party app to write to the window's title that might work for you, depending.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
_______________________________________________<br>
openbox mailing list<br>
<a href="mailto:openbox@icculus.org" target="_blank">openbox@icculus.org</a><br>
<a href="http://icculus.org/mailman/listinfo/openbox" rel="noreferrer" target="_blank">http://icculus.org/mailman/listinfo/openbox</a><br>
</blockquote></div></div>