Can't use Alt key in jEdit 5 under Mac OS X
Submitted by Sunday, 29 July, 2012 - 23:35
on
Hello,
I am trying to get my Alt key to work in Mac OS X. Whenever I try to use it as part of a shortcut, it instead writes a symbol (which symbol depends on what character I hit on the keyboard) into my buffer.
I searched for previous posts, and one suggested modifying my startup.bsh. I tried but still couldn't get my Alt key to function. Can someone tell me what I am doing wrong? Below is the section in my startup.bsh:
/*{{{ Remapping modifier keys part I */
/* The below is the default, swap the items around to
* change meaning of C+, A+, M+, S+.
*/
//KeyEventTranslator.setModifierMapping(InputEvent.CTRL_MASK,
// InputEvent.ALT_MASK, InputEvent.META_MASK,
// InputEvent.SHIFT_MASK);
/* ... and this the MacOS default: */
KeyEventTranslator.setModifierMapping(InputEvent.META_MASK, /* == C+ */
InputEvent.CTRL_MASK, /* == A+ */
InputEvent.ALT_MASK, /* == M+ */
InputEvent.SHIFT_MASK /* == S+ */);
/*}}}*/
/*{{{ Remapping modifier keys part II */
/* Note if you chose to make use of the M+ (option key) prefix on MacOS, you
* will need to disable a little piece of code: */
Debug.ALT_KEY_PRESSED_DISABLED = false;
/* Otherwise M+ will be ignored for the purposes of keyboard shortcuts. */
/* But if you enable this, you might find that Option+8 for example invokes your
* macro but also inserts a bulletpoint, as per standard Macintosh keyboard
* behavior. To disable the Option key for inserting special high ASCII
* characters, uncomment this. Note that it has wider implications, notably
* DROVAK keyboard shortcuts will be mapped as if the keyboard was QWERTY. */
Debug.ALTERNATIVE_DISPATCHER = false;
/*}}}*/
I am trying to get my Alt key to work in Mac OS X. Whenever I try to use it as part of a shortcut, it instead writes a symbol (which symbol depends on what character I hit on the keyboard) into my buffer.
I searched for previous posts, and one suggested modifying my startup.bsh. I tried but still couldn't get my Alt key to function. Can someone tell me what I am doing wrong? Below is the section in my startup.bsh:
/*{{{ Remapping modifier keys part I */
/* The below is the default, swap the items around to
* change meaning of C+, A+, M+, S+.
*/
//KeyEventTranslator.setModifierMapping(InputEvent.CTRL_MASK,
// InputEvent.ALT_MASK, InputEvent.META_MASK,
// InputEvent.SHIFT_MASK);
/* ... and this the MacOS default: */
KeyEventTranslator.setModifierMapping(InputEvent.META_MASK, /* == C+ */
InputEvent.CTRL_MASK, /* == A+ */
InputEvent.ALT_MASK, /* == M+ */
InputEvent.SHIFT_MASK /* == S+ */);
/*}}}*/
/*{{{ Remapping modifier keys part II */
/* Note if you chose to make use of the M+ (option key) prefix on MacOS, you
* will need to disable a little piece of code: */
Debug.ALT_KEY_PRESSED_DISABLED = false;
/* Otherwise M+ will be ignored for the purposes of keyboard shortcuts. */
/* But if you enable this, you might find that Option+8 for example invokes your
* macro but also inserts a bulletpoint, as per standard Macintosh keyboard
* behavior. To disable the Option key for inserting special high ASCII
* characters, uncomment this. Note that it has wider implications, notably
* DROVAK keyboard shortcuts will be mapped as if the keyboard was QWERTY. */
Debug.ALTERNATIVE_DISPATCHER = false;
/*}}}*/