Author Topic: add your favorite openbox customizing tips here  (Read 20802 times)

0 Members and 1 Guest are viewing this topic.

Offline mxx

  • Sr. Mitglied
  • ****
  • Posts: 420
  • Branch: stable
  • Desktop: Openbox/i3wm
  • Kernel: linux4
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #45 on: 29. April 2015, 06:52:29 »
Looks like all the best tips have already been divulged. So I only have some small ones.

Openbox is typically (provided that I am typical) installed on small laptops and netbooks, where it is operated with touchpad rather than a mouse. A touchpad is much trickier than a mouse, so it's in order to get rid of some of the annoyances that may make sense with a mouse, but not with a touchpad.

For example, it's horrifying how a scroll on the desktop flings you to another desktop. This should not happen.

Scrolls are identified in openbox/rc.xml as <mousebind button="Up" action="Click"> and <mousebind button="Down" action="Click">. So, find those places in openbox/rc.xml and comment them out by enclosing them in <!-- -->. In xml, this has to be precise. <!-- must be precisely before a <mousebind> tag and --> precisely after a </mousebind> tag.

To get rid of the switching of desktops by scroll, find this section.
Code: [Select]
<mousebind button="Up" action="Click">
        <action name="GoToDesktop">
          <to>previous</to>
        </action>
      </mousebind>
      <mousebind button="Down" action="Click">
        <action name="GoToDesktop">
          <to>next</to>
        </action>
      </mousebind>
      <mousebind button="A-Up" action="Click">
        <action name="GoToDesktop">
          <to>previous</to>
        </action>
      </mousebind>
      <mousebind button="A-Down" action="Click">
        <action name="GoToDesktop">
          <to>next</to>
        </action>
      </mousebind>

I recommend commenting it out rather than deleting, because when you migrate your customised rc.xml to a real desktop one day, you may need to activate the section again.

Another annoyance is shade-by-scrolling. This section starts
Code: [Select]
<mousebind button="Up" action="Click">
<action name="if">
          <shaded>no</shaded>
          <then>
            <action name="Shade"/>

Offline handy

  • Global Moderator
  • *****
  • Posts: 5738
  • Desktop: Openbox 3.6.1-3 & Worker :)
  • GPU Card: intel...
  • GPU driver: open-source
  • Kernel: OpenBSD
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #46 on: 29. April 2015, 08:27:51 »
I question the view that the "typical" use of Ob is for notebooks & netbooks?

