Heim Web-Frontend js-Tutorial Detaillierte Erläuterung der Bindung von Eclipse-Tastenkombinationen an Sublime Text

Detaillierte Erläuterung der Bindung von Eclipse-Tastenkombinationen an Sublime Text

Jul 03, 2017 pm 03:57 PM
eclipse sublime text

Wählen Sie im Menü „Einstellungen“ die Option „Tastenkombinationen“ und fügen Sie den folgenden Code in die Benutzerdatei ein:

[
/**
* 常用快捷键(Sublime默认)
* --------------
*
* 光标一个单词一个单词的移动
* { "keys": ["ctrl+left"], "command": "move", "args": {"by": "words", "forward": false} },
* 按住shift来选文字时, 一个个单词的选而不是一个个字母
* { "keys": ["ctrl+shift+left"], "command": "move", "args": {"by": "words", "forward": false, "extend": true} },
*
* 类似光标一个个单词的移动
* { "keys": ["alt+left"], "command": "move", "args": {"by": "subwords", "forward": false} },
* { "keys": ["alt+shift+right"], "command": "move", "args": {"by": "subword_ends", "forward": true, "extend": true} },
*
* 缩进
* { "keys": ["ctrl+]"], "command": "indent" },
* { "keys": ["ctrl+["], "command": "unindent" },
*
* 删除整个单词
* { "keys": ["ctrl+backspace"], "command": "delete_word", "args": { "forward": false } },
* { "keys": ["ctrl+delete"], "command": "delete_word", "args": { "forward": true } },
*
* 行排序(例如选中几个JSON字段, 让这些字段名按字母顺序排序)
* { "keys": ["f9"], "command": "sort_lines", "args": {"case_sensitive": false} },
*
* 参考
* ----------------------
* Using Sublime Text as your IDE
* www.chromium.org/developers/sublime-text
*
* Web Development With Sublime Text 2
* www.paulund.co.uk/web-development-with-sublime-text-2
*/
// editor配置
{ "keys": ["ctrl+v"], "command": "paste_and_indent" },
{ "keys": ["ctrl+shift+v"], "command": "paste" },
/**
* 适配eclipse快捷键
*
* 下面这位仁兄早就有了这个想法
* Eclipse shortcuts for Sublime Text 2
* icoloma.blogspot.com/2011/10/eclipse-shortcuts-for-sublime-text-2.html
*/
{ "keys": ["alt+/"], "command": "auto_complete" },
{ "keys": ["ctrl+i"], "command": "reindent" },
// 当前行和下面一行交互位置
{ "keys": ["alt+up"], "command": "swap_line_up" },
{ "keys": ["alt+down"], "command": "swap_line_down" },
// 复制当前行到上一行
{ "keys": ["ctrl+alt+up"], "command": "duplicate_line" },
// 复制当前行到下一行
{ "keys": ["ctrl+alt+down"], "command": "duplicate_line" },
// 删除整行
{ "keys": ["ctrl+d"], "command": "run_macro_file", "args": {"file": "Packages/Default/Delete Line.sublime-macro"} },
// 光标移动到指定行
{ "keys": ["ctrl+l"], "command": "show_overlay", "args": {"overlay": "goto", "text": ":"} },
// 快速定位到选中的文字
{ "keys": ["ctrl+k"], "command": "find_under_expand_skip" },
// { "keys": ["ctrl+shift+x"], "command": "swap_case" },
{ "keys": ["ctrl+shift+x"], "command": "upper_case" },
{ "keys": ["ctrl+shift+y"], "command": "lower_case" },
// 在当前行的下一行插入空行(这时鼠标可以在当前行的任一位置, 不一定是最后)
{ "keys": ["shift+enter"], "command": "run_macro_file", "args": {"file": "Packages/Default/Add Line.sublime-macro"} },
// 定位到对于的匹配符(譬如{})(从前面定位后面时,光标要在匹配符里面,后面到前面,则反之)
{ "keys": ["ctrl+shift+p"], "command": "move_to", "args": {"to": "brackets"} },
// 这个命令默认使用的是ctrl+shift+p
{ "keys": ["ctrl+p"], "command": "show_overlay", "args": {"overlay": "command_palette"} },
// outline
{ "keys": ["ctrl+o"], "command": "show_overlay", "args": {"overlay": "goto", "text": "@"} },
// 当前文件中的关键字(方便快速查找内容)
{ "keys": ["ctrl+alt+o"], "command": "show_overlay", "args": {"overlay": "goto", "text": "#"} },
// open resource
{ "keys": ["ctrl+shift+r"], "command": "show_overlay", "args": {"overlay": "goto", "show_files": true} },
// 文件内查找/替换
{ "keys": ["ctrl+f"], "command": "show_panel", "args": {"panel": "replace"} },
// 全局查找/替换, 在查询结果中双击跳转到匹配位置
{"keys": ["ctrl+h"], "command": "show_panel", "args": {"panel": "find_in_files"} },
// plugin配置
{ "keys": ["alt+a"], "command": "alignment" },
{"keys": ["ctrl+shift+f"], "command": "js_format"}
]
Nach dem Login kopieren

oder

[
//=======================我的快捷键=======================//
// 删除当前行
{ "keys": ["ctrl+d"], "command":"run_macro_file", "args": {"file":"Packages/Default/Delete Line.sublime-macro"} },
// 复制选中行到行后
{ "keys": ["ctrl+alt+down"], "command":"duplicate_line" },
// 选词(按住-继续选择下个相同的字符串)
{ "keys": ["ctrl+g"], "command":"find_under_expand" },
// gb一次选中所有的
{ "keys": ["ctrl+g", "ctrl+b"],"command": "find_all_under" },
// 自动提示、补全
{ "keys": ["alt+/"], "command":"auto_complete" },
{ "keys": ["alt+/"], "command":"replace_completion_with_auto_complete", "context":
[
{ "key": "last_command", "operator":"equal", "operand": "insert_best_completion" },
{ "key": "auto_complete_visible", "operator":"equal", "operand": false },
{ "key": "setting.tab_completion", "operator":"equal", "operand": true }
]
},
// 与上行互换
{ "keys": ["alt+up"], "command":"swap_line_up" },
// 与下行互换
{ "keys": ["alt+down"], "command":"swap_line_down" },
{ "keys": ["alt+/","alt+/"], "command":"insert_best_completion" },
//与tab键冲突,秒之
{ "keys": ["shift+tab"], "command":"insert_best_completion", "args": {"default":"\t", "exact": true} },
{ "keys": ["shift+tab"], "command":"insert_best_completion", "args": {"default":"\t", "exact": false},
"context":
[
{ "key": "setting.tab_completion", "operator":"equal", "operand": true }
]
},
{ "keys": ["shift+tab"], "command":"replace_completion_with_next_completion", "context":
[
{ "key": "last_command", "operator":"equal", "operand": "insert_best_completion" },
{ "key": "setting.tab_completion", "operator":"equal", "operand": true }
]
},
{ "keys": ["shift+tab"], "command":"reindent", "context":
[
{ "key": "setting.auto_indent", "operator":"equal", "operand": true },
{ "key": "selection_empty", "operator":"equal", "operand": true, "match_all": true },
{ "key": "preceding_text", "operator":"regex_match", "operand": "^$","match_all": true },
{ "key": "following_text", "operator":"regex_match", "operand": "^$","match_all": true }
]
},
{ "keys": ["shift+tab"], "command":"indent", "context":
[
{ "key": "text", "operator":"regex_contains", "operand": "\n" }
]
},
{ "keys": ["shift+tab"], "command":"next_field", "context":
[
{ "key": "has_next_field", "operator":"equal", "operand": true }
]
},
{ "keys": ["shift+tab"], "command":"commit_completion", "context":
[
{ "key": "auto_complete_visible" },
{ "key": "setting.auto_complete_commit_on_tab" }
]
},
//移动光标
{ "keys": ["alt+l"], "command": "move","args": {"by": "characters", "forward":false} },
{ "keys": ["alt+r"], "command": "move","args": {"by": "characters", "forward":true} },
{ "keys": ["alt+u"], "command": "move","args": {"by": "lines", "forward":false} },
{ "keys": ["alt+d"], "command": "move","args": {"by": "lines", "forward":true} },
{ "keys": ["shift+alt+l" ], "command":"move", "args": {"by": "characters","forward": false, "extend": true} },
{ "keys": ["shift+alt+r"], "command":"move", "args": {"by": "characters","forward": true, "extend": true} },
{ "keys": ["shift+alt+u" ], "command":"move", "args": {"by": "lines","forward": false, "extend": true} },
{ "keys": ["shift+alt+d" ], "command":"move", "args": {"by": "lines","forward": true, "extend": true} },
//移动光标到行首或行末
{ "keys": ["alt+b"], "command":"move_to", "args": {"to": "bol","extend": false} },
{ "keys": ["alt+e"], "command":"move_to", "args": {"to": "eol","extend": false} },
{ "keys": ["shift+alt+b"], "command":"move_to", "args": {"to": "bol","extend": true} },
{ "keys": ["shift+alt+e"], "command":"move_to", "args": {"to": "eol","extend": true} },
//滚屏
{ "keys": ["alt+g"], "command":"scroll_lines", "args": {"amount": 1.0 } },
{ "keys": ["alt+h"], "command":"scroll_lines", "args": {"amount": -1.0 } },
//缩进
{ "keys": ["shift+tab"], "command":"unindent" }
]
Nach dem Login kopieren

Das obige ist der detaillierte Inhalt vonDetaillierte Erläuterung der Bindung von Eclipse-Tastenkombinationen an Sublime Text. Für weitere Informationen folgen Sie bitte anderen verwandten Artikeln auf der PHP chinesischen Website!

Erklärung dieser Website
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn

Heiße KI -Werkzeuge

Undresser.AI Undress

Undresser.AI Undress

KI-gestützte App zum Erstellen realistischer Aktfotos

AI Clothes Remover

AI Clothes Remover

Online-KI-Tool zum Entfernen von Kleidung aus Fotos.

Undress AI Tool

Undress AI Tool

Ausziehbilder kostenlos

Clothoff.io

Clothoff.io

KI-Kleiderentferner

AI Hentai Generator

AI Hentai Generator

Erstellen Sie kostenlos Ai Hentai.

Heißer Artikel

R.E.P.O. Energiekristalle erklärten und was sie tun (gelber Kristall)
1 Monate vor By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Beste grafische Einstellungen
1 Monate vor By 尊渡假赌尊渡假赌尊渡假赌
Will R.E.P.O. Crossplay haben?
1 Monate vor By 尊渡假赌尊渡假赌尊渡假赌

Heiße Werkzeuge

Notepad++7.3.1

Notepad++7.3.1

Einfach zu bedienender und kostenloser Code-Editor

SublimeText3 chinesische Version

SublimeText3 chinesische Version

Chinesische Version, sehr einfach zu bedienen

Senden Sie Studio 13.0.1

Senden Sie Studio 13.0.1

Leistungsstarke integrierte PHP-Entwicklungsumgebung

Dreamweaver CS6

Dreamweaver CS6

Visuelle Webentwicklungstools

SublimeText3 Mac-Version

SublimeText3 Mac-Version

Codebearbeitungssoftware auf Gottesniveau (SublimeText3)

Was soll ich zum Öffnen von HTML verwenden? Was soll ich zum Öffnen von HTML verwenden? Apr 21, 2024 am 11:33 AM

Zum Öffnen von HTML-Dateien müssen Sie einen Browser wie Google Chrome oder Mozilla Firefox verwenden. Um eine HTML-Datei mit einem Browser zu öffnen, gehen Sie folgendermaßen vor: 1. Öffnen Sie Ihren Browser. 2. Ziehen Sie die HTML-Datei per Drag-and-Drop in das Browserfenster oder klicken Sie auf das Menü „Datei“ und wählen Sie „Öffnen“.

Welche Software eignet sich für die Python-Programmierung? Welche Software eignet sich für die Python-Programmierung? Apr 20, 2024 pm 08:11 PM

IDLE und Jupyter Notebook werden für Anfänger empfohlen, und PyCharm, Visual Studio Code und Sublime Text werden für mittlere/fortgeschrittene Schüler empfohlen. Die Cloud-IDEs Google Colab und Binder bieten interaktive Python-Umgebungen. Weitere Empfehlungen sind Anaconda Navigator, Spyder und Wing IDE. Zu den Auswahlkriterien gehören Qualifikationsniveau, Projektgröße und persönliche Vorlieben.

So öffnen Sie eine lokale Datei in HTML So öffnen Sie eine lokale Datei in HTML Apr 22, 2024 am 09:39 AM

Mit HTML können lokale Dateien wie folgt geöffnet werden: Erstellen Sie eine .html-Datei und importieren Sie die jQuery-Bibliothek. Erstellen Sie ein Eingabefeld, das es dem Benutzer ermöglicht, eine Datei auszuwählen. Hören Sie sich das Dateiauswahlereignis an und verwenden Sie ein FileReader()-Objekt, um den Dateiinhalt zu lesen. Zeigen Sie den Inhalt der gelesenen Datei auf der Webseite an.

So erstellen Sie eine Py-Datei in Python So erstellen Sie eine Py-Datei in Python May 05, 2024 pm 07:57 PM

Schritte zum Erstellen einer .py-Datei in Python: Öffnen Sie einen Texteditor (z. B. Notepad, TextMate oder Sublime Text). Erstellen Sie eine neue Datei und geben Sie den Python-Code ein. Achten Sie dabei auf Einrückung und Syntax. Verwenden Sie beim Speichern der Datei die Erweiterung .py (z. B. my_script.py).

So verwenden Sie den kopierten Code in Python So verwenden Sie den kopierten Code in Python Apr 20, 2024 pm 06:26 PM

Hier sind die Schritte zur Verwendung von kopiertem Code in Python: Kopieren Sie den Code und fügen Sie ihn in einen Texteditor ein. Erstellen Sie eine Python-Datei. Führen Sie den Code über die Befehlszeile aus. Verstehen Sie, wozu der Code dient und wie er funktioniert. Ändern Sie den Code nach Bedarf und führen Sie ihn erneut aus.

Womit kann ich HTML öffnen? Womit kann ich HTML öffnen? Apr 21, 2024 am 11:36 AM

HTML-Dateien können mit einem Browser (z. B. Chrome, Firefox, Edge, Safari, Opera) geöffnet werden: Suchen Sie die HTML-Datei (.html- oder .htm-Erweiterung); wählen Sie „Öffnen“; ; Wählen Sie die Datei aus, die Sie im Browser verwenden möchten.

Erstellen und öffnen Sie leere HTML-Dokumente Erstellen und öffnen Sie leere HTML-Dokumente Apr 09, 2024 pm 12:06 PM

Erstellen Sie ein HTML-Dokument: Geben Sie die HTML-Struktur mit einem Texteditor ein und speichern Sie sie als .html-Datei. Öffnen Sie ein HTML-Dokument: Doppelklicken Sie auf die Datei oder verwenden Sie die Option „Datei“ > „Öffnen“ in Ihrem Browser. Praxisfall: Erstellen Sie eine neue HTML-Datei, fügen Sie Titel, Stylesheet und Inhalt hinzu und speichern Sie sie als .html-Datei.

Welche HTML-Editor-Software ist einfach zu verwenden? Welche HTML-Editor-Software ist einfach zu verwenden? Apr 17, 2024 am 04:54 AM

Zusammenfassend lässt sich sagen, dass die folgenden HTML-Editoren hoch gelobt werden: Visual Studio Code: Plattformübergreifend, funktionsreich, kostenlos und Open Source. Sublime Text: Leistungsstarke, hochgradig anpassbare, kostenpflichtige Software. Atom: plattformübergreifend, skalierbar, Open Source und kostenlos. Klammern: speziell für die Front-End-Entwicklung, intuitive Benutzeroberfläche, Open Source und kostenlos. Notepad++: leicht, schnell, leistungsstark, Open Source und kostenlos. Berücksichtigen Sie bei der Auswahl eines HTML-Editors Faktoren wie Plattformkompatibilität, Funktionen, Erweiterbarkeit, Preis und Benutzerfreundlichkeit.

See all articles