All Classes Namespaces Functions Variables Enumerations Properties Pages
displayoptionwidget.h
1 /*
2 
3 Pencil2D - Traditional Animation Software
4 Copyright (C) 2012-2020 Matthew Chiawen Chang
5 
6 This program is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public License
8 as published by the Free Software Foundation; version 2 of the License.
9 
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14 
15 */
16 
17 #ifndef DISPLAYOPTIONDOCKWIDGET_H
18 #define DISPLAYOPTIONDOCKWIDGET_H
19 
20 #include "basedockwidget.h"
21 
22 namespace Ui
23 {
24  class DisplayOption;
25 }
26 class Editor;
27 class QToolButton;
28 class ViewManager;
29 
31 {
32  Q_OBJECT
33 public:
35  virtual ~DisplayOptionWidget() override;
36 
37  void initUI() override;
38  void updateUI() override;
39 
40 protected:
41  int getMinHeightForWidth(int width) override;
42 
43 private slots:
44  void toggleMirror(bool);
45  void toggleMirrorV(bool);
46  void toggleOverlayCenter(bool isOn);
47  void toggleOverlayThirds(bool isOn);
48  void toggleOverlayGoldenRatio(bool isOn);
49  void toggleOverlaySafeAreas(bool isOn);
50 
51 private:
52  void makeConnections();
53  Ui::DisplayOption* ui = nullptr;
54 };
55 
56 #endif // DISPLAYOPTIONDOCKWIDGET_H
int width() const const
Q_OBJECTQ_OBJECT
Definition: editor.h:51
QObject * parent() const const