Merge pull request #3834 from RaiKoHoff/Dev_LongPath

Update grepWin current version v2.0.9 -> grepWinNP3 v2.1.9
This commit is contained in:
Rainer Kottenhoff 2021-11-30 14:02:51 +01:00 committed by GitHub
commit d72d30431c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
26 changed files with 253 additions and 473 deletions

View File

@ -2,9 +2,10 @@
Language: Cpp
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: true
AlignConsecutiveDeclarations: true
AlignConsecutiveMacros: true
AlignConsecutiveAssignments: AcrossEmptyLinesAndComments
AlignConsecutiveBitFields: AcrossEmptyLinesAndComments
AlignConsecutiveDeclarations: AcrossEmptyLinesAndComments
AlignConsecutiveMacros: AcrossEmptyLinesAndComments
AlignEscapedNewlines: Right
AlignOperands: true
AlignTrailingComments: true

View File

@ -391,6 +391,7 @@
<ClCompile Include="sktoolslib_mod\FileDropTarget.cpp" />
<ClCompile Include="sktoolslib_mod\Hash.cpp" />
<ClCompile Include="sktoolslib_mod\hyperlink.cpp" />
<ClCompile Include="sktoolslib_mod\InfoRtfDialog.cpp" />
<ClCompile Include="sktoolslib_mod\Language.cpp" />
<ClCompile Include="sktoolslib_mod\Monitor.cpp" />
<ClCompile Include="sktoolslib_mod\PathUtils.cpp" />
@ -407,7 +408,6 @@
<ClCompile Include="src\Bookmarks.cpp" />
<ClCompile Include="src\BookmarksDlg.cpp" />
<ClCompile Include="src\grepWin.cpp" />
<ClCompile Include="src\InfoDlg.cpp" />
<ClCompile Include="src\MultiLineEditDlg.cpp" />
<ClCompile Include="src\NameDlg.cpp" />
<ClCompile Include="src\RegexReplaceFormatter.cpp" />
@ -438,6 +438,7 @@
<ClInclude Include="sktoolslib_mod\FileDropTarget.h" />
<ClInclude Include="sktoolslib_mod\Hash.h" />
<ClInclude Include="sktoolslib_mod\hyperlink.h" />
<ClInclude Include="sktoolslib_mod\InfoRtfDialog.h" />
<ClInclude Include="sktoolslib_mod\Language.h" />
<ClInclude Include="sktoolslib_mod\maxpath.h" />
<ClInclude Include="sktoolslib_mod\Monitor.h" />
@ -457,7 +458,6 @@
<ClInclude Include="src\Bookmarks.h" />
<ClInclude Include="src\BookmarksDlg.h" />
<ClInclude Include="src\COMPtrs.h" />
<ClInclude Include="src\InfoDlg.h" />
<ClInclude Include="src\last\version.h" />
<ClInclude Include="src\LineData.h" />
<ClInclude Include="src\MultiLineEditDlg.h" />

View File

@ -39,9 +39,6 @@
<ClCompile Include="src\grepWin.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="src\InfoDlg.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="src\NameDlg.cpp">
<Filter>Source Files</Filter>
</ClCompile>
@ -156,6 +153,9 @@
<ClCompile Include="sktoolslib_mod\AeroGlass.cpp">
<Filter>sktoolslib_mod</Filter>
</ClCompile>
<ClCompile Include="sktoolslib_mod\InfoRtfDialog.cpp">
<Filter>sktoolslib_mod</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="src\AboutDlg.h">
@ -167,9 +167,6 @@
<ClInclude Include="src\BookmarksDlg.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="src\InfoDlg.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="src\NameDlg.h">
<Filter>Header Files</Filter>
</ClInclude>
@ -308,6 +305,9 @@
<ClInclude Include="sktoolslib_mod\AeroGlass.h">
<Filter>sktoolslib_mod</Filter>
</ClInclude>
<ClInclude Include="sktoolslib_mod\InfoRtfDialog.h">
<Filter>sktoolslib_mod</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<None Include="default.build">

View File

@ -2,9 +2,10 @@
Language: Cpp
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: true
AlignConsecutiveDeclarations: true
AlignConsecutiveMacros: true
AlignConsecutiveAssignments: AcrossEmptyLinesAndComments
AlignConsecutiveBitFields: AcrossEmptyLinesAndComments
AlignConsecutiveDeclarations: AcrossEmptyLinesAndComments
AlignConsecutiveMacros: AcrossEmptyLinesAndComments
AlignEscapedNewlines: Right
AlignOperands: true
AlignTrailingComments: true

View File

@ -43,6 +43,8 @@ CCircularLog& CCircularLog::Instance()
bool CCircularLog::Init(const std::wstring& path, int maxlines)
{
std::unique_lock<std::mutex> lock(m_mutex);
m_path = path;
m_maxLines = maxlines;
@ -74,7 +76,8 @@ bool CCircularLog::Init(const std::wstring& path, int maxlines)
bool CCircularLog::AddLine(const std::wstring& line)
{
wchar_t tmpBuf1[128] = {0};
std::unique_lock<std::mutex> lock(m_mutex);
wchar_t tmpBuf1[128] = {0};
_wstrtime_s(tmpBuf1, 128);
wchar_t tmpBuf2[128] = {0};
_wstrdate_s(tmpBuf2, 128);
@ -87,6 +90,7 @@ bool CCircularLog::AddLine(const std::wstring& line)
bool CCircularLog::Save()
{
std::unique_lock<std::mutex> lock(m_mutex);
if (m_path.empty())
return false;
try

View File

@ -18,6 +18,7 @@
//
#pragma once
#include <list>
#include <mutex>
#include <string>
class CCircularLog
@ -41,4 +42,5 @@ private:
std::list<std::wstring> m_lines;
std::wstring m_path;
int m_maxLines;
std::mutex m_mutex;
};

View File

@ -107,7 +107,6 @@ private:
using RefreshImmersiveColorPolicyStateFn = void(WINAPI* )();
using GetIsImmersiveColorUsingHighContrastFn = BOOL(WINAPI* )(IMMERSIVE_HC_CACHE_MODE mode);
using FlushMenuThemesFn = void(WINAPI* )();
using OpenNcThemeDataFpn = HTHEME(WINAPI* )(HWND hWnd, LPCWSTR pszClassList);
using SetWindowCompositionAttributeFpn = BOOL(WINAPI* )(HWND hwnd, WINDOWCOMPOSITIONATTRIBDATA* data);
AllowDarkModeForAppFpn m_pAllowDarkModeForApp = nullptr;

View File

@ -1,4 +1,4 @@
// sktoolslib - common files for SK tools
// sktoolslib - common files for SK tools
// Copyright (C) 2014, 2017, 2020-2021 - Stefan Kueng
@ -28,7 +28,7 @@ CDownloadFile::CDownloadFile(LPCWSTR useragent, CProgressDlg* pProgress)
hOpenHandle = InternetOpen(useragent, INTERNET_OPEN_TYPE_PRECONFIG, nullptr, nullptr, 0);
}
CDownloadFile::~CDownloadFile(void)
CDownloadFile::~CDownloadFile()
{
if (hOpenHandle)
InternetCloseHandle(hOpenHandle);

View File

@ -1,6 +1,6 @@
// sktoolslib - common files for SK tools
// Copyright (C) 2014, 2020 - Stefan Kueng
// Copyright (C) 2014, 2020-2021 - Stefan Kueng
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
@ -26,7 +26,7 @@ class CDownloadFile
{
public:
CDownloadFile(LPCWSTR useragent, CProgressDlg* pProgress);
~CDownloadFile(void);
~CDownloadFile();
bool DownloadFile(const std::wstring& url, const std::wstring& dest) const;

View File

@ -1,4 +1,4 @@
// sktoolslib - common files for SK tools
// sktoolslib - common files for SK tools
// Copyright (C) 2020-2021 - Stefan Kueng
@ -20,6 +20,9 @@
#include "InfoRtfDialog.h"
#include "OnOutOfScope.h"
#include <richedit.h>
#include <shellapi.h>
#pragma comment(lib, "Shell32.lib")
CInfoRtfDialog::CInfoRtfDialog()
: m_hParent(nullptr)
@ -138,6 +141,7 @@ LRESULT CInfoRtfDialog::DlgFunc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l
SetFocus(m_hwndRichEdit);
SendMessage(m_hwndRichEdit, EM_SETSEL, static_cast<WPARAM>(-1), static_cast<LPARAM>(0));
SendMessage(m_hwndRichEdit, EM_SETREADONLY, static_cast<WPARAM>(1), reinterpret_cast<LPARAM>(nullptr));
SendMessage(m_hwndRichEdit, EM_SETEVENTMASK, NULL, ENM_LINK | ENM_SCROLL);
}
}
}
@ -151,17 +155,56 @@ LRESULT CInfoRtfDialog::DlgFunc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l
MoveWindow(m_hwndRichEdit, 0, 0, width, height, TRUE);
}
break;
case WM_DESTROY:
CloseWindow(m_hwndRichEdit);
DestroyWindow(m_hwndRichEdit);
break;
case WM_COMMAND:
switch (LOWORD(wParam))
{
case IDOK:
case IDCANCEL:
CloseWindow(m_hwndRichEdit);
DestroyWindow(m_hwndRichEdit);
EndDialog(*this, LOWORD(wParam));
return static_cast<INT_PTR>(TRUE);
default:
break;
}
break;
case WM_NOTIFY:
{
auto pHdr = reinterpret_cast<LPNMHDR>(lParam);
if (pHdr)
{
if (pHdr->hwndFrom == m_hwndRichEdit)
{
switch (pHdr->code)
{
case EN_LINK:
{
auto pEnLink = reinterpret_cast<ENLINK*>(lParam);
if ((pEnLink->msg != WM_LBUTTONUP) && (pEnLink->msg != WM_SETCURSOR))
break;
auto buffer = std::make_unique<wchar_t[]>(pEnLink->chrg.cpMax - pEnLink->chrg.cpMin + 1);
TEXTRANGE range{};
range.chrg = pEnLink->chrg;
range.lpstrText = buffer.get();
SendMessage(m_hwndRichEdit, EM_GETTEXTRANGE, 0, reinterpret_cast<LPARAM>(&range));
auto url = std::wstring(buffer.get(), pEnLink->chrg.cpMax - pEnLink->chrg.cpMin);
if (!url.empty())
{
if (pEnLink->msg == WM_SETCURSOR)
SetCursor(LoadCursor(nullptr, IDC_HAND));
else
ShellExecute(hwndDlg, L"open", url.c_str(), nullptr, nullptr, SW_SHOWDEFAULT);
}
}
break;
}
}
}
}
break;
}
return static_cast<INT_PTR>(FALSE);
}
}

View File

@ -1,4 +1,4 @@
// sktoolslib - common files for SK tools
// sktoolslib - common files for SK tools
// Copyright (C) 2013, 2017, 2020-2021 - Stefan Kueng
@ -20,11 +20,11 @@
#include "IniSettings.h"
#include "StringUtils.h"
CIniSettings::CIniSettings(void)
CIniSettings::CIniSettings()
{
}
CIniSettings::~CIniSettings(void)
CIniSettings::~CIniSettings()
{
Save();
}

View File

