sponsor Vim development Vim logo Vim Book Ad

Freebasic vim syntax file : Freebasic syntax file.  Can be used since v5.7

 script karma  Rating 2/2, Downloaded by 993  Comments, bugs, improvements  Vim wiki

created by
Mark Manning
script type
This is the freebasic syntax file I have provided since v5.7.  It handles all (as far as I know) of the freebasic commands.  If you find that there are some it does not cover - please do let me know at markem-at-sim1.us.
install details
You may have to modify the filetype.vim file.  If so, you should insert the following lines:

\" FreeBasic file (similar to QBasic)
au BufNewFile,BufRead *.fb,*.bi setf freebasic


rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
freebasic.vim 7.0b 2019-09-10 7.0 Mark Manning Ok. Found the &B (binary) and &O (octal) were not there and then I found a problem. I had "\\." when it should have been "\\\\.". Fix this. Makes the code look a lot nicer. :-)
freebasic.vim v7.0 2015-02-23 7.0 Mark Manning Mark,

I understand you made the freebasic.vim file that ships with VIM (7.4
here), and also have the file on github.  I've made a number of changes
to the file to fix a lot of things that just weren't working such as
preprocessor directives (#ifdef, #define, etc).  Fixed up comment
handling a bit, and added multi-line comments (/' '/).  Changed a few
other classifications too to make the code highlight more like how code
is highlighted in other languages such as C, Python, etc.  User-defined
identifiers are not colored at all, which makes code a lot more
readable.  Numbers also were not being highlighted at all before; not
sure why but I fixed that.  There are still some broken things I
encounter once in a while, but overall the highlighting is much
improved. If you want to take a look and merge this into the official
VIM distribution, that'd be great for other users.

I borrowed some code from other syntax files that ship with VIM, such as
the HiLink macro, though I am not sure that was necessary.

freebasic.vim v5.7 2012-07-21 7.0 Mark Manning Initial upload
ip used for rating:

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
Vim at Github