You are not logged in.

#1 2009-04-08 21:28:20

DarkLikeHell
Member
Registered: 2009-02-07
Posts: 71

[SOLVED] Adding layouts and changing them per application

Hi
I have just installed openbox not a long ago, and I was wondering,
how can I add another keyboard layout? (Hebrew for example)
I heard that I can do it through xorg.conf, but then, changing layouts
will be globaly and not per application.
How can I add another layout to my openbox and change layout with
alt+shift per application?

Thanks smile

Last edited by DarkLikeHell (2009-04-09 21:41:46)

Offline

#2 2009-04-08 22:35:04

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: [SOLVED] Adding layouts and changing them per application

you can add a keybinding which changes the layout and then use that to switch layouts between apps. Of course this means you will have to use the keybinding every time you switch between a Hebrew app and a english (say) app


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#3 2009-04-08 23:31:43

DarkLikeHell
Member
Registered: 2009-02-07
Posts: 71

Re: [SOLVED] Adding layouts and changing them per application

Yes, this is what I prefer not to do.
If I am not wrong, this way will give me a global layout, and not a per-app layout.
For example, if I'll write in hebrew in my pidgin, and then I'll write something in the terminal, it will be in hebrew too.
Somehow gnome and kde can remember which layout is active in each app.
I think there's an app in the AUR called xxkb, but I don't know how to use and configure it.
(Sorry for my bad English:))

Offline

#4 2009-04-09 16:48:46

DarkLikeHell
Member
Registered: 2009-02-07
Posts: 71

Re: [SOLVED] Adding layouts and changing them per application

I think I'll use xxkb.
Does anyone know how to use it?
What are pixmaps?
How can I add a layout and switch between 2 layouts with alt + shift using xxkb?
It's really important, I'm trying to use Openbox without gnome daemons and settings sad
Thanks

Offline

#5 2009-04-09 21:45:14

DarkLikeHell
Member
Registered: 2009-02-07
Posts: 71

Re: [SOLVED] Adding layouts and changing them per application

Problem solved thanks to DHeart!
I created /etc/hal/fdi/10-keymap.fdi:

<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
 <device>
   <match key="info.capabilities" contains="input.keymap">
     <append key="info.callouts.add" type="strlist">hal-setup-keymap</append>
   </match>

   <match key="info.capabilities" contains="input.keys">
     <merge key="input.xkb.rules" type="string">base</merge>

     <!-- If we're using Linux, we use evdev by default (falling back to
          keyboard otherwise). -->
     <merge key="input.xkb.model" type="string">keyboard</merge>
     <match key="/org/freedesktop/Hal/devices/computer:system.kernel.name"
            string="Linux">
       <merge key="input.xkb.model" type="string">evdev</merge>
     </match>

     <merge key="input.xkb.layout" type="string">us,il</merge>
     <merge key="input.xkb.model" type="string">pc105</merge>
  <merge key="input.xkb.Options" type="string">grp:ctrl_shift_toggle</merge>
   </match>
 </device>
</deviceinfo>

I installed xxkb, and added "exec xxkb &" to my openbox's autostart script.
And it works almost perfect!

Last edited by DarkLikeHell (2009-04-10 08:03:49)

Offline

Board footer

Powered by FluxBB