Linux - DesktopThis forum is for the discussion of all Linux Software used in a desktop context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I have a Hungarian keyboard by default, but I need to type some French letters without changing the layout, so I decided to create my own.
(Fedora Core 8)
Reading the internet I found these:
- I created a new file as /usr/share/X11/xkb/symbols/hu_fr ,file shown at bottom
- I have added 2 lines to /usr/share/X11/xkb/rules/base.lst:
under ! layout
hu_fr Hungary+french
under ! variant
standard hu_fr: Standard
- after that I executed in /usr/share/X11/xkb/symbols
xkbcomp -lhlpR '*' -o ../symbols.dir
After doing that, I havent found any new layouts, and Nautilus won't start.
Removing new file and changes to base.lst and running a xkbcomp command corrects the previous state.
// 102_qwertz_comma_dead_fr
// 102 key qwertz french layout
// with decimal comma on keypad
// and with dead key support
partial
xkb_symbols "102_qwertz_comma_dead_fr" {
name[Group1] = "Hungary - 102/qwertz/comma/Dead keys FR";
include "latin"
include "hu_fr(def_102_fr)"
include "hu_fr(def_qwertz_fr)"
include "kpdl(comma)"
include "hu_fr(def_dead_fr)"
include "hu_fr(def_common_fr)"
include "level3(ralt_switch)"
};
But, I'll write in english for our other friends here.
Quote:
under ! layout
hu_fr Hungary+french
under ! variant
standard hu_fr: Standard
- after that I executed in /usr/share/X11/xkb/symbols
xkbcomp -lhlpR '*' -o ../symbols.dir
Don't change anything in the rules file. I know it may be cleaner to do it this way, but it may not be easier.
backup your /symbols/hu file.
Now, I assume that since you are using the hu layout that you are already familiar with the term ALTGR. That's the right alt key and it's used with non-english languages where there are ciromflexes and cedillas and accents, etc.
In the hu file, the altGR key is the 3rd field. You will have to add what you want that key to do in the 3rd field.
For instance, to get an accent grave with the "comma, question, semicolon" key:
key <AB08> { [ comma, question, grave ] };
Unfortunately, this means having to lose whatever was stored there in the first place.
You may want to check under system, preferences, keyboard, layouts (or something similar in Gnome / KDE) and add the french layout.
There's a way, somewhere in there, to setup changing from one layout to another.
You also may want to install SCIM. SCIM will give you a nifty menu to use to switch between layouts and it may also give you a way to hit 2 keys like alt+shift to switch between types.
This is the file that I use for an english dvorak layout with dead keys for many french (and other language) symbols: /usr/share/X11/xkb/symbols/us
Last edited by DennisC31; 12-12-2007 at 03:14 PM..
Reason: added link
The fourth entry is what you can get by pressing AltGr + Shift (or CapsLock). I have already modified my 'hu' file that way that every acoute character has a circumflex (AltGr) pair, and every simple vowel has a grave pair in AlgGr.
I think this rather a workaround, but it works and i may not need any seperate layout, because i use this layout all the time.
Thanks once more!
P.s. Of course after changes to a layout file, running
xkbcomp -lhlpR '*' -o ../symbols.dir
is needed! Otherwise X will hang on next start.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.