Bug 4448 - xkb issue when using layout 'fr,us' and alts_toggle options
Summary: xkb issue when using layout 'fr,us' and alts_toggle options
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: App/xkbcomp (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: high normal
Assignee: Daniel Stone
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-13 15:34 UTC by Sebastien Bacher
Modified: 2006-03-28 00:57 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Sebastien Bacher 2005-09-13 15:34:53 UTC
using the current xorg modular from Ubuntu:

$ setxkbmap -layout 'fr,us' -model pc105 -option '' -option 'grp:alt s_toggle'
-print
xkb_keymap {
        xkb_keycodes  { include "xfree86+aliases(azerty)"       };
        xkb_types     { include "complete"      };
        xkb_compat    { include "complete"      };
        xkb_symbols   { include "pc(pc105)+fr+us:2+group(alts_toggle)"  };
        xkb_geometry  { include "pc(pc105)"     };

$ setxkbmap -layout 'fr,us' -model pc105 -option '' -option 'grp:alts_toggle'
-print | xkbcomp - :0.0
Warning:          Type "ONE_LEVEL" has 1 levels, but <RALT> has 2 symbols
                  Ignoring extra symbols
Warning:          No symbols defined for <SYRQ> (keycode 92)
Warning:          No symbols defined for <BRK> (keycode 114)
Warning:          No symbols defined for <FK13> (keycode 118)
....
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  148 (XKEYBOARD)
  Minor opcode of failed request:  9 (XkbSetMap)
  Value in failed request:  0x16710002
  Serial number of failed request:  78
  Current serial number in output stream:  84

Sergey V. Udaltsov has mailed a describtion of the issue here:
http://listserv.bat.ru/xkb/Message/880.html
Comment 1 Daniel Stone 2006-03-05 08:10:19 UTC
will get some more sensible debugging information from the server as to why it's
returning badvalue
Comment 2 Tomas Frydrych 2006-03-09 03:52:10 UTC
Not sure if this helps or not, but I am getting the same error from the
following code (trying to change a single KeySym assignment; values in
XkbDescRec seem to be OK):


unsigned short offset;
unsigned short width;
XkbDescPtr pXkbDesc;

pXkbDesc = XkbGetMap(display, XkbKeySymsMask, XkbUseCoreKbd);
		
XkbMapChangesRec ChgRec = {0};
		
ChgRec.changed = XkbKeySymsMask;
ChgRec.first_key_sym = keycode;
ChgRec.num_key_syms = 1;

ChgRec.min_key_code = pXkbDesc->min_key_code;
ChgRec.max_key_code = pXkbDesc->max_key_code;

offset = pXkbDesc->map->key_sym_map[keycode].offset;
width = pXkbDesc->map->key_sym_map[keycode].width;

printf("Changing symbol {%d, %d, %d} from %d to %d\n",
	   keycode, group, level,
	   pXkbDesc->map->syms[offset + group * width + level],
	   newsym);
		
pXkbDesc->map->syms[offset + group * width + level] = newsym;
if(False == XkbChangeMap(display, pXkbDesc, &ChgRec))
{
	printf("ERROR: failed to apply changes.\n");
	ret = 1;
	goto quit;
}
Comment 3 Sergey V. Udaltsov 2006-03-10 11:07:21 UTC
Sebastien, this looks strange. I am using ubunbu breezy and "make install" from
xkeyboard-config. Look:
$ setxkbmap -layout 'fr,us' -model pc105 -option '' -option 'grp:alts_toggle' -print
xkb_keymap {
        xkb_keycodes  { include "xfree86+aliases(azerty)"       };
        xkb_types     { include "complete"      };
        xkb_compat    { include "complete"      };
        xkb_symbols   { include
"pc(pc105)+fr+us:2+level3(ralt_switch_for_alts_toggle):1+level3(ralt_switch_for_alts_toggle):2+group(alts_toggle)"
  };
        xkb_geometry  { include "pc(pc105)"     };
};

It is different from what you show me here...
Comment 4 Sebastien Bacher 2006-03-28 18:57:49 UTC
That is fixed with xkeyboard-config now, closing the bug. Sergey let me know if
you are interested anyway by the reply to your previous comment, but there is
probably no point to debug something working now


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.