I'll tell you what eventually worked best for me.
- Open the gnome preference "keyboard layout" pane
- Move the layout order, if you have more than one
- Delete all layouts except the default one (mine was a US layout)
The previous two steps have been suggested as fixes on their own (on the Ubuntu forums?). They did not work for me. I tried them together consecutively and this again did not work for me. Thus my next step.
- Press, "Reset to Defaults"
- Layout changes effectuated from both the layout pane and indicator now result in a change in layout.
- Of course, add layouts back before attempting to change to them. Use the preview function to find a layout that easily produces the diacritical marks you seek.
I think my problem was from the fact that some of the layouts had changed in name, at least that's my take considering that the layout names weren't exactly what I expected when reassigning them. Deleting my extra layouts and then assigning new ones from a fresh list seems to have circumvented my issues, that being that the layouts of my choice now point to existing layouts with names to match.
You can use autokey-gtk
. If you set Autokey to run at login, it will sit in the background and monitor input from your keyboard and mouse.
Example: You stated you would like to make Ctrl + Q act like Ctrl + C. If you ask autokey-gtk
to "press" Ctrl + C when Ctrl + Q is pressed.
To install autokey-gtk
issue the following command in a terminal
sudo apt-get install autokey-gtk
After installation, you can access it through the Dash or by typing auto-gtk
in a terminal. To set the key combinations that you stated above, do the following:
Step 1
Run autokey-gtk
Step 2
Create a New Top-Level Folder from File -> Create -> New Top-Level Folder
Step 3
Select Folder and create New Script from File -> Create -> New Script
Step 4
in the # Enter script code box, enter "keyboard.send_keys(shortcut you desire to imitate)"
Examples:
1. keyboard.send_keys("<ctrl>+c")
2. keyboard.send_keys("<ctrl>+v")
3. keyboard.send_keys("<ctrl>+x")
NOTE: repeat Step 3-4 for each hotkey you want to add
Step 5
For each Script you made click on the second "set button" next to Hotkey and enter your key combination that you will use to imitate.
In your case for the keyboard.send_keys("<ctrl>+c") script
you would type Q in the text box and click on the Control button
and then click OK.
**Do this for each script, being sure to modify your hotkey of course.*
Step 6
Click on *Edit* -> *Preferences*
Select the check box next to Automatically start Autokey at Login
This should accomplish what your asking for :)
Best Answer
One way to come close to the desired behavior is to
~/.XCompose
~/.XCompose
I tested it with a
~/.XCompose
file with only this line:When using the Russian (phonetic) keyboard layout it lets me do:
Compose followed by С followed by Х -> ш