resize works

git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui@2 af1100a4-978c-4157-bff7-07162d2ba061
This commit is contained in:
l_maliakal_d
2012-05-23 16:00:35 +00:00
parent 9f851d6156
commit 934bbbd0c8
21 changed files with 1858 additions and 619 deletions

View File

@ -9,12 +9,12 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>1000</width> <width>800</width>
<height>956</height> <height>822</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
@ -44,7 +44,7 @@
</property> </property>
<widget class="QWidget" name="centralwidget"> <widget class="QWidget" name="centralwidget">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
@ -52,13 +52,13 @@
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>0</width> <width>0</width>
<height>470</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>1000</width> <width>1000</width>
<height>470</height> <height>1000</height>
</size> </size>
</property> </property>
<widget class="QWidget" name="gridLayoutWidget"> <widget class="QWidget" name="gridLayoutWidget">
@ -66,8 +66,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>953</width> <width>754</width>
<height>470</height> <height>368</height>
</rect> </rect>
</property> </property>
<layout class="QGridLayout" name="layoutTabs"/> <layout class="QGridLayout" name="layoutTabs"/>
@ -78,7 +78,7 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>1000</width> <width>800</width>
<height>25</height> <height>25</height>
</rect> </rect>
</property> </property>
@ -135,23 +135,60 @@
</widget> </widget>
<widget class="QDockWidget" name="dockWidgetTerminal"> <widget class="QDockWidget" name="dockWidgetTerminal">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Preferred"> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>40</width> <width>38</width>
<height>54</height> <height>369</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>524287</width> <width>524287</width>
<height>470</height> <height>524287</height>
</size> </size>
</property> </property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>119</red>
<green>119</green>
<blue>119</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="font"> <property name="font">
<font> <font>
<pointsize>11</pointsize> <pointsize>11</pointsize>
@ -166,7 +203,7 @@
<bool>false</bool> <bool>false</bool>
</property> </property>
<property name="features"> <property name="features">
<set>QDockWidget::DockWidgetFloatable|QDockWidget::DockWidgetMovable|QDockWidget::DockWidgetVerticalTitleBar</set> <set>QDockWidget::DockWidgetVerticalTitleBar</set>
</property> </property>
<property name="allowedAreas"> <property name="allowedAreas">
<set>Qt::BottomDockWidgetArea|Qt::RightDockWidgetArea</set> <set>Qt::BottomDockWidgetArea|Qt::RightDockWidgetArea</set>
@ -178,6 +215,43 @@
<number>2</number> <number>2</number>
</attribute> </attribute>
<widget class="QWidget" name="dockWidgetContentsTerminal"> <widget class="QWidget" name="dockWidgetContentsTerminal">
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>119</red>
<green>119</green>
<blue>119</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="font"> <property name="font">
<font> <font>
<pointsize>9</pointsize> <pointsize>9</pointsize>
@ -189,15 +263,15 @@
</widget> </widget>
<widget class="QDockWidget" name="dockWidgetPlot"> <widget class="QDockWidget" name="dockWidgetPlot">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>58</width> <width>36</width>
<height>455</height> <height>422</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
@ -206,16 +280,53 @@
<height>524287</height> <height>524287</height>
</size> </size>
</property> </property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>119</red>
<green>119</green>
<blue>119</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="font"> <property name="font">
<font> <font>
<family>Sans Serif</family> <family>Sans Serif</family>
<pointsize>11</pointsize> <pointsize>11</pointsize>
<weight>75</weight> <weight>50</weight>
<bold>true</bold> <bold>false</bold>
</font> </font>
</property> </property>
<property name="features"> <property name="features">
<set>QDockWidget::DockWidgetMovable</set> <set>QDockWidget::NoDockWidgetFeatures</set>
</property> </property>
<property name="allowedAreas"> <property name="allowedAreas">
<set>Qt::BottomDockWidgetArea</set> <set>Qt::BottomDockWidgetArea</set>
@ -228,7 +339,7 @@
</attribute> </attribute>
<widget class="QWidget" name="dockWidgetContentsPlot"> <widget class="QWidget" name="dockWidgetContentsPlot">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
@ -236,7 +347,7 @@
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>0</width> <width>0</width>
<height>429</height> <height>400</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
@ -245,49 +356,50 @@
<height>16777215</height> <height>16777215</height>
</size> </size>
</property> </property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>119</red>
<green>119</green>
<blue>119</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="font"> <property name="font">
<font> <font>
<pointsize>9</pointsize> <pointsize>9</pointsize>
<weight>50</weight> <weight>75</weight>
<bold>false</bold> <bold>true</bold>
</font> </font>
</property> </property>
<widget class="QFrame" name="framePlot">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>1000</width>
<height>431</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<property name="lineWidth">
<number>1</number>
</property>
</widget>
</widget> </widget>
</widget> </widget>
<action name="actionOpenSetup"> <action name="actionOpenSetup">
@ -390,7 +502,7 @@
<bool>true</bool> <bool>true</bool>
</property> </property>
<property name="text"> <property name="text">
<string>&amp;Dockable Plot</string> <string>&amp;Dockable Windows</string>
</property> </property>
</action> </action>
</widget> </widget>

View File

@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>1000</width> <width>800</width>
<height>435</height> <height>400</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy"> <property name="sizePolicy">
@ -16,16 +16,22 @@
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="windowTitle"> <property name="windowTitle">
<string>Form</string> <string>Form</string>
</property> </property>
<widget class="QGroupBox" name="boxPlot"> <widget class="QGroupBox" name="boxPlot">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>3</x> <x>0</x>
<y>-2</y> <y>-2</y>
<width>1000</width> <width>795</width>
<height>435</height> <height>400</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy"> <property name="sizePolicy">
@ -54,8 +60,8 @@
<rect> <rect>
<x>-3</x> <x>-3</x>
<y>16</y> <y>16</y>
<width>1001</width> <width>788</width>
<height>421</height> <height>383</height>
</rect> </rect>
</property> </property>
<layout class="QGridLayout" name="plotLayout"> <layout class="QGridLayout" name="plotLayout">

View File

@ -6,20 +6,26 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>952</width> <width>748</width>
<height>445</height> <height>339</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>952</width> <width>0</width>
<height>445</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>445</height> <height>1000</height>
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">

View File

@ -6,20 +6,26 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>952</width> <width>748</width>
<height>445</height> <height>339</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>952</width> <width>0</width>
<height>445</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>445</height> <height>1000</height>
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -28,8 +34,8 @@
<widget class="QPushButton" name="pushButton"> <widget class="QPushButton" name="pushButton">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>3</x> <x>69</x>
<y>412</y> <y>229</y>
<width>75</width> <width>75</width>
<height>25</height> <height>25</height>
</rect> </rect>
@ -41,8 +47,8 @@
<widget class="QPushButton" name="btnTemp"> <widget class="QPushButton" name="btnTemp">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>626</x> <x>52</x>
<y>8</y> <y>106</y>
<width>91</width> <width>91</width>
<height>41</height> <height>41</height>
</rect> </rect>
@ -61,8 +67,8 @@ Temperature</string>
<widget class="QLineEdit" name="dispTempFpga"> <widget class="QLineEdit" name="dispTempFpga">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>796</x> <x>222</x>
<y>34</y> <y>132</y>
<width>151</width> <width>151</width>
<height>21</height> <height>21</height>
</rect> </rect>
@ -84,8 +90,8 @@ Temperature</string>
<widget class="QLabel" name="label_10"> <widget class="QLabel" name="label_10">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>736</x> <x>162</x>
<y>4</y> <y>102</y>
<width>41</width> <width>41</width>
<height>20</height> <height>20</height>
</rect> </rect>
@ -97,8 +103,8 @@ Temperature</string>
<widget class="QLabel" name="label_11"> <widget class="QLabel" name="label_11">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>736</x> <x>162</x>
<y>34</y> <y>132</y>
<width>41</width> <width>41</width>
<height>20</height> <height>20</height>
</rect> </rect>
@ -110,8 +116,8 @@ Temperature</string>
<widget class="QLineEdit" name="dispTempAdc"> <widget class="QLineEdit" name="dispTempAdc">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>796</x> <x>222</x>
<y>4</y> <y>102</y>
<width>151</width> <width>151</width>
<height>21</height> <height>21</height>
</rect> </rect>

View File

@ -6,10 +6,16 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>900</width> <width>748</width>
<height>400</height> <height>339</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>0</width> <width>0</width>
@ -18,7 +24,7 @@
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>1000</height> <height>1000</height>
</size> </size>
</property> </property>

View File

@ -6,20 +6,26 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>952</width> <width>748</width>
<height>445</height> <height>350</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>952</width> <width>0</width>
<height>445</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>445</height> <height>1000</height>
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">

View File

@ -6,20 +6,26 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>952</width> <width>748</width>
<height>445</height> <height>339</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>952</width> <width>0</width>
<height>445</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>445</height> <height>1000</height>
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">

View File

