I don't know why but Vim always mess up my formatting if I am copying code from some external program through CTRL + V + P shortcut. For instance this snippet of XML code 
<dependency>
    <groupId>org.jboss.test</groupId>
    <artifactId>richfaces-selenium</artifactId>
    <scope>test</scope>
</dependency>
is copied into Vim like this (sorry for | characters, that is from indentLine plugin )
<dependency>
    │   │   │   │   │   <groupId>org.jboss.test</groupId>
    │   │   │   │   │   │   │   │   <artifactId>richfaces-selenium</artifactId>
    │   │   │   │   │   │   │   │   │   │   │   <scope>test</scope>
    │   │   │   │   │   │   │   │   │   │   │   │   │   </dependency>
So how do I fix this behaviour? Something similar also happens when I paste Java or Python code.
 
     
    