Skip to content

Commit ca8b960

Browse files
authored
Merge pull request #51 from cadenasgmbh/glsl-support
mod: enable glsl support
2 parents 854c90d + 2ae58bf commit ca8b960

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

package.json

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@
3636
"onLanguage:typescript",
3737
"onLanguage:proto",
3838
"onLanguage:proto3",
39-
"onLanguage:apex"
39+
"onLanguage:apex",
40+
"onLanguage:glsl"
4041
],
4142
"contributes": {
4243
"configuration": {
@@ -193,6 +194,21 @@
193194
"default": "",
194195
"description": "clang-format fallback style for Apex, left empty to use clang-format.fallbackStyle"
195196
},
197+
"clang-format.language.glsl.enable": {
198+
"type": "boolean",
199+
"default": true,
200+
"description": "enable formatting for GLSL (requires reloading Visual Studio Code)"
201+
},
202+
"clang-format.language.glsl.style": {
203+
"type": "string",
204+
"default": "",
205+
"description": "clang-format fallback style for GLSL, left empty to use clang-format.style"
206+
},
207+
"clang-format.language.glsl.fallbackStyle": {
208+
"type": "string",
209+
"default": "",
210+
"description": "clang-format fallback style for GLSL, left empty to use clang-format.fallbackStyle"
211+
},
196212
"clang-format.assumeFilename": {
197213
"type": "string",
198214
"default": "",

src/clangMode.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ export const ALIAS = {
77
};
88

99
let languages: string[] = [];
10-
for (let l of ['cpp', 'c', 'objective-c', 'objective-cpp', 'java', 'javascript', 'typescript', 'proto', 'proto3', 'apex']) {
10+
for (let l of ['cpp', 'c', 'objective-c', 'objective-cpp', 'java', 'javascript', 'typescript', 'proto', 'proto3', 'apex', 'glsl']) {
1111
let confKey = `language.${ALIAS[l] || l}.enable`;
1212
if (vscode.workspace.getConfiguration('clang-format').get(confKey)) {
1313
languages.push(l);

0 commit comments

Comments
 (0)