@ -6,10 +6,16 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>900</width> <width>734</width>
<height>400</height> <height>339</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>0</width> <width>0</width>
@ -18,105 +24,153 @@
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>500</height> <height>1000</height>
</size> </size>
</property> </property>
<property name="palette">
<palette>
<active>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
<colorrole role="Text">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
<colorrole role="ButtonText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
<colorrole role="Shadow">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</active>
<inactive>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
<colorrole role="Text">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
<colorrole role="ButtonText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
<colorrole role="Shadow">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>0</red>
<green>0</green>
<blue>0</blue>
</color>
</brush>
</colorrole>
</inactive>
<disabled>
<colorrole role="WindowText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>193</red>
<green>193</green>
<blue>193</blue>
</color>
</brush>
</colorrole>
<colorrole role="Text">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>188</red>
<green>188</green>
<blue>188</blue>
</color>
</brush>
</colorrole>
<colorrole role="ButtonText">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>192</red>
<green>192</green>
<blue>192</blue>
</color>
</brush>
</colorrole>
<colorrole role="Shadow">
<brush brushstyle="SolidPattern">
<color alpha="255">
<red>189</red>
<green>189</green>
<blue>189</blue>
</color>
</brush>
</colorrole>
</disabled>
</palette>
</property>
<property name="windowTitle"> <property name="windowTitle">
<string>Form</string> <string>Form</string>
</property> </property>
<widget class="QWidget" name="gridLayoutWidget"> <widget class="QWidget" name="gridLayoutWidget_3">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>9</x> <x>20</x>
<y>30</y> <y>20</y>
<width>420</width> <width>321</width>
<height>355</height> <height>117</height>
</rect> </rect>
</property> </property>
<layout class="QGridLayout" name="gridLayout"> <layout class="QGridLayout" name="gridLayout">
<item row="0" column="1" colspan="2"> <property name="verticalSpacing">
<widget class="QComboBox" name="comboSettings"> <number>-1</number>
<property name="sizePolicy"> </property>
<sizepolicy hsizetype="Preferred" vsizetype="Maximum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Settings of the detector.
#settings#</string>
</property>
<item>
<property name="text">
<string>Standard</string>
</property>
</item>
<item>
<property name="text">
<string>Fast</string>
</property>
</item>
<item>
<property name="text">
<string>High Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Dynamic Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Low Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Medium Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Very High Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Undefined</string>
</property>
</item>
<item>
<property name="text">
<string>Uninitialized</string>
</property>
</item>
</widget>
</item>
<item row="0" column="0"> <item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Settings:</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_5"> <widget class="QLabel" name="label_5">
<property name="text"> <property name="text">
<string>Number of measurements:</string> <string>Number of Measurements:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="2" column="0"> <item row="0" column="1">
<widget class="QLabel" name="label_6"> <widget class="QSpinBox" name="spinNumMeasurements">
<property name="text">
<string>Acquisition Time:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QDoubleSpinBox" name="spinExpTime">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
@ -124,21 +178,189 @@
</sizepolicy> </sizepolicy>
</property> </property>
<property name="toolTip"> <property name="toolTip">
<string>Exposure time of each frame. <string>Number of measurements (not in real time) that will be acquired.
#exptime#</string> #frames#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
<property name="value">
<number>1</number>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>File Name:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="dispFileName">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Root of the file name - please check that the output directory is correctly set and select the file name format.
#fname#</string>
</property>
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_8">
<property name="text">
<string>Run Index:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QSpinBox" name="spinIndex">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Run index (automatically incremented)
#index#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>0</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
<property name="value">
<number>0</number>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="gridLayoutWidget">
<property name="geometry">
<rect>
<x>390</x>
<y>20</y>
<width>322</width>
<height>312</height>
</rect>
</property>
<layout class="QGridLayout" name="gridTimeResolved">
<item row="4" column="0">
<widget class="QLabel" name="lblNumTriggers">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string>Number of Triggers:</string>
</property>
</widget>
</item>
<item row="4" column="2" colspan="2">
<widget class="QSpinBox" name="spinNumTriggers">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Run index (automatically incremented)
#index#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>0</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
<property name="value">
<number>0</number>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="lblDelay">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string>Delay After Trigger:</string>
</property>
</widget>
</item>
<item row="5" column="2">
<widget class="QDoubleSpinBox" name="spinDelay">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Frame period between exposures.
#period#</string>
</property> </property>
<property name="maximum"> <property name="maximum">
<double>2000000000.000000000000000</double> <double>2000000000.000000000000000</double>
</property> </property>
<property name="value"> <property name="value">
<double>1.000000000000000</double> <double>0.000000000000000</double>
</property> </property>
</widget> </widget>
</item> </item>
<item row="2" column="2"> <item row="5" column="3">
<widget class="QComboBox" name="comboExpUnit"> <widget class="QComboBox" name="comboDelayUnit">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
@ -178,8 +400,27 @@
</item> </item>
</widget> </widget>
</item> </item>
<item row="3" column="1"> <item row="6" column="0">
<widget class="QDoubleSpinBox" name="spinPeriod"> <widget class="QLabel" name="lblNumGates">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Number of Gates:</string>
</property>
</widget>
</item>
<item row="6" column="2" colspan="2">
<widget class="QSpinBox" name="spinNumGates">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
@ -187,19 +428,230 @@
</sizepolicy> </sizepolicy>
</property> </property>
<property name="toolTip"> <property name="toolTip">
<string>Frame period between exposures. <string>Run index (automatically incremented)
#period#</string> #index#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>0</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
<property name="value">
<number>0</number>
</property>
</widget>
</item>
<item row="7" column="0">
<widget class="QLabel" name="lblNumProbes">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Number of Probes:</string>
</property>
</widget>
</item>
<item row="7" column="2" colspan="2">
<widget class="QSpinBox" name="spinNumProbes">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Run index (automatically incremented)
#index#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>0</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
<property name="value">
<number>0</number>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Timing Mode:</string>
</property>
</widget>
</item>
<item row="0" column="2" colspan="2">
<widget class="QComboBox" name="comboTimingMode">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Settings of the detector.
#settings#</string>
</property>
<item>
<property name="text">
<string>None</string>
</property>
</item>
<item>
<property name="text">
<string>Auto</string>
</property>
</item>
<item>
<property name="text">
<string>Gated</string>
</property>
</item>
<item>
<property name="text">
<string>Trigger Exposure</string>
</property>
</item>
<item>
<property name="text">
<string>Trigger Frame</string>
</property>
</item>
<item>
<property name="text">
<string>Trigger Readout</string>
</property>
</item>
<item>
<property name="text">
<string>Gated with Start Trigger</string>
</property>
</item>
<item>
<property name="text">
<string>External Trigger Window</string>
</property>
</item>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="lblNumFrames">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string>Number of Frames:</string>
</property>
</widget>
</item>
<item row="1" column="2" colspan="2">
<widget class="QSpinBox" name="spinNumFrames">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Number of measurements (not in real time) that will be acquired.
#frames#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
<property name="value">
<number>1</number>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="lblExpTime">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string>Exposure Time:</string>
</property>
</widget>
</item>
<item row="2" column="2">
<widget class="QDoubleSpinBox" name="spinExpTime">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Exposure time of each frame.
#exptime#</string>
</property> </property>
<property name="maximum"> <property name="maximum">
<double>2000000000.000000000000000</double> <double>2000000000.000000000000000</double>
</property> </property>
<property name="value"> <property name="value">
<double>2.000000000000000</double> <double>0.000000000000000</double>
</property> </property>
</widget> </widget>
</item> </item>
<item row="3" column="2"> <item row="2" column="3">
<widget class="QComboBox" name="comboPeriodUnit"> <widget class="QComboBox" name="comboExpUnit">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="currentIndex"> <property name="currentIndex">
<number>2</number> <number>2</number>
</property> </property>
@ -236,110 +688,188 @@
</widget> </widget>
</item> </item>
<item row="3" column="0"> <item row="3" column="0">
<widget class="QLabel" name="label_9"> <widget class="QLabel" name="lblPeriod">
<property name="text"> <property name="enabled">
<string>Frame Period:</string> <bool>false</bool>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>File Name:</string>
</property>
</widget>
</item>
<item row="4" column="1" colspan="2">
<widget class="QLineEdit" name="dispFileName">
<property name="toolTip">
<string>Root of the file name - please check that the output directory is correctly set and select the file name format.
#fname#</string>
</property> </property>
<property name="text"> <property name="text">
<string>run</string> <string>Acquisition Period:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="5" column="0"> <item row="3" column="2">
<widget class="QLabel" name="label_8"> <widget class="QDoubleSpinBox" name="spinPeriod">
<property name="text"> <property name="enabled">
<string>Run Index:</string> <bool>false</bool>
</property> </property>
</widget>
</item>
<item row="5" column="1" colspan="2">
<widget class="QSpinBox" name="spinIndex">
<property name="toolTip">
<string>Run index (automatically incremented)
#index#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>0</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
<property name="value">
<number>0</number>
</property>
</widget>
</item>
<item row="6" column="0" colspan="3">
<widget class="QPushButton" name="btnStartStop">
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Starts Acquisition</string>
</property>
<property name="text">
<string>Start</string>
</property>
</widget>
</item>
<item row="1" column="1" colspan="2">
<widget class="QSpinBox" name="spinNumMeasurements">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="toolTip"> <property name="toolTip">
<string>Number of measurements (not in real time) that will be acquired. <string>Frame period between exposures.
#frames#</string> #period#</string>
</property>
<property name="statusTip">
<string/>
</property>
<property name="whatsThis">
<string/>
</property>
<property name="suffix">
<string/>
</property>
<property name="minimum">
<number>1</number>
</property> </property>
<property name="maximum"> <property name="maximum">
<number>2000000000</number> <double>2000000000.000000000000000</double>
</property> </property>
<property name="value"> <property name="value">
<number>2000</number> <double>0.000000000000000</double>
</property> </property>
</widget> </widget>
</item> </item>
<item row="3" column="3">
<widget class="QComboBox" name="comboPeriodUnit">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="currentIndex">
<number>2</number>
</property>
<item>
<property name="text">
<string>hr</string>
</property>
</item>
<item>
<property name="text">
<string>min</string>
</property>
</item>
<item>
<property name="text">
<string>s</string>
</property>
</item>
<item>
<property name="text">
<string>ms</string>
</property>
</item>
<item>
<property name="text">
<string>us</string>
</property>
</item>
<item>
<property name="text">
<string>ns</string>
</property>
</item>
</widget>
</item>
<item row="1" column="1">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>10</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout> </layout>
</widget> </widget>
<widget class="QGroupBox" name="boxProgress">
<property name="geometry">
<rect>
<x>20</x>
<y>150</y>
<width>319</width>
<height>90</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="title">
<string>Progress Monitor</string>
</property>
<property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property>
<widget class="QProgressBar" name="progressBar">
<property name="geometry">
<rect>
<x>10</x>
<y>50</y>
<width>300</width>
<height>23</height>
</rect>
</property>
<property name="value">
<number>24</number>
</property>
</widget>
<widget class="QLabel" name="label">
<property name="geometry">
<rect>
<x>10</x>
<y>30</y>
<width>91</width>
<height>16</height>
</rect>
</property>
<property name="text">
<string>Current Index: </string>
</property>
</widget>
<widget class="QLabel" name="lblProgressIndex">
<property name="geometry">
<rect>
<x>100</x>
<y>31</y>
<width>101</width>
<height>16</height>
</rect>
</property>
<property name="text">
<string>0</string>
</property>
</widget>
</widget>
<widget class="QPushButton" name="btnStartStop">
<property name="geometry">
<rect>
<x>20</x>
<y>280</y>
<width>319</width>
<height>31</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="focusPolicy">
<enum>Qt::NoFocus</enum>
</property>
<property name="toolTip">
<string>Starts Acquisition</string>
</property>
<property name="text">
<string>Start</string>
</property>
</widget>
</widget> </widget>
<resources/> <resources/>
<connections/> <connections/>

