This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 145050 - Editor macro keybindings are not specific to keymap profile
Summary: Editor macro keybindings are not specific to keymap profile
Status: REOPENED
Alias: None
Product: editor
Classification: Unclassified
Component: Macros (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P3 blocker (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-25 19:52 UTC by matthies
Modified: 2016-07-18 20:09 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description matthies 2008-08-25 19:52:58 UTC
When creating a new macro and assigning a keyboard shortcut to it using Tools -> Options -> Editor -> Macros, this 
keybinding (stored under {userdir}/config/Editor/Macros/org-netbeans-modules-editor-settings-CustomMacros.xml) is not 
specific to the selected keymap profile, yet it is listed under Tools -> Options -> Keymap as if it were.

Expected behavior: Either make macro keybindings profile-specific, or else don't list them under Tools -> Options -> 
Keymap.
Comment 1 matthies 2008-08-25 19:53:30 UTC
Version info:
Product Version: NetBeans IDE Dev (Build 200808220201)
Java: 1.6.0_04; Java HotSpot(TM) Client VM 10.0-b19
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
Comment 2 Vitezslav Stejskal 2008-08-26 12:32:23 UTC
Historically the macro shortcuts have been always visible in Tools-Options -> Keymap. But you are right that it is
confusing. I'll hide them for now.

I'm not sure how useful it would be to have macro shortcuts part of a keybinding profile. But if people think it's
useful we can turn this into RFE and implement it.
Comment 3 matthies 2008-08-28 14:58:30 UTC
There's also the question of how to check keybinding conflicts when some (non-macro) are keymap dependent and some 
(macro) are not. For example if I define a macro keybinding which does not conflict with the current keymap, and then I 
switch to a different keymap wich does conflict, then what is supposed to happen?

I see three possible ways to make things consistent and well-defined:

1) Make macro keybindings keymap-specific.

2) Make macro keybindings non-keymap-specific and allow conflicts between macro keybindings and keymap keybindings. 
Macro keybindings should override conflicting keymap keybindings. This would also be a useful strategy for handling 
language-specific macro keybindings (see issue 145433).

3) Make macro keybindings non-keymap-specific and don't allow conflicts with any existing keymap, even if the keymap 
containing the conflicting keybinding is not the currently selected one.
Comment 4 Svata Dedic 2011-10-10 11:45:08 UTC
I would prefer the 2nd option: macros are much more sensitive to the language than to the keyboard profile - user does not typically switch keymaps back and forth. Unless we intend to ship predefined sets of macros (which should cleanly apply in all shipped keymaps or be keymap-specific) we don't need to complicate the system even more.
Comment 5 Martin Balin 2016-07-07 07:27:41 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss
Comment 6 matthies 2016-07-18 20:09:17 UTC
Still reproducable in current dev build.