mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-23 06:50:02 +02:00
bugfix: catching config count at the beginning caused it to crash. now it works without crashing. still to catch cerr output
git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui@96 af1100a4-978c-4157-bff7-07162d2ba061
This commit is contained in:
parent
e104b1d529
commit
34b3a8b01b
@ -95,23 +95,27 @@ void qDetectorMain::SetUpWidgetWindow(const string fName){
|
|||||||
layoutTabs->addWidget(tabs);
|
layoutTabs->addWidget(tabs);
|
||||||
|
|
||||||
|
|
||||||
// creating the messages tab before the plots and detector to catch config stdout
|
// creating the messages tab before the plots and detector to catch config stdout
|
||||||
tab_messages = new qTabMessages (this); cout<<"Messages ready"<<endl;
|
tab_messages = new qTabMessages (this); cout<<"Messages ready"<<endl;
|
||||||
|
//no scroll buttons this way
|
||||||
|
tabs->insertTab(Messages, tab_messages, "Messages");
|
||||||
|
|
||||||
// settings up detector
|
// settings up detector
|
||||||
SetUpDetector(fName);
|
SetUpDetector(fName);
|
||||||
|
|
||||||
// plot setup
|
// plot setup
|
||||||
myPlot = new qDrawPlot(dockWidgetPlot,myDet);cout<<"DockPlot ready"<<endl;
|
myPlot = new qDrawPlot(dockWidgetPlot,myDet); cout<<"DockPlot ready"<<endl;
|
||||||
dockWidgetPlot->setWidget(myPlot);
|
dockWidgetPlot->setWidget(myPlot);
|
||||||
|
|
||||||
//settings messages to have the det reference
|
//settings messages to have the det reference
|
||||||
tab_messages->SetDetectorReference(myDet);
|
tab_messages->SetDetectorReference(myDet);
|
||||||
// creating all the other tab widgets
|
// creating all the other tab widgets
|
||||||
tab_measurement = new qTabMeasurement (this, myDet,myPlot); cout<<"Measurement ready"<<endl;
|
tab_measurement = new qTabMeasurement (this, myDet,myPlot); cout<<"Measurement ready"<<endl;
|
||||||
tab_dataoutput = new qTabDataOutput (this, myDet); cout<<"DataOutput ready"<<endl;
|
tab_dataoutput = new qTabDataOutput (this, myDet); cout<<"DataOutput ready"<<endl;
|
||||||
tab_plot = new qTabPlot (this, myDet,myPlot); cout<<"Plot ready"<<endl;
|
tab_plot = new qTabPlot (this, myDet,myPlot); cout<<"Plot ready"<<endl;
|
||||||
tab_actions = new qTabActions (this, myDet); cout<<"Actions ready"<<endl;
|
tab_actions = new qTabActions (this, myDet); cout<<"Actions ready"<<endl;
|
||||||
tab_settings = new qTabSettings (this, myDet); cout<<"Settings ready"<<endl;
|
tab_settings = new qTabSettings (this, myDet); cout<<"Settings ready"<<endl;
|
||||||
tab_advanced = new qTabAdvanced (this, myDet,myPlot); cout<<"Advanced ready"<<endl;
|
tab_advanced = new qTabAdvanced (this, myDet,myPlot); cout<<"Advanced ready"<<endl;
|
||||||
tab_debugging = new qTabDebugging (this, myDet); cout<<"Debugging ready"<<endl;
|
tab_debugging = new qTabDebugging (this, myDet); cout<<"Debugging ready"<<endl;
|
||||||
tab_developer = new qTabDeveloper (this, myDet); cout<<"Developer ready"<<endl;
|
tab_developer = new qTabDeveloper (this, myDet); cout<<"Developer ready"<<endl;
|
||||||
// creating the scroll area widgets for the tabs
|
// creating the scroll area widgets for the tabs
|
||||||
@ -137,9 +141,12 @@ void qDetectorMain::SetUpWidgetWindow(const string fName){
|
|||||||
tabs->insertTab(Advanced, scroll[Advanced], "Advanced");
|
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");
|
||||||
// Prefer this to expand and not have scroll buttons
|
|
||||||
tabs->insertTab(Messages, tab_messages, "Messages");
|
|
||||||
|
|
||||||
|
//swap tabs so that messages is last tab
|
||||||
|
tabs->tabBar()->moveTab(tabs->indexOf(tab_messages),Messages);
|
||||||
|
tabs->setCurrentIndex(Measurement);
|
||||||
|
|
||||||
|
//other tab properties
|
||||||
// Default tab color
|
// Default tab color
|
||||||
defaultTabColor = tabs->tabBar()->tabTextColor(DataOutput);
|
defaultTabColor = tabs->tabBar()->tabTextColor(DataOutput);
|
||||||
//Set the current tab(measurement) to blue as it is the current one
|
//Set the current tab(measurement) to blue as it is the current one
|
||||||
|
@ -25,7 +25,7 @@ using namespace std;
|
|||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
qTabMessages::qTabMessages(QWidget *parent):QWidget(parent),myDet(0){
|
qTabMessages::qTabMessages(QWidget *parent):QWidget(parent),myDet(0),qout(NULL){
|
||||||
SetupWidgetWindow();
|
SetupWidgetWindow();
|
||||||
Initialization();
|
Initialization();
|
||||||
}
|
}
|
||||||
@ -65,7 +65,7 @@ void qTabMessages::SetupWidgetWindow(){
|
|||||||
gridLayout->addItem(new QSpacerItem(15,10,QSizePolicy::Fixed,QSizePolicy::Fixed),2,0);
|
gridLayout->addItem(new QSpacerItem(15,10,QSizePolicy::Fixed,QSizePolicy::Fixed),2,0);
|
||||||
gridLayout->addWidget(dispLog,3,0,1,5);
|
gridLayout->addWidget(dispLog,3,0,1,5);
|
||||||
|
|
||||||
qout=new qDebugStream(cout,cerr, this);cout<<"working!"<<endl;
|
qout=new qDebugStream(cout,cerr, this);
|
||||||
//qerr=new qDebugStream(cerr,this);
|
//qerr=new qDebugStream(cerr,this);
|
||||||
|
|
||||||
//qerr=NULL;
|
//qerr=NULL;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user