在Delphi中,每当我的程序变得无响应时,我就习惯按F12来查看主线程正在做什么,主要用于堆栈跟踪,但有时也用于局部变量。
现在我正在玩SharpDevelop,看不到类似的东西。这可能吗?
在SharpDevelop中没有预定义的键盘快捷键用于调试中断。可以从"调试"菜单中选择"调试-中断"。您也可以按主工具栏上的暂停键。
如果你想要一个键盘快捷键,那么你需要编辑ICSharpCode.SharpDevelop.addin文件,并在Break菜单中添加一个快捷键。下面显示了中断菜单项,没有键盘快捷键,以及以F5为快捷键的继续菜单项。
<Condition name="DebuggerSupports" debuggersupports = "ExecutionControl">
<MenuItem id = "ExecutionControlSeparator" type = "Separator" />
<Condition name="IsProcessRunning" isprocessrunning = "True" isdebugging = "True" action = "Disable">
<MenuItem id = "Break"
label = "${res:XML.MainMenu.DebugMenu.Break}"
icon = "Icons.16x16.Debug.Break"
class = "ICSharpCode.SharpDevelop.Project.Commands.BreakDebuggingCommand"/>
</Condition>
<Condition name="IsProcessRunning" isprocessrunning = "False" isdebugging = "True" action = "Disable">
<MenuItem id = "Continue"
label = "${res:XML.MainMenu.DebugMenu.Continue}"
icon = "Icons.16x16.Debug.Continue"
shortcut = "F5"
class = "ICSharpCode.SharpDevelop.Project.Commands.ContinueDebuggingCommand"/>
</Condition>
</Condition>
如果你想的话,可以通过编辑ICSharpCode.SharpDevelop.addin文件为Break菜单项添加一个新的快捷属性