MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / toggleMirrorView

Method toggleMirrorView

src/openms_gui/source/VISUAL/Plot1DWidget.cpp:135–161  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133 }
134
135 void Plot1DWidget::toggleMirrorView(bool mirror)
136 {
137 if (mirror)
138 {
139 grid_->addItem(spacer_, 1, 1);
140 grid_->addWidget(flipped_y_axis_, 2, 1);
141 grid_->removeWidget(canvas());
142 grid_->removeWidget(x_axis_);
143 grid_->removeWidget(x_scrollbar_);
144 grid_->addWidget(canvas(), 0, 2, 3, 1); // rowspan = 3
145 grid_->addWidget(x_axis_, 3, 2);
146 grid_->addWidget(x_scrollbar_, 4, 2);
147 flipped_y_axis_->show();
148 }
149 else
150 {
151 grid_->removeWidget(canvas());
152 grid_->removeWidget(flipped_y_axis_);
153 flipped_y_axis_->hide();
154 grid_->removeItem(spacer_);
155 grid_->removeWidget(x_axis_);
156 grid_->removeWidget(x_scrollbar_);
157 grid_->addWidget(canvas(), 0, 2);
158 grid_->addWidget(x_axis_, 1, 2);
159 grid_->addWidget(x_scrollbar_, 2, 2);
160 }
161 }
162
163 void Plot1DWidget::performAlignment(Size layer_index_1, Size layer_index_2, const Param& param)
164 {

Callers 1

setMirrorModeActiveMethod · 0.80

Calls 2

showMethod · 0.80
canvasFunction · 0.50

Tested by

no test coverage detected