eclipse 使用eclipse在pydev中切换断点的键盘快捷键是什么
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/3593894/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
what's the keyboard shortcut to toggle breakpoint in pydev using eclipse
提问by Joe
I think I'm missing the elephant in the room but for the life of me I can't find the keyboard shortcut to setting a breakpoint in eclipse when using the pydev plugin.
我想我错过了房间里的大象,但在我的生活中,我找不到在使用 pydev 插件时在 eclipse 中设置断点的键盘快捷键。
Things that I've already tried:
我已经尝试过的事情:
Ctrl+ Shift+ B: does nothing.
Ctrl+ F10: brings up the breakpoint context menu where you can select to add breakpoint, remove etc... I don't want to have to scroll through a menu every time I want to use a keyboard shortcut.. .kinda defeats the purpose of a shortcut.
Clicking on the strip on the left hand side of the code: this is the only way that I'm setting it atm, but I'm rather avoid using the mouse if I can.
Ctrl+ Shift+ B:什么都不做。
Ctrl+ F10:调出断点上下文菜单,您可以在其中选择添加断点、删除等...我不想每次要使用键盘快捷键时都必须滚动菜单...有点违背了目的一条捷径。
单击代码左侧的条带:这是我设置 atm 的唯一方法,但如果可以,我宁愿避免使用鼠标。
I'm using pydev 1.6.1 on eclipse 3.6
我在 Eclipse 3.6 上使用 pydev 1.6.1
EDIT (31/08): In light of the two answers by codedevour and Tao, I've tried editing the shortcut but have had no luck with the new shortcut Ctrl+ Shift+ Alt+ Beither. Other shortcuts work. I've also tried changing the "When" drop down from In Windows to 'Pydev editor scope' with no effects. From what the editor is telling me, there is no conflicts with the breakpoint shortcut.
编辑 (31/08):鉴于 codedevour 和 Tao 的两个答案,我尝试编辑快捷方式,但对新快捷方式Ctrl+ Shift+ Alt+B也没有运气。其他快捷方式有效。我还尝试将“何时”下拉菜单从“Windows 中”更改为“Pydev 编辑器范围”,但没有任何影响。从编辑器告诉我的情况来看,与断点快捷方式没有冲突。
This is a fresh install on two machines, both windows 7 and it's happened on both machines.
这是在两台机器上的全新安装,都是 Windows 7,并且在两台机器上都发生过。
回答by Joe
Finally found it!
终于找到了!
The answer is here: http://www.mail-archive.com/[email protected]/msg04234.html
答案在这里:http: //www.mail-archive.com/[email protected]/msg04234.html
In short, shortcuts are not set for all perspectives of eclipse. Whilst in the pydev perspective, go to Window > Customize perspective > Command Groups Availability > Check breakpoints.
总之,不是对eclipse的所有视角都设置了捷径。在 pydev 透视图中,转到Window > Customize透视图 > Command Groups Availability > Check breakpoints。
That's it!
就是这样!
I was using the pydev perspective (which is what it switches to when you first create a pydev project) however, breakpoint shortcuts are only available in the debug perspective by default so you need to turn the shortcut on... wow that was so NOT obvious!
我使用的是 pydev 透视图(这是您第一次创建 pydev 项目时切换到的)但是,默认情况下断点快捷方式仅在调试透视图中可用,因此您需要打开快捷方式...哇,原来如此明显的!
回答by Christopher Klewes
Ctrl+ Shift+ B
Ctrl+ Shift+B
If this refuses to work, have a look at Window > Preferences > General > Keysand look for overlayed keys which may shadow this shortcut.
如果这不起作用,请查看窗口 > 首选项 > 常规 > 键并查找可能覆盖此快捷方式的重叠键。
回答by Tao
Ctrl+ Shift+ Bworks for me and I am using pydev 1.6.1 with eclipse 3.6.
Ctrl+ Shift+B对我有用,我在 Eclipse 3.6 中使用 pydev 1.6.1。
Perhaps, you have a conflict with another program? Try change it under menu Window > Preference > General > Keys > Toggle Breakpointto another keyboard shortcut.
也许,你和另一个程序有冲突?尝试在菜单Window > Preference > General > Keys > Toggle Breakpoint下将其更改为另一个键盘快捷键。
回答by bagerard
On recent pydev versions:
在最近的 pydev 版本上:
Go to Window > Perspective > customize perspective... And in tab "Action Set Availability", check "Breakpoints"
转到窗口 > 透视 > 自定义透视...然后在选项卡“操作集可用性”中,选中“断点”