LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-08-2011, 03:46 PM   #1
daghenningsorbo
LQ Newbie
 
Registered: Mar 2009
Posts: 24

Rep: Reputation: 0
VIM - Visual Mode problem


Hi,
this problem only occurs in Vim (not GVim).

When pressing v (aka entering visual mode) it doesn't enter visual mode. But the second press of v starts it, but then visual mode behaves weird.

The <Leader> is not recognized, so my mappings doesn't work. This happens even when starting vim with "vim -u NONE".

Does anyone have a clue about what might be wrong?


Regards,
dagH
 
Old 08-08-2011, 04:30 PM   #2
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005
Hello,

What distribution are you using? It seems as when you open up vim, you are using the original vim modes; You most likely need to install the vim-common and vim-enhanced packages, along with the dependencies that normally come with it.

If you are using ubuntu, enter the following on the command line:
Code:
sudo apt-get install vim
Cheers,

Josh

Last edited by corp769; 08-08-2011 at 04:31 PM.
 
Old 08-08-2011, 05:13 PM   #3
daghenningsorbo
LQ Newbie
 
Registered: Mar 2009
Posts: 24

Original Poster
Rep: Reputation: 0
Well, I have all that installed, so it can't be the reason.

I thought that it might be problems in my vimrc file, but the problem was still there even when I ran vim without the vimrc file.

Any other clue?

PS: using Ubuntu 10.04
 
Old 08-08-2011, 05:23 PM   #4
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005
Can you post what is outputted when you ran the above command? I know it sounds silly, but when I was at my friends house a while back, he had a similar problem, and he needed to install more packages than he realized.
 
Old 08-08-2011, 05:31 PM   #5
daghenningsorbo
LQ Newbie
 
Registered: Mar 2009
Posts: 24

Original Poster
Rep: Reputation: 0
I didn't run it because it was already installed, but my installed vim packages are these:

Code:
~$ dpkg --get-selections | grep vim
vim                                             install
vim-common                                      install
vim-doc                                         install
vim-gnome                                       install
vim-gui-common                                  install
vim-runtime                                     install
vim-tiny                                        install
out of possible:

Code:
~$ apt-cache search vim | grep vim
vim - Vi IMproved - enhanced vi editor
vim-common - Vi IMproved - Common files
vim-dbg - Vi IMproved - enhanced vi editor (debugging symbols)
vim-doc - Vi IMproved - HTML documentation
vim-gnome - Vi IMproved - enhanced vi editor - with GNOME2 GUI
vim-gui-common - Vi IMproved - Common GUI files
vim-runtime - Vi IMproved - Runtime files
vim-tiny - Vi IMproved - enhanced vi editor - compact version
jvim-canna - Japanized VIM (Canna version)
jvim-doc - Documentation for jvim (Japanized VIM)
libtext-vimcolor-perl - syntax color text in HTML or XML using Vim
libvi-quickfix-perl - Perl support for vim's QuickFix mode
vim-addon-manager - manager of addons for the Vim editor
vim-gtk - Vi IMproved - enhanced vi editor - with GTK2 GUI
vim-latexsuite - view, edit and compile LaTeX documents from within Vim
vim-nox - Vi IMproved - enhanced vi editor
vim-rails - plugins for vim to allow easier editing of Rails Applications
vim-scripts - plugins for vim, adding bells and whistles
vim-syntax-gtk - Syntax files to highlight GTK+ keywords in vim
vim-vimoutliner - script for building an outline editor on top of Vim
vimhelp-de - Vi IMproved - Documentation files (German translation)
vim-puppet - Vim syntax highlighting for puppet manifests
But I don't think this is the problem, but hey, maybe it is
 
Old 08-08-2011, 05:34 PM   #6
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005
I'm about to leave for work dude, but for the hell of it, try removing vim-tiny for the time being, along with messing with the other packages. I know it's a simple fix, but I don't time until now plus 12-13 hours.....

Hope you find a fix while I'm gone!

-Josh
 
Old 08-08-2011, 05:49 PM   #7
daghenningsorbo
LQ Newbie
 
Registered: Mar 2009
Posts: 24

Original Poster
Rep: Reputation: 0
Hey man, thanks!

...even if the problem wasn't vim-tiny, but your suggestion pointed me in the right direction. The problem was the binary vim.gnome which /usr/bin/vim linked to. When I started /usr/bin/vim.basic, then problem disappeared right away

So thanks for leading be in the right direction
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Visual mode of VIM jcky Linux - Newbie 2 01-03-2010 05:18 AM
LXer: A visual walk through of a couple of the new features in Vim 7.0 LXer Syndicated Linux News 0 09-21-2006 10:54 AM
VIM insert before a visual block... pld Linux - Software 0 06-22-2005 12:36 PM
Using Visual in VIM editor manikantha Linux - General 4 06-10-2005 09:55 AM
Possible problem with VISUAL=vi (vim & bash) redthor Linux - Newbie 2 04-26-2005 07:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:10 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration