OSDN Git Service

upgrade to 3.6.1
[jnethack/source.git] / win / Qt4 / qt4set.h
1 // Copyright (c) Warwick Allison, 1999.
2 // Qt4 conversion copyright (c) Ray Chason, 2012-2014.
3 // NetHack may be freely redistributed.  See license for details.
4
5 // qt4set.h -- the Qt settings
6
7 #ifndef QT4SET_H
8 #define QT4SET_H
9
10 namespace nethack_qt4 {
11
12 class NetHackQtGlyphs;
13
14 class NetHackQtSettings : public QDialog {
15         Q_OBJECT
16 public:
17         // Size of window - used to decide default sizes
18         NetHackQtSettings(int width, int height);
19
20         NetHackQtGlyphs& glyphs();
21         const QFont& normalFont();
22         const QFont& normalFixedFont();
23         const QFont& largeFont();
24
25         bool ynInMessages();
26
27 signals:
28         void fontChanged();
29         void tilesChanged();
30
31 public slots:
32         void toggleGlyphSize();
33         void setGlyphSize(bool);
34
35 private:
36         QSpinBox tilewidth;
37         QSpinBox tileheight;
38         QLabel widthlbl;
39         QLabel heightlbl;
40         QCheckBox whichsize;
41         QSize othersize;
42
43         QComboBox fontsize;
44
45         QFont normal, normalfixed, large;
46
47         NetHackQtGlyphs* theglyphs;
48
49 private slots:
50         void resizeTiles();
51 };
52
53 extern NetHackQtSettings* qt_settings;
54
55 } // namespace nethack_qt4
56
57 #endif