@ -1,4 +1,4 @@
// sktoolslib - common files for SK tools
// sktoolslib - common files for SK tools
// Copyright (C) 2013, 2020-2021 - Stefan Kueng
@ -22,8 +22,8 @@
class CIniSettings
{
private:
CIniSettings(void);
~CIniSettings(void);
CIniSettings();
~CIniSettings();
public:
static CIniSettings& Instance();

View File

@ -1,4 +1,4 @@
// sktoolslib - common files for SK tools
// sktoolslib - common files for SK tools
// Copyright (C) 2012, 2017-2018, 2020-2021 - Stefan Kueng
@ -94,7 +94,7 @@ public:
/// used in subclass templates to specify the correct string type
using StringT = S;
typedef S StringT;
protected:
//members
@ -315,7 +315,7 @@ public:
* Make the value type accessible to others.
*/
using ValueT = T;
typedef T ValueT;
/**
* Constructor.
@ -1060,8 +1060,8 @@ typedef CKeyList<CRegString> CRegStringList;
# endif
#endif
using CRegStdDWORD = CRegDWORDCommon<CRegStdBase>;
using CRegStdString = CRegStringCommon<CRegStdBase>;
typedef CRegDWORDCommon<CRegStdBase> CRegStdDWORD;
typedef CRegStringCommon<CRegStdBase> CRegStdString;
#ifdef _MAP_
typedef CKeyList<CRegStdDWORD> CRegStdDWORDList;

View File

@ -1,4 +1,4 @@
// sktoolslib - common files for SK tools
// sktoolslib - common files for SK tools
// Copyright (C) 2012-2017, 2019-2021 - Stefan Kueng
@ -186,7 +186,7 @@ static constexpr BYTE DecLookup[] = {
std::string CStringUtils::ToHexString(BYTE* pSrc, int nSrcLen)
{
WORD* pwHex = reinterpret_cast<WORD*>(const_cast<BYTE*>(HexLookup));
auto dest = std::make_unique<char[]>((nSrcLen * 2) + 1);
auto dest = std::make_unique<char[]>((nSrcLen * 2LL) + 1LL);
WORD* pwDest = reinterpret_cast<WORD*>(dest.get());
for (int j = 0; j < nSrcLen; j++)
{
@ -226,7 +226,7 @@ std::unique_ptr<char[]> CStringUtils::Decrypt(const char* text)
if (CryptStringToBinaryA(text, static_cast<DWORD>(strlen(text)), CRYPT_STRING_HEX, nullptr, &dwLen, nullptr, nullptr) == FALSE)
return nullptr;
auto strIn = std::make_unique<BYTE[]>(dwLen + 1);
auto strIn = std::make_unique<BYTE[]>(dwLen + 1LL);
if (CryptStringToBinaryA(text, static_cast<DWORD>(strlen(text)), CRYPT_STRING_HEX, strIn.get(), &dwLen, nullptr, nullptr) == FALSE)
return nullptr;
@ -239,8 +239,8 @@ std::unique_ptr<char[]> CStringUtils::Decrypt(const char* text)
return nullptr;
SecureZeroMemory(blobIn.pbData, blobIn.cbData);
auto result = std::make_unique<char[]>(blobOut.cbData + 1);
strncpy_s(result.get(), blobOut.cbData + 1, reinterpret_cast<const char*>(blobOut.pbData), blobOut.cbData);
auto result = std::make_unique<char[]>(blobOut.cbData + 1LL);
strncpy_s(result.get(), blobOut.cbData + 1LL, reinterpret_cast<const char*>(blobOut.pbData), blobOut.cbData);
SecureZeroMemory(blobOut.pbData, blobOut.cbData);
LocalFree(blobOut.pbData);
LocalFree(descr);
@ -253,7 +253,7 @@ std::unique_ptr<wchar_t[]> CStringUtils::Decrypt(const wchar_t* text)
if (CryptStringToBinaryW(text, static_cast<DWORD>(wcslen(text)), CRYPT_STRING_HEX, nullptr, &dwLen, nullptr, nullptr) == FALSE)
return nullptr;
auto strIn = std::make_unique<BYTE[]>(dwLen + 1);
auto strIn = std::make_unique<BYTE[]>(dwLen + 1LL);
if (CryptStringToBinaryW(text, static_cast<DWORD>(wcslen(text)), CRYPT_STRING_HEX, strIn.get(), &dwLen, nullptr, nullptr) == FALSE)
return nullptr;
@ -287,7 +287,7 @@ std::string CStringUtils::Encrypt(const char* text)
DWORD dwLen = 0;
if (CryptBinaryToStringA(blobout.pbData, blobout.cbData, CRYPT_STRING_HEX | CRYPT_STRING_NOCRLF, nullptr, &dwLen) == FALSE)
return result;
auto strOut = std::make_unique<char[]>(dwLen + 1);
auto strOut = std::make_unique<char[]>(dwLen + 1LL);
if (CryptBinaryToStringA(blobout.pbData, blobout.cbData, CRYPT_STRING_HEX | CRYPT_STRING_NOCRLF, strOut.get(), &dwLen) == FALSE)
return result;
LocalFree(blobout.pbData);
@ -310,7 +310,7 @@ std::wstring CStringUtils::Encrypt(const wchar_t* text)
DWORD dwLen = 0;
if (CryptBinaryToStringW(blobOut.pbData, blobOut.cbData, CRYPT_STRING_HEX | CRYPT_STRING_NOCRLF, nullptr, &dwLen) == FALSE)
return result;
auto strOut = std::make_unique<wchar_t[]>(dwLen + 1);
auto strOut = std::make_unique<wchar_t[]>(dwLen + 1LL);
if (CryptBinaryToStringW(blobOut.pbData, blobOut.cbData, CRYPT_STRING_HEX | CRYPT_STRING_NOCRLF, strOut.get(), &dwLen) == FALSE)
return result;
LocalFree(blobOut.pbData);
@ -333,7 +333,7 @@ std::wstring CStringUtils::Format(const wchar_t* frmt, ...)
auto len = _vscwprintf(frmt, marker);
if (len > 0)
{
buffer.resize(len + 1);
buffer.resize(len + 1LL);
_vsnwprintf_s(&buffer[0], buffer.size(), len, frmt, marker);
buffer.resize(len);
}
@ -356,7 +356,7 @@ std::string CStringUtils::Format(const char* frmt, ...)
auto len = _vscprintf(frmt, marker);
if (len > 0)
{
buffer.resize(len + 1);
buffer.resize(len + 1LL);
_vsnprintf_s(&buffer[0], buffer.size(), len, frmt, marker);
buffer.resize(len);
}
@ -383,18 +383,16 @@ bool WriteAsciiStringToClipboard(const wchar_t* sClipdata, HWND hOwningWnd)
CloseClipboard(););
EmptyClipboard();
size_t sLen = wcslen(sClipdata);
HGLOBAL hClipboardData = GlobalAlloc(GMEM_DDESHARE, (sLen + 1) * sizeof(wchar_t));
HGLOBAL hClipboardData = GlobalAlloc(GMEM_MOVEABLE, (sLen + 1) * sizeof(wchar_t));
if (hClipboardData)
{
wchar_t* pchData = static_cast<wchar_t*>(GlobalLock(hClipboardData));
if (pchData)
{
wcscpy_s(pchData, sLen + 1, sClipdata);
if (GlobalUnlock(hClipboardData))
{
if (SetClipboardData(CF_UNICODETEXT, hClipboardData) == nullptr)
return true;
}
GlobalUnlock(hClipboardData);
if (SetClipboardData(CF_UNICODETEXT, hClipboardData) == nullptr)
return true;
}
}
}

View File

@ -1,79 +0,0 @@
// grepWin - regex search and replace for Windows
// Copyright (C) 2007-2009, 2011-2014, 2020-2021 - Stefan Kueng
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software Foundation,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
//
#include "stdafx.h"
#include "InfoDlg.h"
#include "StringUtils.h"
#include "DPIAware.h"
#include "maxpath.h"
#include <memory>
#include <mshtmhst.h>
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
CInfoDlg::CInfoDlg()
{
}
CInfoDlg::~CInfoDlg()
{
}
//Function which takes input of An HTML Resource Id
BOOL CInfoDlg::ShowDialog(HWND hParent, UINT idAboutHtmlid, HINSTANCE hInstance)
{
//Load the IE Specific MSTML Interface DKK
HINSTANCE hinstMshtml = LoadLibrary(TEXT("mshtml.dll"));
BOOL bSuccess = FALSE;
if (hinstMshtml)
{
//Locate The Function ShowHTMLDialog in the Loaded mshtml.dll
SHOWHTMLDIALOGEXFN* pfnShowHTMLDialog = reinterpret_cast<SHOWHTMLDIALOGEXFN*>(GetProcAddress(hinstMshtml, "ShowHTMLDialogEx"));
if (pfnShowHTMLDialog)
{
auto lpszModule = std::make_unique<wchar_t[]>(MAX_PATH_NEW);
//Get The Application Path
if (GetModuleFileName(hInstance, lpszModule.get(), MAX_PATH_NEW))
{
//Add the IE Res protocol
auto strResourceURL = std::make_unique<wchar_t[]>(MAX_PATH_NEW);
swprintf_s(strResourceURL.get(), MAX_PATH_NEW, L"res://%s/%u", lpszModule.get(), idAboutHtmlid);
auto iLength = wcslen(strResourceURL.get());
auto lpWideCharStr = std::make_unique<wchar_t[]>(iLength + 1);
//Attempt to Create the URL Moniker to the specified in the URL String
IMoniker* pmk;
if (SUCCEEDED(CreateURLMoniker(NULL, strResourceURL.get(), &pmk)))
{
//Invoke the ShowHTMLDialog function by pointer
//passing the HWND of your Application , the Moniker,
//the remaining parameters can be set to NULL
auto opts = CStringUtils::Format(L"dialogHeight:%dpx; dialogWidth:%dpx; resizable:yes",
CDPIAware::Instance().Scale(hParent, 600),
CDPIAware::Instance().Scale(hParent, 480));
pfnShowHTMLDialog(nullptr, pmk, HTMLDLG_MODELESS, nullptr, opts.data(), nullptr);
bSuccess = TRUE;
}
}
}
FreeLibrary(hinstMshtml);
}
return bSuccess;
}

View File

@ -1,29 +0,0 @@
// grepWin - regex search and replace for Windows
// Copyright (C) 2007-2008, 2020-2021 - Stefan Kueng
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software Foundation,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
//
#pragma once
class CInfoDlg
{
public:
CInfoDlg();
virtual ~CInfoDlg();
public:
static BOOL ShowDialog(HWND hParent, UINT idAboutHtmlid, HINSTANCE hInstance);
};

Binary file not shown.

View File

@ -323,10 +323,10 @@ END
/////////////////////////////////////////////////////////////////////////////
//
// HTML
// RTF
//
IDR_INFODLG HTML "infodlg.htm"
IDR_INFODLG RTF "infodlg.rtf"
/////////////////////////////////////////////////////////////////////////////

View File

@ -1,290 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="iso-8859-1">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Regex Help</title>
<style>
html {
width: 400px
}
body {
font: 80% "Lucida Grande", Verdana, Arial, Sans-Serif
}
code {
font-family: monospace, serif;
font-size: 1em
}
h1 {
font-size: 1.4em;
margin: 8px auto 4px
}
table,
th,
td {
border-collapse: collapse;
border: 1px solid black;
padding: 8px;
}
.style1 {
width: 188px
}
.style2 {
width: 188px;
height: 26px
}
.style3 {
width: 188px;
height: 17px
}
.style4 {
width: 360px;
height: 17px
}
.style5 {
width: 360px;
height: 26px
}
.td-left {
text-align: left
}
.td-right {
text-align: right
}
</style>
</head>
<body>
<p>This help file shows only the basics of a regular expression search, and
it's here only to show the flavor of the used regex.</p>
<p>If you're not familiar with regular expressions, please consult
a tutorial like <a href="https://www.regular-expressions.info/tutorial.html"
target="_blank">https://www.regular-expressions.info/tutorial.html</a></p>
<p>
The Regex syntax is described in detail here:
<a href="https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/perl_syntax.html" target="_blank">https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/perl_syntax.html</a>
<br />
and all the possible character classes can be found here:
<a href="https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/character_classes.html" target="_blank">https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/character_classes.html</a>
</p>
<table>
<tr>
<td colspan="2">
<h1>Regular expression examples</h1>
</td>
</tr>
<tr>
<td class="style1">.</td>
<td class="td-left">Matches all characters</td>
</tr>
<tr>
<td class="style1">+</td>
<td class="td-left">Matches the previous expression one or more times</td>
</tr>
<tr>
<td class="style2">*</td>
<td class="style5 td-left">Matches the previous expression zero or more times</td>
</tr>
<tr>
<td class="style2">\</td>
<td class="style5 td-left">Escapes special characters</td>
</tr>
<tr>
<td class="style2">\Q...\E</td>
<td class="style5 td-left">Matches the characters between <code>\Q</code> and <code>\E</code> literally,
suppressing the meaning of special characters.</td>
</tr>
<tr>
<td class="style2">[a-c]</td>
<td class="style5 td-left">Matches a, b and c</td>
</tr>
<tr>
<td class="style2">\d</td>
<td class="style5 td-left">Matches all digits</td>
</tr>
<tr>
<td class="style2">\w</td>
<td class="style5 td-left">Matches all word characters</td>
</tr>
<tr>
<td class="style2">\s</td>
<td class="style5 td-left">Matches all whitespace characters</td>
</tr>
<tr>
<td class="style3">^</td>
<td class="style4 td-left">Matches the start of a line</td>
</tr>
<tr>
<td class="style3">$</td>
<td class="style4 td-left">Matches the end of a line</td>
</tr>
<tr>
<td class="style3">\b</td>
<td class="style4 td-left">Matches a word boundary. Use this to search for whole words, e.g. <code>\bword\b</code>.</td>
</tr>
<tr>
<td class="style3">\x{FFFF}</td>
<td class="style4 td-left">Matches the unicode character 0xFFFF. Note: this only works for text files!</td>
</tr>
<tr>
<td class="style3">\xFF</td>
<td class="style4 td-left">Matches the character 0xFF</td>
</tr>
</table>
<p>for replacing, the following placeholders can be used</p>
<table>
<tr>
<td class="style3">$&</td>
<td class="style4 td-left">Outputs what matched the whole expression</td>
</tr>
<tr>
<td class="style3">$` or ${^PREMATCH}</td>
<td class="style4 td-left">Outputs the text between the end of the last match found (or the start of the
text if no previous match was found), and the start of the current match</td>
</tr>
<tr>
<td class="style3">$' or ${^POSTMATCH}</td>
<td class="style4 td-left">Outputs all the text following the end of the current match</td>
</tr>
<tr>
<td class="style3">$+</td>
<td class="style4 td-left">Outputs what matched the last marked sub-expression in the regular expression
</td>
</tr>
<tr>
<td class="style3">$n or ${n}</td>
<td class="style4 td-left">Outputs what matched the n'th sub-expression</td>
</tr>
<tr>
<td class="style3">$$</td>
<td class="style4 td-left">Outputs a literal '$'</td>
</tr>
<tr>
<td class="style3">$+{NAME}</td>
<td class="style4 td-left">Outputs whatever matched the sub-expression named "NAME"</td>
</tr>
<tr>
<td class="style3">${count08}</td>
<td class="style4 td-left">replaced with numbers starting from 1, incrementing by 1 for every match. The
numbers after "count" are optional and indicate how many leading spaces the output should use, or if the
number is preceded by a zero how many leading zeros.</td>
</tr>
<tr>
<td class="style3">${count08(start)}</td>
<td class="style4 td-left">same as <code>${count}</code>, but with "start" as the start value for counting</td>
</tr>
<tr>
<td class="style3">${count08(start, increment)}</td>
<td class="style4 td-left">same as <code>${count(start)}</code>, but with "increment" as the increment value
instead of the default 1</td>
</tr>
<tr>
<td class="style3">${filepath}</td>
<td class="style4 td-left">replaced with the path of the currently searched file</td>
</tr>
<tr>
<td class="style3">${filename}</td>
<td class="style4 td-left">replaced with the name of the currently searched file. The name does not include
the file extension</td>
</tr>
<tr>
<td class="style3">${fileext}</td>
<td class="style4 td-left">replaced with the extension of the currently searched file</td>
</tr>
<tr>
<td class="style3">${now}</td>
<td class="style4 td-left">replaced with the current date and time in the locale system format</td>
</tr>
<tr>
<td class="style3">${now}</td>
<td class="style4 td-left">replaced with the current date and time with the specified format.
The format string must be in the format of the strftime c++ function. See <a href="https://www.cplusplus.com/reference/ctime/strftime/">https://www.cplusplus.com/reference/ctime/strftime/</a>
for the specs.<br/>
Example: ${now,%A, %B %d, %Y} would print &quot;Saturday, March 17, 2021&quot;<br/>
The tooltip on the replace text box shows the expanded string.</td>
</tr>
<tr>
<td class="style3">\a</td>
<td class="style4 td-left">Outputs the bell character: '\a'</td>
</tr>
<tr>
<td class="style3">\e</td>
<td class="style4 td-left">Outputs the ANSI escape character (code point 27)</td>
</tr>
<tr>
<td class="style3">\f</td>
<td class="style4 td-left">Outputs a form feed character: '\f'</td>
</tr>
<tr>
<td class="style3">\n</td>
<td class="style4 td-left">Outputs a newline character: '\n'</td>
</tr>
<tr>
<td class="style3">\r</td>
<td class="style4 td-left">Outputs a carriage return character: '\r'</td>
</tr>
<tr>
<td class="style3">\t</td>
<td class="style4 td-left">Outputs a tab character: '\t'</td>
</tr>
<tr>
<td class="style3">\v</td>
<td class="style4 td-left">Outputs a vertical tab character: '\v'</td>
</tr>
<tr>
<td class="style3">\xDD</td>
<td class="style4 td-left">Outputs the character whose hexadecimal code point is 0xDD</td>
</tr>
<tr>
<td class="style3">\x{DDDD}</td>
<td class="style4 td-left">Outputs the character whose hexadecimal code point is 0xDDDDD</td>
</tr>
<tr>
<td class="style3">\cX</td>
<td class="style4 td-left">Outputs the ANSI escape sequence "escape-X"</td>
</tr>
<tr>
<td class="style3">\D</td>
<td class="style4 td-left">If D is a decimal digit in the range 1-9, then outputs the text
that matched sub-expression D</td>
</tr>
<tr>
<td class="style3">\l</td>
<td class="style4 td-left">Causes the next character to be outputted, to be output in lower case</td>
</tr>
<tr>
<td class="style3">\u</td>
<td class="style4 td-left">Causes the next character to be outputted, to be output in upper case</td>
</tr>
<tr>
<td class="style3">\L</td>
<td class="style4 td-left">Causes all subsequent characters to be output in lower case, until a \E is found</td>
</tr>
<tr>
<td class="style3">\U</td>
<td class="style4 td-left">Causes all subsequent characters to be output in upper case, until a \E is found</td>
</tr>
<tr>
<td class="style3">\E</td>
<td class="style4 td-left">Terminates a \L or \U sequence</td>
</tr>
<tr>
<td class="style3"></td>
<td class="td-right"><button tabindex="1" type="submit" onclick="window.close();">Close</button></td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,124 @@
{\rtf1\ansi\ansicpg1252\deff0\nouicompat\deflang1033\deflangfe1033{\fonttbl{\f0\fswiss\fprq2\fcharset0 Calibri;}}
{\colortbl ;\red0\green0\blue0;\red0\green0\blue255;\red0\green0\blue238;}
{\*\generator Riched20 10.0.22000}{\*\mmathPr\mdispDef1\mwrapIndent1440 }\viewkind4\uc1
\pard\widctlpar\fi-10\li-5\sa138\sl240\slmult1\cf1\f0\fs24 This help file shows only the basics of a regular expression search, and it's here only to show the flavor of the used regex.\par
\pard\widctlpar\fi-10\li-5\sl240\slmult1 If you're not familiar with regular expressions, please consult a tutorial like {\cf0{\field{\*\fldinst{HYPERLINK https://www.regular-expressions.info/tutorial.html }}{\fldrslt{https://www.regular-expressions.info/tutorial.html\ul0\cf0}}}}\cf0\f0\fs24\par
\pard\widctlpar\fi-10\li-5\sa138\sl240\slmult1\cf1\par
\pard\widctlpar\sa160\sl252\slmult1\expndtw1\charscalex110 The\expndtw8 \expndtw1 Regex\expndtw8 \expndtw1 syntax\expndtw8 \expndtw1 is\expndtw8 \expndtw1 described\expndtw8 \expndtw1 in\expndtw8 \expndtw1 detail\expndtw7 \expndtw1 here:\line {\cf0\charscalex104{\field{\*\fldinst{HYPERLINK https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/perl_syntax.html }}{\fldrslt{https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/perl_syntax.html\ul0\cf0}}}}\expndtw0\charscalex0\f0\fs24\par
\expndtw1\charscalex109 and\expndtw8 \expndtw1 all\expndtw7 \expndtw1 the\expndtw8 \expndtw1 possible\expndtw8 \expndtw1 character\expndtw8 \expndtw1 classes\expndtw8 \expndtw1 can\expndtw8 \expndtw1 be\expndtw8 \expndtw1 found\expndtw8 \expndtw1 here:\line {\cf0\charscalex105{\field{\*\fldinst{HYPERLINK https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/character_classes.html }}{\fldrslt{https://www.boost.org/doc/libs/release/libs/regex/doc/html/boost_regex/syntax/character_classes.html\ul0\cf0}}}}\expndtw0\charscalex0\f0\fs24\par
\trowd\trgaph134\trleft12\trrh612\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5114
\pard\intbl\widctlpar\sl252\slmult1\b\fs36 Regular expression examples\b0\cell\row\trowd\trgaph134\trleft12\trrh396\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\fs24 .\cell Matches all characters\cell\row\trowd\trgaph134\trleft12\trrh588\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1 +\cell Matches the previous expression one or more times\cell\row\trowd\trgaph134\trleft12\trrh588\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1 *\cell Matches the previous expression zero or more times\cell\row\trowd\trgaph134\trleft12\trrh516\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\\cell Escapes special characters\cell\row\trowd\trgaph134\trleft12\trrh780\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\Q...\\E\cell
\pard\intbl\widctlpar\ri155\sl252\slmult1\qj Matches the characters between \\Q and \\E literally, suppressing the meaning of special characters.\cell\row\trowd\trgaph134\trleft12\trrh516\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1 [a-c]\cell Matches a, b and c\cell\row\trowd\trgaph134\trleft12\trrh516\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\d\cell Matches all digits\cell\row\trowd\trgaph134\trleft12\trrh516\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\w\cell Matches all word characters\cell\row\trowd\trgaph134\trleft12\trrh516\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\s\cell Matches all whitespace characters\cell\row\trowd\trgaph134\trleft12\trrh408\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1 ^\cell Matches the start of a line\cell\row\trowd\trgaph134\trleft12\trrh408\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1 $\cell Matches the end of a line\cell\row\trowd\trgaph134\trleft12\trrh588\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\b\cell Matches a word boundary. Use this to search for whole words, e.g. \\bword\\b.\cell\row\trowd\trgaph134\trleft12\trrh780\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\x\{FFFF\}\cell Matches the unicode character\par
0xFFFF. Note: this only works for text\par
files!\cell\row\trowd\trgaph134\trleft12\trrh408\trpaddl134\trpaddr134\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1704\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5116
\pard\intbl\widctlpar\sl252\slmult1\\xFF\cell Matches the character 0xFF\cell\row
\pard\widctlpar\fi-10\li-5\sa138\sl240\slmult1\par
for replacing, the following placeholders can be used\par
\trowd\trgaph105\trleft6\trrh408\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $&\cell Outputs what matched the whole expression\cell\row\trowd\trgaph105\trleft6\trrh780\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $` or\par
$\{^PREMATCH\}\cell Outputs the text between the end of the last match found (or the start of the text if no previous match was found), and the start of the current match\cell\row\trowd\trgaph105\trleft6\trrh588\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $' or\par
$\{^POSTMATCH\}\cell Outputs all the text following the end of the current\par
match\cell\row\trowd\trgaph105\trleft6\trrh588\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $+\cell Outputs what matched the last marked subexpression in the regular expression\cell\row\trowd\trgaph105\trleft6\trrh408\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $n or $\{n\}\cell Outputs what matched the n'th sub-expression\cell\row\trowd\trgaph105\trleft6\trrh408\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $$\cell Outputs a literal '$'\cell\row\trowd\trgaph105\trleft6\trrh588\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $+\{NAME\}\cell Outputs whatever matched the sub-expression named "NAME"\cell\row\trowd\trgaph105\trleft6\trrh1356\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $\{count08\}\cell
\pard\intbl\widctlpar\ri4\sl252\slmult1 replaced with numbers starting from 1, incrementing by 1 for every match. The numbers after "count" are optional and indicate how many leading spaces the output should use, or if the number is preceded by a zero how many leading zeros.\cell\row\trowd\trgaph105\trleft6\trrh588\trpaddl105\trpaddr105\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $\{count08(start)\}\cell same as $\{count\}, but with "start" as the start value for counting\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\tx5207 $\{count08(start, increment)\}\cell
\pard\intbl\widctlpar\ri35\sl252\slmult1 same as $\{count(start)\}, but with "increment" as the increment value instead of the default 1\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $\{filepath\}\cell replaced with the path of the currently searched file\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $\{filename\}\cell replaced with the name of the currently searched file. The name does not include the file extension\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $\{fileext\}\cell replaced with the extension of the currently searched file\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $\{now\}\cell
\pard\intbl\widctlpar\ri28\sl252\slmult1 replaced with the current date and time in the locale system format\cell\row\trowd\trgaph102\trleft6\trrh1932\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1 $\{now\}\cell
\pard\intbl\widctlpar\sl240\slmult1 replaced with the current date and time with the specified format. The format string must be in the format of the strftime c++ function. See {{\field{\*\fldinst{HYPERLINK "https://www.cplusplus.com/reference/ctime/strftime/"}}{\fldrslt{\ul\cf2\cf3\ul https://www.cplusplus.com/reference/ctime/strftime/ }}}}\f0\fs24 for the specs.\par
\pard\intbl\widctlpar\sl252\slmult1 Example: $\{now,%A, %B %d, %Y\} would print\par
"Saturday, March 17, 2021"\par
The tooltip on the replace text box shows the expanded string.\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\a\cell Outputs the bell character: '\\a'\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\e\cell Outputs the ANSI escape character (code point 27)\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\f\cell Outputs a form feed character: '\\f'\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\n\cell Outputs a newline character: '\\n'\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\r\cell Outputs a carriage return character: '\\r'\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\t\cell Outputs a tab character: '\\t'\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\v\cell Outputs a vertical tab character: '\\v'\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\xDD\cell Outputs the character whose hexadecimal code point is 0xDD\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\x\{DDDD\}\cell Outputs the character whose hexadecimal code point is 0xDDDDD\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\cX\cell Outputs the ANSI escape sequence "escape-X"\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\D\cell If D is a decimal digit in the range 1-9, then outputs the text that matched sub-expression D\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\l\cell Causes the next character to be outputted, to be output in lower case\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\u\cell Causes the next character to be outputted, to be output in upper case\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\L\cell Causes all subsequent characters to be output in lower case, until a \\E is found\cell\row\trowd\trgaph102\trleft6\trrh588\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\U\cell Causes all subsequent characters to be output in upper case, until a \\E is found\cell\row\trowd\trgaph102\trleft6\trrh408\trpaddl102\trpaddr102\trpaddfl3\trpaddfr3
\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx1458\clvertalc\clbrdrl\brdrw12\brdrs\brdrcf1\clbrdrt\brdrw12\brdrs\brdrcf1\clbrdrr\brdrw12\brdrs\brdrcf1\clbrdrb\brdrw12\brdrs\brdrcf1 \cellx5124
\pard\intbl\widctlpar\sl252\slmult1\\E\cell Terminates a \\L or \\U sequence\cell\row
\pard\widctlpar\li-96\ri4713\sl252\slmult1\fs16\par
}

View File

@ -34,7 +34,6 @@
#include "BookmarksDlg.h"
#include "MultiLineEditDlg.h"
#include "AboutDlg.h"
#include "InfoDlg.h"
#include "DropFiles.h"
#include "RegexReplaceFormatter.h"
#include "LineData.h"
@ -138,7 +137,6 @@ CSearchDlg::CSearchDlg(HWND hParent)
, m_bCaseSensitiveC(false)
, m_bDotMatchesNewline(false)
, m_bDotMatchesNewlineC(false)
, m_bNotSearch(false)
, m_bCaptureSearch(false)
, m_bSizeC(false)
, m_endDialog(false)
@ -831,7 +829,11 @@ LRESULT CSearchDlg::DlgFunc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPara
break;
case WM_HELP:
{
CInfoDlg::ShowDialog(*this, IDR_INFODLG, hResource);
if (m_rtfDialog == nullptr)
{
m_rtfDialog = std::make_unique<CInfoRtfDialog>();
}
m_rtfDialog->ShowModeless(g_hInst, *this, "grepWinNP3 help", IDR_INFODLG, L"RTF", IDI_GREPWIN, 400, 600);
}
break;
case WM_SYSCOMMAND:
@ -1089,13 +1091,6 @@ LRESULT CSearchDlg::DoCommand(int id, int msg)
m_listItems.clear();
m_listItems.reserve(500000);
s_BackupAndTmpFiles.clear();
if (m_searchString.empty())
{
// switch to file view
CheckRadioButton(*this, IDC_RESULTFILES, IDC_RESULTCONTENT, IDC_RESULTFILES);
m_showContent = false;
InitResultList();
}
HWND hListControl = GetDlgItem(*this, IDC_RESULTLIST);
ListView_SetItemCount(hListControl, 0);
@ -1159,6 +1154,14 @@ LRESULT CSearchDlg::DoCommand(int id, int msg)
m_replaceString = ExpandString(m_replaceString);
}
if (m_searchString.empty() || IsNOTSearch())
{
// switch to file view
CheckRadioButton(*this, IDC_RESULTFILES, IDC_RESULTCONTENT, IDC_RESULTFILES);
m_showContent = false;
InitResultList();
}
InterlockedExchange(&s_SearchThreadRunning, TRUE);
InterlockedExchange(&s_Cancelled, FALSE);
SetDlgItemText(*this, IDOK, TranslatedString(hResource, IDS_STOP).c_str());

View File

@ -26,6 +26,7 @@
#include "Registry.h"
#include "EditDoubleClick.h"
#include "StringUtils.h"
#include "InfoRtfDialog.h"
#include <string>
#include <vector>
#include <set>
@ -43,6 +44,7 @@
#endif
#include <wrl.h>
using namespace Microsoft::WRL;
#define SEARCH_START (WM_APP+1)
@ -227,7 +229,6 @@ private:
bool m_bCaseSensitiveC;
bool m_bDotMatchesNewline;
bool m_bDotMatchesNewlineC;
bool m_bNotSearch;
bool m_bCaptureSearch;
bool m_bSizeC;
bool m_endDialog;
@ -251,6 +252,7 @@ private:
bool m_bAscending;
std::wstring m_resultString;
std::wstring m_toolTipReplaceString;
std::unique_ptr<CInfoRtfDialog> m_rtfDialog;
bool m_bStayOnTop;
BYTE m_OpacityNoFocus;

View File

@ -6,13 +6,13 @@
//#pragma message(__LOC__"Run the NAnt script to get proper version info")
#define FILEVER 2, 1, 8, 40
#define PRODUCTVER 2, 1, 8, 40
#define STRFILEVER "2.1.8.40\0"
#define STRPRODUCTVER "2.1.8.40\0"
#define FILEVER 2, 1, 9, 41
#define PRODUCTVER 2, 1, 9, 41
#define STRFILEVER "2.1.9.41\0"
#define STRPRODUCTVER "2.1.9.41\0"
#define GREPWIN_VERMAJOR 2
#define GREPWIN_VERMINOR 1
#define GREPWIN_VERMICRO 8
#define GREPWIN_VERBUILD 40
#define GREPWIN_VERDATE "2021-10-19"
#define GREPWIN_VERMICRO 9
#define GREPWIN_VERBUILD 41
#define GREPWIN_VERDATE "2021-11-30"

View File

@ -39,7 +39,6 @@
#define IDS_REGEXINVALID 132
#define IDC_BKPOPUP 133
#define IDS_SIZE 133
#define IDR_INFODLG 134
#define IDS_LINE 134
#define IDD_ABOUT 135
#define IDS_MATCHES 135
@ -50,6 +49,8 @@
#define IDD_SETTINGS 138
#define IDS_ENCODING 138
#define IDS_DATEMODIFIED 139
#define IDR_RTF1 139
#define IDR_INFODLG 139
#define IDS_SELECTEDITOR 140
#define IDS_OPENWITHEDITOR 141
#define IDS_OPENCONTAININGFOLDER 142
@ -201,7 +202,7 @@
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NO_MFC 1
#define _APS_NEXT_RESOURCE_VALUE 139
#define _APS_NEXT_RESOURCE_VALUE 140
#define _APS_NEXT_COMMAND_VALUE 32776
#define _APS_NEXT_CONTROL_VALUE 1092
#define _APS_NEXT_SYMED_VALUE 110

View File

@ -4,7 +4,7 @@
<setenv>
<variable name="MajorVersion" value="2" />
<variable name="MinorVersion" value="0" />
<variable name="MicroVersion" value="8" />
<variable name="MicroVersion" value="9" />
<variable name="WCREV" value="$WCLOGCOUNT$" />
<variable name="WCDATE" value="$WCDATE$" />
</setenv>

View File

@ -1,2 +1,2 @@
2.0.8.1054
2.0.9.1098
https://tools.stefankueng.com/grepWin.html