Skip to content

Commit

Permalink
Merge pull request #1 from sleutho/spring2017sprint
Browse files Browse the repository at this point in the history
Spring2017sprint
  • Loading branch information
sleutho authored Apr 3, 2017
2 parents 09bc576 + f3d2759 commit f60babc
Show file tree
Hide file tree
Showing 11 changed files with 289 additions and 71 deletions.
13 changes: 0 additions & 13 deletions .vscode/launch.json

This file was deleted.

11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
## [0.2.0 Preview]
### Added
- Improved syntax highlight
- Numerics
- Nested procs
- Improved snipets
- Improved presentation


## [0.1.1 Fork]
- Started as a fork of [another Tcl Extension](https://marketplace.visualstudio.com/items?itemName=rashwell.tcl)
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# TCL Language Support for VS Studio Code
# Tcl for Visual Studio Code

This extension adds rich language support for the TCL language. including so far
- Language service
- Syntax highlighting
- Snippets

- Colorization
- Snippets
If you run into any problems, please file an issue on [GitHub](https://github.com/sleutho/tcl).

## Syntax highlighting
![Syntax highlighting](images/syntax-highlight.png)

## Snippets
![Snippets](images/snippets.gif)
144 changes: 144 additions & 0 deletions images/Tcl-powered.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed images/logo.png
Binary file not shown.
Binary file added images/snippets.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/syntax-highlight.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
15 changes: 6 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,23 +1,20 @@
{
"name": "tcl",
"displayName": "TCL",
"description": "TCL Language Support",
"version": "0.0.2",
"publisher": "rashwell",
"displayName": "Tcl",
"description": "Tcl language support",
"version": "0.2.0",
"publisher": "sleutho",
"icon": "images/Tcl-powered.svg",
"engines": {
"vscode": "^0.10.1"
},
"repository": {
"type": "git",
"url": "https://github.com/rashwell/tcl.git"
"url": "https://github.com/sleutho/tcl.git"
},
"categories": [
"Languages"
],
"galleryBanner": {
"color": "#9AB3CF",
"theme": "light"
},
"contributes": {
"languages": [
{
Expand Down
105 changes: 91 additions & 14 deletions snippets/tcl.json
Original file line number Diff line number Diff line change
@@ -1,65 +1,142 @@
{
"For Loop": {
"for": {
"prefix": "for",
"body": [
"for \\{set ${index} 0\\} \\{ \\$${index} < ${length} \\} \\{ incr ${index} \\} \\{",
"for {set ${1:index} ${2:0}} {\\$${1:index} < ${3:length}} {incr ${1:index}} {",
"\t$0",
"}"
],
"description": "For Loop"
},
"Foreach Loop": {
"foreach": {
"prefix": "foreach",
"body": [
"foreach ${var} ${list} \\{",
"foreach ${1:var} ${2:list} {",
"\t$0",
"}"
],
"description": "Foreach Loop"
},
"If Condition": {
"if": {
"prefix": "if",
"body": [
"if \\{${var}\\} \\{",
"if {${1:var}} {",
"\t$0",
"}"
],
"description": "If Condition"
},
"ElseIf Condition": {
"elseif": {
"prefix": "elseif",
"body": [
"elseif \\{${var}\\} \\{",
"elseif {${1:var}} {",
"\t$0",
"}"
],
"description": "ElseIf Condition"
},
"Else Block": {
"else": {
"prefix": "else",
"body": [
"else \\{",
"else {",
"\t$0",
"}"
],
"description": "Else Block"
},
"Proc Block": {
"proc": {
"prefix": "proc",
"body": [
"proc ${name} \\{${args}\\} \\{",
"proc ${1:name} {${2:args}} {",
"\t$0",
"}"
],
"description": "Proc Block"
},
"While Lopp": {
"while": {
"prefix": "while",
"body": [
"while \\{${var}\\} \\{",
"while {${1:var}} {",
"\t$0",
"}"
],
"description": "While Loop"
},
"catch": {
"prefix": "catch",
"body": [
"catch {${1:body}} ${2:var}"
],
"description": "Catch Block"
},
"try": {
"prefix": "try",
"body": [
"try {",
"\t$1",
"} finally {",
"\t$0",
"}"
],
"description": "Try Block"
},
"switch": {
"prefix": "switch",
"body": [
"switch ${1:var} {",
"\t${2:case} {$3}",
"\tdefault {$0}",
"}"
],
"description": "Switch Block"
},
"oo::class create": {
"prefix": "oo::class create",
"body": [
"oo::class create ${1:name} {",
"\t${2:superclass s}",
"\tconstructor {} {",
"\t\t$3",
"\t}",
"\tmethod ${4:m} {} {",
"\t\t$0",
"\t}",
"}"
],
"description": "Class Create"
},
"tk_chooseDirectory": {
"prefix": "tk_chooseDirectory",
"body": [
"tk_chooseDirectory ${-initialdir dirname -mustexist boolean -title titleString}"
],
"description": "Choose Directory"
},
"tk_getOpenFile": {
"prefix": "tk_getOpenFile",
"body": [
"tk_getOpenFile -filetypes {",
"\t\t{{Text Files} {.txt} }",
"\t\t{{All Files} * }",
"\t}"
],
"description": "Open File Dialog"
},
"tk_getSaveFile": {
"prefix": "tk_getSaveFile",
"body": [
"tk_getSaveFile -filetypes {",
"\t\t{{Text Files} {.txt} }",
"\t\t{{All Files} * }",
"\t}"
],
"description": "Save File Dialog"
},
"tk_messageBox": {
"prefix": "tk_messageBox",
"body": [
"tk_messageBox ${-message msg}"
],
"description": "Message Box"
}
}
Loading

0 comments on commit f60babc

Please sign in to comment.