Bug 11356 - braille patterns xkb option
Summary: braille patterns xkb option
Status: RESOLVED FIXED
Alias: None
Product: xkeyboard-config
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: Other All
: medium enhancement
Assignee: xkb
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-06-23 18:45 UTC by Samuel Thibault
Modified: 2007-06-26 01:28 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
XKB symbols for braille (4.69 KB, text/plain)
2007-06-23 18:46 UTC, Samuel Thibault
Details
XKB group for braille (1.13 KB, text/plain)
2007-06-23 19:32 UTC, Samuel Thibault
Details
version with keypad hidden and included in others (1.23 KB, text/plain)
2007-06-24 04:14 UTC, Samuel Thibault
Details
with group description (1.35 KB, text/plain)
2007-06-24 05:05 UTC, Samuel Thibault
Details
xkb output (51.45 KB, text/plain)
2007-06-25 16:08 UTC, Samuel Thibault
Details

Description Samuel Thibault 2007-06-23 18:45:52 UTC
Here is a symbols/ files for adding braille patterns bindings to the
keyboard, for use with the following new options:

  braille              Adding braille patterns to certain keys
  braille:home_row     Add braille patterns to the home row
  braille:left_hand    Add braille patterns to the left hand
  braille:right_hand   Add braille patterns to the right hand
  braille:keypad       Add braille patterns to the keypad
Comment 1 Samuel Thibault 2007-06-23 18:46:26 UTC
Created attachment 10426 [details]
XKB symbols for braille
Comment 2 Samuel Thibault 2007-06-23 19:09:49 UTC
Mmm, that said, maybe it should rather be implemented as a whole group?
Comment 3 Samuel Thibault 2007-06-23 19:32:17 UTC
Created attachment 10427 [details]
XKB group for braille

That's much simpler indeed :)
Comment 4 Sergey V. Udaltsov 2007-06-24 03:33:00 UTC
I like the last version. I'll use it. But I need a bit more context info. Is Braille international? Does it depend on country/language?
Comment 5 Sergey V. Udaltsov 2007-06-24 03:37:38 UTC
More questions:
1. Would it make sense to put all these symbols into one xkb_symbols? Why do you want them split - would anyone use one part without using the rest?
2. In terms of layouts/variants/options - would it be more logical to expose this group as an XKB layout or as an XKB option?
Comment 6 Samuel Thibault 2007-06-24 03:49:31 UTC
Yes, braille depends on the language, the country, the culture, whether contraction is in use or not... and even personnal preference.  That's why xkb can't handle all that itself and should just produce the 0xfff[1-a] keysyms corresponding to the ten dots. The actual translation is then performed by an X Input Method. By default, libX11 produces raw braille patterns (U+28xy), which is already useful for writing UTF-8 braille tables for instance. Later on, I'll write a more advanced Input Method in a separate program that will take into account language/country/culture/contraction/personnal preference.
Comment 7 Samuel Thibault 2007-06-24 03:53:34 UTC
About splitting: home_row, left_hand and right_hand conflict. The numpad would doesn't conflict with others, however, so it may make sense to include it in all others.

About layout vs option, I haven't seen an option that defines a whole group, so I thought using a layout was the finest way. And to me it makes sense: it is not really a modifier of other layouts, it is really a whole layout per itself (not dependent on main layout at all).
Comment 8 Sergey V. Udaltsov 2007-06-24 04:02:38 UTC
> About splitting: home_row, left_hand and right_hand conflict. The numpad would
> doesn't conflict with others, however, so it may make sense to include it in
> all others.
What about making numpad hidden and including it in 3 others?

> I thought using a layout was the finest way. And to me it makes sense: it is
> not really a modifier of other layouts, it is really a whole layout per itself
> (not dependent on main layout at all).
OK, I see. No problem. But it is actually related to the question regarding the country. So far xkeyboard-config layouts are built on per-country basis (except for 2 or 3 very special cases). Which country would be the best place for your layout/variants? US?
Comment 9 Samuel Thibault 2007-06-24 04:14:32 UTC
Created attachment 10429 [details]
version with keypad hidden and included in others

Here is a version with numpad hidden and included.

About per-country... I'd say no country is the best place: the layout of raw braille dots themselves doesn't depend on the country, only on the physical geometry of the keyboard.
Comment 10 Sergey V. Udaltsov 2007-06-24 04:36:53 UTC
> Created an attachment (id=10429) [details]
> version with keypad hidden and included in others
Good!

> About per-country... I'd say no country is the best place: the layout of raw
> braille dots themselves doesn't depend on the country, only on the physical
> geometry of the keyboard.
Well, I would agree with "no country" approach - but how are these symbols used by people in the countries with non-latin alphabets? Or in Europe, where "extended Latin" is necessary? Please do not get me wrong, I just want to get the whole picture.
Comment 11 Samuel Thibault 2007-06-24 04:45:33 UTC
The Input Method will handle all that, it just needs raw braille dot patterns as input.
Comment 12 Sergey V. Udaltsov 2007-06-24 04:58:53 UTC
OK.

So, the file would be put as symbols/braille. The default variant would be "home_row" (objections?).

Also, I need nice user visible group descriptions (see other symbols/* files for example).

> The Input Method will handle all that, it just needs raw braille dot patterns
> as input.
OK
Comment 13 Samuel Thibault 2007-06-24 05:05:17 UTC
Created attachment 10430 [details]
with group description

Here are group descriptions.

Setting home_row as default variant should be fine.
Comment 14 Sergey V. Udaltsov 2007-06-24 05:13:49 UTC
Great! I'll commit it then
Comment 15 Sergey V. Udaltsov 2007-06-25 14:41:32 UTC
I have committed the stuff to CVS. Could you please check?
Comment 16 Samuel Thibault 2007-06-25 15:09:18 UTC
setxkbmap -layout fr,braille -variant latin9,home_row  works fine. However,  setxkbmap -layout fr,braille -variant latin9,  doesn't. Is that expected? (I thought it should select home_row by default) 
Comment 17 Sergey V. Udaltsov 2007-06-25 15:16:54 UTC
What kind of error do you get? Try 
setxkbmap ... -print | xkbcomp - :0 -w10
It could give more info on what's wrong.

(In reply to comment #16)
> setxkbmap -layout fr,braille -variant latin9,home_row  works fine. However, 
> setxkbmap -layout fr,braille -variant latin9,  doesn't. Is that expected? (I
> thought it should select home_row by default) 
> 

Comment 18 Samuel Thibault 2007-06-25 15:27:17 UTC
Oops, sorry, I meant: it doesn't fail, but no braille layout is applied on top of the fr layout.
Comment 19 Sergey V. Udaltsov 2007-06-25 15:38:19 UTC
Anyway, first look at the result of setxkbmap ... -print, then, as I said, feed it into xkbcomp. May be, "... | xkbcomp - -xkb out.xkb" would give you something interesting in out.xkb
Comment 20 Samuel Thibault 2007-06-25 16:08:25 UTC
Created attachment 10448 [details]
xkb output

This is the output.  Not Group2 for qsdf & co.  But I noticed the keypa has it.  I tried putting back the keypad xkb_symbols section at the end of the "braille" file, and now home_row is correctly taken as default.  It looks like xkb uses the first xkb_symbols section as default, regardless of the "default" qualifier.
Comment 21 Sergey V. Udaltsov 2007-06-26 01:11:37 UTC
It seems you're right about ignoring the default attribute. Should be ok in CVS now. Please check
Comment 22 Samuel Thibault 2007-06-26 01:28:05 UTC
Works fine now, thanks! 


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.