BibleTime
cbiblereadwindow.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-2021 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 "cdisplaywindow.h"
16 
17 #include <QAction>
18 #include "../cexportmanager.h"
19 #include "btactioncollection.h"
20 
21 
22 class CSwordKey;
23 class CSwordVerseKey;
24 class QAction;
25 class QEvent;
26 class QMenu;
27 class QObject;
28 
30 
31  Q_OBJECT
32 
33 public: // methods:
34 
36  CMDIArea * parent)
37  : CDisplayWindow(modules, parent)
38  { init(); }
39 
41  { return CSwordModuleInfo::Bible; }
42 
43  void storeProfileSettings(BtConfigCore & windowConf) const override;
44  void applyProfileSettings(BtConfigCore const & windowConf) override;
45  static void insertKeyboardActions( BtActionCollection* const a );
46 
47 protected: // methods:
48 
49  void initActions() override;
50  void initView() override;
51  QMenu * newDisplayWidgetPopupMenu() override;
52  bool eventFilter( QObject* o, QEvent* e) override;
53 
54  struct {
57 
59  struct {
66  }
68 
70  struct {
74  }
76 
78  struct {
81  }
83  }
85 
86 
87 public Q_SLOTS:
88 
89  void nextBook();
90  void previousBook();
91  void nextChapter();
92  void previousChapter();
93  void nextVerse();
94  void previousVerse();
95 
96  void reload() override;
97 
98 protected Q_SLOTS:
99 
100  /**
101  * Copies the current chapter into the clipboard.
102  */
103  void copyDisplayedText() override;
104  /**
105  * Saves the chapter as valid HTML page.
106  */
107  void saveChapterHTML();
108  /**
109  * Saves the chapter as valid HTML page.
110  */
111  void saveChapterPlain();
112  void lookupSwordKey(CSwordKey * newKey) override;
113  void syncWindows();
114 
115 private: // methods:
116 
117  /**
118  * Wrapper around key() to return the right type of key.
119  */
121 
122  void saveChapter(CExportManager::Format const format);
123 
124 };
void saveChapter(CExportManager::Format const format)
QAction * chapterAsHTML
QAction * referenceOnly
struct CBibleReadWindow::@1::@3 save
void applyProfileSettings(BtConfigCore const &windowConf) override
Loads the settings of this window from configuration.
void lookupSwordKey(CSwordKey *newKey) override
QAction * byReferences
CBibleReadWindow(QList< CSwordModuleInfo * > const &modules, CMDIArea *parent)
static void insertKeyboardActions(BtActionCollection *const a)
void initActions() override
QAction * referenceTextOnly
bool eventFilter(QObject *o, QEvent *e) override
struct CBibleReadWindow::@1::@4 print
void initView() override
void copyDisplayedText() override
QAction * referenceAndText
struct CBibleReadWindow::@1::@2 copy
void storeProfileSettings(BtConfigCore &windowConf) const override
Stores the settings of this window to configuration.
CSwordModuleInfo::ModuleType moduleType() const override
CSwordVerseKey * verseKey()
void reload() override
struct CBibleReadWindow::@1 m_actions
QAction * chapterAsPlain
QAction * selectedText
QMenu * newDisplayWidgetPopupMenu() override
The base class for all display windows of BibleTime.
BtModuleList const & modules() const noexcept
CSwordKey implementation for Sword's VerseKey.