View File

@ -6,20 +6,20 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>952</width> <width>748</width>
<height>445</height> <height>339</height>
</rect> </rect>
</property> </property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>952</width> <width>0</width>
<height>445</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>445</height> <height>1000</height>
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -29,24 +29,30 @@
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>250</y> <y>180</y>
<width>571</width> <width>731</width>
<height>151</height> <height>151</height>
</rect> </rect>
</property> </property>
<property name="title"> <property name="title">
<string>Plot Axis</string> <string>Plot Axis</string>
</property> </property>
<property name="flat">
<bool>false</bool>
</property>
<widget class="QWidget" name="gridLayoutWidget"> <widget class="QWidget" name="gridLayoutWidget">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>20</y> <y>20</y>
<width>551</width> <width>712</width>
<height>121</height> <height>121</height>
</rect> </rect>
</property> </property>
<layout class="QGridLayout" name="gridLayout"> <layout class="QGridLayout" name="gridLayout" columnstretch="0,0,0,0,0,0,0,0">
<property name="sizeConstraint">
<enum>QLayout::SetNoConstraint</enum>
</property>
<item row="1" column="0"> <item row="1" column="0">
<widget class="QCheckBox" name="chkXAxis"> <widget class="QCheckBox" name="chkXAxis">
<property name="text"> <property name="text">
@ -54,18 +60,44 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="1"> <item row="1" column="1" colspan="2">
<widget class="QLineEdit" name="dispXAxis"/> <widget class="QLineEdit" name="dispXAxis">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>2</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item> </item>
<item row="1" column="3"> <item row="1" column="3">
<widget class="QCheckBox" name="chkXMin"> <widget class="QCheckBox" name="chkXMin">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text"> <property name="text">
<string>X min:</string> <string>X min:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="4"> <item row="1" column="4">
<widget class="QLineEdit" name="dispXMin"/> <widget class="QLineEdit" name="dispXMin">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>20</width>
<height>0</height>
</size>
</property>
</widget>
</item> </item>
<item row="1" column="6"> <item row="1" column="6">
<widget class="QCheckBox" name="chkXMax"> <widget class="QCheckBox" name="chkXMax">
@ -75,7 +107,14 @@
</widget> </widget>
</item> </item>
<item row="1" column="7"> <item row="1" column="7">
<widget class="QLineEdit" name="dispXMax"/> <widget class="QLineEdit" name="dispXMax">
<property name="sizePolicy">
<sizepolicy hsizetype="Maximum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item> </item>
<item row="2" column="0"> <item row="2" column="0">
<widget class="QCheckBox" name="chkYAxis"> <widget class="QCheckBox" name="chkYAxis">
@ -84,18 +123,44 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="2" column="1"> <item row="2" column="1" colspan="2">
<widget class="QLineEdit" name="dispYAxis"/> <widget class="QLineEdit" name="dispYAxis">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>2</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item> </item>
<item row="2" column="3"> <item row="2" column="3">
<widget class="QCheckBox" name="chkYMin"> <widget class="QCheckBox" name="chkYMin">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text"> <property name="text">
<string>Y min:</string> <string>Y min:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="2" column="4"> <item row="2" column="4">
<widget class="QLineEdit" name="dispYMin"/> <widget class="QLineEdit" name="dispYMin">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>20</width>
<height>0</height>
</size>
</property>
</widget>
</item> </item>
<item row="2" column="6"> <item row="2" column="6">
<widget class="QCheckBox" name="chkYMax"> <widget class="QCheckBox" name="chkYMax">
@ -105,7 +170,14 @@
</widget> </widget>
</item> </item>
<item row="2" column="7"> <item row="2" column="7">
<widget class="QLineEdit" name="dispYMax"/> <widget class="QLineEdit" name="dispYMax">
<property name="sizePolicy">
<sizepolicy hsizetype="Maximum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item> </item>
<item row="3" column="0"> <item row="3" column="0">
<widget class="QCheckBox" name="chkZAxis"> <widget class="QCheckBox" name="chkZAxis">
@ -114,18 +186,37 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="3" column="1"> <item row="3" column="1" colspan="2">
<widget class="QLineEdit" name="dispZAxis"/> <widget class="QLineEdit" name="dispZAxis"/>
</item> </item>
<item row="3" column="3"> <item row="3" column="3">
<widget class="QCheckBox" name="chkZMin"> <widget class="QCheckBox" name="chkZMin">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text"> <property name="text">
<string>Z min:</string> <string>Z min:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="3" column="4"> <item row="3" column="4">
<widget class="QLineEdit" name="dispZMin"/> <widget class="QLineEdit" name="dispZMin">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>20</width>
<height>0</height>
</size>
</property>
</widget>
</item> </item>
<item row="3" column="6"> <item row="3" column="6">
<widget class="QCheckBox" name="chkZMax"> <widget class="QCheckBox" name="chkZMax">
@ -135,20 +226,20 @@
</widget> </widget>
</item> </item>
<item row="3" column="7"> <item row="3" column="7">
<widget class="QLineEdit" name="dispZMax"/> <widget class="QLineEdit" name="dispZMax">
</item> <property name="sizePolicy">
<item row="1" column="2"> <sizepolicy hsizetype="Maximum" vsizetype="Fixed">
<spacer name="horizontalSpacer"> <horstretch>0</horstretch>
<property name="orientation"> <verstretch>0</verstretch>
<enum>Qt::Horizontal</enum> </sizepolicy>
</property> </property>
<property name="sizeHint" stdset="0"> <property name="minimumSize">
<size> <size>
<width>60</width> <width>0</width>
<height>20</height> <height>0</height>
</size> </size>
</property> </property>
</spacer> </widget>
</item> </item>
<item row="1" column="5"> <item row="1" column="5">
<spacer name="horizontalSpacer_2"> <spacer name="horizontalSpacer_2">
@ -157,7 +248,7 @@
</property> </property>
<property name="sizeHint" stdset="0"> <property name="sizeHint" stdset="0">
<size> <size>
<width>60</width> <width>20</width>
<height>20</height> <height>20</height>
</size> </size>
</property> </property>
@ -180,7 +271,7 @@
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>170</y> <y>100</y>
<width>571</width> <width>571</width>
<height>61</height> <height>61</height>
</rect> </rect>
@ -188,48 +279,19 @@
<property name="title"> <property name="title">
<string>2D Plot Options</string> <string>2D Plot Options</string>
</property> </property>
<property name="flat">
<bool>false</bool>
</property>
<widget class="QWidget" name="gridLayoutWidget_2"> <widget class="QWidget" name="gridLayoutWidget_2">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>20</y> <y>20</y>
<width>551</width> <width>585</width>
<height>31</height> <height>31</height>
</rect> </rect>
</property> </property>
<layout class="QGridLayout" name="gridLayout_2"> <layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="1">
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="3">
<spacer name="horizontalSpacer_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="0"> <item row="0" column="0">
<widget class="QCheckBox" name="chkInterpolate"> <widget class="QCheckBox" name="chkInterpolate">
<property name="text"> <property name="text">
@ -237,20 +299,36 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="0" column="2"> <item row="0" column="1">
<widget class="QCheckBox" name="chkContour"> <widget class="QCheckBox" name="chkContour">
<property name="text"> <property name="text">
<string>Contour</string> <string>Contour</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="0" column="4"> <item row="0" column="2">
<widget class="QCheckBox" name="chkLogz"> <widget class="QCheckBox" name="chkLogz">
<property name="text"> <property name="text">
<string>Log Scale (Z)</string> <string>Log Scale (Z)</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="0" column="3">
<spacer name="horizontalSpacer_9">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>250</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout> </layout>
</widget> </widget>
</widget> </widget>
@ -258,7 +336,7 @@
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>90</y> <y>20</y>
<width>571</width> <width>571</width>
<height>61</height> <height>61</height>
</rect> </rect>
@ -266,17 +344,40 @@
<property name="title"> <property name="title">
<string>1D Plot Options</string> <string>1D Plot Options</string>
</property> </property>
<property name="flat">
<bool>false</bool>
</property>
<widget class="QWidget" name="gridLayoutWidget_3"> <widget class="QWidget" name="gridLayoutWidget_3">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>20</y> <y>20</y>
<width>551</width> <width>658</width>
<height>31</height> <height>30</height>
</rect> </rect>
</property> </property>
<layout class="QGridLayout" name="gridLayout_3"> <layout class="QGridLayout" name="gridLayout_3">
<item row="0" column="0"> <item row="0" column="0">
<widget class="QCheckBox" name="chkLogz_2">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string>Log Scale (Z)</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QCheckBox" name="chkLogz_3">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string>Superimpose</string>
</property>
</widget>
</item>
<item row="0" column="2">
<spacer name="horizontalSpacer_8"> <spacer name="horizontalSpacer_8">
<property name="orientation"> <property name="orientation">
<enum>Qt::Horizontal</enum> <enum>Qt::Horizontal</enum>
@ -286,7 +387,7 @@
</property> </property>
<property name="sizeHint" stdset="0"> <property name="sizeHint" stdset="0">
<size> <size>
<width>430</width> <width>295</width>
<height>20</height> <height>20</height>
</size> </size>
</property> </property>
@ -295,76 +396,43 @@
</layout> </layout>
</widget> </widget>
</widget> </widget>
<widget class="QGroupBox" name="boxPlot"> <widget class="QWidget" name="gridLayoutWidget_4">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>610</x>
<y>10</y> <y>22</y>
<width>571</width> <width>121</width>
<height>61</height> <height>71</height>
</rect> </rect>
</property> </property>
<property name="title"> <layout class="QGridLayout" name="gridLayout_4">
<string>Plot Options</string> <item row="0" column="0">
</property> <widget class="QPushButton" name="btnClone">
<widget class="QWidget" name="gridLayoutWidget_4"> <property name="sizePolicy">
<property name="geometry"> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<rect> <horstretch>0</horstretch>
<x>10</x> <verstretch>0</verstretch>
<y>20</y> </sizepolicy>
<width>551</width> </property>
<height>31</height> <property name="text">
</rect> <string>Clone</string>
</property> </property>
<layout class="QGridLayout" name="gridLayout_4"> </widget>
<item row="0" column="1"> </item>
<spacer name="horizontalSpacer_6"> <item row="1" column="0">
<property name="orientation"> <widget class="QPushButton" name="btnCloseClones">
<enum>Qt::Horizontal</enum> <property name="sizePolicy">
</property> <sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<property name="sizeType"> <horstretch>0</horstretch>
<enum>QSizePolicy::Fixed</enum> <verstretch>0</verstretch>
</property> </sizepolicy>
<property name="sizeHint" stdset="0"> </property>
<size> <property name="text">
<width>10</width> <string>Close All Clones</string>
<height>20</height> </property>
</size> </widget>
</property> </item>
</spacer> </layout>
</item>
<item row="0" column="3">
<spacer name="horizontalSpacer_7">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>300</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="0">
<widget class="QPushButton" name="btnClone">
<property name="text">
<string>Clone</string>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="QPushButton" name="btnCloseClones">
<property name="text">
<string>Close All Clones</string>
</property>
</widget>
</item>
</layout>
</widget>
</widget> </widget>
</widget> </widget>
<resources/> <resources/>

