You are here: PSPad forum > English discussion forum > CTRL+V adds extra spaces at the end of the line

CTRL+V adds extra spaces at the end of the line

#1 CTRL+V adds extra spaces at the end of the line

Posted by: TrywareDk | Date: 2014-02-27 16:33 | IP: IP Logged

When I copy paste at the end of a line it works, but my cursor moves several spaces to the right, after the text being copy pasted.

The reason is, that the number of tabs to the left of where I paste, is calculated to a number of spaces, and this number of spaces is added to the right

Do you have a fix for this?

In this example I show you tabs as #, spaces as ¤, cursor as &, CTRL+V as %
and my tabs is set to 4 spaces

Shown with # ¤ & %:
#If¤bStatus¤Then¤bStatus¤=¤Len(sExample)&

Shown in PsPad:
If bStatus Then bStatus = Len(sExample)

If I want to add a comment on the above, which comment I maybe have from a website, I put my cursor after Len(sExample), press 1 tab and writes ' More info on (and here I press CTRL+V in order to get the www.

Shown with # ¤ & %:
#If¤bStatus¤Then¤bStatus¤=¤Len(sExample)#'#More¤info¤on¤%www.¤¤¤¤¤¤¤¤¤¤¤¤&

Shown in PsPad:
If bStatus Then bStatus = Len(sExample) ' More info on www.

As you can't see above in this forum (but you can in PsPad), there are 3 tabs in the line to the left of my CTRL+V, so it's 3x4 spaces, that's added at the end of the line.

Sincerely
Jorgen Malmgren
www.tryware.dk

--
Sincerely

J. Malmgren
IT-Programmer
www.tryware.dk

Options: Reply | Quote | Up ^


#2 Re: CTRL+V adds extra spaces at the end of the line

Posted by: carbonize | Date: 2014-03-01 21:32 | IP: IP Logged

I'm guessing that when you copy the string you are also copying the tabs from the end of it which is why the space is being added.

--
Carbonize

Options: Reply | Quote | Up ^






Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR