Commit f311412a authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Disable DiacriticAct when regularexpression is checked

parent 22073753
Pipeline #146946 passed with stages
in 7 minutes and 3 seconds
......@@ -113,13 +113,19 @@ TextFindWidget::TextFindWidget(QWidget *parent)
connect(mCaseSensitiveAct, &QAction::toggled, this, &TextFindWidget::updateSearchOptions);
connect(mWholeWordAct, &QAction::toggled, this, &TextFindWidget::updateSearchOptions);
connect(mRespectDiacriticAct, &QAction::toggled, this, &TextFindWidget::updateSearchOptions);
connect(mRegularExpressionAct, &QAction::toggled, this, &TextFindWidget::updateSearchOptions);
connect(mRegularExpressionAct, &QAction::toggled, this, &TextFindWidget::slotRegularExpressionChanged);
connect(mSearch, &QLineEdit::textChanged, this, &TextFindWidget::slotAutoSearch);
connect(mSearch, &QLineEdit::returnPressed, this, &TextFindWidget::findNext);
}
TextFindWidget::~TextFindWidget() = default;
void TextFindWidget::slotRegularExpressionChanged(bool b)
{
mRespectDiacriticAct->setEnabled(!b);
Q_EMIT updateSearchOptions();
}
void TextFindWidget::setFoundMatch(bool match)
{
#ifndef QT_NO_STYLE_STYLESHEET
......
......@@ -46,6 +46,7 @@ Q_SIGNALS:
void searchStringEmpty(bool);
private:
void slotRegularExpressionChanged(bool b);
QLineEdit *const mSearch;
QAction *mCaseSensitiveAct = nullptr;
QAction *mWholeWordAct = nullptr;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment