Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 227949 - Key binding for Plugin Spy not working
Summary: Key binding for Plugin Spy not working
Status: RESOLVED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.4   Edit
Hardware: Macintosh Mac OS X - Carbon (unsup.)
: P3 major (vote)
Target Milestone: 3.4.1   Edit
Assignee: Chris Aniszczyk CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-04-21 02:07 EDT by Tadayuki Yoshida CLA
Modified: 2013-04-25 04:21 EDT (History)
7 users (show)

See Also:


Attachments
org.eclipse.pde.runtime.patch (882 bytes, patch)
2008-04-24 05:07 EDT, Chris Aniszczyk CLA
no flags Details | Diff
mylyn/context/zip (769 bytes, application/octet-stream)
2008-04-24 05:07 EDT, Chris Aniszczyk CLA
no flags Details
for Windows and Japanese Locale user's patch (976 bytes, patch)
2008-07-18 02:36 EDT, Hiroki Kondo CLA
caniszczyk: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tadayuki Yoshida CLA 2008-04-21 02:07:17 EDT
OS: Mac OS X 10.5.2 (intel)
Build: Eclipse 3.4M6a

The default key binding for launching Plugin Spy is Shift+Option+(Fn+)F1, but it didn't work.
In addition, we cannot set this key binding in the Preference page by manual operation.

If we assign another key binding for Plugin Spy, it really works, so please alter the default key binding.
Comment 1 Chris Aniszczyk CLA 2008-04-21 03:06:48 EDT
Kim, is there something I don't understand about Mac's here?
Comment 2 Kim Horne CLA 2008-04-21 08:04:33 EDT
Default behaviour on the Mac (laptops at least) is for the function keys to map to control functions such as brightness, volume, and expose.  To use them as actual F keys you need to hold down the Fn key.  You can swich this behaviour such that the Fn is the default, and in that scenario the keybindign works, but this bug is real.  If you have your keyboard in the default mode Shift-Option-F1(fn) does not work.  Interestingly enough, other Fn keys do work in this scenario... 
Comment 3 Tadayuki Yoshida CLA 2008-04-21 22:36:02 EDT
I'm using Mac mini (intel) with a new aluminum keyboard (JIS).
According to your suggestion, I changed the default behavior of Fn keys in the System Preference page.
But Shift+Option+F1 (without Fn) didn't let Plugin Spy come up yet...

I tried some keybindings as follows:

Shift+Option+F1 - cannot set - dont work (by default)
Shift+Option+\   -  can set       - works
Shift+Control+F1 - can set      - works
Shift+Command+F1 - cannot set - (dont work)

"can set"/"cannot set" means I could/could not overwrite keybinding for Plugin Spy on General > Keys in the Eclipse Preferences page.
Comment 4 Chris Aniszczyk CLA 2008-04-22 03:47:58 EDT
Paul, do you know of keybindings that do this?

