OpenBox

From Pandora Wiki
Revision as of 19:56, 10 December 2012 by CountOrlock (talk | contribs) (rc.xml)
Jump to: navigation, search

Default Config

Default Keybindings

  • Root Menu: "Pandora Key" or "Ctrl-M" "Right-Nub-Right-Click"
  • Go To Desktop 1: Alt DPAD-left
  • Go To Desktop 2: Alt DPAD-right
  • Send To Desktop 1: Ctrl DPAD-left
  • Send To Desktop 2: Ctrol DPAD-right
  • Client Menu: Alt DPAD-up
  • Switch Applications: Alt DPAD-down
  • Toggle Maximize: Ctrl DPAD-up
  • Toggle Shade: Ctrl DPAD-down
  • Quit Application: Ctrl-q

Customize your environment

  • start-up file: /usr/bin/openbox-session
  • pnd menu: /etc/xdg/menus/openbox-pnd.menu
  • root menu: /home/<yourname>/Applications/Settings/openbox/menu.xml
  • openbox settings: /home/<yourname>/Applications/Settings/openbox/rc.xml
  • execute before openbox starts: /home/<yourname>/Applications/Settings/openbox/environment
  • execute after openbox starts: /home/<yourname>/Applications/Settings/openbox/autostart
  • manually add stuff to warlock bar: /home/<yourname>/Applications/Settings/openbox/wbar_custom.cfg

CountOrlock Config

rc.xml

This a work in process config, so please be aware that you use it at your own risk. Here is the main bindings:

  • Root Menu: "Pandora Key"
  • Window Listing and Desktop Management Menu: Shift "Pandora Key"
  • Client Menu: Ctrl Space
  • Next Window: Ctrl DPAD-Right
  • Previous Window: Ctrl DPAD-Left
  • Toggle Maximize: Ctrl DPAD-up
  • Toggle FullScreen (No Decoration): Ctrl o
  • Toggle Desktop: Ctrl u
  • Window on left side : Ctrl j
  • Window on right side : Ctrl k
  • Window on half top : Ctrl i
  • Window on half bottom : Ctrl m
  • Quit Application: Ctrl-q
  • Launch urxvt : Ctrl Shift t
  • Launch Thunar : Ctrl Shift f

And this is the content of the rc.xml, make a backup of your config before tying this. :

 
 <?xml version="1.0" encoding="UTF-8"?>
 <openbox_config xmlns="http://openbox.org/3.4/rc" xmlns:xi="http://www.w3.org/2001/XInclude">
  <resistance>
    <strength>10</strength>
    <screen_edge_strength>20</screen_edge_strength>
  </resistance>
  <focus>
    <focusNew>yes</focusNew>
    <followMouse>no</followMouse>
    <focusLast>yes</focusLast>
    <underMouse>no</underMouse>
    <focusDelay>200</focusDelay>
    <raiseOnFocus>no</raiseOnFocus>
  </focus>
  <placement>
    <policy>Smart</policy>
    
