From 1135fcf7dd77616aa1108632494be3680c1832f8 Mon Sep 17 00:00:00 2001 From: Roy Qu Date: Mon, 24 Jan 2022 18:03:35 +0800 Subject: [PATCH] - fix: search around option can't be disabled - enhancement: show a confirm dialog when search/replace around --- NEWS.md | 2 + RedPandaIDE/RedPandaIDE_zh_CN.qm | Bin 110837 -> 112067 bytes RedPandaIDE/RedPandaIDE_zh_CN.ts | 111 +++++++++++++----- RedPandaIDE/qsynedit/SynEdit.cpp | 9 +- RedPandaIDE/qsynedit/SynEdit.h | 4 +- RedPandaIDE/qsynedit/TextPainter.cpp | 1 - .../compilersetoptionwidget.cpp | 2 - .../settingsdialog/compilersetoptionwidget.ui | 2 +- RedPandaIDE/widgets/searchdialog.cpp | 24 +++- RedPandaIDE/widgets/searchdialog.h | 4 +- 10 files changed, 116 insertions(+), 43 deletions(-) diff --git a/NEWS.md b/NEWS.md index 01eebbce..fb5ae43d 100644 --- a/NEWS.md +++ b/NEWS.md @@ -22,6 +22,8 @@ Red Panda C++ Version 0.13.3 - fix: indent lines displayed at wrong position, when there are folded lines - fix: if editor's active line color is disabled, caret's position may not be correct redrawn - fix: insert code snippets will crash, if current compiler set's include dir list is not empty and lib dir list is empty + - fix: search around option can't be disabled + - enhancement: show a confirm dialog when search/replace around Red Panda C++ Version 0.13.2 - fix: "delete and exit" button in the environtment / folder option page doesn't work correctly diff --git a/RedPandaIDE/RedPandaIDE_zh_CN.qm b/RedPandaIDE/RedPandaIDE_zh_CN.qm index 6fb3940ae753c06678367dfad36d17b34f455858..be776f37b1d810d1ac2e0899a70d4444f36147e8 100644 GIT binary patch delta 11494 zcma)?bwCtb`1hZ)J2P9ey9S{mx&~rmH;Rg)B4B_8NG}KyO4zU}c3=Ra*nx@Y6+2Kd zP_Lp`*G|MhvAf>y?%emj@9)3gKYVs}XU?4SoTm?;9tkJQg+=zJ#!4bCo#;+oFazuj zW`fb+QgAVt1?~fvfp@^=M0W|?O{~ug@I5gP+{afT*54lNOf+MGg-mxvVw4H&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ds)`VEHAdO_PUM{ iEGNfqG&`%wF^*#wbUD&==B{6tKcB70;TE#Imj4IDsmgHx diff --git a/RedPandaIDE/RedPandaIDE_zh_CN.ts b/RedPandaIDE/RedPandaIDE_zh_CN.ts index c37a15bc..4e8299eb 100644 --- a/RedPandaIDE/RedPandaIDE_zh_CN.ts +++ b/RedPandaIDE/RedPandaIDE_zh_CN.ts @@ -773,9 +773,8 @@ p, li { white-space: pre-wrap; } 链接时加入下列选项 - Add Charset arguments when calling the compiler - 编译时自动加入字符编码选项 + 编译时自动加入字符编码选项 @@ -807,6 +806,12 @@ p, li { white-space: pre-wrap; } Remove 删除 + + + Convert Executable's Charset as + Convert Executable's Charset + 将可执行文件中的字符串转码为 + Statically link libraries @@ -902,12 +907,12 @@ p, li { white-space: pre-wrap; } 选择性能分析器 - + Confirm 确认 - + Red Panda C++ will clear current compiler list and search for compilers in the following locations:<br /> '%1'<br /> '%2'<br />Are you really want to continue? Red Panda C++ will clear current compiler list and search for compilers in the following locations: '%1' @@ -916,50 +921,50 @@ Are you really want to continue? 小熊猫C++ 将会清除现有的编译器配置列表,然后在下列文件夹中搜索编译器:<br/> '%1'<br/> '%2'<br />你确定要继续吗? - + ANSI ANSI - + UTF-8 UTF-8 - + Red Panda C++ will clear current compiler list and search for compilers in the the PATH. <br />Are you really want to continue? 小熊猫C++ 将会清除现有的编译器配置列表,然后在PATH路径中搜索gcc编译器.<br />你确定要继续吗? - - + + Failed 失败 - - + + Can't find any compiler. 找不到编译器 - - + + Compiler Set Name 编译器配置名称 - + Name 名称 - + Compiler Set Folder 编译器所在文件夹 - + New name 新名称 @@ -6027,6 +6032,26 @@ Are you really want to continue? Cannot find the %1 "%2" 无法找到%1程序"%2" + + + C Compiler + C编译器 + + + + C++ Compiler + C++编译器 + + + + Maker + 构建程序(Make) + + + + Debugger + 调试器 + C options @@ -6093,7 +6118,7 @@ Are you really want to continue? 生成调试信息(-g3) - + Would you like Red Panda C++ to search for compilers in PATH? 您同意小熊猫C++在PATH路径中寻找gcc编译器吗? @@ -6192,34 +6217,34 @@ Are you really want to continue? 只生成汇编代码(-S) - - + + Confirm 确认 - + The following problems were found during validation of compiler set "%1": 在验证编译器设置"%1"时遇到了下列问题: - + Would you like Red Panda C++ to remove them for you and add the default paths to the valid paths? 是否让小熊猫C++删除这些配置,并尝试重新建立配置? - + Leaving those directories will lead to problems during compilation.<br /><br />Unless you know exactly what you're doing, it is recommended that you click Yes. 如果仍然保留这些设置,可能会导致编译错误。<br /><br />请选择“是”,除非您清楚的知道选择“否”的后果, - - + + Compiler set not configuared. 未配置编译器设置。 - + Would you like Red Panda C++ to search for compilers in the following locations: <BR />'%1'<BR />'%2'? 您需要小熊猫C++在下列位置搜索编译器吗:<br />%1<br />%2 @@ -6244,13 +6269,13 @@ Are you really want to continue? C++包含文件 - + No - + Yes @@ -6753,7 +6778,7 @@ Are you really want to continue? - + Replace 替换 @@ -6763,10 +6788,36 @@ Are you really want to continue? 在文件中替换 - + + Continue Search + Search Around + 继续查找 + + + + + End of file has been reached. + End of file has been reached. + 已到达文件结尾。 + + + + + Do you want to continue from file's beginning? + Do you want to start from beginning? + 是否从文件开头继续? + + + Replace this occurrence of ''%1''? 替换这里的"%1"? + + + Continue Replace + Replace Around + 继续替换 + SearchResultListModel @@ -7368,7 +7419,7 @@ Are you really want to continue? 无法读取文件'%1'! - + Can't open file '%1' for save! 无法写入文件'%2'! diff --git a/RedPandaIDE/qsynedit/SynEdit.cpp b/RedPandaIDE/qsynedit/SynEdit.cpp index 7741f853..6086f79a 100644 --- a/RedPandaIDE/qsynedit/SynEdit.cpp +++ b/RedPandaIDE/qsynedit/SynEdit.cpp @@ -4755,7 +4755,7 @@ void SynEdit::doSetSelText(const QString &Value) } int SynEdit::searchReplace(const QString &sSearch, const QString &sReplace, SynSearchOptions sOptions, PSynSearchBase searchEngine, - SynSearchMathedProc matchedCallback) + SynSearchMathedProc matchedCallback, SynSearchConfirmAroundProc confirmAroundCallback) { if (!searchEngine) return 0; @@ -4917,9 +4917,10 @@ int SynEdit::searchReplace(const QString &sSearch, const QString &sReplace, SynS ptCurrent.Line--; else ptCurrent.Line++; - if ( - ((ptCurrent.Line < ptStart.Line) || (ptCurrent.Line > ptEnd.Line)) - && bFromCursor){ + if (((ptCurrent.Line < ptStart.Line) || (ptCurrent.Line > ptEnd.Line)) + && bFromCursor && sOptions.testFlag(ssoWrapAround)){ + if (confirmAroundCallback && !confirmAroundCallback()) + break; //search start from cursor, search has finished but no result founds bFromCursor = false; ptStart.Char = 1; diff --git a/RedPandaIDE/qsynedit/SynEdit.h b/RedPandaIDE/qsynedit/SynEdit.h index 542db9f3..d30f1210 100644 --- a/RedPandaIDE/qsynedit/SynEdit.h +++ b/RedPandaIDE/qsynedit/SynEdit.h @@ -147,6 +147,7 @@ using SynPaintProc = std::function; // SynFontStyles& style, QColor& foreground, QColor& background)>; using SynSearchMathedProc = std::function; +using SynSearchConfirmAroundProc = std::function; class SynEdit; using PSynEdit = std::shared_ptr; @@ -244,7 +245,8 @@ public: void setSelText(const QString& text); int searchReplace(const QString& sSearch, const QString& sReplace, SynSearchOptions options, - PSynSearchBase searchEngine, SynSearchMathedProc matchedCallback = nullptr); + PSynSearchBase searchEngine, SynSearchMathedProc matchedCallback = nullptr, + SynSearchConfirmAroundProc confirmAroundCallback = nullptr); int maxScrollWidth() const; int maxScrollHeight() const; diff --git a/RedPandaIDE/qsynedit/TextPainter.cpp b/RedPandaIDE/qsynedit/TextPainter.cpp index b083d499..fb633f9e 100644 --- a/RedPandaIDE/qsynedit/TextPainter.cpp +++ b/RedPandaIDE/qsynedit/TextPainter.cpp @@ -720,7 +720,6 @@ void SynEditTextPainter::PaintFoldAttributes() // Now loop through all the lines. The indices are valid for Lines. for (cRow = aFirstRow; cRow<=aLastRow;cRow++) { vLine = edit->rowToLine(cRow); - qDebug()< edit->mLines->count() && edit->mLines->count() > 0) break; // Set vertical coord diff --git a/RedPandaIDE/settingsdialog/compilersetoptionwidget.cpp b/RedPandaIDE/settingsdialog/compilersetoptionwidget.cpp index 08ddb91e..5a8a535f 100644 --- a/RedPandaIDE/settingsdialog/compilersetoptionwidget.cpp +++ b/RedPandaIDE/settingsdialog/compilersetoptionwidget.cpp @@ -59,7 +59,6 @@ CompilerSetOptionWidget::~CompilerSetOptionWidget() void CompilerSetOptionWidget::init() { - ui->cbEncoding->setVisible(false); ui->cbEncodingDetails->setVisible(false); ui->cbEncoding->clear(); ui->cbEncoding->addItem(tr("ANSI"),ENCODING_SYSTEM_DEFAULT); @@ -144,7 +143,6 @@ static void loadCompilerSetSettings(Settings::PCompilerSet pSet, Ui::CompilerSet ui->txtResourceCompiler->setText(pSet->resourceCompiler()); ui->txtProfiler->setText(pSet->profiler()); - ui->cbEncoding->setVisible(pSet->autoAddCharsetParams()); if (pSet->execCharset() == ENCODING_AUTO_DETECT || pSet->execCharset() == ENCODING_SYSTEM_DEFAULT || pSet->execCharset() == ENCODING_UTF8) { diff --git a/RedPandaIDE/settingsdialog/compilersetoptionwidget.ui b/RedPandaIDE/settingsdialog/compilersetoptionwidget.ui index 0757cec2..9fcb6130 100644 --- a/RedPandaIDE/settingsdialog/compilersetoptionwidget.ui +++ b/RedPandaIDE/settingsdialog/compilersetoptionwidget.ui @@ -138,7 +138,7 @@ - Convert Executable's Charset + Convert Executable's Charset as diff --git a/RedPandaIDE/widgets/searchdialog.cpp b/RedPandaIDE/widgets/searchdialog.cpp index fb42d035..a84485bf 100644 --- a/RedPandaIDE/widgets/searchdialog.cpp +++ b/RedPandaIDE/widgets/searchdialog.cpp @@ -250,7 +250,15 @@ void SearchDialog::on_btnExecute_clicked() if (actionType == SearchAction::Find) { Editor *e = pMainWindow->editorList()->getEditor(); if (e!=nullptr) { - findCount+=execute(e,ui->cbFind->currentText(),""); + findCount+=execute(e,ui->cbFind->currentText(),"",nullptr, + [](){ + return QMessageBox::question(pMainWindow, + tr("Continue Search"), + tr("End of file has been reached. ") + +tr("Do you want to continue from file's beginning?"), + QMessageBox::Yes|QMessageBox::No, + QMessageBox::Yes) == QMessageBox::Yes; + }); } } else if (actionType == SearchAction::Replace) { Editor *e = pMainWindow->editorList()->getEditor(); @@ -279,6 +287,14 @@ void SearchDialog::on_btnExecute_clicked() } else { return SynSearchAction::ReplaceAll; } + }, + [](){ + return QMessageBox::question(pMainWindow, + tr("Continue Replace"), + tr("End of file has been reached. ") + +tr("Do you want to continue from file's beginning?"), + QMessageBox::Yes|QMessageBox::No, + QMessageBox::Yes) == QMessageBox::Yes; }); } @@ -376,7 +392,9 @@ void SearchDialog::on_btnExecute_clicked() } } -int SearchDialog::execute(SynEdit *editor, const QString &sSearch, const QString &sReplace, SynSearchMathedProc matchCallback) +int SearchDialog::execute(SynEdit *editor, const QString &sSearch, const QString &sReplace, + SynSearchMathedProc matchCallback, + SynSearchConfirmAroundProc confirmAroundCallback) { if (editor==nullptr) return 0; @@ -398,7 +416,7 @@ int SearchDialog::execute(SynEdit *editor, const QString &sSearch, const QString } return editor->searchReplace(sSearch, sReplace, mSearchOptions, - mSearchEngine, matchCallback); + mSearchEngine, matchCallback, confirmAroundCallback); } std::shared_ptr SearchDialog::batchFindInEditor(SynEdit *e, const QString& filename,const QString &keyword) diff --git a/RedPandaIDE/widgets/searchdialog.h b/RedPandaIDE/widgets/searchdialog.h index 5d88ded0..260c0067 100644 --- a/RedPandaIDE/widgets/searchdialog.h +++ b/RedPandaIDE/widgets/searchdialog.h @@ -61,7 +61,9 @@ private slots: void on_btnExecute_clicked(); private: int execute(SynEdit* editor, const QString& sSearch, - const QString& sReplace, SynSearchMathedProc matchCallback = nullptr); + const QString& sReplace, + SynSearchMathedProc matchCallback = nullptr, + SynSearchConfirmAroundProc confirmAroundCallback = nullptr); std::shared_ptr batchFindInEditor(SynEdit * editor,const QString& filename, const QString& keyword); private: Ui::SearchDialog *ui;