Results 1 to 8 of 8

Thread: Openbox Windows tiling

  1. #1
    Join Date
    May 2017
    Beans
    24

    Question Openbox Windows tiling

    I love Lubuntu, my only beef is with Openbox that doesn't provide Windows tiling (maybe that's not the right name for it? What I mean is when you drag your window to the left of the screen, and it automatically fills half the screen, or when you drag it to one of the corners and automatically fills 1/4 of the screen).

    I would appreciate any help you can provide. Thank you very much.

  2. #2
    Join Date
    Dec 2007
    Beans
    12,521

    Re: Openbox Windows tiling

    Openbox is a stacking window manager. However, with a little effort and compromise, you can get close to what you want. You can definitely get there with the keyboard.

    You need to look at ~/.config/openbox/lubuntu-rc.xml. The keyboard section should have something of relevance.

    Two links of interest:
    https://pclosmag.com/html/Issues/201011/page09.html
    and
    https://help.ubuntu.com/community/Lu..._Using_a_Mouse (for an older Lubuntu but you get the idea)

  3. #3
    Join Date
    Oct 2017
    Beans
    5

    Re: Openbox Windows tiling

    You can set hotkeys to tile windows into specific positions. For example, I use the following to map Win + left/right bracket to cover the left / right half of the screen:

    Code:
        <keybind key="W-bracketright">
          <action name="MoveResizeTo">
            <x>-0</x>
            <y>0</y>
            <width>50%</width>
            <height>100%</height>
          </action>
        </keybind>
        <keybind key="W-bracketleft">
          <action name="MoveResizeTo">
            <x>0</x>
            <y>0</y>
            <width>50%</width>
            <height>100%</height>
          </action>
        </keybind>
    Further reference: http://openbox.org/wiki/Help:Actions

  4. #4
    Join Date
    Dec 2007
    Beans
    12,521

    Re: Openbox Windows tiling

    And from my old notes, this is what I used:
    Code:
        <keybind key="W-Left">        # HalfLeftScreen
          <action name="Unmaximize"/>
          <action name="MoveResizeTo"><x>0</x><y>0</y><height>100%</height><width>50%</width></action>
        </keybind>
        <keybind key="W-Right">        # HalfRightScreen
          <action name="Unmaximize"/>
          <action name="MoveResizeTo"><x>0</x><y>0</y><height>100%</height><width>50%</width></action>
        </keybind>
        <keybind key="W-Up">        # HalfUpperScreen
          <action name="Unmaximize"/>
          <action name="MoveResizeTo"><x>0</x><y>0</y><width>100%</width><height>50%</height></action>
        </keybind>
        <keybind key="W-Down">        # HalfLowerScreen
          <action name="Unmaximize"/>
          <action name="MoveResizeTo"><x>0</x><y>0</y><width>100%</width><height>50%</height></action>
        </keybind>
        <keybind key="W-5">        # 50% width, height
          <action name="Unmaximize"/>
          <action name="MoveResizeTo"><x>center</x><y>center</y><width>50%</width><height>100%</height></action>
        </keybind>
        <keybind key="W-w">        # Center on screen
        <action name="MoveResizeTo"><x>center</x><y>center</y></action>
        </keybind>
    Just make sure to back up your original and to run
    Code:
    openbox --reconfigure
    each time you edit and save the file to make sure there aren't any parsing errors and to make the changes take effect at once without having to log out.

  5. #5
    Join Date
    May 2017
    Beans
    24

    Re: Openbox Windows tiling

    Outstanding! Seems like I am keeping Lubuntu after all. I guess I should have read the documentation first. Thank you!

    PS: Is there a program with a GUI available to see all of this commands?
    Last edited by thanekrios; December 7th, 2017 at 10:01 PM.

  6. #6
    Join Date
    May 2017
    Beans
    24

    Re: Openbox Windows tiling

    Ok this is what it looks like now:

    Code:
    <keybind key="W-a">
          <action name="MoveResizeTo">
            <x>0</x>
            <y>0</y>
            <width>50%</width>
            <height>50%</height>
          </action>
        </keybind>
        <keybind key="W-s">
          <action name="MoveResizeTo">
            <x>-0</x>
            <y>0</y>
            <width>50%</width>
            <height>50%</height>
          </action>
        </keybind>
    <keybind key="W-z">
          <action name="MoveResizeTo">
            <x>0</x>
            <y>-0</y>
            <width>50%</width>
            <height>50%</height>
          </action>
        </keybind>
        <keybind key="W-x">
          <action name="MoveResizeTo">
            <x>-0</x>
            <y>-0</y>
            <width>50%</width>
            <height>50%</height>
          </action>
        </keybind>
    Thank you all!

    Just in case:

    W+a sends it to the top left side
    W+s to the top right side
    W+z to bottom left side
    W+x to bottom right side

  7. #7
    Join Date
    Mar 2017
    Beans
    1,018

    Re: Openbox Windows tiling

    Quote Originally Posted by thanekrios View Post
    PS: Is there a program with a GUI available to see all of this commands?
    HOW TO CREATE AND EDIT KEYBOARD SHORTCUTS IN LUBUNTU (OPENBOX)

  8. #8
    Join Date
    May 2017
    Beans
    24

    Re: Openbox Windows tiling

    Thank you! I appreciate all the help!
    I see little good coming from this, but... Thy intent is to persevere... to the bitter end, hmm?

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •