• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Other Editor which allows marking and copying

balanga

Daemon

Thanks: 59
Messages: 1,961

#1
Which editor permits simple block marking and copying to the system clipboard by use of the arrow keys (no mouse cursor) and works in terminal mode?
 

roddierod

Aspiring Daemon

Thanks: 144
Messages: 824

#2
vi/vim.

v - enter the visual mode. move with cursor to select block. y - copy (or yank in vi terms). d - cut.

p is simpliest paste in.

Look up yanking and pasting in vi for more.
 

Bobi B.

Member

Thanks: 44
Best answers: 1
Messages: 97

#3
Which editor permits simple block marking and copying to the system clipboard by use of the arrow keys (no mouse cursor) and works in terminal mode?
Rectangle-like block mode or line mode (a sequence of characters)?
What do you mean exactly by "system clipboard"? Do you want to copy/paste between different console applications (i.e. paste from text editor into shell) on only to move text in the editor itself?
Do you mean virtual terminal, text-only mode (no X)?

Any decent visual editor can copy/paste a sequence of characters from one place to another; see vi(1), editors/mg, too many to list here. editor/emacs can do rectangle-alike block mode.
 

VladiBG

Active Member

Thanks: 40
Messages: 114

#4
vi(1) is part of the base system and support cut/copy/paste with marking a block.
To mark a block and send it to the buffer use mx where x can be any lеtter/number.
To copy use y`x.
To cut use d`x
To paste use p

To copy a single line where the cursor is use yy
To paste the line use pp

If you don't have Xorg and you are using only ssh/terminal i can suggest you to check the Midnight Commander /usr/ports/misc/mc as it has all you need to edit/copy/move/compare files but it's comes with a lot of dependence libraries that you have to update and maintain in the future use of the system.
 

balanga

Daemon

Thanks: 59
Messages: 1,961

#5
Try firing up vi or emacs and just using shift+arrow keys and Ctrl-Ins Shift-Ins for copy and pasting marked text from one place to another (no X) but maybe between different terminals.

I want something simple rather than having to learn dozens of key combinations.
 

balanga

Daemon

Thanks: 59
Messages: 1,961

#6
vi(1) is part of the base system and support cut/copy/paste with marking a block.
To mark a block and send it to the buffer use mx where x can be any lеtter/number.
To copy use y`x.
To cut use d`x
To paste use p

To copy a single line where the cursor is use yy
To paste the line use pp

If you don't have Xorg and you are using only ssh/terminal i can suggest you to check the Midnight Commander /usr/ports/misc/mc as it has all you need to edit/copy/move/compare files but it's comes with a lot of dependence libraries that you have to update and maintain in the future use of the system.

I use Midnight Commander all the time but am frustrated with its inability to mark, copy and paste text the way I would like.
 

VladiBG

Active Member

Thanks: 40
Messages: 114

#7
I use Midnight Commander all the time but am frustrated with its inability to mark, copy and paste text the way I would like.
in Midnight Commander you select /mark the text using F3 and paste it with F5.

Edit: you can also can have multiple files opened at the same time and copy/paste/compare between them in mc
 

balanga

Daemon

Thanks: 59
Messages: 1,961

#8
I can't copy text to the clipboard and then paste it into a shell or another program or terminal.

I want to copy to the system clipboard so that the text can be pasted anywhere.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Thanks: 5,883
Best answers: 6
Messages: 26,492

#10
The problem here is that there's no such thing as a standard "clipboard" on UNIX. All you have are different buffers, and none of them are connected or related to each other. So vi(1) (or vim(1)) has its own buffers, the console (by way of moused(8)) has its own buffer, Xorg has its own buffer, etc. Each individual buffer appears to act like a "clipboard" but in reality they're all different and unrelated.
 
Top