Git Product home page Git Product logo

daddel80 / notepadpp-multireplace Goto Github PK

View Code? Open in Web Editor NEW
13.0 2.0 4.0 40.07 MB

MultiReplace is a plugin for Notepad++ enabling multi-string replacement, allowing list saving and loading. It provides CSV syntax highlighting and enabling precise column targeting. Additionally, it introduces conditional and computational operations within the replacement string.

License: GNU General Public License v2.0

C 67.12% C++ 29.13% HTML 3.75%
find-and-replace notepad-plus-plus notepad-plusplus-plugin notepadplusplus replace-text string-replace column-filter delimited delimited-data filter-replacement

notepadpp-multireplace's Introduction

MultiReplace for Notepad++

License: GPL-2.0 Latest Stable Version Total Downloads

MultiReplace is a Notepad++ plugin that allows users to create, store, and manage search and replace strings within a list, proving useful across various sessions or projects. This enhancement increases efficiency when multiple replacements need to be made concurrently, thereby bolstering the overall functionality of Notepad++.

MultiReplace Screenshot

Table of Contents

Key Features

  • Multiple Replacements: Execute multiple replacements in a single operation, in one document or across all opened documents.
  • Entry Toggling: Toggle list entries for replacement, highlighting, or searching.
  • String Storage: Store and load your search and replace strings in a list, facilitating reuse across different sessions or projects.
  • CSV Scope Functionality: Target specific columns in a delimited file for search or replacement operations, offering precision in managing CSV data.
  • Scripted Text Replacements: Export to bash script for scripted text replacements.
  • Highlighting: Highlight multiple find words in unique colors for better visual distinction.
  • Variable Usage: Employ variables for conditional and computational operations within the replacement string.

Match and Replace Options

This chapter provides an overview of the various match and replace options available in MultiReplace, enhancing the flexibility and precision of your search and replace operations.

Match Whole Word Only: When this option is enabled, the search term is matched only if it appears as a whole word. This is particularly useful for avoiding partial matches within larger words, ensuring more precise and targeted search results.

Match Case: Selecting this option makes the search case-sensitive, meaning 'Hello' and 'hello' will be treated as distinct terms. It's useful for scenarios where the case of the letters is crucial to the search.

Use Variables: This feature allows the use of variables within the replacement string for dynamic and conditional replacements. For more detailed information, refer to the Option 'Use Variables' chapter.

Replace First Match Only: The "Replace First Match Only" option is ideal for Replace-All operations, where it replaces only the first occurrence of a match in each list entry. This is particularly useful for different replace strings with the same find pattern. It's designed for modifying only the initial match in a document or scope, while keeping other instances intact. The same effect can be achieved with the 'Use Variables' option using cond(CNT == 1, 'Replace String') for conditional replacements.

Wrap Around: When this option is active, the search will continue from the beginning of the document after reaching the end, ensuring that no potential matches are missed in the document.

Scope Functions

Scope functions define the range for searching and replacing strings:

  • Selection Option: Supports Rectangular and Multiselect to focus on specific areas for search or replace.
  • CSV Option: Enables targeted search or replacement within specified columns of a delimited file.
    • Cols: Specify the columns for focused operations.
    • Delim: Define the delimiter character.
    • Quote: Delineate areas where characters are not recognized as delimiters.

CSV Processing Functions

Sorting, Deleting, and Copying

  • Sorting Lines in CSV by Columns:Ascend or descend, combining columns in any prioritized order.
  • Toggle Sort: Allows users to return columns to their initial unsorted state with just an extra click on the sorting button. This feature is effective even after rows are modified, deleted, or added.
  • Deleting Multiple Columns: Remove multiple columns at once, cleaning obsolete delimiters.
  • Clipboard Column Copying: Copy columns with original delimiters to clipboard.

Header Line Sorting Control

  • Exclude Header Lines from Sorting: Set HeaderLines=<number> in %USERPROFILE%\AppData\Roaming\Notepad++\plugins\config\MultiReplace\MultiReplace.ini to specify the number of top lines to exclude from sorting as headers.

Numeric Sorting in CSV

  • For accurate numeric sorting in CSV files, the following settings and regex patterns can be used:
Purpose Find Pattern Replace With Regex Use Variables
Align Numbers with Leading Zeros (Decimal) \b(\d*)\.(\d{2}) set(string.rep("0",9-string.len(string.format("%.2f", CAP1)))..string.format("%.2f", CAP1)) Yes Yes
Align Numbers with Leading Zeros (Non-decimal) \b(\d+) set(string.rep("0",9-string.len(CAP1))..CAP1) Yes Yes
Remove Leading Zeros (Decimal) \b0+(\d*\.\d+) $1 Yes No
Remove Leading Zeros (Non-decimal) \b0+(\d*) $1 Yes No

Option 'Use Variables'

Activate the 'Use Variables' checkbox to employ variables associated with specified strings, allowing for conditional and computational operations within the replacement string. This Dynamic Substitution is compatible with all search settings of Search Mode, Scope, and the other options.

Note: Utilize either the set() or cond() command in 'Replace with:' to channel the output as the replacement string. Only one of these commands should be used at a time.

Variables Overview

Variable Description
CNT Count of the detected string.
LINE Line number where the string is found.
APOS Absolute character position in the document.
LPOS Relative line position.
LCNT Count of the detected string within the line.
COL Column number where the string was found (CSV-Scope option selected).
MATCH Contains the text of the detected string, in contrast to CAP variables which correspond to capture groups in regex patterns.
CAP1, CAP2, ... These variables are equivalents to regex capture groups, designed for use in the 'Use Variables' environment. Unlike their counterparts ($1, $2, ...), they are specifically suited for calculations and conditional operations within this environment.

Decimal Separator
When MATCH and CAP variables are used to read numerical values for further calculations, both dot (.) and comma (,) can serve as decimal separators. However, these variables do not support the use of thousands separators.

Command Overview

String Composition

.. is employed for concatenation.
E.g., "Detected "..CNT.." times."

set(strOrCalc)

Directly outputs strings or numbers, replacing the matched text in the Replace String with the specified or calculated value.

Example Result (assuming LINE = 5, CNT = 3)
set("replaceString"..CNT) "replaceString3"
set(LINE+5) "10"

cond(condition, trueVal, [falseVal])

Implements if-then-else logic, or if-then if falseVal is omitted. Evaluates the condition and pushes the corresponding value (trueVal or falseVal) to the Replace String.

Example Result (assuming LINE = 5)
cond(LINE<=5 or LINE>=9, "edge", "center") "edge"
cond(LINE<3, "Modify this line") (Original text remains unchanged)
cond(LINE<10, cond(LINE<5, cond(LINE>2, "3-4", "0-2"), "5-9"), "10+") "5-9" (Nested condition)

init({Variable1=Value1, Variable2=Value2, ...})

Initializes custom variables for use in various commands, extending beyond standard variables like CNT, MATCH, CAP1. These variables can carry the status of previous find-and-replace operations to subsequent ones.

Custom variables maintain their values throughout a single Replace-All or within the list of multiple Replace operations. So they can transfer values from one list entry to the following ones. They reset at the start of each new document in 'Replace All in All Open Documents'.

Find: Replace: Before After
(\d+) init({COL2=0,COL4=0}); cond(LCNT==4, COL2+COL4); if COL==2 then COL2=CAP1 end; if COL==4 then COL4=CAP1 end; 1,20,text,2,0
2,30,text,3,0
3,40,text,4,0
1,20,text,2,22.0
2,30,text,3,33.0
3,40,text,4,44.0
\d{2}-[A-Z]{3} init({MATCH_PREV=''}); cond(LCNT==1,'Moved', MATCH_PREV); MATCH_PREV=MATCH; 12-POV,00-PLC
65-SUB,00-PLC
43-VOL,00-PLC
Moved,12-POV
Moved,65-SUB
Moved,43-VOL

fmtN(num, maxDecimals, fixedDecimals)

Formats numbers based on precision (maxDecimals) and whether the number of decimals is fixed (fixedDecimals being true or false).

Note: The fmtN command can exclusively be used within the set and cond commands.

Example Result
set(fmtN(5.73652, 2, true)) "5.74"
set(fmtN(5.0, 2, true)) "5.00"
set(fmtN(5.73652, 4, false)) "5.7365"
set(fmtN(5.0, 4, false)) "5"

Operators

Type Operators
Arithmetic +, -, *, /, ^, %
Relational ==, ~=, <, >, <=, >=
Logical and, or, not

If-Then Logic

If-then logic is integral for dynamic replacements, allowing users to set custom variables based on specific conditions. This enhances the versatility of find-and-replace operations.

Note: Do not embed cond(), set(), or init() within if statements; if statements are exclusively for adjusting custom variables.

Syntax Combinations
  • if condition then ... end
  • if condition then ... else ... end
  • if condition then ... elseif another_condition then ... end
  • if condition then ... elseif another_condition then ... else ... end
Example

This example shows how to use if statements with cond() to manage variables based on conditions:

init({MVAR=""}); if CAP2~=nil then MVAR=MVAR..CAP2 end; cond(string.sub(CAP1,1,1)~="#", MVAR); if CAP2~=nil then MVAR=string.sub(CAP1,4,-1) end

More Examples

Find in: Replace with: Description/Expected Output Regex Scope CSV
; cond(LCNT==5,";Column5;") Adds a 5th Column for each line into a ; delimited file. No No
key set("key"..CNT) Enumerates key values by appending the count of detected strings. E.g., key1, key2, key3, etc. No No
(\d+) set("$1€ The VAT is: ".. (CAP1 * 0.15).."€ Total with VAT: ".. (CAP1 + (CAP1 * 0.15)).."€") Finds a number and calculates the VAT at 15%, then displays the original amount, the VAT, and the total amount. E.g., 50 becomes 50€ The VAT is: 7.5€ Total with VAT: 57.5€ Yes No
--- cond(COL==1 and LINE<3, "0-2", cond(COL==2 and LINE>2 and LINE<5, "3-4", cond(COL==3 and LINE>=5 and LINE<10, "5-9", cond(COL==4 and LINE>=10, "10+")))) Replaces --- with a specific range based on the COL and LINE values. E.g., 3-4 in column 2 of lines 3-4, and 5-9 in column 3 of lines 5-9 assuming --- is found in all lines and columns. No Yes
(\d+)\.(\d+)\.(\d+) cond(CAP1 > 0 and CAP2 == 0 and CAP3 == 0, MATCH, cond(CAP2 > 0 and CAP3 == 0, " " .. MATCH, " " .. MATCH)) Alters the spacing based on the hierarchy of the version numbers, aligning lower hierarchies with spaces as needed. E.g., 1.0.0 remains 1.0.0, 1.2.0 becomes 1.2.0, indicating a second-level version change. Yes No
(\d+) set(CAP1 * 2) Doubles the matched number. E.g., 100 becomes 200. Yes No
; cond(LCNT == 1, string.rep(" ", 20- (LPOS))..";") Inserts spaces before the semicolon to align it to the 20th character position if it's the first occurrence. No No
- cond(LINE == math.floor(10.5 + 6.25 * math.sin((2 * math.pi * LPOS) / 50)), "*", " ") Draws a sine wave across a canvas of '-' characters spanning at least 20 lines and 80 characters per line. No No
^(.*)$ init({MATCH_PREV=1}); cond(MATCH == MATCH_PREV, ''); MATCH_PREV=MATCH; Removes duplicate lines, keeping the first occurrence of each line. Matches an entire line and uses MATCH_PREV to identify and remove consecutive duplicates. Yes No

Engine Overview

MultiReplace uses the Lua engine, allowing for Lua math operations and string methods. Refer to Lua String Manipulation and Lua Mathematical Functions for more information.

User Interaction and List Management

Manage search and replace strings within the list using the context menu, which provides comprehensive functionalities accessible by right-clicking on an entry, using direct keyboard shortcuts, or mouse interactions. Here are the detailed actions available:

Context Menu and Keyboard Shortcuts

Right-click on any entry in the list or use the corresponding keyboard shortcuts to access these options:

Menu Item Shortcut Description
Transfer to Input Fields Alt+Up Transfers the selected entry to the input fields for editing.
Search in List Ctrl+F Initiates a search within the list entries. Inputs are entered in the "Find what" and "Replace with" fields.
Cut Ctrl+X Cuts the selected entry to the clipboard.
Copy Ctrl+C Copies the selected entry to the clipboard.
Paste Ctrl+V Pastes content from the clipboard into the list.
Edit Field Opens the selected entry for direct editing.
Delete Del Removes the selected entry from the list.
Select All Ctrl+A Selects all entries in the list.
Enable Alt+E Enables the selected entries, making them active for operations.
Disable Alt+D Disables the selected entries to prevent them from being included in operations.

