Post New Topic  Post A Reply
my profile | register | search | faq | forum home
  next oldest topic   next newest topic
» MacOSX - forked.net   » Ported Packages   » colors in VIM?

UBBFriend: Email this page to someone!    
Author Topic: colors in VIM?
georgemp
Junior Member
Member # 171

posted October 18, 2001 05:14 PM      Profile for georgemp   Email georgemp   Send New Private Message      Edit/Delete Post  Reply With Quote 
Hi,
I downloaded and installed the vim package from here. But, try as i might I can't get it to display color. It instead underlines and highlights in bold. I'm a newbie vim user and in Linux I just did the following to get my syntax in color
:syntax enable
:set filetype=cpp
I've tried running VIM both in the mac os X terminal and xterm and eterm via XDarwin. gVIM displays in color tho in XDarwin but not in the OS X terminal. How do i get it to work? Any help appreciated. Thanks. I primarily want to get it to work in color under the OS X terminal if possible.

Posts: 2 | From: India | Registered: Oct 2001  |  IP: Logged
sungwoo
Junior Member
Member # 183

posted October 21, 2001 10:44 AM      Profile for sungwoo        Edit/Delete Post  Reply With Quote 
Sorry about off-topic... I am newbie in here.
I just installed VIM6.0 but got the following error.

dyld: vim can't open library: /usr/X11R6/lib/libXaw.7.dylib (No such file or directory, errno = 2)

Seems like the VIM is XDarwin application? Should I have to install XDarwin and Xwindows?
Does XEmacs needs XDarwin as well?
Thanks....


Posts: 1 | From: uk | Registered: Oct 2001  |  IP: Logged
apex
Administrator
Member # 1

posted October 22, 2001 01:10 AM      Profile for apex   Email apex   Send New Private Message      Edit/Delete Post  Reply With Quote 
georgemp:
Type this whilst in vim

code:

:set term=builtin_ansi


Posts: 307 | From: Alaska | Registered: Aug 2001  |  IP: Logged
apex
Administrator
Member # 1

posted October 22, 2001 01:14 AM      Profile for apex   Email apex   Send New Private Message      Edit/Delete Post  Reply With Quote 
quote:
Originally posted by sungwoo:
Sorry about off-topic... I am newbie in here.
I just installed VIM6.0 but got the following error.

dyld: vim can't open library: /usr/X11R6/lib/libXaw.7.dylib (No such file or directory, errno = 2)

Seems like the VIM is XDarwin application? Should I have to install XDarwin and Xwindows?
Does XEmacs needs XDarwin as well?
Thanks....


You need Xfree86, and you probably want Xdarwin also. Yep, Xemacs requires X also.


Posts: 307 | From: Alaska | Registered: Aug 2001  |  IP: Logged
PEZ
Junior Member
Member # 347

posted March 01, 2002 05:00 AM      Profile for PEZ        Edit/Delete Post  Reply With Quote 
quote:
Originally posted by georgemp:
I primarily want to get it to work in color under the OS X terminal if possible.

An ugly, but working solution is to add the line

let &t_Co = 8

to your .vimrc file somewhere before it turns syntax highlightning on.


Posts: 1 | Registered: Mar 2002  |  IP: Logged
georgemp
Junior Member
Member # 171

posted March 01, 2002 10:45 AM      Profile for georgemp   Email georgemp   Send New Private Message      Edit/Delete Post  Reply With Quote 
Hi,
Thanks for the various replies. I managed to get a fix from http://ahdore.com/craig/vim/osx.html
before I could try out these. Basically you have to edit the /usr/share/misc/termcap.db and enter/modify

d0|foo|vt100|vt100-am|vt100am|dec vt100:\
:Co#8:Sf=\E[3%dm:Sb=\E[4%dm:\
:do=^J:co#80:li#24:cl=\E[;H\E[2J:sf=2*\ED:\
:le=^H:bs:am:cm=5\E[%i%d;%dH:nd=2\E[C:up=2\E[A:\
:...... (lots of lines follow here)

The second line :do ... has to be added in

Then u need to
sudo cap_mkdb /usr/share/misc/termcap.db

Then open a new terminal window and
set term ansi (u can enter this in your .tcshrc file so that u don't have to enter it with each window opened)

VIM will work in color now. :-)

Thanks once again for the replies.


georgemp

[ March 01, 2002: Message edited by: georgemp ] :mad: :mad: :mad: :mad: :mad: :mad: :mad:

[ March 01, 2002: Message edited by: georgemp ]


Posts: 2 | From: India | Registered: Oct 2001  |  IP: Logged

All times are Pacific Time  

Post New Topic  Post A Reply Close Topic    Move Topic    Delete Topic next oldest topic   next newest topic
Hop To:

Contact Us | macosx.forked.net

Powered by Infopop Corporation
Ultimate Bulletin BoardTM 6.1.0.2