[Bug 174948] Add setting to set/force a specific layout for specific programs

Andriy Rysin arysin at gmail.com
Sun Apr 17 19:14:33 BST 2011


https://bugs.kde.org/show_bug.cgi?id=174948


Andriy Rysin <arysin at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |arysin at gmail.com




--- Comment #5 from Andriy Rysin <arysin gmail com>  2011-04-17 20:14:31 ---
I think that most of this wish will be covered with using "By Application"
switching mode. I am planning to push the fix for 52095 (No session management
in kxkb - it doesn't remembers the last layout) so that all modes except "by
window" will store the layout maps when exiting KDE (and restore session option
is ON in System Settings/Startup & Shutdown).

Thus in By Application mode when the application is active you will switch the
layout once and it'll be remembered unless you change the layout settings or
unselect "restore previous session".

Unfortunately I won't have time any time soon to add "hardcoded layout per
application". I will review the patch if somebody sends me one but from what I
can tell this feature is quite intrusive both UI- and code-wise so I would be
cautious about merging something like that. The codebase and feature count for
the layout switcher grown quite a bit these days so the more and more I am
thinking if the switcher does too much already (breaking the Unix-way) :)

As to the VirtualBox problem: I hate to put workarounds for bugs in other
programs into the code (I must say there's quite a bit of ugliness in xkb to
deal with already). But if it was a small tweak to fix some big annoyance I
could consider it. The problem is - you mentioned that the VB should be
*started* with predefined layout. And keyboard daemon has no control of
application start - it only gets notified when the window gets active (which is
too late) so in this case I don't think I could help here much. Seems like to
address this problem you'll need to add a notification to keyboard daemon that
some program is starting and then implement the whole feature I was talking
about. And it does not look like it's worth it. 
I'd say for bugs in other programs like this you'd want a two-liner script
instead, e.g.:
#/bin/bash
set_active_layout "ee"
VirtualBox

set_active_layout can be just a dbus call, e.g:
qdbus org.kde.keyboard /Layouts setLayout 'ee'

I would close this bug as fixed when 52095 is done but if you want to keep it
open please let me know.

-- 
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the Unassigned-bugs mailing list