Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
vim syntax highlighting
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
UnderDog138
n00b
n00b


Joined: 03 Dec 2002
Posts: 67
Location: Dallas, TX, USA

PostPosted: Thu Jan 09, 2003 12:17 am    Post subject: vim syntax highlighting Reply with quote

Is there a plugin for vi/m that allows c/++ syntax highlighting? I know it exists because I used it when I had mandrake ages ago, but I can't find out any information about it.
_________________
Adopt an unanswered post today!
Back to top
View user's profile Send private message
raluke
n00b
n00b


Joined: 11 Aug 2002
Posts: 56
Location: Maryland, USA

PostPosted: Thu Jan 09, 2003 12:31 am    Post subject: Reply with quote

Just type ":syn on" and it ought to pick up on the fact that the file is a c++ file. Maybe you should give it a "*.cpp" or ".cxx" extension to give it even more of a clue, but that may not be necessary.

-Robert
Back to top
View user's profile Send private message
UnderDog138
n00b
n00b


Joined: 03 Dec 2002
Posts: 67
Location: Dallas, TX, USA

PostPosted: Thu Jan 09, 2003 1:48 am    Post subject: Reply with quote

Nifty.. that works. Thanks.
_________________
Adopt an unanswered post today!
Back to top
View user's profile Send private message
Valen
Apprentice
Apprentice


Joined: 18 Aug 2002
Posts: 197
Location: Toronto, Ontario, Canada

PostPosted: Thu Jan 09, 2003 3:10 am    Post subject: Reply with quote

If you want to for a certain syntax on vim use
Code:
:set syn=*
you can use cpp,pascal,java,sh whatever you like (look in /usr/share/vim/vim***/syntax/ for others).
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum