Community
    • Login

    [New Plugin] MultiReplace

    Scheduled Pinned Locked Moved Notepad++ & Plugin Development
    80 Posts 12 Posters 84.0k Views 4 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Mit JeanM Offline
      Mit Jean
      last edited by

      A CTRL-Click on a tab would select it as part of a new scope for multi-documemt replacement.

      A new feature very useful when you want to apply search/replace to a list of open documents but not all open documents

      Alan KilbornA Thomas KnoefelT 2 Replies Last reply Reply Quote 0
      • Alan KilbornA Offline
        Alan Kilborn @Mit Jean
        last edited by

        @Mit-Jean said in [New Plugin] MultiReplace:

        A CTRL-Click on a tab would select it

        This is not something the MultiReplace plugin has the power to do, as the idea messes with core Notepad++ functionality.
        However, nothing is stopping the plugin author from creating some other mechanism within the plugin to do what you want.

        1 Reply Last reply Reply Quote 0
        • Thomas KnoefelT Offline
          Thomas Knoefel @Mit Jean
          last edited by

          @Mit-Jean
          A better solution would be to mark documents by pinning them. Unfortunately, Notepad++ does not provide an official API to detect whether a tab is pinned.

          Mark OlsonM 1 Reply Last reply Reply Quote 1
          • Mark OlsonM Offline
            Mark Olson @Thomas Knoefel
            last edited by

            @Thomas-Knoefel
            Your idea of a plugin interface to determine if a tab is pinned seems very reasonable, so I created this GitHub issue to ask for such a feature.

            Thomas KnoefelT 1 Reply Last reply Reply Quote 1
            • Thomas KnoefelT Offline
              Thomas Knoefel @Mark Olson
              last edited by Thomas Knoefel

              This post is deleted!
              1 Reply Last reply Reply Quote 0
              • Thomas KnoefelT Offline
                Thomas Knoefel @Thomas Knoefel
                last edited by Thomas Knoefel

                A new version of MultiReplace (v4.5.0.30) is ready and will be available with the next Notepad++ release. It can be dowloaded here.

                The focus of this release is on expanding the search functionality and giving you more flexibility.

                Implemented updates:

                • Find All: This is a new feature that lets you find all matches and see them in the search results window. It’s not limited to the current file – you can also search across all open documents or in entire folders.

                • GroupResults: To go with “Find All,” this new INI option lets you choose how your results are displayed. You can see them all mixed together in document order (the default), or neatly grouped by each list entry, which is great for getting a clear overview of complex searches.

                • lcmd: A new command for the “Use Variables” feature. It allows you to load your own custom helper functions from external files, which opens up a lot of possibilities for complex and reusable logic.

                • AllFromCursor: Another new INI setting that gives you more control. You can now choose to start “Find All”, “Replace All” and “Mark” operations from your current cursor position instead of from the top of the file.

                Here is a visual take on the changes:
                MultiReplace45.png

                Thomas KnoefelT 1 Reply Last reply Reply Quote 2
                • Thomas KnoefelT Offline
                  Thomas Knoefel @Thomas Knoefel
                  last edited by

                  A new version of MultiReplace (v5.0.0.35) is ready and will be available with the next Notepad++ release. For early testing, it can already be downloaded here.

                  The focus of this release is on a new Settings Panel, improved Search Results visualization, and overall usability enhancements.

                  Key Features & Improvements

                  • Settings Panel: A comprehensive configuration dialog replaces manual INI file editing. All options are now organized into clear categories: Search & Replace, List View, CSV Options, Export, and Appearance.
                  • Refined Toolbar Icon: The icon has been updated to improve clarity.
                  • List Search Bar: Press Ctrl+F while focused on the replacement list to open a search bar. Quickly find entries in large lists by searching through the ‘Find’ and ‘Replace’ columns.
                  • Search Results Window Enhancements:
                    • Color-coded matches (up to 28 colors) for easy visual distinction per list entry.
                    • Double-click the Matches count to jump directly to the results.
                  • Duplicate Line Detection: Identify and mark duplicate CSV rows. Delete or inspect duplicates with optional bookmark navigation.
                  • Binary Escape Sequence: Extended mode now supports \bNNNNNNNN for binary values.
                  • tonum() Function: New helper to convert strings to numbers, supporting both dot and comma as decimal separators.
                  • MATCH and CAP Variables: Now always return strings. Use tonum(CAP1) for calculations.
                  • Selection Mode: The ‘In Selection’ radio button no longer disables itself, enabling smoother repeated searches.
                  • Document Filtering for Open Docs: Find and Replace in Open Documents now supports wildcard-based filename filtering.
                  • Unified Filter Syntax: Filters now use semicolons (;) as separators in both ‘Open Documents’ and ‘Find in Files’ modes. This enables filtering for filenames containing spaces.
                  • Performance: Various optimizations for Replace All, Find All, and FlowTabs alignment on large files.

                  New Settings Panel with organized categories
                  17ec400c-8dde-4b03-94ec-c2f2a25bc600-image.png
                   
                  Double-click the Matches count to quickly navigate through results
                  ba478eec-321e-42f3-ad63-d2c9239eca42-image.png

                  Enjoy!

                  Thomas KnoefelT 1 Reply Last reply Reply Quote 4
                  • Thomas KnoefelT Offline
                    Thomas Knoefel @Thomas Knoefel
                    last edited by Thomas Knoefel

                    MultiReplace 6.0 is out and will land in Plugin Admin with the next Notepad++ release.

                    The focus of this release is a second formula engine: ExprTk now sits alongside Lua for math, string and conditional replacements, joined by multi-list tabs, tandem mode, and a series of UI and workflow improvements. Several new options live under Plugins > MultiReplace > Settings.

                    Download: Latest build

                    Key Features & Improvements

                    • New Formula Engine (ExprTk): A second engine alongside Lua for math, string and conditional replacements. Its standout is the built-in output formatter - a single declarative spec that turns any result into fixed decimals, hex/binary, padded and aligned fields, time durations or formatted dates, applied right where the value is produced. Switch per tab via the (L) / (E) indicator next to Formula Support. The ExprTk integration - the (?=...) marker and the formula functions for reading captures and earlier results - follows the approach pioneered by @Coises in Columns++. Full syntax and examples are in the ExprTk formula reference.
                    • List Tabs: Keep different replacement sets available across tabs. State is fully separate per tab.
                    • Tandem Mode: MR panel snaps to the Notepad++ window edge and follows it around. Toggle via the plugin menu.
                    • Reopen on Startup: Reopens MR automatically if it was open when you closed Notepad++. Opt-in via the plugin menu.
                    • Compact Toolbar: New top toolbar layout - more horizontal space for the list.
                    • Always Visible List: Keeps the list visible instead of collapsing when you toggle it off. Requires “Keep list always visible” enabled in Settings.
                    • Bookmark Matches: Sets a Notepad++ bookmark on every match line. Toggle via the new checkbox next to Mark Matches.
                    • Column Reorder & Lock: Drag column headers to rearrange. Right-click for “Lock column width” or “Reset Column Order”.
                    • Modified Timestamp Column: Optional column tracking the last edit per entry. A dirty-flag stripe on the left edge marks unsaved changes.
                    • Excel-Compatible CSV: Lists save in the standard CSV dialect used by spreadsheets - opens cleanly in Excel, edit there, load back without conversion.

                    Keyboard Shortcuts

                    • Ctrl+Up/Down: Move selected rows up or down (auto-repeat)
                    • Ctrl+L: Toggle list visibility from anywhere in the panel
                    • Alt+Up/Down: Round-trip between input fields and a selected row
                    • Ctrl+Shift + button click: Run from the input fields while the list stays open
                    • Ctrl+Shift+H: Pull selected editor text into Find what (optionally auto-escaped for Regex/Extended mode)

                    MultiReplace6.png


                    Issues or suggestions: GitHub.

                    Happy replacing!

                    1 Reply Last reply Reply Quote 3
                    • guy038G Online
                      guy038
                      last edited by guy038

                      Hello, @thomas-knoefel and All,

                      First, note that I use your last version 6.0.0.36 !

                      In this post, I did tests about the Search in Files feature with the three N++, Search and MultiReplace features.

                      Globaly, they all give the same results with tiny differences regarding the MultiReplace plugin, which will require a follow-up inspection


                      Now, in my last post to @coises, I did similar tests and this time, the MultiReplace plugin give completely different results, compared to native N++ and Search++ ! Indeed, I got :

                      • 27,081 matches in 841 files of 1,772, in 2m 10s, with Search++

                      • 27,081 matches in 841 files of 1,772, in 1m 21s, with N++

                      But only :

                      • 18,767 hits in 726 files in 1m 05s, with MultiReplace

                      As I said, in @coises’s post, I first suspected your File Search : Skip files larger than option, in Settings, to be enabled but it was not set !

                      Here is a screenshot of the MultiReplace dialog and of the Search Results panel :

                      fc011293-9c1f-48be-a5ad-22ff996790cb-image.jpeg

                      So, did I do something wrong ?


                      • I also did a test on an other USB key where I put a simple subset of 7 files, from my D: key, in a Test folder

                      • I moved, within a command prompt, to that Test folder

                      • I started N++ without a session and opened these 7 files only

                      • I first ran the Find in Files operation, with the Directory option = E:\Test and the Filter option = *.* => 83 hits in 3 files

                      • Then, I ran the similar Find in Docs operation => 372 hits in 7 files !

                      So, an obvious difference ! If necessary, I could send you the contents of this Test folder, for further tests !

                      Best Regards,

                      guy038

                      Thomas KnoefelT 1 Reply Last reply Reply Quote 0
                      • Thomas KnoefelT Offline
                        Thomas Knoefel @guy038
                        last edited by

                        @guy038
                        Hello @guy038,

                        Thanks for this thorough test, and no, you didn’t do anything wrong. Your investigation uncovered two separate behaviors in the code:

                        1. Binary Files: MultiReplace “Find in Files” currently skips binary files, while native N++ searches every file it lists. That accounts for most of the gap in your USB drive numbers. I’ll look at how to make this configurable and more transparent.
                        2. UTF-16 Bug: There is indeed a bug in how “Find in Files” handles UTF-16 encodings compared to “Find in Docs” and “Replace in Files”. This most likely explains the missing files in your smaller Test folder too.

                        Since the forum isn’t ideal for sharing files and tracking bug fixes, I have opened a GitHub issue for this here: https://github.com/daddel80/notepadpp-multireplace/issues/133
                        I would gladly take you up on your offer to share the E:\Test folder contents so I can verify the fix against them. Could you please attach that folder as a zip or provide a link in the GitHub issue?

                        Thanks again for your time and for helping to polish the next release candidate!

                        1 Reply Last reply Reply Quote 0

                        Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                        Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                        With your input, this post could be even better 💗

                        Register Login
                        • First post
                          Last post
                        The Community of users of the Notepad++ text editor.
                        Powered by NodeBB | Contributors