Re: setting keyboard layout

2016-09-10 Thread Olivier Peyrusse
Hello Nulik,

in my answer, I suppose that you use the latest script version with
setxkbmap.

First thing first, if you look at the script, "Foo" being the 3rd parameter
(and lua being 1-index based), it will be the caption display in the widget
for your keyboard configuration.

kbdcfg.widget:set_text(" " .. t[3] .. " ")

Regarding the first and second params in the config, they are used in the
generated command configuring your keyboard mapping.

os.execute( kbdcfg.cmd .. " " .. t[1] .. " " .. t[2] )

Generating respectively `setxkbmap us   ` (blank spaces as 2nd is "") and
`setxkbmap us dvorak`
They served to select a special variant of your keyboard mapping. Without
variant, you get the default mapping.
Read manual of setxkbmap for full info.

Regarding your errors, I can't really say. Send your personal version of
the lua code so we can see what's wrong.

Cheers
Kineolyan

On Sat, Sep 10, 2016 at 3:42 PM Absolute Zero  wrote:

> Hi,
> I am having hard time configuring keyboard layout, I want russian ,
> english and spanish. But I do not understand how to configure. I am
> following the instructions from here:
> https://awesome.naquadah.org/wiki/Change_keyboard_maps
>
> But what does this mean:
>
> kbdcfg.layout = { { "us", "" , "Foo" }, { "us", "dvorak" , "Bar" } }
>
> 
>
> What should be Foo ??? What should be Bar ??? Why is the "us" parameter
>  duplicated ? Why there is an empty space as the second parameter in the
> first list? Are these two lists somewhat related to each other ?
> I have tried many options but I just get some weird errors in the log like
> these and nothing works:
>
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: >
>   Abandoning symbols file "default"
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: Errors from
> xkbcomp are not fatal to the X server
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: (EE) Error
> loading keymap /tmp/server-1.xkm
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: Error loading
> new keyboard description
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: The XKEYBOARD
> keymap compiler (xkbcomp) reports:
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: > Error:
>  No Symbols named "es" in the include file "us"
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: >
>   Exiting
> Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: >
>   Abandoning symbols file "default"
>
> Could someone explain the input parameters on the keyboard code snippet ?
>
>
> TIA
> Nulik
>


setting keyboard layout

2016-09-10 Thread Absolute Zero
Hi,
I am having hard time configuring keyboard layout, I want russian , english
and spanish. But I do not understand how to configure. I am following the
instructions from here:
https://awesome.naquadah.org/wiki/Change_keyboard_maps

But what does this mean:

kbdcfg.layout = { { "us", "" , "Foo" }, { "us", "dvorak" , "Bar" } }



What should be Foo ??? What should be Bar ??? Why is the "us" parameter
 duplicated ? Why there is an empty space as the second parameter in the
first list? Are these two lists somewhat related to each other ?
I have tried many options but I just get some weird errors in the log like
these and nothing works:

Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: >
Abandoning symbols file "default"
Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: Errors from
xkbcomp are not fatal to the X server
Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: (EE) Error
loading keymap /tmp/server-1.xkm
Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: Error loading
new keyboard description
Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: The XKEYBOARD
keymap compiler (xkbcomp) reports:
Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: > Error:
 No Symbols named "es" in the include file "us"
Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: >
Exiting
Sep 10 08:22:32 dev1.home /usr/libexec/gdm-x-session[7394]: >
Abandoning symbols file "default"

Could someone explain the input parameters on the keyboard code snippet ?


TIA
Nulik


Re: Setting keyboard layout per client

2012-04-05 Thread [email protected]
>
> ali.mousavi, don't you use Debian Wheezy? Some days ago I've got a strange
> issue with old configs for keyboard layout changing on Wheezy.


Sorry for answering so much late, I must have missed this email somehow.
I'm using Arch linux, my guess is that these packages are a little buggy
with the new systems and probably nobody cares that much to fix them. :)


Re: Setting keyboard layout per client

2012-03-16 Thread Dmitry Kuharev
ali.mousavi, don't you use Debian Wheezy? Some days ago I've got a strange
issue with old configs for keyboard layout changing on Wheezy.

Anyway, take Alexander's advice, setxbmap+kbdd should work for any system.

On Thu, Mar 15, 2012 at 3:23 PM, [email protected] <
[email protected]> wrote:

> hi,
> I wonder if anyone has a working way to set the keyboard leyout per
> client. I tried using xxkb which was suggested in the wiki[1], but it
> couldn't remember the layout for applications probably due to this bug[2].
> So I tried kbdd which is explained in the wiki[3], and it was the only
> thing that worked but I couldn't use the shortcut alt + shift to change the
> keyboard. sometimes the shortcut works, sometimes doesn't and this is
> pretty much annoying. changing the shortcuts using the mouse buttons seemed
> to be working as expected.
> so, if anyone has any advice I really appreciate it.
>
> [1]
> http://awesome.naquadah.org/wiki/FAQ#How_to_add_a_keyboard_layout_switcher_.3F
> [2] https://awesome.naquadah.org/bugs/index.php?do=details&task_id=476
> [3] http://awesome.naquadah.org/wiki/Keyboard_layouts_with_kbdd
>


Re: Setting keyboard layout per client

2012-03-15 Thread Alexander Yakushev

Hello Ali,

I use kbdd + setxkbmap for switching layouts with a shortcut. Add the 
following line to your autorun section of Awesome (or to .xinitrc):


 setxkbmap -layout 'us,ru' -variant ',winkeys' -option 
grp:alt_shift_toggle -option compose:ralt


Change "ru" to the layout you want. This command will also set your 
Right Alt to act as a compose key (so you can type nice things like ©®™å 
by holding Right Alt and pressing "o" and "c" for example).


Regards,
Alexander

On 03/15/2012 01:23 PM, [email protected] wrote:

hi,
I wonder if anyone has a working way to set the keyboard leyout per 
client. I tried using xxkb which was suggested in the wiki[1], but it 
couldn't remember the layout for applications probably due to this 
bug[2]. So I tried kbdd which is explained in the wiki[3], and it was 
the only thing that worked but I couldn't use the shortcut alt + shift 
to change the keyboard. sometimes the shortcut works, sometimes 
doesn't and this is pretty much annoying. changing the shortcuts using 
the mouse buttons seemed to be working as expected.

so, if anyone has any advice I really appreciate it.

[1] 
http://awesome.naquadah.org/wiki/FAQ#How_to_add_a_keyboard_layout_switcher_.3F
[2] https://awesome.naquadah.org/bugs/index.php?do=details&task_id=476 


[3] http://awesome.naquadah.org/wiki/Keyboard_layouts_with_kbdd




Setting keyboard layout per client

2012-03-15 Thread [email protected]
hi,
I wonder if anyone has a working way to set the keyboard leyout per client.
I tried using xxkb which was suggested in the wiki[1], but it couldn't
remember the layout for applications probably due to this bug[2]. So I
tried kbdd which is explained in the wiki[3], and it was the only thing
that worked but I couldn't use the shortcut alt + shift to change the
keyboard. sometimes the shortcut works, sometimes doesn't and this is
pretty much annoying. changing the shortcuts using the mouse buttons seemed
to be working as expected.
so, if anyone has any advice I really appreciate it.

[1]
http://awesome.naquadah.org/wiki/FAQ#How_to_add_a_keyboard_layout_switcher_.3F
[2] https://awesome.naquadah.org/bugs/index.php?do=details&task_id=476
[3] http://awesome.naquadah.org/wiki/Keyboard_layouts_with_kbdd