By default if you want to open any files it will take gedit as default text editor.If you want to change this to gvim do the following procedure.
First you need to edit the /etc/gnome/defaults.list file
sudo gedit /etc/gnome/defaults.list
Change the following setting
Save and exit the file this should solve the issue.
You can check this by right clicking on any text file you should see Open with GVim Text Editor