[openbox] Windows Positioning

laertis loutsis at csd.uoc.gr
Tue Dec 18 12:28:36 EST 2012


Hello,

first of all i'd like to say how much i love this WM and how configurable
it is.

What is troubling me for the past of the week is how to get openbox to
simulate Win7 aero snapping behavior which i find really comforting and
productive btw. I assumed that in order to achieve so, given the current
configuration actions, i would need to know the variables holding the
window's position so i could "MoveResizeTo" those!

I think this guy describes the same thing with me except that he is talking
about mousebinds while i'm talking about keybinds.


And this is the nearest i could get to Win7 snapping :
http://www.jasoncavett.com/2012/05/better-aero-snap-with-openbox.html

I've tried a work around leveraging the if statements of the openbox
configuration file and the result was something like this :

<keybind key='W-Right">
  <action name="If">
    <maximized>yes</maximized>
    <then>
      <action name="Unmaximize"/>
      <action name="Unmaximize"/>
        <direction>vertical</direction>
      </action>
      <action name="MoveResizeTo">
        <x>0</x>
        <y>0</y>
        <width>50%</width>
      </action>
    </then>
    <else>
      <action name="If">
       ..........
       ..........
       ..........
       ..........

  but i figured out but it can't be done without knowing the window's
position.

So i think writing a wmctrl script holding the windows position and
combining it with the above would give me what i want.

Is there any chance this is implemented somewhere out there?

I think i'm gonna write down a script either way but if there is something
out there getting the job done it would help for now.

However there are some issues i'm thinking right now, such as, how is each
windows going to hold it's previous state ?

Anyway, that's about it. Thank you for the support.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://icculus.org/pipermail/openbox/attachments/20121218/34b686bc/attachment.htm>


More information about the openbox mailing list