diff --git a/PowerEditor/src/Notepad_plus.cpp b/PowerEditor/src/Notepad_plus.cpp index 259e1e13c..e1153c595 100644 --- a/PowerEditor/src/Notepad_plus.cpp +++ b/PowerEditor/src/Notepad_plus.cpp @@ -1486,10 +1486,8 @@ void Notepad_plus::doTrim(trimOp whichPart) else return; env._str4Replace = TEXT(""); - env._searchType = FindRegex; - bool isEntireDoc = _pEditView->execute(SCI_GETSELECTIONSTART) == _pEditView->execute(SCI_GETSELECTIONEND); - env._isInSelection = !isEntireDoc; - _findReplaceDlg.processAll(ProcessReplaceAll, &env, isEntireDoc); + env._searchType = FindRegex; + _findReplaceDlg.processAll(ProcessReplaceAll, &env, true); } void Notepad_plus::removeEmptyLine(bool isBlankContained)