Bug 19750 - missing geometry for Dell Latitude D620 french keyboard
Summary: missing geometry for Dell Latitude D620 french keyboard
Status: RESOLVED INVALID
Alias: None
Product: xkeyboard-config
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: xkb
QA Contact:
URL:
Whiteboard:
Keywords: NEEDINFO
Depends on:
Blocks:
 
Reported: 2009-01-26 13:59 UTC by Bryce Harrington
Modified: 2010-05-07 12:55 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
dell latitude d620.xkb (5.99 KB, application/octet-stream)
2009-01-26 13:59 UTC, Bryce Harrington
Details
Preview of the geometry (39.01 KB, image/png)
2009-01-28 14:10 UTC, Sergey V. Udaltsov
Details

Description Bryce Harrington 2009-01-26 13:59:25 UTC
Created attachment 22257 [details]
dell latitude d620.xkb

Forwarding this bug from a Ubuntu reporter:
https://bugs.edge.launchpad.net/ubuntu/+source/xkeyboard-config/+bug/138131

[Problem]
There is no geometry file for the Dell Latitude D620 laptop with french keyboard.  User has come up with a partly-working geometry but gets an error trying to use it.

[Original Report]
Hello! I'm using a Dell Latitude D620 laptop, with a French keyboard (I'm not sure if the others are the same), and I noticed there's no geometry file for this model in Ubuntu.

If you open the Keyboard Preferences applet, the Layouts tab, and try to pick a keyboard model, you'll notice a "Dell Latitude series laptop" model. Unfortunately this is quite different from what the keyboard looks like on my machine. I've spent a lot of time today trying to create another geometry file (ie, something appropriate to append to /usr/share/X11/xkb/geometry/pc) with only moderate success.

The main problem is that I couldn't find a decent tool to actually check my resulting layout. What I did was dump the current X config to an .xkb file (call it layout.xkb) using xkbcomp, edited it, then I used
      $xkbcomp layout.xkb && xkbprint -color -label none -level2 layout.xkm && ps2pdf layout.ps && xpdf layout.pdf
to take a look at it. This baroque system was needed because:
(a) I can't figure out how to get a "clean" xkb file, and I don't know how to look at a "geometry" description by itself;
(b) for some reason xkbprint often generates ps output that either is broken, or is understandable by neither ps2pdf nor evince;
(c) also xkbprint fails with strange errors if I tell it to display the labels on the keys. This happens on the file compiled by xkbcomp, so I don't think it's an error in my layout.
(d) even if it does work, for some reason evince sometimes can't read the resulting pdf. Weird, I know. I might even file a bug report next time this happens. Anyway, only (a)--(c) are really relevant.

That being said, I have been able to create a layout that _looks_ like the keyboard I have. I can compile it, and xkbprint generates a graphic if I set it to not display labels (as above). But it doesn't show the keysims, so I doubt they're set completely right. There are some weird keys on the laptop and I'm not sure how to deal with them, or if it's even necessary (they all work with the default keyboard "model" which doesn't show most of them). I'm guessing they're mostly cosmetic.

Anyway, I tried to hack the resulting geometry section into the /usr/share/X11/xkb/geometry/pc file and rebooted. The new layout is shown in the Keyboard Preferences applet list, but if I try to pick it I get an error. It's not very descriptive, it just says something was wrong and to contact the Xorg guys with the output of two commands. I checked (see below), they only display the current settings at the time, which isn't very helpful because I know them.

$ xprop -root|grep XKB
_XKB_RULES_NAMES_BACKUP(STRING) = "xorg", "pc104", "us", "dvorak", ""
_XKB_RULES_NAMES(STRING) = "xorg", "latitude", "us,fr", "dvorak,", "ctrl:swapcaps,altwin:super_win,grp:alts_toggle"
$ gconftool-2 -R /desktop/gnome/peripherals/keyboard/kbd
 layouts = [us dvorak,fr]
 model = latituded620
 options = [ctrl ctrl:swapcaps,altwin altwin:super_win,grp grp:alts_toggle]
 overrideSettings = true

So, what I'd need is for someone to coach me into finding out what's wrong with the geometry, debugging it, and generally getting it to a state where it can be accepted into Ubuntu (and pushed upstream). I'll attach the xkb file right away.
Comment 1 Sergey V. Udaltsov 2009-01-26 14:01:52 UTC
Since we are in freeze (tomorrow is release), I will postpone this one. But it will be one of the first commits.
Comment 2 Sergey V. Udaltsov 2009-01-28 14:10:30 UTC
Created attachment 22328 [details]
Preview of the geometry

There is something wrong with the geometry. See attached.

I have committed it as dell(latitude) geometry, since there is no specific D620 model.

I must admit - I am impressed with the complexity of the picture. Well done!
Comment 3 Sergey V. Udaltsov 2009-01-28 14:12:30 UTC
Anyway, it is committed to git, so you're welcome to try (and fix these minor issues).
Comment 4 Bogdan Butnaru 2009-02-02 06:53:10 UTC
Hello Sergey!

I'm the guy who originally made this and placed it in Ubuntu's bugtracker, but it languished there for a year or so.

By the way, this particular keyboard is based on the French version of http://www.dell.com/content/products/productdetails.aspx/latit_d620?c=us&cs=28&l=en&s=dfb (I'm not quite sure I understand your comment about the model).

I'd like to fix the bugs, and I have another keyboard I'd like to add. Can you tell me what you used to create that picture, and if there are any tools I can use to validate a geometry file? I remember I was working half-blind when I did this one. The only help I had was gnome's keyboard applet, and it wasn't very helpful when something went wrong.

Also, I'm not sure about your 'git' comment; where is the repository? Is there some wiki page saying how I should make modifications/send patches?
Comment 5 Bogdan Butnaru 2009-02-02 06:56:11 UTC
Oh, and while we're at it I have another question: what is the preferred way of installing a custom geometry file? Do I really have to mess with /usr/share/X11/xkb, or is there some support for user files?
Comment 6 Sergey V. Udaltsov 2009-02-04 16:37:55 UTC
Yes I am using gnome utilities. The indicator applet has "Keyboard preview" feature. You can also use xkbprint. Or, if you build libgnomekbd (used by the gnome applet), there is a test utility you can run to show the keyboard preview. You choose;)

The repository is in git. http://freedesktop.org/wiki/Software/XKeyboardConfig/Development

You do not have to mess with /usr/share/X11, there is -I option for both xkbcomp and setxkbmap (even though some people have issues with it).
Comment 7 Sergey V. Udaltsov 2010-05-06 16:08:43 UTC
What a pity. The patch that is "almost there" - but not quite. And no reply for a year.

Please reopen if you have fixed version of the geometry.
Comment 8 Bogdan Butnaru 2010-05-07 09:54:31 UTC
Sorry Sergey. The documentation for creating these files is ridiculously lacking, each time I tried to work on it again I hit some obscure & inexplicable behavior and got annoyed.

(And since I’m not using that computer anymore I’m even less motivated.)

Anyway, the files are left here, if anyone cares more than I do or knows more about these files they can try fixing them. Maybe I will, eventually. Do you mind if I email you directly, if I pick this up again and have questions?
Comment 9 Sergey V. Udaltsov 2010-05-07 12:55:45 UTC
Well, I do not mind general questions in personal email. I just prefer to keep in bugzilla all discussions related to particular topic. So, choose wisely what way of communication to use;)


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.