简体   繁体   English

Chrome 中是否有用于将光标重新聚焦到控制台内的键盘快捷键?

[英]Is there a keyboard shortcut in Chrome for refocusing the cursor to within the console?

I am new to Chrome Developer Tools and am doing a Udemy course on JavaScript.我是 Chrome 开发人员工具的新手,正在学习有关 JavaScript 的 Udemy 课程。 I have a split screen with my course video in a window on the left and a blank Chrome tab on the right with the console open.我在左侧的窗口中有一个带有我的课程视频的分屏,右侧有一个空白的 Chrome 选项卡,控制台打开。 Often in the course of typing commands the focus will leave the console and move elsewhere and I will have to take my fingers away from the keyboard and use the trackpad to re-select the console pane, enabling me to type again.通常在键入命令的过程中,焦点会离开控制台并移动到其他地方,我将不得不将手指从键盘上移开并使用触控板重新选择控制台窗格,使我能够再次键入。 I am looking for a keyboard shortcut to focuses the cursor in the console, similar to CTRL+L (Win) for focusing the cursor in the address bar.我正在寻找一个键盘快捷键来聚焦控制台中的光标,类似于用于在地址栏中聚焦光标的 CTRL+L (Win)。 Does such a shortcut exist?有这样的捷径吗?

Thanks to all!谢谢大家!

From within Chrome, you can focus the DevTools console using the shortcut Control+` (control and backtick).在 Chrome 中,您可以使用快捷键Control+` (控制和反引号)聚焦 DevTools 控制台。

Google has documentation listing all available keyboard shortcuts for the Chrome DevTools here: https://developers.google.com/web/tools/chrome-devtools/shortcuts Google 的文档列出了 Chrome DevTools 的所有可用键盘快捷键: https : //developers.google.com/web/tools/chrome-devtools/shortcuts

F6 will cycle the keyboard focus through various UI elements (URL bar, page display, Dev tools, etc.). F6将通过各种 UI 元素(URL 栏、页面显示、开发工具等)循环键盘焦点。 Once in the Dev tools pane, either of these should get you on your way:进入开发工具窗格后,其中任何一个都应该让您上路:

  • Press the Esc key (perhaps multiple times in row).Esc键(可能连续多次)。 This will close sections, then toggle the secondary Dev tools pane.这将关闭部分,然后切换辅助开发工具窗格。

  • Another option is to check the option Enable Ctrl + 1-9 shortcut to switch panels option in the Dev Tools preferences (accessed via 3 vertical dots icon in upper right).另一个选项是选中“开发工具”首选项中的“启用 Ctrl + 1-9 快捷方式切换面板选项”选项(通过右上角的 3 个垂直点图标访问)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM