pub*_*ide 5 comments sublimetext
当我在注释块内输入新行时,有人能指出我如何使SublimeText插入注释延续双斜线?
// I have comments like this, and when I enter a '\n'
// it break's out of comment-entering mode
like this (drops slashes, cursor stays at leftmost column)
// and I want to have them automatically inserted after hiting '\n'
// like this
Run Code Online (Sandbox Code Playgroud)
我可能在调整偏好文件时意外改变了,我不知道如何设置它.
这是我的用户首选项:
{
"animation_enabled": false,
"auto_complete_commit_on_tab": true,
"auto_complete_delay": 200,
"auto_complete_size_limit": 2097152,
"auto_complete_triggers":
[
{
"characters": "<",
"selector": "text.html"
},
{
"characters": ".",
"selector": "source.python"
},
{
"characters": ".",
"selector": "source.javascript"
}
],
"bold_folder_labels": true,
"caret_extra_bottom": 1,
"caret_extra_top": 1,
"caret_extra_width": 0,
"caret_style": "solid",
"color_scheme": "Packages/User/base16-compact.dark (SL).tmTheme",
"copy_with_empty_selection": false,
"default_line_ending": "unix",
"drag_text": false,
"draw_white_space": "none",
"fade_fold_buttons": false,
"font_face": "Inconsolata",
"font_size": 10,
"highlight_modified_tabs": true,
"ignored_packages":
[
"Vintage",
"Diff",
"DocBlockr",
"Markdown",
"Shell Command"
],
"indent_guide_options":
[
"draw_normal"
],
"line_padding_bottom": 1,
"line_padding_top": 1,
"logging_level": "error",
"margin": 0,
"match_brackets_content": false,
"remember_open_files": false,
"scroll_past_end": true,
"scroll_speed": 0,
"shift_tab_unindent": true,
"show_encoding": true,
"show_line_endings": true,
"soda_classic_tabs": true,
"spell_check": false,
"tab_size": 2,
"theme": "Soda Dark.sublime-theme",
"translate_tabs_to_spaces": true,
"tree_animation_enabled": false,
"trim_automatic_white_space": false,
"use_tab_stops": true
}
Run Code Online (Sandbox Code Playgroud)
只需输入以下命令:
CTRL + /
Run Code Online (Sandbox Code Playgroud)
单行注释是single line,如果您想使用另一行,请使用multi-line注释。
/* */
Run Code Online (Sandbox Code Playgroud)
恢复您的偏好:
删除用户首选项中的所有代码并将其替换为 {},然后按 CTRL+S 保存。它应该进行恢复。