• Save and Restore Change History Markers

    General Discussion
    2
    1 Votes
    2 Posts
    167 Views
    mpheathM

    @Vince-Aman

    Change History is great feature, though programming usually uses involves a File Versioning System which keeps good progress with diffs, … . Each time I commit, I clear the Undo and Change History and then go another round of code.

    The 2nd week of the month is usually reboot time. Prepare for the worst so I wind down by closing numerous projects and usually manually reboot and start small so an unexpected forced reboot may hurt less. Starting back up with projects is like where was I with what exactly.

    The problem with your idea is make sure to prepare. The idea may have some benefit so did some scripting. The code makes a snapshot before editing the code and then later, which is after a Notepad++ restart, restore from the snapshot and then patch in the changes which will return a new Change History.

    I posted a fresh GIST with BufferRestoreChangeHistory.py . It uses a little bit of code from another older GIST BufferPatch.py so I had a head start on how to do it. There is a readme.md with the GISTs that explain some more details.

    The BufferRestoreChangeHistory.py script requires PythonScript 2 or 3. I usually use PythonScript 3 so it was lucky that testing in PythonScript 2 worked without any code modification. The code is fresh so advise to test before becoming dependent on it in a big way.

  • Move Line Up

    Help wanted · · · – – – · · ·
    5
    1 Votes
    5 Posts
    135 Views
    guy038G

    Hello, @barry-lort, @peterjones and All,

    @barry-lort, here is an other method to solve your problem !

    Let’s suppose that your file contains 100 lines, so 50 lines beginning with #SERVICE and 50 lines beginning with #DESCRIPTION, as below :

    #SERVICE:4:8:1:6:0 #DESCRIPTION Angus #SERVICE:4:7:0:3:0: #DESCRIPTION Ayrshire #SERVICE:5:8:4:1:0 #DESCRIPTION Brown-Swiss #SERVICE:3:6:7:1:0 #DESCRIPTION Galloway #SERVICE:4:9:2:5:0 #DESCRIPTION Guernsey #SERVICE:6:4:7:8:0 #DESCRIPTION Hereford #SERVICE:2:7:4:1:0 #DESCRIPTION Holstein #SERVICE:6:4:2:9:0 #DESCRIPTION Piedmontese #SERVICE:3:6:3:1:0 #DESCRIPTION Scottish-Highland #SERVICE:4:4:9:3:0 #DESCRIPTION Shorthorn #SERVICE:4:8:1:6:0 #DESCRIPTION Angus #SERVICE:4:7:0:3:0: #DESCRIPTION Ayrshire #SERVICE:5:8:4:1:0 #DESCRIPTION Brown-Swiss #SERVICE:3:6:7:1:0 #DESCRIPTION Galloway #SERVICE:4:9:2:5:0 #DESCRIPTION Guernsey #SERVICE:6:4:7:8:0 #DESCRIPTION Hereford #SERVICE:2:7:4:1:0 #DESCRIPTION Holstein #SERVICE:6:4:2:9:0 #DESCRIPTION Piedmontese #SERVICE:3:6:3:1:0 #DESCRIPTION Scottish-Highland #SERVICE:4:4:9:3:0 #DESCRIPTION Shorthorn #SERVICE:4:8:1:6:0 #DESCRIPTION Angus #SERVICE:4:7:0:3:0: #DESCRIPTION Ayrshire #SERVICE:5:8:4:1:0 #DESCRIPTION Brown-Swiss #SERVICE:3:6:7:1:0 #DESCRIPTION Galloway #SERVICE:4:9:2:5:0 #DESCRIPTION Guernsey #SERVICE:6:4:7:8:0 #DESCRIPTION Hereford #SERVICE:2:7:4:1:0 #DESCRIPTION Holstein #SERVICE:6:4:2:9:0 #DESCRIPTION Piedmontese #SERVICE:3:6:3:1:0 #DESCRIPTION Scottish-Highland #SERVICE:4:4:9:3:0 #DESCRIPTION Shorthorn #SERVICE:4:8:1:6:0 #DESCRIPTION Angus #SERVICE:4:7:0:3:0: #DESCRIPTION Ayrshire #SERVICE:5:8:4:1:0 #DESCRIPTION Brown-Swiss #SERVICE:3:6:7:1:0 #DESCRIPTION Galloway #SERVICE:4:9:2:5:0 #DESCRIPTION Guernsey #SERVICE:6:4:7:8:0 #DESCRIPTION Hereford #SERVICE:2:7:4:1:0 #DESCRIPTION Holstein #SERVICE:6:4:2:9:0 #DESCRIPTION Piedmontese #SERVICE:3:6:3:1:0 #DESCRIPTION Scottish-Highland #SERVICE:4:4:9:3:0 #DESCRIPTION Shorthorn #SERVICE:4:8:1:6:0 #DESCRIPTION Angus #SERVICE:4:7:0:3:0: #DESCRIPTION Ayrshire #SERVICE:5:8:4:1:0 #DESCRIPTION Brown-Swiss #SERVICE:3:6:7:1:0 #DESCRIPTION Galloway #SERVICE:4:9:2:5:0 #DESCRIPTION Guernsey #SERVICE:6:4:7:8:0 #DESCRIPTION Hereford #SERVICE:2:7:4:1:0 #DESCRIPTION Holstein #SERVICE:6:4:2:9:0 #DESCRIPTION Piedmontese #SERVICE:3:6:3:1:0 #DESCRIPTION Scottish-Highland #SERVICE:4:4:9:3:0 #DESCRIPTION Shorthorn

    Now, just follow this road map :

    Select any string #SERVICE

    Run the Edit > Multi-select All > Match Case Only option

    => All strings #SERVICE should have been selected

    Use the Shift + End shortcut to extend the selection to the end of each line

    Use the Ctrl + X shortcut to delete these lines and place them in the clipboard

    Hit two times on the Down arrow key

    => Each cursor/caret should had been moved two lines under

    Use the Ctrl + V shortcut to recopy all #SERVICE lines to their new location

    Finally, hit the ESC key to clear the current multi-selection

    Voila !

    Best Regards,

    guy038

    P.S. :

    We could use the multi-selection of all #DESCRIPTION lines, either ! But, in that case, you need to :

    Add an empty line at the very beginning of your file

    Hit two times on the Up arrow key, right before the pasting operation

    P.P.S. :

    A similar regex S/R could be :

    FIND (?-s)^(.+\R)(.+(\R)?)

    REPLACE $2(?3:\r\n)$1

    Note that the conditional replacement (?3:\r\n) manages the case where your last #DESCRIPTION line would not end with a line-break !

  • Notepad++ VERY slow to open

    Help wanted · · · – – – · · ·
    16
    0 Votes
    16 Posts
    11k Views
    MarcosM

    Hello!

    I’m having a similar problem with NPP being slow to open, and I believe it’s related to the fact that I have several “draft” (unsaved) files saved, since I have the options enabled: backup and remember last session.
    This has already been reported in another post:

    https://github.com/notepad-plus-plus/notepad-plus-plus/issues/14000

    In my case, I have an SSD and it takes about 20 seconds to load about 200 files. So it spends about 0.1 seconds per file.

    I did some tests using Process Monitor, as shown in the image below.

    notepad.png

    In this case, it seems that NPP keeps trying to create files in the “Program Files” folder, but it gives a “NAME NOT FOUND” error.
    After that, it goes to the “AppData/Roaming…” folder where the backup files are located.

    In short, based on this result, does anyone have any idea how to try to solve this delay, perhaps caused by failures or repeated attempts to read/write the backup files?

  • 0 Votes
    4 Posts
    199 Views
    h-jangraH

    Thanks @Coises & @rdipardo
    I tried this and its working but still not better. You can suggest anything if I can add more styling.

    10f9d4ce-57f8-4d4c-a375-a9f4450b524e-image.png

    h-jangra/BetterMarkdown/releases/tag/0.1

  • New Vim modal editing plugin release

    General Discussion
    6
    1 Votes
    6 Posts
    4k Views
    h-jangraH

    @PeterJones @guy038 @W-H @Ava-Thompson and everyone

    Thanks a lot for checking out NppVim and for all the support. Really appreciate the feedback and the nice words.

    Quick updates:

    Repo here: https://github.com/h-jangra/NppVim I’m still actively working on the plugin, adding more motions, fixing bugs and making things feel closer to real Vim. More text objects, better repeat for t/f etc all in progress.

    I’m glad to hear interest in supporting the project. I’ll set up GitHub Sponsors soon and will update this thread.

    Thanks again for trying it out and giving feedback, it motivates me to keep improving it.
    Please feel free to open issues on GitHub for any bugs or features you want prioritized.

  • Mover abas

    General Discussion
    3
    0 Votes
    3 Posts
    248 Views
    Mark OlsonM

    I seem to recall that there was a bug in the main GitHub repo about this kind of issue, where it was extremely slow to move tabs when a lot of tabs were open.

    I also seem to recall that this issue was solved, probably in the last year. I’d recommend that @Wilson-Azambuja-Porto-Alegre-RS install the most recent Notepad++ version and see if that fixes the problem.

  • notepad++,exe- bad image

    Help wanted · · · – – – · · ·
    3
    0 Votes
    3 Posts
    211 Views
    pbarneyP

    @Alan, listen to @PeterJones when he says to scan your computer for viruses. TextShaping.dll is commonly used in DLL sideloading exploits, and if your executables are trying to call it when it resides in a place it doesn’t belong (your Notepad++ directory), then there’s a good chance your computer has been hacked.

    That doesn’t mean you should freak out just yet, just take some steps to ensure that you’re not hacked.

  • Update CLI command

    Help wanted · · · – – – · · ·
    4
    0 Votes
    4 Posts
    5k Views
    D

    All the gup.exe does is to check if there is a newer version than specified by the string input parameter is available. It does not handle the update itself. You would have to code it for yourself.

    For example like this in Powershell 5.1 for the 64bit version of Notepad++.

    [string]$ScriptFolder = $PSCommandPath | Split-Path -Parent $Notepad = Get-ItemProperty -LiteralPath 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Uninstall\Notepad++' $InstalledVersion = $Notepad.DisplayVersion $UpdateCheck = Invoke-WebRequest -Uri "https://notepad-plus-plus.org/update/getDownloadUrl.php?version=$InstalledVersion" $UpdateCheckAnswer = ([xml]$UpdateCheck.Content).GUP if ($UpdateCheckAnswer.NeedToBeUpdated -eq 'yes') { $Filename = $UpdateCheckAnswer.Location.Split('/')[-1] Invoke-WebRequest -Uri $UpdateCheckAnswer.Location -OutFile "$ScriptFolder\$Filename" & "$ScriptFolder\$Filename" '/S /closeRunningNpp' }
  • Notepad++ 8.8.8 release candidate

    Pinned Announcements
    1
    5 Votes
    1 Posts
    587 Views
    No one has replied
  • 0 Votes
    1 Posts
    108 Views
    No one has replied
  • using the command line switches, but not working

    General Discussion
    2
    0 Votes
    2 Posts
    95 Views
    PeterJonesP

    @Dan-McGovern ,

    -openFoldersAsWorkspace works just fine with -settingsDir and -titleAdd and other similar options, in my experiements.

    But, as far as I can tell, once -openFoldersAsWorkspace is specified anywhere on the command line, all path arguments are treated under the rule, “if it’s a folder, put it in the FolderAsWorkspace panel, and don’t open any file-paths directly”.

    That seems like the intent, because I don’t think it was considered that notepad++.exe myfile.txt -openFoldersAsWorkspace SomeDirectory\ would be a normal use-case (ie, when adding the feature, didn’t think that you’d want to open a file from one location, plus a folder-as-workspace from another, in the same command-line)

    If you don’t have the -multiInst argument, and if you don’t have the multi-instance preference set, then you could break it up into two calls of notepad++.exe

    "%np%" -settingsDir="..." -openFoldersAsWorkspace "%workspace%" "%np%" -settingsDir="..." "%file%"

    In that incantation, the oFAW has to come first, because of the known-and-never-solved issue that oFAW doesn’t work on an already-running instance of Notepad++.

    … But since I seem to remember that you do have the multi-instance preference set, that’s not likely to work for you. In which case, until you do a feature request, and it was accepted and implemented and released, I don’t know that you’ll get exactly what you want.

    I’ll update the manual to better explain current behavior with the oFAW option.

  • PHP Linter PythonScript

    General Discussion
    8
    0 Votes
    8 Posts
    461 Views
    PeterJonesP

    @pbarney said in PHP Linter PythonScript:

    my impression is that Pythonscript ships with 2.8

    From Plugins Admin, PythonScript v2.1.0 uses Python v2.7.18 (as far as I am aware, there is no such thing as Python v2.8).

    However, if you go to the PythonScript releases page, you will see that there is also an “alpha” track of PythonScript v3.0.x (currently at 3.0.24), which use Python v3.12.xx. This is the route I personally recommend (caveat below).

    The maintainer of PythonScript has chosen not to take PythonScript 3 out of “alpha” until it fully supports non-unicode encodings (ie, until it supports the 1980s-style character set encodings), so until that point, to get a maintained version of the Python interpreter for PythonScript, you have to manually install an alpha version of PythonScript – essentially, you have to put up with legacy syntax of Python if you want to deal with legacy non-unicode encodings of text. I personally have no need of supporting 80s technology for file encodings (and I pity anyone for whom their circumstances demand that they deal with file encodings that haven’t been brought into this millennium anytime in the last quarter century), so I use the 2020s version of Python for my PythonScript. (My personal opinion is that PythonScript should start shipping PythonScript 3 as non-alpha, and that they just prominently make it clear that if you have to deal with the old character sets that you should instead install the outdated PythonScript2 version from the releases page. But my opinion on such things holds no weight.)

  • 0 Votes
    3 Posts
    112 Views
    pbarneyP

    @Rick-Kosters, .docx files are compressed files, so unless you’re able to uncompress them first, you’ll never be able to use a third-party program to search them.

    For what it’s worth, 7-ZIP, Pkzip, WinZip, WinRAR, etc are all capable of opening those files. If you do unzip them, you’ll find a number of files and folders. What you’re looking for is most likely in word\document.xml.

  • Support for Plugins Admin & NppPluginList

    Notepad++ & Plugin Development
    74
    1 Votes
    74 Posts
    121k Views
    pbarneyP

    Would it be possible to add a column (or two) to the Plugins Admin? Created and Last Updated sortable columns to be able to find the most recent plugins.

    It would also be wonderful to have another column Description that just gives the first line of the longer description that is displayed in the lower box when you click on a plugin.

  • WebEdit Plugin for NPP x64 ?

    Help wanted · · · – – – · · ·
    9
    0 Votes
    9 Posts
    2k Views
    Richárd StockingerR

    Hi everyone!

    I have some good news and bad news.

    The good news is that I’ve finished WebEdit 2.9, which includes several new features: multi-select support, tag recommendations, quick tag addition/editing, and a few other minor upgrades.

    The bad news is that I’ve actually finished all the essential features I wanted to implement, so I’m not planning any further developments for the time being. Of course, you can still report bugs/issues and even make minor development suggestions, but the goal remains to keep the plugin fast, lightweight and easy to use.

    The overview of the (new) features is also available on the module’s main page: https://github.com/Krazal/WebEdit

    What’s next: when I have time, I’d like to return to my own plugin, because it has been full of bugs for months (not my fault!). ^^’

    Thank you for letting me contribute to this plugin, which I hope others will find just as great and useful as me!

  • FORUM: Posting Queue

    Pinned General Discussion
    10
    12 Votes
    10 Posts
    7k Views
    Ivy_PearsonI

    Thanks for the update, Peter. Totally understand the need for a posting queue—spam is getting tricky these days. Hopefully, it won’t take long to get posts approved once you earn reputation!

  • 8 Votes
    16 Posts
    1k Views
    CoisesC

    In case anyone is interested, I’ve created a version of this that runs as a Windows application rather than as a Notepad++ plugin, so it works in all applications:

    Compose for Windows

    This should be considered experimental. Since it works everywhere, not just in Notepad++, it has more potential to mess things up if I’ve missed something.

    Since it has no connection to Notepad++ (other than being a spin-off of the plugin described in the original topic message):

    The convenience features for editing a user definitions file which I added in response to @PeterJones’ notes aren’t included.

    Further discussion will be off-topic here. Please raise questions and concerns in the Issues for the project.

    The actions to create GitHub pages are, for some reason and at least temporarily, not working on this repository, which affects the normal presentation of the help file. However, you can still read the help file here (though some links appear to be garbled).

  • Using the Language Editor

    Help wanted · · · – – – · · ·
    4
    0 Votes
    4 Posts
    350 Views
    Lycan ThropeL

    @James-Burke-0 ,
    In addition to what @PeterJones has explained, the only other thing you could do, is bring up dBASEPlus in the Language->User Defined Language->Define your language...User language drop down box, and then `Save As’ and give it a new name.

    At that point, you can play with the settings, keywords, etc… all you want in your own named UDL. Because of the way the entire UDL ecosystem works, however, you’ll lose the ability to use the autoComplete file and the functionList file as well, because of their links to the UDL’s file names that those work with, as well as the overrideMap.xml linkage file, but you’d have JUST the UDL to adjust to your likings and then when you’re satisfied, you could go back to the original dBASEPlus UDL and put the changes that you want into the Dialog boxes for the language and then do as @PeterJones says, and just close and reopen the editor and your changes will be applied to the intalled dBASEPlus UDL definition.

    If you don’t need the Function List or Auto Complete capability, you can just use your newly named version of the dBASEPlus UDL to view and edit dBASE specific files.

    Just in case this is what you meant you wanted to do, to customize the dBASEPlus UDL without losing the original functionality of the original package. I hope this helps.

  • 0 Votes
    2 Posts
    87 Views
    PeterJonesP

    @Jerry-Scannell said in backward search doesn't work any longer:

    All of a sudden searching backwards through a file doesn’t work and I have to have proper case for strings I am searching. Does anyone know about this? Is it a setting that has changed for some reason? I am using version 8.7.5 if that helps.
    Thanks in advance,
    Paul

    That setting hasn’t changed since 2020 (v7.8.7).

    If you are in Regular Expression search mode, you cannot do backward search, unless you have followed the User Manual instructions (https://npp-user-manual.org/docs/preferences/#preferences-for-advanced-users) to set the regexBackward4PowerUser attribute in the xml config file, and restarted N++.

    But, as I said, this is nothing new. So a “sudden change” presumably was you choosing Regular Expression mode.

  • Markdown preview plugin

    Notepad++ & Plugin Development
    3
    0 Votes
    3 Posts
    150 Views
    PeterJonesP

    @notdodgeball said,

    If you are talking the MarkdownViewerPlusPlus plugin by nea, its indeed been dormant for many years, although I suspect it still works and you may have a problem on your end.

    I can confirm MarkdownViewer++ still works… in that I still semi-actively use it in Notepad++ v8.8.7-64bit (it’d been a few weeks since the last time, so in case I had misremembered and it was on v8.8.5 that I’d last used it, I double-checked today, and it can still display my Markdown)

    @Dragon-Red said,

    Do you plan to upgrade the DLL so that this plugin is usable again?

    In case you were curious, this Community Forum is the Community of Notepad++ users. Further, plugins are maintained by their respective authors or maintainers, not by the Notepad++ Developer, so even if you incorrectly thought this Community was the way to get in contact with the Notepad++ Developer, he’s not the right one to contact when you want an fix for a plugin. (And, as @notdodgeball told you, MarkdownViewer++ is effectively unmaintained at this point, unfortunately.)