BibleTime
btbiblekeywidget.h
Go to the documentation of this file.
1/*********
2*
3* In the name of the Father, and of the Son, and of the Holy Spirit.
4*
5* This file is part of BibleTime's source code, https://bibletime.info/
6*
7* Copyright 1999-2025 by the BibleTime developers.
8* The BibleTime source code is licensed under the GNU General Public License
9* version 2.0.
10*
11**********/
12
13#pragma once
14
15#include <QWidget>
16
17#include <QTimer>
18#include "../../../backend/drivers/cswordbiblemoduleinfo.h"
19
20
21class CSwordVerseKey;
22class QLineEdit;
23class QMenu;
24
25class BtBibleKeyWidget : public QWidget {
26 Q_OBJECT
27
28 public:
30 CSwordVerseKey * key,
31 QWidget * parent = nullptr);
32
33 ~BtBibleKeyWidget() override;
34 bool setKey(CSwordVerseKey* key);
35 void setModule(const CSwordBibleModuleInfo *m = nullptr);
36 bool eventFilter(QObject *o, QEvent *e) override;
37
38 Q_SIGNALS:
40
41 protected:
42 void enterEvent(QEnterEvent * event) override;
43 void leaveEvent(QEvent *event) override;
44 void resizeEvent(QResizeEvent *event) override;
46
47 public Q_SLOTS:
48 void updateText();
49
50 private: // methods:
51
52 void populateBookMenu(QMenu & menu);
53 void populateChapterMenu(QMenu & menu);
54 void populateVerseMenu(QMenu & menu);
55
56 private:
57
59
61
64
66 QString oldKey;
68};
const CSwordBibleModuleInfo * m_module
void enterEvent(QEnterEvent *event) override
CSwordVerseKey * m_key
bool eventFilter(QObject *o, QEvent *e) override
void resizeEvent(QResizeEvent *event) override
void populateBookMenu(QMenu &menu)
QLineEdit * m_textbox
void setModule(const CSwordBibleModuleInfo *m=nullptr)
void leaveEvent(QEvent *event) override
void populateChapterMenu(QMenu &menu)
void changed(CSwordVerseKey *key)
void populateVerseMenu(QMenu &menu)
bool setKey(CSwordVerseKey *key)
QWidget * m_dropDownButtons
Implementation for Sword Bibles.
CSwordKey implementation for Sword's VerseKey.