KVIrc  4.9.2
DeveloperAPIs
SetupWizard.h
Go to the documentation of this file.
1 #ifndef _SETUPWIZARD_H_
2 #define _SETUPWIZARD_H_
3 //=============================================================================
4 //
5 // File : SetupWizard.h
6 // Creation date : Sat Oct 6 02:06:51 2001 GMT by Szymon Stefanek
7 //
8 // This file is part of the KVIrc IRC client distribution
9 // Copyright (C) 2001-2010 Szymon Stefanek (pragma at kvirc dot net)
10 //
11 // This program is FREE software. You can redistribute it and/or
12 // modify it under the terms of the GNU General Public License
13 // as published by the Free Software Foundation; either version 2
14 // of the License, or (at your option) any later version.
15 //
16 // This program is distributed in the HOPE that it will be USEFUL,
17 // but WITHOUT ANY WARRANTY; without even the implied warranty of
18 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
19 // See the GNU General Public License for more details.
20 //
21 // You should have received a copy of the GNU General Public License
22 // along with this program. If not, write to the Free Software Foundation,
23 // Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
24 //
25 //=============================================================================
26 
27 #include "kvi_settings.h"
28 #include "KviCString.h"
29 #include "KviSelectors.h"
30 #include "KviTalWizard.h"
31 #include "KviTalVBox.h"
32 #include "KviTalHBox.h"
33 #include "KviTalGroupBox.h"
34 
35 #include <QLabel>
36 #include <QPixmap>
37 #include <QLineEdit>
38 #include <QRadioButton>
39 #include <QComboBox>
40 #include <QCheckBox>
41 #include <QGridLayout>
42 
43 class SetupWizard;
44 
45 class SetupPage : public QWidget
46 {
47  Q_OBJECT
48 public:
50  ~SetupPage();
51 
52 public:
54  QLabel * m_pPixmapLabel;
55  QLabel * m_pTextLabel;
56 };
57 
58 #define THEME_APPLY_NONE 0
59 #define THEME_APPLY_HIRES 1
60 #define THEME_APPLY_LORES 2
61 
62 class SetupWizard : public KviTalWizard
63 {
64  Q_OBJECT
65 public:
66  SetupWizard();
67  ~SetupWizard();
68 
69 public:
70  QPixmap * m_pLabelPixmap;
71 
79 
80  // Theme
81  QGroupBox * m_pThemeButtonGroup;
82 
83  QRadioButton * m_pThemeHiRes;
84  QRadioButton * m_pThemeLoRes;
85  QRadioButton * m_pThemeNone;
86 
87  // Welcome
88  QCheckBox * m_pCreateUrlHandlers;
90 
91  //Dir
92  QLineEdit * m_pDataPathEdit;
93  QLineEdit * m_pIncomingPathEdit;
95  QRadioButton * m_pDirUsePrev;
96  QRadioButton * m_pDirUseNew;
97 #if defined(COMPILE_ON_WINDOWS) || defined(COMPILE_ON_MINGW)
98  QRadioButton * m_pDirMakePortable;
99 #endif
100  //QRadioButton * m_pDirRestore;
101  QLineEdit * m_pOldDataPathEdit;
105 
106  //Identify
107  QComboBox * m_pAgeCombo;
108  QComboBox * m_pGenderCombo;
109 
114 //KviStringSelector * m_pOtherInfoSelector;
115 
116 //Servers
117 //KviTalGroupBox * m_pServersButtonGroup;
118 //QRadioButton * m_pServersChooseFromList;
119 //QRadioButton * m_pServersSpecifyManually;
120 //QRadioButton * m_pServersOpenIrcUrl;
121 //QRadioButton * m_pServersLoadConfig;
122 #if defined(COMPILE_ON_WINDOWS) || defined(COMPILE_ON_MINGW)
123  QString m_szMircServerIniFile;
124  QCheckBox * m_pUseMircServerList;
125 #endif
126 
128  QString m_szServerUrl;
129  QString m_szServerHost;
130  unsigned int m_uServerPort;
131 
134  //KviFileSelector * m_pServerConfigSelector;
136 
137 protected:
138  void makeLink();
139  void setUrlHandlers();
140  virtual void showEvent(QShowEvent * e);
142 public slots:
143  void chooseOldDataPath();
144  void chooseDataPath();
145  void chooseIncomingPath();
146  virtual void accept();
147  virtual void reject();
148 
149  void oldDirClicked();
150  void newDirClicked();
151  void portableClicked();
152 
153  void nickSelectorTextChanged(const QString &);
154  void oldDataTextChanged(const QString &);
155  void newDataTextChanged(const QString &);
156  void newIncomingTextChanged(const QString &);
157 };
158 
159 #endif //_SETUPWIZARD_H_
QLineEdit * m_pOldDataPathEdit
Definition: SetupWizard.h:101
Toolkit Abstraction Layer: hbox class.
Definition: KviTalHBox.h:44
SetupPage * m_pTheme
Definition: SetupWizard.h:76
QRadioButton * m_pThemeLoRes
Definition: SetupWizard.h:84
unsigned int m_uServerPort
Definition: SetupWizard.h:130
QRadioButton * m_pDirUsePrev
Definition: SetupWizard.h:95
void portableClicked()
Definition: SetupWizard.cpp:700
Class for horizontal box.
KviTalGroupBox * m_pDirButtonGroup
Definition: SetupWizard.h:94
SetupPage * m_pDesktopIntegration
Definition: SetupWizard.h:77
Class for vertical box.
Class for groupbox.
~SetupWizard()
Definition: SetupWizard.cpp:604
SetupPage * m_pDirectory
Definition: SetupWizard.h:74
QCheckBox * m_pCreateUrlHandlers
Definition: SetupWizard.h:88
SetupPage(SetupWizard *w)
Definition: SetupWizard.cpp:74
QString m_szServerUrl
Definition: SetupWizard.h:128
KviTalHBox * m_pOldPathBox
Definition: SetupWizard.h:102
KviStringSelector * m_pServerUrlSelector
Definition: SetupWizard.h:133
KviStringSelector * m_pNickSelector
Definition: SetupWizard.h:110
void oldDirClicked()
Definition: SetupWizard.cpp:647
SetupPage * m_pServers
Definition: SetupWizard.h:78
QString m_szServerConfigFile
Definition: SetupWizard.h:127
QGroupBox * m_pThemeButtonGroup
Definition: SetupWizard.h:81
SetupPage * m_pWelcome
Definition: SetupWizard.h:72
#define e
Definition: detector.cpp:69
KviStringSelector * m_pLocationSelector
Definition: SetupWizard.h:112
void makeLink()
Definition: SetupWizard.cpp:779
QComboBox * m_pGenderCombo
Definition: SetupWizard.h:108
void chooseOldDataPath()
Definition: SetupWizard.cpp:716
QLineEdit * m_pDataPathEdit
Definition: SetupWizard.h:92
QComboBox * m_pAgeCombo
Definition: SetupWizard.h:107
QString m_szServerHost
Definition: SetupWizard.h:129
KviUIntSelector * m_pServerPortSelector
Definition: SetupWizard.h:135
QLabel * m_pPixmapLabel
Definition: SetupWizard.h:54
void newDirClicked()
Definition: SetupWizard.cpp:681
QRadioButton * m_pDirUseNew
Definition: SetupWizard.h:96
Definition: KviSelectors.h:78
void nickSelectorTextChanged(const QString &)
Definition: SetupWizard.cpp:642
KviStringSelector * m_pServerHostSelector
Definition: SetupWizard.h:132
void oldDataTextChanged(const QString &)
Definition: SetupWizard.cpp:666
virtual void showEvent(QShowEvent *e)
Definition: SetupWizard.cpp:609
KviTalVBox * m_pVBox
Definition: SetupWizard.h:53
virtual void accept()
Definition: SetupWizard.cpp:952
Toolkit Abstraction Layer: groupbox class.
Definition: KviTalGroupBox.h:43
void chooseIncomingPath()
Definition: SetupWizard.cpp:766
Definition: SetupWizard.h:62
KviTalHBox * m_pNewIncomingBox
Definition: SetupWizard.h:104
Toolkit Abstraction Layer: vbox class.
Definition: KviTalVBox.h:44
SetupPage * m_pLicense
Definition: SetupWizard.h:73
QLabel * m_pTextLabel
Definition: SetupWizard.h:55
#define w
Definition: detector.cpp:87
void newIncomingTextChanged(const QString &)
Definition: SetupWizard.cpp:676
Provides a wizard-style dialog with steps.
Definition: KviTalWizard.h:42
void newDataTextChanged(const QString &)
Definition: SetupWizard.cpp:671
void setUrlHandlers()
Definition: SetupWizard.cpp:879
QRadioButton * m_pThemeHiRes
Definition: SetupWizard.h:83
QLineEdit * m_pIncomingPathEdit
Definition: SetupWizard.h:93
SetupWizard()
Definition: SetupWizard.cpp:131
KviStringSelector * m_pLanguagesSelector
Definition: SetupWizard.h:113
QCheckBox * m_pCreateDesktopShortcut
Definition: SetupWizard.h:89
Definition: SetupWizard.h:45
This file contains compile time settings.
void chooseDataPath()
Definition: SetupWizard.cpp:752
void enableOrDisableIdentityPageNextButton()
Definition: SetupWizard.cpp:637
KviTalHBox * m_pNewPathBox
Definition: SetupWizard.h:103
QRadioButton * m_pThemeNone
Definition: SetupWizard.h:85
KviStringSelector * m_pRealNameSelector
Definition: SetupWizard.h:111
SetupPage * m_pIdentity
Definition: SetupWizard.h:75
Definition: KviSelectors.h:187
virtual void reject()
Definition: SetupWizard.cpp:941
QPixmap * m_pLabelPixmap
Definition: SetupWizard.h:70