Scribus
Open source desktop publishing at your fingertips
configuration.h
1 /*
2 For general Scribus (>=1.3.2) copyright and licensing information please refer
3 to the COPYING file provided with the program. Following this notice may exist
4 a copyright and/or license notice that predates the release of Scribus 1.3.2
5 for which a new license (GPL+exception) is in place.
6 */
7 #ifndef _SCRIBUS_SHORTCFG_H_
8 #define _SCRIBUS_SHORTCFG_H_
9 
10 #include <QObject>
11 
12 class QString;
13 class QStringList;
14 class PrefsContext;
15 
25 class SWConfig : public QObject
26 {
27  Q_OBJECT
28 
29 public:
31  SWConfig();
33  ~SWConfig(){};
34 
36  uint action;
37  //*! \brief UI checkbox */
38  bool useStyle;
39  QString currentLanguage;
40 
43  QStringList getShortWords(QString lang);
46  static QString getAvailableLanguages();
47  static QStringList getAvailableLanguagesList();
48 
50  void saveConfig();
51 
52 private:
54  PrefsContext* prefs;
59  QStringList getShortWordsFromFile(QString lang, QString filename);
63  static QStringList getAvailableLanguageCodes(QString filename);
66  static QStringList getLanguageStringsFromCodes(QStringList codes);
67 };
68 
69 #endif
uint action
Id of the UI radiobutton.
Definition: configuration.h:33
QStringList getShortWords(QString lang)
Returns all options for specified language.
Definition: configuration.cpp:90
~SWConfig()
Writes config into the ui cfg file.
Definition: configuration.h:33
static QString getAvailableLanguages()
available configs for UI about.
Definition: configuration.cpp:131
void saveConfig()
Save cfg.
Definition: configuration.cpp:45
Definition: prefscontext.h:40
SWConfig()
Reads config from the ui cfg file.
Definition: configuration.cpp:35
This is the Scribus Short Words configuratin specification. Methods of this class read config files a...
Definition: configuration.h:25