yes
<monitor>Primary</monitor> <primaryMonitor>1</primaryMonitor> </placement> <theme> <name>Clearlooks</name> <titleLayout>NLIMC</titleLayout> <keepBorder>yes</keepBorder> <animateIconify>yes</animateIconify> <name>Sans</name> <size>9</size> <weight>Bold</weight> <slant>Normal</slant> <name>Sans</name> <size>9</size> <weight>Bold</weight> <slant>Normal</slant> <name>Sans</name> <size>10</size> <weight>Normal</weight> <slant>Normal</slant> <name>Sans</name> <size>10</size> <weight>Normal</weight> <slant>Normal</slant> <name>Sans</name> <size>10</size> <weight>Bold</weight> <slant>Normal</slant> <name>Sans</name> <size>10</size> <weight>Bold</weight> <slant>Normal</slant> </theme> <desktops> <number>1</number> <firstdesk>1</firstdesk> <names> <name>Desktop 1</name> </names> <popupTime>875</popupTime> </desktops> <resize> <drawContents>yes</drawContents> <popupShow>Nonpixel</popupShow> <popupPosition>Center</popupPosition> <popupFixedPosition> <x>10</x> <y>10</y> </popupFixedPosition> </resize> <margins> <top>0</top> <bottom>0</bottom> <left>0</left> <right>0</right> </margins> <dock> <position>TopRight</position> <stacking>Above</stacking> <direction>Vertical</direction> <autoHide>no</autoHide> <hideDelay>300</hideDelay> <showDelay>300</showDelay> <moveButton>Middle</moveButton> <decor>no</decor> <border>no</border> </dock> <keyboard> <keybind key="XF86MenuKB"> <action name="ShowMenu"> <menu>root-menu</menu> </action> </keybind> <keybind key="S-XF86MenuKB"> <action name="ShowMenu"> <menu>client-list-combined-menu</menu> </action> </keybind> <keybind key="C-Up"> <action name="ToggleMaximizeFull"> <finalactions> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </finalactions> </action> </keybind> <keybind key="C-Down"> <action name="Iconify"> </action> </keybind> <keybind key="C-o"> <action name="ToggleFullscreen"> </action> </keybind> <keybind key="C-u"> <action name="ToggleShowDesktop"/> </keybind> <keybind key="C-Left"> <action name="PreviousWindow"> <finalactions> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </finalactions> </action> </keybind> <keybind key="C-Right"> <action name="NextWindow"> <finalactions> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </finalactions> </action> </keybind> <keybind key="C-q"> <action name="Close"/> </keybind> <keybind key="C-space"> <action name="ShowMenu"> <menu>client-menu</menu> </action> </keybind> <keybind key="C-k"> <action name="MoveResizeTo"> <x>-0</x> <y>0</y> <width>50%</width> <height>460</height> <finalactions> <action name="Unmaximize"/> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </finalactions> </action> </keybind> <keybind key="C-j"> <action name="MoveResizeTo"> <x>0</x> <y>0</y> <width>50%</width> <height>460</height> <finalactions> <action name="Unmaximize"/> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </finalactions> </action> </keybind> <keybind key="C-i"> <action name="MoveResizeTo"> <x>0</x> <y>0</y> <width>100%</width> <height>230</height> <finalactions> <action name="Unmaximize"/> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </finalactions> </action> </keybind> <keybind key="C-m"> <action name="MoveResizeTo"> <x>0</x> <y>-0</y> <width>100%</width> <height>230</height> <finalactions> <action name="Unmaximize"/> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </finalactions> </action> </keybind> <keybind key="C-S-t"> <action name="Execute"> <command>urxvt -title "Pandora Term"</command> </action> </keybind> <keybind key="C-S-f"> <action name="Execute"> <command>thunar</command> </action> </keybind> </keyboard> <mouse> <dragThreshold>1</dragThreshold> <doubleClickTime>200</doubleClickTime> <screenEdgeWarpTime>400</screenEdgeWarpTime> <screenEdgeWarpMouse>false</screenEdgeWarpMouse> <context name="Frame"> <mousebind button="A-Left" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> <mousebind button="A-Left" action="Click"> <action name="Unshade"/> </mousebind> <mousebind button="S-Left" action="Drag"> <action name="Move"/> </mousebind> <mousebind button="A-Right" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="A-Right" action="Drag"> <action name="Resize"/> </mousebind> <mousebind button="A-Middle" action="Press"> <action name="Lower"/> <action name="FocusToBottom"/> <action name="Unfocus"/> </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> <mousebind button="C-A-Up" action="Click"> <action name="GoToDesktop"> <to>previous</to> </action> </mousebind> <mousebind button="C-A-Down" action="Click"> <action name="GoToDesktop"> <to>next</to> </action> </mousebind> <mousebind button="A-S-Up" action="Click"> <action name="SendToDesktop"> <to>previous</to> </action> </mousebind> <mousebind button="A-S-Down" action="Click"> <action name="SendToDesktop"> <to>next</to> </action> </mousebind> </context> <context name="Titlebar"> <mousebind button="Left" action="Drag"> <action name="Move"/> </mousebind> <mousebind button="Left" action="DoubleClick"> <action name="ToggleMaximize"/> </mousebind> <mousebind button="Up" action="Click"> <action name="if"> <shaded>no</shaded> <then> <action name="Shade"/> <action name="FocusToBottom"/> <action name="Unfocus"/> <action name="Lower"/> </then> </action> </mousebind> <mousebind button="Down" action="Click"> <action name="if"> <shaded>yes</shaded> <then> <action name="Unshade"/> <action name="Raise"/> </then> </action> </mousebind> </context> <context name="Titlebar Top Right Bottom Left TLCorner TRCorner BRCorner BLCorner"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="Middle" action="Press"> <action name="Lower"/> <action name="FocusToBottom"/> <action name="Unfocus"/> </mousebind> <mousebind button="Right" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="ShowMenu"> <menu>client-menu</menu> </action> </mousebind> </context> <context name="Top"> <mousebind button="Left" action="Drag"> <action name="Resize"> <edge>top</edge> </action> </mousebind> </context> <context name="Left"> <mousebind button="Left" action="Drag"> <action name="Resize"> <edge>left</edge> </action> </mousebind> </context> <context name="Right"> <mousebind button="Left" action="Drag"> <action name="Resize"> <edge>right</edge> </action> </mousebind> </context> <context name="Bottom"> <mousebind button="Left" action="Drag"> <action name="Resize"> <edge>bottom</edge> </action> </mousebind> <mousebind button="Right" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="ShowMenu"> <menu>client-menu</menu> </action> </mousebind> </context> <context name="TRCorner BRCorner TLCorner BLCorner"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="Left" action="Drag"> <action name="Resize"/> </mousebind> </context> <context name="Client"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> <mousebind button="Middle" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> <mousebind button="Right" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> </context> <context name="Icon"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> <action name="ShowMenu"> <menu>client-menu</menu> </action> </mousebind> <mousebind button="Right" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="ShowMenu"> <menu>client-menu</menu> </action> </mousebind> </context> <context name="AllDesktops"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="Left" action="Click"> <action name="ToggleOmnipresent"/> </mousebind> </context> <context name="Shade"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> <mousebind button="Left" action="Click"> <action name="ToggleShade"/> </mousebind> </context> <context name="Iconify"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> <mousebind button="Left" action="Click"> <action name="Iconify"/> </mousebind> </context> <context name="Maximize"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="Middle" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="Right" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="Left" action="Click"> <action name="ToggleMaximize"/> </mousebind> <mousebind button="Middle" action="Click"> <action name="ToggleMaximize"> <direction>vertical</direction> </action> </mousebind> <mousebind button="Right" action="Click"> <action name="ToggleMaximize"> <direction>horizontal</direction> </action> </mousebind> </context> <context name="Close"> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> <action name="Unshade"/> </mousebind> <mousebind button="Left" action="Click"> <action name="Close"/> </mousebind> </context> <context name="Desktop"> <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> <mousebind button="C-A-Up" action="Click"> <action name="GoToDesktop"> <to>previous</to> </action> </mousebind> <mousebind button="C-A-Down" action="Click"> <action name="GoToDesktop"> <to>next</to> </action> </mousebind> <mousebind button="Left" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> <mousebind button="Right" action="Press"> <action name="Focus"/> <action name="Raise"/> </mousebind> </context> <context name="Root"> <mousebind button="Middle" action="Press"> <action name="ShowMenu"> <menu>client-list-combined-menu</menu> </action> </mousebind> <mousebind button="Right" action="Press"> <action name="ShowMenu"> <menu>root-menu</menu> </action> </mousebind> </context> <context name="MoveResize"> <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> </context> </mouse> <menu><file>menu.xml</file><showicons>yes</showicons><hideDelay>200</hideDelay><middle>no</middle><submenuShowDelay>100</submenuShowDelay><submenuHideDelay>400</submenuHideDelay> if this is a negative value, then the delay is infinite and the submenu will not be hidden until a different submenu is opened --> <applicationIcons>yes</applicationIcons> <manageDesktops>yes</manageDesktops> </menu> <applications> <application name="mousepad"> <maximized>true</maximized> </application> </applications> </openbox_config>

