MCPcopy Create free account
hub / github.com/dail8859/NotepadNext / QuickFindWidget

Method QuickFindWidget

src/widgets/QuickFindWidget.cpp:31–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29#include <QScrollBar>
30
31QuickFindWidget::QuickFindWidget(QWidget *parent) :
32 QFrame(parent),
33 ui(new Ui::QuickFindWidget)
34{
35 ui->setupUi(this);
36
37 // Move the focus to the line edit widget
38 setFocusProxy(ui->lineEdit);
39
40 ui->lineEdit->installEventFilter(this);
41
42 FocusWatcher *fw = new FocusWatcher(ui->lineEdit);
43 connect(fw, &FocusWatcher::focusOut, this, &QuickFindWidget::focusOut);
44 connect(fw, &FocusWatcher::focusIn, this, &QuickFindWidget::focusIn);
45
46 connect(ui->lineEdit, &QLineEdit::returnPressed, this, &QuickFindWidget::returnPressed);
47
48 // Any changes need to trigger a new search
49 connect(ui->lineEdit, &QLineEdit::textChanged, this, &QuickFindWidget::performNewSearch);
50 connect(ui->buttonMatchCase, &QToolButton::toggled, this, &QuickFindWidget::performNewSearch);
51 connect(ui->buttonWholeWord, &QToolButton::toggled, this, &QuickFindWidget::performNewSearch);
52 connect(ui->buttonRegexp, &QToolButton::toggled, this, &QuickFindWidget::performNewSearch);
53}
54
55QuickFindWidget::~QuickFindWidget()
56{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected