I've read this question and answer already, however it could not solve my doubts.
As far as my understanding is correct, p
always has the same effect (p
utting the content of a register, by default the "
register).
Different effects of the p
command are actually a consequence of different contents of the register(s) that we put. In this respect, given the sample text
-----------
---moree---
---lines---
---oftxt---
-----------
moree---
---l
I notice the following:
y
anking/d
eleting character-wisemore
into a register fills the register withmore
;y
anking/d
eleting line-wise---moree---
into a register fills the register with---more---^J
, where^J
is a single caracter representing the linefeed<NL>
;y
anking/d
eleting block-wise the alphabetic rectangle fills the register withmoree^Jlines^Joftxt
, where^J
has the same meaning as above.
However:
- Concerning 2 as compared to 1 and 3, how can something (
^J
) later in the register affect where thep
utting action starts? - Concerning 1 and 2 as compared to 3,
y
anking av
isual selection going from the firstm
to the firstl
will fill the register withmoree---^J---l
,y
anking a blockCTRL-V
isual selection of the last two lines (obtained by 0CTRL-Vj$) fills the register exactly with the same contentmoree---^J---l
,- however putting the two registers will have a different effect.
Can someone please help me understand this?
Besides, is it possible to get ^J
in text just as can get ^M
in text by CTRL-VEnter, ^[
by CTRL-VEscape and so on?
Ctrl-V
+Ctrl-M
then:set fileformat=mac
;)