menu.xml

Menu changed to get easy access to config files as I spend a lot of time tuning them. So nothing new, items are just at different place. <?xml version="1.0" encoding="UTF-8"?> <openbox_menu xmlns="http://openbox.org/3.4/menu"> <menu id="PNDs-menu" label="PNDs" execute="openbox-menu /etc/xdg/menus/openbox-pnd.menu" /> <menu id="Config-menu" label="Config" execute="openbox-functions configmenu" /> <menu id="Status-menu" label="Status" execute="openbox-functions showstatus" /> <menu id="root-menu" label="Openbox 3"> <menu id="PNDs-menu" /> <separator /> <menu id="Config-menu" /> <separator /> <menu id="Status-menu" /> <separator /> <item label="Toggle Bluetooth" icon="/usr/share/icons/hicolor/32x32/apps/bluetooth.png"> <action name="Execute"> <command>/usr/pandora/scripts/op_bluetooth.sh</command> </action> </item> <item label="Toggle WiFi" icon="/usr/share/icons/openbox/wifi.png"> <action name="Execute"> <command>sudo /usr/pandora/scripts/op_wifi.sh</command> </action> </item> <item label="Edit Connections" icon="/usr/share/icons/gnome/32x32/status/network-idle.png"> <action name="Execute"> <command>nm-connection-editor</command> </action> </item> <item label="Auto Connect" icon="/usr/share/icons/gnome/32x32/status/network-transmit.png"> <action name="Execute"> <command>openbox-functions autoconnect</command> </action> </item> <item label="Toggle USB Host" icon="/usr/share/icons/openbox/op_usbhost.png"> <action name="Execute"> <command>/usr/pandora/scripts/op_usbhost.sh</command> </action> </item> <item label="Toggle System Tray " icon="/usr/share/icons/gnome/32x32/actions/remove.png"> <action name="Execute"> <command>openbox-functions togglesystray</command> </action> </item> <item label="Toggle Warlock Bar " icon="/usr/share/pixmaps/wbar/wbar.png"> <action name="Execute"> <command>openbox-functions togglewbar</command> </action> </item> <separator /> <item label="PND Installer" icon="/usr/share/icons/gnome/32x32/status/software-update-available.png"> <action name="Execute"> <command>openbox-functions pndinstaller</command> </action> </item> <item label="File Manager" icon="/usr/share/icons/gnome/32x32/apps/system-file-manager.png"> <action name="Execute"> <command>Thunar</command> </action> </item> <item label="Terminal" icon="/usr/share/icons/gnome/32x32/apps/utilities-terminal.png"> <action name="Execute"> <command>urxvt -title "Pandora Term"</command> </action> </item> <separator /> <item label="Switch GUI" icon="/usr/share/icons/openbox/switchgui.png"> <action name="Execute"> <command>/usr/pandora/scripts/op_switchgui.sh</command> </action> </item> <item label="Shutdown"> <action name="Execute"> <command>openbox-functions shutdown</command> </action> </item> </menu> </openbox_menu>