Additional Interactions:

  • Space Key: Toggles the activation state of selected entries, similar to using Alt+E to enable or Alt+D to disable.
  • Double-Click: Mirrors the 'Transfer to Input Fields' action by transferring the contents of a row with their options to the input fields, equivalent to pressing Alt+Up.

List Columns

Column Description
W Watch whole word only
C Match case
V Use Variables
N Normal
E Extended
R Regular expression

List Toggling

  • "Use List" checkbox toggles operation application between all list entries or the "Find what:" and "Replace with:" fields.

Statistical Columns Button

  • Statistics Button: Located to the left of the list, this button when clicked, opens two new columns:
    • Find Count: Displays the number of times each 'Find what' string is detected.
    • Replace Count: Shows the number of replacements made for each 'Replace what' string.
  • Note: The values in 'Find Count' and 'Replace Count' can differ, especially when 'Use Variables' is employed to conditionally modify text.

Entry Interaction and Limits

  • Manage Entries: Manage search and replace strings in a list, and enable or disable entries for replacement, highlighting or searching within the list.
  • Highlighting: Highlight multiple find words in unique colors for better visual distinction, with over 20 distinct colors available.
  • Character Limit: Field limits of 4096 characters for "Find what:" and "Replace with:" fields.

Data Handling

Import/Export

  • Supports import/export of search and replace strings with their options in CSV format, including selection states.
  • Adherence to RFC 4180 standards for CSV, enabling compatibility and easy interaction with other CSV handling tools.
  • Enables reuse of search and replace operations across sessions and projects.

Bash Script Export

  • Exports Find and Replace strings into a runnable script, aiming to encapsulate the full functionality of the plugin in the script. However, due to differences in tooling, complete compatibility cannot be guaranteed.
  • This feature intentionally does not support the value \0 in the Extended Option to avoid escalating environment tooling requirements.

Multilingual UI Support

The MultiReplace plugin offers a multilingual UI, enabling navigation in various languages through adjustments in the languages.ini file within the plugin's configuration directory:

  • %APPDATA%\Notepad++\plugins\config\MultiReplace\languages.ini

This file enables users to select or customize the UI language settings, enhancing the accessibility and usability of the plugin for non-English speakers.

notepadpp-multireplace's People

Contributors

daddel80 avatar dependabot[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

notepadpp-multireplace's Issues

Make Escape key close smarter

If the dialog is just opened as a floating window, Escape key should - and currently does - close the floating dialog window. If however the dialog is docked to the Notepad++ window in one of the four (top, bottom, left, or right) docking spots, Escape key should not close the dialog; rather, it should set focus to the current Scintilla editing component. The thought is if the dialog is docked, the user may want to use it multiple times while swapping back and forth to navigate through the document.

Extra files from template

The files:

  • src/DockingFeature/GoToLineDlg.cpp
  • src/DockingFeature/GoToLineDlg.h
  • src/DockingFeature/goLine.rc

seem to be unnecessary cruft from the template plugin.

32-bit warning as error again

notepadpp-multireplace/src/MultiReplace.cpp:

677:     for (int i = 0; i < replaceListData.size(); i++) {

should be size_t

Build issue from command line

When using standard msbuild from command line, getting:

notepadpp-multireplace\src\AboutDialog.cpp(ROW,COL): error C2065: 'IDC_***': undeclared identifier

type errors. Due to missing:

#include "DockingFeature/resource.h"

in 'src\AboutDialog.cpp'.

Also, getting:

src\MultiReplace.h(20,10): fatal error C1083: Cannot open include file: 'resource.h': No such file or directory

due to incorrect include, should be:

#include "DockingFeature\resource.h"

Replace using Capture Variables

Trying to renumber the ini keys from #31 with new syntax:

Find what:

^(button|cmd|param|path|iconic|menu)\d*=

Replace with:

init({BTTNCNT=0}); if "$1" == "button" then BTTNCNT=BTTNCNT+1 end; set("$1"..BTTNCNT.."=")

But it does not seem to work.

The set always returns .0=.

Regexp rename with a counter

Is there a way?

I need to rename key names in an ini file:

[section1]
Buttoncount=2

button1=...
cmd1=...
menu1=...

button2=...
cmd2=...
menu2=...

I want to insert a button (block of keys) between 1 and 2 and call the replacer to rename all keys using the counter variable:

[section1]
Buttoncount=2

button1=...
cmd1=...
menu1=...

; inserted values
button=...
cmd=...
menu=...

button2=...
cmd2=...
menu2=...

Execution halted

Have the file:

# dest: "d:\blabla"
#> c:\myshortcuts1\|test1.txt.lnk
e:\blabla\|test1.txt
#> c:\myshortcuts2\|test2.txt.lnk
e:\blabla\|test2.txt

Want to replace to:

# dest: "d:\blabla"
#> c:\myshortcuts1\|test1.txt.lnk
c:\myshortcuts1\|test1.txt
#> c:\myshortcuts2\|test2.txt.lnk
c:\myshortcuts2\|test2.txt

The expression:

Selected,Find,Replace,WholeWord,MatchCase,UseVariables,Regex,Extended
1,"^([^\\r\\n\\|]+)(\\|([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+))?)?)?","init({DESTDIR=""""}); if CAP1 ~= nil and string.sub(CAP1,1,2) == ""#>"" then DESTDIR=string.sub(CAP1,4,-1) elseif CAP1 ~= nil and string.len(DESTDIR) and CAP2 ~= nil then set(DESTDIR..""|""..CAP2) end",0,0,1,0,1

Result:

---------------------------
Use Variables: Execution Error
---------------------------
Execution halted due to execution failure in:

init({DESTDIR=""}); if CAP1 ~= nil and string.sub(CAP1,1,2) == "#>" then DESTDIR=string.sub(CAP1,4,-1) elseif CAP1 ~= nil and string.len(DESTDIR) and CAP2 ~= nil then set(DESTDIR.."|"..CAP2) end
---------------------------
OK   
---------------------------

Can you help with the expression?

32-bit build failing due to sign mismatch warning and treat warnings as errors

When building the 32-bit version, I'm getting several warnings about sign mismatch in "src\MultiReplace.cpp":

notepadpp-multireplace\src\MultiReplace.cpp(448,42):  warning C4018: '>=': signed/unsigned mismatch [notepadpp-multireplace\vs.proj\NppMultiReplace.vcxproj]
notepadpp-multireplace\src\MultiReplace.cpp(467,42):  warning C4018: '>=': signed/unsigned mismatch [notepadpp-multireplace\vs.proj\NppMultiReplace.vcxproj]
notepadpp-multireplace\src\MultiReplace.cpp(502,129): warning C4389: '==': signed/unsigned mismatch [notepadpp-multireplace\vs.proj\NppMultiReplace.vcxproj]
notepadpp-multireplace\src\MultiReplace.cpp(1077,14): warning C4018: '<':  signed/unsigned mismatch [notepadpp-multireplace\vs.proj\NppMultiReplace.vcxproj]
notepadpp-multireplace\src\MultiReplace.cpp(1131,30): warning C4018: '>=': signed/unsigned mismatch [notepadpp-multireplace\vs.proj\NppMultiReplace.vcxproj]
notepadpp-multireplace\src\MultiReplace.cpp(1290,28): warning C4018: '<=': signed/unsigned mismatch [notepadpp-multireplace\vs.proj\NppMultiReplace.vcxproj]
notepadpp-multireplace\src\MultiReplace.cpp(1581,40): warning C4018: '<':  signed/unsigned mismatch [notepadpp-multireplace\vs.proj\NppMultiReplace.vcxproj]

The build fails since in "vs.proj\NppMultiReplace.vcxproj", the <TreatWarningAsError>true</TreatWarningAsError> is set in all the ItemDefinitionGroup's.

You could just set that to false for the 32-bit build configurations. Better would be to examine how / why the comparisons are between int and size_t (in most cases) and see if that could be fixed or just cast the size_t to int minding:

https://stackoverflow.com/questions/3642010/can-i-compare-int-with-size-t-directly-in-c

Cheers.

Ability to translate the plugin

Good afternoonю If it's possible and if it's not difficult, could you add the ability for everyone (me in particular) to translate your plugin into their native language? For example, how this is implemented in NotePad++: there is an XML file that can be edited and get the result that you need. I use your plugin to modify games, correct official localizations, and it’s just nice when all the space around you is in your native language :)

Thank you!

Parentheses incorrect replacement in regexp expression

File:

c:\dir1\|aaa (bbb) ccc
#> d:\dirA\ddd
c:\dirB\|aaa (bbb) ccc
#> d:\dirC\ddd
c:\dirD\|bbb) ccc

Want to replace to:

c:\dir1\|aaa (bbb) ccc
#> d:\dirA\ddd
d:\dirA\|aaa (bbb) ccc
#> d:\dirC\ddd
d:\dirC\|bbb) ccc

The expression:

Selected,Find,Replace,WholeWord,MatchCase,UseVariables,Regex,Extended
1,"^([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+))?)?)?","init({DESTDIR="""",REPLACETO=""""}); if CAP1 ~= nil and string.sub(CAP1,1,3) == ""#> "" then DESTDIR=string.match(string.sub(CAP1,4,-1),""^(.+)\\\\"") elseif CAP1 ~= nil and string.sub(CAP1,1,1) ~= ""#"" and string.len(DESTDIR) and CAP2 ~= nil then REPLACETO=DESTDIR..""\\\\|""..CAP2 end; cond(CAP1 ~= nil and CAP2 ~= nil and string.len(CAP1) and string.len(CAP2) and string.sub(CAP1,1,1) ~= ""#"" and string.len(REPLACETO), REPLACETO)",0,0,1,0,1

Result:

|aaa bbb ccc
#> d:\dirA\ddd
d:\dirA\|aaa bbb ccc
#> d:\dirC\ddd
d:\dirC\|bbb

Additionally, the first line should not be replaced, because REPLACETO is empty, but anyway it does replacement.

Dots incorrect replacement in regexp expressions

File:

# dest: "d:\blabla"
#> c:\test1\test1.aaa|test1.txt.lnk
e:\blabla\|test1.txt
#> c:\test2\test2.bbb|test2.txt.lnk
e:\blabla\|test2.txt

Want to replace to:

# dest: "d:\blabla"
#> c:\test1\test1.aaa|test1.txt.lnk
c:\test1\test1.aaa|test1.txt
#> c:\test2\test2.bbb|test2.txt.lnk
c:\test2\test2.bbb|test2.txt

The expression:

1,"^([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+)(?:\\|([^\\r\\n\\|]+))?)?)?","init({DESTDIR="""",REPLACETO=""""}); if CAP1 ~= nil and string.sub(CAP1,1,3) == ""#> "" then DESTDIR=string.match(string.sub(CAP1,4,-1),""^(.+)\\\\"") elseif CAP1 ~= nil and string.sub(CAP1,1,1) ~= ""#"" and string.len(DESTDIR) > 0 and CAP2 ~= nil then REPLACETO=DESTDIR..""\\\\|""..CAP2 end; cond(CAP1 ~= nil and CAP2 ~= nil and string.len(CAP1) > 0 and string.len(CAP2) > 0 and string.sub(CAP1,1,1) ~= ""#"" and string.len(REPLACETO) > 0, REPLACETO)",0,0,1,0,1

Result:

# dest: "d:\blabla"
#> c:\test1\test1.aaa|test1.txt.lnk
c:\test1\test1|test1.txt
#> c:\test2\test2.bbb|test2.txt.lnk
c:\test2\test2|test2.txt

32-bit build warning as error signed mismatch (again)

Some new updates have reintroduced an old warning as error again:

notepadpp-multireplace\src\MultiReplace.cpp(2143,23): warning C4018: '<': signed/unsigned mismatch

notepadpp-multireplace\src\MultiReplace.cpp(2143,23): error C2220: the following warning is treated as an error 

Due to line:

    for (int i = 0; i < replaceListData.size(); i++) {

Guessing replaceListData.size() is of size_t.

Cheers.

Wrong dlgID in multiReplace()

The member dlgID should:

        // the dlgDlg should be the index of funcItem where the current function pointer is
        // in this case is DOCKABLE_DEMO_INDEX

That is 0 from:

notepadpp-multireplace/src/PluginDefinition.cpp:

71:     setCommand(0, TEXT("&Multi Replace && Mark"), multiReplace, NULL, false);
72:     setCommand(1, TEXT("&About"), about, NULL, false);

however, it is set to 3.

all open documents

Is there a way to do a search and replace on all open documents? You can do this with the built-in function. Thanks!

Version is misreported

See:

PS VinsWorldcom C:\usr\bin\npp64\plugins\NppMultiReplace > (Get-Item .\NppMultiReplace.dll).VersionInfo

ProductVersion   FileVersion      FileName
--------------   -----------      --------
4.3              4.3              C:\usr\bin\npp64\plugins\NppMultiReplace\NppMult...

Coming from:

#define VERSION_VALUE "4.3\0"

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.