sgzwiz / pyscripter

Automatically exported from code.google.com/p/pyscripter
1 stars 2 forks source link

Ctrl+Y always deletes line when empty redo buffer; no way to remap "delete line" #620

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Remap redo to Ctrl+Y (IDE Shorcuts->Edit->actEditRedo)
2. Enter a new line of text
3. Ctrl+Z to undo typing the line of text
4. Ctrl+Y to redo typing the text (works as expected)
5. Ctrl+Y again (to simulate an accident or not knowing that we are at the end 
of the redo buffer)

What is the expected output? What do you see instead?
I expect that redo does nothing when called on an empty buffer. However, if 
redo is mapped to Ctrl+Y (which is standard for most Windows apps), it seems to 
revert back to its default "delete line" functionality. 

A relevant side-issue is that "delete line" appears nowhere in the IDE 
shortcuts window, so there's no obvious way for the user to delete the default 
mapping of Ctrl+Y. An enhancement to go along with this issue is to detect and 
point out conflicts with shortcut key assignments.

What version of the product are you using? On what operating system?
2.4.3.0 on Windows 7 Pro, 32-bit

Original issue reported on code.google.com by pckuj...@gmail.com on 9 Mar 2012 at 5:43

GoogleCodeExporter commented 9 years ago
So I rediscovered the Editor Options->Keystrokes tab which defines Ctrl+Y as 
Delete Line and am able to remove it from there, which resolves the issue. But 
it begs the question, Why the separate (confusing) dialogs for assigning 
shortcuts? (I'm not the first who's been confused by this: 
http://codecrafter.wordpress.com/2008/05/10/pyscripter-annoyances-and-general-fi
nd-replace-gripes/#comment-254 )

Original comment by pckuj...@gmail.com on 9 Mar 2012 at 6:00

GoogleCodeExporter commented 9 years ago
I know this is not perfect, but there are two kinds of shortcuts.

IDE shortcuts (Tools, Options, IDE shortcuts)
Editor shortcuts (Tools, Options, Editor Options).

IDE options take precendence, but consistency between them is not enforced.  
Since Ctrl +Y is mapped to the delete line command, You will to change that 
shortcut as well as you have discovered.  

I will close this issue, but you may well want to open a separate one about 
unifying the user interface of IDE and Editor shortcuts and imposing 
consistency.

Original comment by pyscripter on 9 Mar 2012 at 10:53

GoogleCodeExporter commented 9 years ago
Fair enough. Thanks!

Original comment by pckuj...@gmail.com on 9 Mar 2012 at 5:13