Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support inserting outside code when texts are selected, some like VS #4715

Merged
merged 1 commit into from
Aug 23, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 17 additions & 17 deletions snippets/csharp.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"body": [
"checked",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Checked block"
Expand All @@ -52,7 +52,7 @@
"Console.WriteLine": {
"prefix": "cw",
"body": [
"System.Console.WriteLine($0);"
"System.Console.WriteLine(${TM_SELECTED_TEXT}$0);"
],
"description": "Console.WriteLine"
},
Expand All @@ -61,7 +61,7 @@
"body": [
"do",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"} while (${1:true});"
],
"description": "do...while loop"
Expand All @@ -71,7 +71,7 @@
"body": [
"else",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Else statement"
Expand Down Expand Up @@ -140,7 +140,7 @@
"body": [
"foreach (${1:var} ${2:item} in ${3:collection})",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Foreach statement"
Expand All @@ -150,7 +150,7 @@
"body": [
"for (int ${1:i} = ${2:length} - 1; ${1:i} >= 0 ; ${1:i}--)",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Reverse for loop"
Expand All @@ -160,7 +160,7 @@
"body": [
"for (int ${1:i} = 0; ${1:i} < ${2:length}; ${1:i}++)",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "for loop"
Expand All @@ -170,7 +170,7 @@
"body": [
"if (${1:true})",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "if statement"
Expand Down Expand Up @@ -271,7 +271,7 @@
"body": [
"lock (${1:this})",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Lock statement"
Expand All @@ -297,7 +297,7 @@
"prefix": "ifd",
"body": [
"#if ${1:true}",
" $0",
" ${TM_SELECTED_TEXT}$0",
"#endif"
],
"description": "#if"
Expand All @@ -306,7 +306,7 @@
"prefix": "region",
"body": [
"#region ${1:Name}",
" $0",
" ${TM_SELECTED_TEXT}$0",
"#endregion"
],
"description": "#region"
Expand Down Expand Up @@ -385,7 +385,7 @@
"body": [
"try",
"{",
" $1",
" ${TM_SELECTED_TEXT}$1",
"}",
"finally",
"{",
Expand All @@ -399,7 +399,7 @@
"body": [
"try",
"{",
" $1",
" ${TM_SELECTED_TEXT}$1",
"}",
"catch (${2:System.Exception})",
"{",
Expand All @@ -414,7 +414,7 @@
"body": [
"unchecked",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Unchecked block"
Expand All @@ -424,7 +424,7 @@
"body": [
"unsafe",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Unsafe statement"
Expand All @@ -434,7 +434,7 @@
"body": [
"using (${1:resource})",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "Using statement"
Expand All @@ -444,7 +444,7 @@
"body": [
"while (${1:true})",
"{",
" $0",
" ${TM_SELECTED_TEXT}$0",
"}"
],
"description": "While loop"
Expand Down