Disabling clicking beyond end of line
-
Hi everyone. I’m not sure what to call this so I’ll try to describe as best I can. I have 2 computers with Notepad++ installed: my local machine where I can upgrade and manage plugins, and a VM where I don’t have access to make any changes.
On my local machine, when I click past (to the right) of a CRLF, it extends the CRLF to where I clicked (which I don’t want). On my VM, if I click past the CRLF, it places the cursor at the existing CRLF (which I do want).
I’ve compared the settings/preferences between the two and unless I missed something I don’t see anything that would affect the issue. I also disabled the plugins on my local machine but that didn’t fix the issue either.
Is this just a feature of the newer versions of N++, or does anyone know how I can change this behavior? Debug info below. Thanks in advance for any help!
– Computer that dynamically extends the CRLF –
Notepad++ v8.4.4 (64-bit)
Build time : Jul 15 2022 - 17:54:42
Path : C:\Program Files\Notepad++\notepad++.exe
Command Line :
Admin mode : OFF
Local Conf mode : OFF
Cloud Config : OFF
OS Name : Windows 10 Enterprise (64-bit)
OS Version : 21H1
OS Build : 19043.928
Current ANSI codepage : 1252
Plugins :
ComparePlugin (2.0.2)
CSVLint (0.4.5.2)
CsvQuery (1.2.9)
mimeTools (2.8)
NppConverter (4.4)
NppExport (0.4)
NPPJSONViewer (1.40)
NppSaveAsAdmin (1.0.211)
NppToolBucket (1.10.6622.41516)
RegexTrainer (1)
SQLinFormNpp64 (5.3.35)
XMLTools (3.1.1.13)– Computer that retains the existing CRLF –
Notepad++ v8.2 (32-bit)
Build time : Dec 30 2021 - 03:36:49
Path : C:\Program Files (x86)\Notepad++\notepad++.exe
Command Line :
Admin mode : OFF
Local Conf mode : OFF
Cloud Config : OFF
OS Name : Windows 10 Enterprise (64-bit)
OS Version : 2009
OS Build : 19042.1889
Current ANSI codepage : 1252
Plugins : ComparePlugin.dll mimeTools.dll NppConverter.dll NppExport.dll -
I cannot replicate.
- If I click at 1,
- The cursor goes to 2
- If I
Alt+Click+Drag
from 3 to 4 (which makes use of “column select mode”) - Notepad++ will move the EOL sequences (
CRLF
) to be to the right of the rectangle - (but if I click somewhere else without typing anything, the EOL will snap back to where they were before)
You can look for unexpected characters beyond the last visible character by turning on View > Show Symbol > Show All Characters (which I did right before the screenshots above) – this will show literal spaces (ASCII 32) as a middot
∙
(pale orange in my screenshot), and a tab as a stretched right arrow→
, and control characters as things like theCR
andLF
in the screenshot. Maybe you just happen to have other characters. (If you have other characters you see, you might try running the script from this post in PythonScript plugin { see instructions for running a script with that plugin } – it will reveal other characters that have no glyph because they are invisible/zero-width.)Other than that, since you already said you tried running without plugins, I am not sure why it still plagues you.
That said, the underlying editor component does have a concept of “virtual space” which allows moving the cursor beyond the end of the line; that feature is not enabled by default in Notepad++, and Notepad++ doesn’t expose that option to users without a plugin; however, the plugin ExtSettings does give you access to that: I can toggle that behavior with the “Cursor beyond line endings” checkbox in that plugin’s dialog. I don’t know how it got turned on for you, but maybe that plugin will be able to turn it off for you. (Since the problem is occurring on a machine where you have the ability to add plugins, then maybe you won’t mind installing another plugin to try to fix it.)
Notepad++ v8.4.4 (64-bit) Build time : Jul 15 2022 - 17:54:42 Path : C:\usr\local\apps\npp\npp.8.4.4.portable.x64\notepad++.exe Command Line : Admin mode : OFF Local Conf mode : ON Cloud Config : OFF OS Name : Windows 10 Enterprise (64-bit) OS Version : 20H2 OS Build : 19042.1889 Current ANSI codepage : 1252 Plugins : mimeTools (2.8) NppConverter (4.4) NppExport (0.4)
-
Nevermind, I am an idiot.
Settings > Preferences > Editing > Enable Virtual Space does give you access. That feature was added in v8.4.3, but it wasn’t specifically mentioned in the change list (it was implied as part of the make-EOL-customizable entry), so I didn’t know to add it to the user manual. Well, I know what I’m doing next. 😉
-
@PeterJones said in Disabling clicking beyond end of line:
concept of “virtual space” which allows moving the cursor beyond the end of the line; that feature is not enabled by default in Notepad++
Still, @willb2022 had to have gone in and enabled that, so really, the moral of the story is, when you’re enabling something, ask yourself “Do I really know what this does?”. Also, if you then notice a behavior you don’t like, ask yourself “Did I change something that could affect this?”
-
@willb2022 said in Disabling clicking beyond end of line:
when I click past (to the right) of a CRLF, it extends the CRLF to where I clicked
Actually, it doesn’t do anything except put your caret out in the virtual space area – if you don’t start typing there, it won’t have any other effect.
It is a bit strange when you have visible line endings turned on, though, because it moves the CRLF notation to the right of that virtual caret position, which IMO is misleading.
-
That was it, thank you! When comparing the two, I didn’t see this in the older version, and since I didn’t know what this did, I didn’t uncheck it. Very appreciative for your help!
-
@Alan-Kilborn, actually I don’t recall enabling that. Either I fat-fingered it by accident, or it was enabled by the previous user before I acquired this computer. In either case, unchecking it solved the problem.