I used to use putty with Unix server to open screen, and then use Vim to write Python. This recording improves the color of Python.
Activating 256-Color terminal
First, increase the available color to 256 colors, make sure Putty is the new version (old version Putty does not support 256 colors). Then, "let vim, screen support 256 colors" to set screen and Vim, remember to use the text mentioned in the Colortest test whether there are 256 colors, success, the numbers 0 ~ 15 for the original 16 colors, 16 ~ 231 for the new color (6 X 6 x 6), 232 ~ 255 for new gray color. You can see the numbers and colors with colortest.
Here to forget the steps mentioned in this article:
- Join in ~/.VIMRC:
- Join in ~/.SCREENRC:
1 |
Termcapinfo xterm ' CO#256:AB=\E[48;5;%DM:AF=\E[38;5;%DM ' |
Update the format of the Python script detector
Update the Syntax/python.vim to let vim detect more of the formats, such as the end of the line, or blank lines with spaces will be detected. The procedure is as follows:
- Download the latest Python.vim and put it under ~/.vim/syntax/.
- Edit ~/.VIMRC, join
1 |
Let Python_highlight_all = 1 |
To show all python.vim in the form of a reconnaissance. Take a look at the Python.vim and learn about the details.
Replace the color that is displayed
- Download the Vim color Scheme:Wombat256.vim and put it under ~/.vim/colors/.
- Join in ~/.VIMRC
So there is a beautiful color, wombat256 screenshot see here.
Registration
This website offers many different color scheme screenshot, but it does not have Python screenshot.
Original: https://www.cnblogs.com/lexus/archive/2012/03/11/2390414.html
Enhanced Python color in Vim