弹出“快速修复”菜单的Visual Studio代码中的键盘快捷键是什么?

时间:2017-11-14 13:42:48

标签: angular visual-studio-code keyboard-shortcuts autocorrect

在Visual Studio Code IDE中,当红色波浪线为代码添加下划线时,如何弹出菜单以显示“快速修复”建议并选择一个建议的修补程序以应用于您的代码?带下划线的代码示例:

enter image description here

2 个答案:

答案 0 :(得分:1)

在Mac上,使用命令 + 键弹出快速修复建议菜单。

在Windows上,使用 Ctrl + 键。

然后,只需选择要应用于代码的快速修复建议。

Mac上的示例:

enter image description here

答案 1 :(得分:1)

与该问题相对应的另一个可能是database = open("database", "r") template = open("template", "r") outfile1 = open("junk1", "w") outfile2 = open("junk2", "w") outfile3 = open("junk3", "w") for line in database: part = line.split("|") title = part[0] #replaces #1 firstname = part[1] #replaces #2 lastname = part[2] #replaces #3 address = part[3] #replaces #4 city = part[4] #replaces #5 state = part[5] #replaces #6 zipcode = part[6] #replaces #7 for line in template: string = line for r in (("|1|",title),("|2|", firstname),("|3|", lastname),("|4|", address),("|5|", city),("|6|", state),("|7|", zipcode)): string = string.replace(*r) outfile1.write(string) outfile2.write(string) outfile3.write(string) outfile1.close() outfile2.close() outfile3.close() database.close() template.close()

showHover shortcut