Is there a keyboard shortcut for stopping the current console in Eclipse?

眉间皱痕 提交于 2019-12-11 08:37:33

问题


I'm developping a Java application with a class containing main. I can start the application using Ctrl+Alt+X J subsequently the application can be re-run by hitting Alt+R T Enter to choose the menu option for the first item in the Run history.

But to stop the application, I have to click on the small red square in the console view. This is annoying, because it forces me to use the mouse, type Alt+R T Enter then re-focus the editor using the mouse again.

Eclipse being so configurable, there must be a keyboard shortcut to stop the application run in the current console I haven't found. There are an entry in Window > Preferences > Keys called Terminate and Terminate and Relaunch but no matter what binding I assign or what when conditions I set and no matter if I use the Debug perspective or not, they don't seem to fire.

Please help an Eclipse newbie avoiding the mouse :)


回答1:


Go to Preferences -> General -> Keys

Find "Terminate" Set your binding to whatever you want.

Then change "When" from "Debugging" to "Editing Java Source".



来源:https://stackoverflow.com/questions/15259857/is-there-a-keyboard-shortcut-for-stopping-the-current-console-in-eclipse

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!