Openbox: keycodes and keybindings

I've got a six year old very basic Logitech wireless keyboard with 8 hotkeys (inc volume). I've found the keycodes using showkey, but I can't get them to do anything. I'm trying to get keycode 172 (hexadecimal AC) to start Firefox, and keycode 156 (hex 9C) to start xterm, with the following code in my home/USERNAME/.config/openbox/rc.xml:
<!-- Keybindings for running applications -->
<keybind key="0xAC">
<action name="Execute">
<startupnotify>
<enabled>true</enabled>
<name>firefox</name>
<wmclass>Firefox</wmclass>
</startupnotify>
<command>firefox</command>
</action>
</keybind>
<keybind key="0x9C">
<action name="Execute"><command>xterm</command></action>
</keybind>
<keybind key="W-e">
<action name="Execute">
<startupnotify>
<enabled>true</enabled>
<name>Konqueror</name>
</startupnotify>
<command>kfmclient openProfile filemanagement</command>
</action>
</keybind>
<!-- Other keybindings -->
<keybind key="C-Escape">
<action name="Exit">
</action>
</keybind>
My Other keybinding C-Escape to exit openbox works fine, but why not the hotkeys?
Last edited by dameunmate (2010-07-16 14:06:26)

I just tried that but it didn't work. Uninstalled and deleted xbindkeys.
But a small change to home/USERNAME/.config/openbox/rc.xml does work, the following code starts firefox when I press the key with keycode 172:
<keybind key="XF86HomePage">
<action name="Execute">
<execute>firefox</execute>
</action>
</keybind>
Why is is that <keybind key="XF86HomePage"> does work but <keybind key="0xAC"> does not work? 0xAC = 172 in decimal = the correct keycode for the XF86HomePage button, so why doesn't that work? It should work in Openbox, see http://openbox.org/wiki/Help:Bindings#Key_combination: "Keys can also be specified by their numeric codes. This can be done by specifying the keycode in hex." I have another keyboard with loads of extra keys so I need to be able to use keycodes in rc.xml
Last edited by dameunmate (2010-07-16 14:05:01)