View File

@ -6,37 +6,108 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>952</width> <width>748</width>
<height>445</height> <height>339</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>952</width> <width>0</width>
<height>445</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>952</width> <width>1000</width>
<height>445</height> <height>1000</height>
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string>Form</string> <string>Form</string>
</property> </property>
<widget class="QPushButton" name="pushButton"> <widget class="QWidget" name="gridLayoutWidget">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>333</x> <x>13</x>
<y>161</y> <y>16</y>
<width>75</width> <width>227</width>
<height>25</height> <height>47</height>
</rect> </rect>
</property> </property>
<property name="text"> <layout class="QGridLayout" name="gridLayout">
<string>PushButton</string> <item row="0" column="0">
</property> <widget class="QLabel" name="label_3">
<property name="text">
<string>Settings:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QComboBox" name="comboSettings">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Settings of the detector.
#settings#</string>
</property>
<item>
<property name="text">
<string>Standard</string>
</property>
</item>
<item>
<property name="text">
<string>Fast</string>
</property>
</item>
<item>
<property name="text">
<string>High Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Dynamic Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Low Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Medium Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Very High Gain</string>
</property>
</item>
<item>
<property name="text">
<string>Undefined</string>
</property>
</item>
<item>
<property name="text">
<string>Uninitialized</string>
</property>
</item>
</widget>
</item>
</layout>
</widget> </widget>
</widget> </widget>
<resources/> <resources/>

View File

@ -60,10 +60,14 @@ private:
/**Tab Widget */ /**Tab Widget */
QTabWidget *tabs; QTabWidget *tabs;
static const int NUMBER_OF_TABS = 8; /** height of Plot Window when undocked */
int heightPlotWindow;
/** enumeration of the tabs */
enum {Measurement, DataOutput, Plot, Actions, Settings, Advanced, Debugging, Developer, NumberOfTabs };
/* Scroll Area for the tabs**/ /* Scroll Area for the tabs**/
QScrollArea *scroll[NUMBER_OF_TABS]; QScrollArea *scroll[NumberOfTabs];
QScrollArea *scrollMain; QScrollArea *scrollMain;
/**Measurement tab */ /**Measurement tab */
qTabMeasurement *tab_measurement; qTabMeasurement *tab_measurement;
@ -73,18 +77,15 @@ private:
qTabPlot *tab_plot; qTabPlot *tab_plot;
/**Actions tab */ /**Actions tab */
qTabActions *tab_actions; qTabActions *tab_actions;
/**Settings tab */
qTabSettings *tab_settings;
/**Advanced tab */ /**Advanced tab */
qTabAdvanced *tab_advanced; qTabAdvanced *tab_advanced;
/**Settings tab */
qTabSettings *tab_Settings;
/**Debugging tab */ /**Debugging tab */
qTabDebugging *tab_debugging; qTabDebugging *tab_debugging;
/**Developer tab */ /**Developer tab */
qTabDeveloper *tab_developer; qTabDeveloper *tab_developer;
/** enumeration of the tabs */
enum {Measurement, DataOutput, Plot, Actions, Advanced, Settings, Debugging, Developer };
/**Sets up the layout of the widget /**Sets up the layout of the widget
*/ */
@ -153,6 +154,16 @@ void Version();
/** Executing About */ /** Executing About */
void About(); void About();
/** Resizes the main window if the plot is docked/undocked
* @param b bool TRUE if undocked(outside main window), FALSE docked
*/
void ResizeMainWindow(bool b);
/** Sets the Size of the undocked/docked terminal window
* @param b bool TRUE if undocked(outside main window), FALSE docked
*/
void SetTerminalWindowSize(bool b);
signals: signals:

View File

@ -7,8 +7,7 @@
#ifndef QDRAWPLOT_H #ifndef QDRAWPLOT_H
#define QDRAWPLOT_H #define QDRAWPLOT_H
/** Form Header */
#include "ui_form_drawplot.h"
/** Project Class Headers */ /** Project Class Headers */
class slsDetectorUtils; class slsDetectorUtils;
/** Qt Project Class Headers */ /** Qt Project Class Headers */
@ -17,13 +16,17 @@ class SlsQt1DPlot;
class SlsQt2DPlotLayout; class SlsQt2DPlotLayout;
class qCloneWidget; class qCloneWidget;
/** Qt Include Headers */ /** Qt Include Headers */
class QTimer;
class QGridLayout; #include <QWidget>
#include <QGridLayout>
#include <QGroupBox>
#include <QTimer>
/** /**
*@short Sets up the plot widget *@short Sets up the plot widget
*/ */
class qDrawPlot:public QWidget, private Ui::DrawPlotObject{ class qDrawPlot:public QWidget{
Q_OBJECT Q_OBJECT
public: public:
@ -41,36 +44,12 @@ public:
*/ */
void StartStopDaqToggle(bool stop_if_running=0); void StartStopDaqToggle(bool stop_if_running=0);
public slots:
/** To select 1D or 2D plot
* @param i is 1 for 1D, else 2D plot
*/
void SelectPlot(int i=2);
/** To select 1D plot
*/
void Select1DPlot() {SelectPlot(1);}
/** To select 2D plot
*/
void Select2DPlot() {SelectPlot(2);}
/** To clear plot
*/
void Clear1DPlot();
/** Creates a clone of the plot
* */
void ClonePlot();
/** Closes all the clone plots
* */
void CloseClones();
private: private:
/** The sls detector object */ /** The sls detector object */
slsDetectorUtils *myDet; slsDetectorUtils *myDet;
/** Number of Measurements */
int numberOfMeasurements;
/** Number of Exposures */ /** Number of Exposures */
int number_of_exposures; int number_of_exposures;
/** Duration between Exposures */ /** Duration between Exposures */
@ -79,16 +58,22 @@ private:
double acquisitionTime; double acquisitionTime;
/** Widgets needed to plot the clone */ /** Widgets needed to plot the clone */
/** Max Number of Clone Windows */
static const int MAXCloneWindows = 50; static const int MAXCloneWindows = 50;
/** */ /** Array of clone window widget pointers */
qCloneWidget *winClone[MAXCloneWindows]; qCloneWidget *winClone[MAXCloneWindows];
/** */
/** Widgets needed to set up plot*/
QGroupBox *boxPlot;
QGridLayout *layout;
QGridLayout *plotLayout;
/** Timer to update plot */
QTimer* plot_update_timer; QTimer* plot_update_timer;
/** */ /** 1D object */
SlsQt1DPlot* plot1D; SlsQt1DPlot* plot1D;
/** */ /** 2D object */
SlsQt2DPlotLayout* plot2D; SlsQt2DPlotLayout* plot2D;
/** */ /** 1D hist values */
QVector<SlsQtH1D*> plot1D_hists; QVector<SlsQtH1D*> plot1D_hists;
@ -99,37 +84,37 @@ private:
pthread_mutex_t last_image_complete_mutex; pthread_mutex_t last_image_complete_mutex;
/**variables for histograms */ /**variables for histograms */
/** */ /** 1D or 2D */
unsigned int plot_in_scope; unsigned int plot_in_scope;
/** */ /** Current Image Number */
unsigned int lastImageNumber; unsigned int lastImageNumber;
/** */ /** Title in 2D */
std::string imageTitle; std::string imageTitle;
/** */ /** X Axis Title in 2D */
std::string imageXAxisTitle; std::string imageXAxisTitle;
/** */ /** Y Axis Title in 2D */
std::string imageYAxisTitle; std::string imageYAxisTitle;
/** */ /** Z Axis Title in 2D */
std::string imageZAxisTitle; std::string imageZAxisTitle;
/** */ /** Number of Pixels in X Axis */
unsigned int nPixelsX; unsigned int nPixelsX;
/** */ /** Number of Pixels in Y Axis */
unsigned int nPixelsY; unsigned int nPixelsY;
/** */ /** Current Image Values in 1D */
double* lastImageArray; double* lastImageArray;
/** */ /** Number of graphs in 1D */
unsigned int nHists; unsigned int nHists;
/** */ /** Title for all the graphs in 1D */
std::string histTitle[10]; std::string histTitle[10];
/** */ /** X Axis Title in 1D */
std::string histXAxisTitle; std::string histXAxisTitle;
/** */ /** Y Axis Title in 1D */
std::string histYAxisTitle; std::string histYAxisTitle;
/** */ /** Total Number of X axis values/channels in 1D */
int histNBins; int histNBins;
/** */ /** X Axis value in 1D */
double* histXAxis; double* histXAxis;
/** */ /** Y Axis value in 1D */
double* histYAxis[10]; double* histYAxis[10];
@ -196,6 +181,40 @@ private:
void* AcquireImages(); void* AcquireImages();
public slots:
/** Set number of measurements
* @param num number of measurements to be set
*/
void setNumMeasurements(int num);
/** To select 1D or 2D plot
* @param i is 1 for 1D, else 2D plot
*/
void SelectPlot(int i=2);
/** To select 1D plot
*/
void Select1DPlot() {SelectPlot(1);}
/** To select 2D plot
*/
void Select2DPlot() {SelectPlot(2);}
/** To clear plot
*/
void Clear1DPlot();
/** Creates a clone of the plot
* */
void ClonePlot();
/** Closes all the clone plots
* */
void CloseClones();
private slots: private slots:
/** To update plot /** To update plot
*/ */

View File

@ -44,6 +44,8 @@ private:
/** The Plot widget */ /** The Plot widget */
qDrawPlot *myPlot; qDrawPlot *myPlot;
enum{None, Auto, Gated, Trigger_Exp_Series, Trigger_Frame, Trigger_Readout, Gated_Start, Trigger_Window, NumTimingModes};
/** methods */ /** methods */
/** Sets up the widget /** Sets up the widget
@ -51,8 +53,16 @@ private:
void SetupWidgetWindow(); void SetupWidgetWindow();
/** Sets up all the slots and signals /** Sets up all the slots and signals
* @param timingChange only some of the signals are disconnected when timing mode is changed
* This method is to reconnect them again.
*/ */
void Initialization(); void Initialization(int timingChange=0);
/** Disconnects all the slots and signals (which depend on timing mode)
* to retrieve all the parameters from client.
* This is done only when Timing mode is changed
*/
void DeInitialization();
/** Enables/Disables all the widgets /** Enables/Disables all the widgets
*/ */
@ -66,24 +76,9 @@ public slots:
void UpdateFinished(); void UpdateFinished();
private slots: private slots:
/** Set settings according to selection
* @param index index of selection
*/
void setSettings(int index);
/** Set number of frames
* @param val number of frames to be set
*/
void setNumFrames(int val);
/** Set acquisition time
*/
void setAcquisitionTime();
/** Set frame period between exposures
*/
void setFramePeriod();
/** Set file name /** Set file name
* @param fName name of file * @param fName name of file
*/ */
@ -98,6 +93,44 @@ void setRunIndex(int index);
*/ */
void startStopAcquisition(); void startStopAcquisition();
/** Sets the timing mode
* @ param mode cane be None, Auto, Gated, Trigger Exposure Series,
* Trigger Frame, Trigger Readout, External Trigger Window
*/
void setTimingMode(int mode);
/** Set number of frames
* @param val number of frames to be set
*/
void setNumFrames(int val);
/** Set acquisition time
*/
void setExposureTime();
/** Set frame period between exposures
*/
void setAcquisitionPeriod();
/** Set number of triggers
* @param val number of triggers to be set
*/
void setNumTriggers(int val);
/** Set delay
*/
void setDelay();
/** Set number of gates
* @param val number of gates to be set
*/
void setNumGates(int val);
/** Set number of probes
* @param val number of probes to be set
*/
void setNumProbes(int val);
signals: signals:

View File

@ -41,7 +41,6 @@ private:
/** The Plot widget */ /** The Plot widget */
qDrawPlot *myPlot; qDrawPlot *myPlot;
/** methods */ /** methods */
/** Sets up the widget /** Sets up the widget
*/ */

View File

@ -47,6 +47,13 @@ private:
*/ */
void Enable(bool enable); void Enable(bool enable);
private slots:
/** Set settings according to selection
* @param index index of selection
*/
void setSettings(int index);
}; };

