3
* This file is part of BibleTime's source code, http://www.bibletime.info/.
5
* Copyright 1999-2006 by the BibleTime developers.
6
* The BibleTime source code is licensed under the GNU General Public License version 2.0.
12
#ifndef CPROFILEWINDOW_H
13
#define CPROFILEWINDOW_H
15
#include "backend/cswordmoduleinfo.h"
16
#include "backend/cswordbackend.h"
21
#include <qstringlist.h>
26
/** Contains the settings for one window saved in the profile.
27
* @author The BibleTime team
29
class CProfileWindow {
32
int horizontal; //the position of the horizontal scrollbar
33
int vertical; //the position of the vertical scrollbar
36
CProfileWindow(CSwordModuleInfo::ModuleType type = CSwordModuleInfo::Unknown);
41
void setModules( const QStringList& modules );
43
* Returns the type of the managed window (bible window, commentary window or lexicon window).
45
const CSwordModuleInfo::ModuleType type() const;
47
* Sets the type of the used modules.
49
void setType(const CSwordModuleInfo::ModuleType& type);
51
* Sets the size of the window.
53
void setGeometry( const QRect& s );
55
* Returns the size of the window including the x,y coordinates.
57
const QRect& geometry() const;
59
* Returns a list of module names which are chosen in the managed window profile.
61
const QStringList& modules() const;
63
* Set the key used in the modules.
65
void setKey( const QString& );
67
* Returns the current key set in the modules.
69
const QString& key() const;
71
* Sets the current position of the scrollbars.
73
void setScrollbarPositions(const int& x, const int& y);
75
* Sets the windows maximized state to true or false.
77
void setMaximized( const bool& maximized );
79
* Sets the windows hasFocus state to true or false.
81
void setFocus( const bool& hasFocus );
83
* Sets the window specific settings.
85
void setWindowSettings( const int& settings );
87
* Returns an integer with the window specific settings
89
const int& windowSettings() const;
91
* Returns true if the window is maximized.
93
const bool& maximized() const;
95
* Returns true if the window has the focus in the MDI area.
97
const bool& hasFocus() const;
99
* Returns tghe position of the scrollbars
101
const CProfileWindow::ScrollbarPos& scrollbarPositions() const;
103
* Returns whether this profile window represents a write window.
105
const int& writeWindowType() const;
107
* Tells this profile window to represent a write window.
109
void setWriteWindowType( const int& writeWindowType );
112
CSwordModuleInfo::ModuleType m_type;
113
QRect m_windowGeometry;
114
QStringList m_moduleList;
116
ScrollbarPos m_scrollbarPos;
119
int m_windowSettings;
120
int m_writeWindowType;
123
} //end of namespace Profile