Many users (I've been one of them for many years now -  well over 7 at this stage) don't like/need or have any use for the icon/menu based DE's out there. We usually really like to build our Ob setups to suit our peculiar & usually very customized ways of using our computer. We don't like anything on our machines that we don't use, & like very much those things that we do use.  :) Some OB (or other WM users) are minimalist by nature, others are not. We just don't need all of those menus, icons & bars all over the place.

For those readers that are amping up & getting ready to take me on in defence of their favourite DE (or whatever) don't. I'm not sticking it to your taste or needs, I'm just mentioning that their are other equally (not more or less equal, just equally) valid ways of choosing to interface with your OS.

Ob is far more than just being a way to save resources on a machine, it is a base for building a machine that has a quick, simple GUI, is very easy to customize & gets out of your way so that you can do the things that you want to do without having all of this other stuff hanging around doing nothing whilst it waits to (usually for a long time, sometimes forever) to be used gain.

I'm not saying the above to provoke one of those oh! so easily provoked my taste is better than your taste DE/WM wars. I'm just stating that there do exist other ways to look at light weight WM's & the reasons why people like to use them. I stuck to just Ob, & didn't even touch the tiling WM's that the terminal addicts love to use, for the primary reason that it suits their particular style of computing best.

The best things about GNU/Linux are that it is primarily about freedom of choice, freedom of expression & that it is also 99.99% free as in monetary cost. All of us can use it, modify it, create for it, make money out of it if we can & choose, if we wish, to support in in any number of ways that don't involve coding.

The worst things about GNU/Linux (these days at least, since hardware support is so much better now than it used to be) is that (& this is NOT pointed at anyone in this thread) there are those that have GNU/Linux (with or without the GNU or the Linux) egos that NEED to be right, they need to feel superior to others for any reason that they can find (GNU & or Linux just happen to be the vehicles that we - rarely in this forum thankfully - see them use)  This is both unfortunate & sad.

I don't have any secret remedy to offer on that one I'm sorry to say. Well, apart from once you have identified such a person, DON'T argue with them, as that is exactly the food that they need, it empowers them.

They aren't always trolls, though I think that they are cousins of trolls at best.
The ultimate tyranny in a society is not control
by martial law. It is control by the psychological
manipulation of consciousness, through which reality
is defined so that those who exist within do not even
realize that they are in prison.
  —  Barbara Marciniak

Offline mxx

  • Sr. Mitglied
  • ****
  • Posts: 420
  • Branch: stable
  • Desktop: Openbox/i3wm
  • Kernel: linux4
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #47 on: 29. April 2015, 12:27:16 »
I stuck to just Ob, & didn't even touch the tiling WM's that the terminal addicts love to use, for the primary reason that it suits their particular style of computing best.
There are some little but fundamental things that determine the choice between a tiling and a stacking window manager. They are profoundly different.

A tiling window manager isn't even a proper window manager. It's a tiles manager. You open tiles, not windows. Resizing or closing a tile means resizing other(s). Opening a new tile means adding a smaller one into the mix of current ones.

All this makes sense only when you open up things that demand equal attention at the same time, as in massive concurrent multitasking. It requires a huge screen in order to be able to actually see every little tile.

Working with tiles is not always possible and not always necessary. For example I use a netbook with a limited screen estate, so I have to have wholescreen windows more often than not. I open up webbrowsers and office software more often than terminals, and for a browser it does not make sense to sit in a tiny tile in some corner. It makes sense to have a browser mazimized or nearly maximized. And it's my preference to attend to a single task at a time, as far as possible.

So, the choice between a tiling and a stacking window manager is decided by the size of screen and the kind of windows that the user needs to open up. When you open browsers and office software more often than terminals, then this means big and real windows, and there's a need for a true window manager, not a tiles manager. Also, when you need access to the desktop, then tiling is not the way to go.

Having many maximised windows open means there should be one convenient way to switch between them, such as Alt+Tab, instead of having to think "left", "right", "up" and "down" in a directional way.

I don't think "stacking window manager" is an appropriate term. It's not about stacking. It's about switching between windows by cycling. It's about maximising, minimising, and resizing without affecting other open windows. In short, it's about windows, not about tiles.

Of course, i3wm is undeniably cool. And Pek is also cool. Pek has been nearly suitable for my purposes, but Openbox still wins, because it deals more with windows rather than tiles.

Tiles have their purpose too. Tiles make enormous sense when you need to follow a bunch of processes in separate terminals. This is what Tmux is for and I am quite familiar with it. I open up Tmux and do C-b, " and C-b, % a few times to create some tiles. Then I do C-b, o to cycle between the tiles. I can also create new windows with C-b, c and switch between them stacking-style with C-b, w. It's all great and perfect for terminals, but what you cannot do here is to resize a single window to get some access to desktop.

Then again, I do some tiling also outside Tmux. Sometimes I compare documents or texts, so I have, let's say a browser and a Word document open side by side. Openbox easily does snap-tiling this way. And this is pretty much all the tiling I need. I need proper windowing more often.

Offline mxx

  • Sr. Mitglied
  • ****
  • Posts: 420
  • Branch: stable
  • Desktop: Openbox/i3wm
  • Kernel: linux4
  • Skill: Intermediate
Max Windows
« Reply #48 on: 13. July 2015, 12:37:19 »
To get always maximized windows in your Openbox, add this to rc.xml in the <applications> section,

   <application class="*">
      <decor>no</decor>
      <maximized>yes</maximized>
    </application>
    <application type="dialog">
      <decor>yes</decor>
      <maximized>no</maximized>
    </application>

This will remove decorations (titlebar) and maximize all new windows. When you unmaximize the window, the window will get its normal state back, whichever way you configured it.

This setting makes good sense with small screens.

But dialogs and prompts will be exempted from maximization. Some apps don't have their dialog windows configured properly and will be maximized anyway, for example Seamonkey's download notification.

Additionally, you may want to exempt more apps from maximization, for example the messenger and the background image changer,

    <application class="Pidgin">
      <decor>yes</decor>
      <maximized>no</maximized>
    </application>
    <application class="Nitrogen">
      <decor>yes</decor>
      <maximized>no</maximized>
    </application>

Usually app names straightforwardly go into the class/name="" property, but to do this rightly, use obxprop this way:

- In terminal, type obxprop (it as if stalls, let it be)
- Switch to the window whose class/name info you want - change to it with keyboard, not with mouse
- Click on the window
- Turn back to the terminal and find the relevant class/name info to put into rc.xml.

Offline Chrysostomus

  • Maintainer
  • ***
  • Posts: 1634
  • Neckbeards are cool
    • Git
  • Branch: unstable
  • Desktop: Gnome, bspwm
  • GPU Card: Intel HD4000
  • GPU driver: free
  • Kernel: linux44-x64
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #49 on: 24. August 2015, 05:09:24 »
When I was using openbox actively my favourite customizations were:
- aerosnap keybindings http://crunchbang.org/forums/viewtopic.php?id=26400
- adding home folder menu to openbox menu http://crunchbang.org/forums/viewtopic.php?id=8753
- binding rootmenu to left clicking desktop,similar to enlightenment
- adding docky/plank/wbar
- trying to add skippy-xd for expose effect

Sorry for somewhat of topic:

Handy and mxx make good case for advantages of floating window managers in favor of tilers. Cycling windows not one of them though. Most tilers implement alt+tab somehow, and have easy way of maximizing windows, so attending to one task at the time is just as easy. And using other workspaces is tiling equilevant of minimizing windows.

Main advantage of tiling wms often are:
- paradigm more suited to multitasking and keyboard operation
- keys are easier to bind
- defaults for manipulating/operating workspaces are usually better (this can be remedied with 10min of configuration though)
- they are usually even lighter than openbox

Biggest advantages of floating wms are often:
- better standards complience, work often better together with bars, docks and panels
- better discoverability and lower learning curve
- work better with applications that open many windows, like gimp
- presentations are often easier with ad hoc multihead

But each to his own, I very much enjoy openbox and gnome even though I usually run bspwm. Openbox used to be my main system until I found that that some tilers are even more easier and efficient for me. I use notebook with small screen, and maximizing screen real estate just made sense. I find it convenient to tile office apps (I often need to compare documents), file managers (drag things between windows) and browser (copy and paste stuff in and out of browser). I find that on widescreen display, browser and documents usually really benefit from only 50-60% of screen widht, because webpages and document pages are modelled after paper sheets that are not as wide as the screen is.
« Last Edit: 24. August 2015, 05:28:10 by Chrysostomus »

Offline mxx

  • Sr. Mitglied
  • ****
  • Posts: 420
  • Branch: stable
  • Desktop: Openbox/i3wm
  • Kernel: linux4
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #50 on: 08. October 2015, 22:33:14 »
Here's something that Openbox can do natively, but i3wm cannot: Bind an action to all unfocused windows

For example, kill all windows except the focused one:

        <action name="ForEach">
          <focused>no</focused>
          <then>
        <action name="Close"/>
          </then>       
        </action>

Offline Chrysostomus

  • Maintainer
  • ***
  • Posts: 1634
  • Neckbeards are cool
    • Git
  • Branch: unstable
  • Desktop: Gnome, bspwm
  • GPU Card: Intel HD4000
  • GPU driver: free
  • Kernel: linux44-x64
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #51 on: 17. October 2015, 09:40:47 »
Depends on what you count native, I'm pretty sure you can do that with i3-msg, but yeah, seems way easier with openbox. Cool feature!  :)

Offline mxx

  • Sr. Mitglied
  • ****
  • Posts: 420
  • Branch: stable
  • Desktop: Openbox/i3wm
  • Kernel: linux4
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #52 on: 20. October 2015, 20:19:52 »
Depends on what you count native, I'm pretty sure you can do that with i3-msg, but yeah, seems way easier with openbox. Cool feature!  :)
By native I mean just tweaking the config file, not installing anything additional to achieve the effect.

Offline Chrysostomus

  • Maintainer
  • ***
  • Posts: 1634
  • Neckbeards are cool
    • Git
  • Branch: unstable
  • Desktop: Gnome, bspwm
  • GPU Card: Intel HD4000
  • GPU driver: free
  • Kernel: linux44-x64
  • Skill: Intermediate
Re: add your favorite openbox customizing tips here
« Reply #53 on: 27. October 2015, 09:06:32 »
Good definition

Offline darkcity

  • Neuling
  • *
  • Posts: 24
  • Branch: stable
  • Desktop: Openbox
  • GPU Card: [AMD/ATI] RV100 [Radeon 7000 / Radeon VE]
  • GPU driver: radeon
  • Kernel: Linux 3.10.13-1-MANJARO (x86_64)
  • Skill: Novice
Re: add your favorite openbox customizing tips here
« Reply #54 on: 08. November 2015, 12:42:52 »
you guys are putting me to shame with your advanced tips  ;D

here is a basic one i always enable numbers lock

install "numlockx"

go to your autostart file

Code: [Select]
## Basic compositing effects
compton -CGb &

## Background
nitrogen --restore &

## Panel
(sleep 1s && tint2) &

## Startup
(sleep 1s && pnmixer) &
(sleep 3s && conky) &
(sleep 3s && numlockx) &

Currently (by default) the numlockx line is in the autostart file, but numlockx isn't installed.