summaryrefslogtreecommitdiffstats
path: root/ftplugin
diff options
context:
space:
mode:
authorAdam Stankiewicz <sheerun@sher.pl>2017-09-27 20:00:19 +0200
committerAdam Stankiewicz <sheerun@sher.pl>2017-09-27 20:00:25 +0200
commit4cd5566b40948bbca93b8c0d6a20e2ad3236046f (patch)
tree310c6ee2a57e074202b7094fc93837c81f0f714c /ftplugin
parent8b3418cab8eb5267b3a5743e4d5fe5f698d48bc8 (diff)
downloadvim-polyglot-4cd5566b40948bbca93b8c0d6a20e2ad3236046f.tar.gz
vim-polyglot-4cd5566b40948bbca93b8c0d6a20e2ad3236046f.zip
Add gmpl and openscan, closes #232, closes #233
Diffstat (limited to 'ftplugin')
-rw-r--r--ftplugin/openscad.vim18
1 files changed, 18 insertions, 0 deletions
diff --git a/ftplugin/openscad.vim b/ftplugin/openscad.vim
new file mode 100644
index 00000000..2933c232
--- /dev/null
+++ b/ftplugin/openscad.vim
@@ -0,0 +1,18 @@
+if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'openscad') == -1
+
+" Blatantly stolen from vim74\ftplugin\c.vim
+
+" Set 'formatoptions' to break comment lines but not other lines,
+" and insert the comment leader when hitting <CR> or using "o".
+setlocal fo-=t fo+=croql
+
+" Set 'comments' to format dashed lists in comments.
+setlocal comments=sO:*\ -,mO:*\ \ ,exO:*/,s1:/*,mb:*,ex:*/,://
+
+" Win32 can filter files in the browse dialog
+if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
+ let b:browsefilter = "OpenSCAD Source Files (*.scad)\t*.scad\n" .
+ \ "All Files (*.*)\t*.*\n"
+endif
+
+endif