View File

@ -81,7 +81,6 @@ HEADERS = \
FORMS = \ FORMS = \
forms/form_detectormain.ui\ forms/form_detectormain.ui\
forms/form_drawplot.ui\
forms/form_tab_measurement.ui\ forms/form_tab_measurement.ui\
forms/form_tab_dataoutput.ui\ forms/form_tab_dataoutput.ui\
forms/form_tab_plot.ui\ forms/form_tab_plot.ui\

View File

@ -14,6 +14,7 @@
#include "multiSlsDetector.h" #include "multiSlsDetector.h"
#include "sls_detector_defs.h" #include "sls_detector_defs.h"
/** Qt Include Headers */ /** Qt Include Headers */
#include <QSizePolicy>
/** C++ Include Headers */ /** C++ Include Headers */
#include<iostream> #include<iostream>
#include <string> #include <string>
@ -34,13 +35,22 @@ int main (int argc, char **argv) {
qDetectorMain::qDetectorMain(int argc, char **argv, QApplication *app, QWidget *parent) : QMainWindow(parent), theApp(app),myPlot(NULL),tabs(NULL){ qDetectorMain::qDetectorMain(int argc, char **argv, QApplication *app, QWidget *parent) :
QMainWindow(parent), theApp(app),myPlot(NULL),tabs(NULL){
myDet = 0; myDet = 0;
setupUi(this); setupUi(this);
SetUpWidgetWindow(); SetUpWidgetWindow();
Initialization(); Initialization();
SetDeveloperMode(); SetDeveloperMode();
/**need to use argc and argv to determine which slsdet or multidet to use.*/ /**need to use argc and argv to determine which slsdet or multidet to use.*/
if(argc>1){
if(!strcasecmp(argv[1],"-developer"))
tabs->setTabEnabled(Developer,true);
else
tabs->setTabEnabled(Developer,false);
}
} }
@ -68,7 +78,8 @@ void qDetectorMain::SetUpWidgetWindow(){
SetUpDetector(); SetUpDetector();
/** plot setup*/ /** plot setup*/
myPlot = new qDrawPlot(framePlot,myDet); myPlot = new qDrawPlot(dockWidgetPlot,myDet);
dockWidgetPlot->setWidget(myPlot);
/**tabs setup*/ /**tabs setup*/
tabs = new QTabWidget(this); tabs = new QTabWidget(this);
@ -78,12 +89,12 @@ void qDetectorMain::SetUpWidgetWindow(){
tab_dataoutput = new qTabDataOutput (this, myDet); tab_dataoutput = new qTabDataOutput (this, myDet);
tab_plot = new qTabPlot (this, myDet,myPlot); tab_plot = new qTabPlot (this, myDet,myPlot);
tab_actions = new qTabActions (this, myDet); tab_actions = new qTabActions (this, myDet);
tab_settings = new qTabSettings (this, myDet);
tab_advanced = new qTabAdvanced (this, myDet); tab_advanced = new qTabAdvanced (this, myDet);
tab_Settings = new qTabSettings (this, myDet);
tab_debugging = new qTabDebugging (this, myDet); tab_debugging = new qTabDebugging (this, myDet);
tab_developer = new qTabDeveloper (this, myDet); tab_developer = new qTabDeveloper (this, myDet);
/** creating the scroll area widgets for the tabs */ /** creating the scroll area widgets for the tabs */
for(int i=0;i<NUMBER_OF_TABS;i++){ for(int i=0;i<NumberOfTabs;i++){
scroll[i] = new QScrollArea; scroll[i] = new QScrollArea;
scroll[i]->setFrameShape(QFrame::NoFrame); scroll[i]->setFrameShape(QFrame::NoFrame);
} }
@ -92,8 +103,8 @@ void qDetectorMain::SetUpWidgetWindow(){
scroll[DataOutput] ->setWidget(tab_dataoutput); scroll[DataOutput] ->setWidget(tab_dataoutput);
scroll[Plot] ->setWidget(tab_plot); scroll[Plot] ->setWidget(tab_plot);
scroll[Actions] ->setWidget(tab_actions); scroll[Actions] ->setWidget(tab_actions);
scroll[Settings] ->setWidget(tab_settings);
scroll[Advanced] ->setWidget(tab_advanced); scroll[Advanced] ->setWidget(tab_advanced);
scroll[Settings] ->setWidget(tab_Settings);
scroll[Debugging] ->setWidget(tab_debugging); scroll[Debugging] ->setWidget(tab_debugging);
scroll[Developer] ->setWidget(tab_developer); scroll[Developer] ->setWidget(tab_developer);
/** inserting all the tabs*/ /** inserting all the tabs*/
@ -101,8 +112,8 @@ void qDetectorMain::SetUpWidgetWindow(){
tabs->insertTab(DataOutput, scroll[DataOutput], "Data Output"); tabs->insertTab(DataOutput, scroll[DataOutput], "Data Output");
tabs->insertTab(Plot, scroll[Plot], "Plot"); tabs->insertTab(Plot, scroll[Plot], "Plot");
tabs->insertTab(Actions, scroll[Actions], "Actions"); tabs->insertTab(Actions, scroll[Actions], "Actions");
tabs->insertTab(Advanced, scroll[Advanced], "Advanced");
tabs->insertTab(Settings, scroll[Settings], "Settings"); tabs->insertTab(Settings, scroll[Settings], "Settings");
tabs->insertTab(Advanced, scroll[Advanced], "Advanced");
tabs->insertTab(Debugging, scroll[Debugging], "Debugging"); tabs->insertTab(Debugging, scroll[Debugging], "Debugging");
tabs->insertTab(Developer, scroll[Developer], "Developer"); tabs->insertTab(Developer, scroll[Developer], "Developer");
@ -117,6 +128,8 @@ void qDetectorMain::SetUpWidgetWindow(){
void qDetectorMain::SetUpDetector(){ void qDetectorMain::SetUpDetector(){
/**instantiate detector and set window title*/ /**instantiate detector and set window title*/
myDet = new multiSlsDetector(Detector_Index); myDet = new multiSlsDetector(Detector_Index);
if(!myDet->getHostname(Detector_Index).length()){ if(!myDet->getHostname(Detector_Index).length()){
@ -138,7 +151,9 @@ void qDetectorMain::SetUpDetector(){
void qDetectorMain::Initialization(){ void qDetectorMain::Initialization(){
/** Dockable Plot*/
connect(dockWidgetPlot,SIGNAL(topLevelChanged(bool)),this,SLOT(ResizeMainWindow(bool)));
connect(dockWidgetTerminal,SIGNAL(topLevelChanged(bool)),this,SLOT(SetTerminalWindowSize(bool)));
/** tabs */ /** tabs */
connect(tabs,SIGNAL(currentChanged(int)),this, SLOT(refresh(int)));//( QWidget*))); connect(tabs,SIGNAL(currentChanged(int)),this, SLOT(refresh(int)));//( QWidget*)));
@ -170,6 +185,8 @@ void qDetectorMain::Initialization(){
connect(actionAbout,SIGNAL(triggered()),this,SLOT(About())); connect(actionAbout,SIGNAL(triggered()),this,SLOT(About()));
connect(actionVersion,SIGNAL(triggered()),this,SLOT(Version())); connect(actionVersion,SIGNAL(triggered()),this,SLOT(Version()));
heightPlotWindow = dockWidgetPlot->size().height();
} }
@ -200,7 +217,6 @@ void qDetectorMain::SetExpertMode(bool b){
#endif #endif
//threshold part in measu is enabled //threshold part in measu is enabled
tabs->setTabEnabled(Advanced,b); tabs->setTabEnabled(Advanced,b);
tabs->setTabEnabled(Settings,b);
tab_advanced->setEnabled(b); tab_advanced->setEnabled(b);
} }
@ -217,12 +233,16 @@ void qDetectorMain::refresh(int index){
void qDetectorMain::SetDockableMode(bool b){ void qDetectorMain::SetDockableMode(bool b){
#ifdef VERBOSE #ifdef VERBOSE
cout<<"Setting Dockable Plot Mode to "<<b<<endl; cout<<"Setting Dockable Mode to "<<b<<endl;
#endif #endif
if(b) if(b){
dockWidgetPlot->setFeatures(QDockWidget::DockWidgetMovable | QDockWidget::DockWidgetFloatable); dockWidgetPlot->setFeatures(QDockWidget::DockWidgetFloatable);
else dockWidgetTerminal->setFeatures(QDockWidget::DockWidgetFloatable|QDockWidget::DockWidgetVerticalTitleBar);
}else{
dockWidgetPlot->setFeatures(QDockWidget::NoDockWidgetFeatures); dockWidgetPlot->setFeatures(QDockWidget::NoDockWidgetFeatures);
dockWidgetTerminal->setFeatures(QDockWidget::DockWidgetVerticalTitleBar);
}
} }
@ -289,3 +309,36 @@ void qDetectorMain::About(){
#endif #endif
} }
void qDetectorMain::ResizeMainWindow(bool b){
#ifdef VERBOSE
cout<<"Resizing Main Window: height:"<<height()<<endl;
#endif
if(b)/** sets the main window height to a smaller maximum to get rid of space*/
setMaximumHeight(height()-heightPlotWindow-9);
else
setMaximumHeight(QWIDGETSIZE_MAX);
cout<<"size hint ht:"<<sizeHint().height()<<endl;
}
void qDetectorMain::SetTerminalWindowSize(bool b){
#ifdef VERBOSE
cout<<"Resizing Terminal Window"<<endl;
#endif
cout<<"min width:"<<dockWidgetTerminal->minimumWidth()<<endl;
cout<<"min height:"<<dockWidgetTerminal->minimumHeight()<<endl;
if(b){
dockWidgetTerminal->setMinimumWidth(width()/2);
}
//dockWidgetTerminal->setFixedSize(width()/2,dockWidgetTerminal->minimumHeight());
else{
dockWidgetTerminal->setMinimumWidth(38);
QSizePolicy sizePolicy(QSizePolicy::Preferred,QSizePolicy::Preferred);
dockWidgetTerminal->setSizePolicy(sizePolicy);
//dockWidgetTerminal->setSizePolicy(new QSizePolicy(QSizePolicy::Expanding,QSizePolicy::Expanding));
//dockWidgetTerminal->setFixedSize(dockWidgetTerminal->minimumWidth(),dockWidgetTerminal->minimumHeight());
}
}

View File

@ -13,7 +13,7 @@
#include "slsDetector.h" #include "slsDetector.h"
#include "multiSlsDetector.h" #include "multiSlsDetector.h"
/** Qt Include Headers */ /** Qt Include Headers */
#include <QTimer> #include <QFont>
/** C++ Include Headers */ /** C++ Include Headers */
#include <iostream> #include <iostream>
#include <string> #include <string>
@ -23,9 +23,8 @@ using namespace std;
#define Detector_Index 0 #define Detector_Index 0
qDrawPlot::qDrawPlot(QWidget *parent,slsDetectorUtils*& detector):QWidget(parent),myDet(detector){ qDrawPlot::qDrawPlot(QWidget *parent,slsDetectorUtils*& detector):QWidget(parent),myDet(detector),numberOfMeasurements(1){
if(myDet) { if(myDet) {
setupUi(this);
Initialization(); Initialization();
SetupWidgetWindow(); SetupWidgetWindow();
StartStopDaqToggle(); //as default StartStopDaqToggle(); //as default
@ -36,15 +35,11 @@ qDrawPlot::qDrawPlot(QWidget *parent,slsDetectorUtils*& detector):QWidget(parent
qDrawPlot::~qDrawPlot(){ qDrawPlot::~qDrawPlot(){
/** Clear plot*/ /** Clear plot*/
Clear1DPlot(); Clear1DPlot();
for(QVector<SlsQtH1D*>::iterator h = plot1D_hists.begin();h!=plot1D_hists.end();h++){ for(QVector<SlsQtH1D*>::iterator h = plot1D_hists.begin();h!=plot1D_hists.end();h++)
delete *h; delete *h;
}
plot1D_hists.clear(); plot1D_hists.clear();
delete[] lastImageArray; lastImageArray=0; delete[] lastImageArray; lastImageArray=0;
StartOrStopThread(0); StartOrStopThread(0);
/** delete detector object pointer*/ /** delete detector object pointer*/
delete myDet; delete myDet;
} }
@ -77,6 +72,13 @@ void qDrawPlot::Initialization(){
void qDrawPlot::SetupWidgetWindow(){ void qDrawPlot::SetupWidgetWindow(){
/** Setting up window*/
setFont(QFont("Sans Serif",9));
layout = new QGridLayout;
boxPlot = new QGroupBox("Start Image");
layout->addWidget(boxPlot,1,1);
this->setLayout(layout);
plot_update_timer = new QTimer(this); plot_update_timer = new QTimer(this);
connect(plot_update_timer, SIGNAL(timeout()), this, SLOT(UpdatePlot())); connect(plot_update_timer, SIGNAL(timeout()), this, SLOT(UpdatePlot()));
@ -224,6 +226,7 @@ void* qDrawPlot::AcquireImages(){
//cout<<"filePath:"<<filePath<<endl; //cout<<"filePath:"<<filePath<<endl;
//string fileName; //string fileName;
//numberOfMeasurements
for(int i=0;i<number_of_exposures;i++){ for(int i=0;i<number_of_exposures;i++){
///// /////
@ -301,6 +304,9 @@ void* qDrawPlot::AcquireImages(){
void qDrawPlot::setNumMeasurements(int num){
numberOfMeasurements = num;
}

View File

@ -12,6 +12,9 @@
/** Project Class Headers */ /** Project Class Headers */
#include "slsDetector.h" #include "slsDetector.h"
#include "multiSlsDetector.h" #include "multiSlsDetector.h"
#include <QStandardItemModel>
/** C++ Include Headers */ /** C++ Include Headers */
#include<iostream> #include<iostream>
using namespace std; using namespace std;
@ -22,7 +25,8 @@ using namespace std;
qTabMeasurement::qTabMeasurement(QWidget *parent,slsDetectorUtils*& detector, qDrawPlot*& plot):QWidget(parent),myDet(detector),myPlot(plot){ qTabMeasurement::qTabMeasurement(QWidget *parent,slsDetectorUtils*& detector, qDrawPlot*& plot):
QWidget(parent),myDet(detector),myPlot(plot){
setupUi(this); setupUi(this);
if(myDet) if(myDet)
{ {
@ -43,63 +47,169 @@ qTabMeasurement::~qTabMeasurement(){
void qTabMeasurement::SetupWidgetWindow(){ void qTabMeasurement::SetupWidgetWindow(){
/** all set initially to reflect the detector's actual parameter values*/
/** Settings */ /** File Name **/
comboSettings->setCurrentIndex(myDet->getSettings(Detector_Index)); //set it to default acc to detector??? dispFileName->setText(QString(myDet->getFileName().c_str()));
/** Number of Measurements/Frames*/ /** File Index **/
setNumFrames(2000); spinIndex->setValue(myDet->getFileIndex());
/** Acquisition Time */ /** only initially **/
setAcquisitionTime(); lblProgressIndex->setText(QString::number(myDet->getFileIndex()));
/** Frame Period between exposures*/
setFramePeriod(); /** Enabling/Disabling depending on the detector type*/
/** File Name*/ QStandardItemModel* model = qobject_cast<QStandardItemModel*>(comboTimingMode->model());
setFileName("run"); QModelIndex index[NumTimingModes];
/** File Index*/ QStandardItem* item[NumTimingModes];
setRunIndex(0); if (model) {
for(int i=0;i<NumTimingModes;i++){
index[i] = model->index(i, comboTimingMode->modelColumn(), comboTimingMode->rootModelIndex());
item[i] = model->itemFromIndex(index[i]);
}
switch(myDet->getDetectorsType()){
case slsDetectorDefs::MYTHEN:
item[(int)Gated]->setEnabled(true);
item[(int)Trigger_Exp_Series]->setEnabled(true);
item[(int)Trigger_Frame]->setEnabled(false);
item[(int)Trigger_Readout]->setEnabled(true);
item[(int)Gated_Start]->setEnabled(true);
item[(int)Trigger_Window]->setEnabled(false);
break;
case slsDetectorDefs::EIGER:
item[(int)Gated]->setEnabled(false);
item[(int)Trigger_Exp_Series]->setEnabled(true);
item[(int)Trigger_Frame]->setEnabled(true);
item[(int)Trigger_Readout]->setEnabled(false);
item[(int)Gated_Start]->setEnabled(false);
item[(int)Trigger_Window]->setEnabled(true);
break;
case slsDetectorDefs::GOTTHARD:
item[(int)Gated]->setEnabled(false);
item[(int)Trigger_Exp_Series]->setEnabled(true);
item[(int)Trigger_Frame]->setEnabled(false);
item[(int)Trigger_Readout]->setEnabled(false);
item[(int)Gated_Start]->setEnabled(false);
item[(int)Trigger_Window]->setEnabled(false);
break;
/* case slsDetectorDefs::PICASSO:
case slsDetectorDefs::PILATUS:
case slsDetectorDefs::AGIPD:*/
default:
cout<<"ERROR: Detector Type is Generic"<<endl;
exit(-1);
}
}
//get timing mode from client
} }
void qTabMeasurement::Initialization(){ void qTabMeasurement::Initialization(int timingChange){
/** Settings */ /** These signals are connected only at start up*/
connect(comboSettings,SIGNAL(currentIndexChanged(int)),this,SLOT(setSettings(int))); if(!timingChange){
/** Number of Measurements/Frames*/ /** Number of Measurements**/
connect(spinNumMeasurements,SIGNAL(valueChanged(int)),this,SLOT(setNumFrames(int))); connect(spinNumMeasurements,SIGNAL(valueChanged(int)), myPlot, SLOT(setNumMeasurements(int)));
/** Acquisition Time */ /** File Name**/
connect(spinExpTime,SIGNAL(valueChanged(double)),this,SLOT(setAcquisitionTime())); connect(dispFileName,SIGNAL(textChanged(const QString&)), this, SLOT(setFileName(const QString&)));
connect(comboExpUnit,SIGNAL(currentIndexChanged(int)),this,SLOT(setAcquisitionTime())); /** File Index**/
/** Frame Period between exposures*/ connect(spinIndex,SIGNAL(valueChanged(int)), this, SLOT(setRunIndex(int)));
connect(spinPeriod,SIGNAL(valueChanged(double)),this,SLOT(setFramePeriod())); /** Start/Stop Acquisition**/
connect(comboPeriodUnit,SIGNAL(currentIndexChanged(int)),this,SLOT(setFramePeriod())); connect(btnStartStop,SIGNAL(clicked()), this, SLOT(startStopAcquisition()));
/** File Name*/ /** Timing Mode **/
connect(dispFileName,SIGNAL(textChanged(const QString&)),this,SLOT(setFileName(const QString&))); connect(comboTimingMode,SIGNAL(currentIndexChanged(int)), this, SLOT(setTimingMode(int)));//
/** File Index*/ }
connect(spinIndex,SIGNAL(valueChanged(int)),this,SLOT(setRunIndex(int))); /** Number of Frames**/
/** Start/Stop Acquisition*/ connect(spinNumFrames,SIGNAL(valueChanged(int)), this, SLOT(setNumFrames(int)));
/** Exposure Time **/
connect(spinExpTime,SIGNAL(valueChanged(double)), this, SLOT(setExposureTime()));//..myplot
connect(comboExpUnit,SIGNAL(currentIndexChanged(int)), this, SLOT(setExposureTime()));
/** Frame Period between exposures**/
connect(spinPeriod,SIGNAL(valueChanged(double)), this, SLOT(setAcquisitionPeriod()));//..myplot
connect(comboPeriodUnit,SIGNAL(currentIndexChanged(int)), this, SLOT(setAcquisitionPeriod()));
/** Number of Triggers**/
connect(spinNumTriggers,SIGNAL(valueChanged(int)), this, SLOT(setNumTriggers(int)));//
/** Delay After Trigger **/
connect(spinDelay,SIGNAL(valueChanged(double)), this, SLOT(setDelay()));//
connect(comboDelayUnit,SIGNAL(currentIndexChanged(int)), this, SLOT(setDelay()));
/** Number of Gates**/
connect(spinNumGates,SIGNAL(valueChanged(int)), this, SLOT(setNumGates(int)));//
/** Number of Probes**/
connect(spinNumProbes,SIGNAL(valueChanged(int)), this, SLOT(setNumProbes(int)));//
}
void qTabMeasurement::DeInitialization(){
/** Number of Frames**/
disconnect(spinNumFrames,SIGNAL(valueChanged(int)), this, SLOT(setNumFrames(int)));
/** Exposure Time **/
disconnect(spinExpTime,SIGNAL(valueChanged(double)), this, SLOT(setExposureTime()));//..myplot
disconnect(comboExpUnit,SIGNAL(currentIndexChanged(int)), this, SLOT(setExposureTime()));
/** Frame Period between exposures**/
disconnect(spinPeriod,SIGNAL(valueChanged(double)), this, SLOT(setAcquisitionPeriod()));//..myplot
disconnect(comboPeriodUnit,SIGNAL(currentIndexChanged(int)), this, SLOT(setAcquisitionPeriod()));
/** Number of Triggers**/
disconnect(spinNumTriggers,SIGNAL(valueChanged(int)), this, SLOT(setNumTriggers(int)));
/** Delay After Trigger **/
disconnect(spinDelay,SIGNAL(valueChanged(double)), this, SLOT(setDelay()));
disconnect(comboDelayUnit,SIGNAL(currentIndexChanged(int)), this, SLOT(setDelay()));
/** Number of Gates**/
disconnect(spinNumGates,SIGNAL(valueChanged(int)), this, SLOT(setNumGates(int)));
/** Number of Probes**/
disconnect(spinNumProbes,SIGNAL(valueChanged(int)), this, SLOT(setNumProbes(int)));
}
void qTabMeasurement::Enable(bool enable){
gridTimeResolved->setEnabled(enable);
gridLayout->setEnabled(enable);
boxProgress->setEnabled(enable);
/** Enable this always **/
if(!enable) btnStartStop->setEnabled(true);
}
void qTabMeasurement::UpdateFinished(){
disconnect(btnStartStop,SIGNAL(clicked()),this,SLOT(startStopAcquisition()));
btnStartStop->setText("Start");
Enable(1);
connect(btnStartStop,SIGNAL(clicked()),this,SLOT(startStopAcquisition())); connect(btnStartStop,SIGNAL(clicked()),this,SLOT(startStopAcquisition()));
} }
void qTabMeasurement::setFileName(const QString& fName){
//enabled other tabs as well?? // emit fileNameChanged(fName);
void qTabMeasurement::Enable(bool enable){ // thred-->fileName=s;myDet->setFileName(fName.ascii());
//this->setEnabled(enable); myDet->setFileName(fName.toAscii().data());
comboSettings->setEnabled(enable); #ifdef VERBOSE
spinNumMeasurements->setEnabled(enable); cout<<"Setting File name to " << myDet->getFileName()<<endl;
spinExpTime->setEnabled(enable); #endif
comboExpUnit->setEnabled(enable);
spinPeriod->setEnabled(enable);
comboPeriodUnit->setEnabled(enable);
dispFileName->setEnabled(enable);
spinIndex->setEnabled(enable);
if(!enable) btnStartStop->setEnabled(true);
} }
void qTabMeasurement::setRunIndex(int index){
myDet->setFileIndex(index);
#ifdef VERBOSE
cout<<"Setting File Index to " << myDet->getFileIndex()<<endl;
#endif
}
void qTabMeasurement::startStopAcquisition(){ void qTabMeasurement::startStopAcquisition(){
if(!btnStartStop->text().compare("Start")){ if(!btnStartStop->text().compare("Start")){
#ifdef VERBOSE #ifdef VERBOSE
@ -118,33 +228,20 @@ void qTabMeasurement::startStopAcquisition(){
} }
void qTabMeasurement::UpdateFinished(){
disconnect(btnStartStop,SIGNAL(clicked()),this,SLOT(startStopAcquisition()));
btnStartStop->setText("Start");
Enable(1);
connect(btnStartStop,SIGNAL(clicked()),this,SLOT(startStopAcquisition()));
}
void qTabMeasurement::setSettings(int index){
slsDetectorDefs::detectorSettings sett = myDet->setSettings((slsDetectorDefs::detectorSettings)index,Detector_Index);
#ifdef VERBOSE
cout<<"Settings have been set to "<<myDet->slsDetectorBase::getDetectorSettings(sett)<<endl;
#endif
}
void qTabMeasurement::setNumFrames(int val){ void qTabMeasurement::setNumFrames(int val){
myDet->setTimer(slsDetectorDefs::FRAME_NUMBER,val); myDet->setTimer(slsDetectorDefs::FRAME_NUMBER,val);
#ifdef VERBOSE #ifdef VERBOSE
cout<<"Setting Frame number to " << (int)myDet->setTimer(slsDetectorDefs::FRAME_NUMBER,-1)<<endl; cout<<"Setting number of frames to " << (int)myDet->setTimer(slsDetectorDefs::FRAME_NUMBER,-1)<<endl;
#endif #endif
} }
void qTabMeasurement::setAcquisitionTime(){ void qTabMeasurement::setExposureTime(){
int64_t exptime64; int64_t exptime64;
/** Get the 64 bit value of timer*/ /** Get the 64 bit value of timer**/
exptime64 = qDefs::get64bTime((qDefs::timeUnit)comboExpUnit->currentIndex(),spinExpTime->value()); exptime64 = qDefs::get64bTime((qDefs::timeUnit)comboExpUnit->currentIndex(),spinExpTime->value());
#ifdef VERBOSE #ifdef VERBOSE
cout<<"Setting acquisition time to " << exptime64 << " clocks" << endl; cout<<"Setting acquisition time to " << exptime64 << " clocks" << endl;
@ -157,9 +254,9 @@ void qTabMeasurement::setAcquisitionTime(){
void qTabMeasurement::setFramePeriod(){ void qTabMeasurement::setAcquisitionPeriod(){
int64_t exptime64; int64_t exptime64;
/** Get the 64 bit value of timer*/ /** Get the 64 bit value of timer**/
exptime64 = qDefs::get64bTime((qDefs::timeUnit)comboPeriodUnit->currentIndex(),spinPeriod->value()); exptime64 = qDefs::get64bTime((qDefs::timeUnit)comboPeriodUnit->currentIndex(),spinPeriod->value());
#ifdef VERBOSE #ifdef VERBOSE
cout<<"Setting frame period between exposures to " << exptime64 << " clocks" << endl; cout<<"Setting frame period between exposures to " << exptime64 << " clocks" << endl;
@ -172,24 +269,210 @@ void qTabMeasurement::setFramePeriod(){
void qTabMeasurement::setFileName(const QString& fName){
// emit fileNameChanged(fName);
// thred-->fileName=s;myDet->setFileName(fName.ascii()); void qTabMeasurement::setNumTriggers(int val){
myDet->setTimer(slsDetectorDefs::CYCLES_NUMBER,val);
#ifdef VERBOSE #ifdef VERBOSE
cout<<"Setting File name to " << myDet->getFileName()<<endl; cout<<"Setting number of triggers to " << (int)myDet->setTimer(slsDetectorDefs::CYCLES_NUMBER,-1)<<endl;
#endif
myDet->setFileName(fName.toAscii().data());
}
void qTabMeasurement::setRunIndex(int index){
myDet->setFileIndex(index);
#ifdef VERBOSE
cout<<"Setting File Index to " << myDet->getFileIndex()<<endl;
#endif #endif
} }
void qTabMeasurement::setDelay(){
int64_t exptime64;
/** Get the 64 bit value of timer**/
exptime64 = qDefs::get64bTime((qDefs::timeUnit)comboDelayUnit->currentIndex(),spinDelay->value());
#ifdef VERBOSE
cout<<"Setting delay after trigger to " << exptime64 << " clocks" << endl;
#endif
myDet->setTimer(slsDetectorDefs::DELAY_AFTER_TRIGGER,exptime64);
}
void qTabMeasurement::setNumGates(int val){
myDet->setTimer(slsDetectorDefs::GATES_NUMBER,val);
#ifdef VERBOSE
cout<<"Setting number of gates to " << (int)myDet->setTimer(slsDetectorDefs::GATES_NUMBER,-1)<<endl;
#endif
}
void qTabMeasurement::setNumProbes(int val){
myDet->setTimer(slsDetectorDefs::PROBES_NUMBER,val);
#ifdef VERBOSE
cout<<"Setting number of frames to " << (int)myDet->setTimer(slsDetectorDefs::PROBES_NUMBER,-1)<<endl;
#endif
}
void qTabMeasurement::setTimingMode(int mode){
#ifdef VERBOSE
cout<<"Setting Timing mode to " << comboTimingMode->currentText().toAscii().data()<<endl;
#endif
//need to send to client to set the timing mode
switch(mode){
case None:
lblNumFrames->setEnabled(false); spinNumFrames->setEnabled(false);
lblExpTime->setEnabled(false); spinExpTime->setEnabled(false); comboExpUnit->setEnabled(false);
lblPeriod->setEnabled(false); spinPeriod->setEnabled(false); comboPeriodUnit->setEnabled(false);
lblNumTriggers->setEnabled(false); spinNumTriggers->setEnabled(false);
lblDelay->setEnabled(false); spinDelay->setEnabled(false); comboDelayUnit->setEnabled(false);
lblNumGates->setEnabled(false); spinNumGates->setEnabled(false);
lblNumProbes->setEnabled(false); spinNumProbes->setEnabled(false);
break;
case Auto:
lblNumFrames->setEnabled(true); spinNumFrames->setEnabled(true);
lblExpTime->setEnabled(true); spinExpTime->setEnabled(true); comboExpUnit->setEnabled(true);
lblPeriod->setEnabled(true); spinPeriod->setEnabled(true); comboPeriodUnit->setEnabled(true);
lblNumTriggers->setEnabled(false); spinNumTriggers->setEnabled(false);
lblDelay->setEnabled(false); spinDelay->setEnabled(false); comboDelayUnit->setEnabled(false);
lblNumGates->setEnabled(false); spinNumGates->setEnabled(false);
break;
case Gated:
lblNumFrames->setEnabled(true); spinNumFrames->setEnabled(true);
lblExpTime->setEnabled(false); spinExpTime->setEnabled(false); comboExpUnit->setEnabled(false);
lblPeriod->setEnabled(false); spinPeriod->setEnabled(false); comboPeriodUnit->setEnabled(false);
lblNumTriggers->setEnabled(false); spinNumTriggers->setEnabled(false);
lblDelay->setEnabled(false); spinDelay->setEnabled(false); comboDelayUnit->setEnabled(false);
lblNumGates->setEnabled(true); spinNumGates->setEnabled(true);
break;
case Trigger_Exp_Series:
lblNumFrames->setEnabled(true); spinNumFrames->setEnabled(true);
lblExpTime->setEnabled(true); spinExpTime->setEnabled(true); comboExpUnit->setEnabled(true);
lblPeriod->setEnabled(true); spinPeriod->setEnabled(true); comboPeriodUnit->setEnabled(true);
lblNumTriggers->setEnabled(true); spinNumTriggers->setEnabled(true);
lblDelay->setEnabled(true); spinDelay->setEnabled(true); comboDelayUnit->setEnabled(true);
lblNumGates->setEnabled(false); spinNumGates->setEnabled(false);
break;
case Trigger_Readout:
lblNumFrames->setEnabled(true); spinNumFrames->setEnabled(true);
lblExpTime->setEnabled(true); spinExpTime->setEnabled(true); comboExpUnit->setEnabled(true);
lblPeriod->setEnabled(true); spinPeriod->setEnabled(true); comboPeriodUnit->setEnabled(true);
lblNumTriggers->setEnabled(false); spinNumTriggers->setEnabled(false);
lblDelay->setEnabled(true); spinDelay->setEnabled(true); comboDelayUnit->setEnabled(true);
lblNumGates->setEnabled(false); spinNumGates->setEnabled(false);
break;
case Gated_Start:
lblNumFrames->setEnabled(true); spinNumFrames->setEnabled(true);
lblExpTime->setEnabled(true); spinExpTime->setEnabled(true); comboExpUnit->setEnabled(true);
lblPeriod->setEnabled(true); spinPeriod->setEnabled(true); comboPeriodUnit->setEnabled(true);
lblNumTriggers->setEnabled(true); spinNumTriggers->setEnabled(true);
lblDelay->setEnabled(false); spinDelay->setEnabled(false); comboDelayUnit->setEnabled(false);
lblNumGates->setEnabled(true); spinNumGates->setEnabled(true);
break;
case Trigger_Frame:
lblNumFrames->setEnabled(false); spinNumFrames->setEnabled(false);
lblExpTime->setEnabled(true); spinExpTime->setEnabled(true); comboExpUnit->setEnabled(true);
lblPeriod->setEnabled(false); spinPeriod->setEnabled(false); comboPeriodUnit->setEnabled(false);
lblNumTriggers->setEnabled(true); spinNumTriggers->setEnabled(true);
lblDelay->setEnabled(false); spinDelay->setEnabled(false); comboDelayUnit->setEnabled(false);
lblNumGates->setEnabled(false); spinNumGates->setEnabled(false);
break;
case Trigger_Window:
lblNumFrames->setEnabled(false); spinNumFrames->setEnabled(false);
lblExpTime->setEnabled(false); spinExpTime->setEnabled(false); comboExpUnit->setEnabled(false);
lblPeriod->setEnabled(false); spinPeriod->setEnabled(false); comboPeriodUnit->setEnabled(false);
lblNumTriggers->setEnabled(true); spinNumTriggers->setEnabled(true);
lblDelay->setEnabled(false); spinDelay->setEnabled(false); comboDelayUnit->setEnabled(false);
lblNumGates->setEnabled(false); spinNumGates->setEnabled(false);
break;
default:
cout<<"ERROR: Timing mode being set to other should never happen"<<endl;
exit(-1);
}
if(mode!=None){
if(myDet->getDetectorsType()==slsDetectorDefs::MYTHEN){
lblNumProbes->setEnabled(true); spinNumProbes->setEnabled(true);
}else{
lblNumProbes->setEnabled(false); spinNumProbes->setEnabled(false);
}
}
/** To disconnect all the signals before changing their values*/
DeInitialization();
float time;
int val;
/**Number of Frames */
if(lblNumFrames->isEnabled()){
val = (int)myDet->setTimer(slsDetectorDefs::FRAME_NUMBER,-1);
spinNumFrames->setValue(val);
#ifdef VERBOSE
cout<<"Getting number of frames : " << val <<endl;
#endif
}
/**Exposure Time */
if(lblExpTime->isEnabled()){
time = (float)(myDet->setTimer(slsDetectorDefs::ACQUISITION_TIME,-1)*(1E-9));
#ifdef VERBOSE
cout<<"Getting acquisition time : " << time << "s" << endl;
#endif
spinExpTime->setValue(time);
comboExpUnit->setCurrentIndex(qDefs::SECONDS);
}
/**Frame Period between exposures */
if(lblPeriod->isEnabled()){
time = (float)(myDet->setTimer(slsDetectorDefs::FRAME_PERIOD,-1)*(1E-9));
#ifdef VERBOSE
cout<<"Getting frame period between exposures : " << time << "s" << endl;
#endif
spinPeriod->setValue(time);
comboPeriodUnit->setCurrentIndex(qDefs::SECONDS);
}
/**Number of Triggers */
if(lblNumTriggers->isEnabled()){
val = (int)myDet->setTimer(slsDetectorDefs::CYCLES_NUMBER,-1);
spinNumTriggers->setValue(val);
#ifdef VERBOSE
cout<<"Getting number of triggers : " << val <<endl;
#endif
}
/**Delay After Trigger */
if(lblDelay->isEnabled()){
time = (float)(myDet->setTimer(slsDetectorDefs::DELAY_AFTER_TRIGGER,-1)*(1E-9));
#ifdef VERBOSE
cout<<"Getting delay after trigger : " << time << "s" << endl;
#endif
spinDelay->setValue(time);
comboDelayUnit->setCurrentIndex(qDefs::SECONDS);
}
/**Number of Gates */
if(lblNumGates->isEnabled()){
val = (int)myDet->setTimer(slsDetectorDefs::GATES_NUMBER,-1);
spinNumGates->setValue(val);
#ifdef VERBOSE
cout<<"Getting number of gates : " << val <<endl;
#endif
}
/**Number of Probes */
if(lblNumProbes->isEnabled()){
val = (int)myDet->setTimer(slsDetectorDefs::PROBES_NUMBER,-1);
spinNumProbes->setValue(val);
#ifdef VERBOSE
cout<<"Getting number of probes : " << val <<endl;
#endif
}
/** To reconnect all the signals after changing their values*/
Initialization(1);
}

View File

@ -59,7 +59,8 @@ void qTabPlot::Initialization(){
void qTabPlot::Enable(bool enable){ void qTabPlot::Enable(bool enable){
boxPlot->setEnabled(enable); btnClone->setEnabled(enable);
btnCloseClones->setEnabled(enable);
box1D->setEnabled(enable); box1D->setEnabled(enable);
box2D->setEnabled(enable); box2D->setEnabled(enable);
boxPlotAxis->setEnabled(enable); boxPlotAxis->setEnabled(enable);

View File

@ -39,18 +39,29 @@ qTabSettings::~qTabSettings(){
void qTabSettings::SetupWidgetWindow(){ void qTabSettings::SetupWidgetWindow(){
/** Settings */
comboSettings->setCurrentIndex(myDet->getSettings(Detector_Index));
} }
void qTabSettings::Initialization(){ void qTabSettings::Initialization(){
/** Settings */
connect(comboSettings,SIGNAL(currentIndexChanged(int)),this,SLOT(setSettings(int)));
} }
void qTabSettings::Enable(bool enable){ void qTabSettings::Enable(bool enable){
//this->setEnabled(enable); comboSettings->setEnabled(enable);
} }
void qTabSettings::setSettings(int index){
slsDetectorDefs::detectorSettings sett = myDet->setSettings((slsDetectorDefs::detectorSettings)index,Detector_Index);
#ifdef VERBOSE
cout<<"Settings have been set to "<<myDet->slsDetectorBase::getDetectorSettings(sett)<<endl;
#endif
}