sponsor Vim development Vim logo Vim Book Ad

vim-mma : A Neovim plugin to provide Wolfram Mathematica language support

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

created by
Yun Zhi
 
script type
syntax
 
description
vim-mma

NOTE: Please view https://github.com/voldikss/vim-mma for more details and screenshots examples!

A Vim/Neovim plugin to provide Wolfram Mathematica language support.

This is a fork of vim-mathematica with some improvements.

1. Installation

Preferred plugin manager is vim-plug, add

\\\" Install one of these two plugins:
\\\" Plug \\'neoclide/coc.nvim\\'
\\\" Plug \\'Shougo/deoplete.nvim\\'
Plug \\'voldikss/vim-mma\\'
to your .vimrc, restart Vim and run :PlugInstall.

Additionally, Vim doesn\\'t regard *.wl/*.wsl as Mathematica file, you may set filetype by adding the following to your vimrc:

autocmd BufNewFile,BufRead *.wl setfiletype mma
autocmd BufNewFile,BufRead *.wls setfiletype mma

2. Features

- Syntax highlighting

Vim has the orignial support for mma files. However, many mma keywords were not included.

I implemented almost all the keywords of mma(version 11.3) for better syntax highlighting.

- Code completion

This plugin can perform code completion for all the built-in functions or variables(totally 7406 now)

NOTE: You must install Deoplete or Coc completion framework!!!

- Smart Conceal
The conceal features make it easier to read code that has been copied from the Front End. It \\\"hides\\\" symbols such as \\\\[Alpha], which are displayed as α in the Front End, and shows the equivalent Greek letter instead. Some common operators are also prettified, such as ⧴ for :>, ≠ for !=, etc.

To enable this feature, ensure that you have a font that has good unicode support (like Deja Vu Mono) and enter the following in your .vimrc

let g:mma_candy = 1
To turn off the conceal features, simply change the value to 0. Note that the source code is not modified. The conceal feature affects only the display and is disabled for the current line so that you know what you\\'re editing.

There is a second level of conceal features (in addition to the above) which can be turned on with

let g:mma_candy = 2
However, these might not look good in all fonts, and are also a tad awkward, so turn it on only if you like it (I don\\'t use them).
 
install details
" Install one of these two plugins:
" Plug \\'neoclide/coc.nvim\\'
" Plug \\'Shougo/deoplete.nvim\\'
Plug \\'voldikss/vim-mma\\'
to your .vimrc, restart Vim and run :PlugInstall.
 

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
vim-mma.zip 0.1.1 2019-05-02 8.0 Yun Zhi bugs fixed
vim-mma-master.zip 0.1.0 2019-03-30 7.0 Yun Zhi Initial upload
ip used for rating: 34.204.194.190

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.
   
OSDN.net Logo