comparison view/PaneStack.h @ 867:99373ca20caf alignment_view

First sketch at alignment view (between panes in stack)
author Chris Cannam
date Fri, 17 Oct 2014 14:58:51 +0100
parents 4c8ca536b54f
children 36cddc3de023
comparison
equal deleted inserted replaced
866:d854c72dcaa1 867:99373ca20caf
30 class Pane; 30 class Pane;
31 class Layer; 31 class Layer;
32 class ViewManager; 32 class ViewManager;
33 class PropertyContainer; 33 class PropertyContainer;
34 class PropertyStack; 34 class PropertyStack;
35 class AlignmentView;
35 36
36 class PaneStack : public QFrame 37 class PaneStack : public QFrame
37 { 38 {
38 Q_OBJECT 39 Q_OBJECT
39 40
68 void setLayoutStyle(LayoutStyle style); 69 void setLayoutStyle(LayoutStyle style);
69 70
70 void setPropertyStackMinWidth(int mw); 71 void setPropertyStackMinWidth(int mw);
71 72
72 void setShowPaneAccessories(bool show); // current indicator, close button 73 void setShowPaneAccessories(bool show); // current indicator, close button
74
75 void setShowAlignmentViews(bool show);
73 76
74 void sizePanesEqually(); 77 void sizePanesEqually();
75 78
76 signals: 79 signals:
77 void currentPaneChanged(Pane *pane); 80 void currentPaneChanged(Pane *pane);
110 protected: 113 protected:
111 Pane *m_currentPane; 114 Pane *m_currentPane;
112 115
113 struct PaneRec 116 struct PaneRec
114 { 117 {
115 Pane *pane; 118 Pane *pane;
116 QWidget *propertyStack; 119 QWidget *propertyStack;
117 QPushButton *xButton; 120 QPushButton *xButton;
118 QLabel *currentIndicator; 121 QLabel *currentIndicator;
119 QFrame *frame; 122 QFrame *frame;
120 QGridLayout *layout; 123 QGridLayout *layout;
124 AlignmentView *alignmentView;
121 }; 125 };
122 126
123 std::vector<PaneRec> m_panes; 127 std::vector<PaneRec> m_panes;
124 std::vector<PaneRec> m_hiddenPanes; 128 std::vector<PaneRec> m_hiddenPanes;
125 129
126 bool m_showAccessories; 130 bool m_showAccessories;
131 bool m_showAlignmentViews;
127 132
128 QSplitter *m_splitter; 133 QSplitter *m_splitter;
129 QStackedWidget *m_propertyStackStack; 134 QStackedWidget *m_propertyStackStack;
130 135
131 ViewManager *m_viewManager; // I don't own this 136 ViewManager *m_viewManager; // I don't own this
132 int m_propertyStackMinWidth; 137 int m_propertyStackMinWidth;
133 void sizePropertyStacks(); 138 void sizePropertyStacks();
134 139
135 void showOrHidePaneAccessories(); 140 void showOrHidePaneAccessories();
136 141
142 void unlinkAlignmentViews();
143 void relinkAlignmentViews();
144
137 LayoutStyle m_layoutStyle; 145 LayoutStyle m_layoutStyle;
138 }; 146 };
139 147
140 #endif 148 #endif
141 149