ie., declare two, use that 'carbon' platform hack to accommodate Mac users?
Comment 5 Paul Webster CLA 2008-04-22 12:57:06 EDT
(In reply to comment #4)
> Paul, do you know of keybindings that do this?
> 

Yes, there are a couple of key bindings that use something (like ALT+LEFT_ARROW on most platforms, M1+[ on carbon)

You just need to pick a safe, logical key for the mac.

Tadayuki, it sounds like some other program is eating the key on your mac.  Kim, does the keybinding work on your Mac at all?

PW

Comment 6 Kim Horne CLA 2008-04-22 13:13:58 EDT
(In reply to comment #5)
> (In reply to comment #4)
> > Paul, do you know of keybindings that do this?
> > 
> 
> Yes, there are a couple of key bindings that use something (like ALT+LEFT_ARROW
> on most platforms, M1+[ on carbon)
> 
> You just need to pick a safe, logical key for the mac.
> 
> Tadayuki, it sounds like some other program is eating the key on your mac. 
> Kim, does the keybinding work on your Mac at all?
> 
> PW
> 

It works if I change the default Fn key behaviour in the System Properties first.  If I have to use the fn key to get regular Fn behaviour I see the result as Tadayuki.

Tadayuki, are you running in the English locale?  
Comment 7 Tadayuki Yoshida CLA 2008-04-22 22:52:02 EDT
I have checked this problem both Japanese and English locale (note that I have v10.5 installed in Japanese)

After searching several web pages regarding Kotoeri (Japanese IME on Mac), I got some findings as follows:

1. Kotoeri cannot be disabled when v10.5 installed in Japanese (grayout in input menu on the menu bar)
2. Kotoeri keeps traditional (Mac OS 9) keybindings for switching input modes among Hiragana, Katakana, and English (Romaji). For example, we can use traditional way of Option+Shift+F1 for switching to Hiragana as well as modern Ctrl+Shift+J (as yo can see in input menu)

So... I believe Kotoeri would catch Option+Shift+F1 and similar keybindings as used in the earlier version of Mac OS for most (carbon-based?) applications

Here are some typical keybindings caught by Kotoeri:

traditional (modern) - mode
Option+Shift+F1 (Ctrl+Shift+J) - Hiragana
Option+Shift+F2 (Ctrl+Shift+K) - Katakana
Option+Shift+F4 (Ctrl+Shift+;) - Romaji

Comment 8 Paul Webster CLA 2008-04-23 07:42:39 EDT
(In reply to comment #7)
> I have checked this problem both Japanese and English locale (note that I have
> v10.5 installed in Japanese)
> 
> After searching several web pages regarding Kotoeri (Japanese IME on Mac), I
> got some findings as follows:
> 
> 1. Kotoeri cannot be disabled when v10.5 installed in Japanese (grayout in
> input menu on the menu bar)

Thank you, that helps.

Chris, you would want to redefine the keybinding for plugin spy for carbon (or don't specify carbon if it is an IME problem that is not platform specific) and their locale.

For example (from org.eclipse.ui/plugin.xml):

      <!-- Special content assist key bindings for the Chinese language to prevent conflict with IME -->
      <key
            locale="zh"
   	    contextId="org.eclipse.ui.contexts.dialogAndWindow"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
            sequence="CTRL+SPACE"/>
      <key
            locale="zh"
            commandId="org.eclipse.ui.edit.text.contentAssist.proposals"
            contextId="org.eclipse.ui.contexts.dialogAndWindow"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
            sequence="M3+/"/>

PW
Comment 9 Chris Aniszczyk CLA 2008-04-24 04:59:26 EDT
mine
Comment 10 Chris Aniszczyk CLA 2008-04-24 05:07:48 EDT
Created attachment 97402 [details]
org.eclipse.pde.runtime.patch

I've decided to use M1+M3+F1

That looks like it should work.

Can you please verify Yoshida? I have no Mac to test :/

>20080424
Comment 11 Chris Aniszczyk CLA 2008-04-24 05:07:51 EDT
Created attachment 97403 [details]
mylyn/context/zip
Comment 12 Chris Aniszczyk CLA 2008-04-24 05:08:13 EDT
done!
Comment 13 Paul Webster CLA 2008-04-24 07:54:15 EDT
Chris, you need this line as well:

      <key
            contextId="org.eclipse.ui.contexts.dialogAndWindow"
            platform="carbon"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
            sequence="M3+M2+F1">
      </key>

That "deletes" the original binding for carbon.


Although I'll point out that you have changed this key for all mac users.  The other way would have been:

      <key
            contextId="org.eclipse.ui.contexts.dialogAndWindow"
            locale="ja"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
            sequence="M3+M2+F1">
      </key>
      <key
            commandId="org.eclipse.pde.runtime.spy.commands.spyCommand"
            contextId="org.eclipse.ui.contexts.dialogAndWindow"
            locale="ja"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
            sequence="M1+M3+F1">
      </key>

This fixes the problem for the japanese locales.

PW
Comment 14 Chris Aniszczyk CLA 2008-04-24 09:31:18 EDT
Thanks Paul, I updated it to the latter scenario to not piss off the other Mac users.

Please verify this Yoshida when you have time :)
Comment 15 Tadayuki Yoshida CLA 2008-04-28 03:49:16 EDT
Hi,

Since the latest version of plugin.xml (v1.47) is not incorporated in the build as of Apr 28, I inserted the modified lines to plugin.xml (extracted from org.eclipse.pde.runtime_3.4.0.v20080324-0900.jar) manually, then clean up the workbench.

When running in "ja" locale, the new keybinding (Option+Command+F1) for Plugin spy is successfully shown in the Preference (and verified unchanged in "en" locale), but it still won't work. Plug-in spy window didn't show up yet.

This sequence must be trapped by another application on Mac v10.5.2 Japanese as found by the fact that I cannot set this sequence for Plugin spy in the Preference page.

Please note that sequence of Control+{Shift or Option or Command}+F1 does work for my environment.

Comment 16 Hiroki Kondo CLA 2008-07-18 02:35:18 EDT
This bug doesn't fix Ganymede Stable Release(it doesn't MILESTONE RELEASE!) on Windows and Japanese Locale Environment.
Please re-open this BUG!!!(Because Plug-in Spy is good feature for plug-in developpers!)

I think these code are needed for Mac OSX

       <key
            contextId="org.eclipse.ui.contexts.dialogAndWindow"
            locale="ja"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
            sequence="M3+M2+F1">
      </key>
      <key
            commandId="org.eclipse.pde.runtime.spy.commands.spyCommand"
            contextId="org.eclipse.ui.contexts.dialogAndWindow"
            locale="ja"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
            sequence="M1+M3+F1">
      </key>

I read the help about org.eclipse.ui.bindings.The "M1" is only supported for Mac OSX.So the other OS's Eclipse Japanese users can't use this sequence.

I attached this patch is tested on Windows and Japanese Locale Environment.
Comment 17 Hiroki Kondo CLA 2008-07-18 02:36:00 EDT
Created attachment 107799 [details]
for Windows and Japanese Locale user's patch
Comment 18 Chris Aniszczyk CLA 2008-07-23 10:26:24 EDT
reopening due to japanese issue
Comment 19 Chris Aniszczyk CLA 2008-07-23 10:26:47 EDT
targetting for 3.4.1
Comment 20 Chris Aniszczyk CLA 2008-07-23 10:34:04 EDT
Thanks, fixed in 3.5 and 3.4.1
Comment 21 Hiroki Kondo CLA 2010-09-01 09:27:51 EDT
in helios,is the key binding changed?
My development environment has same problem on Mac OSX and Japanese locale Environment.
The plug-in selection spy's key binding is "Command+Option+F1".It is shown on preference.
I changed  to �hOption+Shift+(fn)+F1�h(F1 is hotkey of darker screen. So I pressed "fn" key.But if it is pressed fn and option, os handles "Alt" key...) and tested.It is executed.
Plug-in menu spy's key binding is "Option+Shift+(fn)+F2". So it should has similar binding.
Please reopen this bug...
Comment 22 Takehiko Ishii CLA 2013-04-25 04:18:32 EDT
On Mac OS X, the default shortcut key for Plug-in SPY is set to command+option+F1. However this doesn't work.
Comment 23 Takehiko Ishii CLA 2013-04-25 04:21:33 EDT
this comes to work if you change the shortcut key to other one, for example option+Shift+F1 which is the similar shortcut key as other platforms. 

I tried making the changes back to the default (command+option+F1), I couldn't set it because "F1" is not displayed on the field when I click both command and option keys together. 

Please reopen this bug and assign another shortcut key. Thanks.