Similar Messages

  • [SOLVED]openbox-xdgmenu and setting up

    hey guys
    ive installed openbox-xdgmenu. ( yes i read the wiki, im still confused ), ive added as suggested after installation
    <menu id="xdg-apps" label="Applications" execute="openbox-xdgmenu /etc/xdg/menus/applications.menu" />
    To the top area of my menu.xml
    Then i reset openbox
    And it wont show up in the menu. so im just abit confused in where to go from here
    Last edited by nankura (2012-07-18 14:50:41)

    i figured it out, i apologise for the rash post x.x, i forgot to add the link under the openbox rootmenu in the menu.xml

  • GDM and OpenBox - Wallpaper and background problem [SOLVED]

    I have a strange problem.
    I am using GDM as login manager. And I am using OpenBox as a window manager.
    As soon as GDM appears on the screen, my wifi connection is connected... so its good.
    But, when I login Feh loads my background picture and it disappears after few seconds..... I solved this modifying the autostart script (adding the sleep).
    Now background stays, BUT not always. Sometimes it disappears.... sometimes not.
    It seams that this problem is appearing randomly.
    So my question is:
    Is there a way to disable Gnomes (GDMs) background color and picture after loading openbox through GDM?
    Last edited by webmasteryoda (2011-06-26 10:50:10)

    azleifel wrote:
    It will apply to gnome as well, so if gnome-settings-daemon is your problem then you either need to choose one environment or perhaps do some settings adjustment with gconftool-2 when you log into each environment.  I didn't try this but settings for openbox could be changed with a couple of gconftool-2 lines in autostart.sh, e.g.
    gconftool-2 --set --type bool /desktop/gnome/background/draw_background "false" &
    and settings for gnome could be changed from a DE-specific ("OnlyShowIn=GNOME") .desktop file or two in $HOME/.config/autostart.
    I tried this, but it didnt work. Its a Gnome 3.
    I dont understand second part of your post... ("OnlyShowIn=GNOME")

  • Xmonad: startup programs and keybindings

    hi!
    i'm using xmonad since 2 weeks and so far i'm really satisfied with it. but i have 2 problems which i can not solve, so any help would be appreciated:
    1. is there a way to turn off/on all keybindings on the fly?
    2. i have several startup programs which are correctly moved to the specified workspace upon start. however, the order of the programs on each workspace is kind of random. for example, i would like to have a shell on the left side, and another program on the right side. how can i achieve this?
    thanks in advance!

    Go here for your support page and enter your full model number then select the drivers tab, then down on left side select your opersting system for your drivers. http://support.toshiba.com/home
    S70-ABT2N22 Windows 7 Pro & 8.1Pro, C55-A5180 Windows 8.1****Click on White “Kudos” STAR to say thanks!****

  • Keyboard remapping - scancodes/keycodes and Fn key

    Hello,
    I'm using Archlinux on a MacBook Pro and I'm overall pretty happy.
    However I desperately want to swap my Fn and Control keys. I know that this is a tricky business but I also know that this can be done in OS X via a kext module, so I hope it can be done in Linux as well.
    The output of showkey prints when I press Fn:
    keycode 464 press
    keycode 464 release
    showkey -s however prints nothing when I press just Fn.
    Here's the output of evtest:
    Event: time 1396031474.937906, -------------- SYN_REPORT ------------
    Event: time 1396031475.169971, type 1 (EV_KEY), code 464 (KEY_FN), value 1
    It does not print an EV_MSC line as the Control key does:
    Event: time 1396031475.561965, -------------- SYN_REPORT ------------
    Event: time 1396031475.729966, type 4 (EV_MSC), code 4 (MSC_SCAN), value 700e0
    Event: time 1396031475.729966, type 1 (EV_KEY), code 29 (KEY_LEFTCTRL), value 1
    So, it looks like my plan to remap the keys using scancodes (via setkeycodes) will not work. Remapping via loadkeys (keycode 464 = Control) also does not work - the Fn+<letter> combination is treated as if just the letter has been pressed.
    I will appreciate any kind of help as I am pretty stuck at this point.
    Thanks!
    P.S.: Sorry if the topic is in the wrong forum.

    I do not have a Thinkvantage folder in Control Panel.
    I was unable to find any reference on Lenovo's site for the T500 for keyboard customization.
    I  took you original advice, before editing, and installed the Keyboard customizer for the T400.  This works as expected for the T500.  I looked through the programs supplied by Lenovo for the T500 and could not find any program for the keyboard on my system. 
    I have removed some of the less than useful Lenovo configuration and control programs maybe that is the reason for the missing Control Panel folder.  Many seem to be slow to get things right and often get things wrong, but that is another thread.  I do not understand why IBM and now Lenovo keep making programs that are redundant with small gain relative to standard Windows features.  I have found the WiFi and Wired networking particularly difficult to get working smoothly.  The only solution is to turn off the WiFi.
    Now if you have a reason for 4 displays, 2 ATi, and 2 Intel Mobile in the windows display confguration panel on my system I will be forever grateful.
    Anyway thank you for you help in finding a solution to my external keyboard customization problem.

  • [SOLVED] Xorg Hotplug, Openbox, CLI and native characters and fonts

    -- according to a suggestion from: http://bbs.archlinux.org/viewtopic.php? … 82#p683282 am posting this as  a separate thread--
    Does anyone happen to encounter the following problem.
    Before the update: no local (polish) characters in the GUI apps when I type (openbox) but the characters in CLI apps run under openbox display fonts correctly while typing
    After the update, situation is reversed (i have tried to configure the hal policy but apparently I am missing something)
    GUI apps under openbox display polish fonts correctly when I type and CLI apps (tilda, gvim, etc) dispplay '?' instead of local charcters when I type
    Displaying previously created files which include polish characters display squares insted of the aforementioned glyphs.
    I have tried numerous hints found on the web:
    - modification of the 10-keymap.fdi file
    - regenerate locale
    - set xset fp+ /usr/share..
    ...but I'm running out of ideas.
    So if any of you knows how to get rid of that crappy behaviour please share your priceless knowledge smile
    BTW. under KDE everything seems to work fine...
    Last edited by psycepa (2010-05-04 22:01:28)

    locale -a
    C
    POSIX
    en_US
    en_US.iso88591
    en_US.utf8
    pl_PL
    pl_PL.iso88592
    pl_PL.utf8
    polish
    I am using Terminus for most of my CLI apps.
    The Konsole app is somehow and exception if I set Terminus Font and UTF-8 or ISO-8859-2 encoding, but the fonts are ugly, like here:
    other apps do not work no matter what I set.
    The point is it was working well before xorg hotplugging was enabled. Afterwards...you can see yourelf...
    @tomk: I'll try, but this should have nothing to do with specific nation whatsoever
    edit:
    I don't know if that does matter but its arch64...
    Last edited by psycepa (2010-01-07 13:28:29)

  • Urxvt won't get transparent with openbox, rgba and xcompmgr

    Hello!
    Yesterday I had a nice working openbox setup with real transparency in urxvt using
    Urxvt*background: rgba:0000/0000/0000/bbbb
    in ~/.Xdefaults.
    Then I did some fiddling around with vga boot options to get a nicer console, and realized the terminals in openbox was not transparent anymore. I thought of it as a framebuffer issue with the nvidia driver, and set everything back to normal again. That did nothing however, the urxvt was still not transparent.
    Reinstalled arch this morning for the sake of it, but I still can't get urxvt transparent with xcompmgr. Compositing seems to work with drop shadows and transset, but not when using rgba for urxvt.
    Any ideas what I've done wrong?
    My Xorg.0.log shows no errors.

    Ah, thank you!
    I forgot to change it back after I did some troubleshooting...it's all working now!

  • My iPad air is disabled because I endeterd the wong keycode and now and will not enter recovery mode

    My iPad air is disabled because I endeterd the wong keycode too many times and now and will not enter recovery mode. I haven't a clue what to do next?

    Follow the steps in this Apple support page.
    Forgot passcode for your iPhone, iPad, or iPod touch, or your device is disabled - Apple Support
    If you must use Recovery Mode, which is at the bottom of the linked page, follow all steps very carefully. Even hen you might have to try several times.

  • LXDE (Openbox) Fullscreen and Layer Problems

    Hi,
    I run the console "Terminator" as a wallpaper and I sometimes use in fullscreen mode on occasion.    I've noticed that once Terminator is in fullscreen, it's "always on top" despite being in the bottom layer.  From fullscreen back to normal mode, it's in the bottom again.  It's not just with Terminator but all applications are behaving the same way (fullscreen ==> always on top).
    I've then binded the "F6 key" to toggle the Raise/Lower window functionality in my ~/.config/openbox/lxde-rc.xml file.  That did not do the trick either.  Is there a way to make an application to keep their layers even in fullscreen?
    Thanks in advance~

    Do you use a composition manager? Any application specific settings in rc.xml?
    Last edited by emeres (2014-05-30 17:54:40)

  • [Openbox] Margins and Screenlets, Settings Manager

    Hi everyone!
    I have a few openbox questions. I installed screenlets to use the Launcher for starting programms. Everything works fine and I added
    /usr/share/screenlets/Launcher/LauncherScreenlet.py &
    to my autostart. Then I defined a margin and moved the launchers inside the margin. But on next start they were moved outside the margin. I found that someone asked that question for conky and so I tried changing my autostart to
    (sleep 5 && /usr/share/screenlets/Launcher/LauncherScreenlet.py) &
    But that doesn't work either. Has anyone an idea how to get this done?
    Next qustion, I couldn't find out how to change things like brightness and energy options, for example when the screen should turn off. Could I change everything with xfce-mcs-manager or gnome-settings-deamon or is there a better solution for it?
    Cheers, Mario

    In regards to the energy options I use laptop-mode-tools, pm-utils, cpufrequtils to controls screen brightness and other low-energy settings on my netbook. Nice lightweight options if you don't have have Gnome installed.
    Check out the power management section of the laptop wiki article
    http://wiki.archlinux.org/index.php/Laptop
    Last edited by bearman51 (2010-07-21 19:29:49)

  • JSplitPane, focus and keybindings

    Just noticed that the JSplitPane is a bit crazy regarding its keybindings (example below)
    - bindings are defined in When_Ancestor, that's the good part
    - they only work if the splitpane itself is focused
    This requires additional activity for the user: needs to press f8 (and know about that particular binding, me didn't until browsing the bug parade) to first focus, than move the divider
    The culprit is BasicSplitPaneUI.Actions in collaboration with Handler:
    // actionPerformed
      if (ui.dividerKeyboardResize) {
            // move the divider
    // handler focusLost
      ui.dividerKeyboardResize = false;Any ideas how to make them work as expected (that is move the divider if focus somewhere in the child hierarchy, provided no child consumes it) - short of c&p the actions without that check?
    Thanks
    Jeanette
    public class SplitPaneKeyBindings {
        private JComponent createContent(boolean focusable) {
            JButton button = new JButton("left");
            button.setFocusable(focusable);
            JButton other = new JButton("right");
            other.setFocusable(focusable);
            JSplitPane pane = new JSplitPane();
            pane.setLeftComponent(button);
            pane.setRightComponent(other);
            return pane;
        public static void main(String[] args) {
            SwingUtilities.invokeLater(new Runnable() {
                @Override
                public void run() {
                    JFrame frame = new JFrame("");
                    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                    frame.add(new SplitPaneKeyBindings().createContent(true));
                    frame.setLocationRelativeTo(null);
                    frame.setSize(400, 200);
                    frame.setVisible(true);
    }

    You can (and should, I guess) use the component's input and action maps.
    Kind regards,
      Levi

  • [SOLVED] OpenBox - Transparency and Virtual Desktop Switcher

    Hi All
    I've just recently, in the last 2 days, switched from Gnome 3.2 to Openbox. I've never really used it before except for a short period on #! as I recall. I've a couple of problems I don't seem to be able to find any answers to and hopefully someone on here already knows how:
    1) I'm using Guake dropdown terminal - I don't mind switching to any other terminal if necessary. I can't get transparency to work correctly with it though. I've installed the following to try to resolve the issue:
    Cairo Composite Manager
    transset-df
    If I issue the command:
    transset-df -n 'Guake!' &
    the Guake terminal sets to transparent which is great. However, as soon as the window retracts and I call it back again the transparency has switched off.
    2) I've installed tint2 and it's pretty good. Problem is I can't find a way to get a virtual desktop switcher. Again, this choice isn't cast in stone, I'm quite happy to change to any other application, or set of applications, to achieve the following:
    Virtual Desktop Switcher - i like the way pypanel does this actually. I'm happy enough with the mouse wheel switching desktops but I'd like some indication of which desktop I'm on.
    Date and Time with a calendar - I've got Orca working quite well on a click on the clock for the calendar.
    I would have thought this was pretty simple to resolve really, it's just that i don't know Openbox that well yet and I could use some advice on the best way to resolve the issues.
    Thanks in advance
    Rich
    Last edited by RichAustin (2011-10-23 09:20:13)

    I've actually managed to resolve the transparency issue as well.
    sudo pacman -S devilspie xcompmgr transset-df
    Then in .config/openbox/autostart:
    # Start Composite Manager
    xcompmgr &
    # Start Devilspie to alter windows
    devilspie -a &
    # Start Main Panel
    tint2 &
    Finally, create a file in .devilspie called guake.ds with the following content:
    (if
    (is (window_name) "guake.py" )
    (begin
    (spawn_sync (str "transset-df -i " (window_xid) " 0.5") )

  • [solved]Openbox margins and Conky

    I have a 1 line conky that i want to remain at the top of my screen at all times. I set up a margin in openbox to leave enough pixels at the top to comfortably fit the conky. The problem is that when i first boot to my desktop conky is placed below the margin. If i restart X however conky is right where i want it in the margin. Does anyone know how to put conky in the right place the first time?
    .conkyrc is setup for top_left placement and theres only a few pixels on the y axis from the top.
    I call conky from .xinitrc  before openbox
    I can't think of any other relevant info but let me know!
    Last edited by czar (2008-06-04 01:18:09)

    B wrote:
    The function created with the brackets, combined with the ampersand, puts the whole sequence in the background, so .xinitrc will not stop being parsed for that whole time.
    Don't worry, the guy knows what he's talking about...
    thanks for clearing that up. I read the parenthesis as English not as code. sorry for doubting you redroar!
    And moljac, i'll check that out when i get home, thanks.
    Last edited by czar (2008-06-02 17:54:29)

  • Openbox + AWN and achieving a sleek look

    hey guys
    Im planning on using AWN with openbox. ive seen alot of screenshots like so http://www.flickr.com/photos/kr-hibiki/5160108080/
    ( his description is in another langauge, i cant understand it )
    and i want to achieve something sleek, something nice like that, so im wondering if someone can point me in the right direction to getting that sleek style with openbox and awn. i have tried before, ive googled themes, theres alot of tweaking involved with awn

    I happen to be fluent in any language (well, kind of ): try this
    Good resources for customising AWN are plentiful on the web. Maybe start here, here. or here.

  • I lost my keycode and can`t reset my iphone 4

    please, i can not reset my iphone because i  lost the key code

    If you have forgotten your lockscreen password, connect in recovery mode and restore, you'll get the option to reset the passcode during this process:
    iOS: Unable to update or restore and iPhone and iPod touch: Wrong passcode results in red disabled screen
    If you cannot remember the passcode, you will need to restore your device using the computer with which you last synced it. This allows you to reset your passcode and resync the data from the device (or restore from a backup). If you restore on a different computer that was never synced with the device, you will be able to unlock the device for use and remove the passcode, but your data will not be present. Refer to Updating and restoring iPhone, iPad and iPod touch software.

Maybe you are looking for