Commit 6a16b4fd authored by Matthew Andrew's avatar Matthew Andrew
Browse files

Updated IqtFit tab to new layout

parent 03177055
......@@ -250,7 +250,6 @@ set(
IndirectTransmission.ui
IndirectTransmissionCalc.ui
Iqt.ui
IqtFit.ui
JumpFit.ui
JumpFitAddWorkspaceDialog.ui
MSDFit.ui
......@@ -545,7 +544,6 @@ set(
IndirectTransmission.ui
IndirectTransmissionCalc.ui
Iqt.ui
IqtFit.ui
JumpFit.ui
JumpFitAddWorkspaceDialog.ui
MSDFit.ui
......
......@@ -6,6 +6,7 @@
// SPDX - License - Identifier: GPL - 3.0 +
#include "IqtFit.h"
#include "IndirectFunctionBrowser/IqtTemplateBrowser.h"
#include "IndirectFitPlotView.h"
#include "MantidQtWidgets/Common/UserInputValidator.h"
......@@ -34,20 +35,31 @@ namespace IDA {
IqtFit::IqtFit(QWidget *parent)
: IndirectFitAnalysisTab(new IqtFitModel, parent),
m_uiForm(new Ui::IqtFit) {
m_uiForm(new Ui::ConvFit) {
m_uiForm->setupUi(parent);
m_fitPropertyBrowser = new IndirectFitPropertyBrowser();
QDockWidget *plotViewArea = new QDockWidget();
IndirectFitPlotView *fitPlotView = new IndirectFitPlotView();
plotViewArea->setWidget(fitPlotView);
plotViewArea->setFeatures(QDockWidget::DockWidgetFloatable);
m_uiForm->dockArea->addDockWidget(Qt::BottomDockWidgetArea,
m_fitPropertyBrowser);
m_uiForm->dockArea->addDockWidget(Qt::BottomDockWidgetArea, plotViewArea);
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
m_uiForm->dockArea->resizeDocks({m_fitPropertyBrowser, plotViewArea},
{20, 20}, Qt::Horizontal);
#endif
m_iqtFittingModel = dynamic_cast<IqtFitModel *>(fittingModel());
setFitDataPresenter(std::make_unique<IndirectFitDataPresenter>(
m_iqtFittingModel, m_uiForm->fitDataView));
setPlotView(m_uiForm->pvFitPlotView);
m_iqtFittingModel, m_uiForm->dockArea->m_uiForm->centralwidget));
setPlotView(fitPlotView);
setSpectrumSelectionView(m_uiForm->svSpectrumView);
setOutputOptionsView(m_uiForm->ovOutputOptionsView);
auto templateBrowser = new IqtTemplateBrowser;
m_uiForm->fitPropertyBrowser->setFunctionTemplateBrowser(templateBrowser);
setFitPropertyBrowser(m_uiForm->fitPropertyBrowser);
m_fitPropertyBrowser->setFunctionTemplateBrowser(templateBrowser);
setFitPropertyBrowser(m_fitPropertyBrowser);
setEditResultVisible(true);
setStartAndEndHidden(false);
}
void IqtFit::setupFitTab() {
......
......@@ -11,7 +11,7 @@
#include "MantidAPI/CompositeFunction.h"
#include "MantidAPI/MatrixWorkspace_fwd.h"
#include "ui_IqtFit.h"
#include "ui_ConvFit.h"
#include <memory>
......
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>IqtFit</class>
<widget class="QWidget" name="IqtFit">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>799</width>
<height>741</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QSplitter" name="splitter">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="childrenCollapsible">
<bool>false</bool>
</property>
<widget class="MantidQt::CustomInterfaces::IDA::IndirectFitDataView" name="fitDataView" native="true"/>
<widget class="QWidget" name="layoutWidget">
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<layout class="QHBoxLayout" name="loPlotArea" stretch="1,1">
<property name="leftMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<item>
<widget class="MantidQt::CustomInterfaces::IDA::IndirectFitPropertyBrowser" name="fitPropertyBrowser">
<widget class="QWidget" name="dockWidgetContents"/>
</widget>
</item>
<item>
<widget class="MantidQt::CustomInterfaces::IDA::IndirectFitPlotView" name="pvFitPlotView" native="true"/>
</item>
</layout>
</item>
<item>
<widget class="QFrame" name="frame">
<layout class="QVBoxLayout" name="verticalLayout_3">
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="MantidQt::CustomInterfaces::IDA::IndirectSpectrumSelectionView" name="svSpectrumView" native="true"/>
</item>
<item>
<widget class="QGroupBox" name="gbRun">
<property name="title">
<string>Run</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="topMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>7</number>
</property>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="pbRun">
<property name="text">
<string>Run</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<widget class="MantidQt::CustomInterfaces::IDA::IndirectFitOutputOptionsView" name="ovOutputOptionsView" native="true"/>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>MantidQt::CustomInterfaces::IDA::IndirectSpectrumSelectionView</class>
<extends>QWidget</extends>
<header>IndirectSpectrumSelectionView.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>MantidQt::CustomInterfaces::IDA::IndirectFitPropertyBrowser</class>
<extends>QDockWidget</extends>
<header>IndirectFitPropertyBrowser.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>MantidQt::CustomInterfaces::IDA::IndirectFitPlotView</class>
<extends>QWidget</extends>
<header>IndirectFitPlotView.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>MantidQt::CustomInterfaces::IDA::IndirectFitDataView</class>
<extends>QWidget</extends>
<header>IndirectFitDataView.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>MantidQt::CustomInterfaces::IDA::IndirectFitOutputOptionsView</class>
<extends>QWidget</extends>
<header>IndirectFitOutputOptionsView.h</header>
<container>1</container>
</customwidget>
</customwidgets>
<resources/>
<connections/>
</ui>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment